/* ============================================================
   AGRIBOX — cinematic industrial
   Palette: navy #17283B (video-matched) · maíz #F2B233 · agave #7FC6A6
   Type: Big Shoulders Display (condensed industrial) · Archivo · IBM Plex Mono
   ============================================================ */

:root {
  --navy:       #17283B;
  --navy-deep:  #0E1A29;
  --navy-ink:   #0A1420;
  --bone:       #F2EFE6;
  --paper:      #EDE9DD;
  --maiz:       #F2B233;
  --agave:      #7FC6A6;
  --line:       rgba(242, 239, 230, 0.14);
  --line-soft:  rgba(242, 239, 230, 0.08);
  --txt:        #EFEDE4;
  --txt-dim:    rgb(238, 236, 227);
  --focus-ring: var(--maiz);
  --display: "Big Shoulders Display", "Big Shoulders", "Arial Narrow", sans-serif;
  --sans: "Archivo", "Helvetica Neue", sans-serif;
  --mono: "IBM Plex Mono", "SF Mono", monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scrollbar-color: var(--maiz) var(--navy-ink); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  background: var(--navy);
  color: var(--txt);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

/* ============ FOCUS VISIBLE (teclado) ============ */
:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
  border-radius: 4px;
}
/* anillo visible sobre fondos maíz/agave */
.nav-cta:focus-visible, .btn-submit:focus-visible { outline-color: var(--txt); }
#custom :focus-visible { outline-color: #256f42; }
#quote-form input:focus-visible {
  outline: none; border-radius: 0;
  border-color: var(--maiz);
  box-shadow: 0 1px 0 0 var(--maiz);
}

/* ============ SKIP LINK ============ */
.skip-link {
  position: fixed; top: 0.9rem; left: 50%; z-index: 110;
  transform: translate(-50%, -300%);
  background: var(--maiz); color: var(--navy-ink);
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.18em;
  padding: 0.7rem 1.3rem; border-radius: 999px; text-decoration: none;
  transition: transform 0.25s ease;
}
.skip-link:focus-visible { transform: translate(-50%, 0); }

/* ============ VOLVER ARRIBA ============ */
/* oculto por defecto: sin JS nunca recibe .is-visible y no estorba */
.to-top {
  position: fixed; z-index: 70;
  right: clamp(1rem, 3vw, 2rem); bottom: clamp(1rem, 3vw, 2rem);
  display: grid; place-items: center;
  width: 46px; height: 46px;
  border: 0; border-radius: 50%;
  background: var(--maiz); color: var(--navy-ink);
  cursor: pointer;
  opacity: 0; transform: translateY(12px); pointer-events: none;
  transition: opacity 0.3s, transform 0.3s, background 0.25s, box-shadow 0.25s;
}
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--agave); box-shadow: 0 10px 28px -10px rgba(127, 198, 166, 0.55); }
.to-top:active { transform: scale(0.94); }
.to-top svg { display: block; width: 20px; height: 20px; }
/* el modal manda: nada flota sobre él */
body.modal-open .to-top { opacity: 0; pointer-events: none; }

.mono { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.14em; }

/* ---------- shared type ---------- */
.eyebrow {
  color: var(--agave);
  font-size: 0.68rem;
  letter-spacing: 0.32em;
  margin-bottom: 1.4rem;
}

.display-xl, .display-l {
  font-family: var(--display);
  font-weight: 800;
  text-transform: uppercase;
  line-height: 0.92;
  letter-spacing: 0.005em;
}
.display-xl { font-size: clamp(3.4rem, 9.5vw, 9rem); }
.display-l  { font-size: clamp(2.4rem, 5.6vw, 4.6rem); }

.text-maiz { color: var(--maiz); }
.case-normal { text-transform: none; }

.stroke-text { color: var(--maiz); }

.underline-accent {
  background-image: linear-gradient(var(--maiz), var(--maiz));
  background-repeat: no-repeat;
  background-size: 100% 0.09em;
  background-position: 0 92%;
}

/* ============ LOADER ============ */
#loader {
  position: fixed; inset: 0; z-index: 100;
  background: var(--navy-ink);
  display: grid; place-items: center;
  transition: opacity 0.7s ease, visibility 0.7s;
}
#loader.done { opacity: 0; visibility: hidden; }
.loader-inner { text-align: center; width: min(420px, 80vw); }
.loader-logo { width: 128px; margin: 0 auto 2.2rem; }
.loader-count {
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(4rem, 12vw, 7rem);
  line-height: 1;
  color: var(--txt);
}
.loader-count::after { content: "%"; font-size: 0.35em; color: var(--maiz); vertical-align: super; }
.loader-bar {
  height: 2px; background: var(--line);
  margin: 1.6rem 0 1rem; overflow: hidden;
}
#loader-fill {
  display: block; height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--agave), var(--maiz));
  transition: width 0.2s ease;
}
.loader-tag { font-family: var(--mono); font-size: 0.65rem; letter-spacing: 0.3em; color: var(--txt-dim); text-transform: uppercase; }
.loader-dev {
  position: fixed; bottom: 1rem; left: 1rem; z-index: 200;
  padding: 0.45rem 0.75rem;
  background: rgba(14, 26, 41, 0.92);
  border: 1px solid var(--line-soft);
  border-radius: 4px;
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  color: var(--agave);
}
.loader-dev[hidden] { display: none; }

/* ============ NAV ============ */
#nav {
  position: fixed; z-index: 50;
  top: clamp(0.8rem, 2vw, 1.3rem);
  left: clamp(0.8rem, 3vw, 1.6rem);
  right: clamp(0.8rem, 3vw, 1.6rem);
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  padding: 0.5rem 0.5rem 0.5rem clamp(1rem, 3vw, 1.6rem);
  border-radius: 999px;
  border: 1px solid var(--line-soft);
  background: rgba(10, 20, 32, 0.34);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  transition: background 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}
/* estado sólido al salir del hero — legible sobre secciones claras */
#nav.scrolled {
  background: rgba(10, 20, 32, 0.82);
  border-color: var(--line);
  box-shadow: 0 18px 42px -26px rgba(0, 0, 0, 0.75);
}
.nav-logo { position: relative; display: inline-flex; }
.nav-logo img { height: 34px; }
.nav-links {
  display: none;
  align-items: center;
  gap: clamp(0.9rem, 2vw, 1.8rem);
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 960px) {
  /* centrado absoluto dentro de la píldora, entre logo y CTA */
  .nav-links { display: flex; position: absolute; left: 50%; transform: translateX(-50%); }
}
.nav-links a {
  display: inline-flex; align-items: center;
  min-height: 44px;
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: 1rem; letter-spacing: 0.06em;
  color: var(--maiz);
  text-decoration: none;
  transition: color 0.25s, text-shadow 0.25s;
}
.nav-links a:hover {
  color: var(--agave);
  text-shadow: 0 6px 22px rgba(127, 198, 166, 0.45);
}
.nav-links a:active { transform: scale(0.97); }

