/* Plataforma AML · Molina Law Boutique
   Identidad del portal de clientes: tinta, crema y cobre; EB Garamond para títulos y Figtree para el texto.
   Las fuentes van incluidas en /static/fonts (licencia SIL OFL), sin llamadas a servicios externos. */

@font-face { font-family: "EB Garamond"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/eb-garamond-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/eb-garamond-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/figtree-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/figtree-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/figtree-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/figtree-latin-700-normal.woff2") format("woff2"); }

:root {
  --ink: #19130e; --ink-2: #2a231d;
  --text: #19130e; --text-2: #3e362f; --text-3: #554c44; --text-4: #6b625a; --text-5: #938a81;
  --on-ink: #f4f3f1; --on-ink-2: #c4bdb5; --on-ink-3: #8b8279;
  --cream: #f4f3f1; --cream-dark: #ece9e4; --rail: #ece9e4; --surface: #ffffff; --surface-2: #faf9f7;
  --accent: #9a5a2e; --accent-text: #7f4722; --accent-deep: #5e3416; --accent-light: #c79267; --accent-tint: #f3ece6;
  --sage: #6f7d57; --sage-text: #4a5636; --sage-tint: #eef0ea;
  --danger: #a3402b; --danger-text: #86331e; --danger-tint: #f6eae7;
  --border: #e3e0da; --border-2: #c9c5c0; --border-3: #d5d1cb; --divider: #ebe8e3;
  --radius-nav: 4px; --radius-card: 6px; --radius-card-lg: 8px; --radius-pill: 999px;
  --shadow-card: 0 0 0 1px var(--border); --shadow-rest: 0 1px 2px rgba(25, 19, 14, .06); --shadow-hover: 0 2px 10px rgba(25, 19, 14, .08);
  --font-sans: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-display: "EB Garamond", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font-sans); font-size: 14px; line-height: 1.5; color: var(--text); background: var(--cream); }
a { color: var(--accent-text); text-decoration: none; }
a:hover { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; letter-spacing: -.01em; color: var(--text); }
h1 { font-size: 42px; line-height: 1.08; margin: 0; }
h2 { font-size: 26px; line-height: 1.2; margin: 0; }
h3 { font-size: 20px; line-height: 1.25; margin: 0; }
p { margin: 0; }
code { font-size: 12px; background: var(--cream-dark); padding: 1px 5px; border-radius: 3px; }
pre { white-space: pre-wrap; font-family: inherit; margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ------------------------------------------------------------------ estructura */
.app { min-height: 100vh; display: flex; flex-wrap: wrap; }
.sidebar { flex: 1 1 248px; background: var(--rail); border-right: 1px solid var(--border); padding: 28px 20px; display: flex; flex-direction: column; gap: 32px; }
.brand { display: flex; flex-direction: column; gap: 18px; }
.brand-mark { display: flex; align-items: center; gap: 10px; color: var(--text); }
.brand-mark:hover { text-decoration: none; color: var(--text); }
.brand-m { font-family: var(--font-display); font-size: 38px; line-height: 1; font-weight: 500; }
.brand-words { display: flex; flex-direction: column; gap: 3px; border-left: 1px solid var(--border-2); padding-left: 10px; }
.brand-name { font-family: var(--font-display); font-size: 15px; letter-spacing: .2em; }
.brand-sub { font-size: 9px; letter-spacing: .3em; font-weight: 600; color: var(--text-3); }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius-nav); color: var(--text-2); font-weight: 500; }
.nav a:hover { background: rgba(255, 255, 255, .55); color: var(--text); text-decoration: none; }
.nav a[aria-current="page"] { background: var(--surface); box-shadow: var(--shadow-rest); color: var(--text); font-weight: 600; }
.nav svg { flex: 0 0 18px; }
.nav .count { margin-left: auto; font-size: 12px; font-weight: 600; padding: 1px 8px; border-radius: var(--radius-pill); background: var(--ink); color: var(--on-ink); }
.report-btn { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 11px 12px; border: 1px solid var(--border-2); border-radius: var(--radius-nav); background: var(--surface); color: var(--text); font-weight: 600; font-size: 13px; }
.report-btn:hover { text-decoration: none; color: var(--text); border-color: var(--accent); box-shadow: var(--shadow-rest); }
.report-btn svg { color: var(--accent); }
.who { margin-top: 0; padding-top: 20px; border-top: 1px solid var(--border-3); display: flex; flex-direction: column; gap: 4px; }
.who strong { font-size: 13px; }
.who span { font-size: 12px; color: var(--text-3); }
.who a { margin-top: 8px; font-size: 13px; font-weight: 600; }
.main { flex: 999 1 560px; min-width: 0; padding: 36px 48px 72px; }
.container { max-width: 1160px; display: flex; flex-direction: column; gap: 24px; }

