/* FCSD · sitio. Marca en docs/brand.md: carbón, hueso, dos grises y el ocre como único acento.
   Archivo en una sola familia: titulares 900 condensada, texto 400/600, cifras tabulares. */
@property --p { syntax: '<number>'; inherits: true; initial-value: 0; }

:root {
  --carbon: #141414; --hueso: #EDE9E1; --jaspe: #9A9A96; --humo: #5C5C58; --ocre: #8A6A1F;
  --bg: var(--hueso); --fg: var(--carbon); --muted: var(--humo);
  --line: rgba(20, 20, 20, .16); --card: rgba(20, 20, 20, .05); --track: rgba(20, 20, 20, .12);
  --g: 16px; --max: 1200px;
  --cond: 68%; --xcond: 62%;
  --sans: Archivo, "Helvetica Neue", Arial, system-ui, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1C1C1B; --fg: var(--hueso); --muted: var(--jaspe);
    --line: rgba(237, 233, 225, .14); --card: rgba(237, 233, 225, .05); --track: rgba(237, 233, 225, .12);
    color-scheme: dark;
  }
}
/* Secciones oscuras: carbón con letras hueso, en tema claro y oscuro. */
.ink {
  --bg: var(--carbon); --fg: var(--hueso); --muted: var(--jaspe);
  --line: rgba(237, 233, 225, .18); --card: rgba(237, 233, 225, .06); --track: rgba(237, 233, 225, .14);
  background: var(--bg); color: var(--fg);
}
@media (min-width: 860px) { :root { --g: 32px; } }

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  background: var(--bg); color: var(--fg);
  font-family: var(--sans); font-size: 17px; font-weight: 400; line-height: 1.55;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-underline-offset: .18em; }
:focus-visible { outline: 3px solid var(--fg); outline-offset: 3px; }
.nw { white-space: nowrap; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding-left: var(--g); padding-right: var(--g); }

/* Titulares: 900 condensada */
.cond, .h2, h1, .mark, .btn, .giant { font-weight: 900; font-stretch: var(--cond); }
.h2 { font-size: clamp(40px, 11vw, 88px); line-height: .92; letter-spacing: -.005em; text-wrap: balance; margin-top: 12px; }
.eyebrow { font-size: 13px; font-weight: 600; line-height: 1.3; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); text-wrap: balance; }
.body { margin-top: 16px; max-width: 34em; }
.fine { margin-top: 10px; font-size: 14px; color: var(--muted); }

/* Barra superior */
.nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 68px; padding-top: 10px; padding-bottom: 10px; }
.nav-r { display: flex; align-items: center; gap: 8px; }
.mark { font-size: 32px; line-height: 1; font-stretch: var(--xcond); letter-spacing: .01em; text-decoration: none; color: var(--fg); }
.lang {
  min-height: 44px; min-width: 44px; padding: 0 12px; border-radius: 999px;
  background: none; border: 1.5px solid var(--line); color: var(--fg);
  font: 600 13px/1 var(--sans); letter-spacing: .08em; cursor: pointer;
}

/* Botones: 900 condensada en mayúsculas (texto grande, así el ocre cumple contraste) */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 54px; padding: 0 26px; border: 0; border-radius: 999px;
  background: var(--fg); color: var(--bg);
  font-family: var(--sans); font-size: 20px; line-height: 1; letter-spacing: .03em; text-transform: uppercase;
  text-decoration: none; cursor: pointer; white-space: nowrap;
}
.btn-sm { min-height: 44px; padding: 0 16px; font-size: 16px; }
.btn-ocre { background: var(--ocre); color: var(--hueso); }
.btn:disabled { opacity: .6; cursor: progress; }
@media (hover: hover) { .btn:hover { opacity: .88; } }

