/* =============================================================================
   NexlEdu por Imtery - Hoja de estilos de la página de presentación.

   Sistema de diseño (una sola regla por eje, aplicada en toda la página):

   - Color: el azul Imtery #1782f2 en los dos temas, tanto en --brand como en
     --accent. Es una decisión de marca tomada a sabiendas: sobre fondo claro
     ese azul da 3,68:1 como texto y 3,81:1 con texto blanco encima, por debajo
     del 4,5:1 que pide WCAG AA para texto normal. Cumple de sobra allí donde
     el umbral es 3:1 (iconos, trazos, aros de foco, el deslizador) y en modo
     oscuro, donde da 5,13:1. Para recuperar AA en modo claro sin tocar el
     azul, basta pasar --accent-ink a #041220, que sobre el relleno da 4,95:1.
     El segundo eje ya no es un color: --accent-2 es tinta neutra, #303030 en
     claro y #d5dae3 en oscuro, porque el gris oscuro desaparece sobre fondo
     oscuro (1,48:1). Marca una sola cosa, el eje del tiempo y lo que ya viene
     incluido, y al ser neutro deja el azul como el único color de la página.
   - Forma: la escala de Material Design 3, md-sys-shape. 4px campos de texto,
     8px fichas y marcas, 12px tarjetas, 16px paneles, 28px diálogos y hojas,
     y corner-full en los botones.
   - Superficies y estados: Material Design 3. Cada control lleva su capa de
     estado, al 8% con el cursor encima y al 12% al pulsar o enfocar, en vez de
     cambiar el color de fondo. La elevación usa los niveles y las sombras de
     md-sys-elevation, y la etiqueta de los botones usa label-large.
   - Tema: claro y oscuro completos. Ninguna sección invierte el tema.
   - Movimiento: solo transform y opacity, siempre bajo prefers-reduced-motion.
============================================================================= */

/* ---------------------------------------------------------------- tipografía
   Auto-hospedada: sin peticiones a terceros y sin bloqueo de renderizado. */

@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(fonts/plus-jakarta-sans-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'Plus Jakarta Sans';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(fonts/plus-jakarta-sans-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/ibm-plex-mono-400-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/ibm-plex-mono-500-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/ibm-plex-mono-400-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/ibm-plex-mono-500-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* -------------------------------------------------------------------- tokens */

:root {
  color-scheme: light dark;

  --font-sans: 'Plus Jakarta Sans', ui-sans-serif, system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'Cascadia Mono', monospace;

  /* Escala de esquinas. Sin píldoras. */
  --r-xs: 4px;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 28px;
  --r-btn: 9999px;

  /* Alias heredados, atados a la escala de MD3. */
  --r-1: var(--r-sm);
  --r-2: var(--r-md);
  --r-3: var(--r-xl);

  --maxw: 1200px;
  --gutter: clamp(1.125rem, 4vw, 2.5rem);
  --nav-h: 62px;
  --section-y: clamp(3.25rem, 5.5vw, 5rem);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  /* Tema claro */
  --bg: #fafbfc;
  --surface: #ffffff;
  --surface-2: #f1f3f7;
  --surface-3: #e5e9f0;
  --pista: #e2e7ee;
  --line: rgb(18 24 38 / 0.11);
  --line-2: rgb(18 24 38 / 0.2);
  --text: #14171f;
  --text-2: #4e5666;
  --text-3: #676f7e;
  --brand: #1782f2;
  --accent: #1782f2;
  --accent-ink: #ffffff;
  --accent-soft: #eff6fe;
  --accent-line: rgb(23 130 242 / 0.32);
  --accent-2: #303030;
  --accent-2-ink: #ffffff;
  --accent-2-fill: #303030;
  --accent-2-soft: #ebecee;
  --accent-2-line: rgb(48 48 48 / 0.22);
  --danger: #b4232a;
  --estado: 18 24 38;
  --art-op: 0.14;
  --sombra: 18 24 38;
  --elev-1: 0 1px 2px 0 rgb(var(--sombra) / 0.3), 0 1px 3px 1px rgb(var(--sombra) / 0.15);
  --elev-2: 0 1px 2px 0 rgb(var(--sombra) / 0.3), 0 2px 6px 2px rgb(var(--sombra) / 0.15);
  --elev-3: 0 1px 3px 0 rgb(var(--sombra) / 0.3), 0 4px 8px 3px rgb(var(--sombra) / 0.15);
  --shadow: 0 1px 2px rgb(18 24 38 / 0.04), 0 12px 32px -12px rgb(18 24 38 / 0.14);
  --block: #0b3a75;
  --block-text: #ffffff;
  --block-text-2: #c3d7f2;
  --block-line: rgb(255 255 255 / 0.18);
  --scrim: linear-gradient(to top, rgb(11 26 48 / 0.78), rgb(11 26 48 / 0) 58%);
}

:root[data-theme='dark'] {
  color-scheme: dark;
  --bg: #0a0c11;
  --surface: #11141b;
  --surface-2: #171b24;
  --surface-3: #1f2532;
  --pista: #2b3342;
  --line: rgb(255 255 255 / 0.1);
  --line-2: rgb(255 255 255 / 0.2);
  --text: #eef0f5;
  --text-2: #a6aebf;
  --text-3: #7e8798;
  --brand: #1782f2;
  --accent: #1782f2;
  --accent-ink: #041220;
  --accent-soft: #0a1929;
  --accent-line: rgb(23 130 242 / 0.4);
  --accent-2: #d5dae3;
  --accent-2-ink: #0a0c11;
  --accent-2-fill: #d5dae3;
  --accent-2-soft: #23262e;
  --accent-2-line: rgb(213 218 227 / 0.28);
  --danger: #ff9d9d;
  --estado: 235 240 250;
  --art-op: 0.2;
  --sombra: 0 0 0;
  --elev-1: 0 1px 2px 0 rgb(var(--sombra) / 0.3), 0 1px 3px 1px rgb(var(--sombra) / 0.15);
  --elev-2: 0 1px 2px 0 rgb(var(--sombra) / 0.3), 0 2px 6px 2px rgb(var(--sombra) / 0.15);
  --elev-3: 0 1px 3px 0 rgb(var(--sombra) / 0.3), 0 4px 8px 3px rgb(var(--sombra) / 0.15);
  --shadow: 0 1px 2px rgb(0 0 0 / 0.5), 0 14px 36px -14px rgb(0 0 0 / 0.7);
  --block: #0d2a4d;
  --block-text: #f2f6fc;
  --block-text-2: #a8c4e6;
  --block-line: rgb(255 255 255 / 0.14);
  --scrim: linear-gradient(to top, rgb(4 8 14 / 0.72), rgb(4 8 14 / 0) 58%);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    color-scheme: dark;
    --bg: #0a0c11;
    --surface: #11141b;
    --surface-2: #171b24;
    --surface-3: #1f2532;
    --pista: #2b3342;
    --line: rgb(255 255 255 / 0.1);
    --line-2: rgb(255 255 255 / 0.2);
    --text: #eef0f5;
    --text-2: #a6aebf;
    --text-3: #7e8798;
    --brand: #1782f2;
    --accent: #1782f2;
    --accent-ink: #041220;
    --accent-soft: #0a1929;
    --accent-line: rgb(23 130 242 / 0.4);
    --accent-2: #d5dae3;
    --accent-2-ink: #0a0c11;
    --accent-2-fill: #d5dae3;
    --accent-2-soft: #23262e;
    --accent-2-line: rgb(213 218 227 / 0.28);
    --danger: #ff9d9d;
    --estado: 235 240 250;
    --art-op: 0.2;
    --sombra: 0 0 0;
    --elev-1: 0 1px 2px 0 rgb(var(--sombra) / 0.3), 0 1px 3px 1px rgb(var(--sombra) / 0.15);
    --elev-2: 0 1px 2px 0 rgb(var(--sombra) / 0.3), 0 2px 6px 2px rgb(var(--sombra) / 0.15);
    --elev-3: 0 1px 3px 0 rgb(var(--sombra) / 0.3), 0 4px 8px 3px rgb(var(--sombra) / 0.15);
    --shadow: 0 1px 2px rgb(0 0 0 / 0.5), 0 14px 36px -14px rgb(0 0 0 / 0.7);
    --block: #0d2a4d;
    --block-text: #f2f6fc;
    --block-text-2: #a8c4e6;
    --block-line: rgb(255 255 255 / 0.14);
    --scrim: linear-gradient(to top, rgb(4 8 14 / 0.72), rgb(4 8 14 / 0) 58%);
  }
}

/* ---------------------------------------------------------------------- base */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
h4,
p,
ul,
ol,
figure,
fieldset {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 3px;
}

::selection {
  background: var(--accent);
  color: var(--accent-ink);
}

[hidden] {
  display: none !important;
}

.icon {
  width: 1em;
  height: 1em;
  fill: currentColor;
  flex: none;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: var(--r-1);
  font-weight: 600;
  transform: translateY(-160%);
}

.skip-link:focus-visible {
  transform: translateY(0);
}

/* ------------------------------------------------------------------ retícula */

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: var(--section-y);
}