@media (max-width: 860px) {
  .sidebar { padding: 18px 16px; gap: 16px; border-right: 0; border-bottom: 1px solid var(--border); }
  .nav { flex-direction: row; flex-wrap: wrap; }
  .nav a { padding: 8px 10px; }
  .who { margin-top: 0; padding-top: 12px; flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
  .report-btn { margin-top: 0; }
  .who a { margin-top: 0; }
  .main { padding: 24px 16px 56px; }
  h1 { font-size: 34px; }
}

/* ------------------------------------------------------------------ cabecera de página */
.crumbs { font-size: 13px; color: var(--text-4); }
.crumbs a { font-weight: 600; }
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.page-head > div:first-child { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--accent-text); }
.lead { font-size: 14px; color: var(--text-4); max-width: 760px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }

/* ------------------------------------------------------------------ tarjetas y rejillas */
.card { background: var(--surface); border-radius: var(--radius-card); box-shadow: var(--shadow-card); padding: 24px; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.card.flush { padding: 0; gap: 0; }
.card.flush > .card-head { padding: 22px 24px 12px; }
.card.flush > .card-body { padding: 0 24px 24px; }
.card.flush > .card-foot { padding: 18px 24px 22px; border-top: 1px solid var(--divider); background: var(--surface-2); border-radius: 0 0 var(--radius-card) var(--radius-card); }
.card-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 16px; }
.card-head .meta, .meta { font-size: 13px; color: var(--text-4); }
.card.muted-bg { background: var(--cream-dark); box-shadow: none; }
.card.ink { background: var(--ink); color: var(--on-ink); box-shadow: none; }
.card.ink h2, .card.ink h3 { color: var(--on-ink); }
.card.ink .label { color: var(--accent-light); }
.card.ink p, .card.ink .meta { color: var(--on-ink-2); }
.label { font-size: 11px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--text-4); }
.split { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.split > .primary { flex: 2 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.split > .aside { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.grid { display: grid; gap: 16px; }
.grid.auto { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid.two { grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr)); gap: 20px; }
.empty { color: var(--text-4); font-size: 13px; }

/* ------------------------------------------------------------------ cifras */
.stat { display: flex; flex-direction: column; gap: 14px; padding: 22px 24px; background: var(--surface); border-radius: var(--radius-card); box-shadow: var(--shadow-card); color: var(--text); }
a.stat:hover { text-decoration: none; color: var(--text); box-shadow: var(--shadow-card), var(--shadow-hover); }
.stat .l { font-size: 13px; font-weight: 500; color: var(--text-3); }
.stat .n { font-family: var(--font-display); font-size: 52px; line-height: 1; }
.stat .go { font-size: 13px; font-weight: 600; color: var(--accent-text); }
.stat.ink { background: var(--ink); color: var(--on-ink); box-shadow: none; }
a.stat.ink:hover { color: var(--on-ink); box-shadow: var(--shadow-hover); }
.stat.ink .l { color: var(--on-ink-2); }
.stat.ink .go { color: var(--accent-light); }
.mini-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.mini-stats .n { font-family: var(--font-display); font-size: 32px; line-height: 1; display: block; }
.mini-stats .l { font-size: 12px; color: var(--text-3); }

/* ------------------------------------------------------------------ insignias */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--radius-pill); font-size: 12px; font-weight: 600; line-height: 1.4; white-space: nowrap; background: var(--cream-dark); color: var(--text-2); }
.b-high, .b-block, .b-rejected, .b-confirmed { background: var(--danger-tint); color: var(--danger-text); }
.b-medium, .b-review, .b-pending, .b-pending_approval, .b-draft, .b-open { background: var(--accent-tint); color: var(--accent-text); }
.b-low, .b-allow, .b-approved, .b-submitted, .b-false_positive, .b-active { background: var(--sage-tint); color: var(--sage-text); }
.b-closed, .b-retired, .b-in_case, .b-related { background: var(--cream-dark); color: var(--text-2); }
.tag-pep { display: inline-block; padding: 2px 6px; border-radius: 3px; font-size: 11px; font-weight: 700; letter-spacing: .08em; background: var(--ink); color: var(--on-ink); vertical-align: 1px; }
.risk { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.risk::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--border-2); }
.risk.r-high::before { background: var(--danger); }
.risk.r-medium::before { background: var(--accent); }
.risk.r-low::before { background: var(--sage); }
.risk strong { font-weight: 600; }
.risk span { color: var(--text-4); }
.dot { flex: 0 0 8px; width: 8px; height: 8px; margin-top: 6px; border-radius: 50%; background: var(--accent); }
.dot.d-high { background: var(--danger); }
.dot.d-ok { background: var(--sage); }
.ok { color: var(--sage-text); } .ko { color: var(--danger-text); } .muted { color: var(--text-4); }

