/* FAMAT — prototipo v11 «Del plano a la apertura», revisión r1.
   Una sola hoja. Fuente única de verdad visual: docs/DESIGN_SYSTEM.md (colores, fuentes,
   radios de 4 px, elevaciones). Índice:
   1. Tokens · 2. Base · 3. Secciones · 4. Cabecera · 5. Botones · 6. Hero · 7. Logos
   8. Situaciones · 9. Pestañas y soluciones · 10. Proceso (lámina sticky) · 11. Caso y materiales
   12. Capacidades · 13. FAQ · 14. Cierre y formulario · 15. Pie y barra móvil
   16. Modo revisión · 17. Movimiento */

/* ========== 1. Tokens ========== */

@font-face {
  font-family: "Space Grotesk";
  src: url("../assets/fonts/space-grotesk-latin-var.woff2") format("woff2");
  font-weight: 500 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Work Sans";
  src: url("../assets/fonts/work-sans-latin-var.woff2") format("woff2");
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --white: #FFFFFF;
  --surface-subtle: #F8F9FA;
  --chrome-highlight: #F0F2F5;
  --divider: #E5E7EB;
  --chrome-metallic: #D1D5DB;
  --chrome-border: #9CA3AF;
  --placeholder: #6B7280;       /* ajuste WCAG aprobado (el DS pide #9CA3AF, 2.5:1) */
  --charcoal: #2B2B2B;
  --charcoal-dark: #1E1E1E;
  --text: #1E1E1E;
  --heading: #2B2B2B;
  --text-muted: #5F5E5E;
  --on-dark: #F0F2F5;
  --on-dark-muted: #D1D5DB;
  --primary: #D3122A;
  --primary-deep: #A80B1E;
  --error: #BA1A1A;

  --font-display: "Space Grotesk", "Segoe UI", system-ui, sans-serif;
  --font-body: "Work Sans", "Segoe UI", system-ui, sans-serif;
  --headline-xl: 2rem;    --headline-xl-lh: 2.5rem;
  --headline-lg: 1.625rem; --headline-lg-lh: 2.125rem;
  --headline-md: 1.5rem;  --headline-md-lh: 2rem;
  --headline-sm: 1.25rem; --headline-sm-lh: 1.75rem;
  --body-lg: 1.125rem;    --body-lg-lh: 1.75rem;
  --body-md: 0.9375rem;   --body-md-lh: 1.5rem;
  --body-sm: 0.8125rem;   --body-sm-lh: 1.25rem;
  --label-lg: 0.875rem;
  --label-md: 0.75rem;
  --label-sm: 0.625rem;

  --radius: 0.25rem;
  --radius-sm: 0.125rem;
  --elev-1: 0 1px 3px rgba(30, 30, 30, 0.08);
  --elev-2: 0 6px 16px -2px rgba(30, 30, 30, 0.12);
  --elev-3: 0 20px 40px -4px rgba(30, 30, 30, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.8);
  --elev-primary: 0 2px 8px rgba(211, 18, 42, 0.35);

  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2.5rem;
  --space-2xl: 4rem;
  --page-margin: 1rem;
  --gutter: 1rem;
  --max: 90rem;
  --section-gap: 5rem;
  --stack: var(--space-xl);
  --header-h: 4rem;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --t-press: 160ms;
  --t-fast: 200ms;
  --t-base: 280ms;
  --t-scene: 450ms;
  --t-reveal: 800ms;
}
@media (min-width: 48rem) {
  :root {
    --page-margin: 2rem;
    --gutter: 1.5rem;
    --headline-xl: 3rem;    --headline-xl-lh: 3.5rem;
    --headline-lg: 2.25rem; --headline-lg-lh: 2.75rem;
  }
}
@media (min-width: 60rem) { :root { --header-h: 4.5rem; } }
@media (min-width: 75rem) {
  :root { --page-margin: 3rem; --gutter: 2rem; --section-gap: 7rem; --stack: var(--space-2xl); }
}

/* ========== 2. Base ========== */

*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
  scroll-padding-bottom: 6rem;
  scrollbar-color: var(--chrome-border) var(--surface-subtle);
}
@media (min-width: 60rem) { html { scroll-padding-bottom: 1rem; } }
body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--body-md);
  line-height: var(--body-md-lh);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, svg, picture { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; color: var(--heading); letter-spacing: -0.02em; text-wrap: balance; }
p { text-wrap: pretty; }
a { color: inherit; text-underline-offset: 0.22em; text-decoration-thickness: 1px; }
button, input, select { font: inherit; color: inherit; }
.num, td, dd { font-variant-numeric: tabular-nums; }
::selection { background: var(--charcoal); color: var(--white); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.on-dark :focus-visible { outline-color: var(--on-dark); }
.on-dark .callback :focus-visible { outline-color: var(--primary); }
input { caret-color: var(--primary); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link {
  position: absolute; left: var(--page-margin); top: -4rem; z-index: 100;
  padding: 0.75rem 1rem; border-radius: var(--radius); background: var(--charcoal-dark); color: var(--white);
  font-family: var(--font-display); font-size: var(--label-lg); font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; text-decoration: none;
}
.skip-link:focus { top: 0.75rem; }
.icon { width: 1.25em; height: 1.25em; flex: none; }
html:not(.js) img[data-defer] { display: none; }

/* Etiqueta técnica (label-md) */
.photo-tag, .clients-band__title, .facts dt, .field label, .stage__n, .viewer__thumb span {
  font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; line-height: 1rem; letter-spacing: 0.08em; text-transform: uppercase;
}

/* Dibujo técnico: trazos de esquema, cotas en rojo */
.drawing path { fill: none; stroke-width: 2; stroke-linecap: square; stroke-linejoin: miter; }
.drawing .ink path { stroke: var(--charcoal); }
.drawing .accent path { stroke: var(--primary); }
.drawing .dash { stroke-dasharray: 6 6; }
.drawing--dark .ink path { stroke: var(--on-dark-muted); }

/* ========== 3. Secciones ========== */

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--page-margin); }
.section { padding-block: var(--section-gap); }
.section--warm { background: var(--surface-subtle); }
.section--dark { background: var(--charcoal-dark); color: var(--on-dark); }
.section--dark h2, .section--dark h3 { color: var(--white); }
.section-title { max-width: 24ch; font-size: var(--headline-lg); line-height: var(--headline-lg-lh); }
.section-lead { max-width: 52ch; font-size: var(--body-lg); line-height: var(--body-lg-lh); color: var(--text-muted); }
.section--dark .section-lead { color: var(--on-dark-muted); }

/* Encabezado de sección: título y entradilla en dos columnas en escritorio */
.needs__head, .solutions__head, .process__head, .capabilities__head { display: grid; gap: var(--space-md); margin-bottom: var(--stack); }
@media (min-width: 60rem) {
  .needs__head, .solutions__head, .process__head, .capabilities__head { grid-template-columns: 7fr 5fr; column-gap: var(--gutter); align-items: end; }
}

.photo-tag {
  position: absolute; left: var(--space-md); bottom: var(--space-md); max-width: calc(100% - 2rem);
  padding: var(--space-sm) 0.75rem; border-radius: var(--radius-sm); background: var(--white); color: var(--charcoal);
}

/* ========== 4. Cabecera ========== */