/* --- submenú de Productos (escritorio) -------------------------------
   Sin JavaScript: abre con :hover y con :focus-within, así el teclado lo
   alcanza tabulando igual que el ratón. El panel cuelga de un <li>
   relativo y sale de la píldora porque #nav no recorta su contenido.   */
.nav-has-sub { position: relative; }
.nav-has-sub > a { gap: 0.45em; }
.nav-chev {
  width: 0.6em; height: 0.6em;
  fill: none; stroke: currentColor; stroke-width: 2.8;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform 0.25s ease;
}
.nav-has-sub:hover .nav-chev,
.nav-has-sub:focus-within .nav-chev { transform: rotate(180deg); }

.nav-sub {
  position: absolute; top: calc(100% + 0.6rem); left: 50%;
  margin: 0; padding: 0.4rem 0;
  list-style: none;
  min-width: max-content;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(10, 20, 32, 0.94);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 18px 42px -26px rgba(0, 0, 0, 0.8);
  transform: translateX(-50%) translateY(-6px);
  opacity: 0; visibility: hidden;
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s linear 0.22s;
}
/* Puente invisible sobre el hueco entre la píldora y el panel: sin él el
   puntero cruza aire, se pierde el :hover y el menú se cierra a medio camino. */
.nav-sub::before {
  content: ""; position: absolute;
  left: 0; right: 0; bottom: 100%; height: 0.6rem;
}
.nav-has-sub:hover .nav-sub,
.nav-has-sub:focus-within .nav-sub {
  opacity: 1; visibility: visible;
  transform: translateX(-50%) translateY(0);
  transition: opacity 0.22s ease, transform 0.22s ease;
}
/* Mono, como los eyebrow de las secciones: se lee como un nivel por debajo
   del menú, no como otro enlace principal. */
.nav-sub a {
  display: flex; align-items: center;
  min-height: 38px;
  padding: 0 1.2rem;
  font-family: var(--mono); font-weight: 500; text-transform: uppercase;
  font-size: 0.68rem; letter-spacing: 0.14em;
  white-space: nowrap;
}
.nav-sub a:hover { text-shadow: none; }

/* --- hamburguesa (solo móvil) --- */
.nav-burger {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px;
  margin: 0; padding: 0;
  background: none; border: 0;
  color: var(--maiz);
  cursor: pointer;
  transition: color 0.25s;
}
.nav-burger:hover { color: var(--agave); }
.nav-burger svg { display: block; }
.nav-burger .bl {
  stroke: currentColor; stroke-width: 2.2; stroke-linecap: round;
  transform-box: fill-box; transform-origin: center;
  transition: transform 0.25s, opacity 0.2s;
}
.nav-burger.open .bl-1 { transform: translateY(5px) rotate(45deg); }
.nav-burger.open .bl-2 { opacity: 0; }
.nav-burger.open .bl-3 { transform: translateY(-5px) rotate(-45deg); }
@media (min-width: 960px) { .nav-burger { display: none; } }
.no-js .nav-burger { display: none; }

/* --- menú móvil (overlay bajo la píldora del nav) --- */
.mobile-menu {
  position: fixed; inset: 0; z-index: 40;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2.4rem;
  background: rgba(14, 26, 41, 0.97);
  opacity: 0; visibility: hidden;
  transition: opacity 0.25s ease, visibility 0s linear 0.25s;
}
.mobile-menu.open {
  opacity: 1; visibility: visible;
  transition: opacity 0.25s ease;
}
.mobile-links {
  margin: 0; padding: 0;
  list-style: none;
  display: flex; flex-direction: column; align-items: center; gap: 1.1rem;
}
.mobile-links a {
  display: inline-flex; align-items: center;
  min-height: 44px;
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: clamp(1.9rem, 8vw, 2.6rem); letter-spacing: 0.05em;
  color: var(--maiz);
  text-decoration: none;
  transition: color 0.25s;
}
.mobile-links a:hover { color: var(--agave); }
.mobile-links a:active { transform: scale(0.97); }

/* En móvil el submenú no se pliega: es un solo enlace y un acordeón para
   un elemento estorba más de lo que ayuda. Va anidado y a la vista. */
.mobile-links > li {
  display: flex; flex-direction: column; align-items: center; gap: 0.2rem;
}
.mobile-sub {
  margin: 0; padding: 0;
  list-style: none;
  display: flex; flex-direction: column; align-items: center; gap: 0.2rem;
}
.mobile-sub a {
  min-height: 40px;
  font-family: var(--mono); font-weight: 500;
  font-size: clamp(0.72rem, 3vw, 0.86rem); letter-spacing: 0.16em;
  color: var(--txt-dim);
}
.mobile-sub a:hover { color: var(--agave); }
@media (min-width: 960px) { .mobile-menu { display: none; } }

.nav-cta {
  position: relative;
  display: inline-flex; align-items: center;
  min-height: 44px;
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: 1.05rem; letter-spacing: 0.06em;
  color: var(--navy-ink);
  background: var(--maiz);
  padding: 0.4rem 1.5rem 0.5rem;
  border-radius: 999px;
  text-decoration: none;
  transition: background 0.25s, box-shadow 0.25s, transform 0.25s;
}
.nav-cta:hover {
  background: var(--agave);
  box-shadow: 0 10px 28px -10px rgba(127, 198, 166, 0.55);
}
.nav-cta:active { transform: scale(0.97); }

/* ============ PROGRESS ============ */
#progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 60;
  pointer-events: none;
}
#progress-fill {
  display: block; height: 100%; width: 100%;
  background: linear-gradient(90deg, var(--agave), var(--maiz));
  transform: scaleX(0); transform-origin: left;
}

/* ============ HERO SCRUB ============ */
#hero-scrub { height: 520vh; position: relative; }

@media (max-width: 719px) {
  #hero-scrub { height: 320vh; }
}
.sticky-vp {
  position: sticky; top: 0; height: 100vh; height: 100svh;
  overflow: hidden;
}
#orbit-canvas {
  position: absolute; inset: 0; width: 100%; height: 100%;
  display: block;
}
.vignette {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 120% 90% at 50% 45%, transparent 55%, rgba(10, 20, 32, 0.55) 100%),
    linear-gradient(180deg, rgba(10, 20, 32, 0.35) 0%, transparent 22%, transparent 75%, rgba(10, 20, 32, 0.5) 100%);
}
.vignette.strong {
  background:
    radial-gradient(ellipse 110% 85% at 50% 45%, transparent 40%, rgba(10, 20, 32, 0.75) 100%),
    linear-gradient(180deg, rgba(10, 20, 32, 0.4) 0%, transparent 25%, transparent 70%, rgba(10, 20, 32, 0.6) 100%);
}

