/* =========================================================================
   FerSaSoft Finanzas — Estilo "Neobank oscuro"
   Oscuro por defecto · tarjetas glass + glow · acento esmeralda→lima
   Inter · números grandes y tabulares. Tema claro disponible vía toggle.
   ========================================================================= */
:root {
  --bg: #0c0e13;
  --surface: rgba(255, 255, 255, 0.045);     /* vidrio sobre el carbón */
  --surface-2: rgba(255, 255, 255, 0.08);
  --ink: #eef2f0;
  --ink-soft: #c1c9cf;
  --muted: #8a93a0;
  --muted-2: #5c6675;
  --line: rgba(255, 255, 255, 0.10);
  --line-strong: rgba(255, 255, 255, 0.17);

  --brand: #13e29a;
  --brand-2: #7af0c0;
  --brand-ink: #2ee6a6;                       /* enlaces / texto activo */
  --brand-tint: rgba(19, 226, 154, 0.13);
  --brand-grad: linear-gradient(135deg, #13e29a 0%, #8df0a8 100%);

  --green: #2ee6a6;
  --green-tint: rgba(46, 230, 166, 0.14);
  --red: #ff5a6e;
  --red-tint: rgba(255, 90, 110, 0.14);
  --amber: #f6c44b;
  --amber-tint: rgba(246, 196, 75, 0.14);
  --blue: #5aa2ff;
  --blue-tint: rgba(90, 162, 255, 0.14);

  --radius: 18px;
  --radius-sm: 12px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow: 0 2px 10px rgba(0, 0, 0, .45), 0 14px 34px -10px rgba(0, 0, 0, .55);
  --shadow-lg: 0 26px 64px -18px rgba(0, 0, 0, .72);
  --ring: 0 0 0 3px rgba(19, 226, 154, .32);

  --t: 160ms cubic-bezier(.4,0,.2,1);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-feature-settings: "cv02","cv11","ss01";
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  letter-spacing: -0.01em;
}
a { color: var(--brand-ink); text-decoration: none; transition: color var(--t); }
a:hover { color: var(--brand); }
::selection { background: rgba(109,94,252,.18); }
h1, h2, h3 { letter-spacing: -0.02em; }

/* ---------- Layout ---------- */
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: 252px;
  background: var(--surface);
  border-right: 1px solid var(--line);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  position: sticky;
  top: 0;
  height: 100vh;
}
.brand {
  font-size: 1.18rem; font-weight: 800; color: var(--ink);
  margin: 4px 6px 22px; display: flex; align-items: center; gap: 9px;
  letter-spacing: -0.03em;
}
.brand small {
  display: block; font-weight: 500; font-size: .7rem; color: var(--muted-2);
  letter-spacing: 0; margin-top: 1px;
}
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 12px; border-radius: var(--radius-sm);
  color: var(--muted); font-size: .9rem; font-weight: 500;
  transition: background var(--t), color var(--t);
}
.nav a:hover { background: var(--surface-2); color: var(--ink); }
.nav a.active {
  background: var(--brand-tint); color: var(--brand-ink); font-weight: 600;
}
.sidebar .spacer { flex: 1; }
.sidebar .user-box {
  border-top: 1px solid var(--line); padding-top: 14px; margin-top: 8px;
  display: flex; flex-direction: column; gap: 5px;
}
.user-name { font-size: .85rem; font-weight: 600; color: var(--ink-soft); }
.logout-link { font-size: .8rem; color: var(--muted-2); }
.logout-link:hover { color: var(--red); }