.section--tint {
  background: var(--surface-2);
  border-block: 1px solid var(--line);
}

[id] {
  scroll-margin-top: calc(var(--nav-h) + 1.5rem);
}

/* La barra fija no debe tapar el elemento que acaba de recibir el foco. */
a,
button,
input,
[tabindex] {
  scroll-margin-top: calc(var(--nav-h) + 1rem);
  scroll-margin-bottom: 1rem;
}

/* ---------------------------------------------------------------- tipografía */

.display {
  font-size: clamp(2.05rem, 1.15rem + 3.55vw, 3.35rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.07;
}

.h2 {
  font-size: clamp(1.6rem, 1.05rem + 2.1vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
  max-width: 19ch;
}

.h3 {
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.012em;
  line-height: 1.35;
}

.lead {
  font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  color: var(--text-2);
  line-height: 1.6;
  max-width: 54ch;
}

.body {
  color: var(--text-2);
  max-width: 62ch;
}

.small {
  font-size: 0.875rem;
  color: var(--text-2);
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

.section__head {
  max-width: 44rem;
  margin-bottom: clamp(1.5rem, 2.5vw, 2.25rem);
}

.section__head .body {
  margin-top: 0.875rem;
}

/* ------------------------------------------------------------------- botones
   Material Design 3, con los valores de @material/web 2.3.0: contenedor de
   40px de alto, forma corner-full, etiqueta label-large (0,875rem, peso 500,
   tracking 0,00625rem), icono de 18px y capa de estado al 8% con el cursor
   encima y al 12% al pulsar o enfocar. El relleno horizontal es de 24px, y
   baja a 16px del lado donde hay icono. */

.btn {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 40px;
  padding: 0 24px;
  border: 0;
  border-radius: var(--r-btn);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.25rem;
  letter-spacing: 0.00625rem;
  white-space: nowrap;
  cursor: pointer;
  transition: box-shadow 0.2s var(--ease), border-color 0.2s var(--ease);
}

/* El icono va detrás de la etiqueta, así que el espacio que se acorta es el
   de la derecha. */
.btn:has(.icon) {
  padding-right: 16px;
}

.btn .icon {
  width: 18px;
  height: 18px;
  font-size: 18px;
  transition: transform 0.25s var(--ease);
}

.btn:hover .icon {
  transform: translateX(2px);
}

/* Capa de estado, atada al color del texto de cada variante. */
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: currentColor;
  opacity: 0;
  transition: opacity 0.15s var(--ease);
}

.btn:hover::after {
  opacity: 0.08;
}

.btn:focus-visible::after,
.btn:active::after {
  opacity: 0.12;
}

/* Relleno: la acción principal. Nivel 0 en reposo, nivel 1 al pasar. */
.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.btn--primary:hover {
  box-shadow: var(--elev-1);
}

/* Contorno: 1px de trazo, sin elevación en ningún estado. */
.btn--ghost {
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--line-2);
  color: var(--accent);
}

/* Relleno sólido al pasar: con solo la capa de estado al 8% el contorno
   apenas cambiaba, y sobre fondos claros u oscuros se leía distinto. */
.btn--ghost:hover {
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.btn--ghost:hover::after {
  opacity: 0;
}

/* Elevada: superficie propia y un nivel de sombra que sube al pasar. */
.btn--onblock {
  background: var(--block-text);
  color: var(--block);
  box-shadow: var(--elev-1);
}

.btn--onblock:hover {
  box-shadow: var(--elev-2);
}

.btn--sm {
  min-height: 32px;
  padding: 0 16px;
}

.btn--sm:has(.icon) {
  padding-right: 12px;
}

.btn--wide {
  width: 100%;
}

.btn:disabled {
  cursor: not-allowed;
  box-shadow: none;
  background: rgb(var(--estado) / 0.12);
  color: rgb(var(--estado) / 0.38);
}

.btn:disabled::after {
  opacity: 0;
}

/* --------------------------------------------------------------- superficies
   Las tres tarjetas de MD3: contorno para lo que se lee, elevada para lo que
   se manipula, rellena para lo que agrupa. Todas con corner-medium. */

.surface {
  border-radius: var(--r-md);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}

.surface--elevada {
  box-shadow: var(--elev-1);
}

.surface--elevada:hover {
  box-shadow: var(--elev-2);
}

.surface--rellena {
  background: var(--surface-2);
  box-shadow: none;
}

/* ----------------------------------------------------------------- navegación */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--nav-h);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease);
}