.site-header { position: sticky; top: 0; z-index: 50; background: var(--white); border-bottom: 1px solid transparent; transition: border-color var(--t-base) ease; }
.site-header.is-scrolled { border-bottom-color: var(--divider); }
/* Barra de progreso desde 60rem (donde desaparece la barra móvil). Va 1:1 con el scroll: sin transición, solo transform. */
.scroll-progress { display: none; }
@media (min-width: 60rem) {
  .js .scroll-progress { display: block; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--primary); transform: scaleX(0); transform-origin: left center; pointer-events: none; }
}
.site-header__bar { display: flex; align-items: center; gap: var(--space-lg); min-height: var(--header-h); }
/* Zona de clic de 44 px con el logo centrado: el logo no cambia de tamaño */
.brand { flex: none; display: inline-flex; align-items: center; min-height: 2.75rem; margin-right: auto; }
.brand img { width: 7.5rem; }
.site-nav__list {
  display: flex; gap: var(--space-lg);
  font-family: var(--font-display); font-size: var(--label-lg); font-weight: 600; line-height: 1.25rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--charcoal);
}
.site-nav__list a { display: inline-block; padding-block: 0.75rem; border-bottom: 2px solid transparent; text-decoration: none; transition: border-color var(--t-fast) ease; }
.site-nav__list a:hover { border-bottom-color: var(--primary); }
.site-nav__toggle { display: none; }
.site-header .header-cta { display: none; }
@media (min-width: 60rem) {
  .brand img { width: 10rem; }
  /* Siempre presente y en el mismo sitio (sin saltos). Mientras el CTA del hero está a la vista
     es secundario (contorno) para no competir; después pasa a rojo. Solo cambia el color. */
  .site-header .header-cta { display: inline-flex; }
  .site-header .header-cta.is-quiet { background: var(--white); border-color: var(--charcoal); color: var(--charcoal); }
  .site-header .header-cta.is-quiet:hover { background: var(--chrome-highlight); box-shadow: none; }
}
@media (min-width: 75rem) { .site-nav__list, .site-header__bar { gap: var(--space-xl); } }
@media (max-width: 59.99rem) {
  .site-header__bar { gap: var(--space-sm); }
  .site-nav { order: 3; }
  .site-nav__toggle {
    display: inline-flex; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem;
    border: 1px solid var(--chrome-metallic); border-radius: var(--radius); background: var(--white); cursor: pointer;
  }
  .site-nav__toggle-bars, .site-nav__toggle-bars::before { display: block; width: 1.125rem; height: 2px; background: var(--charcoal); transition: transform var(--t-base) var(--ease-out); }
  .site-nav__toggle-bars { position: relative; transform: translateY(-3px); }
  .site-nav__toggle-bars::before { content: ""; position: absolute; top: 6px; }
  .site-nav__toggle[aria-expanded="true"] .site-nav__toggle-bars { transform: rotate(45deg); }
  .site-nav__toggle[aria-expanded="true"] .site-nav__toggle-bars::before { transform: translateY(-6px) rotate(-90deg); }
  .site-nav__list {
    position: absolute; inset: 100% 0 auto 0; flex-direction: column; gap: 0;
    padding: var(--space-sm) var(--page-margin) var(--space-lg); background: var(--white); border-bottom: 1px solid var(--chrome-metallic); box-shadow: var(--elev-2);
  }
  .js .site-nav__list:not(.is-open) { display: none; }
  .site-nav__list.is-open { animation: menu-in var(--t-base) var(--ease-out); }
  .site-nav__list a { display: block; padding-block: var(--space-md); border-bottom: 0; }
  html:not(.js) .site-header__bar { flex-wrap: wrap; padding-block: var(--space-sm); }
  html:not(.js) .site-nav { order: 0; width: 100%; }
  html:not(.js) .site-nav__toggle { display: none; }
  html:not(.js) .site-nav__list { position: static; flex-direction: row; flex-wrap: wrap; gap: 0 var(--space-lg); padding: 0; border: 0; box-shadow: none; }
  html:not(.js) .site-nav__list a { padding-block: var(--space-sm); }
}
@keyframes menu-in { from { opacity: 0; transform: translateY(-6px); } }

/* ========== 5. Botones y enlaces ========== */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.625rem; min-height: 3rem; padding: 0 1.5rem;
  border: 1.5px solid transparent; border-radius: var(--radius);
  font-family: var(--font-display); font-size: var(--label-lg); font-weight: 600; line-height: 1.25rem; letter-spacing: 0.06em; text-transform: uppercase; text-decoration: none; cursor: pointer;
  transition: background-color var(--t-fast) ease, border-color var(--t-fast) ease, color var(--t-fast) ease, box-shadow var(--t-fast) ease, transform var(--t-press) var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn--wa { background: var(--primary); color: var(--white); }
.btn--wa:hover { background: var(--primary-deep); box-shadow: var(--elev-primary); }
.btn--ink { background: var(--chrome-highlight); border-color: var(--chrome-border); color: var(--charcoal-dark); }
.btn--ink:hover { background: var(--divider); border-color: var(--charcoal); }
.btn--small { min-height: 2.75rem; padding: 0 1rem; font-size: var(--label-md); letter-spacing: 0.08em; }
.btn--large { min-height: 3.5rem; padding: 0 2rem; }
.btn--block { width: 100%; }
/* En móvil, todos los botones de las secciones de contenido van a todo el ancho */
@media (max-width: 47.99rem) { main .btn { width: 100%; } }
.btn__via { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.btn[disabled] { cursor: progress; opacity: 0.7; }
.btn[disabled]:active { transform: none; }

.link-arrow {
  display: inline-flex; align-items: center; gap: var(--space-sm); min-height: 2.75rem;
  font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; text-decoration: none; color: var(--charcoal);
}
.link-arrow::after {
  content: ""; width: 0.5em; height: 0.5em; border-top: 1.5px solid currentColor; border-right: 1.5px solid currentColor;
  transform: rotate(45deg); transition: transform var(--t-fast) var(--ease-out);
}
.link-arrow:hover { color: var(--primary); }
/* Enlace de texto de Situaciones y FAQ: siempre subrayado, 24 px de alto como mínimo y el foco global */
.enlace-texto { display: inline-block; padding-block: 0.25rem; color: var(--charcoal); font-weight: 500; text-decoration: underline; transition: color var(--t-fast) ease; }
.enlace-texto:hover { color: var(--primary); }
@media (hover: hover) and (pointer: fine) { .link-arrow:hover::after { transform: translateX(4px) rotate(45deg); } }

/* ========== 6. Hero ========== */

.hero { display: grid; }
.hero__text { display: grid; gap: var(--space-lg); align-content: center; padding: var(--space-xl) var(--page-margin); }
.hero__eyebrow { font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; line-height: 1rem; letter-spacing: 0.08em; color: var(--primary); }
.hero__title { max-width: 16ch; font-size: var(--headline-xl); line-height: var(--headline-xl-lh); color: var(--charcoal); }
.hero__lead { max-width: 40ch; font-size: var(--body-lg); line-height: var(--body-lg-lh); }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-md) var(--space-lg); margin-top: var(--space-sm); }
.hero__note { font-size: var(--body-sm); line-height: var(--body-sm-lh); color: var(--text-muted); }
.hero__metrics { display: grid; gap: var(--space-sm); padding-top: var(--space-md); border-top: 1px solid var(--divider); }
.hero__metrics div { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: var(--space-sm); align-items: baseline; }
.hero__metrics dt { font-family: var(--font-display); font-size: var(--body-lg); line-height: 1.5rem; font-weight: 700; color: var(--charcoal); }
.hero__metrics dd { font-size: var(--body-sm); line-height: var(--body-sm-lh); color: var(--text-muted); }
@media (min-width: 30rem) and (max-width: 47.99rem), (min-width: 75rem) {
  .hero__metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); }
  .hero__metrics div { grid-template-columns: 1fr; gap: var(--space-xs); align-content: start; }
}
.hero__media { position: relative; overflow: hidden; background: var(--surface-subtle); }
.hero__media > picture img { width: 100%; aspect-ratio: 1376 / 768; object-fit: cover; }
.hero__media .photo-tag { display: none; }
@media (min-width: 48rem) {
  .hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; }
  .hero__media .photo-tag { display: block; }
}
@media (min-width: 60rem) {
  .hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); padding-block: var(--space-lg) var(--space-xl); }
  .hero__media { margin-right: max(var(--page-margin), calc((100vw - var(--max)) / 2 + var(--page-margin))); border-radius: var(--radius); }
  .hero__text { padding-left: max(var(--page-margin), calc((100vw - var(--max)) / 2 + var(--page-margin))); padding-right: var(--space-xl); }
  .hero__media .photo-tag { left: var(--space-lg); bottom: var(--space-lg); }
}

/* ========== 7. Logos ========== */

.clients-band { border-block: 1px solid var(--divider); }
.clients-band__inner { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-lg); padding-block: var(--space-xl); }
.clients-band__title { color: var(--text-muted); }
.clients { display: grid; grid-template-columns: repeat(3, 1fr); align-items: center; gap: var(--space-xl) var(--space-lg); }
.clients li { display: flex; justify-content: center; }
.clients img {
  width: auto; height: var(--logo-h, 2rem); max-width: 100%; object-fit: contain; filter: grayscale(1); opacity: 0.78; mix-blend-mode: multiply;
  transition: filter var(--t-base) ease, opacity var(--t-base) ease;
}
/* Estado base (sin JS o con movimiento reducido): cuadrícula estática, sin copia y sin botón de pausa */
.clients--copia, .marquee__toggle, .marquee__pausa, .marquee__reanudar { display: none; }
@media (hover: hover) and (pointer: fine) { .clients img:hover { filter: none; opacity: 1; } }
@media (min-width: 60rem) {
  .clients-band__inner { grid-template-columns: 12rem minmax(0, 1fr); align-items: center; column-gap: var(--space-xl); }
  .clients { grid-template-columns: repeat(6, 1fr); }
}
@media (min-width: 48rem) and (max-width: 59.99rem) { .clients { grid-template-columns: repeat(4, 1fr); } }
/* Marquee: el botón de pausa es un checkbox nativo; su nombre accesible cambia con el CSS (WCAG 2.2.2) */
@media (prefers-reduced-motion: no-preference) {
  .js .marquee { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: var(--space-md); }
  .js .marquee__toggle { display: block; }
  .js .marquee__pausa {
    position: relative; display: inline-flex; align-items: center; justify-content: center; grid-column: 2; grid-row: 1; width: 2.75rem; height: 2.75rem; border: 1px solid var(--chrome-metallic); border-radius: 4px; background: var(--white); color: var(--charcoal); cursor: pointer;
    transition: border-color var(--t-fast) ease, transform var(--t-press) var(--ease-out);
  }
  .js .marquee__pausa:hover { border-color: var(--charcoal); }
  .js .marquee__pausa:active { transform: scale(0.97); }
  .js .marquee__toggle:focus-visible + .marquee__pausa { outline: 2px solid var(--primary); outline-offset: 2px; }
  .js .marquee__toggle:checked + .marquee__pausa .marquee__pausar { display: none; }
  .js .marquee__toggle:checked + .marquee__pausa .marquee__reanudar { display: inline; }
  .js .marquee__icono--reanudar, .js .marquee__toggle:checked + .marquee__pausa .marquee__icono--pausar { display: none; }
  .js .marquee__toggle:checked + .marquee__pausa .marquee__icono--reanudar { display: block; }
  .js .marquee__vista {
    grid-column: 1; grid-row: 1; overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
    mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
  }
  .js .marquee__pista { display: flex; width: max-content; animation: marquee 100s linear infinite; }
  .js .marquee__vista:hover .marquee__pista,
  .js .marquee__toggle:focus-visible ~ .marquee__vista .marquee__pista,
  .js .marquee__toggle:checked ~ .marquee__vista .marquee__pista { animation-play-state: paused; }
  .js .clients { display: flex; flex: none; align-items: center; gap: var(--space-2xl); padding-right: var(--space-2xl); }
  .js .clients li { flex: none; }
  .js .clients img { max-width: none; }
}
@media (prefers-reduced-motion: no-preference) and (max-width: 47.99rem) {
  .js .marquee { column-gap: var(--space-sm); }
}
@keyframes marquee { to { transform: translateX(-50%); } }