/* ------------------------------------------------------------------ avisos */
.flash { display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-radius: var(--radius-nav); background: var(--sage-tint); color: var(--sage-text); font-weight: 500; }
.flash.err { background: var(--danger-tint); color: var(--danger-text); }
.notice { display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--radius-nav); background: var(--accent-tint); color: var(--accent-deep); font-size: 13px; line-height: 1.55; }
.notice svg { flex: 0 0 18px; margin-top: 1px; }
.notice.danger { background: var(--danger-tint); color: var(--danger-text); }
.notice.ok { background: var(--sage-tint); color: var(--sage-text); }
.notice.neutral { background: var(--cream-dark); color: var(--text-2); }

/* ------------------------------------------------------------------ tablas */
.table-wrap { overflow-x: auto; position: relative; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; padding: 10px 12px; font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--text-4); border-bottom: 1px solid var(--divider); white-space: nowrap; }
td { text-align: left; padding: 14px 12px; border-bottom: 1px solid var(--divider); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
th:first-child, td:first-child { padding-left: 24px; }
th:last-child, td:last-child { padding-right: 24px; }
.card:not(.flush) th:first-child, .card:not(.flush) td:first-child { padding-left: 0; }
.card:not(.flush) th:last-child, .card:not(.flush) td:last-child { padding-right: 0; }
td .sub { display: block; font-size: 12px; color: var(--text-4); margin-top: 3px; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
td.nowrap { white-space: nowrap; }
.strong-link { font-weight: 600; color: var(--text); }
.strong-link:hover { color: var(--accent-text); }
.prio { display: inline-flex; align-items: center; gap: 10px; white-space: nowrap; }
.prio b { width: 26px; }
.bar { display: block; width: 56px; height: 4px; border-radius: 2px; background: var(--cream-dark); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 2px; background: var(--accent); }
.bar.high > i { background: var(--danger); }
.bar.low > i { background: var(--sage); }
.bar.ink > i { background: var(--ink); }
.bar.wide { width: 100%; height: 8px; border-radius: 4px; }
.bar.wide > i { border-radius: 4px; }

/* ------------------------------------------------------------------ listas de datos */
.facts { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 18px 24px; }
.facts > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.facts dt { font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--text-4); }
.facts dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.checklist { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 0 24px; }
.checklist li { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--divider); }
.checklist li svg { flex: 0 0 18px; margin-top: 1px; }
.checklist li.missing span { font-weight: 600; }
.checklist small { display: block; font-size: 12px; color: var(--text-4); font-weight: 400; }
.attention { display: flex; flex-direction: column; gap: 16px; margin: 0; padding: 0; list-style: none; }
.attention a { display: flex; gap: 12px; color: var(--text); }
.attention a:hover { text-decoration: none; }
.attention a:hover strong { color: var(--accent-text); }
.attention strong { display: block; font-weight: 600; }
.attention span.sub { display: block; font-size: 13px; color: var(--text-4); }
.factors { display: flex; flex-direction: column; gap: 14px; }
.factor { display: grid; grid-template-columns: minmax(150px, 1.3fr) minmax(100px, 2fr) 56px; gap: 16px; align-items: center; }
.factor .v { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.factor small { display: block; font-size: 12px; color: var(--text-4); font-weight: 400; }
.notes { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 16px; }
.notes li { display: flex; gap: 14px; }
.avatar { flex: 0 0 36px; width: 36px; height: 36px; border-radius: 50%; background: var(--cream-dark); display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; color: var(--text-2); }
.notes .who-line { font-size: 13px; }
.notes p { line-height: 1.6; color: var(--text-2); margin-top: 4px; white-space: pre-wrap; }

/* ------------------------------------------------------------------ pasos */
.steps { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); background: var(--surface); border-radius: var(--radius-card); box-shadow: var(--shadow-card); overflow: hidden; }
.steps li { display: flex; gap: 12px; padding: 18px 20px; border-right: 1px solid var(--divider); }
.steps li:last-child { border-right: 0; }
.steps li.current { background: var(--surface-2); }
.step-icon { flex: 0 0 26px; width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; border: 2px solid var(--border-2); color: var(--text-3); }
.steps li.done .step-icon { background: var(--sage); border-color: var(--sage); color: #fff; }
.steps li.current .step-icon { border-color: var(--accent); color: var(--accent-text); }
.steps li.blocked .step-icon { border-color: var(--danger); color: var(--danger-text); }
.steps li.active .step-icon { background: var(--ink); border-color: var(--ink); color: var(--on-ink); }
.steps strong { display: block; font-weight: 600; }
.steps small { display: block; font-size: 12px; color: var(--text-4); }
.steps li.current small { color: var(--accent-text); font-weight: 600; }
.steps li.blocked small { color: var(--danger-text); font-weight: 600; }
.steps .k { display: block; font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--text-4); }