.nav[data-stuck='true'] {
  border-bottom-color: var(--line);
}

@supports not (backdrop-filter: blur(1px)) {
  .nav {
    background: var(--bg);
  }
}

.nav__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  height: 100%;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-size: 1.0625rem;
  margin-right: auto;
}

/* La marca Imtery tiene dos versiones fijas: una para fondo claro y otra para
   fondo oscuro. Se intercambian por tema en lugar de recolorear el SVG. */
.brandmark {
  display: inline-flex;
  flex: none;
}

.brandmark img {
  height: var(--brandmark-h, 22px);
  width: auto;
}

.brandmark [data-tema='dark'] {
  display: none;
}

:root[data-theme='dark'] .brandmark [data-tema='light'] {
  display: none;
}

:root[data-theme='dark'] .brandmark [data-tema='dark'] {
  display: block;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .brandmark [data-tema='light'] {
    display: none;
  }

  :root:not([data-theme='light']) .brandmark [data-tema='dark'] {
    display: block;
  }
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav__link {
  padding: 0.45rem 0.7rem;
  border-radius: var(--r-1);
  font-size: 0.875rem;
  font-weight: 550;
  color: var(--text-2);
  transition: color 0.2s var(--ease), background-color 0.2s var(--ease);
}

.nav__link:hover {
  color: var(--text);
  background: var(--surface-2);
}

.nav__tools {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Botón de icono de Material Design 3, variante con contorno: contenedor de
   40x40, forma corner-full, icono de 24px y capa de estado al 8% y al 12%.
   Al quedar activado se rellena con la superficie inversa, que es lo que MD3
   hace con el botón de icono conmutable. */
.icon-btn {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 40px;
  height: 40px;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: var(--r-btn);
  box-shadow: inset 0 0 0 1px var(--line-2);
  color: var(--text-2);
  cursor: pointer;
  transition: color 0.2s var(--ease), box-shadow 0.2s var(--ease),
    background-color 0.2s var(--ease);
}

.icon-btn .icon {
  width: 24px;
  height: 24px;
  font-size: 24px;
}

.icon-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: currentColor;
  opacity: 0;
  transition: opacity 0.15s var(--ease);
}

.icon-btn:hover {
  color: var(--text);
}

.icon-btn:hover::after {
  opacity: 0.08;
}

.icon-btn:focus-visible::after,
.icon-btn:active::after {
  opacity: 0.12;
}

/* Conmutado: superficie inversa, igual que el toggle de MD3. */
.icon-btn[aria-pressed='true'] {
  background: var(--accent-2-fill);
  box-shadow: none;
  color: var(--accent-2-ink);
}

.nav__burger {
  display: none;
}

@media (max-width: 62rem) {
  .nav__links {
    display: none;
  }

  .nav__burger {
    display: inline-flex;
  }

  .nav__cta {
    display: none;
  }

  .nav__cta {
    display: none;
  }
}

/* -------------------------------------------------------------------- cajón
   Menú lateral en móvil. El velo cierra al pulsar, Escape también, y el foco
   queda dentro mientras está abierto. */

.drawer {
  position: fixed;
  inset: 0;
  z-index: 60;
}

.drawer[hidden] {
  display: none;
}

.drawer__scrim {
  position: absolute;
  inset: 0;
  background: rgb(8 12 20 / 0.5);
  backdrop-filter: blur(2px);
}

/* Material Design 3 ancla el cajón de navegación al borde de arranque, que
   en español es el izquierdo, y redondea solo las esquinas interiores. */
.drawer__panel {
  position: absolute;
  inset-block: 0;
  left: 0;
  width: min(20rem, 86vw);
  border-radius: 0 var(--r-lg) var(--r-lg) 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.75rem;
  background: var(--surface);
  border-right: 1px solid var(--line);
  box-shadow: var(--elev-3);
  overflow-y: auto;
}

.drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.35rem 0.35rem 0.85rem 0.75rem;
  margin-bottom: 0.35rem;
  border-bottom: 1px solid var(--line);
}

.drawer__title {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--text-3);
}

.drawer__panel a:not(.btn) {
  display: flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.5rem 0.75rem;
  border-radius: var(--r-1);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-2);
}

.drawer__panel a:not(.btn):hover {
  background: var(--surface-2);
  color: var(--text);
}

.drawer__cta {
  margin-top: auto;
}

@media (prefers-reduced-motion: no-preference) {
  .drawer__scrim {
    animation: velo 0.25s var(--ease);
  }

  .drawer__panel {
    animation: cajon 0.3s var(--ease);
  }

  @keyframes velo {
    from {
      opacity: 0;
    }
  }

  @keyframes cajon {
    from {
      transform: translateX(-100%);
    }
  }
}

/* ------------------------------------------------------- iconos de marca
   Los iconos de viñeta y el distintivo de las hojas son gráficos, no texto:
   el umbral es 3:1, así que pueden llevar el azul de marca exacto en vez del
   tono profundo que necesita el texto pequeño. */

.stage__does .icon,
.mod__does .icon,
.role__does .icon,
.sheet__does .icon,
.sheet .mod__badge {
  color: var(--brand);
}

/* ------------------------------------------------------------------- fichas
   Etiqueta pequeña con relleno. El ámbar marca lo que ya viene incluido y los
   meses del año; el azul queda para lo interactivo. */

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  white-space: nowrap;
}

.chip--incluido {
  background: var(--accent-2-soft);
  color: var(--accent-2);
  border: 1px solid var(--accent-2-line);
}

/* La etapa abierta lleva el mes en relleno sólido y las demás en tinte: da
   color a la sección, que se leía gris entera, y marca cuál se está leyendo. */
.chip--mes {
  background: var(--accent-2-soft);
  color: var(--accent-2);
  border: 1px solid var(--accent-2-line);
  justify-content: center;
}

.stage__btn[aria-expanded='true'] .chip--mes {
  background: var(--accent-2-fill);
  border-color: var(--accent-2-fill);
  color: var(--accent-2-ink);
}

/* En pantallas anchas todas las fichas de mes miden igual, para que los
   títulos del acordeón arranquen alineados. En móvil no, porque ese ancho
   fijo empujaba el título a dos líneas. */
@media (min-width: 30rem) {
  .chip--mes {
    min-width: 6.5rem;
  }
}

/* ---------------------------------------------------------------------- héroe
   A la izquierda el mensaje y la cifra que responde; a la derecha el
   configurador con el número de alumnos y los módulos. */