.content { flex: 1; padding: 30px 38px; max-width: 1240px; width: 100%; margin: 0 auto; }
.page-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; flex-wrap: wrap; gap: 12px; }
.page-head h1 { font-size: 1.6rem; margin: 0; font-weight: 700; }
.muted { color: var(--muted); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--brand-grad); color: #042b1d; border: 0; cursor: pointer;
  padding: 10px 17px; border-radius: var(--radius-sm); font-size: .88rem; font-weight: 700;
  font-family: inherit; letter-spacing: -0.01em;
  box-shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 18px -6px rgba(19,226,154,.5);
  transition: transform var(--t), box-shadow var(--t), background var(--t), filter var(--t);
}
.btn:hover { filter: brightness(1.06); transform: translateY(-1px); box-shadow: 0 2px 4px rgba(0,0,0,.3), 0 10px 26px -6px rgba(19,226,154,.6); text-decoration: none; color: #042b1d; }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: none; box-shadow: var(--ring); }
.btn.secondary {
  background: var(--surface); color: var(--ink); border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-sm);
}
.btn.secondary:hover { background: var(--surface-2); color: var(--ink); filter: none; }
.btn.danger { background: var(--red); color: #2a0710; box-shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 18px -6px rgba(255,90,110,.55); }
.btn.small { padding: 6px 11px; font-size: .8rem; border-radius: 9px; }

/* ---------- Cards / grids ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(248px, 1fr)); gap: 18px; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow-sm); transition: transform var(--t), box-shadow var(--t), border-color var(--t);
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: var(--line-strong); }
.account-card { position: relative; overflow: hidden; border-left: 4px solid var(--brand); }
.account-card .acc-type { font-size: .68rem; color: var(--muted-2); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }
.account-card .acc-name { font-weight: 700; font-size: 1.05rem; margin: 5px 0; display: flex; align-items: center; gap: 8px; letter-spacing: -0.02em; }
.account-card .acc-balance { font-size: 1.4rem; font-weight: 700; margin-top: 10px; font-variant-numeric: tabular-nums; letter-spacing: -0.03em; }
.balance-neg { color: var(--red); }
.balance-pos { color: var(--green); }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 18px; margin-bottom: 26px; }
.stat {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow-sm); transition: box-shadow var(--t), transform var(--t);
}
.stat:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.stat .label { font-size: .76rem; color: var(--muted); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; }
.stat .value { font-size: 1.7rem; font-weight: 700; margin-top: 8px; font-variant-numeric: tabular-nums; letter-spacing: -0.03em; }

.section {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow-sm); margin-bottom: 22px;
}
.section h2 { font-size: 1.02rem; margin: 0 0 16px; font-weight: 700; }
.two-col { display: grid; grid-template-columns: 1.35fr 1fr; gap: 22px; }

/* ---------- Tables ---------- */
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { text-align: left; padding: 11px 12px; border-bottom: 1px solid var(--line); }
th {
  font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted-2);
  font-weight: 600; border-bottom: 1px solid var(--line-strong);
}
tbody tr { transition: background var(--t); }
tbody tr:hover { background: var(--surface-2); }
tbody tr:last-child td { border-bottom: 0; }
.amount { font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.tag {
  display: inline-block; padding: 3px 10px; border-radius: var(--radius-pill); font-size: .72rem; font-weight: 600;
  letter-spacing: .01em;
}
.tag.income { background: var(--green-tint); color: var(--green); }
.tag.expense { background: var(--red-tint); color: var(--red); }
.tag.transfer { background: var(--blue-tint); color: var(--blue); }
.tag.adjustment { background: var(--amber-tint); color: var(--amber); }

/* ---------- Forms ---------- */
.form-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow-sm); max-width: 640px;
}
.field { margin-bottom: 17px; }
.field label { display: block; font-size: .84rem; font-weight: 600; margin-bottom: 7px; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  width: 100%; padding: 10px 13px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); font-size: .92rem;
  background: var(--surface); color: var(--ink); font-family: inherit;
  transition: border-color var(--t), box-shadow var(--t);
}
.field input::placeholder, .field textarea::placeholder { color: var(--muted-2); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--brand); box-shadow: var(--ring); }
.field input[type="color"] { padding: 4px; height: 42px; cursor: pointer; }
.field small { display: block; margin-top: 5px; font-size: .78rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.form-actions { display: flex; gap: 10px; margin-top: 6px; }
.inline-form { display: flex; gap: 13px; align-items: end; flex-wrap: wrap; }

/* ---------- Login ---------- */
.auth-wrap {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px;
  background:
    radial-gradient(1100px 600px at 12% -8%, rgba(109,94,252,.22), transparent 60%),
    radial-gradient(900px 600px at 100% 110%, rgba(168,85,247,.20), transparent 55%),
    #0e1018;
}
.auth-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 40px;
  width: 100%; max-width: 408px; box-shadow: var(--shadow-lg);
}
.auth-card h1 { margin: 0 0 6px; font-size: 1.5rem; font-weight: 800; letter-spacing: -0.03em; }
.auth-card .sub { color: var(--muted); font-size: .9rem; margin-bottom: 26px; }
.auth-card .btn { width: 100%; justify-content: center; padding: 12px; font-size: .92rem; margin-top: 4px; }
.auth-switch { text-align: center; margin-top: 20px; font-size: .88rem; color: var(--muted); }
.error { background: var(--red-tint); color: var(--red); padding: 11px 15px; border-radius: var(--radius-sm); font-size: .86rem; margin-bottom: 18px; font-weight: 500; }
.empty { text-align: center; color: var(--muted); padding: 44px 20px; font-size: .92rem; }

