/* ═══════════════════════════════════════════════
   FAMILY FINANCE FLOW — Design System
   Aesthetic: "Structured Clarity" — Editorial finance
   ═══════════════════════════════════════════════ */

:root {
  --bg: #f4f3ef;
  --bg-2: #eceae4;
  --surface: #ffffff;
  --surface-2: #f9f8f5;
  --border: #e2dfd8;
  --border-strong: #c8c4bb;

  --text-primary: #1a1916;
  --text-secondary: #6b6860;
  --text-muted: #9e9b94;

  --accent: #2d5be3;
  --accent-light: #eef1fd;
  --accent-dark: #1a3eb0;

  --green: #1a7a4a;
  --green-light: #e8f5ee;
  --red: #c0392b;
  --red-light: #fdecea;
  --orange: #d35400;
  --orange-light: #fef3ed;
  --amber: #b7791f;
  --amber-light: #fef9e7;

  --sidebar-w: 220px;
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow: 0 4px 12px rgba(0,0,0,0.08), 0 2px 4px rgba(0,0,0,0.04);
  --shadow-lg: 0 12px 32px rgba(0,0,0,0.1), 0 4px 8px rgba(0,0,0,0.06);

  --font: 'Sora', sans-serif;
  --font-mono: 'DM Mono', monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 15px; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-primary);
  display: flex;
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* ─── SCROLLBAR ─── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 99px; }

/* ══════════════════════════════════════
   SIDEBAR
══════════════════════════════════════ */
.sidebar {
  width: var(--sidebar-w);
  background: var(--text-primary);
  display: flex;
  flex-direction: column;
  padding: 24px 16px;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  transition: transform 0.25s ease;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 8px 28px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 20px;
}

.logo-icon {
  font-size: 22px;
  color: #7eb3ff;
  line-height: 1;
}

.logo-text {
  font-size: 17px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.08em;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  transition: all 0.15s ease;
}

.nav-item:hover { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.85); }
.nav-item.active { background: rgba(255,255,255,0.13); color: #fff; }

.nav-icon { font-size: 14px; width: 18px; text-align: center; }
.nav-label { flex: 1; }

.sidebar-footer { padding-top: 16px; border-top: 1px solid rgba(255,255,255,0.1); }

.btn-add-global {
  width: 100%;
  padding: 11px 16px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: background 0.15s ease;
  letter-spacing: 0.01em;
}

.btn-add-global:hover { background: var(--accent-dark); }
.btn-add-global span { font-size: 18px; font-weight: 300; line-height: 1; }

/* ══════════════════════════════════════
   MAIN CONTENT
══════════════════════════════════════ */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  padding: 32px 36px;
  min-height: 100vh;
  overflow-y: auto;
}

/* ─── PAGE HEADER ─── */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 28px;
  flex-wrap: wrap;
  gap: 12px;
}

.page-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.page-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 3px;
}

/* ══════════════════════════════════════
   CARDS & SURFACES
══════════════════════════════════════ */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.card-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ══════════════════════════════════════
   DASHBOARD
══════════════════════════════════════ */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  position: relative;
  overflow: hidden;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.stat-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }

.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--accent);
  border-radius: var(--radius) var(--radius) 0 0;
}

.stat-card.green::before { background: var(--green); }
.stat-card.red::before { background: var(--red); }
.stat-card.amber::before { background: var(--amber); }

.stat-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.stat-value {
  font-family: var(--font-mono);
  font-size: 26px;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.stat-value.positive { color: var(--green); }
.stat-value.negative { color: var(--red); }

.stat-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* DASHBOARD BOTTOM GRID */
.dashboard-bottom {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 20px;
}

/* ALERTS */
.alerts-list { display: flex; flex-direction: column; gap: 10px; }

.alert-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
}

.alert-item.warning { background: var(--amber-light); color: var(--amber); }
.alert-item.danger { background: var(--red-light); color: var(--red); }
.alert-item.info { background: var(--accent-light); color: var(--accent); }
.alert-item.success { background: var(--green-light); color: var(--green); }

.alert-icon { font-size: 16px; flex-shrink: 0; }

/* ══════════════════════════════════════
   GRIDS
══════════════════════════════════════ */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}