/* Fondo del héroe: dos velos muy suaves, uno por acento, que dan profundidad
   sin dibujar nada. El azul se sitúa detrás del configurador para levantarlo
   del papel; el ámbar apenas tiñe la esquina inferior izquierda y ata el
   segundo color desde el arranque. Se apagan al imprimir. */
.hero {
  position: relative;
  isolation: isolate;
  /* La luz que sigue al puntero mide 36rem: sin recorte, al llevarla al borde
     derecho alargaba el documento y salía barra horizontal. */
  overflow: clip;
  padding-top: clamp(2rem, 4vw, 3rem);
  padding-bottom: clamp(2.5rem, 5vw, 4rem);
  border-bottom: 1px solid var(--line);
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(
      70% 80% at 82% 18%,
      color-mix(in srgb, var(--accent) 13%, transparent),
      transparent 62%
    ),
    radial-gradient(
      55% 60% at 4% 96%,
      color-mix(in srgb, var(--accent-2) 9%, transparent),
      transparent 60%
    );
  pointer-events: none;
}

/* Luz que sigue al puntero. Es un solo elemento movido con transform, así que
   no repinta el fondo; se apaga con movimiento reducido y en pantallas
   táctiles, donde no hay cursor al que seguir. */
.hero__luz {
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
  width: 36rem;
  height: 36rem;
  margin: -18rem 0 0 -18rem;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    color-mix(in srgb, var(--brand) 24%, transparent),
    transparent 68%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s var(--ease);
  will-change: transform;
}

.hero[data-luz='on'] .hero__luz {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce), (hover: none) {
  .hero__luz {
    display: none;
  }
}

@supports not (background: color-mix(in srgb, red, blue)) {
  .hero::before,
  .hero__luz {
    background: none;
  }
}

@media print {
  .hero::before {
    display: none;
  }
}

.hero__grid {
  display: grid;
  gap: clamp(1.75rem, 3.5vw, 3rem);
  align-items: center;
}

@media (min-width: 62rem) {
  .hero__grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.95fr);
  }
}

.hero__title {
  text-wrap: balance;
}

.hero__title em {
  font-style: normal;
  color: var(--brand);
}

.hero__lead {
  margin-top: 1rem;
  max-width: 42ch;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.hero__fine {
  margin-top: 1rem;
  font-size: 0.75rem;
  color: var(--text-3);
  max-width: 46ch;
  line-height: 1.5;
}

/* Lectura en vivo del configurador. */
.readout {
  margin-top: 1.5rem;
  padding: 1.1rem 1.25rem;
  border: 1px solid var(--accent-line);
  border-left: 3px solid var(--brand);
  background: linear-gradient(90deg, var(--accent-soft), transparent 80%);
  border-radius: var(--r-1);
}

.readout__label {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--text-3);
}

.readout__price {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0 0.45rem;
  margin-top: 0.35rem;
}

.readout__cur {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-2);
}

.readout__num {
  font-size: clamp(2.2rem, 1.7rem + 2vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.readout__per {
  font-size: 0.875rem;
  color: var(--text-2);
}

.readout__rows {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 1.75rem;
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--accent-line);
  font-size: 0.8125rem;
  color: var(--text-2);
}

.readout__rows > div {
  display: flex;
  gap: 0.4rem;
}

.readout__rows dd {
  margin: 0;
  font-family: var(--font-mono);
  font-weight: 500;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.readout__big {
  margin-top: 0.3rem;
  font-size: clamp(1.4rem, 1.2rem + 0.9vw, 1.8rem);
  font-weight: 790;
  letter-spacing: -0.03em;
}

.readout__note {
  margin-top: 0.4rem;
  font-size: 0.875rem;
  color: var(--text-2);
  max-width: 40ch;
}

/* ----------------------------------------------------------- configurador */

.probe {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-3);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.probe__head {
  padding: 1.15rem 1.25rem 1.25rem;
  border-bottom: 1px solid var(--line);
}

.probe__core {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  padding: 0.85rem 1.25rem;
  background: var(--accent-2-soft);
  border-bottom: 1px solid var(--line);
}

.probe__coreName {
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  flex: 1;
}

.probe__coreRate {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.probe__tiles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  padding: 0;
  margin: 0;
  border: 0;
  background: var(--line);
}

/* Tesela de módulo: icono, nombre, precio. Poco texto y mucho estado visible. */
/* La tesela entera es el control: no hay casilla que marcar, el bloque se
   tiñe al elegirlo. El input sigue existiendo debajo para el teclado y los
   lectores de pantalla. */
.tile {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-areas:
    'icono nombre'
    'icono nota'
    'tarifa tarifa';
  gap: 0.15rem 0.7rem;
  align-content: start;
  padding: 0.95rem 1rem;
  background: var(--surface);
  cursor: pointer;
  transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.tile:hover {
  background: var(--surface-2);
}

.tile input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
}

.tile__icon {
  grid-area: icono;
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: var(--r-1);
  background: var(--surface-2);
  color: var(--text-3);
  font-size: 1rem;
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease);
}

.tile__name {
  grid-area: nombre;
  font-size: 0.9375rem;
  font-weight: 650;
  letter-spacing: -0.012em;
}

.tile__note {
  grid-area: nota;
  font-size: 0.75rem;
  color: var(--text-3);
  line-height: 1.35;
}

.tile__rate {
  grid-area: tarifa;
  margin-top: 0.55rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-2);
  font-variant-numeric: tabular-nums;
}

/* Elegida: solo se tiñe el bloque y se enciende el icono. Sin aro y con el
   texto en su color de siempre, que con todo en acento saturaba la rejilla. */
.tile:has(input:checked) {
  background: var(--accent-soft);
}

.tile:has(input:checked) .tile__icon {
  background: var(--brand);
  color: #ffffff;
}

.tile:has(input:checked) .tile__rate {
  color: var(--accent);
}

.tile:has(input:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.probe__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 1.25rem;
  border-top: 1px solid var(--line);
  background: var(--surface-2);
}

.probe__count {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--text-3);
}

/* ------------------------------------------------------- franja de normativa */

.norms {
  padding-block: clamp(2rem, 3.5vw, 3rem);
  background: var(--surface-2);
  border-block: 1px solid var(--line);
}

.norms__intro {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-2);
  max-width: 34ch;
}

/* Ocho normas. En pantallas angostas la franja se desliza en horizontal en
   lugar de dejar celdas vacías; en anchas pasa a dos filas de cuatro. */
.norms__list {
  display: flex;
  gap: 1px;
  margin-top: 1.5rem;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--r-2);
  overflow-x: auto;
  scrollbar-width: none;
}

.norms__list::-webkit-scrollbar {
  display: none;
}

.norms__item {
  flex: 1 1 9rem;
  min-width: 9rem;
  background: var(--surface);
  padding: 0.95rem 1.1rem;
}