/* ========== 7 bis. Trayectoria ========== */

.ventajas { padding-block: var(--space-2xl); }
.ventajas .section-title { margin-bottom: var(--space-xl); }
/* v16 (PDF de Andrea): 3 tarjetas centradas con el icono arriba, el título en mayúsculas y el texto debajo.
   1 columna en móvil, 3 desde 768 px y más separación desde 1024 px. El copy y los iconos no cambian. */
.ventajas__lista { display: grid; gap: var(--space-md); }
.ventajas__lista li { display: grid; justify-items: center; align-content: start; gap: var(--space-md); padding: 2rem; border: 1px solid var(--divider); border-radius: var(--radius); background: var(--surface-subtle); text-align: center; }
/* Icono de 48 px sin recuadro: el viewBox (48) se dibuja 1:1, así que el trazo de 1,5 da 1,5 px visibles */
.ventajas .ventajas__icono { flex: none; width: 3rem; height: 3rem; }
.ventajas .ventajas__icono path { stroke-width: 1.5; }
.ventajas__texto { display: grid; justify-items: center; gap: var(--space-sm); }
.ventajas__texto h3 { font-family: var(--font-display); font-size: 1.125rem; line-height: 1.5rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--heading); }
.ventajas__texto p { max-width: 30ch; min-height: 3rem; font-size: var(--body-md); line-height: var(--body-md-lh); color: var(--text-muted); text-wrap: balance; }  /* 2 líneas reservadas: iguala las tarjetas apiladas en móvil */
@media (max-width: 47.99rem) {
  .ventajas__lista { gap: var(--space-sm); }
  .ventajas__lista li { padding: 1.5rem; }
}
@media (min-width: 48rem) {
  .ventajas__lista { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); }
}
@media (min-width: 64rem) {
  .ventajas__lista { gap: var(--space-xl); }
}
/* Entrada: cada icono se traza en 900 ms con 100 ms de escalonado; el texto entra a los 600 ms */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal="ventajas"] path { stroke-dasharray: 1; stroke-dashoffset: 0; transition: stroke-dashoffset 900ms var(--ease-in-out); }
  .js [data-reveal="ventajas"]:not(.is-in) path { stroke-dashoffset: 1; }
  .js [data-reveal="ventajas"] li:nth-child(2) path { transition-delay: 100ms; }
  .js [data-reveal="ventajas"] li:nth-child(3) path { transition-delay: 200ms; }
  .js [data-reveal="ventajas"] .ventajas__texto { transition: opacity 400ms ease 600ms; }
  .js [data-reveal="ventajas"]:not(.is-in) .ventajas__texto { opacity: 0; }
}

/* ========== 8. Situaciones ========== */

.needs__list { display: grid; gap: var(--space-lg); }
.need { display: flex; }
/* Las tarjetas solo identifican la situación: no son enlaces y no reaccionan al puntero */
.need__card {
  display: grid; grid-template-rows: auto auto 1fr; gap: 0.75rem; width: 100%; padding: var(--space-md);
  border: 1px solid var(--divider); border-top: 3px solid var(--charcoal); border-radius: var(--radius); background: var(--white);
}
.need__art { width: 100%; aspect-ratio: 8 / 5; padding: var(--space-sm); border: 1px solid var(--divider); border-radius: var(--radius-sm); background: radial-gradient(var(--chrome-metallic) 1px, transparent 1px) 0 0 / 12px 12px, var(--surface-subtle); }
.need__title { font-size: var(--headline-sm); line-height: var(--headline-sm-lh); font-weight: 600; letter-spacing: 0; }
.need p { max-width: 32ch; color: var(--text-muted); }
/* Bajo 960 px la lámina es pequeña: con 2 unidades el trazo queda entre 0,65 y 1,3 px */
@media (max-width: 59.99rem) {
  .need__art.drawing path { stroke-width: 3.5; }
}
@media (max-width: 47.99rem) {
  /* Móvil: lámina a la izquierda y texto a la derecha, para que las tres quepan en poco más de una pantalla */
  .needs__list { gap: var(--space-sm); }
  .need__card { grid-template-columns: 7.5rem minmax(0, 1fr); grid-template-rows: auto 1fr; column-gap: var(--space-md); row-gap: var(--space-xs); padding: var(--space-sm); }
  .need__art { grid-row: 1 / -1; align-self: start; padding: var(--space-xs); }
  .need__title { font-size: var(--body-lg); line-height: 1.5rem; }
  .need p { font-size: var(--body-sm); line-height: var(--body-sm-lh); }
}
@media (min-width: 48rem) {
  .needs__list { grid-template-columns: repeat(3, 1fr); gap: var(--gutter); }
  .need__art { aspect-ratio: 2 / 1; }
}

/* Banda de cierre: el único camino a WhatsApp de la sección */
.needs__banda { display: grid; gap: 0.75rem; margin-top: var(--space-lg); padding: var(--space-md); border: 1px solid var(--divider); border-radius: var(--radius); background: var(--surface-subtle); }
.needs__banda-titulo { font-family: var(--font-display); font-size: var(--body-lg); line-height: 1.5rem; font-weight: 600; color: var(--charcoal); }
@media (min-width: 48rem) {
  .needs__banda { grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: var(--space-xl); padding: var(--space-lg) var(--space-xl); }
  .needs__banda-titulo { font-size: var(--headline-sm); line-height: var(--headline-sm-lh); }
}

/* ========== 9. Pestañas y soluciones ========== */

/* Lista de pestañas: chips del DS (4 px, borde cromado; activo en carbón) */
.tabs__list { display: flex; flex-wrap: wrap; gap: var(--space-sm); margin-bottom: var(--space-lg); }
.tabs__tab {
  display: inline-flex; align-items: center; gap: var(--space-sm); flex: none; min-height: 2.75rem; padding: 0 1rem;
  border: 1px solid var(--chrome-metallic); border-radius: var(--radius); background: var(--white); color: var(--charcoal); cursor: pointer;
  font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  transition: background-color var(--t-fast) ease, color var(--t-fast) ease, border-color var(--t-fast) ease, transform var(--t-press) var(--ease-out);
}
.tabs__tab:hover { border-color: var(--charcoal); }
.tabs__tab:active { transform: scale(0.97); }
.tabs__tab[aria-selected="true"] { background: var(--charcoal); border-color: var(--charcoal); color: var(--white); }
html:not(.js) .tabs__list { display: none; }

/* Paneles apilados en la misma celda: la altura es la del mayor, sin saltos al cambiar */
.tabs__panels { display: grid; gap: var(--space-2xl); }
.js .tabs__panels { gap: 0; }
.js .tabs__panels > [role="tabpanel"] { grid-area: 1 / 1; }
.js .tabs__panels > [role="tabpanel"]:not(.is-active) { visibility: hidden; opacity: 0; pointer-events: none; }

.solution { display: grid; gap: var(--space-lg); }
.solution__media { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--chrome-highlight); }
.solution__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.solution__body { display: grid; gap: var(--space-md); align-content: center; justify-items: start; }
.solution__title { font-size: var(--headline-md); line-height: var(--headline-md-lh); font-weight: 600; letter-spacing: -0.01em; }
.solution__body > p { max-width: 38ch; }
.solution .lista-iconos { width: 100%; margin-block: var(--space-sm); }
@media (min-width: 48rem) {
  .solution { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); column-gap: var(--space-xl); align-items: center; }
}
@media (min-width: 64rem) {
  .solution { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: var(--space-2xl); }
  .solutions__head { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: var(--space-2xl); }
}
/* Pestañas de categoría: en móvil, 2×2 en columnas iguales (no se desbordan ni cambian de línea a medias) */
@media (max-width: 47.99rem) {
  .solutions .tabs__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .solutions .tabs__tab { justify-content: center; padding: 0.5rem; text-align: center; line-height: 1rem; }
}
@media (max-width: 29.99rem) { .solutions .tabs__tab .icon { display: none; } }