/* velo de apertura del hero — JS lo desvanece al salir el logo (frame ~10) */
.hero-overlay {
  position: absolute; inset: 0;
  background: rgba(14, 26, 41, 0.88);
  pointer-events: none;
}

.stage {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  pointer-events: none;
  padding: 0 1.5rem;
}

/* Stage A — wordmark */
.stage-a .eyebrow { margin-bottom: 0.6rem; }
.wordmark {
  margin: 0;
  line-height: 0.9;
}
.wordmark-logo {
  display: block;
  width: clamp(13rem, 38vw, 30rem);
  height: auto;
  filter: drop-shadow(0 10px 60px rgba(10, 20, 32, 0.8));
}
@media (min-width: 960px) {
  /* desktop: wordmark al 200% */
  .wordmark-logo { width: clamp(26rem, 76vw, 60rem); }
}
.hero-sub {
  margin-top: 1.2rem;
  font-size: clamp(1rem, 1.6vw, 1.3rem);
  font-weight: 500;
  color: var(--txt-dim);
  line-height: 1.4;
}

/* Stage B — model lockup */
.stage-b { align-items: flex-start; text-align: left; justify-content: flex-end; padding: 0 clamp(1.5rem, 6vw, 6rem) 14vh; }
/* scrim de legibilidad: oscurece el fondo detrás del texto sin tapar la caja */
.stage-b::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(10, 20, 32, 0.72) 0%, rgba(10, 20, 32, 0.45) 30%, transparent 58%);
  pointer-events: none;
  z-index: -1;
}
.model-name {
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: clamp(2rem, 5vw, 4.4rem); line-height: 0.94;
}
.model-tag { margin-top: 0.8rem; color: var(--agave); font-weight: 500; }

/* Stage D — features empresa (aparece ~frame 24) */
/* misma línea base que stage B: ambos bloques anclan al borde inferior */
.stage-d { align-items: flex-end; text-align: right; justify-content: flex-end; padding: 0 clamp(1.5rem, 6vw, 6rem) 14vh; }
/* Scrim de stage D — vive fuera de .stage-d porque backdrop-filter deja de
   funcionar cuando un ancestro tiene opacity animada. JS interpola --sd (0-1)
   y el radio del blur, así el efecto entra con "POR QUÉ AGRIBOX" y no antes.
   La máscara limita oscuridad y desenfoque al costado del texto. */
.stage-d-scrim {
  --sd: 0;
  position: absolute; inset: 0;
  background: rgba(10, 20, 32, calc(0.85 * var(--sd)));
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
  -webkit-mask-image: linear-gradient(270deg, #000 0%, rgba(0, 0, 0, 0.8) 35%, transparent 65%);
  mask-image: linear-gradient(270deg, #000 0%, rgba(0, 0, 0, 0.8) 35%, transparent 65%);
  pointer-events: none;
}
/* sin filetes: el ritmo lo da el gap, no una línea */
.feature-list { display: grid; gap: clamp(1.1rem, 2.2vh, 1.7rem); max-width: 300px; }
.stage-d .eyebrow { margin-bottom: 0.15rem; }
/* copy a la izquierda, icono en el riel derecho (alineado al margen) */
.feature { display: grid; grid-template-columns: 1fr auto; align-items: start; gap: clamp(0.85rem, 1.5vw, 1.25rem); }
.feature-icon {
  flex: none; display: block; margin-top: 0.1rem;
  width: clamp(1.7rem, 2.4vw, 2.15rem); height: clamp(1.7rem, 2.4vw, 2.15rem);
  color: var(--agave);
  filter: drop-shadow(0 0 16px rgba(127, 198, 166, 0.5));
}
.feature-icon svg { width: 100%; height: 100%; display: block; }
.feature strong {
  display: block;
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: clamp(1.6rem, 2.6vw, 2.3rem); line-height: 0.95; letter-spacing: 0.02em;
  color: var(--maiz);
}
/* mismo tratamiento que .model-tag ("Una caja. Toda la cosecha.") */
.feature em {
  font-style: normal; display: block; margin-top: 0.4rem;
  font-size: clamp(0.85rem, 1.2vw, 1rem); line-height: 1.45;
  font-weight: 500;
  color: var(--agave);
}
/* en móvil el bloque vuelve arriba: abajo chocaría con el lockup de stage B */
@media (max-width: 719px) {
  .stage-d { justify-content: flex-start; padding: 13vh clamp(1.5rem, 6vw, 6rem) 0; }
  /* en móvil el texto vive arriba: el scrim baja desde el borde superior */
  .stage-d-scrim {
    -webkit-mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.8) 45%, transparent 75%);
    mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.8) 45%, transparent 75%);
  }
}

/* Stage C — callouts */
.callout {
  position: absolute;
  display: flex; gap: 0.8rem; align-items: flex-start;
  text-align: left; max-width: 240px;
}
.callout strong { font-family: var(--display); font-weight: 800; text-transform: uppercase; font-size: 1.35rem; letter-spacing: 0.03em; display: block; line-height: 1; }
.callout em { font-style: normal; font-size: 0.82rem; color: var(--txt-dim); display: block; margin-top: 0.35rem; }
.co-dot {
  flex: none; width: 10px; height: 10px; margin-top: 0.4rem;
  background: var(--maiz); border-radius: 50%;
  box-shadow: 0 0 0 6px rgba(242, 178, 51, 0.18), 0 0 24px rgba(242, 178, 51, 0.5);
}
.co-2 .co-dot { background: var(--agave); box-shadow: 0 0 0 6px rgba(127, 198, 166, 0.16), 0 0 24px rgba(127, 198, 166, 0.5); }
.co-1 { top: 18%; left: clamp(1.5rem, 8vw, 10rem); }
.co-2 { top: 42%; right: clamp(1.5rem, 7vw, 9rem); max-width: 310px; }
/* copy más largo que el resto: baja un punto para que el salto caiga tras "POLIETILENO" */
.co-2 strong { font-size: 1.15rem; line-height: 1.05; }
.co-3 { bottom: 16%; left: clamp(1.5rem, 14vw, 16rem); }

/* scroll cue + corner meta */
.scroll-cue {
  position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 0.7rem;
  color: var(--txt-dim); letter-spacing: 0.4em; font-size: 0.65rem;
}
.cue-line { width: 1px; height: 48px; background: var(--line); position: relative; overflow: hidden; }
.cue-line::after {
  content: ""; position: absolute; left: 0; top: -50%;
  width: 100%; height: 50%;
  background: var(--maiz);
  animation: cueDrop 1.8s cubic-bezier(0.65, 0, 0.35, 1) infinite;
}
@keyframes cueDrop { to { top: 110%; } }

