/* =========================================================
   ALIVIA — Design system
   Tipografía: Fraunces (display, serif óptica) + Manrope (UI)
   Paleta: verde bosque profundo · papel cálido · lima eléctrica
   ========================================================= */

@font-face { font-family: "Fraunces"; src: url("../fonts/fraunces-var.woff2") format("woff2"); font-weight: 300 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url("../fonts/fraunces-var-italic.woff2") format("woff2"); font-weight: 300 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("../fonts/manrope-var.woff2") format("woff2"); font-weight: 200 800; font-style: normal; font-display: swap; }

:root {
  --ink: #0B2E23;
  --ink-2: #123D30;
  --ink-3: #1B5241;
  --paper: #F5F1E8;
  --paper-2: #ECE5D6;
  --card: #FFFDF8;
  --text: #13201A;
  --muted: #5E6C65;
  --line: rgba(19, 32, 26, .12);
  --line-strong: rgba(19, 32, 26, .22);
  --lime: #C8F45A;
  --lime-2: #B4E43F;
  --coral: #FF6B4A;
  --amber: #F5B83D;
  --sky: #4FB3E8;
  --violet: #8B7CF6;
  --rose: #EE5D8C;
  --ok: #1F9D61;
  --err: #D6402A;
  --on-ink: #F4F1E8;
  --on-ink-muted: #A7C1B5;

  --r-sm: 10px; --r: 18px; --r-lg: 28px;
  --shadow: 0 1px 2px rgba(11, 46, 35, .06), 0 8px 24px -8px rgba(11, 46, 35, .18);
  --shadow-lg: 0 2px 6px rgba(11, 46, 35, .08), 0 30px 60px -20px rgba(11, 46, 35, .35);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0D1814; --paper-2: #13211C; --card: #172620; --text: #ECE9E1; --muted: #9AAAA2;
    --line: rgba(236, 233, 225, .1); --line-strong: rgba(236, 233, 225, .2);
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px -8px rgba(0,0,0,.5);
    --shadow-lg: 0 30px 60px -20px rgba(0,0,0,.7);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--sans); font-size: 16px; line-height: 1.55; color: var(--text); background: var(--paper); -webkit-font-smoothing: antialiased; font-feature-settings: "ss01"; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--lime-2); outline-offset: 2px; border-radius: 6px; }
::selection { background: var(--lime); color: var(--ink); }
.sr, .hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--lime); color: var(--ink); padding: 8px 14px; border-radius: 8px; font-weight: 700; }
.skip:focus { left: 8px; }

.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; padding-block: 32px 64px; }
.ico { width: 1.15em; height: 1.15em; flex: none; }
.muted { color: var(--muted); }
.center { text-align: center; }
.tiny { font-size: .8rem; color: var(--muted); display: flex; gap: .4em; align-items: flex-start; margin: .75rem 0 0; }
.tiny .ico { margin-top: .15em; }
.mono, code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; }
code { background: var(--paper-2); padding: .1em .4em; border-radius: 6px; word-break: break-all; }