.norms__code {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.norms__what {
  display: block;
  font-size: 0.8125rem;
  color: var(--text-2);
  margin-top: 0.2rem;
}

@media (min-width: 62rem) {
  .norms__intro {
    max-width: 46ch;
  }

  /* Con ocho normas una sola fila ya no cabe sin deslizarse: en pantalla
     ancha van en dos filas de cuatro, sin celdas vacías. */
  .norms__list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    overflow: visible;
  }

  .norms__item {
    min-width: 0;
  }
}

/* --------------------------------------------------------------- año escolar
   Acordeón. Cada etapa muestra su mes y su título; la descripción se abre al
   pulsar, así las siete caben en una pantalla en vez de en tres. */

.year__grid {
  display: grid;
  gap: clamp(1.5rem, 3vw, 2.75rem);
}

@media (min-width: 58rem) {
  .year__grid {
    grid-template-columns: minmax(0, 19rem) minmax(0, 1fr);
    align-items: start;
  }

  .year__aside {
    position: sticky;
    top: calc(var(--nav-h) + 2rem);
  }
}

.year__aside .body {
  margin-top: 0.875rem;
}

.year__stages {
  border: 1px solid var(--line);
  border-radius: var(--r-2);
  overflow: hidden;
  background: var(--surface);
}

.stage + .stage {
  border-top: 1px solid var(--line);
}

.stage__head {
  margin: 0;
  font-size: inherit;
  font-weight: inherit;
}

.stage__btn {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  padding: 0.95rem 1.15rem;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.2s var(--ease);
}

.stage__btn:hover {
  background: var(--surface-2);
}

.stage__btn:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: -2px;
}

.stage__title {
  flex: 1;
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.stage__chevron {
  flex: none;
  font-size: 0.9rem;
  color: var(--text-3);
  transition: transform 0.25s var(--ease), color 0.25s var(--ease);
}

.stage__btn[aria-expanded='true'] {
  background: var(--surface-2);
  box-shadow: inset 3px 0 0 var(--accent-2-fill);
}

.stage__btn[aria-expanded='true'] .stage__chevron {
  transform: rotate(90deg);
  color: var(--brand);
}

.stage__panel {
  padding: 0 1.15rem 1.25rem;
  background: var(--surface-2);
  box-shadow: inset 3px 0 0 var(--accent-2-fill);
}

.stage__lead {
  color: var(--text-2);
  max-width: 56ch;
}

.stage__does {
  margin-top: 0.9rem;
  display: grid;
  gap: 0.5rem;
}

.stage__does li {
  display: flex;
  gap: 0.6rem;
  font-size: 0.9375rem;
  color: var(--text-2);
}

.stage__does .icon {
  margin-top: 0.34em;
  font-size: 0.8em;
  color: var(--accent);
}

.stage__tag {
  margin-top: 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--accent-2);
}

@media (prefers-reduced-motion: no-preference) {
  .stage__panel:not([hidden]) {
    animation: abrir 0.28s var(--ease);
  }

  @keyframes abrir {
    from {
      opacity: 0;
      transform: translateY(-4px);
    }
  }
}

/* -------------------------------------------------------------------- módulos
   El núcleo ocupa toda la fila y los cuatro opcionales van debajo. Cinco
   elementos, cinco celdas: la retícula no deja huecos. */

.mods {
  display: grid;
  gap: 1rem;
}

/* Cinco paquetes y la tarjeta de lo que viene: tres por fila, sin huecos. */
@media (min-width: 56rem) {
  .mods {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .mod--core {
    grid-column: 1 / -1;
  }
}

@media (min-width: 40rem) and (max-width: 55.999rem) {
  .mods {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.mod {
  /* La ilustración de fondo va en posición absoluta: sin esto se ancla al
     viewport, las cuatro se apilan en una esquina y desbordan la página. */
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-2);
  overflow: hidden;
}

/* Cada módulo opcional se distingue por su icono, no por una fotografía: a
   este ancho de tarjeta los recortes partían caras y pesaban más que el texto.
   Las fotografías viven donde sí funcionan: la sección por rol y el cierre. */
/* Solo sobrevive dentro de la hoja de detalle: en la tarjeta duplicaba la
   ilustración de fondo. */
.sheet .mod__badge {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--r-1);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 1.15rem;
}

.mod__body {
  position: relative;
  z-index: 1;
  padding: clamp(1.1rem, 2vw, 1.5rem);
  flex: 1;
}

/* Marca de agua de cada módulo: composición de trazo, no un icono ampliado.
   Va detrás del texto, recortada por la propia tarjeta. */
.mod__art {
  position: absolute;
  right: -1.75rem;
  bottom: 1.5rem;
  width: 11rem;
  height: 11rem;
  color: var(--brand);
  opacity: var(--art-op);
  pointer-events: none;
}

.mod__tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background: var(--accent-2-soft);
  border: 1px solid var(--accent-2-line);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--accent-2);
  margin-bottom: 0.7rem;
}

.mod__name {
  font-size: 1.0625rem;
  font-weight: 720;
  letter-spacing: -0.02em;
}

.mod--core .mod__name {
  font-size: clamp(1.25rem, 1.05rem + 0.8vw, 1.6rem);
  font-weight: 780;
  letter-spacing: -0.028em;
}

.mod__lead {
  margin-top: 0.5rem;
  color: var(--text-2);
  max-width: 58ch;
}

.mod__does--core {
  margin-top: 1.1rem;
}

@media (min-width: 46rem) {
  .mod__does--core {
    grid-template-columns: 1fr 1fr;
    column-gap: 2.25rem;
  }
}

/* Abre el detalle completo del paquete sin alargar la tarjeta. */
.mod__more {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1rem;
  padding: 0.35rem 0;
  border: 0;
  background: none;
  font-size: 0.8125rem;
  font-weight: 650;
  color: var(--accent);
  cursor: pointer;
}

.mod__more:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.mod__more .icon {
  font-size: 0.85em;
  transition: transform 0.2s var(--ease);
}

.mod__more:hover .icon {
  transform: translateX(2px);
}

.mods__resto {
  margin-top: 1.25rem;
  font-size: 0.8125rem;
  color: var(--text-3);
  max-width: 70ch;
}

.mod__does {
  display: grid;
  gap: 0.6rem;
  margin-top: 0.9rem;
  align-content: start;
}


.mod__does li {
  display: flex;
  gap: 0.6rem;
  font-size: 0.875rem;
  color: var(--text-2);
  line-height: 1.45;
}

.mod__does strong {
  color: var(--text);
  font-weight: 650;
}

.mod__does .icon {
  margin-top: 0.34em;
  font-size: 0.8em;
  color: var(--accent);
}