/* ============ HISTORIA ============ */
#historia {
  position: relative;
  padding: clamp(7rem, 18vh, 13rem) clamp(1.5rem, 6vw, 6rem) clamp(7rem, 16vh, 12rem);
  background:linear-gradient(
180deg, #13212e 1%, rgba(23, 40, 59, 0) 18%, rgba(14, 26, 41, 0.5) 98%, #13202d 107%), linear-gradient(90deg, rgba(14, 26, 41, 0.74) 21%, rgba(23, 40, 59, .06) 45%, rgba(23, 40, 59, 0.25) 100%), url(../assets/campo.webp) center 62% / cover no-repeat;
}
.historia-inner { position: relative; }
/* el contenido va por encima del logo: la legibilidad manda */
.historia-inner > :not(.historia-logo) { position: relative; z-index: 1; }
/* logo centrado en la sección, fuera del flujo: no mueve el contenido */
.historia-logo {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: clamp(13rem, 24vw, 22rem);
  pointer-events: none;
  filter: drop-shadow(0 10px 40px rgba(10, 20, 32, 0.6));
}
/* En móvil el logo no cabe centrado detrás del texto sin estorbarlo:
   pasa al flujo como segunda columna, a un lado de "HECHO PARA EL CAMPO". */
@media (max-width: 719px) {
  .historia-inner {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "eyebrow eyebrow"
      "title   logo"
      "cols    cols";
    column-gap: clamp(0.75rem, 3vw, 1.5rem);
    align-items: center;
  }
  .historia-inner > .eyebrow { grid-area: eyebrow; }
  .historia-title { grid-area: title; }
  .historia-cols { grid-area: cols; }
  .historia-logo {
    grid-area: logo;
    position: static;
    transform: none;
    width: clamp(5.5rem, 26vw, 9rem);
    justify-self: end;
  }
}
.display-xl .line { display: block; overflow: hidden; }
.display-xl .line > span { display: inline-block; }
.accent-line { color: var(--agave); }

.historia-cols { margin-top: 3.5rem; max-width: 620px; }
.historia-lead {
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  font-size: clamp(1.4rem, 2.6vw, 2rem); line-height: 1.1;
  color: var(--maiz);
  margin-bottom: 1.6rem;
}
.historia-body p { color: var(--txt-dim); max-width: 52ch; }
.historia-body p + p { margin-top: 1rem; }

/* ============ MARQUEE ============ */
.marquee {
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  background: var(--navy-ink);
  overflow: hidden;
  padding: 0.9rem 0;
}
.marquee-track {
  display: flex; width: max-content;
  animation: marquee 28s linear infinite;
}
.marquee-track span {
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  font-size: 1.5rem; letter-spacing: 0.12em;
  color: var(--txt-dim);
  white-space: nowrap;
}
@keyframes marquee { to { transform: translateX(-50%); } }
.marquee:hover .marquee-track { animation-play-state: paused; }

/* ============ SPECS ============ */
#specs {
  background:
    radial-gradient(ellipse 60% 45% at 15% 10%, rgba(242, 178, 51, 0.10), transparent 55%),
    radial-gradient(ellipse 55% 40% at 90% 85%, rgba(127, 198, 166, 0.08), transparent 60%),
    linear-gradient(180deg, var(--navy-ink) 0%, var(--navy-deep) 55%, var(--navy) 100%);
  padding: clamp(6rem, 14vh, 11rem) clamp(1.5rem, 6vw, 6rem);
  position: relative;
}
.specs-head { position: relative; margin-bottom: clamp(3rem, 7vh, 5.5rem); }

.specs-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  border: 1px solid var(--line);
}
@media (min-width: 720px)  { .specs-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .specs-grid { grid-template-columns: repeat(3, 1fr); } }

.spec-cell {
  padding: clamp(1.6rem, 3vw, 2.6rem);
  border: 1px solid var(--line-soft);
  margin: -0.5px;
  display: flex; flex-direction: column; gap: 0.9rem;
  min-height: 210px;
  transition: background 0.3s;
}
.spec-cell:hover { background: rgba(242, 178, 51, 0.045); }
.spec-label { color: var(--agave); font-size: 0.62rem; letter-spacing: 0.26em; }
.spec-value {
  font-family: var(--display); font-weight: 800;
  font-size: clamp(2.6rem, 4.5vw, 4rem);
  line-height: 0.95; text-transform: uppercase;
  margin-top: auto;
}
.spec-value em { font-style: normal; font-size: 0.45em; color: var(--maiz); font-weight: 700; }
.spec-value-m { font-size: clamp(2rem, 3.2vw, 2.9rem); }
.spec-foot { color: var(--txt-dim); font-size: 0.65rem; letter-spacing: 0.2em; display: flex; align-items: center; gap: 0.5rem; }
.recycle { width: 20px; height: 20px; color: var(--agave); flex: none; }

.spec-cell-visual { padding: 0; overflow: hidden; min-height: 260px; position: relative; }
.spec-cell-visual img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: 70% 50%;
  filter: brightness(1.05);
}

.specs-note { position: relative; margin-top: 1.6rem; color: var(--txt-dim); font-size: 0.65rem; letter-spacing: 0.2em; }

/* ============ CUSTOM (light section) ============ */
#custom {
  background: var(--bone);
  color: var(--navy-ink);
  padding: clamp(6rem, 14vh, 11rem) clamp(1.5rem, 6vw, 6rem);
}
#custom .eyebrow { color: #256f42; }
#custom .display-xl { color: var(--navy-ink); }
.custom-lead {
  margin-top: 1.8rem; max-width: 46ch;
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  color: rgba(14, 26, 41, 0.72);
}

.customizer {
  margin-top: clamp(3rem, 7vh, 5rem);
  display: grid; grid-template-columns: 1fr; gap: 3rem;
  align-items: center;
}
@media (min-width: 960px) { .customizer { grid-template-columns: 1.15fr 0.85fr; gap: 4rem; } }

.crate-stage {
  position: relative;
  background: none;
  border: 0;
  box-shadow: none;
  overflow: visible;
  /* cuadro compacto: 70% del ancho de la columna y proporción baja,
     para no dejar aire muerto arriba y abajo del objeto */
  width: 85%;
  margin-inline: auto;
  aspect-ratio: 4 / 3.4;
}
@media (min-width: 960px) {
  .crate-stage { width: 70%; aspect-ratio: 4 / 2.9; }
}
/* la foto de respaldo ya no define el alto: el cuadro manda */
.crate-stage img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: contain;
}
#crate-tint {
  position: absolute; inset: 0;
  mix-blend-mode: color;
  pointer-events: none;
  transition: background 0.45s ease;
}
.swatch-title { color: rgba(14, 26, 41, 0.72); font-size: 0.65rem; letter-spacing: 0.26em; }
#swatch-name { color: var(--navy-ink); font-weight: 500; }
.swatches { display: flex; flex-wrap: wrap; gap: 0.9rem; margin: 1.2rem 0 2.2rem; }
.swatch {
  width: 46px; height: 46px;
  border-radius: 50%;
  background: var(--c);
  border: 2px solid rgba(14, 26, 41, 0.15);
  cursor: pointer;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s;
}
.swatch:hover { transform: scale(1.1); }
.swatch:active { transform: scale(0.95); }
.swatch.is-active {
  transform: scale(1.12);
  box-shadow: 0 0 0 3px var(--bone), 0 0 0 5px var(--navy-ink);
}
.custom-points { list-style: none; display: grid; gap: 1rem; }
.custom-points li {
  padding-left: 1.4rem; position: relative;
  color: rgba(14, 26, 41, 0.72); font-size: 0.95rem;
}
.custom-points li::before {
  content: "✦"; position: absolute; left: 0; color: #d99a12;
}
.custom-points strong { color: var(--navy-ink); }