/* ---------- Filters bar ---------- */
.filters { display: flex; gap: 12px; flex-wrap: wrap; align-items: end; margin-bottom: 18px; }
.filters .field { margin-bottom: 0; }

/* ---------- Mobile ---------- */
@media (max-width: 860px) {
  .layout { flex-direction: column; }
  .sidebar {
    width: 100%; height: auto; position: sticky; top: 0; z-index: 20;
    flex-direction: row; flex-wrap: wrap; align-items: center;
    padding: 10px 14px; gap: 8px; border-right: 0; border-bottom: 1px solid var(--line);
  }
  .brand { margin: 0 auto 0 0; font-size: 1.05rem; }   /* empuja el toggle a la derecha */
  .brand small { display: none; }
  .sidebar .spacer, .sidebar .user-box { display: none; }
  /* Nav como barra deslizable horizontal (una sola fila, swipe) */
  .nav {
    order: 2; width: 100%; flex-direction: row; flex-wrap: nowrap; gap: 4px;
    overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 2px;
    scrollbar-width: none;
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { flex: 0 0 auto; white-space: nowrap; padding: 8px 12px; font-size: .85rem; }
  /* Toggle de tema compacto arriba a la derecha (especificidad para ganar a la base) */
  .sidebar .theme-toggle { order: 1; width: auto; margin: 0; padding: 7px 11px; font-size: .8rem; }

  .content { padding: 16px; }
  .two-col { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }

  /* Tablas anchas: scroll horizontal solo en secciones con tabla (no se cortan) */
  .section:has(> table) { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .section > table { min-width: 100%; }
  .section > table th, .section > table td { white-space: nowrap; }

  /* Formularios horizontales (filtros, alta rápida) a ancho completo */
  .inline-form { flex-direction: column; align-items: stretch; gap: 12px; }
  .inline-form .field { margin-bottom: 0; }
  .inline-form .field input,
  .inline-form .field select { width: 100%; }
  .inline-form .btn { width: 100%; justify-content: center; }

  .page-head h1 { font-size: 1.35rem; }
  .stat .value { font-size: 1.45rem; }
}

/* =========================================================================
   Fase 3 — banner de consejos, progreso, alertas, modo oscuro
   ========================================================================= */

/* ---- Banner de consejos ---- */
.advice-banner {
  display: flex; align-items: center; gap: 14px;
  background: linear-gradient(100deg, var(--brand-tint), var(--surface));
  border: 1px solid var(--line); border-left: 4px solid var(--brand);
  border-radius: var(--radius); padding: 13px 18px; margin-bottom: 22px;
  box-shadow: var(--shadow-sm);
}
.advice-ico { font-size: 1.3rem; }
.advice-body { flex: 1; line-height: 1.35; }
.advice-text { font-size: .9rem; font-weight: 500; color: var(--ink-soft); }
.advice-src { display: block; font-size: .76rem; color: var(--brand-ink); font-weight: 600; margin-top: 2px; }
.advice-next {
  background: var(--surface); border: 1px solid var(--line-strong); color: var(--muted);
  width: 32px; height: 32px; border-radius: 9px; cursor: pointer; font-size: 1rem;
  transition: all var(--t); flex-shrink: 0;
}
.advice-next:hover { background: var(--brand); color: #fff; border-color: var(--brand); transform: rotate(90deg); }

/* ---- Lista de consejos (sección Crecimiento) ---- */
.advice-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.advice-list li { font-size: .9rem; color: var(--ink-soft); line-height: 1.4; padding-left: 4px; }
.advice-list-tag {
  display: inline-block; background: var(--brand-tint); color: var(--brand-ink);
  font-size: .68rem; font-weight: 600; padding: 1px 8px; border-radius: var(--radius-pill); margin-right: 6px;
}

/* ---- Barra de progreso ---- */
.progress { width: 100%; height: 10px; background: var(--line); border-radius: var(--radius-pill); overflow: hidden; }
.progress-bar { height: 100%; background: var(--brand-grad); border-radius: var(--radius-pill); transition: width .5s ease; }

/* ---- Alertas ---- */
.alerts { display: flex; flex-direction: column; gap: 10px; margin-bottom: 22px; }
.alert {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 16px; border-radius: var(--radius-sm); font-size: .88rem; border: 1px solid var(--line);
}
.alert-amber { background: var(--amber-tint); border-color: #f3d9a8; color: #8a5a06; }
.alert-red { background: var(--red-tint); border-color: #f5c2cd; color: #a01233; }
.alert-tag { font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.alert-actions { display: inline-flex; align-items: center; gap: 12px; }

/* ---- Alertas colapsables (botón "Ver detalle") ---- */
.alerts-collapse {
  margin-bottom: 22px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); box-shadow: var(--shadow-sm); overflow: hidden;
}
.alerts-collapse > summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center;
  gap: 12px; padding: 14px 18px; font-weight: 600; font-size: .92rem; color: var(--ink-soft);
  border-left: 4px solid var(--amber); transition: background var(--t);
}
.alerts-collapse > summary::-webkit-details-marker { display: none; }
.alerts-collapse > summary:hover { background: var(--surface-2); }
.alerts-summary-hint { display: inline-flex; align-items: center; gap: 6px; font-size: .82rem; font-weight: 600; color: var(--brand-ink); }
.alerts-summary-hint::after { content: "▾"; transition: transform var(--t); }
.alerts-collapse[open] > summary { border-bottom: 1px solid var(--line); }
.alerts-collapse[open] .alerts-summary-hint { color: var(--muted); }
.alerts-collapse[open] .alerts-summary-hint::after { transform: rotate(180deg); }
.alerts-overdue { color: var(--red); font-weight: 700; }
.alerts-collapse .alerts { margin: 0; padding: 14px; }

/* ---- Label con acción a la derecha (ej: + Nueva categoría) ---- */
.label-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.label-row .btn.small { font-weight: 600; }

/* ---- Modal ---- */
.modal-overlay {
  position: fixed; inset: 0; z-index: 100; padding: 20px;
  background: rgba(10, 11, 17, .55); backdrop-filter: blur(2px);
  display: none; align-items: center; justify-content: center;
}
.modal-overlay.show { display: flex; animation: modal-fade var(--t); }
@keyframes modal-fade { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; width: 100%; max-width: 420px; box-shadow: var(--shadow-lg);
}
.modal h3 { margin: 0 0 18px; font-size: 1.1rem; font-weight: 700; }
.modal.modal-lg { max-width: 560px; }

/* ---- Tarjetas de deuda (panel compacto) ---- */
.debt-card { display: flex; flex-direction: column; gap: 4px; }
.debt-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 4px; }
.debt-name { font-weight: 700; font-size: 1.02rem; letter-spacing: -0.02em; }
.debt-pending { display: flex; flex-direction: column; gap: 2px; margin: 6px 0 10px; }
.debt-pending-val { font-size: 1.5rem; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -0.03em; }
.debt-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 12px; font-size: .82rem; color: var(--ink-soft); }
.debt-actions { display: flex; align-items: center; gap: 8px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.debt-payments { margin-top: 12px; }
.debt-payments > summary {
  cursor: pointer; font-size: .82rem; font-weight: 600; color: var(--brand-ink);
  list-style: none; padding: 4px 0;
}
.debt-payments > summary::-webkit-details-marker { display: none; }
.debt-payments > summary::before { content: "▸ "; }
.debt-payments[open] > summary::before { content: "▾ "; }
.debt-payments ul { list-style: none; margin: 6px 0 0; padding: 0; }
.debt-payments li { display: flex; justify-content: space-between; gap: 10px; font-size: .82rem; padding: 5px 0; border-bottom: 1px solid var(--line); }
.debt-payments li:last-child { border-bottom: 0; }

/* ---- Toggle de tema ---- */
.theme-toggle {
  display: flex; align-items: center; gap: 8px; width: 100%;
  background: var(--surface-2); border: 1px solid var(--line); color: var(--muted);
  padding: 9px 12px; border-radius: var(--radius-sm); font-size: .85rem; font-weight: 500;
  font-family: inherit; cursor: pointer; margin-bottom: 8px; transition: all var(--t);
}
.theme-toggle:hover { background: var(--brand-tint); color: var(--brand-ink); border-color: var(--brand-tint); }

/* =========================================================================
   MODO OSCURO
   ========================================================================= */
:root[data-theme="light"] {
  --bg: #f4f6f5;
  --surface: #ffffff;
  --surface-2: #f2f5f3;
  --ink: #0f1915;
  --ink-soft: #38443e;
  --muted: #69756e;
  --muted-2: #99a39c;
  --line: #e7eae8;
  --line-strong: #d7ddd9;

  --brand: #0e9f6e;
  --brand-2: #34d399;
  --brand-ink: #0b8c61;
  --brand-tint: #e6f6ef;
  --brand-grad: linear-gradient(135deg, #0e9f6e 0%, #34d399 100%);

  --green: #0e9f6e;
  --green-tint: #e6f6ef;
  --red: #e11d48;
  --red-tint: #fdeaef;
  --amber: #d97706;
  --amber-tint: #fdf2e3;
  --blue: #2563eb;
  --blue-tint: #e8f0fe;

  --shadow-sm: 0 1px 2px rgba(16,24,20,.05), 0 1px 3px rgba(16,24,20,.06);
  --shadow: 0 2px 8px rgba(16,24,20,.08), 0 12px 28px -10px rgba(16,24,20,.14);
  --shadow-lg: 0 20px 50px -16px rgba(16,24,20,.22);
}
:root[data-theme="light"] body::before { opacity: 0; }
:root[data-theme="light"] .btn { color: #ffffff; }
:root[data-theme="light"] .btn:hover { color: #ffffff; }
:root[data-theme="light"] .btn.danger { color: #ffffff; }
:root[data-theme="light"] .field input[type="color"] { background: var(--surface); }

/* =========================================================================
   Tratamiento Neobank — glow de fondo, glass y números grandes
   ========================================================================= */
body::before {
  content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(920px 540px at 6% -10%, rgba(19,226,154,.16), transparent 60%),
    radial-gradient(820px 520px at 110% 4%, rgba(122,240,192,.10), transparent 55%),
    radial-gradient(760px 620px at 50% 122%, rgba(90,162,255,.08), transparent 60%);
}
.card, .stat, .section, .sidebar, .modal, .form-card, .alerts-collapse, .advice-banner {
  backdrop-filter: blur(16px) saturate(125%);
  -webkit-backdrop-filter: blur(16px) saturate(125%);
}
.stat .value, .acc-balance, .debt-pending-val { font-weight: 800; }
.stat .value { font-size: 1.9rem; }
/* alertas legibles en ambos temas */
.alert-amber { background: var(--amber-tint); border-color: var(--line); color: var(--amber); }
.alert-red { background: var(--red-tint); border-color: var(--line); color: var(--red); }

/* ---- Compromiso mensual (dashboard) ---- */
.commit-row { display: grid; grid-template-columns: auto 1fr; gap: 10px 22px; align-items: center; }
.commit-total .label { font-size: .74rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.commit-total .value { font-size: 1.7rem; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.03em; }
.commit-bar { display: flex; height: 14px; border-radius: var(--radius-pill); overflow: hidden; background: var(--surface-2); }
.commit-seg { height: 100%; }
.commit-legend { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: .85rem; color: var(--ink-soft); }
.commit-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: baseline; }
@media (max-width: 860px) { .commit-row { grid-template-columns: 1fr; } }

/* ---- Chips de filtro (vistas) ---- */
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.chip {
  padding: 7px 14px; border-radius: var(--radius-pill); font-size: .85rem; font-weight: 600;
  background: var(--surface); border: 1px solid var(--line-strong); color: var(--ink-soft);
  transition: all var(--t);
}
.chip:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.chip-on { background: var(--brand-tint); border-color: transparent; color: var(--brand-ink); }