/* ---------- Tipografía ---------- */
.display { font-family: var(--serif); font-optical-sizing: auto; font-weight: 600; font-size: clamp(2.6rem, 7vw, 5.4rem); line-height: .98; letter-spacing: -.025em; margin: .2em 0 .3em; }
.display em, .h1 em { font-style: italic; font-weight: 400; color: var(--lime); }
.display--sm { font-size: clamp(2.1rem, 5vw, 3.6rem); }
.h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(1.8rem, 4vw, 2.7rem); line-height: 1.08; letter-spacing: -.02em; margin: .2em 0 .35em; }
.h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(1.5rem, 3vw, 2.25rem); line-height: 1.1; letter-spacing: -.015em; margin: 0 0 .6em; }
.h2 small { font-family: var(--sans); font-size: .5em; font-weight: 600; letter-spacing: 0; }
.h2--light { color: var(--on-ink); }
.h3 { font-family: var(--serif); font-weight: 600; font-size: 1.35rem; line-height: 1.2; margin: 0 0 .5em; }
.h4 { font-size: 1rem; font-weight: 700; margin: 0 0 .5em; display: flex; gap: .45em; align-items: center; }
.lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); line-height: 1.55; max-width: 58ch; color: var(--muted); }
.lead--light { color: var(--on-ink-muted); }
.eyebrow { display: inline-flex; align-items: center; gap: .6em; font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--lime); margin: 0; }
.eyebrow--dark { color: var(--ink-3); }
@media (prefers-color-scheme: dark) { .eyebrow--dark { color: var(--lime); } }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 0 rgba(200, 244, 90, .7); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(200, 244, 90, 0); } 100% { box-shadow: 0 0 0 0 rgba(200, 244, 90, 0); } }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .55em; padding: .8em 1.3em; border-radius: 999px; border: 1.5px solid transparent; font-weight: 700; font-size: .95rem; line-height: 1.1; letter-spacing: -.005em; transition: transform .2s var(--ease), background .2s, box-shadow .2s, border-color .2s; white-space: nowrap; background: none; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn--sm { padding: .55em 1em; font-size: .85rem; }
.btn--lg { padding: 1em 1.6em; font-size: 1.02rem; }
.btn--block { display: flex; width: 100%; margin-top: .6rem; }
.btn--lime { background: var(--lime); color: var(--ink); box-shadow: 0 6px 20px -8px rgba(160, 210, 40, .8); }
.btn--lime:hover { background: #D4FA6E; }
.btn--ink { background: var(--ink); color: var(--on-ink); }
.btn--line { border-color: rgba(244, 241, 232, .35); color: var(--on-ink); }
.btn--line:hover { border-color: var(--on-ink); }
.btn--line-ink { border-color: var(--line-strong); color: var(--text); }
.btn--line-ink:hover { border-color: var(--text); }
.btn--ghost { color: var(--on-ink); background: rgba(255, 255, 255, .08); }
.btn--danger { background: var(--err); color: #fff; }
.btn--text { color: var(--muted); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
@media (prefers-color-scheme: dark) { .btn--ink { background: var(--on-ink); color: var(--ink); } }
.iconbtn { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255,255,255,.08); color: var(--on-ink); transition: background .2s; }
.iconbtn:hover { background: rgba(255,255,255,.16); }
.iconbtn--sm { width: 30px; height: 30px; background: var(--paper-2); color: var(--text); vertical-align: middle; }
.link { display: inline-flex; align-items: center; gap: .4em; font-weight: 700; color: var(--ink-3); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; }
@media (prefers-color-scheme: dark) { .link { color: var(--lime); } }
.link--sm { font-size: .85rem; }

/* ---------- Topbar ---------- */
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(11, 46, 35, .92); backdrop-filter: saturate(140%) blur(14px); -webkit-backdrop-filter: saturate(140%) blur(14px); color: var(--on-ink); border-bottom: 1px solid rgba(255,255,255,.06); }
.topbar__in { display: flex; align-items: center; gap: 24px; height: 66px; }
.brand { display: inline-flex; align-items: center; gap: .5rem; }
.brand__mark { width: 30px; height: 30px; }
.brand__mark circle { fill: var(--lime); }
.brand__mark path { fill: none; stroke: var(--ink); stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.brand__word { font-family: var(--serif); font-size: 1.55rem; font-weight: 600; letter-spacing: -.03em; font-style: italic; }
.nav { display: flex; gap: 4px; margin-left: 12px; }
.nav a { padding: .5em .9em; border-radius: 999px; font-weight: 600; font-size: .92rem; color: var(--on-ink-muted); transition: color .2s, background .2s; }
.nav a:hover { color: var(--on-ink); background: rgba(255,255,255,.06); }
.topbar__end { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.topbar .link { color: var(--on-ink); text-decoration: none; padding: .4em .6em; }
.lang { display: inline-flex; background: rgba(255,255,255,.07); border-radius: 999px; padding: 3px; }
.lang a { font-size: .74rem; font-weight: 800; letter-spacing: .06em; padding: .38em .7em; border-radius: 999px; color: var(--on-ink-muted); }
.lang a.on { background: var(--on-ink); color: var(--ink); }
.mnav { display: none; position: relative; }
.mnav summary { list-style: none; }
.mnav summary::-webkit-details-marker { display: none; }
.mnav__panel { position: absolute; right: 0; top: calc(100% + 10px); width: min(300px, 86vw); background: var(--card); color: var(--text); border-radius: var(--r); box-shadow: var(--shadow-lg); padding: 10px; display: grid; gap: 2px; animation: pop .22s var(--ease); }
.mnav__panel a, .mnav__panel button { display: flex; align-items: center; gap: .7em; padding: .8em .9em; border-radius: 12px; font-weight: 600; border: 0; background: none; width: 100%; text-align: left; }
.mnav__panel a:hover, .mnav__panel button:hover { background: var(--paper-2); }
.mnav__panel .btn { justify-content: center; margin-top: 6px; }
@keyframes pop { from { opacity: 0; transform: translateY(-6px) scale(.98); } }
@media (max-width: 860px) { .nav, .hide-sm { display: none !important; } .mnav { display: block; } }

/* ---------- Toasts ---------- */
.toasts { position: fixed; z-index: 60; left: 50%; top: 78px; transform: translateX(-50%); width: min(520px, 100% - 24px); display: grid; gap: 8px; }
.toast { display: flex; gap: .7em; align-items: center; padding: .85em 1em; border-radius: 14px; background: var(--ink); color: var(--on-ink); box-shadow: var(--shadow-lg); font-weight: 600; font-size: .93rem; animation: toast .4s var(--ease); }
.toast--ok .ico:first-child { color: var(--lime); }
.toast--err { background: #3A1410; }
.toast--err .ico:first-child { color: var(--coral); }
.toast span { flex: 1; }
.toast__x { border: 0; background: none; color: var(--on-ink-muted); padding: 4px; }
.toast.out { opacity: 0; transform: translateY(-8px); transition: .3s; }
@keyframes toast { from { opacity: 0; transform: translateY(-14px); } }

/* ---------- Hero ---------- */
.hero { background: radial-gradient(1200px 600px at 85% -10%, #1F5A47 0%, transparent 60%), radial-gradient(800px 500px at -10% 110%, #164536 0%, transparent 60%), var(--ink); color: var(--on-ink); overflow: hidden; }
.hero__in { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; padding-block: clamp(48px, 8vw, 110px); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 36px; }
.kpis { display: flex; gap: clamp(20px, 4vw, 48px); margin: 0; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.1); }
.kpis dt { font-size: .74rem; letter-spacing: .12em; text-transform: uppercase; color: var(--on-ink-muted); font-weight: 700; }
.kpis dd { margin: .15em 0 0; font-family: var(--serif); font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 600; letter-spacing: -.02em; }
.hero__stack { position: relative; height: 470px; perspective: 1200px; }
.hero__card { position: absolute; inset: 0; margin: auto; width: min(360px, 100%); height: max-content; transition: transform .6s var(--ease); }
.hero__card--0 { z-index: 3; transform: rotate(-3deg); }
.hero__card--1 { z-index: 2; transform: translate(34px, -18px) rotate(5deg) scale(.95); opacity: .85; }
.hero__card--2 { z-index: 1; transform: translate(-30px, 20px) rotate(-9deg) scale(.9); opacity: .6; }
.hero__stack:hover .hero__card--0 { transform: rotate(0) translateY(-6px); }
.hero__card .dcard { box-shadow: 0 40px 80px -30px rgba(0,0,0,.6); }
.hero__demo { background: var(--card); color: var(--text); border-radius: var(--r-lg); padding: 26px; }
.swipehint { display: flex; justify-content: center; gap: 22px; margin-top: 18px; }
.swipehint span { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 50%; border: 1.5px solid var(--line-strong); }
.swipehint .yes { background: var(--lime); color: var(--ink); border: 0; }
@media (max-width: 900px) { .hero__in { grid-template-columns: 1fr; } .hero__stack { height: 400px; } }
@media (max-width: 520px) { .hero__stack { display: none; } .kpis { gap: 18px; } .hero__cta .btn { flex: 1; } }

/* ---------- Bandas ---------- */
.band { padding-block: clamp(56px, 9vw, 112px); }
.band--paper { background: var(--paper); }
.band--ink { background: var(--ink); color: var(--on-ink); }
.band--lime { background: var(--lime); color: var(--ink); }
.band--lime .eyebrow--dark { color: var(--ink); }
.sechead { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }

.steps { list-style: none; padding: 0; margin: 32px 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; counter-reset: s; }
.steps li { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 26px 22px; position: relative; }
.steps__n { font-family: var(--serif); font-style: italic; font-size: 2.4rem; line-height: 1; color: var(--ink-3); opacity: .35; }
.steps h3 { font-size: 1.1rem; margin: .7em 0 .35em; }
.steps p { margin: 0; color: var(--muted); font-size: .95rem; }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }
.safe { display: flex; gap: 16px; align-items: flex-start; padding: 22px 24px; border-radius: var(--r); background: var(--ink); color: var(--on-ink); }
.safe .ico { width: 30px; height: 30px; color: var(--lime); }
.safe p { margin: 0; color: var(--on-ink-muted); }
.safe strong { color: var(--on-ink); }

/* ---------- Escalera de rangos ---------- */
.ladder { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 40px 0; }
.ladder__step { border-radius: var(--r); padding: 20px 16px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); position: relative; }
.ladder__step:nth-child(2) { transform: translateY(-10px); } .ladder__step:nth-child(3) { transform: translateY(-20px); }
.ladder__step:nth-child(4) { transform: translateY(-30px); } .ladder__step:nth-child(5) { transform: translateY(-40px); }
.ladder__ico { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; background: var(--tier); color: var(--ink); margin-bottom: 14px; }
.ladder__name { font-family: var(--serif); font-size: 1.25rem; font-weight: 600; }
.ladder__pts { font-size: .8rem; color: var(--on-ink-muted); font-weight: 600; }
@media (max-width: 760px) { .ladder { grid-template-columns: 1fr 1fr; } .ladder__step { transform: none !important; } }
.tier-seed { --tier: #9CC9B4; } .tier-spark { --tier: var(--amber); } .tier-beacon { --tier: var(--lime); }
.tier-guardian { --tier: var(--sky); } .tier-legend { --tier: linear-gradient(135deg, #FFE27A, #F5B83D 40%, #FF8A5B); }

.recgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.rec { padding: 24px; border-radius: var(--r); border: 1px solid rgba(255,255,255,.1); transition: background .3s, border-color .3s; }
.rec:hover { background: rgba(200, 244, 90, .06); border-color: rgba(200, 244, 90, .3); }
.rec > .ico { width: 28px; height: 28px; color: var(--lime); }
.rec h3 { margin: .8em 0 .3em; font-size: 1.05rem; }
.rec p { margin: 0; color: var(--on-ink-muted); font-size: .93rem; }
@media (max-width: 900px) { .recgrid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .recgrid { grid-template-columns: 1fr; } }

/* ---------- Insignias ---------- */
.badgerow { display: flex; gap: 14px; overflow-x: auto; padding: 40px 2px 8px; scrollbar-width: none; }
.badgerow .badge { flex: 0 0 150px; }
.badgegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-bottom: 40px; }
.badge { text-align: center; padding: 20px 14px 18px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); color: var(--text); transition: transform .3s var(--ease); }
.band--ink .badge { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.1); color: var(--on-ink); }
.band--ink .badge__desc { color: var(--on-ink-muted); }
.badge:hover { transform: translateY(-4px) rotate(-1deg); }
.badge__medal { width: 64px; height: 64px; margin: 0 auto 12px; display: grid; place-items: center; color: var(--ink); background: var(--tone); clip-path: polygon(50% 0, 93% 25%, 93% 75%, 50% 100%, 7% 75%, 7% 25%); position: relative; }
.badge__medal .ico { width: 28px; height: 28px; }
.badge__name { font-weight: 800; font-size: .9rem; line-height: 1.2; }
.badge__desc { font-size: .76rem; color: var(--muted); margin-top: 4px; line-height: 1.35; }
.badge--locked { opacity: .55; }
.badge--locked .badge__medal { background: var(--paper-2); color: var(--muted); }
.tone-lime { --tone: var(--lime); } .tone-amber { --tone: var(--amber); } .tone-sky { --tone: var(--sky); }
.tone-coral { --tone: var(--coral); } .tone-rose { --tone: var(--rose); } .tone-violet { --tone: var(--violet); }

/* ---------- Podio / gratitud / CTA ---------- */
.podium { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1.15fr 1fr; gap: 14px; align-items: end; }
.podium__p { background: var(--card); border: 1px solid var(--line); border-radius: var(--r) var(--r) 8px 8px; padding: 28px 20px 22px; text-align: center; display: grid; gap: 4px; }
.podium__p a, .podium__p > span:not(.podium__rank) { font-family: var(--serif); font-size: 1.3rem; font-weight: 600; }
.podium__p small { color: var(--muted); font-weight: 600; }
.podium__rank { width: 44px; height: 44px; margin: 0 auto 8px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: var(--paper-2); }
.podium__p--1 { order: 2; padding-top: 44px; background: var(--ink); color: var(--on-ink); border-color: var(--ink); }
.podium__p--1 small { color: var(--on-ink-muted); }
.podium__p--1 .podium__rank { background: var(--lime); color: var(--ink); width: 56px; height: 56px; font-size: 1.3rem; }
.podium__p--2 { order: 1; } .podium__p--3 { order: 3; }
@media (max-width: 640px) { .podium { grid-template-columns: 1fr; } .podium__p { order: 0 !important; } }
.quotes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 20px; }
.quote { margin: 0; }
.quote blockquote { margin: 0; font-family: var(--serif); font-size: clamp(1.15rem, 2vw, 1.45rem); line-height: 1.35; font-style: italic; }
.quote figcaption { margin-top: 12px; font-weight: 700; font-size: .9rem; }
.quote--card { padding: 22px 24px; border-radius: var(--r); background: var(--paper-2); margin-top: 20px; }
@media (max-width: 800px) { .quotes { grid-template-columns: 1fr; } }
.cta2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.cta2__box { padding: clamp(28px, 4vw, 44px); border-radius: var(--r-lg); background: var(--lime); color: var(--ink); }
.cta2__box p { max-width: 46ch; margin: 0 0 22px; }
.cta2__box--alt { background: var(--card); color: var(--text); border: 1px solid var(--line); }
.cta2__ico { width: 34px; height: 34px; margin-bottom: 16px; }
.cta2__box .btn--ink { background: var(--ink); color: var(--on-ink); }
@media (max-width: 760px) { .cta2 { grid-template-columns: 1fr; } }

/* ---------- Chips / estado ---------- */
.chip { display: inline-flex; align-items: center; gap: .35em; padding: .32em .7em; border-radius: 999px; font-size: .74rem; font-weight: 800; letter-spacing: .02em; background: var(--paper-2); color: var(--text); }
.chip .ico { width: 1em; height: 1em; }
.chip--cat { background: color-mix(in srgb, var(--cat) 22%, transparent); color: color-mix(in srgb, var(--cat) 60%, var(--text)); }
.chip--urgent, .chip--urg3 { background: rgba(255, 107, 74, .16); color: #C2381B; }
.chip--urg2 { background: rgba(245, 184, 61, .2); color: #8A5A00; }
.chip--ok { background: rgba(31, 157, 97, .13); color: var(--ok); }
@media (prefers-color-scheme: dark) { .chip--urgent, .chip--urg3 { color: #FF9A80; } .chip--urg2 { color: #F5C66A; } .chip--ok { color: #5FD69B; } }
.cat-electricity { --cat: var(--amber); } .cat-water { --cat: var(--sky); } .cat-gas { --cat: var(--coral); }
.cat-internet { --cat: var(--violet); } .cat-rent { --cat: #FF7A59; } .cat-medical { --cat: var(--rose); }
.cat-education { --cat: var(--violet); } .cat-food { --cat: #E9A23B; } .cat-other { --cat: #8A9A92; }
.status { display: inline-flex; align-items: center; gap: .45em; font-size: .78rem; font-weight: 700; padding: .3em .7em; border-radius: 999px; background: var(--paper-2); white-space: nowrap; }
.status i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.status--published i { background: var(--sky); } .status--reserved i { background: var(--amber); }
.status--proof_uploaded i { background: var(--violet); } .status--paid i { background: var(--ok); }
.status--paid { background: rgba(31,157,97,.13); color: var(--ok); }
.status--rejected i { background: var(--err); } .status--pending i { background: var(--amber); animation: pulse 2s infinite; }
.pill { font-size: .72rem; font-weight: 800; padding: .3em .7em; border-radius: 999px; }
.pill--act { background: var(--coral); color: #fff; }

/* ---------- Tarjeta de deuda ---------- */
.dcard { position: relative; background: var(--card); color: var(--text); border-radius: var(--r-lg); padding: 24px; border: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 10px; transition: transform .3s var(--ease), box-shadow .3s; overflow: hidden; }
.dcard::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 5px; background: var(--cat); }
.dcard__top { display: flex; flex-wrap: wrap; gap: 6px; }
.dcard__amount { font-family: var(--serif); font-size: 2.4rem; font-weight: 600; letter-spacing: -.03em; line-height: 1; margin-top: 8px; }
.dcard__title { font-size: 1.08rem; line-height: 1.3; margin: 0; font-weight: 800; }
.dcard__story { margin: 0; color: var(--muted); font-size: .93rem; }
.dcard__meta { margin: 6px 0 0; padding-top: 12px; border-top: 1px dashed var(--line-strong); display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; font-size: .83rem; }
.dcard__meta div { display: flex; gap: .45em; align-items: center; min-width: 0; }
.dcard__meta dt { color: var(--muted); }
.dcard__meta dd { margin: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dcard__link { position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.grid .dcard:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.dcard__stamp { position: absolute; top: 34px; padding: .25em .6em; border: 4px solid; border-radius: 10px; font-weight: 900; font-size: 1.6rem; letter-spacing: .08em; opacity: 0; pointer-events: none; z-index: 3; }
.dcard__stamp--yes { left: 22px; color: var(--ok); transform: rotate(-14deg); }
.dcard__stamp--no { right: 22px; color: var(--err); transform: rotate(14deg); }
.dcard:not(.dcard--swipe) .dcard__stamp { display: none; }

/* ---------- Explorar ---------- */
.pagehead { padding-block: 40px 20px; }
.pagehead--ink { background: var(--ink); color: var(--on-ink); padding-block: 56px 44px; margin-bottom: 36px; }
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; margin-top: 18px; }
.seg { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--paper-2); gap: 2px; }
.seg a, .seg label span { display: inline-flex; align-items: center; gap: .45em; padding: .55em 1em; border-radius: 999px; font-weight: 700; font-size: .88rem; color: var(--muted); cursor: pointer; }
.seg a[aria-selected="true"], .seg input:checked + span { background: var(--card); color: var(--text); box-shadow: var(--shadow); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg--dark { background: rgba(255,255,255,.07); margin-top: 18px; }
.seg--dark a { color: var(--on-ink-muted); }
.seg--dark a[aria-selected="true"] { background: var(--lime); color: var(--ink); }
.seg--small { margin: 4px 0 6px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; }
select, input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), textarea { width: 100%; padding: .78em .95em; border-radius: 12px; border: 1.5px solid var(--line-strong); background: var(--card); transition: border-color .2s, box-shadow .2s; }
select { appearance: none; padding-right: 2.4em; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 18px) 55%, calc(100% - 13px) 55%; background-size: 5px 5px; background-repeat: no-repeat; }
.filters select { width: auto; border-radius: 999px; font-weight: 600; font-size: .9rem; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--ink-3); box-shadow: 0 0 0 4px rgba(200, 244, 90, .45); }
textarea { resize: vertical; min-height: 6em; }
.explore { padding-bottom: 80px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.empty { text-align: center; padding: 70px 20px; border: 1.5px dashed var(--line-strong); border-radius: var(--r-lg); }
.empty > .ico { width: 42px; height: 42px; margin: 0 auto 14px; color: var(--ink-3); }

.deck { display: grid; justify-items: center; gap: 22px; }
.deck__stack { position: relative; width: min(420px, 100%); height: 540px; }
.deck__stack .dcard, .deck__end { position: absolute; inset: 0; }
.dcard--swipe { cursor: grab; touch-action: pan-y; user-select: none; will-change: transform; padding: 28px; }
.dcard--swipe:active { cursor: grabbing; }
.dcard--swipe .dcard__amount { font-size: 3.2rem; }
.dcard--swipe .dcard__story { flex: 1; font-size: 1rem; }
.dcard--swipe .dcard__meta { grid-template-columns: 1fr; }
.dcard--swipe.is-behind { transform: scale(.95) translateY(14px); filter: brightness(.97); }
.dcard--swipe.is-hidden { visibility: hidden; }
.dcard--swipe.fly { transition: transform .45s var(--ease), opacity .45s; }
.deck__end { display: grid; place-content: center; justify-items: center; text-align: center; gap: 8px; border: 1.5px dashed var(--line-strong); border-radius: var(--r-lg); padding: 30px; }
.deck__end > .ico { width: 44px; height: 44px; color: var(--ok); }
.deck__ctrl { display: flex; gap: 18px; align-items: center; }
.round { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid var(--line-strong); background: var(--card); box-shadow: var(--shadow); transition: transform .2s var(--ease); }
.round:hover { transform: scale(1.08); }
.round .ico { width: 26px; height: 26px; }
.round--no { color: var(--err); }
.round--info { width: 48px; height: 48px; color: var(--muted); }
.round--info .ico { width: 20px; height: 20px; }
.round--yes { width: 76px; height: 76px; background: var(--lime); border: 0; color: var(--ink); }
.round--yes .ico { width: 32px; height: 32px; }
.deck__hint { font-size: .85rem; margin: 0; text-align: center; }
@media (max-width: 520px) { .explore .deck { gap: 14px; } .deck__stack { height: clamp(360px, calc(100svh - 400px), 500px); } .toolbar { margin-top: 10px; gap: 8px; } .filters { flex-wrap: nowrap; width: 100%; } .filters select { flex: 1; min-width: 0; font-size: .85rem; } .dcard--swipe { padding: 22px; } .dcard--swipe .dcard__meta { grid-template-columns: 1fr 1fr; } .dcard--swipe .dcard__story { display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; } .pagehead { padding-block: 22px 12px; } .pagehead .h1 { font-size: 1.7rem; } .round { width: 56px; height: 56px; } .round--yes { width: 66px; height: 66px; } .dcard--swipe .dcard__amount { font-size: 2.6rem; } }

/* ---------- Detalle ---------- */
.detail { padding-block: 24px 80px; }
.back { display: inline-flex; gap: .45em; align-items: center; font-weight: 700; color: var(--muted); margin-bottom: 14px; font-size: .92rem; }
.back:hover { color: var(--text); }
.detail__grid { display: grid; grid-template-columns: 1fr 380px; gap: 32px; align-items: start; }
.detail__chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.detail__amount { font-family: var(--serif); font-size: clamp(2.8rem, 6vw, 4.2rem); font-weight: 600; letter-spacing: -.035em; line-height: 1; margin: 6px 0 22px; }
.detail__amount small { display: block; font-family: var(--sans); font-size: .9rem; font-weight: 600; color: var(--muted); letter-spacing: 0; margin-top: 6px; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; margin: 0 0 28px; }
.facts div { background: var(--card); padding: 14px 16px; }
.facts dt { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; }
.facts dd { margin: 4px 0 0; font-weight: 700; overflow-wrap: anywhere; }
.story { font-size: 1.08rem; line-height: 1.7; max-width: 68ch; }
.track { list-style: none; margin: 34px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); }
.track li { position: relative; padding-top: 22px; font-size: .8rem; font-weight: 700; color: var(--muted); }
.track li::before { content: ""; position: absolute; top: 6px; left: 0; right: 0; height: 3px; background: var(--line-strong); }
.track li span { position: absolute; top: 0; left: 0; width: 15px; height: 15px; border-radius: 50%; background: var(--paper); border: 3px solid var(--line-strong); z-index: 1; }
.track li.done::before, .track li.now::before { background: var(--ok); }
.track li.done span { background: var(--ok); border-color: var(--ok); }
.track li.now span { border-color: var(--ok); box-shadow: 0 0 0 5px rgba(31,157,97,.18); }
.track li.now { color: var(--text); }
.freed { display: flex; gap: 18px; align-items: center; margin-top: 30px; padding: 22px; border-radius: var(--r); background: var(--ink); color: var(--on-ink); }
.freed__seal { width: 64px; height: 64px; border-radius: 50%; background: var(--lime); color: var(--ink); display: grid; place-items: center; flex: none; }
.freed__seal .ico { width: 30px; height: 30px; stroke-width: 2.6; }
.freed__k { margin: 0; font-size: .75rem; text-transform: uppercase; letter-spacing: .12em; color: var(--on-ink-muted); font-weight: 700; }
.freed__name { margin: 2px 0 4px; font-family: var(--serif); font-size: 1.6rem; font-weight: 600; }
.freed__ded { margin: 0 0 6px; color: var(--on-ink-muted); }
.freed .link { color: var(--lime); }
.detail__side { position: sticky; top: 86px; display: grid; gap: 14px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 24px; box-shadow: var(--shadow); }
.panel--soft { background: var(--paper-2); box-shadow: none; }
.pts { display: flex; gap: .5em; align-items: center; font-weight: 700; color: var(--ink-3); background: rgba(200,244,90,.35); padding: .6em .9em; border-radius: 12px; font-size: .9rem; }
@media (prefers-color-scheme: dark) { .pts { color: var(--lime); background: rgba(200,244,90,.1); } }
.countdown { display: flex; gap: .5em; align-items: center; font-weight: 700; color: #B4500F; background: rgba(245,184,61,.18); padding: .6em .9em; border-radius: 12px; font-size: .9rem; }
@media (prefers-color-scheme: dark) { .countdown { color: #F5C66A; } }
.payinfo { margin: 14px 0; display: grid; gap: 10px; }
.payinfo div { display: grid; gap: 2px; }
.payinfo dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; }
.payinfo dd { margin: 0; font-weight: 700; font-size: 1.05rem; display: flex; align-items: center; gap: 8px; }
.files { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.files a { display: flex; gap: .5em; align-items: center; font-weight: 700; padding: .55em .7em; border-radius: 10px; background: var(--card); }
.files small { margin-left: auto; color: var(--muted); font-weight: 600; }
@media (max-width: 900px) { .detail__grid { grid-template-columns: 1fr; } .detail__side { position: static; } .facts { grid-template-columns: 1fr 1fr; } }

/* ---------- Formularios ---------- */
.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field > span, .label { font-weight: 700; font-size: .9rem; }
.field small { color: var(--muted); font-size: .8rem; display: flex; gap: .4em; align-items: center; }
.field span small { font-weight: 500; }
.check { display: flex; gap: .7em; align-items: flex-start; font-size: .92rem; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--ink-3); margin-top: 1px; flex: none; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { .row2 { grid-template-columns: 1fr; } }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
legend { padding: 0; margin-bottom: 8px; }
.note { display: flex; gap: .55em; align-items: flex-start; padding: .85em 1em; border-radius: 12px; background: var(--paper-2); font-size: .88rem; margin: 10px 0; }
.note .ico { margin-top: .15em; color: var(--ink-3); }
.note ul { margin: 0; padding-left: 1.1em; }
.note--err { background: rgba(214,64,42,.1); color: var(--err); display: block; }
.note--warn { background: rgba(245,184,61,.18); }
.note--ok { background: rgba(31,157,97,.12); color: var(--ok); }
.drop { position: relative; display: grid; justify-items: center; gap: 4px; padding: 26px 16px; border: 2px dashed var(--line-strong); border-radius: var(--r); text-align: center; cursor: pointer; transition: border-color .2s, background .2s; font-weight: 700; }
.drop:hover, .drop.has-file { border-color: var(--ink-3); background: rgba(200,244,90,.12); }
.drop .ico { width: 28px; height: 28px; color: var(--ink-3); }
.drop small { color: var(--muted); font-weight: 500; }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(20px, 3vw, 30px); box-shadow: var(--shadow); }
.card--danger { border-color: rgba(214,64,42,.3); box-shadow: none; }
.cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; }
.cat input { position: absolute; opacity: 0; }
.cat span { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; padding: 14px; border-radius: 14px; border: 1.5px solid var(--line-strong); font-weight: 700; font-size: .9rem; cursor: pointer; transition: .2s; }
.cat span .ico { width: 22px; height: 22px; color: var(--cat); }
.cat input:checked + span { border-color: var(--cat); background: color-mix(in srgb, var(--cat) 14%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--cat) 25%, transparent); }
.cat input:focus-visible + span { outline: 3px solid var(--lime-2); }

/* ---------- Auth ---------- */
.auth { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; padding-block: 48px 80px; align-items: start; }
.auth--narrow { grid-template-columns: 1fr; max-width: 460px; }
.auth__aside { position: sticky; top: 110px; background: var(--ink); color: var(--on-ink); border-radius: var(--r-lg); padding: clamp(28px, 4vw, 48px); }
.auth__card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(22px, 3vw, 34px); box-shadow: var(--shadow); }
.ticks { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 12px; }
.ticks li { display: flex; gap: .7em; align-items: flex-start; color: var(--on-ink-muted); }
.ticks .ico { color: var(--lime); margin-top: .15em; }
.ticks--dark li { color: var(--text); }
.ticks--dark .ico { color: var(--ok); }
.roles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.roles legend { grid-column: 1 / -1; }
.role input { position: absolute; opacity: 0; }
.role span { display: grid; gap: 4px; padding: 16px; border-radius: 16px; border: 1.5px solid var(--line-strong); cursor: pointer; height: 100%; transition: .2s; }
.role span .ico { width: 24px; height: 24px; color: var(--ink-3); }
.role small { color: var(--muted); font-size: .8rem; line-height: 1.3; }
.role input:checked + span { border-color: var(--ink-3); background: rgba(200,244,90,.18); box-shadow: 0 0 0 3px rgba(200,244,90,.45); }
.role input:focus-visible + span { outline: 3px solid var(--lime-2); }
[data-only-donor][hidden] { display: none; }
@media (max-width: 860px) { .auth { grid-template-columns: 1fr; gap: 20px; padding-top: 24px; } .auth__aside { position: static; } }

/* ---------- Panel ---------- */
.dash { padding-block: 32px 80px; display: grid; gap: 40px; }
.dash__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.dash__head .h1 { margin-bottom: 0; }
.dash__actions { display: flex; gap: 10px; flex-wrap: wrap; }
.list { display: grid; gap: 8px; }
.row { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; transition: border-color .2s, transform .2s var(--ease); flex-wrap: wrap; }
.row:hover { border-color: var(--line-strong); transform: translateX(3px); }
.row__ico { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--cat) 20%, transparent); color: color-mix(in srgb, var(--cat) 70%, var(--text)); flex: none; }
.row__main { flex: 1; min-width: 180px; display: grid; }
.row__main small { color: var(--muted); }
.row__amt { font-family: var(--serif); font-weight: 600; font-size: 1.15rem; }
.row__go { color: var(--muted); }
.tiercard { display: grid; grid-template-columns: auto 1fr auto; gap: 26px; align-items: center; padding: clamp(22px, 3vw, 34px); border-radius: var(--r-lg); background: var(--ink); color: var(--on-ink); position: relative; overflow: hidden; }
.tiercard::after { content: ""; position: absolute; right: -80px; top: -80px; width: 260px; height: 260px; border-radius: 50%; background: var(--tier); opacity: .14; filter: blur(10px); }
.tiercard__ico { width: 84px; height: 84px; border-radius: 24px; display: grid; place-items: center; background: var(--tier); color: var(--ink); }
.tiercard__ico .ico { width: 40px; height: 40px; }
.tiercard__k { margin: 0; font-size: .75rem; text-transform: uppercase; letter-spacing: .14em; color: var(--on-ink-muted); font-weight: 700; }
.tiercard__name { font-family: var(--serif); font-size: clamp(2rem, 4vw, 2.8rem); margin: 0 0 12px; font-weight: 600; letter-spacing: -.02em; }
.meter { height: 10px; border-radius: 99px; background: rgba(255,255,255,.1); overflow: hidden; max-width: 440px; }
.meter span { display: block; height: 100%; width: 0; background: var(--lime); border-radius: inherit; transition: width 1.2s var(--ease); }
.tiercard__next { margin: 10px 0 0; font-size: .88rem; color: var(--on-ink-muted); }
.tiercard__stats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 28px; margin: 0; position: relative; z-index: 1; }
.tiercard__stats dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--on-ink-muted); font-weight: 700; }
.tiercard__stats dd { margin: 0; font-family: var(--serif); font-size: 1.6rem; font-weight: 600; }
@media (max-width: 860px) { .tiercard { grid-template-columns: auto 1fr; } .tiercard__stats { grid-column: 1 / -1; grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 520px) { .tiercard__stats { grid-template-columns: 1fr 1fr; } .tiercard__ico { width: 60px; height: 60px; } }
.split { display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }
.sealprev { border-radius: 18px; margin: 10px 0 14px; box-shadow: var(--shadow); }
.sharebar { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.settings__grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; align-items: start; }
@media (max-width: 860px) { .settings__grid { grid-template-columns: 1fr; } }
.kpirow { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; margin: 0; }
.kpirow div { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; }
.kpirow dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
.kpirow dd { margin: 4px 0 0; font-family: var(--serif); font-size: 1.7rem; font-weight: 600; }
.review { display: grid; gap: 8px; }
.review__head { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.review__head b { flex: 1; }
.review__acts { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.inline { display: flex; gap: 8px; align-items: center; flex: 1; min-width: 260px; }
.inline input { padding: .5em .8em !important; }
.tablewrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.table th, .table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.table th { font-size: .74rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

/* ---------- Ranking ---------- */
.board { padding-bottom: 80px; }
.lb { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 8px; }
.lb__row { display: grid; grid-template-columns: 44px 48px 1fr auto auto auto; gap: 16px; align-items: center; padding: 14px 20px; background: var(--card); border: 1px solid var(--line); border-radius: 18px; }
.lb__row--top { padding-block: 20px; }
.lb__row--1 { background: var(--ink); color: var(--on-ink); border-color: var(--ink); }
.lb__row--1 small { color: var(--on-ink-muted) !important; }
.lb__pos { font-family: var(--serif); font-size: 1.5rem; font-weight: 600; font-style: italic; text-align: center; }
.lb__row--1 .lb__pos { color: var(--lime); font-size: 2rem; }
.lb__av { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--tier); color: var(--ink); }
.lb__who { display: grid; min-width: 0; }
.lb__who a, .lb__who > span { font-weight: 800; font-size: 1.05rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb__who small, .lb__num small { color: var(--muted); font-size: .76rem; font-weight: 600; }
.lb__num { display: grid; text-align: right; }
.lb__num b { font-family: var(--serif); font-size: 1.2rem; font-weight: 600; }
@media (max-width: 640px) { .lb__row { grid-template-columns: 28px 40px 1fr auto; gap: 10px; padding: 12px 14px; } .lb__row .lb__num:nth-of-type(n+5) { display: none; } .lb__num:last-child { display: none; } .lb__av { width: 40px; height: 40px; } }

/* ---------- Perfil ---------- */
.profile { background: radial-gradient(700px 400px at 90% 0%, color-mix(in srgb, var(--lime) 18%, transparent), transparent 60%), var(--ink); color: var(--on-ink); padding-block: 56px; margin-bottom: 40px; }
.profile__in { display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: center; position: relative; }
.profile__av { width: 120px; height: 120px; border-radius: 34px; display: grid; place-items: center; background: var(--tier); color: var(--ink); }
.profile__av .ico { width: 54px; height: 54px; }
.profile__meta { display: flex; flex-wrap: wrap; gap: 16px; color: var(--on-ink-muted); font-size: .9rem; margin: 0; }
.profile__meta span, .profile__meta a { display: inline-flex; gap: .4em; align-items: center; }
.profile__meta a { color: var(--lime); }
.profile__stats { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: rgba(255,255,255,.1); border-radius: var(--r); overflow: hidden; margin: 10px 0 0; }
.profile__stats div { background: var(--ink-2); padding: 18px 20px; }
.profile__stats dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--on-ink-muted); font-weight: 700; }
.profile__stats dd { margin: 4px 0 0; font-family: var(--serif); font-size: 1.8rem; font-weight: 600; }
.profile__share { position: absolute; top: 0; right: 0; }
@media (max-width: 640px) { .profile__in { grid-template-columns: 1fr; } .profile__av { width: 84px; height: 84px; border-radius: 24px; } .profile__stats { grid-template-columns: 1fr 1fr; } .profile__share { position: static; justify-self: start; } }
.timeline { list-style: none; padding: 0; margin: 0 0 80px; display: grid; gap: 0; }
.timeline li { display: grid; grid-template-columns: 44px 1fr; gap: 16px; position: relative; padding-bottom: 22px; }
.timeline li::before { content: ""; position: absolute; left: 21px; top: 44px; bottom: 0; width: 2px; background: var(--line); }
.timeline li:last-child::before { display: none; }
.timeline__dot { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--cat) 22%, var(--card)); color: color-mix(in srgb, var(--cat) 70%, var(--text)); }
.timeline__body p { margin: 0 0 4px; }
.timeline__body small { display: block; color: var(--muted); font-weight: 600; }
.mini { margin: 8px 0; padding-left: 14px; border-left: 3px solid var(--lime); font-family: var(--serif); font-style: italic; font-size: 1.05rem; }