/* ========== 10. Proceso «Del plano a la apertura» ==========
   Tarjetas apiladas en todos los anchos: cada etapa es una tarjeta con su foto, número gigante, icono, título y línea.
   Hasta 599 px la foto va arriba; desde 600 px, a la izquierda del texto. */

.proceso { display: grid; gap: var(--space-xl); }

/* Rótulo de cada imagen (honestidad: tipo de imagen) */
.kind {
  display: inline-block; padding: 0.25rem 0.5rem; border-radius: var(--radius-sm); background: var(--charcoal-dark); color: var(--on-dark);
  font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; line-height: 1rem; letter-spacing: 0.08em; text-transform: uppercase;
}

.pasos { display: grid; gap: var(--space-sm); }
.paso:nth-child(1) { --i: 0; }
.paso:nth-child(2) { --i: 1; }
.paso:nth-child(3) { --i: 2; }
.paso:nth-child(4) { --i: 3; }
/* Grises derivados del carbón, un poco más claros en cada tarjeta */
.paso { position: relative; display: grid; gap: 0.75rem; align-content: start; padding: var(--space-md); border-radius: var(--radius); background: color-mix(in srgb, var(--charcoal), var(--white) calc(var(--i) * 3%)); box-shadow: 0 -6px 16px rgba(0, 0, 0, 0.28); transform-origin: 50% 0; }
.paso__fig { position: relative; min-width: 0; margin: 0; aspect-ratio: 16 / 9; border-radius: var(--radius); background: var(--charcoal-dark); overflow: hidden; }
.paso__fig picture { display: contents; }
.paso__fig img { width: 100%; height: 100%; object-fit: cover; }
.paso__fig .kind { position: absolute; left: var(--space-sm); top: var(--space-sm); max-width: calc(100% - 2 * var(--space-sm)); }
.paso__texto { display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto 1fr; gap: var(--space-xs) 0.875rem; align-items: start; min-width: 0; }
/* Número gigante e icono: decorativos. El lector de pantalla conserva el número del título */
.paso__marca { display: grid; grid-column: 1; grid-row: 1 / span 2; gap: var(--space-xs); justify-items: start; }
.paso__num { font-family: var(--font-display); font-size: 4rem; font-weight: 700; line-height: 0.9; color: var(--white); }
/* 1,5 px visibles: el icono se dibuja a 28 de 48 unidades */
.paso__icono { width: 1.75rem; height: 1.75rem; }
.paso .paso__icono path { stroke: var(--on-dark-muted); stroke-width: 2.57; }
.paso__titulo { grid-column: 2; grid-row: 1; font-size: var(--headline-sm); line-height: var(--headline-sm-lh); font-weight: 600; letter-spacing: 0; color: var(--white); }
.paso__n { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.paso__texto p { grid-column: 2; grid-row: 2; max-width: 40ch; color: var(--on-dark); }
/* Menos de 380 px: número de 3rem y título menor */
@media (max-width: 23.74rem) {
  .paso { padding: 0.75rem; }
  .paso__num { font-size: 3rem; }
  .paso__titulo { font-size: var(--body-lg); line-height: 1.5rem; }
}
/* De 600 a 767 px: foto y texto lado a lado */
@media (min-width: 37.5rem) {
  .paso { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); column-gap: var(--space-lg); align-items: center; }
}
/* Desde 768 px: mitad foto y mitad texto, con número e icono mayores */
@media (min-width: 48rem) {
  .pasos { gap: var(--space-md); }
  .paso { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: clamp(1.5rem, 4vw, 4rem); padding: var(--space-lg); }
  .paso__fig { aspect-ratio: 7 / 4; }
  .paso__texto { column-gap: 1.25rem; }
  .paso__num { font-size: clamp(4rem, 8vw, 7.5rem); }
  /* 1,5 px visibles: el icono se dibuja a 32 de 48 unidades */
  .paso__icono { width: 2rem; height: 2rem; }
  .paso .paso__icono path { stroke-width: 2.25; }
}
@media (min-width: 64rem) {
  .paso__titulo { font-size: var(--headline-md); line-height: var(--headline-md-lh); }
  .paso__texto p { font-size: var(--body-lg); line-height: var(--body-lg-lh); }
}
/* Apilado: cada tarjeta se fija bajo la cabecera y la anterior se reduce al llegar la siguiente. Solo transform y opacity; sin movimiento si se pide reducirlo.
   Desde 600 px de alto: en pantallas más bajas (apaisado, zoom alto) una tarjeta fija podría quedar más alta que la ventana y esconder su texto. */
@media (min-height: 37.5rem) and (prefers-reduced-motion: no-preference) {
  .paso { position: sticky; top: calc(var(--header-h) + var(--i) * 0.75rem); }
  .paso::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: var(--charcoal-dark); opacity: 0; pointer-events: none; transition: opacity 400ms var(--ease-out); }
  .paso.is-atras { transform: scale(0.92); }
  .paso.is-atras::after { opacity: 0.32; }
}
@media (min-width: 48rem) and (min-height: 37.5rem) and (prefers-reduced-motion: no-preference) {
  .paso { top: calc(var(--header-h) + var(--i) * 1.25rem); }
}

.process__cta { display: grid; gap: var(--space-md); justify-items: start; padding-top: var(--space-lg); border-top: 1px solid rgba(240, 242, 245, 0.18); }
.process__cta p { max-width: 36ch; color: var(--on-dark); }

/* ========== 11. Caso (comparador) y materiales (V12) ==========
   < 48rem: cabecera, comparador 4:5, descripción y CTA. 48–64rem: lo mismo con el comparador 4:3 a todo el ancho.
   ≥ 64rem: descripción y CTA a la izquierda; comparador a la derecha. */

.case__grid { display: grid; gap: var(--space-lg) var(--gutter); }
.case__head { display: grid; gap: var(--space-xs); align-content: start; }
.case__info { display: grid; gap: var(--space-lg); align-content: start; }
/* Encabezado de la alianza: la etiqueta va dentro del h2 para que la sección se nombre completa */
.case__nombre { font-size: var(--headline-lg); line-height: var(--headline-lg-lh); }
.etiqueta { display: block; margin-bottom: var(--space-sm); font-size: var(--label-md); font-weight: 600; line-height: 1rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--primary); }
/* Fondo oscuro: el rojo da 3,09:1 y no cumple en texto de este tamaño. Texto claro y raya roja decorativa. */
.on-dark .etiqueta { display: flex; align-items: center; gap: var(--space-xs); color: var(--on-dark-muted); }
.on-dark .etiqueta::before { content: ""; flex: none; width: 1.5rem; height: 2px; background: var(--primary); }

/* Detalles del módulo: lista con título visible, sin cajas ni mayúsculas */
/* Lista con iconos, única para Soluciones y Alianza. 2 columnas desde 500 px de ancho de la propia lista (2 × 238 + 24); por debajo, 1.
   Con columnas CSS el orden visual es el del HTML y 5 ítems quedan en 3 + 2. */
.lista-iconos { columns: 14.875rem 2; column-gap: var(--space-lg); }
.lista-iconos li { display: flex; align-items: center; gap: var(--space-sm); padding: 0.375rem 0; break-inside: avoid; font-size: var(--body-md); font-weight: 400; }
.lista-iconos .icon { width: 1.5rem; height: 1.5rem; color: var(--charcoal); }

.tags { display: flex; flex-wrap: wrap; gap: var(--space-sm); }
.tags li {
  padding: 0.375rem 0.625rem; border: 1px solid var(--chrome-metallic); border-radius: var(--radius-sm); background: var(--surface-subtle);
  font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; line-height: 1rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--charcoal);
}

.case__visual { display: grid; gap: var(--space-sm); min-width: 0; margin: 0; }
/* Comparador: dos fotos del mismo encuadre apiladas; la de «equipado» se recorta desde el divisor. */
/* Cabecera del comparador: rótulo de la foto equipada (fuera de la imagen para no tapar el módulo) y selector de vista, separado 8 px de la foto.
   row-reverse deja el rótulo a la derecha y, si no caben juntos, encima del selector. El rótulo se oculta sin desplazar nada cuando la foto equipada deja de verse. */