/* Lista de espera */
.wl { display: flex; flex-wrap: wrap; gap: 8px; max-width: 540px; }
.wl input[type=email] {
  flex: 1 1 220px; min-width: 0; min-height: 54px; padding: 0 20px; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--card); color: var(--fg);
  font: 400 17px/1.2 var(--sans);
}
.wl input[type=email]::placeholder { color: var(--muted); opacity: 1; }
.wl input[type=email]:focus-visible { border-color: var(--fg); }
.wl .btn { flex: 1 0 auto; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.wl-msg { min-height: 24px; margin-top: 10px; font-size: 15px; font-weight: 600; }
.wl-msg.err { font-weight: 700; }

/* Hero: carbón, la pregunta del Score, el teléfono y el FCSD recortado abajo y a la derecha */
.hero { overflow: hidden; }
.hero-in { display: grid; gap: 48px; padding-top: 24px; padding-bottom: 48px; }
.hero-copy { container-type: inline-size; min-width: 0; }
/* Dos renglones fijos. "¿Qué tan FCSD" mide 5.56em: 16.8cqi lo deja en ~93 % del ancho de la columna. */
.hero h1 { margin-top: 16px; font-size: clamp(44px, 15.6vw, 112px); font-size: min(16.8cqi, 128px); line-height: .88; letter-spacing: -.01em; }
.hero h1 .ln { display: block; white-space: nowrap; }
.lead { margin-top: 20px; font-size: 19px; line-height: 1.45; max-width: 28em; text-wrap: pretty; }
.tag { margin-top: 14px; font-weight: 900; font-stretch: var(--cond); font-size: 24px; line-height: 1; color: var(--muted); }
.hero .wl { margin-top: 28px; }
#lista { scroll-margin-top: 24px; }

/* Wordmark gigante. Con line-height .8 la línea base queda .066em arriba del borde de la caja;
   el margen de -.25em esconde ~27 % de la altura de las mayúsculas (regla de marca: máximo 40 %).
   El ancho se calcula para que la D se corte un poco en el borde derecho. */
.giant {
  display: block; width: max-content; white-space: nowrap;
  font-size: min(calc((100vw - var(--g)) / 1.76), 48rem); line-height: .8;
  font-stretch: var(--xcond); letter-spacing: 0;
  margin-left: max(calc(var(--g) - .04em), calc(100% - 1.79em));
  margin-bottom: -.25em;
  color: var(--fg);
  -webkit-user-select: none; user-select: none;
}

/* Secciones */
.sec { padding-top: 64px; padding-bottom: 72px; }
.ink + .ink, .sec:not(.ink) + .sec:not(.ink) { border-top: 1px solid var(--line); }
h3 { text-wrap: balance; }
.h2-l { font-size: clamp(36px, 9.6vw, 76px); line-height: .94; }
.dim { color: var(--muted); }
#prob-t span { display: block; }

/* El problema: tres tarjetas */
.cards { list-style: none; display: grid; gap: 12px; margin-top: 36px; }
.card { padding: 22px 22px 24px; border-radius: 18px; background: var(--card); }
.card h3 { font-weight: 900; font-stretch: var(--cond); font-size: 28px; line-height: 1.02; }
.card p { margin-top: 10px; color: var(--muted); }

/* Cómo lo resuelve: resultado + una línea + prueba */
.flist { list-style: none; display: grid; column-gap: 40px; margin-top: 36px; }
.flist li { display: grid; grid-template-columns: 40px minmax(0, 1fr); grid-template-rows: auto auto 1fr; column-gap: 12px; padding: 20px 0 24px; border-top: 1px solid var(--line); }
.flist li > * { grid-column: 2; }
.flist .fn { grid-column: 1; grid-row: 1 / span 3; font-weight: 900; font-stretch: var(--xcond); font-size: 22px; line-height: 1.15; color: var(--muted); }
.flist h3 { font-weight: 900; font-stretch: var(--cond); font-size: 30px; line-height: 1; }
.flist p { margin-top: 8px; color: var(--muted); font-size: 16px; }
.chip { display: inline-block; justify-self: start; align-self: start; max-width: 100%; margin-top: 14px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--fg); font-size: 15px; font-weight: 600; line-height: 1.35; }