/* ============ CTA ============ */
#cotiza {
  background:
    radial-gradient(ellipse 70% 45% at 15% 34%, rgba(242, 178, 51, 0.07), transparent 58%),
    radial-gradient(ellipse 60% 45% at 90% 85%, rgba(127, 198, 166, 0.06), transparent 60%),
    var(--navy-ink);
  padding: clamp(6rem, 14vh, 11rem) clamp(1.5rem, 6vw, 6rem);
}
.cta-inner { max-width: 880px; }
.cta-lead { margin-top: 1.6rem; color: var(--txt-dim); max-width: 44ch; font-size: clamp(1rem, 1.5vw, 1.2rem); }

.cta-actions { display: flex; align-items: center; gap: 1.6rem; flex-wrap: wrap; margin: 2.8rem 0 2.4rem; }
.btn-whatsapp {
  display: inline-flex; align-items: center; gap: 0.7rem;
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: 1.3rem; letter-spacing: 0.05em;
  color: var(--navy-ink); background: var(--agave);
  padding: 0.9rem 2rem 1rem; border-radius: 999px;
  text-decoration: none;
  transition: background 0.25s, box-shadow 0.25s, transform 0.25s;
}
.btn-whatsapp:hover {
  background: var(--maiz);
  box-shadow: 0 12px 32px -10px rgba(242, 178, 51, 0.5);
}
.btn-whatsapp:active { transform: scale(0.97); }
.btn-whatsapp svg { width: 24px; height: 24px; }
.cta-or { color: var(--txt-dim); letter-spacing: 0.3em; }

#quote-form { display: grid; gap: 1.2rem; max-width: 640px; }
.form-row { display: grid; gap: 1.2rem; }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }
#quote-form label {
  display: grid; gap: 0.45rem;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--txt-dim);
}
#quote-form input {
  font-family: var(--sans); font-size: 1rem;
  color: var(--txt);
  background: transparent;
  border: none; border-bottom: 1px solid var(--line);
  padding: 0.6rem 0.1rem;
  outline: none;
  transition: border-color 0.3s;
}
#quote-form input::placeholder { color: rgba(239, 237, 228, 0.42); }
#quote-form input:focus { border-color: var(--maiz); }
.btn-submit {
  justify-self: start;
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: 1.2rem; letter-spacing: 0.05em;
  color: var(--navy-ink); background: var(--maiz);
  border: none; border-radius: 999px;
  padding: 0.8rem 2rem 0.9rem;
  cursor: pointer;
  transition: background 0.25s, box-shadow 0.25s, transform 0.25s;
  margin-top: 0.6rem;
}
.btn-submit:hover {
  background: var(--agave);
  box-shadow: 0 12px 32px -10px rgba(127, 198, 166, 0.55);
}
.btn-submit:active { transform: scale(0.97); }
.form-note { color: var(--txt-dim); font-size: 0.65rem; letter-spacing: 0.24em; }

/* ============ FOOTER ============ */
footer {
  background: var(--navy-ink);
  border-top: 1px solid var(--line-soft);
  padding: 3rem clamp(1.5rem, 6vw, 6rem) 3.4rem;
  display: grid; gap: 1rem; justify-items: start;
}
.foot-logo { height: 40px; }
.foot-line { color: var(--txt-dim); font-size: 0.65rem; letter-spacing: 0.22em; }
.foot-line.dim { opacity: 0.55; }

/* ============ GRAIN ============ */
.grain {
  position: fixed; inset: -50%; z-index: 90;
  pointer-events: none;
  opacity: 0.055;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grainShift 0.9s steps(4) infinite;
}
@keyframes grainShift {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-2%, 3%); }
  50% { transform: translate(3%, -2%); }
  75% { transform: translate(-3%, -3%); }
  100% { transform: translate(2%, 2%); }
}

/* ============ REVEALS (JS hooks) ============ */
.reveal { opacity: 0; transform: translateY(36px); }
.no-js .reveal, .reduced .reveal { opacity: 1; transform: none; }

/* ============ NO-JS FALLBACK ============ */
/* Si el JS no corre, la clase .no-js permanece: nunca atrapamos al usuario
   detrás del loader ni con contenido oculto, y colapsamos las secciones scrub. */
.no-js #loader { display: none; }
.no-js #progress { display: none; }
.no-js #hero-scrub { height: auto; }
.no-js .sticky-vp { position: relative; height: 100svh; }
.no-js .stage-b,
.no-js .stage-c,
.no-js .stage-d,
.no-js .scroll-cue,
.no-js .stage-d-scrim,
.no-js .hero-overlay { display: none; }

/* ============ REDUCED MOTION ============ */
@media (prefers-reduced-motion: reduce) {
  .marquee-track, .cue-line::after, .grain { animation: none; }
  #hero-scrub { height: auto; }
  .sticky-vp { position: relative; height: 100svh; }
  .stage-b, .stage-c, .stage-d, .stage-d-scrim, .hero-overlay { display: none; }
}

/* ============ SR-ONLY ============ */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* ============ PRODUCTOS (grid) ============ */
/* scroll-margin porque el menú ahora aterriza aquí: la píldora del nav es
   fija y sin este margen taparía el título "LÍNEA DE PRODUCTO". */
.productos {
  position: relative;
  margin-bottom: clamp(3.5rem, 8vh, 6rem);
  scroll-margin-top: clamp(5.5rem, 12vh, 7.5rem);
}
.productos-title {
  color: var(--agave);
  letter-spacing: 0.32em;
  margin-bottom: 1.8rem;
}

.productos-grid {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2.5rem, 5vw, 4rem);
}
@media (min-width: 700px)  { .productos-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .productos-grid { grid-template-columns: repeat(3, 1fr); } }

.producto-card {
  height: 100%;
  display: flex; flex-direction: column;
  border: 0;
  background: none;
  padding: 0;
  cursor: pointer;
  transition: transform 0.35s ease;
}
.producto-card:hover,
.producto-card:focus-within { transform: translateY(-4px); }