/* ------------------------------------------------------------------ formularios */
form { margin: 0; }
form.inline { display: inline; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
label, .field > span { font-size: 13px; font-weight: 600; color: var(--text-2); }
.check { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; }
.check input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--ink); flex: 0 0 18px; }
input, select, textarea { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--border-2); border-radius: var(--radius-nav); font: inherit; font-size: 14px; color: var(--text); background: var(--surface); }
input[type="checkbox"], input[type="radio"] { width: auto; min-height: 0; padding: 0; }
textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: var(--text-5); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(154, 90, 46, .18); }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px 16px; align-items: end; }
.form-grid .wide { grid-column: 1 / -1; }
.form-stack { display: flex; flex-direction: column; gap: 14px; }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 14px; background: var(--surface); border-radius: var(--radius-card); box-shadow: var(--shadow-card); }
.toolbar .search { flex: 1 1 260px; display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 14px; border: 1px solid var(--border-2); border-radius: var(--radius-nav); background: var(--surface); }
.toolbar .search input { border: 0; min-height: 42px; padding: 0; box-shadow: none; }
.toolbar select { width: auto; min-width: 180px; }
.segmented { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px; background: var(--cream); border-radius: var(--radius-nav); }
.segmented a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; border-radius: 3px; font-size: 13px; font-weight: 500; color: var(--text-2); }
.segmented a:hover { text-decoration: none; color: var(--text); background: rgba(255, 255, 255, .6); }
.segmented a[aria-current="true"] { background: var(--surface); box-shadow: 0 1px 2px rgba(25, 19, 14, .08); font-weight: 600; color: var(--text); }