.mod__price {
  padding: 0.75rem clamp(1.1rem, 2vw, 1.5rem);
  border-top: 1px solid var(--line);
  font-size: 0.8125rem;
  color: var(--text-3);
}

.mod__price span {
  font-family: var(--font-mono);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text);
  margin-right: 0.35rem;
  font-variant-numeric: tabular-nums;
}

.mod--core {
  background: var(--accent-soft);
  border-color: var(--accent-line);
}

.mod--core .mod__price {
  border-top-color: var(--accent-line);
}

/* ----------------------------------------------------------------- por rol
   Índice y detalle: la lista de roles queda siempre visible a la izquierda. */

.roles {
  display: grid;
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

@media (min-width: 58rem) {
  .roles {
    grid-template-columns: minmax(0, 15rem) minmax(0, 1fr);
    align-items: start;
  }
}

.roles__list {
  display: flex;
  gap: 0.35rem;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 0.25rem;
}

.roles__list::-webkit-scrollbar {
  display: none;
}

@media (min-width: 58rem) {
  .roles__list {
    flex-direction: column;
    overflow: visible;
    position: sticky;
    top: calc(var(--nav-h) + 1.5rem);
  }
}

.roles__tab {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.7rem 0.85rem;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--r-1);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-2);
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.2s var(--ease), background-color 0.2s var(--ease),
    border-color 0.2s var(--ease);
}

.roles__tab .icon {
  font-size: 1.15em;
  color: var(--text-3);
  transition: color 0.2s var(--ease);
}

.roles__tab:hover {
  color: var(--text);
  background: var(--surface-2);
}

.roles__tab[aria-selected='true'] {
  color: var(--text);
  background: var(--surface);
  border-color: var(--line);
  box-shadow: var(--shadow);
}

.roles__tab[aria-selected='true'] .icon {
  color: var(--brand);
}

.role {
  display: grid;
  gap: clamp(1.25rem, 2.5vw, 2rem);
}

@media (min-width: 46rem) {
  .role {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.85fr);
    align-items: center;
  }
}

.role[hidden] {
  display: none;
}

.role h3 {
  font-size: clamp(1.3rem, 1.1rem + 0.9vw, 1.7rem);
  font-weight: 780;
  letter-spacing: -0.028em;
  line-height: 1.16;
}

.role > div > p {
  margin-top: 0.75rem;
  color: var(--text-2);
  max-width: 48ch;
}

.role__does {
  margin-top: 1.4rem;
  display: grid;
  gap: 0.75rem;
}

.role__does li {
  display: flex;
  gap: 0.65rem;
  font-size: 0.9375rem;
}

.role__does .icon {
  margin-top: 0.34em;
  font-size: 0.8em;
  color: var(--accent);
}

/* Remate de cada rol: una frase completa, con el verbo destacado. Ni caja con
   filo de color ni etiqueta suelta en una columna aparte, que quedaba al aire
   sin decir de qué era etiqueta. */
.role__drop {
  margin-top: 1.5rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line);
  font-size: 0.9375rem;
  color: var(--text-2);
  max-width: 52ch;
}

.role__drop b {
  font-weight: 700;
  color: var(--accent-2);
}

.role__media {
  margin: 0;
  border-radius: var(--r-2);
  overflow: hidden;
  border: 1px solid var(--line);
}

.role__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 3;
}

/* ------------------------------------------------- campo con deslizador */

.field__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.field__label {
  font-size: 0.9375rem;
  font-weight: 650;
}

/* El valor se lee como una ficha, no como texto suelto al lado. */
.field__value {
  display: inline-flex;
  align-items: baseline;
  gap: 0.3rem;
  padding: 0.25rem 0.6rem;
  border: 1px solid var(--accent-line);
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

/* El sufijo se distingue por tamaño, no por opacidad: al 75% se quedaba en
   3,24:1 sobre el fondo de la ficha y no llegaba a AA. */
.field__value::after {
  content: 'alumnos';
  font-size: 0.6875rem;
  letter-spacing: 0.02em;
}

/* ------------------------------------------------------------- deslizador
   Material Design 3, tamaño XS, que es el que trae por omisión: pista de 16px
   de alto con esquina de 8, y tirador de 4px de ancho por 44 de alto en forma
   de barra, no el círculo del Material anterior. Entre el tirador y cada
   tramo de pista queda un hueco de 6px, como en la especificación.
   --p lo actualiza main.js con el avance de 0 a 1. */

.slider {
  -webkit-appearance: none;
  appearance: none;
  display: block;
  width: 100%;
  height: 44px;
  margin: 0;
  background: transparent;
  cursor: pointer;
  /* Centro del tirador: recorre de 2px a (ancho - 2px). */
  --centro: calc(2px + (100% - 4px) * var(--p, 0));
}

.slider::-webkit-slider-runnable-track {
  height: 16px;
  border-radius: 8px;
  background: linear-gradient(
      90deg,
      var(--brand) 0 calc(var(--centro) - 6px),
      transparent calc(var(--centro) - 6px) calc(var(--centro) + 6px),
      var(--pista) calc(var(--centro) + 6px) 100%
    )
    no-repeat;
}

.slider::-moz-range-track {
  height: 16px;
  border-radius: 8px;
  background: linear-gradient(
      90deg,
      var(--brand) 0 calc(var(--centro) - 6px),
      transparent calc(var(--centro) - 6px) calc(var(--centro) + 6px),
      var(--pista) calc(var(--centro) + 6px) 100%
    )
    no-repeat;
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 4px;
  height: 44px;
  margin-top: -14px;
  border: 0;
  border-radius: var(--r-btn);
  background: var(--brand);
  cursor: grab;
  transition: width 0.28s cubic-bezier(0.2, 0, 0, 1),
    background-color 0.28s cubic-bezier(0.2, 0, 0, 1);
}

.slider::-moz-range-thumb {
  width: 4px;
  height: 44px;
  border: 0;
  border-radius: var(--r-btn);
  background: var(--brand);
  cursor: grab;
  transition: width 0.28s cubic-bezier(0.2, 0, 0, 1),
    background-color 0.28s cubic-bezier(0.2, 0, 0, 1);
}

/* Al agarrarlo el tirador adelgaza, que es el gesto de MD3. */
.slider:active::-webkit-slider-thumb {
  width: 2px;
  cursor: grabbing;
}

.slider:active::-moz-range-thumb {
  width: 2px;
  cursor: grabbing;
}

.slider:focus {
  outline: none;
}

.slider:focus-visible::-webkit-slider-thumb {
  outline: 3px solid var(--brand);
  outline-offset: 3px;
}

.slider:focus-visible::-moz-range-thumb {
  outline: 3px solid var(--brand);
  outline-offset: 3px;
}

/* Las marcas van donde cae su valor de verdad, no repartidas por igual:
   400 alumnos está al 27% del rango, no al 33%. */
.slider__ticks {
  position: relative;
  height: 1.5rem;
  margin-top: -0.15rem;
}

.slider__ticks span {
  position: absolute;
  top: 0;
  left: calc(2px + (100% - 4px) * var(--at));
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
}

/* -------------------------------------------------------------- formulario */

.form__grid {
  display: grid;
  gap: 0.95rem;
}

/* Las columnas se dimensionan solas. Con el estiramiento por omisión, un
   error en una columna estiraba el control de la otra y la fila se deformaba. */
@media (min-width: 30rem) {
  .form__grid--2 {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

.field {
  display: grid;
  gap: 0.35rem;
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
}

.field > label,
.field .field__label {
  font-size: 0.8125rem;
  font-weight: 650;
  padding: 0;
}

/* El deslizador queda fuera: también es un input dentro de .field y heredaba
   el marco, el relleno y el fondo del campo de texto. */
.field input:not([type='range']) {
  width: 100%;
  min-height: 40px;
  padding: 0.65rem 0.75rem;
  background: var(--bg);
  border: 1px solid var(--line-2);
  border-radius: var(--r-xs);
  font-size: 0.9375rem;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.field input::placeholder {
  color: var(--text-3);
}

.field input:not([type='range']):focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.field input[aria-invalid='true'] {
  border-color: var(--danger);
}

/* ---------------------------------------------------------------- opciones
   Pocas opciones y siempre a la vista: botones de radio en lugar de una lista
   desplegable. El control nativo sigue debajo, así que las flechas del teclado
   y los lectores de pantalla funcionan sin código propio. */

.picks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

/* Dos por fila: el panel del formulario es estrecho y con cuatro columnas
   cada etiqueta se partía en dos líneas. */
.picks--4 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
}

.pick {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--line-2);
  border-radius: var(--r-btn);
  background: transparent;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-2);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease),
    color 0.2s var(--ease);
}