.producto-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: none;
}
.producto-media img {
  width: 100%; height: 100%;
  object-fit: contain; object-position: 50% 50%;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.producto-card:hover .producto-media img,
.producto-card:focus-within .producto-media img { transform: scale(1.05); }

.producto-nombre {
  font-family: var(--display); font-weight: 800;
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  line-height: 1.02; text-transform: uppercase;
  margin: 1.3rem 0 1.4rem;
}

.producto-btn {
  margin-top: auto;
  align-self: flex-start;
  font-family: var(--mono);
  font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--navy-ink); background: var(--maiz);
  border: 0; border-radius: 999px;
  padding: 0.72rem 1.5rem;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.2s ease;
}
.producto-btn:hover { background: #ffc554; }
.producto-btn:active { transform: scale(0.97); }
.producto-btn:focus-visible { outline-color: var(--txt); }

/* ============ PRODUCTOS (modal) ============ */
.producto-modal {
  position: fixed; inset: 0; z-index: 120;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  align-content: center; /* manda cuando las flechas bajan a su propia fila */
  gap: clamp(0.6rem, 1.6vw, 1.2rem);
  padding: clamp(1rem, 4vw, 3rem);
}
.producto-modal[hidden] { display: none; }

.producto-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(10, 20, 32, 0.82);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 0.35s ease;
}
.producto-modal-panel {
  /* z-index explícito: en móvil el panel lleva order:-1, y el orden de flex
     también manda en el pintado, así que sin esto el velo le queda encima */
  position: relative; z-index: 1;
  /* min-width:0 deja que encoja para hacerle lugar a las flechas */
  flex: 0 1 1020px; min-width: 0;
  max-height: 88svh; overflow-y: auto;
  background: linear-gradient(180deg, var(--navy-deep), var(--navy));
  border: 1px solid var(--line);
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.55);
  display: grid; grid-template-columns: 1fr;
  opacity: 0; transform: translateY(24px) scale(0.97);
  transition: opacity 0.4s ease, transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}
@media (min-width: 860px) {
  .producto-modal-panel { grid-template-columns: 1.05fr 0.95fr; }
  /* a dos columnas la celda se estira sola: el aspecto fijo estorbaría, y
     aquí sí puede llevar min-height porque ya no compite con el aspecto */
  .producto-modal-media { aspect-ratio: auto; min-height: 260px; }
}
/* en móvil no hay margen a los lados: el panel se lleva la fila
   y las flechas bajan debajo, sin encimarse con la caja */
@media (max-width: 719px) {
  .producto-modal-panel { flex-basis: 100%; order: -1; max-height: 76svh; }
}

.producto-modal.is-open .producto-modal-backdrop { opacity: 1; }
.producto-modal.is-open .producto-modal-panel { opacity: 1; transform: none; }

/* La celda de la foto. En una columna el alto sale del aspecto de la imagen;
   en dos columnas manda el grid y la celda se estira a la altura del texto.
   En ambos casos el alto queda definido, que es lo que necesita el height:100%
   de la <img> de más abajo para resolver. */
.producto-modal-media {
  background: var(--navy-ink);
  display: grid; place-items: center;
  padding: clamp(0.9rem, 2.4vw, 1.6rem);
  aspect-ratio: 866 / 744;
}

/* Flechas fuera del panel: son hermanas de la caja, no hijas.
   El orden del DOM (prev · panel · next) ya las deja a los lados;
   en móvil el panel toma la fila completa y ellas caen debajo. */
.pm-arrow {
  position: relative; z-index: 1; /* por encima del velo */
  flex: none;
  display: grid; place-items: center;
  width: 44px; height: 44px;
  border: 0; border-radius: 50%;
  background: rgba(242, 239, 230, 0.1); color: var(--txt);
  cursor: pointer;
  transition: background 0.25s, color 0.25s;
}
.pm-arrow:hover { background: var(--maiz); color: var(--navy-ink); }
.pm-arrow svg { display: block; width: 22px; height: 22px; }
/* contain, no cover: las fotos son recortes sobre fondo transparente y con
   cover el encuadre le cortaba las asas y las esquinas a la caja. El navy-ink
   de la celda hace de fondo, así que el aire que deja contain no se ve como
   borde: se ve como el fondo del panel. */
.producto-modal-media img {
  width: 100%; height: 100%;
  object-fit: contain; object-position: 50% 50%;
}

.producto-modal-body { padding: clamp(1.6rem, 3.5vw, 3rem); }
.producto-modal-title {
  font-family: var(--display); font-weight: 800;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 0.98; text-transform: uppercase;
  margin: 0.4rem 0 1.8rem;
}