.compare__cabecera { display: flex; flex-flow: row-reverse wrap; align-items: flex-end; gap: var(--space-sm) var(--space-md); }
.case__visual:has(.compare.is-end) .compare__rotulo { visibility: hidden; }
/* Selector de vista: control segmentado de radios nativos. Una sola pieza con línea interior, para leerse como estado y no como pestaña; sin escala al pulsar porque no es una acción. Sin overflow: hidden, para no recortar el foco. */
.vista { flex: 1 1 100%; min-width: 0; margin: 0; padding: 0; border: 0; }
.vista__titulo { padding: 0; margin-bottom: var(--space-xs); font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; line-height: 1rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); }
.vista__opciones { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border: 1px solid var(--chrome-metallic); border-radius: var(--radius); background: var(--white); }
.vista__op { position: relative; display: block; }
.vista__op input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.vista__op span {
  display: flex; align-items: center; justify-content: center; min-height: 2.75rem; padding: 0 1rem; border: 0;
  background: var(--white); color: var(--charcoal); font-size: var(--body-sm); font-weight: 500; line-height: 1.25rem; white-space: nowrap; transition: background-color var(--t-fast) ease, color var(--t-fast) ease;
}
.vista__op:first-child span { border-radius: calc(var(--radius) - 1px) 0 0 calc(var(--radius) - 1px); }
.vista__op:last-child span { border-left: 1px solid var(--chrome-metallic); border-radius: 0 calc(var(--radius) - 1px) calc(var(--radius) - 1px) 0; }
.vista__op input:hover + span { background: var(--surface-subtle); }
.vista__op input:checked + span { background: var(--charcoal); border-color: var(--charcoal); color: var(--white); }
.vista__op input:focus-visible + span { position: relative; z-index: 1; outline: 2px solid var(--primary); outline-offset: 2px; }
@media (min-width: 48rem) {
  .vista { flex: 0 1 auto; margin-right: auto; }
  .vista__titulo { float: left; margin: 0 var(--space-sm) 0 0; line-height: 2.875rem; }
  .vista__opciones { display: inline-grid; grid-template-columns: auto auto; }
}
/* Sin JS: fotos apiladas y rótulo bajo la equipada */
html:not(.js) .compare__cabecera { display: contents; }
html:not(.js) .vista { display: none; }
html:not(.js) .compare__rotulo { order: 1; justify-self: start; }
.compare { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--chrome-highlight); aspect-ratio: 4 / 5; isolation: isolate; }
.compare__img, .compare__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.compare__img--after { clip-path: inset(0 0 0 var(--pos)); }
.compare__tag {
  position: absolute; top: var(--space-sm); z-index: 2; padding: 0.25rem 0.5rem; border-radius: var(--radius-sm);
  background: var(--white); color: var(--charcoal); pointer-events: none;
  font-family: var(--font-display); font-size: var(--label-md); font-weight: 600; line-height: 1rem; letter-spacing: 0.08em; text-transform: uppercase;
  transition: opacity var(--t-fast) ease;
}
.compare__tag--before { left: var(--space-sm); }
.compare__tag--after { right: var(--space-sm); background: var(--primary); color: var(--white); }
.compare.is-start .compare__tag--before, .compare.is-end .compare__tag--after { opacity: 0; }
.compare__handle { position: absolute; top: 0; bottom: 0; left: var(--pos); z-index: 2; width: 2px; margin-left: -1px; background: var(--white); pointer-events: none; }
.compare__handle::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 2.75rem; height: 2.75rem; transform: translate(-50%, -50%);
  border-radius: var(--radius); background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23D3122A' stroke-width='2' stroke-linecap='square' d='M9 7l-5 5 5 5M15 7l5 5-5 5'/%3E%3C/svg%3E") center / 1.5rem no-repeat;
  box-shadow: var(--elev-2); transition: transform var(--t-press) var(--ease-out);
}
.compare.is-dragging .compare__handle::after { transform: translate(-50%, -50%) scale(0.94); }
.compare__range {
  position: absolute; inset: 0; z-index: 3; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; touch-action: pan-y;
  -webkit-appearance: none; appearance: none;
}
.compare:has(.compare__range:focus-visible) .compare__handle::after { outline: 2px solid var(--primary); outline-offset: 3px; }
/* Sin JS: el divisor no se puede mover; se ven las dos fotos, una tras otra */
html:not(.js) .compare { display: grid; gap: var(--space-sm); aspect-ratio: auto; background: none; }
html:not(.js) .compare__img, html:not(.js) .compare__img img { position: static; height: auto; aspect-ratio: 4 / 5; }
html:not(.js) .compare__img--after { clip-path: none; }
html:not(.js) .compare__handle, html:not(.js) .compare__range, html:not(.js) .compare__tag { display: none; }


@media (min-width: 48rem) {
  .compare { aspect-ratio: 4 / 3; }
  html:not(.js) .compare__img, html:not(.js) .compare__img img { aspect-ratio: 4 / 3; }
}
@media (min-width: 48rem) { .case__head { margin-bottom: var(--space-md); } }
@media (min-width: 64rem) {
  .case__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: var(--space-2xl); row-gap: var(--space-lg); align-items: start; }
  .case__head { grid-column: 1 / -1; }
  /* Alianza invertida: texto a la izquierda y comparador a la derecha, para alternar con Soluciones y Método */
  .case__visual { grid-column: 2; grid-row: 2; }
  /* Texto centrado respecto al comparador: el H2 ya ocupa todo el ancho encima */
  .case__info { grid-column: 1; grid-row: 2; align-self: center; }
}


/* Cierre: único CTA, bajo la descripción y junto al comparador */
.case__cierre { display: grid; gap: var(--space-md); justify-items: start; }
.case__cierre-texto { font-family: var(--font-display); font-size: var(--headline-sm); line-height: var(--headline-sm-lh); font-weight: 500; color: var(--charcoal); }
.cap-icon path { fill: none; stroke: var(--charcoal); stroke-width: 1.5; stroke-linecap: square; }
.cap-icon .cap-icon__accent { stroke: var(--primary); stroke-width: 2; }

/* ========== 13. FAQ ========== */

.faq__grid { display: grid; gap: var(--stack); }
.faq__intro { display: grid; gap: var(--space-md); align-content: start; }
.faq__note { max-width: 36ch; color: var(--text-muted); }
.faq__cta { justify-self: start; }
.faq__list { display: grid; gap: var(--space-sm); align-content: start; }
.faq__list details { padding-inline: var(--space-lg); border-left: 2px solid transparent; border-radius: var(--radius); background: var(--surface-subtle); transition: border-color var(--t-fast) ease; }
.faq__list details:hover, .faq__list details[open] { border-left-color: var(--primary); }
.faq__list summary {
  display: flex; justify-content: space-between; align-items: center; gap: var(--space-lg); padding-block: 1.25rem;
  font-family: var(--font-display); font-size: var(--headline-sm); line-height: var(--headline-sm-lh); font-weight: 600; color: var(--charcoal); cursor: pointer; list-style: none;
}
.faq__list summary::-webkit-details-marker { display: none; }
.faq__list summary::after {
  content: ""; flex: none; width: 0.875rem; height: 0.875rem;
  background: linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat, linear-gradient(currentColor, currentColor) center / 2px 100% no-repeat;
  transition: transform var(--t-base) var(--ease-out);
}
.faq__list details[open] summary::after { transform: rotate(135deg); }
.faq__list details p { padding-bottom: var(--space-lg); max-width: 62ch; }
@supports (interpolate-size: allow-keywords) {
  .faq__list { interpolate-size: allow-keywords; }
  .faq__list details::details-content { block-size: 0; overflow: hidden; transition: block-size var(--t-base) var(--ease-out), content-visibility var(--t-base) allow-discrete; }
  .faq__list details[open]::details-content { block-size: auto; }
}
@media (min-width: 60rem) {
  .faq__grid { grid-template-columns: repeat(12, 1fr); column-gap: var(--gutter); }
  .faq__intro { grid-column: 1 / 5; }
  .faq__list { grid-column: 6 / -1; }
}

/* ========== 14. Cierre y formulario ========== */