/* ------------------------------------------------------------------ botones */
button, .btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border: 1px solid var(--ink); border-radius: var(--radius-nav); background: var(--ink); color: #fff; font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; white-space: nowrap; }
button:hover, .btn:hover { background: var(--ink-2); color: #fff; text-decoration: none; }
button.secondary, .btn.secondary { background: var(--surface); color: var(--text); border-color: var(--border-2); }
button.secondary:hover, .btn.secondary:hover { background: var(--surface-2); border-color: var(--text-4); color: var(--text); }
button.danger, .btn.danger { background: var(--surface); color: var(--danger-text); border-color: var(--danger); }
button.danger:hover, .btn.danger:hover { background: var(--danger-tint); color: var(--danger-text); }
button.small, .btn.small { min-height: 34px; padding: 0 12px; font-size: 13px; }
button.block, .btn.block { width: 100%; }
button.light { background: var(--on-ink); color: var(--ink); border-color: var(--on-ink); font-weight: 700; }
button.light:hover { background: #fff; color: var(--ink); }
button.ghost-ink { background: transparent; color: var(--on-ink); border-color: var(--on-ink-3); }
button.ghost-ink:hover { background: var(--ink-2); color: var(--on-ink); }
.card.ink input, .card.ink textarea { background: var(--ink-2); border-color: var(--text-3); color: var(--on-ink); }
.card.ink label { color: var(--on-ink-2); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.actions > form { display: contents; }
.quote { padding-left: 14px; border-left: 2px solid var(--border-2); line-height: 1.6; color: var(--text-2); white-space: pre-wrap; }
.card.ink .quote { border-left-color: var(--text-3); color: var(--on-ink-2); }
.summary { font-family: var(--font-display); font-size: 20px; line-height: 1.5; white-space: pre-wrap; }
details > summary { cursor: pointer; font-weight: 600; color: var(--accent-text); list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details > summary::before { content: "+ "; }
details[open] > summary::before { content: "− "; }

/* ------------------------------------------------------------------ acceso */
.login-page { min-height: 100vh; display: flex; flex-wrap: wrap; background: var(--cream); }
.login-hero { flex: 1 1 520px; min-width: 0; background: var(--ink); color: var(--on-ink); padding: 44px 56px; display: flex; flex-direction: column; justify-content: space-between; gap: 56px; }
.login-hero .brand-mark, .login-hero .brand-mark:hover { color: var(--on-ink); }
.login-hero .brand-m { font-size: 44px; }
.login-hero .brand-words { border-left-color: var(--text-3); }
.login-hero .brand-name { font-size: 16px; }
.login-hero .brand-sub { color: var(--on-ink-2); }
.login-hero .pitch { display: flex; flex-direction: column; gap: 20px; max-width: 470px; }
.login-hero .pitch > p.eyebrow { color: var(--accent-light); font-size: 12px; line-height: 1.5; }
.login-hero h1 { color: var(--on-ink); font-size: 46px; line-height: 1.1; }
.login-hero .pitch > p { font-size: 15px; line-height: 1.65; color: var(--on-ink-2); }
.login-hero ul { margin: 12px 0 0; padding: 24px 0 0; list-style: none; border-top: 1px solid var(--ink-2); display: flex; flex-direction: column; gap: 14px; }
.login-hero li { display: flex; align-items: center; gap: 12px; }
.login-hero .foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--on-ink-3); }
.login-side { flex: 1.3 1 520px; min-width: 0; display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.login-box { width: 100%; max-width: 440px; display: flex; flex-direction: column; gap: 20px; }
.login-card { background: var(--surface); border-radius: var(--radius-card-lg); box-shadow: var(--shadow-rest), var(--shadow-card); padding: 40px; display: flex; flex-direction: column; gap: 8px; }
.login-card h2 { font-size: 30px; }
.login-card .lead { font-size: 13px; line-height: 1.6; }
.login-card form { margin-top: 20px; display: flex; flex-direction: column; gap: 8px; }
.login-card button { margin-top: 16px; min-height: 48px; width: 100%; }
.login-card .foot { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--divider); text-align: center; font-size: 13px; color: var(--text-4); }
.login-box > p { text-align: center; font-size: 12px; color: var(--text-4); }
@media (max-width: 860px) {
  .login-hero { padding: 28px 24px; gap: 32px; }
  .login-hero h1 { font-size: 34px; }
  .login-card { padding: 28px 22px; }
}

/* Servicios de inversión (MiFID): cuestionarios */
.quiz { display: flex; flex-direction: column; gap: 20px; }
.quiz fieldset { border: 1px solid var(--divider); border-radius: var(--radius-nav); padding: 16px 18px 18px; margin: 0; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.quiz legend { padding: 0 6px; font-weight: 700; font-size: 14px; color: var(--text); }
.quiz .q { display: flex; flex-direction: column; gap: 8px; }
.quiz .q > p { margin: 0; font-weight: 600; font-size: 14px; color: var(--text-2); }
.quiz .opts { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.quiz .opts .check { font-weight: 400; font-size: 14px; }
.crit { display: grid; grid-template-columns: 22px 1fr; gap: 4px 10px; align-items: start; padding: 10px 0; border-bottom: 1px solid var(--divider); }
.crit:last-child { border-bottom: 0; }
.crit small { display: block; color: var(--text-4); font-size: 12.5px; }
.handwritten { font-family: var(--font-display); font-size: 19px; line-height: 1.45; padding: 12px 16px; border: 1px dashed var(--border-2); border-radius: var(--radius-nav); background: var(--surface); }