.producto-specs { display: grid; gap: 0.1rem; border-top: 1px solid var(--line-soft); }
/* display:flex gana sobre [hidden]: hay que apagarlo a mano */
.producto-spec[hidden] { display: none; }
.producto-spec {
  display: flex; flex-wrap: wrap; gap: 0.4rem 1.2rem;
  justify-content: space-between; align-items: baseline;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line-soft);
}
.producto-spec dt { color: var(--agave); font-size: 0.62rem; letter-spacing: 0.24em; }
.producto-spec dd { font-size: 0.95rem; text-align: right; }
.producto-spec dd.is-pending { color: var(--txt-dim); font-style: italic; opacity: 0.75; }
/* colores disponibles: muestra + nombre, alineados a la derecha como el resto */
.color-chips { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.35rem 0.9rem; }
.color-chip { display: inline-flex; align-items: center; gap: 0.4rem; }
.color-dot {
  flex: none; width: 0.85rem; height: 0.85rem; border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.producto-modal-cta {
  display: inline-block; margin-top: 2rem;
  font-family: var(--mono); font-size: 0.7rem;
  letter-spacing: 0.18em; text-transform: uppercase; text-decoration: none;
  color: var(--navy-ink); background: var(--maiz);
  border-radius: 999px; padding: 0.9rem 1.9rem;
  transition: background 0.25s ease, transform 0.2s ease;
}
.producto-modal-cta:hover { background: #ffc554; }
.producto-modal-cta:active { transform: scale(0.97); }
.producto-modal-cta:focus-visible { outline-color: var(--txt); }

.producto-modal-close {
  position: absolute; top: 0.85rem; right: 0.85rem; z-index: 2;
  width: 42px; height: 42px; border-radius: 999px;
  display: grid; place-items: center;
  background: rgba(10, 20, 32, 0.7); color: var(--txt);
  border: 1px solid var(--line); cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}
.producto-modal-close:hover { background: var(--maiz); color: var(--navy-ink); }
.producto-modal-close svg { width: 20px; height: 20px; }

body.modal-open { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  .producto-card, .producto-media img,
  .producto-modal-backdrop, .producto-modal-panel { transition: none; }
  .producto-card:hover { transform: none; }
  .producto-card:hover .producto-media img { transform: none; }
  .producto-modal-panel { transform: none; }
}

/* ============ VISOR 3D (crate-stage) ============ */
.crate-3d {
  position: absolute; inset: 0;
  opacity: 0;
  cursor: grab;
  touch-action: pan-y;
  transition: opacity 0.6s ease;
}
.crate-3d.is-ready { opacity: 1; }
.crate-3d:active { cursor: grabbing; }
.crate-3d canvas { width: 100%; height: 100%; display: block; }

/* con el 3D activo, la foto fija y su tinte quedan de respaldo silencioso */
.crate-stage:has(.crate-3d.is-ready) #crate-base,
.crate-stage:has(.crate-3d.is-ready) #crate-tint { opacity: 0; }

.crate-wrap { position: relative; }

.crate-hint {
  display: flex; align-items: center; justify-content: center; gap: 0.6rem;
  margin-top: 1.2rem;
  font-size: 0.72rem; letter-spacing: 0.26em;
  color: var(--navy-ink);
  text-transform: uppercase;
}
.crate-hint svg { width: 22px; height: 22px; color: #256f42; flex: none; }
.crate-hint span {
  border-bottom: 2px solid var(--maiz);
  padding-bottom: 0.25rem;
}

/* ============================================================
   SUBPÁGINAS (fichas de producto, índice, 404)
   No cargan el hero animado: no hay canvas, ni loader, ni GSAP.
   El nav va sólido desde el inicio (clase .scrolled en el HTML).
   ============================================================ */
.subpage { background: var(--navy); }

/* despeja la píldora fija del nav, que mide ~60px + su offset */
.page-shell {
  padding: clamp(7rem, 14vh, 10rem) clamp(1.5rem, 6vw, 6rem) clamp(4rem, 10vh, 7rem);
}
.page-narrow { max-width: 820px; margin: 0 auto; }
.page-wide { max-width: 1180px; margin: 0 auto; }

.page-lead {
  margin-top: 1.2rem;
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  line-height: 1.55;
  color: var(--txt-dim);
  max-width: 60ch;
}

/* --- migas de pan --- */
.breadcrumbs { margin-bottom: 1.4rem; }
.breadcrumbs ol {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem;
  margin: 0; padding: 0; list-style: none;
}
.breadcrumbs li { display: flex; align-items: center; gap: 0.5rem; }
.breadcrumbs li + li::before {
  content: "/";
  color: var(--agave);
  opacity: 0.5;
}
.breadcrumbs a { color: var(--agave); text-decoration: none; }
.breadcrumbs a:hover { color: var(--maiz); }
.breadcrumbs [aria-current="page"] { color: var(--txt-dim); }

/* --- prosa de contenido --- */
.prose > * + * { margin-top: 1.1rem; }
.prose p { color: var(--txt-dim); line-height: 1.65; max-width: 68ch; }
.prose h2 {
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: clamp(1.6rem, 3vw, 2.4rem); line-height: 1.05;
  letter-spacing: 0.01em;
  margin-top: clamp(2.5rem, 6vh, 4rem);
}
.prose h3 {
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  font-size: clamp(1.15rem, 1.9vw, 1.5rem); line-height: 1.1;
  color: var(--maiz);
  margin-top: clamp(1.8rem, 4vh, 2.6rem);
}
.prose ul { margin: 0; padding-left: 1.3rem; }
.prose li { color: var(--txt-dim); line-height: 1.6; }
.prose li + li { margin-top: 0.6rem; }
.prose li strong { color: var(--txt); }
.prose a { color: var(--maiz); }

.link-plain {
  color: var(--agave);
  font-family: var(--display); font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.05em; font-size: 1rem;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.25s, border-color 0.25s;
}
.link-plain:hover { color: var(--maiz); border-color: var(--maiz); }

/* --- tablas: especificaciones y comparativa --- */
/* El contenedor scrollea solo; el cuerpo de la página nunca lo hace. */
.table-scroll { overflow-x: auto; margin-top: 1.4rem; }
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  min-width: 560px;
}
.data-table caption {
  text-align: left;
  color: var(--agave);
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.18em;
  text-transform: uppercase;
  padding-bottom: 0.9rem;
}
.data-table th, .data-table td {
  text-align: left;
  padding: 0.85rem 1rem 0.85rem 0;
  border-bottom: 1px solid var(--line-soft);
  vertical-align: top;
}
.data-table thead th {
  color: var(--agave);
  font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 500;
  border-bottom-color: var(--line);
  white-space: nowrap;
}
.data-table tbody th {
  color: var(--agave);
  font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 500;
  width: 42%;
}
.data-table td { color: var(--txt); }
.data-table a { color: var(--maiz); text-decoration: none; }
.data-table a:hover { text-decoration: underline; }
/* fila del modelo que se está viendo */
.data-table tr.is-current { background: rgba(242, 178, 51, 0.07); }
.data-table tr.is-current td, .data-table tr.is-current th { color: var(--maiz); }

/* --- ficha de producto: imagen + datos --- */
.producto-layout { display: grid; gap: clamp(1.8rem, 4vw, 3rem); }
@media (min-width: 860px) {
  .producto-layout { grid-template-columns: 1fr 1fr; align-items: start; }
}
.producto-figura { margin: 0; }
.producto-figura img {
  display: block; width: 100%; height: auto;
  background: var(--navy-ink);
  border: 1px solid var(--line-soft);
}
.producto-figura figcaption {
  margin-top: 0.7rem;
  font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--txt-dim); opacity: 0.75;
  line-height: 1.5;
}

/* Mismo tratamiento que #specs y #cotiza: acento maíz arriba a la izquierda,
   agave abajo a la derecha. La base baja de navy a navy-ink porque viene de
   la sección clara (#custom) y desemboca en #cotiza, que ya es navy-ink. */
#faq {
  background:
    radial-gradient(ellipse 60% 38% at 12% 10%, rgba(242, 178, 51, 0.09), transparent 56%),
    radial-gradient(ellipse 55% 30% at 92% 55%, rgba(127, 198, 166, 0.07), transparent 58%),
    linear-gradient(180deg, var(--navy) 0%, var(--navy-deep) 52%, var(--navy-ink) 88%);
  padding: clamp(6rem, 14vh, 11rem) clamp(1.5rem, 6vw, 6rem);
  position: relative;
}

/* max-width SIN margin auto, igual que .cta-inner: el contenido se alinea
   al borde del relleno de la sección, no al centro. Con .page-wide (que sí
   centra) el titular arrancaba 44px a la derecha del de las demás. */
.faq-inner { max-width: 1040px; }