/* ---------- Certificado ---------- */
.certwrap { padding-block: 40px 80px; display: grid; justify-items: center; gap: 18px; }
.cert { width: min(820px, 100%); background: #FFFDF6; color: #13201A; border-radius: 10px; padding: 16px; box-shadow: var(--shadow-lg); }
.cert__border { border: 2px solid #0B2E23; outline: 1px solid #0B2E23; outline-offset: -8px; border-radius: 4px; padding: clamp(28px, 6vw, 64px) clamp(20px, 6vw, 70px); text-align: center; background: radial-gradient(circle at 50% 0%, rgba(200,244,90,.25), transparent 50%); }
.cert__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 36px; }
.brand--cert .brand__word { color: #0B2E23; font-size: 1.4rem; }
.cert__no { font-family: ui-monospace, monospace; font-size: .8rem; letter-spacing: .1em; }
.cert__k { text-transform: uppercase; letter-spacing: .24em; font-size: .78rem; font-weight: 800; color: #1B5241; margin: 0; }
.cert__name { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: clamp(2.4rem, 7vw, 4.4rem); line-height: 1.05; margin: .25em 0 .3em; letter-spacing: -.02em; }
.cert__txt { max-width: 52ch; margin: 0 auto; font-size: 1.08rem; line-height: 1.6; }
.cert__ded { font-family: var(--serif); font-size: 1.15rem; margin: 18px 0 0; }
.cert__foot { display: grid; grid-template-columns: 1fr auto 1fr; gap: 20px; align-items: center; margin: 40px 0 26px; }
.cert__foot div { display: grid; }
.cert__foot small { font-size: .7rem; text-transform: uppercase; letter-spacing: .14em; color: #5E6C65; font-weight: 700; }
.cert__foot b { font-family: var(--serif); font-size: 1.3rem; }
.cert__seal { width: 92px; height: 92px; border-radius: 50%; display: grid; place-items: center; background: #C8F45A; color: #0B2E23; box-shadow: 0 0 0 6px #FFFDF6, 0 0 0 8px #0B2E23; }
.cert__seal .ico { width: 44px; height: 44px; stroke-width: 2.4; }
.cert__fp { display: flex; justify-content: center; gap: .5em; align-items: center; flex-wrap: wrap; font-size: .78rem; color: #5E6C65; margin: 0; }
.cert__fp code { background: #F0EBDD; color: #13201A; letter-spacing: .06em; }

/* ---------- Varios ---------- */
.prose section { margin-bottom: 38px; scroll-margin-top: 90px; }
.errpage { padding-block: 100px; text-align: center; display: grid; justify-items: center; }
.errpage__code { font-family: var(--serif); font-style: italic; font-size: clamp(5rem, 16vw, 9rem); line-height: 1; margin: 0; color: var(--ink-3); opacity: .25; }
.settings { scroll-margin-top: 90px; }

.foot { background: var(--ink); color: var(--on-ink-muted); padding-block: 56px 28px; }
.foot__in { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.brand--foot { color: var(--on-ink); }
.foot__tag { max-width: 34ch; margin: 12px 0 0; }
.foot__cols { display: flex; gap: 56px; flex-wrap: wrap; }
.foot__cols h4 { color: var(--on-ink); font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; margin: 0 0 12px; }
.foot__cols a { display: block; padding: 4px 0; font-size: .92rem; }
.foot__cols a:hover { color: var(--lime); }
.foot__legal { margin-top: 40px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.08); font-size: .8rem; }

/* Animación de entrada */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

@media print {
  .topbar, .foot, .noprint, .toasts { display: none !important; }
  body { background: #fff; }
  .certwrap { padding: 0; }
  .cert { box-shadow: none; padding: 0; }
}

/* =========================================================
   v2 — verificación, voz, asistente, accesibilidad, reportes
   ========================================================= */
html.big { font-size: 112.5%; }
html.big body { font-size: 18px; }
html.hc { --muted: #2a332f; --line: rgba(0,0,0,.45); --line-strong: rgba(0,0,0,.7); --on-ink-muted: #E6F0EA; --paper: #FFFFFF; --card: #FFFFFF; --text: #000; }
html.hc .chip, html.hc .status { outline: 1.5px solid currentColor; }
html.hc a:not(.btn) { text-decoration: underline; }
@media (prefers-color-scheme: dark) { html.hc { --paper: #000; --card: #0a0a0a; --text: #fff; --muted: #e5e5e5; --line: rgba(255,255,255,.5); --line-strong: rgba(255,255,255,.8); } }

.view-loading { min-height: 50vh; display: grid; place-items: center; color: var(--muted); }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--ink-3); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.btn.is-busy { opacity: .7; pointer-events: none; }
.btn.is-busy::after { content: ""; width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
.field.has-err input, .field.has-err select, .field.has-err textarea { border-color: var(--err); box-shadow: 0 0 0 3px rgba(214,64,42,.15); }

/* Topbar extras */
.bell { position: relative; }
.bell__n { position: absolute; top: 2px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--coral); color: #fff; font-size: .68rem; font-weight: 800; display: grid; place-items: center; }

/* Banda "gratis" */
.free { display: flex; gap: 14px; align-items: flex-start; padding: 18px 22px; border-radius: var(--r); background: rgba(255,107,74,.1); border: 1.5px solid rgba(255,107,74,.35); margin-top: 14px; }
.free .ico { width: 26px; height: 26px; color: var(--coral); flex: none; }
.free p { margin: 0; }
.layers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 28px 0 0; padding: 0; list-style: none; }
.layers li { background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1); border-radius: var(--r); padding: 20px; }
.layers .ico { width: 26px; height: 26px; color: var(--lime); margin-bottom: 10px; }
.layers b { display: block; font-size: 1rem; }
.layers small { color: var(--on-ink-muted); }
@media (max-width: 860px) { .layers { grid-template-columns: 1fr 1fr; } }

/* Stepper de verificación */
.stepper { list-style: none; padding: 0; margin: 24px 0 28px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; counter-reset: st; }
.stepper li { display: flex; gap: 10px; align-items: center; padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); font-weight: 700; font-size: .86rem; }
.stepper li::before { counter-increment: st; content: counter(st); width: 28px; height: 28px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--paper-2); font-weight: 800; }
.stepper li.done::before { content: "✓"; background: var(--ok); color: #fff; }
.stepper li.now { border-color: var(--ink-3); box-shadow: 0 0 0 3px rgba(200,244,90,.45); }
.stepper li.now::before { background: var(--lime); color: var(--ink); }
@media (max-width: 760px) { .stepper { grid-template-columns: 1fr 1fr; } }
.vcard { display: grid; gap: 14px; }
.codebox { font-family: ui-monospace, monospace; font-size: clamp(1.4rem, 5vw, 2rem); font-weight: 800; letter-spacing: .12em; text-align: center; padding: 16px; border-radius: 14px; background: var(--ink); color: var(--lime); }
.wa-btn { background: #25D366; color: #06331b; }
.wa-btn:hover { background: #3be07a; }
.done-row { display: flex; gap: 12px; align-items: center; padding: 16px 18px; border-radius: 14px; background: rgba(31,157,97,.12); color: var(--ok); font-weight: 700; }
.done-row .ico { width: 24px; height: 24px; }

/* Botones de voz */
.listen { display: inline-flex; align-items: center; gap: .45em; padding: .45em .85em; border-radius: 999px; border: 1.5px solid var(--line-strong); background: var(--card); font-weight: 700; font-size: .82rem; color: var(--text); }
.listen[aria-pressed="true"] { background: var(--ink); color: var(--lime); border-color: var(--ink); }
.mic { display: inline-flex; align-items: center; gap: .4em; padding: .45em .85em; border-radius: 999px; border: 1.5px solid var(--line-strong); background: var(--card); font-weight: 700; font-size: .82rem; color: var(--text); }
.mic.rec { background: var(--coral); color: #fff; border-color: var(--coral); animation: pulse 1.4s infinite; }
.tools { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.field__head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }

/* Asistente */
.chatfab { position: fixed; right: 18px; bottom: 18px; z-index: 70; width: 60px; height: 60px; border-radius: 50%; border: 0; background: var(--lime); color: var(--ink); box-shadow: var(--shadow-lg); display: grid; place-items: center; }
.chatfab .ico { width: 28px; height: 28px; }
.chat { position: fixed; right: 18px; bottom: 90px; z-index: 71; width: min(380px, calc(100vw - 24px)); height: min(560px, calc(100svh - 120px)); background: var(--card); border-radius: 22px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); display: flex; flex-direction: column; overflow: hidden; animation: pop .25s var(--ease); }
.chat[hidden] { display: none; }
.chat__head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: var(--ink); color: var(--on-ink); }
.chat__head b { flex: 1; font-family: var(--serif); font-size: 1.1rem; }
.chat__log { flex: 1; overflow-y: auto; padding: 14px; display: grid; gap: 10px; align-content: start; }
.msg { max-width: 85%; padding: 10px 13px; border-radius: 16px; font-size: .93rem; line-height: 1.45; white-space: pre-wrap; }
.msg--bot { background: var(--paper-2); border-bottom-left-radius: 4px; }
.msg--me { background: var(--ink); color: var(--on-ink); justify-self: end; border-bottom-right-radius: 4px; }
.chat__quick { display: flex; gap: 6px; flex-wrap: wrap; padding: 0 14px 10px; }
.chat__quick button { border: 1.5px solid var(--line-strong); background: none; border-radius: 999px; padding: .35em .75em; font-size: .8rem; font-weight: 700; }
.chat__form { display: flex; gap: 6px; padding: 10px; border-top: 1px solid var(--line); align-items: center; }
.chat__form input { flex: 1; border-radius: 999px !important; }
.chat__opts { padding: 0 14px 10px; font-size: .8rem; }
@media (max-width: 520px) { .chat { right: 12px; bottom: 84px; } .chatfab { right: 12px; bottom: 12px; } }

/* Menú de accesibilidad */
.a11y { position: relative; }
.a11y summary { list-style: none; }
.a11y summary::-webkit-details-marker { display: none; }
.a11y__panel { position: absolute; right: 0; top: calc(100% + 10px); width: 240px; background: var(--card); color: var(--text); border-radius: var(--r); box-shadow: var(--shadow-lg); padding: 8px; display: grid; gap: 2px; z-index: 60; animation: pop .2s var(--ease); }
.a11y__panel button { display: flex; align-items: center; gap: .6em; padding: .7em .8em; border: 0; background: none; border-radius: 10px; font-weight: 600; text-align: left; }
.a11y__panel button:hover, .a11y__panel button[aria-pressed="true"] { background: var(--paper-2); }

/* Modal */
.modal { position: fixed; inset: 0; z-index: 90; background: rgba(5,20,15,.7); display: grid; place-items: center; padding: 16px; animation: pop .2s; }
.modal__box { background: var(--card); border-radius: var(--r-lg); max-width: min(900px, 100%); max-height: 92svh; overflow: auto; padding: 18px; position: relative; }
.modal__box img { max-height: 80svh; margin: auto; border-radius: 10px; }
.modal__x { position: sticky; top: 0; float: right; }

/* Admin */
.imgpair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.imgpair figure { margin: 0; background: var(--paper-2); border-radius: 12px; min-height: 160px; display: grid; place-items: center; overflow: hidden; }
.imgpair img { max-height: 320px; object-fit: contain; }
.imgpair figcaption { font-size: .75rem; font-weight: 700; padding: 6px; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 4px 14px; font-size: .9rem; margin: 6px 0; }
.kv dt { color: var(--muted); font-weight: 700; }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.flag-ok { color: var(--ok); font-weight: 800; } .flag-bad { color: var(--err); font-weight: 800; } .flag-na { color: var(--muted); font-weight: 700; }
.tools-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }

/* Notificaciones */
.notifs { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.notifs li a { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); }
.notifs li.unread a { border-color: var(--ink-3); background: rgba(200,244,90,.14); }
.notifs small { margin-left: auto; color: var(--muted); white-space: nowrap; }

/* Reporte de impacto */
.report { padding-block: 32px 80px; }
.report__sheet { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: clamp(22px, 4vw, 48px); box-shadow: var(--shadow); }
.report__head { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; align-items: flex-start; border-bottom: 2px solid var(--ink); padding-bottom: 20px; margin-bottom: 24px; }
.report__kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 0 0 28px; }
.report__kpis div { border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.report__kpis dt { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; }
.report__kpis dd { margin: 4px 0 0; font-family: var(--serif); font-size: 1.7rem; font-weight: 600; }
@media (max-width: 640px) { .report__kpis { grid-template-columns: 1fr 1fr; } }
.bars { display: grid; gap: 8px; margin: 10px 0 26px; }
.bar { display: grid; grid-template-columns: 130px 1fr 110px; gap: 10px; align-items: center; font-size: .88rem; }
.bar__track { height: 12px; border-radius: 6px; background: var(--paper-2); overflow: hidden; }
.bar__fill { height: 100%; width: 0; background: var(--ink-3); border-radius: 6px; transition: width .8s var(--ease); }
.bar b { text-align: right; font-weight: 700; }
.months { display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; align-items: end; height: 140px; margin: 10px 0 30px; }
.months div { display: grid; align-content: end; gap: 4px; height: 100%; text-align: center; font-size: .7rem; color: var(--muted); }
.months i { display: block; background: var(--lime-2); border-radius: 6px 6px 2px 2px; min-height: 2px; height: 0; transition: height .8s var(--ease); }
.report__two { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
@media (max-width: 760px) { .report__two { grid-template-columns: 1fr; } .bar { grid-template-columns: 90px 1fr 80px; } }
.linkedin { background: #0A66C2; color: #fff; }
@media print { .chatfab, .chat, .a11y { display: none !important; } .report__sheet { box-shadow: none; border: 0; padding: 0; } }
.lang button { font: inherit; font-size: .74rem; font-weight: 800; letter-spacing: .06em; padding: .38em .7em; border-radius: 999px; color: var(--on-ink-muted); border: 0; background: none; }
.lang button.on { background: var(--on-ink); color: var(--ink); }
.foot__h { color: var(--on-ink); font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; margin: 0 0 12px; font-family: var(--sans); }
.foot__tag .ico { display: inline; vertical-align: -2px; }
.files__btn { display: flex; gap: .5em; align-items: center; font-weight: 700; padding: .55em .7em; border-radius: 10px; background: var(--card); border: 0; width: 100%; text-align: left; }
.files__btn small { margin-left: auto; color: var(--muted); font-weight: 600; }
.ladder--light .ladder__step { background: var(--card); border-color: var(--line); }
.ladder--light .ladder__pts { color: var(--muted); }
.recgrid--light .rec { background: var(--card); border-color: var(--line); }
.recgrid--light .rec:hover { background: rgba(200,244,90,.14); border-color: var(--lime-2); }
.recgrid--light .rec p { color: var(--muted); }
.recgrid--light .rec > .ico { color: var(--ink-3); }
@media (prefers-color-scheme: dark) { .recgrid--light .rec > .ico { color: var(--lime); } }
.band--tight { padding-top: 0; }
.filters-sel, .report select { width: auto; border-radius: 999px; font-weight: 600; font-size: .9rem; }
.pagehead--ink .filters-sel { background-color: rgba(255,255,255,.08); color: var(--on-ink); border-color: rgba(255,255,255,.2); margin-top: 18px; }
.nav a[aria-current="page"] { color: var(--on-ink); background: rgba(255,255,255,.08); }
.row a.row__main { color: inherit; }
.report .sharebar { align-items: center; margin-bottom: 14px; }
.report .back { margin: 0 auto 0 0; }
.dash > section { scroll-margin-top: 90px; }
h1[tabindex="-1"]:focus, main:focus { outline: none; }