.closing__grid { display: grid; gap: var(--space-2xl) var(--gutter); }
.closing__main { display: grid; gap: var(--space-lg); justify-items: start; align-content: center; }
.closing__title { max-width: 18ch; font-size: var(--headline-lg); line-height: var(--headline-lg-lh); color: var(--white); }
@media (min-width: 60rem) {
  .closing__grid { grid-template-columns: repeat(12, 1fr); align-items: center; }
  .closing__main { grid-column: 1 / 6; }
  .callback { grid-column: 7 / -1; }
}
.callback { border: 1px solid var(--chrome-metallic); border-radius: var(--radius); background: var(--white); box-shadow: var(--elev-1); color: var(--text); }
.section--dark .callback h3, .callback__title { color: var(--heading); }
.callback__title { font-size: var(--headline-sm); line-height: var(--headline-sm-lh); font-weight: 600; letter-spacing: 0; }
.callback__toggle { display: flex; justify-content: space-between; align-items: center; gap: var(--space-lg); min-height: 3.5rem; padding: var(--space-md) var(--space-lg); border-radius: var(--radius); cursor: pointer; list-style: none; transition: background-color var(--t-press) var(--ease-out); }
.callback__toggle::-webkit-details-marker { display: none; }
.callback__toggle::after {
  content: ""; flex: none; width: 0.875rem; height: 0.875rem; color: var(--heading);
  background: linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat, linear-gradient(currentColor, currentColor) center / 2px 100% no-repeat;
  transition: transform var(--t-base) var(--ease-out), color var(--t-press) var(--ease-out);
}
.callback[open] .callback__toggle::after { transform: rotate(135deg); }
/* Con el puntero o el foco: fondo gris claro y «+» en rojo */
.callback__toggle:focus-visible { background: var(--surface-subtle); }
.callback__toggle:focus-visible::after { color: var(--primary); }
@media (hover: hover) {
  .callback__toggle:hover { background: var(--surface-subtle); }
  .callback__toggle:hover::after { color: var(--primary); }
}
/* 5. Apertura animada, como las respuestas del FAQ (280 ms); con movimiento reducido se abre sin transición */
@supports (interpolate-size: allow-keywords) {
  @media (prefers-reduced-motion: no-preference) {
    .callback { interpolate-size: allow-keywords; }
    .callback::details-content { block-size: 0; overflow: hidden; transition: block-size var(--t-base) var(--ease-out), content-visibility var(--t-base) allow-discrete; }
    .callback[open]::details-content { block-size: auto; }
  }
}
.callback .lead-form { padding: var(--space-sm) var(--space-lg) var(--space-lg); }
@media (min-width: 60rem) {
  .callback__toggle { padding-inline: var(--space-xl); }
  .callback .lead-form { padding: var(--space-sm) var(--space-xl) var(--space-xl); }
}
.field { display: grid; gap: var(--space-sm); align-content: start; }
.field label { color: var(--charcoal); }
.req { font-weight: 600; color: var(--text-muted); }
.field input, .field select {
  width: 100%; min-height: 3rem; padding: 0.75rem var(--space-md); border: 1px solid var(--chrome-metallic); border-radius: var(--radius); background: var(--white);
  font-family: var(--font-body); font-size: var(--body-md); line-height: var(--body-md-lh); color: var(--text); transition: border-color var(--t-fast) ease, box-shadow var(--t-fast) ease;
}
.field select {
  -webkit-appearance: none; appearance: none; padding-right: 2.75rem; cursor: pointer;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%232B2B2B' stroke-width='1.5' stroke-linecap='square' d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 0.75rem center / 1.25rem no-repeat;
}
.field ::placeholder { color: var(--placeholder); opacity: 1; }
.field input:hover, .field select:hover { border-color: var(--chrome-border); }
.field input:focus-visible, .field select:focus-visible { outline: none; border-color: var(--primary); box-shadow: 0 0 0 0.5px var(--primary); }
.field [aria-invalid="true"] { border-color: var(--error); box-shadow: 0 0 0 0.5px var(--error); }
.field__error { color: var(--error); font-size: var(--body-sm); line-height: var(--body-sm-lh); font-weight: 500; }
.lead-form { display: grid; gap: var(--space-lg); }
.lead-form__footer { display: grid; gap: var(--space-md); justify-items: start; }
.lead-form__status { font-weight: 500; }
.lead-form__status:empty { display: none; }
.lead-form__status.is-error { color: var(--error); }
.lead-form__legal { max-width: 60ch; font-size: var(--body-sm); line-height: var(--body-sm-lh); color: var(--text-muted); }
.error-summary { padding: var(--space-md) var(--space-lg); border: 1px solid var(--error); border-left-width: 2px; border-radius: var(--radius); background: var(--white); }
.error-summary:focus { outline: none; box-shadow: var(--elev-2); }
.error-summary h4 { margin: 0 0 var(--space-sm); font-size: var(--label-lg); line-height: 1.25rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--error); }
.error-summary ul { display: grid; gap: var(--space-xs); }
.error-summary a { color: var(--error); font-weight: 500; }
.error-summary[hidden] { display: none; }
@media (min-width: 48rem) {
  .lead-form { grid-template-columns: 1fr 1fr; column-gap: var(--gutter); }
  .field--wide, .lead-form__footer, .error-summary, .lead-form__legal { grid-column: 1 / -1; }
}

/* ========== 15. Pie y barra móvil ========== */

.site-footer { padding-block: var(--space-2xl) var(--space-xl); border-top: 1px solid var(--divider); background: var(--white); }
.site-footer__grid { display: grid; gap: var(--space-xl); }
.site-footer__sign { display: grid; gap: var(--space-md); justify-items: start; align-content: start; }
.site-footer__logo { width: min(11rem, 55vw); }
.site-footer__claim { max-width: 34ch; color: var(--text-muted); }
.site-footer__titulo { margin-bottom: var(--space-sm); font-family: var(--font-display); font-size: var(--label-md); line-height: 1rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--charcoal); }
.site-footer__lista { display: grid; }
/* 44 px de alto por enlace */
.site-footer__lista a { display: inline-flex; align-items: center; gap: 0.75rem; min-height: 2.75rem; color: var(--text); text-decoration: none; }
.site-footer__lista a:hover { text-decoration: underline; }
.site-footer__lista .icon { flex: none; width: 1.25rem; height: 1.25rem; color: var(--charcoal); }
.site-footer__dir { align-items: flex-start !important; padding-block: 0.625rem; }
.site-footer__legal { display: grid; gap: var(--space-xs); margin-top: var(--space-xl); padding-top: var(--space-lg); border-top: 1px solid var(--divider); font-size: var(--body-sm); line-height: var(--body-sm-lh); color: var(--text-muted); }
@media (max-width: 47.99rem) {
  .site-footer__nav .site-footer__lista { grid-template-columns: 1fr 1fr; column-gap: var(--gutter); }
}
@media (min-width: 48rem) {
  .site-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-footer__sign { grid-column: 1 / -1; }
}
@media (min-width: 60rem) {
  .site-footer__grid { grid-template-columns: 5fr 3fr 4fr; column-gap: var(--gutter); }
  .site-footer__sign { grid-column: auto; }
  .site-footer__legal { grid-template-columns: auto auto; justify-content: space-between; }
}
.wa-bar {
  position: fixed; inset: auto 0 0 0; z-index: 40; display: flex; gap: var(--space-sm);
  padding: 0.5rem var(--page-margin) calc(0.5rem + env(safe-area-inset-bottom));
  background: var(--white); border-top: 1px solid var(--chrome-metallic); transform: translateY(110%); transition: transform var(--t-fast) var(--ease-out);
}
.wa-bar__main { flex: 1; min-height: 2.75rem; }
.wa-bar__call { flex: none; width: 3rem; min-height: 2.75rem; padding: 0; }
/* Reserva el alto de la barra al final de la página para que nunca tape el último contenido */
@media (max-width: 59.99rem) { body { padding-bottom: calc(3.75rem + env(safe-area-inset-bottom)); } }
.wa-bar.is-visible { transform: none; transition-duration: var(--t-base); }
@media (min-width: 60rem) { .wa-bar { display: none; } }

/* ========== 16. Modo revisión ========== */

.pending, .review-only { display: none; }
.is-review .review-only { display: block; }
.is-review .pending {
  display: inline-block; margin-left: 0.4em; padding: 0.1em 0.45em; border-radius: var(--radius-sm); background: #FFD84D; color: var(--charcoal-dark);
  font-family: var(--font-display); font-size: var(--label-sm); font-weight: 700; line-height: 1.4; letter-spacing: 0.08em; text-transform: uppercase; vertical-align: 0.15em; cursor: help;
}
.is-review .pending::after { content: "por confirmar"; }
.review-panel {
  position: fixed; left: 1rem; bottom: 1rem; z-index: 60; display: flex; flex-wrap: wrap; gap: 0.25rem 1rem; max-width: calc(100% - 2rem);
  padding: 0.75rem 1rem; border-radius: var(--radius); background: var(--charcoal-dark); color: var(--white); box-shadow: var(--elev-3); font-size: var(--body-sm);
}
.review-panel[hidden] { display: none; }
.is-review .wa-bar { bottom: 3.5rem; }

/* ========== 17. Movimiento ==========
   El estado final es el por defecto: los estados ocultos solo existen con JS y sin movimiento reducido,
   y las animaciones ligadas al scroll (animation-timeline) solo donde el navegador las soporta; sin soporte,
   el contenido se ve completo y quieto. Solo se animan transform, opacity, clip-path y trazos SVG.
   Cada sección se mueve a su manera (ver docs/MOTION_DESIGN_V12.md):
   hero (la foto se descubre, se asienta y deriva al salir) · situaciones (cada esquema se dibuja y su acento
   rojo cuenta su caso) · soluciones (la foto se barre en el mismo marco) · caso (el comparador emerge desde abajo)
   · proceso (la lámina fija
   cambia de capa con la etapa) · secciones oscuras (el campo se abre con el scroll). */