/* Cinco apps en una: lo que sobra tachado, FCSD a la derecha */
.swap { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 20px; max-width: 900px; margin-top: 36px; }
.swap-k { font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.swap-old ul { list-style: none; display: grid; gap: 10px; margin-top: 12px; }
.swap-old li { color: var(--muted); font-size: 17px; line-height: 1.3; text-decoration: line-through; text-decoration-thickness: 2px; text-decoration-color: var(--muted); }
.swap-new { align-self: stretch; display: flex; flex-direction: column; justify-content: center; padding-left: 20px; border-left: 1px solid var(--line); }
.swap-mark { margin-top: 6px; font-weight: 900; font-stretch: var(--xcond); font-size: clamp(60px, 18vw, 200px); line-height: .8; color: var(--fg); }

/* Teléfono hecho con CSS: así se ve la app sin capturas con datos reales.
   Va sobre el carbón del hero, así que la pantalla fija sus propios colores claros. */
.phone {
  justify-self: center; width: 300px; max-width: 100%;
  padding: 11px; border-radius: 46px; background: var(--carbon);
  box-shadow: 0 0 0 1px var(--line), 0 40px 80px -36px rgba(0, 0, 0, .9);
}
.screen {
  --bg: var(--hueso); --fg: var(--carbon); --muted: var(--humo);
  --card: rgba(20, 20, 20, .06); --track: rgba(20, 20, 20, .12);
  overflow: hidden; display: flex; flex-direction: column; gap: 9px; padding: 30px 14px 40px;
  border-radius: 36px; background: var(--bg); color: var(--fg); font-size: 12px; line-height: 1.3;
}
.p-top { display: flex; justify-content: space-between; align-items: baseline; padding: 0 2px; }
.p-top b { font-weight: 900; font-stretch: var(--xcond); font-size: 22px; line-height: 1; }
.p-top span, .p-k { color: var(--muted); font-weight: 600; }
.p-card { background: var(--card); border-radius: 16px; padding: 11px 12px; }
.p-score { display: flex; align-items: center; gap: 12px; }
.p-score b { display: block; font-weight: 900; font-stretch: var(--cond); font-size: 20px; line-height: 1; text-transform: uppercase; }
.p-score span { display: block; margin-top: 4px; font-weight: 600; }
.p-row { display: flex; align-items: baseline; gap: 4px; }
.p-row b { font-weight: 900; font-stretch: var(--cond); font-size: 26px; line-height: 1; }
.p-row span { color: var(--muted); font-weight: 600; }
.bar { height: 5px; margin-top: 8px; border-radius: 3px; background: var(--track); }
.bar i { display: block; height: 100%; border-radius: 3px; background: var(--fg); }
.p-mac { display: flex; justify-content: space-between; gap: 6px; margin-top: 8px; color: var(--muted); font-size: 11px; font-weight: 600; }
.p-food b, .p-gym b, .p-k { display: block; }
.p-food b { font-size: 13px; margin-top: 2px; }
.p-food span:last-child { color: var(--muted); }
.p-gym span:not(.p-k) { display: block; margin-top: 2px; color: var(--muted); }
.p-gym b { font-size: 14px; margin-top: 1px; }
.p-hab { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.p-hab b { font-weight: 900; font-stretch: var(--cond); font-size: 20px; line-height: 1; }
.p-duo { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.p-duo b { display: block; margin-top: 3px; font-weight: 900; font-stretch: var(--cond); font-size: 20px; line-height: 1; }

/* Anillo del FCSD Score: el ocre es el arco. */
.ring { --size: 230px; --w: calc(var(--size) * .085); position: relative; width: var(--size); height: var(--size); border-radius: 50%; display: grid; place-content: center; justify-items: center; text-align: center; flex: none; }
.ring::before {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(var(--ocre) calc(var(--p) * 1%), var(--track) 0);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - var(--w)), #000 calc(100% - var(--w) + 1px));
  mask: radial-gradient(farthest-side, transparent calc(100% - var(--w)), #000 calc(100% - var(--w) + 1px));
  animation: ring-fill 1.4s cubic-bezier(.2, .7, .2, 1) .2s both;
}
@keyframes ring-fill { from { --p: 0; } }
.ring-n { position: relative; font-weight: 900; font-stretch: var(--xcond); font-size: calc(var(--size) * .4); line-height: .9; }
.ring-l { position: relative; margin-top: calc(var(--size) * .03); font-size: calc(var(--size) * .062); font-weight: 600; letter-spacing: .16em; color: var(--muted); }
.ring-sm { --size: 66px; }
.ring-sm .ring-l { display: none; }

/* FCSD Score */
.score-in { display: grid; gap: 44px; }
.ring-fig { display: grid; justify-items: center; gap: 18px; }
.ring-fig figcaption { text-align: center; }
.ring-fig figcaption b { display: block; font-weight: 900; font-stretch: var(--cond); font-size: 34px; line-height: 1; text-transform: uppercase; }
.ring-fig figcaption span { display: block; margin-top: 6px; color: var(--muted); }
.lv-bar { position: relative; display: grid; grid-template-columns: 50fr 25fr 15fr 11fr; gap: 3px; height: 10px; margin-top: 32px; max-width: 520px; }
.lv-bar i { border-radius: 2px; }
.lv-mark { position: absolute; left: 92%; top: -7px; bottom: -7px; width: 3px; border-radius: 2px; background: var(--fg); transform: translateX(-50%); }
.lv-d { background: var(--humo); }
.lv-c { background: var(--jaspe); }
.lv-f { background: var(--ocre); }
.lv-p { background: var(--carbon); box-shadow: inset 0 0 0 2px var(--ocre); }
.lv-list { list-style: none; display: grid; gap: 10px; margin-top: 20px; }
.lv-list li { display: flex; align-items: center; gap: 12px; color: var(--muted); font-weight: 600; }
.lv-list li[aria-current] { color: var(--fg); }
.lv-list .sw { width: 14px; height: 14px; border-radius: 3px; flex: none; }
.lv-list .num { min-width: 4.4em; }
.share { margin-top: 24px; max-width: 34em; font-weight: 600; text-wrap: balance; }

/* Coaches */
.coach-in { display: grid; gap: 32px; align-items: center; }
.coach-in .wl { margin-top: 24px; }
.report {
  background: var(--carbon); color: var(--hueso); border: 1px solid var(--line); border-radius: 20px;
  padding: 22px; font: 400 15px/1.55 var(--sans); white-space: pre-wrap; overflow-wrap: anywhere;
}

/* Preguntas: <details> nativo, sin JS. El + gira a × al abrir. */
.faq-in { display: grid; gap: 28px; }
.faq-in .h2 { margin-top: 0; }
.faq { border-bottom: 1px solid var(--line); }
.faq details { border-top: 1px solid var(--line); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px; padding: 16px 0; list-style: none; cursor: pointer;
  font-weight: 900; font-stretch: var(--cond); font-size: 24px; line-height: 1.1;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 16px; height: 16px;
  background: linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
              linear-gradient(currentColor, currentColor) center / 2px 100% no-repeat;
  transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { max-width: 36em; padding-bottom: 22px; color: var(--muted); }
.faq details a { color: var(--fg); font-weight: 600; }

/* Cierre */
.close .big { font-size: clamp(48px, 15vw, 168px); line-height: .88; text-wrap: balance; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 28px; }
.store {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 2px;
  min-height: 58px; padding: 8px 22px; border-radius: 14px;
  background: var(--fg); color: var(--bg); text-decoration: none; line-height: 1.1;
}
.store-k { font-size: 12px; font-weight: 600; letter-spacing: .04em; }
.store-n { font-weight: 900; font-stretch: var(--cond); font-size: 26px; line-height: 1; }
.cta-row .fine { margin-top: 0; }

/* Pie */
.foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 20px; padding-top: 20px; padding-bottom: 32px; border-top: 1px solid var(--line); color: var(--muted); font-size: 15px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.foot a { display: inline-block; padding: 10px 0; text-decoration: none; }
.foot a:hover { text-decoration: underline; }

/* Páginas de texto: privacidad y soporte */
.doc { max-width: 760px; padding-top: 40px; padding-bottom: 72px; }
.doc h1 { margin: 10px 0 12px; font-size: clamp(44px, 12vw, 80px); line-height: .92; text-wrap: balance; }
.doc .upd { margin-bottom: 28px; color: var(--muted); font-size: 15px; }
.doc h2 { margin: 36px 0 10px; font-weight: 900; font-stretch: var(--cond); font-size: 28px; line-height: 1.05; }
.doc p + p { margin-top: 12px; }
.doc ul { display: grid; gap: 8px; margin: 10px 0; padding-left: 20px; }
.doc details { margin-top: 10px; padding: 16px 18px; border-radius: 14px; background: var(--card); }
.doc summary { font-weight: 600; cursor: pointer; }
.doc details p { margin-top: 8px; color: var(--muted); }
.doc .box { margin-top: 12px; padding: 18px; border-radius: 14px; background: var(--card); }

/* Invitación: fcsdapp.com/i/CODIGO */
.inv { overflow: hidden; }
.inv-main { display: grid; justify-items: start; gap: 20px; padding-top: 24px; padding-bottom: 48px; }
.inv h1 { font-size: clamp(48px, 14vw, 120px); line-height: .9; text-wrap: balance; }
.code-box { width: 100%; max-width: 640px; padding: 18px 20px 20px; border-top: 4px solid var(--ocre); border-radius: 0 0 16px 16px; background: var(--card); container-type: inline-size; }
.code {
  margin: 6px 0 18px; font-weight: 900; font-stretch: var(--xcond); line-height: 1; letter-spacing: .04em;
  font-size: 64px; font-size: min(calc(100cqw / (var(--len, 6) * .66)), 120px);
  overflow-wrap: anywhere; -webkit-user-select: all; user-select: all;
}
.copy-msg { min-height: 24px; margin-top: 10px; font-size: 15px; font-weight: 600; }
.inv-main .body { margin-top: 0; }
.inv-main .fine { margin-top: 0; }

@media (min-width: 640px) {
  .flist { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 860px) {
  .hero-in { padding-top: 48px; padding-bottom: 64px; }
  .lead { font-size: 21px; }
  .tag { font-size: 28px; }
  .sec { padding-top: 96px; padding-bottom: 104px; }
  .cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 48px; }
  .card { padding: 26px 26px 30px; }
  .card h3 { font-size: 32px; }
  .flist { margin-top: 48px; }
  .swap { column-gap: 48px; margin-top: 48px; }
  .swap-old li { font-size: 22px; }
  .swap-new { padding-left: 48px; }
  .score-in { grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 72px; }
  .ring { --size: 300px; }
  .ring-sm { --size: 66px; }
  .coach-in { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; }
  .faq-in { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: 64px; align-items: start; }
  .faq summary { font-size: 28px; }
  .inv-main { padding-top: 48px; padding-bottom: 64px; }
}
/* Escritorio: el teléfono junto al texto. */
@media (min-width: 1000px) {
  .hero-in { grid-template-columns: minmax(0, 1fr) 300px; align-items: center; column-gap: 64px; }
  .flist { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}
@media (prefers-reduced-motion: reduce) {
  .ring::before { animation: none; }
  *, *::before, *::after { transition: none !important; }
}