/* ══════════════════════════════════════
   CREDIT CARD VISUAL
══════════════════════════════════════ */
.credit-card-visual {
  background: linear-gradient(135deg, #1a1916 0%, #2d3748 100%);
  border-radius: var(--radius);
  padding: 22px;
  color: #fff;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.credit-card-visual:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }

.credit-card-visual::before {
  content: '';
  position: absolute;
  top: -40px; right: -40px;
  width: 130px; height: 130px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
}

.credit-card-visual::after {
  content: '';
  position: absolute;
  bottom: -50px; left: 30px;
  width: 160px; height: 160px;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
}

.cc-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.cc-name { font-size: 15px; font-weight: 600; letter-spacing: 0.02em; }
.cc-chip { font-size: 20px; opacity: 0.7; }

.cc-limit-bar {
  margin-bottom: 14px;
}

.cc-limit-label {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  opacity: 0.65;
  margin-bottom: 6px;
}

.cc-bar-track {
  height: 4px;
  background: rgba(255,255,255,0.15);
  border-radius: 2px;
}

.cc-bar-fill {
  height: 100%;
  border-radius: 2px;
  background: linear-gradient(90deg, #7eb3ff, #4d8af0);
  transition: width 0.5s ease;
}

.cc-bar-fill.warning { background: linear-gradient(90deg, #fbbf24, #f59e0b); }
.cc-bar-fill.danger { background: linear-gradient(90deg, #f87171, #ef4444); }

.cc-bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.cc-dates { font-size: 11px; opacity: 0.6; line-height: 1.7; }

.cc-available {
  text-align: right;
}

.cc-available-label { font-size: 10px; opacity: 0.6; }
.cc-available-value { font-family: var(--font-mono); font-size: 18px; font-weight: 500; }

.cc-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  position: relative; z-index: 1;
}

.cc-btn {
  flex: 1;
  padding: 7px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.85);
  border-radius: 6px;
  font-size: 11.5px;
  font-family: var(--font);
  cursor: pointer;
  transition: background 0.15s;
  font-weight: 500;
}

.cc-btn:hover { background: rgba(255,255,255,0.15); }

/* ══════════════════════════════════════
   ACCOUNT CARD
══════════════════════════════════════ */
.account-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: box-shadow 0.2s, transform 0.2s;
}

.account-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }

.account-icon {
  width: 46px; height: 46px;
  border-radius: 12px;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.account-info { flex: 1; min-width: 0; }
.account-name { font-size: 14px; font-weight: 600; margin-bottom: 2px; }
.account-balance { font-family: var(--font-mono); font-size: 20px; font-weight: 500; }
.account-balance.positive { color: var(--green); }
.account-balance.negative { color: var(--red); }

.account-actions { display: flex; gap: 6px; }

/* ══════════════════════════════════════
   TABLES & LISTS
══════════════════════════════════════ */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

.data-table th {
  text-align: left;
  padding: 10px 14px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.data-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border);
  color: var(--text-primary);
  vertical-align: middle;
}

.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--surface-2); }

/* ══════════════════════════════════════
   BADGES
══════════════════════════════════════ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.badge-green { background: var(--green-light); color: var(--green); }
.badge-red { background: var(--red-light); color: var(--red); }
.badge-amber { background: var(--amber-light); color: var(--amber); }
.badge-blue { background: var(--accent-light); color: var(--accent); }
.badge-gray { background: var(--bg-2); color: var(--text-secondary); }

/* ══════════════════════════════════════
   BUTTONS
══════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.15s ease;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); }

.btn-secondary { background: var(--surface); color: var(--text-primary); border: 1px solid var(--border); }
.btn-secondary:hover { background: var(--bg-2); }

.btn-danger { background: var(--red-light); color: var(--red); border: 1px solid #f5c6c2; }
.btn-danger:hover { background: #fbd5d2; }

.btn-success { background: var(--green-light); color: var(--green); border: 1px solid #b7deca; }
.btn-success:hover { background: #c9e8d5; }

.btn-ghost { background: transparent; color: var(--text-secondary); border: 1px solid transparent; }
.btn-ghost:hover { background: var(--bg-2); color: var(--text-primary); }

.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-icon { padding: 7px; border-radius: var(--radius-sm); }

/* ══════════════════════════════════════
   MODAL
══════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 8, 0.55);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  animation: overlayIn 0.2s ease;
}

.modal-overlay.active { display: flex; }

@keyframes overlayIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: modalIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-lg { max-width: 680px; }

@keyframes modalIn {
  from { opacity: 0; transform: translateY(16px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
  padding: 22px 24px 16px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-title { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; }

.modal-close {
  width: 30px; height: 30px;
  border-radius: 6px;
  border: none;
  background: var(--bg-2);
  color: var(--text-secondary);
  font-size: 18px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s;
  line-height: 1;
}

.modal-close:hover { background: var(--border); color: var(--text-primary); }

.modal-body { padding: 20px 24px; }
.modal-footer { padding: 16px 24px; border-top: 1px solid var(--border); display: flex; gap: 10px; justify-content: flex-end; }

/* ══════════════════════════════════════
   FORMS
══════════════════════════════════════ */
.form-group { margin-bottom: 16px; }

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 10px 13px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 14px;
  color: var(--text-primary);
  background: var(--surface);
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: none;
  outline: none;
}

.form-input:focus,
.form-select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(45, 91, 227, 0.12); }

.form-input.error { border-color: var(--red); }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }

.form-hint { font-size: 11.5px; color: var(--text-muted); margin-top: 4px; }

/* TOGGLE TABS */
.toggle-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.toggle-tab {
  padding: 9px;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  background: var(--surface);
  color: var(--text-muted);
  transition: all 0.15s;
  font-family: var(--font);
}