.pick input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
}

.pick:hover {
  border-color: var(--accent);
  color: var(--text);
}

.pick:has(input:checked) {
  background: var(--accent-soft);
  border-color: var(--accent-soft);
  color: var(--accent);
}

.pick:has(input:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* El error no se distingue solo por color: lleva icono y texto. */
.field__error {
  display: flex;
  align-items: flex-start;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--danger);
  line-height: 1.4;
}

.field__error .icon {
  margin-top: 0.15em;
  font-size: 0.95em;
  flex: none;
}

.field__error:not([data-con-error]) {
  display: none;
}

/* ------------------------------------------------- bloque de cierre
   Único bloque de color de la página, en azul profundo de marca. */

.closer {
  position: relative;
  isolation: isolate;
  background: var(--block);
  color: var(--block-text);
  padding-block: var(--section-y);
  overflow: clip;
}

/* La fotografía del colegio cierra la página a sangre, como atmósfera y no
   como prueba: va detrás del azul de marca, no compite con el formulario. */
.closer__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.closer__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.closer::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    105deg,
    color-mix(in srgb, var(--block) 96%, transparent) 0%,
    color-mix(in srgb, var(--block) 88%, transparent) 52%,
    color-mix(in srgb, var(--block) 72%, transparent) 100%
  );
}

@supports not (background: color-mix(in srgb, red, blue)) {
  .closer::before {
    background: var(--block);
  }
}

.closer__grid {
  display: grid;
  gap: clamp(2rem, 4vw, 3.5rem);
  align-items: start;
}

@media (min-width: 58rem) {
  .closer__grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 26rem);
  }
}

.closer h2 {
  color: var(--block-text);
}

.closer__lead {
  margin-top: 1rem;
  color: var(--block-text-2);
  max-width: 44ch;
}

.closer__points {
  margin-top: 1.75rem;
  display: grid;
  gap: 0.7rem;
}

.closer__points li {
  display: flex;
  gap: 0.6rem;
  font-size: 0.9375rem;
  color: var(--block-text-2);
}

.closer__points .icon {
  margin-top: 0.34em;
  font-size: 0.8em;
  flex: none;
  color: var(--block-text);
}

.form {
  padding: clamp(1.25rem, 2.5vw, 1.75rem);
  background: var(--surface);
  border-radius: var(--r-xl);
  box-shadow: var(--elev-3);
  color: var(--text);
}

/* ---------------------------------------------------------------- asistente
   El formulario se recorre en tres pasos. Pedir todo de golpe intimida; así
   cada pantalla hace una sola pregunta y el avance se ve en la barra. */

.wiz__top {
  display: grid;
  gap: 0.5rem;
  margin-bottom: 1.1rem;
}

.wiz__count {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--text-3);
}

.wiz__bar {
  height: 4px;
  border-radius: 2px;
  background: var(--surface-3);
  overflow: hidden;
}

.wiz__bar span {
  display: block;
  height: 100%;
  border-radius: 2px;
  background: var(--brand);
  transform-origin: left;
  transform: scaleX(calc(var(--paso) / 3));
  transition: transform 0.35s var(--ease);
}

.wiz__ask {
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.9rem;
}

.wiz__step[hidden] {
  display: none;
}

@media (prefers-reduced-motion: no-preference) {
  .wiz__step:not([hidden]) {
    animation: pasoEntra 0.3s var(--ease);
  }

  @keyframes pasoEntra {
    from {
      opacity: 0;
      transform: translateX(8px);
    }
  }
}

.wiz__nav {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.1rem;
}

.wiz__nav .btn[hidden] {
  display: none;
}

/* ------------------------------------------------------------------ hoja
   Diálogo nativo con el detalle completo de un paquete: el navegador ya
   encierra el foco y atiende Escape, así que no hace falta código propio. */

.sheet {
  width: min(34rem, calc(100vw - 2rem));
  max-height: min(80vh, 42rem);
  padding: clamp(1.25rem, 3vw, 1.75rem);
  border: 1px solid var(--line);
  border-radius: var(--r-3);
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 24px 64px -24px rgb(8 12 20 / 0.45);
}

.sheet::backdrop {
  background: rgb(8 12 20 / 0.5);
  backdrop-filter: blur(2px);
}

.sheet__head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}

.sheet__head .mod__badge {
  margin-bottom: 0;
}

.sheet__title {
  flex: 1;
  font-size: 1.1875rem;
  font-weight: 760;
  letter-spacing: -0.025em;
}

.sheet__does {
  display: grid;
  gap: 0.6rem;
}

.sheet__does li {
  display: flex;
  gap: 0.6rem;
  font-size: 0.9375rem;
  color: var(--text-2);
}

.sheet__does .icon {
  margin-top: 0.34em;
  font-size: 0.8em;
  color: var(--accent);
  flex: none;
}