@media (prefers-reduced-motion: no-preference) {
  .js .hero__media { animation: unveil 700ms var(--ease-out) both; }
  .js .hero__media > picture img { animation: settle 700ms var(--ease-out) both; }
  .js .hero__text > * { animation: rise 700ms var(--ease-out) both; }
  .js .hero__text > :nth-child(2) { animation-delay: 30ms; }
  .js .hero__text > :nth-child(3) { animation-delay: 60ms; }
  .js .hero__text > :nth-child(4) { animation-delay: 90ms; }
  .js .hero__text > :nth-child(5) { animation-delay: 120ms; }

  .js .drawing path:not(.dash):not(.grow) { stroke-dasharray: 1; stroke-dashoffset: 0; transition: stroke-dashoffset 1100ms var(--ease-in-out); }
  .js .drawing .accent path:not(.dash):not(.grow) { transition-delay: 450ms; transition-duration: 700ms; }
  .js .drawing .dash { transition: opacity 400ms ease 800ms; }
  .js [data-reveal="draw"]:not(.is-in) .drawing path:not(.dash):not(.grow) { stroke-dashoffset: 1; }
  .js [data-reveal="draw"]:not(.is-in) .drawing .dash, .js [data-reveal="draw"]:not(.is-in) .drawing .grow { opacity: 0; }
  .js .drawing .grow { transition: opacity 400ms ease 900ms, transform var(--t-scene) var(--ease-out); }
  /* Situaciones: línea de tiempo común de las 3 tarjetas. Trazo 0 + 900 ms; acento 300 + 700 ms; detalle y fecha 1100 + 400 ms */
  .js .need:nth-child(n) .drawing .ink path { transition: stroke-dashoffset 900ms var(--ease-in-out); }
  .js .need:nth-child(n) .drawing .accent path:not(.dash):not(.grow):not(.fecha) { transition: stroke-dashoffset 700ms var(--ease-in-out) 300ms; }
  .js .need:nth-child(n) .drawing .accent path.fecha { transition: stroke-dashoffset 400ms var(--ease-out) 1100ms; }
  .js .need:nth-child(n) .drawing .grow { transition: opacity 400ms var(--ease-out) 1100ms; }

  /* Pestañas: el panel entra con fundido y una subida corta (la foto se barre: ver más abajo) */
  .js .tabs__panels > [role="tabpanel"] { transition: opacity var(--t-base) ease, visibility 0s linear var(--t-base); }
  .js .tabs__panels > [role="tabpanel"].is-active { transition: opacity var(--t-scene) ease, visibility 0s; }
  .js .solution-panel.is-active .solution__body { animation: rise 200ms var(--ease-out) both; }


  /* Caso: al entrar, el divisor hace un recorrido corto que enseña que se puede mover (una vez) */
  .js .compare.is-hint .compare__img--after { transition: clip-path 900ms var(--ease-in-out); }
  .js .compare.is-hint .compare__handle { transition: left 900ms var(--ease-in-out); }
  .js .viewer__view.is-active .details img { animation: settle-sm 700ms var(--ease-out) both; }

  /* Filas que llegan una a una */
  .js [data-reveal="rows"] > * { transition: opacity 500ms var(--ease-out), transform 500ms var(--ease-out); }
  .js [data-reveal="rows"]:not(.is-in) > * { opacity: 0; transform: translateY(10px); }
  .js [data-reveal="rows"] > :nth-child(2) { transition-delay: 60ms; }
  .js [data-reveal="rows"] > :nth-child(3) { transition-delay: 120ms; }
  .js [data-reveal="rows"] > :nth-child(4) { transition-delay: 180ms; }
  .js [data-reveal="rows"] > :nth-child(5) { transition-delay: 240ms; }
}


/* Situaciones: el acento rojo de cada esquema cuenta su caso después del trazo */
@media (prefers-reduced-motion: no-preference) {
  .js .need .accent .dash { transform-box: fill-box; transition: opacity 400ms var(--ease-out) 1100ms, transform 400ms var(--ease-out) 1100ms; }
  .js .need:nth-child(1):not(.is-in) .accent .dash { transform: translateX(18px); }   /* puestos que intentan entrar */
  .js .need:nth-child(3):not(.is-in) .accent .dash { transform: scale(0.9); }          /* muebles que se proponen en el plano */

  /* Soluciones: la foto se barre al entrar en pantalla (no al cargar) y en cada cambio de pestaña */
  .js [data-reveal="sol"]:not(.is-in) .solution-panel.is-active .solution__media { clip-path: inset(0 100% 0 0); }
  .js [data-reveal="sol"].is-in .solution-panel.is-active .solution__media { animation: barrido 260ms var(--ease-in-out) both; }
}

@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    /* Hero: al salir, la foto deriva y crece muy poco (profundidad); no afecta a la carga ni al LCP */
    /* (línea de tiempo con nombre: .hero__media recorta con overflow y sería su propio contenedor de scroll) */
    .js .hero__media { view-timeline: --hero block; }
    .js .hero__media > picture { animation: deriva linear both; animation-timeline: --hero; animation-range: exit 0% exit 100%; }
    /* Caso: el comparador emerge desde abajo al entrar (solo mientras entra; luego queda libre para arrastrar) */
    .js .case__visual { animation: emerge linear both; animation-timeline: view(); animation-range: entry 0% entry 55%; }
    .js .case__info > * { animation: sube linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
  }
}

/* Cambio de clima: el campo carbón se abre a todo el ancho con el scroll (solo CSS) */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .section--dark { animation: field-open linear both; animation-timeline: view(); animation-range: entry 0% entry 70%; }
  }
}

@keyframes deriva { to { transform: translateY(3%) scale(1.06); } }
@keyframes emerge { from { clip-path: inset(0 0 22% 0 round var(--radius)); transform: translateY(2rem); } to { clip-path: inset(0 round var(--radius)); transform: none; } }
@keyframes sube { from { transform: translateY(0.75rem); } to { transform: none; } }  /* solo posición: el texto nunca pierde contraste */
@keyframes barrido { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0); } }
@keyframes unveil { from { clip-path: inset(6% 0 0 0); } to { clip-path: inset(0); } }
@keyframes settle { from { transform: scale(1.04); } }
@keyframes settle-sm { from { transform: scale(1.04); } }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }
@keyframes field-open { from { clip-path: inset(0 var(--page-margin) round var(--radius)); } to { clip-path: inset(0 0 round 0); } }

/* Proceso: entrada de cada tarjeta */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal="paso"] { transition: opacity 400ms var(--ease-out), transform 400ms var(--ease-out); }
  .js [data-reveal="paso"]:not(.is-in) { opacity: 0; transform: translateY(12px); }
}

/* FAQ: las preguntas suben 12 px una a una al llegar (400 ms, 60 ms entre preguntas); el borde rojo conserva su transición */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal="faq"] > details { transition: border-color var(--t-fast) ease, opacity 400ms var(--ease-out), transform 400ms var(--ease-out); }
  .js [data-reveal="faq"]:not(.is-in) > details { opacity: 0; transform: translateY(12px); }
  .js [data-reveal="faq"].is-in > :nth-child(2) { transition-delay: 0ms, 60ms, 60ms; }
  .js [data-reveal="faq"].is-in > :nth-child(3) { transition-delay: 0ms, 120ms, 120ms; }
  .js [data-reveal="faq"].is-in > :nth-child(4) { transition-delay: 0ms, 180ms, 180ms; }
  .js [data-reveal="faq"].is-in > :nth-child(5) { transition-delay: 0ms, 240ms, 240ms; }
  .js [data-reveal="faq"].is-in > :nth-child(6) { transition-delay: 0ms, 300ms, 300ms; }
  .js [data-reveal="faq"].is-in > :nth-child(7) { transition-delay: 0ms, 360ms, 360ms; }
}

/* ===== Bloque 3 ===== */
/* WhatsApp: el icono avanza 2 px con el puntero; el texto queda quieto. Solo con ratón o trackpad */
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .btn .icon:has(use[href="#i-whatsapp"]) { transition: transform var(--t-press) var(--ease-out); }
  .btn:hover .icon:has(use[href="#i-whatsapp"]) { transform: translateX(2px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; transition-delay: 0ms !important; }
  .section--dark { animation: none; }
}

/* Comparador: control nativo de 1 px para que el valor coincida con la posición del puntero
   (con el control por defecto, de ~16 px, el divisor quedaba hasta 2 puntos desplazado del dedo). */
.compare__range::-webkit-slider-runnable-track { height: 100%; background: none; border: 0; }
.compare__range::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 1px; height: 100%; background: none; border: 0; }
.compare__range::-moz-range-track { height: 100%; background: none; border: 0; }
.compare__range::-moz-range-thumb { width: 1px; height: 100%; background: none; border: 0; border-radius: 0; }
/* El arrastre lo gestiona el contenedor (eventos de puntero); el rango nativo queda para teclado y lectores */
.compare { touch-action: pan-y; cursor: ew-resize; user-select: none; -webkit-user-select: none; }
.compare__img img { -webkit-user-drag: none; }
.compare__range { pointer-events: none; }
/* El tirador no se sale del marco en los extremos: la línea sigue en la posición real y el
   botón se desplaza hacia dentro lo justo (unidades de contenedor). */
.compare { container-type: inline-size; }
.compare__handle::after {
  left: calc(50% + max(0px, 1.375rem - var(--pos-n, 50) * 1cqi) - max(0px, 1.375rem - (100 - var(--pos-n, 50)) * 1cqi));
}

/* ========== 18. Ciclo v15: titulares, formulario y consentimiento ========== */

/* E1 · Hero: cada palabra sube desde su máscara. Solo CSS, desde el primer pintado (D1): el H1 no espera a JS.
   La máscara es la propia caja de línea de la palabra; overflow-clip-margin deja respirar los descendentes. */