/* --- Acordeón de preguntas frecuentes ------------------------------------
   Construido sobre <details>/<summary> nativos: teclado, lectores de
   pantalla y funcionamiento sin JavaScript vienen de fábrica. El JS solo
   añade la animación de altura, y solo si el usuario no pidió menos
   movimiento. Sin JS el contenido se ve al abrir, no queda colapsado. */
.faq-list { margin-top: 1.8rem; border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line-soft); }

/* la fila clicable: 44px de alto mínimo por el padding vertical */
.faq-q {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: clamp(0.8rem, 2vw, 1.4rem);
  padding: clamp(1.15rem, 2.4vh, 1.6rem) 0;
  cursor: pointer;
  list-style: none;                 /* Firefox */
  transition: color 0.25s ease;
}
.faq-q::-webkit-details-marker { display: none; }   /* Safari */
.faq-q::marker { content: ""; }

/* el número da el ritmo industrial del resto del sitio (01 — ORIGEN) */
.faq-num {
  color: var(--agave);
  padding-top: 0.35rem;
  opacity: 0.7;
  transition: color 0.25s ease, opacity 0.25s ease;
}
.faq-title {
  font-family: var(--display); font-weight: 800; text-transform: uppercase;
  font-size: clamp(1.05rem, 1.8vw, 1.4rem); line-height: 1.15;
  letter-spacing: 0.02em;
  color: var(--txt);
  margin: 0;
  transition: color 0.25s ease;
}

/* el icono es un signo + que gira hasta ser − : el estado no depende
   solo del color, requisito de accesibilidad */
.faq-icon {
  flex: none;
  display: grid; place-items: center;
  width: 30px; height: 30px;
  margin-top: 0.1rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--maiz);
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.25s ease, background 0.25s ease, color 0.25s ease;
}
.faq-icon svg {
  width: 15px; height: 15px;
  fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round;
}
/* la barra vertical del + se desvanece: queda un − */
.faq-icon svg path { transition: none; }
.faq-item[open] .faq-icon {
  transform: rotate(135deg);
  background: var(--maiz);
  border-color: var(--maiz);
  color: var(--navy-ink);
}

/* hover y foco: solo color, nunca desplazamiento */
.faq-q:hover .faq-title { color: var(--maiz); }
.faq-q:hover .faq-num { color: var(--maiz); opacity: 1; }
.faq-q:hover .faq-icon { border-color: var(--maiz); }
.faq-item[open] .faq-title { color: var(--maiz); }
.faq-item[open] .faq-num { opacity: 1; }
.faq-q:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 4px; }

/* La respuesta. Sin JS: visible al abrir. */
.faq-a-wrap { display: grid; grid-template-rows: 1fr; }
.faq-a { overflow: hidden; }
.faq-a p {
  /* alineada con el título, saltando la columna del número */
  padding: 0 0 clamp(1.3rem, 2.8vh, 1.9rem) 0;
  color: var(--txt-dim); line-height: 1.65; max-width: 68ch;
}
@media (min-width: 720px) {
  .faq-a p { padding-left: calc(2ch + clamp(0.8rem, 2vw, 1.4rem)); }
}

/* Con JS (.is-enhanced) animamos la altura. grid-template-rows de 0fr a 1fr
   es la técnica que permite animar hasta "alto automático" sin medir en JS. */
.faq-list.is-enhanced .faq-a-wrap {
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.28s ease-out;
}
.faq-list.is-enhanced .faq-item.is-open .faq-a-wrap { grid-template-rows: 1fr; }

@media (prefers-reduced-motion: reduce) {
  .faq-q, .faq-num, .faq-title, .faq-icon { transition: none; }
  .faq-list.is-enhanced .faq-a-wrap { transition: none; }
  .faq-item[open] .faq-icon { transform: none; }
}

/* --- 404 --- */
.error-page { text-align: center; }
.error-page .page-lead { margin-left: auto; margin-right: auto; }
.error-actions {
  margin-top: 2.2rem;
  display: flex; flex-wrap: wrap; gap: 1.2rem;
  align-items: center; justify-content: center;
}

/* --- cierre de subpágina: CTA a cotizar --- */
.page-cta {
  margin-top: clamp(3rem, 8vh, 5rem);
  padding-top: clamp(2rem, 5vh, 3rem);
  border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: 1.2rem; align-items: center;
}

/* .prose a pinta los enlaces en maíz, y eso dejaba el texto de los botones
   del mismo color que su fondo. Estas dos reglas les devuelven el suyo. */
.prose .nav-cta { color: var(--navy-ink); }
.prose .nav-cta:hover { color: var(--navy-ink); }
.prose .link-plain { color: var(--agave); }
.prose .link-plain:hover { color: var(--maiz); }

/* En la comparativa el encabezado de fila es el nombre del modelo, no una
   etiqueta: debe verse igual que las celdas vecinas. */
.data-table--compare tbody th {
  width: auto;
  font-family: var(--sans);
  font-size: 0.95rem;
  letter-spacing: normal;
  text-transform: none;
  font-weight: 700;
}

/* El kicker del hero ahora vive dentro del h1 (antes era un <p> aparte).
   El h1 tiene line-height 0.9 y font-weight 800: hay que aislarlo. */
.wordmark-kicker {
  display: block;
  font-family: var(--mono);
  font-weight: 400;
  line-height: 1.4;
  margin-bottom: 0.6rem;
}

/* El nombre de la tarjeta es un enlace real a la ficha (rastreable), pero
   debe verse igual que antes: hereda color y no lleva subrayado. */
.producto-nombre a {
  color: inherit;
  text-decoration: none;
  transition: color 0.25s;
}
.producto-nombre a:hover { color: var(--maiz); }

/* El acordeón vive fuera de .prose, así que su único enlace necesita
   color propio (antes lo heredaba de .prose a). */
.faq-a a { color: var(--maiz); }
.faq-a a:hover { color: var(--agave); }

/* ============ SELLO DE GARANTÍA ============ */
/* Vive en la sección 03, cuyo titular es "ALTA CALIDAD": el sello refuerza
   justo esa afirmación. El PNG es una silueta blanca de alfa completo;
   invert(1) la vuelve tinta negra, que es lo que necesita el fondo hueso.
   El atenuado va DENTRO del filter, no en opacity, porque .reveal anima
   la opacidad del elemento y se pisarían. */
.custom-head { display: grid; gap: clamp(2rem, 5vw, 3.5rem); }
.sello-calidad {
  width: clamp(6.5rem, 12vw, 10rem);
  height: auto;
  justify-self: end;
  transform: rotate(-7deg);
  filter: invert(1) opacity(0.42);
}
@media (min-width: 960px) {
  /* en escritorio ocupa el hueco a la derecha del titular */
  .custom-head { grid-template-columns: 1fr auto; align-items: center; }
  .sello-calidad { justify-self: center; }
}
@media (prefers-reduced-motion: reduce) {
  .sello-calidad { transform: none; }
}