.sheet__foot {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  font-size: 0.8125rem;
  color: var(--text-3);
}

.sheet__foot span {
  font-family: var(--font-mono);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text);
  margin-right: 0.35rem;
  font-variant-numeric: tabular-nums;
}

@media (prefers-reduced-motion: no-preference) {
  .sheet[open] {
    animation: hojaEntra 0.24s var(--ease);
  }

  @keyframes hojaEntra {
    from {
      opacity: 0;
      transform: translateY(10px) scale(0.98);
    }
  }
}

.form__legal {
  margin-top: 0.9rem;
  font-size: 0.75rem;
  color: var(--text-3);
  line-height: 1.5;
}

.form__status {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  background: var(--accent-soft);
  border: 1px solid var(--accent-line);
  border-radius: var(--r-1);
  font-size: 0.875rem;
}

.form__status .icon {
  margin-top: 0.2em;
  color: var(--accent);
  font-size: 1.05em;
}

.form__status:empty {
  display: none;
}

/* --------------------------------------------------------------- pie de página */

.footer {
  padding-block: clamp(3rem, 5vw, 4rem) 2rem;
  background: var(--surface-2);
  border-top: 1px solid var(--line);
}

.footer__grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
}

.footer h2 {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 0.85rem;
}

.footer ul {
  display: grid;
  gap: 0.15rem;
  font-size: 0.875rem;
  color: var(--text-2);
}

/* WCAG 2.2 pide objetivos de 24px: los enlaces del pie medían 18 de alto. */
.footer li {
  display: flex;
  align-items: center;
  min-height: 1.6rem;
}

.footer a {
  display: inline-flex;
  align-items: center;
  min-height: 1.6rem;
}

.footer a:hover {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer__logo {
  --brandmark-h: 22px;
}

.footer__about p {
  margin-top: 0.85rem;
  font-size: 0.875rem;
  color: var(--text-2);
  max-width: 30ch;
}

.footer__base {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  font-size: 0.8125rem;
  color: var(--text-3);
}

/* ------------------------------------------------------------------ movimiento
   Aparición al entrar en pantalla: ordena la lectura de arriba abajo. */

.js .reveal {
  opacity: 0;
  transform: translateY(1.1rem);
}

@media (prefers-reduced-motion: no-preference) {
  .js .reveal {
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
    transition-delay: var(--reveal-delay, 0ms);
  }
}

.js .reveal.is-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------------------------------------------------------- enlace suelto
   Enlace dentro de texto corrido. Se distingue por el subrayado, no por el
   color: la tinta se hereda del parrafo y asi mantiene el contraste del
   cuerpo, que el azul de marca a tamano pequeno no alcanza. */

.link {
  /* El relleno vertical no mueve la linea, pero sube el area pulsable de 21
     a 27px, por encima del minimo de 24 de la pauta. */
  padding-block: 0.2rem;
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  text-decoration-color: color-mix(in srgb, currentColor 45%, transparent);
  transition: text-decoration-color 0.2s var(--ease);
}

.link:hover {
  text-decoration-color: currentColor;
}

/* ------------------------------------------------------------- preguntas
   Acordeon nativo <details>. Se apoya en la reja y el costado del ano
   escolar para no inventar un segundo lenguaje visual, y repite el filo de
   3px del panel abierto. */

.faq__list {
  border: 1px solid var(--line);
  border-radius: var(--r-2);
  overflow: hidden;
  background: var(--surface);
}

.faq__item + .faq__item {
  border-top: 1px solid var(--line);
}

.faq__q {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.95rem 1.15rem;
  cursor: pointer;
  list-style: none;
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
  transition: background-color 0.2s var(--ease);
}

/* El triangulo propio del navegador sobra: ya hay punta de flecha. */
.faq__q::-webkit-details-marker {
  display: none;
}

.faq__q:hover {
  background: var(--surface-2);
}

.faq__q:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: -2px;
}

.faq__q > span {
  flex: 1;
}

.faq__chevron {
  flex: none;
  font-size: 0.9rem;
  color: var(--text-3);
  transition: transform 0.25s var(--ease), color 0.25s var(--ease);
}

.faq__item[open] .faq__q {
  background: var(--surface-2);
  box-shadow: inset 3px 0 0 var(--accent-2-fill);
}

.faq__item[open] .faq__chevron {
  transform: rotate(90deg);
  color: var(--brand);
}

.faq__a {
  padding: 0 1.15rem 1.25rem;
  background: var(--surface-2);
  box-shadow: inset 3px 0 0 var(--accent-2-fill);
}

.faq__a p {
  max-width: 62ch;
  font-size: 0.9375rem;
  color: var(--text-2);
}


/* ---------------------------------------------------------------- en camino
   Lo que el vault marca como pendiente se nombra, pero no se vende como
   hecho: icono de ruta en gris y una ficha pequeña al final de la línea. */

.soon {
  display: inline-block;
  margin-left: 0.3rem;
  padding: 0 0.4rem;
  border: 1px solid var(--line-2);
  border-radius: var(--r-xs);
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-3);
  white-space: nowrap;
  vertical-align: 0.08em;
}

.mod__does .is-soon .icon,
.stage__does .is-soon .icon,
.sheet__does .is-soon .icon {
  color: var(--text-3);
}

/* Tarjeta de lo que viene: la misma forma que las demás, sin relleno y con
   borde discontinuo, para que se lea como hoja de ruta y no como oferta. */
.mod--soon {
  background: transparent;
  border-style: dashed;
  border-color: var(--line-2);
  scroll-margin-top: calc(var(--nav-h) + 1rem);
}

.mod--soon .mod__art {
  color: var(--text-3);
}

.mod--soon .mod__price {
  border-top: 1px dashed var(--line-2);
}

.mod__does--soon li::before {
  content: '';
  flex: none;
  width: 5px;
  height: 5px;
  margin-top: 0.55em;
  border-radius: 50%;
  background: var(--text-3);
}

/* Con un número impar de paquetes el último ocupa la fila entera y lleva la
   tarifa a la derecha, para no dejar una celda vacía en la rejilla. Se cuenta
   por tipo: la leyenda del fieldset es el primer hijo. */
.tile:last-of-type:nth-of-type(odd) {
  grid-column: 1 / -1;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas:
    'icono nombre tarifa'
    'icono nota tarifa';
}

.tile:last-of-type:nth-of-type(odd) .tile__rate {
  margin-top: 0;
  align-self: center;
}

/* Enlace a la hoja de ruta desde la calculadora. El relleno lleva el área
   pulsable por encima de 24px. */
.probe__next {
  padding-block: 0.3rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-2);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  text-decoration-color: color-mix(in srgb, currentColor 45%, transparent);
}

.probe__next:hover {
  text-decoration-color: currentColor;
}