.palabra { display: inline-block; overflow: clip; overflow-clip-margin: 0.1em; vertical-align: top; }
.palabra > span { display: inline-block; }
@media (prefers-reduced-motion: no-preference) {
  .js .hero__text > .hero__title { animation: none; } /* el H1 deja la subida común del hero y usa la suya */
  .hero__title .palabra > span { animation: palabra 640ms var(--ease-out) both; }
  .hero__title .palabra:nth-child(2) > span { animation-delay: 45ms; }
  .hero__title .palabra:nth-child(3) > span { animation-delay: 90ms; }
  .hero__title .palabra:nth-child(4) > span { animation-delay: 135ms; }
  .hero__title .palabra:nth-child(5) > span { animation-delay: 180ms; }
}
/* Fase 3 · por debajo de 360 px el H1 es el LCP: se pinta estático con el primer pintado (core-web-vitals) */
@media (max-width: 22.49rem) { .hero__title .palabra > span { animation: none; } }
@keyframes palabra { from { transform: translateY(105%); } }

/* E2–E5 · Por qué FAMAT (H2 y tres H3), Método (H2 y lead) y Cierre (H2); E5 (Fase 1c): H2 de Necesidades, Soluciones y Alianza.
   FAQ, cuerpo de texto y cifras del hero no se animan. Mismo patrón que E1, sin JS de animación (Fase 1b):
   las palabras esperan bajo su máscara solo con .js y sin .is-in; las suelta el IntersectionObserver de main.js, una vez.
   Sin JS o con movimiento reducido no hay transform: el texto se lee completo desde el primer pintado. */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal="titular"] .palabra > span,
  .js [data-reveal="ventajas"] h3 .palabra > span { transition: transform 600ms var(--ease-out), opacity 300ms var(--ease-out); }
  .js [data-reveal="titular"]:not(.is-in) .palabra > span,
  .js [data-reveal="ventajas"]:not(.is-in) h3 .palabra > span { transform: translateY(105%); opacity: 0; }
  /* nth-child empieza en 2: el primer hijo del H2 es .etiqueta. 80 ms entre palabras; el Cierre, más largo, 40 ms y 560 ms */
  .js [data-reveal="titular"] .palabra:nth-child(3) > span { transition-delay: 80ms; }
  .js [data-reveal="titular"] .palabra:nth-child(4) > span { transition-delay: 160ms; }
  .js [data-reveal="titular"] .palabra:nth-child(5) > span { transition-delay: 240ms; }
  .js [data-reveal="titular"] .palabra:nth-child(6) > span { transition-delay: 320ms; }
  .js [data-reveal="titular"] .palabra:nth-child(7) > span { transition-delay: 400ms; }
  .js [data-reveal="titular"] .palabra:nth-child(8) > span { transition-delay: 480ms; } /* Alianza: 7 palabras */
  .js [data-reveal="titular"] .palabra:nth-child(9) > span { transition-delay: 560ms; }
  .js [data-reveal="titular"] .palabra:nth-child(10) > span { transition-delay: 640ms; } /* Necesidades: 8 palabras */
  .js #closing-title .palabra > span { transition-duration: 560ms, 300ms; }
  .js #closing-title .palabra:nth-child(3) > span { transition-delay: 40ms; }
  .js #closing-title .palabra:nth-child(4) > span { transition-delay: 80ms; }
  .js #closing-title .palabra:nth-child(5) > span { transition-delay: 120ms; }
  .js #closing-title .palabra:nth-child(6) > span { transition-delay: 160ms; }
  /* Lead de Método: aparece tras la primera palabra */
  .js #process-title + .section-lead { transition: opacity 300ms ease 250ms; }
  .js #process-title:not(.is-in) + .section-lead { opacity: 0; }
  /* H3 de las ventajas: entran con su texto (600 ms) y 100 ms entre ellas, como el trazado de los iconos */
  .js [data-reveal="ventajas"] li:nth-child(1) h3 .palabra > span { --d: 600ms; }
  .js [data-reveal="ventajas"] li:nth-child(2) h3 .palabra > span { --d: 700ms; }
  .js [data-reveal="ventajas"] li:nth-child(3) h3 .palabra > span { --d: 800ms; }
  .js [data-reveal="ventajas"] h3 .palabra > span { transition-delay: var(--d); }
  .js [data-reveal="ventajas"] h3 .palabra:nth-child(2) > span { transition-delay: calc(var(--d) + 80ms); }
  .js [data-reveal="ventajas"] h3 .palabra:nth-child(3) > span { transition-delay: calc(var(--d) + 160ms); }
  .js [data-reveal="ventajas"] h3 .palabra:nth-child(4) > span { transition-delay: calc(var(--d) + 240ms); }
  .js [data-reveal="ventajas"] h3 .palabra:nth-child(5) > span { transition-delay: calc(var(--d) + 320ms); }
}

/* Formulario: campo trampa, envío fallido con enlace y mensaje de éxito */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.lead-form[hidden], .lead-exito[hidden] { display: none; }
.lead-form__status a { color: inherit; font-weight: 600; }
.lead-exito { display: grid; gap: var(--space-sm); padding: var(--space-sm) var(--space-lg) var(--space-lg); }
.lead-exito__titulo { font-family: var(--font-display); font-size: var(--headline-sm); line-height: var(--headline-sm-lh); font-weight: 600; color: var(--heading); }
.lead-exito__titulo:focus:not(:focus-visible) { outline: none; }
.lead-exito__tel { font-weight: 600; color: var(--heading); font-variant-numeric: tabular-nums; white-space: nowrap; }
.lead-exito__wa { color: var(--text-muted); }
.lead-exito__wa a { color: var(--text); font-weight: 500; }
@media (min-width: 60rem) { .lead-exito { padding: var(--space-sm) var(--space-xl) var(--space-xl); } }

/* Consentimiento (D3): barra inferior fija y no modal. «Aceptar» y «Rechazar» con el mismo peso visual.
   En móvil sube por encima de la barra de WhatsApp con transform (sin desplazar el layout ni sumar CLS). */
.consent {
  position: fixed; inset: auto 0 0 0; z-index: 60;
  padding: var(--space-md) var(--page-margin) calc(var(--space-md) + env(safe-area-inset-bottom));
  background: var(--white); border-top: 1px solid var(--chrome-metallic); box-shadow: 0 -6px 16px -2px rgba(30, 30, 30, 0.12);
  transition: transform var(--t-fast) var(--ease-out);
}
.consent[hidden] { display: none; }
.consent:not([hidden]) { animation: consent-in 200ms ease-out both; } /* fundido: además evita que su texto sea candidato a LCP */
@keyframes consent-in { from { opacity: 0; } }
.consent__inner { display: grid; gap: var(--space-md); max-width: var(--max); margin-inline: auto; }
.consent__titulo { margin-bottom: var(--space-xs); font-family: var(--font-display); font-size: var(--label-lg); line-height: 1.25rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--heading); }
.consent__texto p { max-width: 72ch; font-size: var(--body-sm); line-height: var(--body-sm-lh); color: var(--text); }
.consent__texto a { color: var(--text); font-weight: 500; text-decoration: underline; }
.consent__acciones { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-sm); }
.consent__btn { min-height: 2.75rem; }
@media (max-width: 59.99rem) {
  body:has(.wa-bar.is-visible) .consent { transform: translateY(calc(-3.75rem - env(safe-area-inset-bottom))); }
}
@media (min-width: 48rem) {
  .consent__inner { grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: var(--space-xl); }
  .consent__acciones { grid-template-columns: auto auto; }
  .consent__btn { min-width: 8.5rem; }
}

/* Pie: política y preferencias de cookies (el botón solo aparece con JS) */
.site-footer__privacidad { display: flex; flex-wrap: wrap; gap: var(--space-xs) var(--space-lg); }
.site-footer__privacidad a, .consent-abrir { display: inline-flex; align-items: center; min-height: 1.5rem; color: var(--text-muted); text-decoration: underline; }
.consent-abrir { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
.consent-abrir[hidden] { display: none; }
.consent-abrir:hover, .site-footer__privacidad a:hover { color: var(--text); }

/* Páginas auxiliares (/gracias/, /politica-de-privacidad/) */
.aux { display: grid; align-content: center; gap: var(--space-lg); min-height: 70vh; padding-block: var(--space-2xl); }
.aux__titulo { max-width: 20ch; font-size: var(--headline-lg); line-height: var(--headline-lg-lh); color: var(--heading); }
.aux p { max-width: 56ch; color: var(--text); }
.aux__acciones { display: flex; flex-wrap: wrap; gap: var(--space-md); align-items: center; }

/* Feedback de Andrea (2026-11-21): bloques ocultos hasta que FAMAT resuelva su pendiente.
   Se ocultan sin borrarlos del DOM; para reactivar un bloque basta con quitar su data-oculto. */
[data-oculto] { display: none !important; }
@media (min-width: 60rem) {
  .closing__grid:has(> .callback[data-oculto]) .closing__main { grid-column: 1 / 9; }
}