.toggle-tab.active.entrada { background: var(--green-light); color: var(--green); }
.toggle-tab.active.saida { background: var(--red-light); color: var(--red); }

.toggle-tabs-3 { grid-template-columns: 1fr 1fr 1fr; }

/* ══════════════════════════════════════
   FATURA CARDS
══════════════════════════════════════ */
.fatura-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  cursor: pointer;
  transition: box-shadow 0.2s, transform 0.2s;
}

.fatura-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }

.fatura-month {
  min-width: 52px;
  text-align: center;
}

.fatura-month-num {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 500;
  color: var(--accent);
  line-height: 1;
}

.fatura-month-name {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-top: 2px;
}

.fatura-info { flex: 1; min-width: 0; }
.fatura-card-name { font-size: 13px; font-weight: 600; margin-bottom: 3px; }
.fatura-total { font-family: var(--font-mono); font-size: 17px; color: var(--text-primary); }

/* ══════════════════════════════════════
   FILTERS BAR
══════════════════════════════════════ */
.filters-bar {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 20px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.filter-select {
  padding: 7px 11px;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  font-family: var(--font);
  font-size: 13px;
  background: var(--bg);
  color: var(--text-primary);
  cursor: pointer;
  outline: none;
  appearance: none;
  padding-right: 28px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%236b6860'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  transition: border-color 0.15s;
}

.filter-select:focus { border-color: var(--accent); }

.filters-spacer { flex: 1; }

/* ══════════════════════════════════════
   EMPTY STATE
══════════════════════════════════════ */
.empty-state {
  text-align: center;
  padding: 52px 24px;
  color: var(--text-muted);
}

.empty-icon { font-size: 36px; margin-bottom: 12px; opacity: 0.5; }
.empty-title { font-size: 15px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.empty-sub { font-size: 13px; color: var(--text-muted); }

/* ══════════════════════════════════════
   CHART CONTAINER
══════════════════════════════════════ */
.chart-container {
  position: relative;
  height: 220px;
}

/* ══════════════════════════════════════
   TOAST
══════════════════════════════════════ */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--text-primary);
  color: #fff;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  animation: toastIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  min-width: 260px;
  max-width: 360px;
  pointer-events: auto;
}

.toast.success { background: #1a5c38; }
.toast.error { background: #8b1e1e; }
.toast.info { background: var(--accent-dark); }

@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes toastOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(20px); }
}

/* ══════════════════════════════════════
   LOADING SPINNER
══════════════════════════════════════ */
.spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  margin: 32px auto;
}

@keyframes spin { to { transform: rotate(360deg); } }

.loading-container { text-align: center; padding: 48px; }
.loading-text { color: var(--text-muted); font-size: 13px; margin-top: 12px; }

/* ══════════════════════════════════════
   AMOUNT DISPLAY
══════════════════════════════════════ */
.amount-positive { color: var(--green); font-family: var(--font-mono); }
.amount-negative { color: var(--red); font-family: var(--font-mono); }
.amount-neutral { font-family: var(--font-mono); }

/* ══════════════════════════════════════
   SECTION DIVIDER
══════════════════════════════════════ */
.section-divider {
  height: 1px;
  background: var(--border);
  margin: 20px 0;
}

/* ══════════════════════════════════════
   FATURAS DETAIL
══════════════════════════════════════ */
.fatura-detail-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

.fatura-detail-card {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.fatura-detail-total {
  font-family: var(--font-mono);
  font-size: 30px;
  font-weight: 500;
  color: var(--text-primary);
}

/* ══════════════════════════════════════
   MELHOR DIA BADGE
══════════════════════════════════════ */
.best-day-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  background: var(--green-light);
  color: var(--green);
  border-radius: 99px;
  font-size: 11px;
  font-weight: 600;
}

/* ══════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════ */
@media (max-width: 1100px) {
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-bottom { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  :root { --sidebar-w: 0px; }
  .sidebar { transform: translateX(-100%); }
  .main-content { margin-left: 0; padding: 20px 16px; }
  .dashboard-grid { grid-template-columns: 1fr; }
}

/* ══════════════════════════════════════
   AUTOCOMPLETE
══════════════════════════════════════ */
.autocomplete-list {
  position: absolute;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  z-index: 300;
  max-height: 160px;
  overflow-y: auto;
  width: 100%;
  top: calc(100% + 4px);
  left: 0;
}

.autocomplete-item {
  padding: 9px 13px;
  font-size: 13.5px;
  cursor: pointer;
  color: var(--text-primary);
  transition: background 0.1s;
}

.autocomplete-item:hover { background: var(--accent-light); color: var(--accent); }

.form-group-relative { position: relative; }

/* HIGHLIGHT SELECTED */
.selected-row { background: var(--accent-light) !important; }

/* SECTION TITLE */
.section-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0 0 10px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

/* CONFIG LINK */
.config-hint {
  background: var(--amber-light);
  border: 1px solid #f0d078;
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-size: 13px;
  color: var(--amber);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}
