/* =========================================================================
   D’kor Blinds + Shades — V2
   Sistema: charcoal + hueso como base, amarillo y rojo de marca como firma.
   Motivo: la lama (la "o" del logo es un círculo con lamas horizontales).
   Formas: superficies e imágenes con radio 4px; todo lo interactivo es pill.
   Capas (z-index): intro 100 > menú 60 > header 50 > barra móvil 40.
   ========================================================================= */

@font-face {
  font-family: 'Outfit';
  src: url('../fonts/outfit-latin-wght-normal.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Instrument Sans';
  src: url('../fonts/instrument-sans-latin-wght-normal.woff2') format('woff2');
  font-weight: 400 700;
  font-display: swap;
}
@font-face {
  font-family: 'Instrument Sans';
  src: url('../fonts/instrument-sans-latin-wght-italic.woff2') format('woff2');
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}

@property --open {
  syntax: '<number>';
  inherits: false;
  initial-value: 1;
}
@property --gap {
  syntax: '<length>';
  inherits: false;
  initial-value: 0px;
}

:root {
  --ink: #141416;
  --ink-bg: #141416;
  --ink-3: #2a2a2e;
  --bone: #f2f2ef;
  --yellow: #ffe600;
  --red: #e3120b;

  --surface: #f2f2ef;
  --surface-2: #fafaf8;
  --text: #141416;
  --muted: #55555b;
  --line: rgba(20, 20, 22, 0.13);
  --focus: #141416;

  --radius: 4px;
  --pill: 999px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-io: cubic-bezier(0.77, 0, 0.175, 1);
  --font-display: 'Outfit', ui-sans-serif, system-ui, sans-serif;
  --font-body: 'Instrument Sans', ui-sans-serif, system-ui, sans-serif;
  --gutter: clamp(16px, 4vw, 56px);
  --header-h: 68px;
  --band: clamp(26px, 3.6vw, 46px);

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink-bg: #0b0b0d;
    --surface: #151517;
    --surface-2: #1c1c1f;
    --text: #f2f2ef;
    --muted: #a5a5ac;
    --line: rgba(255, 255, 255, 0.12);
    --focus: #ffe600;
    color-scheme: dark;
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
}
body {
  margin: 0;
  background: var(--surface);
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overflow-wrap: break-word; /* solo parte una palabra si no cabe sola en la línea (texto ampliado) */
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
::selection { background: var(--yellow); color: var(--ink); }
[hidden] { display: none !important; }

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 2px;
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: fixed; top: 12px; left: 12px; z-index: 110;
  max-width: calc(100% - 24px); /* con texto ampliado no sobresale de la pantalla (ensanchaba el viewport en móvil) */
  padding: 10px 18px; border-radius: var(--pill);
  background: var(--yellow); color: var(--ink); font-weight: 600;
  transform: translateY(-160%); transition: transform 0.2s var(--ease-out);
}
.skip:focus { transform: none; }

.i { width: 1.15em; height: 1.15em; flex: none; }
.i--lg { width: 30px; height: 30px; }

.wrap { width: 100%; max-width: 1320px; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(84px, 11vw, 168px); }
.section--ink {
  --text: var(--bone);
  --muted: #a9a9b0;
  --line: rgba(255, 255, 255, 0.13);
  --focus: var(--yellow);
  background: var(--ink-bg);
  color: var(--text);
}

/* ---------- Tipografía ---------- */
.eyebrow {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 22px;
}
.eyebrow--light { color: #b9b9bf; }
.h2 {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(2.1rem, 1.35rem + 2.9vw, 3.75rem);
  line-height: 1.04;
  letter-spacing: -0.028em;
  text-wrap: balance;
}
.lede {
  color: var(--muted);
  font-size: clamp(1.05rem, 1rem + 0.25vw, 1.2rem);
  max-width: 50ch;
  margin-top: 20px;
}
/* Énfasis de marca: la regla amarilla bajo el texto, como en el logo. */
.mark {
  font-style: normal;
  font-weight: 450;
  background: linear-gradient(var(--yellow), var(--yellow)) no-repeat left bottom / 100% 0.085em;
  padding-bottom: 0.17em;
}

/* ---------- Botones ---------- */
.btn {
  --h: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6em;
  min-height: var(--h);
  max-width: 100%;
  /* Relleno lateral: 1.6rem al 100 %; se reduce si el texto se amplía o la pantalla es estrecha, para dejar sitio a las palabras. */
  padding: 0 min(8vw, clamp(10px, calc(51.2px - 1.6rem), 1.6rem));
  border-radius: var(--pill);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1rem;
  letter-spacing: 0.005em;
  text-align: center;
  overflow-wrap: anywhere; /* el texto del botón (ítem flex) puede bajar de su ancho mínimo si no cabe */
  border: 1px solid transparent;
  transition: transform 0.18s var(--ease-out), background-color 0.25s, border-color 0.25s, color 0.25s;
  -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(0.97); }
.btn--wrap { max-width: 100%; }
@media (max-width: 400px) {
  .btn--wrap { height: auto; min-height: var(--h); padding-block: 12px; white-space: normal; line-height: 1.25; text-align: center; }
}
.btn .i:last-child:not(:first-child) { transition: transform 0.3s var(--ease-out); }
.btn:hover .i:last-child:not(:first-child) { transform: translateX(3px); }
.btn--sm { --h: 44px; padding: 0 min(5.5vw, clamp(8px, calc(35.2px - 1.1rem), 1.1rem)); font-size: 0.95rem; }
.btn--lg { --h: 62px; padding: 0 min(10vw, clamp(12px, calc(64px - 2rem), 2rem)); font-size: 1.06rem; }
.btn--yellow { background: var(--yellow); color: var(--ink); }
.btn--yellow:hover { background: #fff27a; }
.btn--ink { background: var(--ink); color: var(--bone); }
.btn--ink:hover { background: #2c2c31; }
.btn--ghost-light { border-color: rgba(242, 242, 239, 0.34); color: var(--bone); }
.btn--ghost-light:hover { border-color: var(--bone); }
.btn--outline { border-color: var(--text); color: var(--text); }
.btn--outline:hover { background: var(--text); color: var(--surface); }

@media (prefers-color-scheme: dark) {
  .btn--ink { background: var(--bone); color: var(--ink); }
  .btn--ink:hover { background: #fff; }
}

/* ---------- Motivos de marca ---------- */
/* Círculo con lamas: el "o" del logo. */
.disc {
  display: block;
  border-radius: 50%;
  aspect-ratio: 1;
  background: repeating-linear-gradient(180deg, var(--red) 0 14.6%, transparent 14.6% 20%);
}
/* Tilde amarilla: el apóstrofo del logo. */
.tick {
  display: block;
  width: 9px;
  height: 64px;
  background: var(--yellow);
}

/* Revelado en lamas: la imagen aparece como una cortina que abre. */
.js .slats-reveal {
  -webkit-mask-image: repeating-linear-gradient(180deg, #000 0 calc(var(--open) * var(--band)), transparent calc(var(--open) * var(--band)) var(--band));
          mask-image: repeating-linear-gradient(180deg, #000 0 calc(var(--open) * var(--band)), transparent calc(var(--open) * var(--band)) var(--band));
}
@media (prefers-reduced-motion: no-preference) {
  .js .slats-reveal { --open: 0; transition: --open 0.95s var(--ease-io); }
  .js .slats-reveal.is-in { --open: 1; }
}
.js .slats-reveal.is-done { -webkit-mask-image: none; mask-image: none; }

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s var(--ease-out), transform 0.8s var(--ease-out);
  }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
}

/* ---------- Intro ---------- */
.intro { display: none; }
.has-intro .intro {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
}
.intro__slats { position: absolute; inset: 0; display: flex; flex-direction: column; }
.intro__slats span {
  flex: 1;
  margin-bottom: -1px;
  background: var(--bone);
  transform-origin: 50% 0;
  animation: slat-open 0.42s var(--ease-io) forwards;
  animation-delay: calc(0.18s + var(--i, 0) * 0.025s);
}
.intro__slats span:nth-child(2) { --i: 1; }
.intro__slats span:nth-child(3) { --i: 2; }
.intro__slats span:nth-child(4) { --i: 3; }
.intro__slats span:nth-child(5) { --i: 4; }
.intro__slats span:nth-child(6) { --i: 5; }
.intro__slats span:nth-child(7) { --i: 6; }
.intro__slats span:nth-child(8) { --i: 7; }
.intro__logo {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(280px, 58vw);
  translate: -50% -50%;
  animation: logo-in 0.2s var(--ease-out) both, logo-out 0.16s var(--ease-io) 0.16s forwards;
}
@keyframes slat-open { to { transform: scaleY(0); } }
@keyframes logo-in { from { opacity: 0; transform: translateY(10px); clip-path: inset(0 0 100% 0); } to { opacity: 1; transform: none; clip-path: inset(0); } }
@keyframes logo-out { to { opacity: 0; transform: translateY(-8px); } }

/* ---------- Header ---------- */
.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--header-h);
  color: var(--bone);
  --focus: var(--yellow);
  transition: background-color 0.35s, color 0.35s, border-color 0.35s, backdrop-filter 0.35s;
  border-bottom: 1px solid transparent;
  container: header / inline-size;
}
.header.is-scrolled {
  background: rgba(20, 20, 22, 0.72);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
          backdrop-filter: blur(14px) saturate(140%);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}
.header.is-solid {
  --focus: inherit;
  color: var(--text);
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
          backdrop-filter: blur(14px) saturate(140%);
  border-bottom-color: var(--line);
}
.header__inner {
  max-width: 1320px;
  height: 100%;
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  gap: 24px;
}
/* flex-shrink: 0: el logo nunca se comprime aunque el resto del encabezado no quepa. */
.header__brand { display: block; flex-shrink: 0; margin-right: auto; padding-block: 5px; }
.logo { height: 34px; width: auto; }
.logo--dark { display: none; }
.header.is-solid .logo--light { display: none; }
.header.is-solid .logo--dark { display: block; }
@media (prefers-color-scheme: dark) {
  .header.is-solid .logo--light { display: block; }
  .header.is-solid .logo--dark { display: none; }
}
.nav { display: none; }
.nav ul { display: flex; gap: clamp(18px, 2.2vw, 34px); }
.nav a {
  position: relative;
  font-family: var(--font-display);
  font-size: 0.95rem;
  padding: 6px 0;
}
.nav a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--yellow);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.35s var(--ease-out);
}
.nav a:hover::after, .nav a[aria-current='true']::after { transform: scaleX(1); transform-origin: left; }
.header__cta { display: none; }
.menu-btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: var(--pill);
  border: 1px solid currentColor;
  border-color: color-mix(in srgb, currentColor 30%, transparent);
}
.menu-btn .i { width: 22px; height: 22px; }
@media (min-width: 640px) { .header__cta { display: inline-flex; } }
@media (min-width: 1024px) {
  .nav { display: block; }
  .menu-btn { display: none; }
}
/* La navegación completa solo aparece si cabe con el tamaño de texto actual: el umbral va en rem (992 px al
   100 %), así que con el texto ampliado se usa el botón de menú en lugar de comprimir el logo. */
@container header (max-width: 61.99rem) {
  .nav { display: none; }
  .menu-btn { display: grid; }
}

/* ---------- Menú móvil ---------- */
.menu {
  position: fixed;
  inset: 0;
  z-index: 60;
  color: var(--bone);
  --focus: var(--yellow);
}
.menu[hidden] { display: none; }
.menu__slats { position: absolute; inset: 0; display: flex; flex-direction: column; }
.menu__slats span {
  flex: 1;
  margin-bottom: -1px;
  background: var(--ink-bg);
  transform-origin: 50% 0;
  animation: slat-close 0.5s var(--ease-io) both;
  animation-delay: calc(var(--i, 0) * 0.04s);
}
.menu__slats span:nth-child(2) { --i: 1; }
.menu__slats span:nth-child(3) { --i: 2; }
.menu__slats span:nth-child(4) { --i: 3; }
.menu__slats span:nth-child(5) { --i: 4; }
.menu__slats span:nth-child(6) { --i: 5; }
@keyframes slat-close { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.menu__inner {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: calc(var(--header-h) + 24px) var(--gutter) calc(32px + env(safe-area-inset-bottom));
  overflow-y: auto; /* con el texto ampliado en pantallas bajas, el menú se desplaza en vez de dejar los botones fuera */
  overscroll-behavior: contain;
  animation: fade-up 0.5s var(--ease-out) 0.28s both;
}
@keyframes fade-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.menu__close {
  position: absolute;
  top: 12px;
  right: var(--gutter);
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: var(--pill);
  border: 1px solid rgba(242, 242, 239, 0.3);
}
.menu__close .i { width: 22px; height: 22px; }
.menu__links a {
  display: block;
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(2rem, 9vw, 2.8rem);
  letter-spacing: -0.02em;
  padding: 6px 0;
  overflow-wrap: anywhere; /* solo parte la palabra si no cabe (texto al 200 % en 320 px) */
}
.menu__links a:active { color: var(--yellow); }
/* minmax(0, 1fr) + btn--wrap: los botones se ajustan al ancho del menú y su texto se parte si no cabe. */
.menu__foot { margin-top: auto; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.menu__foot .btn { padding-inline: min(1.6rem, 6vw); }

/* ---------- Hero (foto real, sin video) ---------- */
.hero {
  --text: var(--bone);
  --focus: var(--yellow);
  position: relative;
  padding-top: var(--header-h);
  padding-bottom: clamp(40px, 6vh, 72px);
  background: var(--ink-bg);
  color: var(--bone);
  overflow: clip;
}
.hero__sentinel { position: absolute; top: 24px; left: 0; width: 1px; height: 1px; }
/* "transforman" no tiene descendentes: la regla va pegada a la línea base para no chocar con la línea siguiente. */
.hero .mark { padding-bottom: 0; background-position: left 92%; }
.hero__inner { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; }
.hero__title {
  font-family: var(--font-display);
  font-weight: 250;
  font-size: clamp(1.95rem, 1.1rem + 3.6vw, 4.3rem);
  line-height: 1.02;
  letter-spacing: -0.038em;
}
.hero__title .line { display: block; overflow: hidden; padding-bottom: 0.22em; margin-bottom: -0.22em; }
.hero__title .line > span { display: inline-block; max-width: 100%; } /* con texto ampliado la palabra se ajusta en vez de quedar recortada por la línea */
.hero__lede {
  color: #c4c4ca;
  font-size: clamp(1.02rem, 1rem + 0.35vw, 1.25rem);
  max-width: 40ch;
  margin-top: 20px;
}
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero .eyebrow { margin-bottom: 16px; }

/* Móvil: banda de foto a sangre arriba, con recorte horizontal propio. */
.hero__media {
  position: relative;
  order: -1;
  margin-inline: calc(var(--gutter) * -1);
  height: clamp(160px, 29svh, 320px);
  background: var(--ink-3);
}
.hero__media picture, .hero__img { display: block; width: 100%; height: 100%; }
.hero__img { object-fit: cover; object-position: 62% 55%; }
.hero__media::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 38%;
  background: linear-gradient(to top, var(--ink-bg), transparent);
  pointer-events: none;
}
.hero__media figcaption {
  position: absolute;
  z-index: 1;
  right: var(--gutter);
  bottom: 10px;
  font-size: 0.8rem;
  color: #d4d4d8;
}

/* Escritorio: copia a la izquierda, foto a sangre en la mitad derecha a toda la altura. */
@media (min-width: 960px) {
  .hero { min-height: 100svh; display: flex; align-items: center; padding-top: calc(var(--header-h) + 24px); }
  .hero__inner { grid-template-columns: minmax(0, 0.5fr) minmax(0, 0.5fr); }
  .hero__title { font-size: min(3.75rem, 4.3vw); }
  .hero__copy { position: relative; z-index: 1; padding-block: 32px; }
  .hero__media {
    position: absolute;
    order: 0;
    top: 0;
    right: 0;
    bottom: 0;
    width: 48%;
    height: auto;
    margin: 0;
  }
  .hero__img { object-position: 50% 50%; }
  /* Funde solo el borde izquierdo de la foto con el fondo; el producto (derecha) queda limpio. */
  .hero__media::after { inset: 0 auto 0 0; width: 22%; height: auto; background: linear-gradient(to right, var(--ink-bg), transparent); }
  /* La tilde amarilla del logo marca el borde de la foto. */
  .hero__media::before {
    content: '';
    position: absolute;
    z-index: 1;
    left: 0;
    top: calc(var(--header-h) + 40px);
    width: 8px;
    height: 72px;
    background: var(--yellow);
  }
  /* Opacidad 0,72 (antes 0,6): con 0,6 el texto bajaba a 3,5:1 sobre las zonas claras de la foto; ahora ≥ 4,5:1 (WCAG 1.4.3). */
  .hero__media figcaption { right: 24px; bottom: 20px; padding: 6px 12px; border-radius: var(--pill); background: rgba(20, 20, 22, 0.72); }
}

/* Coreografía de entrada del hero: la foto se muestra de inmediato; solo el texto entra. */
@media (prefers-reduced-motion: no-preference) {
  .js .hero { --d: 0.04s; }
  .js.has-intro .hero { --d: 0.3s; }
  .js .hero__title .line > span { transform: translateY(108%); animation: line-up 0.8s var(--ease-out) forwards; animation-delay: var(--d); }
  .js .hero__title .line:nth-child(2) > span { animation-delay: calc(var(--d) + 0.07s); }
  .js .hero__title .line:nth-child(3) > span { animation-delay: calc(var(--d) + 0.14s); }
  .js .hero .mark { background-size: 0% 0.085em; animation: rule-in 0.6s var(--ease-io) forwards; animation-delay: calc(var(--d) + 0.5s); }
  .js .hero .eyebrow, .js .hero__lede, .js .hero__ctas {
    opacity: 0;
    animation: fade-up 0.45s var(--ease-out) forwards;
  }
  .js .hero .eyebrow { animation-delay: var(--d); }
  .js .hero__lede { animation-delay: calc(var(--d) + 0.08s); }
  .js .hero__ctas { animation-delay: calc(var(--d) + 0.12s); }
}
@keyframes line-up { to { transform: none; } }
@keyframes rule-in { to { background-size: 100% 0.085em; } }

/* ---------- Hecho a la medida ---------- */
.craft__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 56px; align-items: center; }
.craft .h2 { max-width: 16ch; }
.craft__steps { margin-top: 40px; container-type: inline-size; }
.craft__steps li {
  display: grid;
  grid-template-columns: 12.5rem minmax(0, 1fr);
  gap: 20px;
  align-items: baseline;
  padding: 22px 0;
  border-top: 1px solid var(--line);
}
.craft__steps li:last-child { border-bottom: 1px solid var(--line); }
/* La tilde amarilla del logo marca cada verbo del proceso. */
.craft__verb {
  position: relative;
  padding-left: 18px;
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(1.5rem, 1.1rem + 1.1vw, 2.05rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.craft__verb::before { content: ''; position: absolute; left: 0; top: 0.2em; bottom: 0.14em; width: 5px; background: var(--yellow); }
.craft__steps p { color: var(--muted); max-width: 46ch; }
.craft__steps strong { color: var(--text); font-weight: 600; }
.craft__copy .lede strong { color: var(--text); font-weight: 600; }
.craft__link { margin-top: 6px; }
.craft__media { position: relative; justify-self: center; width: min(100%, 600px); }
/* Medición: marco horizontal para conservar a las personas, la cinta y la cortina. */
.craft__photo { aspect-ratio: 4 / 3; border-radius: var(--radius); overflow: hidden; background: var(--ink-3); }
.craft__photo img { width: 100%; height: 100%; object-fit: cover; }
/* Instalación (vertical): en móvil va debajo; en escritorio se superpone en la esquina inferior derecha,
   sobre el cuerpo del instalador, sin tapar caras, cinta ni la cortina medida. */
.craft__aside { width: 46%; margin-top: 20px; }
.craft__inset {
  aspect-ratio: 3 / 4;
  border-radius: var(--radius);
  overflow: hidden;
}
.craft__inset picture { display: block; height: 100%; }
.craft__inset img { width: 100%; height: 100%; object-fit: cover; }
.craft__media figcaption { margin-top: 12px; font-size: 0.85rem; color: var(--muted); }
.craft__aside figcaption { margin-top: 8px; }
/* Apilada (móvil y tableta): la figura entera, con su pie, queda centrada bajo la medición; mismo ancho (46 %).
   6em solo supera el 46 % con el texto ampliado (al 100 % son 96 px, por debajo de 132 px a 320 px): así «Instalación»
   no se parte con texto al 200 %, sin deformar la foto (mantiene 3:4). */
@media (max-width: 959px) {
  .craft__aside { width: max(46%, 6em); margin-inline: auto; }
  .craft__aside figcaption { text-align: center; }
}
.craft__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 40px;
  margin-top: clamp(48px, 6vw, 88px);
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-family: var(--font-display);
  font-weight: 500;
}
.craft__facts li, .craft__facts a { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; overflow-wrap: anywhere; }
.craft__facts .i { width: 22px; height: 22px; color: var(--red); }
.craft__facts a { text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 3px; text-underline-offset: 6px; }
.craft__facts a .i:last-child { width: 18px; height: 18px; color: var(--text); transition: transform 0.3s var(--ease-out); }
.craft__facts a:hover .i:last-child { transform: translateX(3px); }
.disc--xs { width: 20px; flex: none; }
@media (min-width: 960px) {
  .craft__grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(56px, 7vw, 120px); }
  .craft__media { justify-self: end; }
  /* La instalación se superpone en la esquina inferior derecha con su leyenda debajo; la leyenda de la medición
     queda en flujo a la izquierda (sin solaparse con la foto pequeña) y reserva la banda donde baja la instalación. */
  .craft__aside { position: absolute; right: -24px; bottom: 0; width: 32%; margin: 0; }
  .craft__inset { border: 6px solid var(--surface); box-shadow: 0 18px 40px rgba(20, 20, 22, 0.16); }
  .craft__main figcaption { min-height: 10rem; padding-right: calc(32% - 4px); }
}
@media (max-width: 700px) {
  .craft__steps li { grid-template-columns: minmax(0, 1fr); gap: 6px; }
}
/* 24.5rem = columna del verbo (12.5rem) + un mínimo legible para el texto; al 100 % nunca se alcanza por encima de 700 px. */
@container (max-width: 24.5rem) {
  .craft__steps li { grid-template-columns: minmax(0, 1fr); gap: 6px; }
}

/* ---------- Catálogo ---------- */
.catalog { background: var(--surface-2); }
.catalog__head { max-width: 780px; margin-bottom: clamp(48px, 7vw, 96px); }
.product { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; align-items: center; }
.product + .product { margin-top: clamp(72px, 10vw, 136px); }
@media (min-width: 860px) {
  .product { grid-template-columns: minmax(0, 0.92fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 104px); }
  .product--flip .viewer { order: 2; }
}

/* Visor de dos estados: Producto / En un espacio. La transición en lamas vive en main.js. */
.viewer { width: min(100%, 480px); justify-self: center; }
@media (min-width: 860px) {
  .viewer { justify-self: start; }
  .product--flip .viewer { justify-self: end; }
}
.viewer__stage {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--ink-3);
  isolation: isolate;
}
.viewer__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; }
.viewer__img.is-active { opacity: 1; }
.viewer--wide { width: min(100%, 560px); }
.viewer--wide .viewer__stage { aspect-ratio: 4 / 3; }
/* Visor estrecho 3:4: Screen (dos fotos verticales). */
.viewer--tall { width: min(100%, 380px); }
.viewer--tall .viewer__stage { aspect-ratio: 3 / 4; }
/* Screen: a 320 px de ancho, la foto de la ventana (941 px) sigue cubriendo DPR 2 y casi DPR 3. */
#screen .viewer--tall { width: min(100%, 320px); }
/* Dim Out: «En dormitorio» no cabe entero en medio selector con texto al 200 % a 320 px; la etiqueta se ajusta al ancho
   del selector solo cuando hace falta (al 100 % manda 0.95rem). */
#dimout .viewer__toggle { container-type: inline-size; }
#dimout .viewer__toggle button { font-size: min(0.95rem, 9.2cqi); }
/* Etiqueta de la leyenda (Dim Out, «Colección exclusiva»): bloque propio para que la leyenda mida lo mismo visible u
   oculta; ajusta sus líneas con texto ampliado. */
.viewer__tag {
  display: block;
  width: fit-content;
  max-width: 100%;
  margin-bottom: 8px;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--yellow);
  color: var(--ink);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.35;
  text-transform: uppercase;
}
/* Enlace «Ver colecciones exclusivas» bajo la leyenda de Dim Out: línea propia, área táctil de 44 px. Va dentro de la
   leyenda de «En ventanas», así que se oculta con ella y la altura de la leyenda no cambia al alternar. */
.viewer__caption .viewer__more { display: flex; width: fit-content; max-width: 100%; margin-top: 2px; color: var(--text); }
.viewer__toggle button { line-height: 1.15; }

/* Leyendas descriptivas de fotos en negrita: mismo tamaño y color de cada fondo, solo más peso. */
.hero__media figcaption, .craft__media figcaption, .viewer__caption, .solo figcaption, .gallery figcaption,
.compare__caption, .space--com figcaption { font-weight: 600; }

/* Ficha con una sola foto (Drop Shades): sin visor forzado. */
.solo { width: min(100%, 560px); justify-self: center; }
.solo picture { display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: var(--radius); background: var(--ink-3); }
.solo img { width: 100%; height: 100%; object-fit: cover; }
.solo figcaption { margin-top: 12px; font-size: 0.88rem; color: var(--muted); }
/* Ficha con una sola foto vertical (Dimout): mismo marco 3:4 que los visores estrechos. */
.solo--tall { width: min(100%, 380px); }
.solo--tall picture { aspect-ratio: 3 / 4; }
@media (min-width: 860px) {
  .solo { justify-self: start; }
  .product--flip .solo { order: 2; justify-self: end; }
}

/* Galerías de producto: fotos reales de instalaciones, sin visor cuando no hay par producto/espacio. */
.gallery { display: grid; gap: 12px; }
.gallery figure { min-width: 0; }
.gallery img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius); background: var(--ink-3); }
.gallery picture { display: block; overflow: hidden; border-radius: var(--radius); }
.gallery figcaption { margin-top: 8px; font-size: 0.85rem; color: var(--muted); }
.gallery--trio { grid-template-columns: repeat(2, minmax(0, 1fr)); width: min(100%, 560px); justify-self: center; }
.gallery--trio .gallery__main { grid-column: 1 / -1; }
.gallery--trio .gallery__main picture { aspect-ratio: 16 / 9; }
.gallery--trio figure:not(.gallery__main) picture { aspect-ratio: 3 / 4; }
/* Tela oscura (9:16): se ancla arriba para conservar el riel y el bajo. */
.gallery__top img { object-position: 50% 0%; }
@media (min-width: 860px) { .gallery--trio { justify-self: start; } }
.viewer__bands { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.viewer__band { position: absolute; left: 0; right: 0; overflow: hidden; will-change: clip-path; }
.viewer__band img { position: absolute; left: 0; width: 100%; max-width: none; object-fit: cover; }
/* Ajustes de encuadre por foto (antes en atributos style, incompatibles con la CSP). main.js conserva estas clases al clonar. */
.viewer__img--top, .viewer__band .viewer__img--top { object-position: 50% 12%; }
.viewer__img--contain, .viewer__band .viewer__img--contain { object-fit: contain; }
.viewer__toggle {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 16px;
  padding: 4px;
  border-radius: var(--pill);
  border: 1px solid var(--line);
  isolation: isolate;
}
.viewer__toggle button {
  position: relative;
  z-index: 1;
  min-height: 44px;
  padding: 0 max(4px, calc(30px - 1rem)); /* 14 px al 100 %; con texto ampliado deja sitio a la etiqueta */
  border-radius: var(--pill);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--muted);
  transition: color 0.25s, transform 0.16s var(--ease-out);
  -webkit-tap-highlight-color: transparent;
}
.viewer__toggle button:active { transform: scale(0.97); }
.viewer__toggle button[aria-pressed='true'] { color: var(--ink); }
.viewer__thumb {
  position: absolute;
  z-index: 0;
  top: 4px;
  bottom: 4px;
  left: 4px;
  width: calc(50% - 4px);
  border-radius: var(--pill);
  background: var(--yellow);
  transition: transform 0.28s var(--ease-out);
}
.viewer[data-state='space'] .viewer__thumb { transform: translateX(100%); }
.viewer__caption { display: grid; margin-top: 12px; min-height: 2.9em; font-size: 0.88rem; color: var(--muted); }
/* Las dos leyendas ocupan la misma celda: el visor no cambia de altura al alternar vistas. */
.viewer__caption > span { grid-area: 1 / 1; }
/* !important para ganar a la regla global [hidden]; la leyenda oculta sigue fuera del árbol de accesibilidad. */
.viewer__caption > span[hidden] { display: block !important; visibility: hidden; }
@media (hover: hover) and (pointer: fine) {
  .viewer__toggle button[aria-pressed='false']:hover { color: var(--text); }
}

.product__info h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.8rem, 1.3rem + 1.4vw, 2.5rem);
  letter-spacing: -0.025em;
  line-height: 1.08;
}
.product__info > p { color: var(--muted); margin-top: 14px; max-width: 48ch; }
.checks { display: grid; gap: 10px; margin-top: 24px; }
.checks li { display: flex; gap: 12px; align-items: baseline; overflow-wrap: anywhere; } /* solo parte una palabra si no cabe (texto al 200 % en 320 px) */
.checks .i { color: var(--red); translate: 0 0.18em; }
.ideal { margin-top: 22px; color: var(--muted); font-size: 0.95rem; }
.ideal strong { color: var(--text); font-weight: 600; margin-right: 4px; }
.product__info .btn { margin-top: 28px; }
/* Cuidados del textil (Screen y Blackouts): <details> nativo, cerrado al cargar y legible sin JavaScript. */
.care { max-width: 48ch; margin-top: 32px; border-block: 1px solid var(--line); }
.care summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 52px;
  padding-block: 10px;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--text);
}
.care summary::-webkit-details-marker { display: none; }
.care summary::after {
  content: '';
  flex: none;
  width: 0.55em;
  height: 0.55em;
  margin-right: 4px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  rotate: 45deg;
  translate: 0 -2px;
  transition: rotate 0.25s var(--ease-out), translate 0.25s var(--ease-out);
}
.care[open] summary::after { rotate: -135deg; translate: 0 2px; }
.care__body { padding-bottom: 22px; color: var(--muted); font-size: 0.95rem; }
.care__list { display: grid; gap: 8px; margin-top: 14px; }
.care__list li { position: relative; padding-left: 1.2em; }
.care__list li::before { content: ''; position: absolute; left: 0; top: 0.6em; width: 0.4em; height: 0.4em; border-radius: 50%; background: var(--red); }
.care__list + p { margin-top: 14px; }
.care__link { margin-top: 8px; }


/* ---------- Showroom (video) ---------- */
.showroom__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 56px; align-items: center; }
.showroom .h2 { max-width: 15ch; }
/* Solo «¡Visítanos!» en el amarillo de la marca: #ffe600 sobre #141416 (o #0b0b0d en modo oscuro), contraste superior a 14:1. */
.showroom__visit { color: var(--yellow); font-weight: 600; }
.chapters { margin-top: 40px; max-width: 460px; }
.chapters li { border-top: 1px solid var(--line); }
.chapters li:last-child { border-bottom: 1px solid var(--line); }
.chapters button {
  position: relative;
  width: 100%;
  display: grid;
  grid-template-columns: minmax(58px, max-content) minmax(0, 1fr);
  align-items: baseline;
  padding: 15px 0;
  text-align: left;
  font-family: var(--font-display);
  font-size: 1.08rem;
  color: var(--muted);
  transition: color 0.2s, padding 0.4s var(--ease-out);
}
.chapters__t { font-size: 0.85rem; color: var(--yellow); font-variant-numeric: tabular-nums; letter-spacing: 0.04em; }
.chapters button:hover, .chapters button[aria-current='true'] { color: var(--text); }
.chapters button[aria-current='true'] { padding-left: 14px; }
.chapters button::before {
  content: '';
  position: absolute;
  left: 0; top: 16px; bottom: 16px;
  width: 4px;
  background: var(--yellow);
  transform: scaleY(0);
  transition: transform 0.4s var(--ease-out);
}
.chapters button[aria-current='true']::before { transform: none; }

.player {
  position: relative;
  justify-self: center;
  width: min(100%, 400px, calc(80vh * 0.5625));
  aspect-ratio: 576 / 1024;
  border-radius: var(--radius);
  overflow: hidden;
  background: #000;
}
.player__video { width: 100%; height: 100%; object-fit: cover; background: var(--ink-3); }
.player::after {
  content: '';
  position: absolute;
  inset: 45% 0 0;
  background: linear-gradient(to top, rgba(10, 10, 12, 0.82), transparent);
  pointer-events: none;
  transition: opacity 0.4s;
}
.player.is-playing::after { opacity: 0; }
.player__play {
  position: absolute;
  z-index: 1;
  left: 20px;
  bottom: 22px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-align: left;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.1rem;
  color: var(--bone);
}
.player__play .i {
  width: 64px;
  height: 64px;
  padding: 22px;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--ink);
  transition: transform 0.3s var(--ease-out);
}
.player__play:hover .i { transform: scale(1.06); }
.player__play small { display: block; font-family: var(--font-body); font-weight: 400; font-size: 0.82rem; color: #c9c9ce; }
.player.is-playing .player__play { display: none; }
.player__error {
  position: absolute;
  inset: auto 12px 12px;
  z-index: 2;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--bone);
  color: var(--ink);
  font-size: 0.92rem;
  --focus: var(--ink);
}
.player__error:empty { display: none; }
.player__error-actions { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 6px; }
.player__error a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-family: var(--font-display);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 3px;
  text-underline-offset: 5px;
}
.chapters button[aria-disabled='true'] { opacity: 0.55; }
.player.has-error .player__play { display: none; }
.player--route { width: min(100%, 360px, calc(78vh * 0.5625)); justify-self: center; }
/* El póster lleva la franja del teléfono incrustada abajo: el botón y su degradado van arriba. */
.player--route .player__play { top: 18px; bottom: auto; }
.player--route::after { inset: 0 0 55% 0; background: linear-gradient(to bottom, rgba(10, 10, 12, 0.78), transparent); }
@media (min-width: 960px) { .player--route { justify-self: start; } }
.chapters--light { margin-top: 20px; width: min(100%, 360px); max-width: none; }
.chapters--light .chapters__t { color: var(--text); font-weight: 600; }
.transcript { width: min(100%, 360px); margin-top: 16px; font-size: 0.95rem; color: var(--muted); }
.transcript summary {
  display: flex;
  align-items: center;
  min-height: 44px;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
}
.transcript p { margin-top: 10px; }
.transcript__note { font-size: 0.85rem; }

@media (min-width: 960px) {
  .showroom__grid { grid-template-columns: minmax(0, 1fr) auto; gap: clamp(56px, 8vw, 140px); }
  .player { justify-self: end; }
}

/* ---------- Residencial / Comercial ---------- */
.spaces__head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 28px; margin-bottom: clamp(32px, 4.5vw, 60px); }
.spaces .h2 { max-width: 16ch; }
.switch {
  position: relative;
  display: inline-flex;
  flex-wrap: wrap;
  max-width: 100%;
  padding: 4px;
  border-radius: var(--pill);
  border: 1px solid var(--line);
  isolation: isolate;
}
.switch button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px min(20px, 5.5vw); /* en 320 px los dos botones caben en una fila (antes sobresalían 8 px) */
  border-radius: var(--pill);
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--muted);
  transition: color 0.3s;
}
.switch button[aria-selected='true'] { color: var(--ink); }
.switch__thumb {
  position: absolute;
  z-index: -1;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  border-radius: var(--pill);
  background: var(--yellow);
  transition: transform 0.5s var(--ease-out), width 0.5s var(--ease-out);
}
.space { display: grid; gap: 12px; }
.space[hidden] { display: none; }
.space figure { border-radius: var(--radius); overflow: hidden; background: var(--ink-3); }
.space picture { display: block; height: 100%; }
.space img { width: 100%; height: 100%; object-fit: cover; }
.space__text { grid-column: 1 / -1; padding-top: 16px; }
.space__text h3 { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.5rem, 1.2rem + 1vw, 2.1rem); letter-spacing: -0.02em; }
.space__text p { color: var(--muted); margin-top: 10px; max-width: 52ch; }
.space .slats-mask {
  -webkit-mask-image: repeating-linear-gradient(180deg, #000 0 calc(var(--open) * var(--band)), transparent calc(var(--open) * var(--band)) var(--band));
          mask-image: repeating-linear-gradient(180deg, #000 0 calc(var(--open) * var(--band)), transparent calc(var(--open) * var(--band)) var(--band));
}
/* Residencial: comedor horizontal grande + detalle de cocina (versiones editoriales de 1600 y 1086 px; sizes medidos por marco). */
.space--res .space__big { aspect-ratio: 16 / 9; }
/* Móvil: marco cuadrado para que la cocina conserve cajón y barra inferior (en 4:3 quedaba fuera la barra). */
.space--res .space__side { aspect-ratio: 1; }
.space--res .space__side img { object-position: 50% 30%; }
/* Comercial: dos proyectos distintos, cada uno con su pie. Oficina horizontal principal y terraza vertical completa
   (9:16, sin recortar las cortinas). En móvil se apilan; la vertical se limita para no ocupar varias pantallas. */
.space--com { grid-template-columns: minmax(0, 1fr); }
.space--com figure { overflow: visible; border-radius: 0; background: none; }
.space__frame { border-radius: var(--radius); overflow: hidden; background: var(--ink-3); }
.space--com .space__big .space__frame { aspect-ratio: 16 / 9; }
.space--com .space__tall { width: min(100%, 360px); }
.space--com .space__tall .space__frame { aspect-ratio: 9 / 16; }
.space--com figcaption { margin-top: 10px; font-size: 0.88rem; color: var(--muted); }
@media (min-width: 900px) {
  .space { gap: 16px; }
  .space--res { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
  .space--res .space__side { aspect-ratio: auto; }
  .space--com { grid-template-columns: minmax(0, 2.4fr) minmax(0, 1fr); align-items: start; column-gap: clamp(16px, 2.5vw, 32px); }
  .space--com .space__tall { width: auto; grid-column: 2; grid-row: 1 / span 2; }
  .space--com .space__text { grid-column: 1; }
}

/* ---------- Antes y después ---------- */
/* Mejora progresiva: sin JS, ambas fotos y pies permanecen visibles. El recorte revela la foto completa,
   nunca encoge su ancho. La barra sigue el gesto sin animaciones ni cambios de altura. */
.compare-sec__head { max-width: 46rem; margin-bottom: clamp(28px, 4vw, 48px); }
.compare { --compare-position: 50%; }
.compare__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
.compare__frame { aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: var(--ink-3); }
.compare__frame img { width: 100%; height: 100%; object-fit: cover; }
.compare__label { margin-top: 10px; font-family: var(--font-display); font-weight: 600; }
.compare__help { display: none; margin-top: 16px; font-size: 0.88rem; color: var(--muted); }
.compare__caption { margin-top: 16px; font-size: 0.88rem; color: var(--muted); }
.compare-sec__cta { margin-top: 28px; }
.compare.is-interactive .compare__grid {
  position: relative; display: block; aspect-ratio: 16 / 9;
  border-radius: var(--radius); overflow: hidden; isolation: isolate;
}
.compare.is-interactive .compare__item { position: absolute; inset: 0; }
.compare.is-interactive .compare__frame { width: 100%; height: 100%; aspect-ratio: auto; }
.compare.is-interactive .compare__item[data-compare-item='before'] {
  z-index: 1; clip-path: inset(0 calc(100% - var(--compare-position)) 0 0);
}
.compare.is-interactive .compare__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.compare.is-interactive .compare__help { display: block; }
.compare.is-interactive .compare__caption { margin-top: 6px; }
.compare__controls { position: absolute; inset: 0; z-index: 2; cursor: ew-resize; touch-action: pan-y; }
.compare__badges {
  position: absolute; inset: clamp(8px, 1.6vw, 20px) clamp(8px, 1.6vw, 20px) auto;
  display: flex; justify-content: space-between; gap: 12px; pointer-events: none;
}
.compare__badge {
  padding: 6px 10px; border-radius: var(--radius);
  background: var(--ink); color: var(--bone); font-family: var(--font-display);
  font-size: 0.8125rem; font-weight: 600; line-height: 1.4;
}
.compare[data-edge='after'] .compare__badge--before,
.compare[data-edge='before'] .compare__badge--after { visibility: hidden; }
.compare__range {
  position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; min-height: 44px;
  margin: 0; padding: 0; border: 0; border-radius: 0;
  appearance: none; -webkit-appearance: none; background: transparent;
  color: transparent; pointer-events: none;
}
.compare__range::-webkit-slider-runnable-track { background: transparent; border: 0; }
.compare__range::-moz-range-track { background: transparent; border: 0; }
.compare__range::-webkit-slider-thumb { appearance: none; -webkit-appearance: none; width: 52px; height: 52px; border: 0; background: transparent; }
.compare__range::-moz-range-thumb { width: 52px; height: 52px; border: 0; background: transparent; }
.compare__range:focus-visible { outline: none; }
.compare__divider {
  position: absolute; top: 0; bottom: 0; left: var(--compare-position); width: 3px;
  transform: translateX(-50%); background: var(--bone); box-shadow: 1px 0 3px rgba(0, 0, 0, 0.4); pointer-events: none;
}
.compare__handle {
  position: absolute; top: 50%; left: clamp(34px, var(--compare-position), calc(100% - 34px));
  display: grid; place-items: center; width: 52px; height: 52px;
  transform: translate(-50%, -50%); border: 2px solid var(--ink); border-radius: 50%;
  background: var(--yellow); color: var(--ink); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.22); pointer-events: none;
}
.compare__handle svg { width: 26px; height: 26px; }
.compare__range:focus-visible ~ .compare__handle { outline: 3px solid var(--bone); outline-offset: 3px; }
.compare.is-dragging .compare__handle { background: var(--bone); }
@media (hover: hover) {
  .compare__controls:hover .compare__handle { background: var(--bone); }
}
@media (min-width: 768px) {
  .compare__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---------- Financiamiento ---------- */
.finance { padding-top: 0; }
.finance__panel {
  --focus: var(--ink);
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 40px;
  padding: clamp(28px, 5.5vw, 80px);
  border-radius: var(--radius);
  background: var(--yellow);
  color: var(--ink);
}
.finance__panel::after {
  content: '';
  position: absolute;
  width: clamp(320px, 42vw, 620px);
  aspect-ratio: 1;
  right: -12%;
  bottom: -30%;
  border-radius: 50%;
  background: repeating-linear-gradient(180deg, rgba(20, 20, 22, 0.045) 0 14.6%, transparent 14.6% 20%);
  pointer-events: none;
}
.finance__lead, .steps, .finance__legal { min-width: 0; position: relative; z-index: 1; }
/* Logo oficial (tarjeta oscura propia): tamaño fijo, sin deformar, con aire alrededor. */
.finance__logo { display: block; width: 146px; height: auto; }
.finance .h2 { margin-top: 24px; max-width: 17ch; }
.finance__lead p { margin-top: 20px; max-width: 46ch; color: rgba(20, 20, 22, 0.8); font-size: 1.08rem; }
/* Frase comercial secundaria: negra y en seminegrita, por debajo del título y del botón; puede partirse en dos líneas. */
.finance__lead .finance__promo { margin-top: 16px; max-width: 100%; color: var(--ink); font-weight: 600; font-size: 1.2rem; line-height: 1.3; overflow-wrap: anywhere; }
.finance__lead .finance__promo + .finance__intro { margin-top: 10px; }
.finance__ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 28px; margin-top: 32px; }
.finance .link-arrow { margin-top: 0; text-decoration-color: currentColor; text-decoration-thickness: 2px; }
.finance__step-link { grid-column: 2; justify-self: start; margin-top: 2px; }
.finance .btn--ink { background: var(--ink); color: var(--bone); }
.finance .btn--ink:hover { background: #2c2c31; }
.steps { align-self: end; }
.steps li {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  padding: 22px 0;
  border-top: 1px solid rgba(20, 20, 22, 0.2);
}
/* Número escrito en el HTML (1, 2, 3): con counter(), cada li es contenedor (container-type: inline-size) y su contención
   de estilo aislaba el contador; WebKit mostraba 0, 0, 0 (reproducido el 2026-11-22). */
.steps__number {
  grid-row: 1;
  grid-column: 1;
  font-family: var(--font-display);
  font-weight: 300;
  font-size: 1.9rem;
  line-height: 1;
}
.steps h3 { font-family: var(--font-display); font-weight: 500; font-size: 1.2rem; }
.steps p { grid-column: 2; margin-top: 4px; color: rgba(20, 20, 22, 0.78); }
/* Paso muy estrecho (320 px con texto al 200 %): el número pasa encima del título para no partir palabras en una columna
   de pocas letras. A tamaño normal nunca se cumple (el paso mide al menos 15em). */
@container (max-width: 12em) {
  .steps__number, .steps h3, .steps p, .finance__step-link { grid-column: 1 / -1; }
  .steps__number { margin-bottom: 8px; }
}
.finance__legal { font-size: 0.88rem; color: rgba(20, 20, 22, 0.76); padding-top: 22px; border-top: 1px solid rgba(20, 20, 22, 0.2); }
@media (min-width: 960px) {
  .finance__panel { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); column-gap: clamp(48px, 6vw, 110px); }
  .finance__legal { grid-column: 1 / -1; }
}

/* ---------- Formas de pago ---------- */
.pay {
  display: grid;
  gap: 32px;
  margin-top: 16px;
  padding: clamp(24px, 4vw, 48px);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.pay__title { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.5rem, 1.2rem + 0.9vw, 2rem); letter-spacing: -0.02em; }
.pay__lede { margin-top: 10px; max-width: 44ch; color: var(--muted); }
/* 14 px entre piezas: área de protección de Apple Pay (1/4 de la altura de la marca) y de Google Pay (media «G»). */
.pay__logos { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 20px; }
.pay__logos li {
  display: grid;
  place-items: center;
  width: 84px;
  height: 56px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
}
.pay__logos img { width: 44px; height: 44px; }
/* UnionPay: logotipo oficial en la misma pieza blanca que las tarjetas, a su proporción (1512 × 945). */
.pay__logos .pay__unionpay { width: auto; height: 32px; }
/* Google Pay y Apple Pay: sus marcas oficiales ya son una pieza con contorno propio. Se muestran a la misma altura que
   las demás piezas (56 px), sin borde ni fondo añadidos: Apple no permite que la marca comparta borde con otro gráfico. */
.pay__logos .pay__mark { width: auto; border: 0; border-radius: 0; background: none; }
.pay__logos .pay__mark img { width: auto; height: 56px; }
/* QR y texto lado a lado solo si el texto dispone de 10em (crece con el texto ampliado); si no, el texto pasa debajo
   del QR. Con la rejilla fija anterior, a 430–480 px y texto al 200 % «Copiar identificador» desbordaba la página. */
.ath { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; }
.ath__qr { flex: none; width: 184px; height: 184px; border-radius: 8px; background: #fff; border: 1px solid var(--line); }
.ath__body { flex: 1 1 10em; min-width: 0; }
/* Nombre en texto de alto contraste; el naranja de ATH queda como acento, no como color de texto (2.98:1). */
.ath__brand { display: flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 600; letter-spacing: 0.01em; }
.ath__brand::before { content: ''; width: 12px; height: 12px; border-radius: 50%; background: #f26722; }
.ath__id code { font-family: var(--font-display); font-size: clamp(1.25rem, 1.1rem + 0.5vw, 1.55rem); font-weight: 500; letter-spacing: -0.01em; word-break: break-all; }
.ath__copy {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  max-width: 100%;
  margin-top: 10px;
  padding: 6px 16px;
  /* 22 px = medio alto mínimo (44 px): igual que la píldora en una línea; con varias líneas, esquinas que no tapan el texto. */
  border-radius: 22px;
  border: 1px solid var(--text);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.95rem;
  line-height: 1.25;
  text-align: start;
  transition: transform 0.16s var(--ease-out), background-color 0.2s, color 0.2s;
}
/* Nunca más ancho que su columna. Primero el texto se reparte en varias líneas junto al icono (base 0 con el mínimo
   automático: solo se pasa de línea si ni la palabra más larga cabe al lado); entonces el icono queda encima.
   El tamaño de letra no se reduce. */
.ath__copy { flex-wrap: wrap; }
.ath__copy [data-copy-label] { flex: 1 1 0; overflow-wrap: break-word; }
.ath__copy:active { transform: scale(0.97); }
.ath__copy.is-copied { background: var(--text); color: var(--surface); }
.ath__help { margin-top: 12px; max-width: 46ch; font-size: 0.9rem; color: var(--muted); }
@media (min-width: 960px) { .pay { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 5vw, 80px); align-items: center; } }
@media (max-width: 420px) { .ath__body { flex-basis: 100%; } .ath__qr { width: 200px; height: 200px; } }

/* ---------- Filosofía / Misión / Visión (banda charcoal) ---------- */
.story__title {
  margin-bottom: clamp(32px, 5vw, 64px);
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(1.35rem, 1.1rem + 0.9vw, 1.9rem);
  letter-spacing: -0.015em;
  color: var(--muted);
}
.story__manifesto {
  max-width: 15ch;
  margin-top: 20px;
  font-family: var(--font-display);
  font-weight: 250;
  font-size: clamp(2.2rem, 1.2rem + 3.6vw, 4.6rem);
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.story__body { max-width: 52ch; margin-top: 28px; color: var(--muted); font-size: 1.05rem; }
/* Sin la foto: en móvil, filosofía → misión → visión seguidas, con una separación contenida. */
.story__values { display: grid; grid-template-columns: minmax(0, 1fr); margin-top: clamp(40px, 6vw, 88px); }
/* Misión y visión: mismo bloque, mismo relleno y misma tipografía. Lado a lado, la rejilla los estira a la misma altura;
   apilados, cada uno mide lo que su texto (sin alturas fijas). */
.story__values { gap: 16px; }
.value { display: flex; flex-direction: column; padding: clamp(24px, 3.2vw, 44px); border: 1px solid var(--line); border-radius: var(--radius); background: rgba(255, 255, 255, 0.03); }
.value__label {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}
.value__label::before { content: ''; width: 28px; height: 2px; background: var(--red); }
/* Misión y visión: un párrafo por bloque (texto aprobado, más largo que una frase destacada). */
.value__text {
  max-width: 68ch;
  margin-top: 18px;
  font-size: clamp(1.02rem, 0.98rem + 0.25vw, 1.15rem);
  line-height: 1.7;
  text-wrap: pretty;
  -webkit-hyphens: auto;
  hyphens: auto;
}
@media (min-width: 960px) {
  /* Introducción en una sola zona centrada. La frase ocupa el ancho nuevo (ya no la columna estrecha de 15ch) con
     saltos equilibrados; el párrafo es un bloque centrado y conserva su justificación (última línea al inicio). */
  .story__lead { text-align: center; }
  .story__lead .value__label { justify-content: center; }
  .story__manifesto { max-width: 22ch; margin-inline: auto; }
  .story__body { max-width: 60ch; margin-inline: auto; }
  .story__values { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(16px, 2vw, 28px); }
}

/* ---------- Reseña (dentro de Visítanos) ---------- */
.stars { display: flex; gap: 4px; color: var(--text); }
.stars .i { width: 18px; height: 18px; }
.review {
  margin-top: 40px;
  padding: clamp(24px, 3vw, 36px);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface-2);
}
.review blockquote p {
  margin-top: 16px;
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(1.25rem, 1.05rem + 0.7vw, 1.6rem);
  line-height: 1.28;
  letter-spacing: -0.015em;
  text-wrap: pretty;
}
.review figcaption { margin-top: 16px; color: var(--muted); font-size: 0.92rem; }
.review figcaption strong { display: block; color: var(--text); font-weight: 600; }
.review .link-arrow { margin-top: 10px; }
/* Dos reseñas al final de Visítanos: dos tarjetas desde 768 px, apiladas en móvil. Sin carrusel. */
.reviews { margin-top: clamp(48px, 6vw, 88px); }
.reviews__list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.reviews__list > li { display: grid; grid-template-columns: minmax(0, 1fr); min-width: 0; }
.reviews .review { margin-top: 0; overflow-wrap: anywhere; } /* solo parte una palabra si no cabe (texto al 200 % en 320 px) */
.reviews__link { margin-top: 20px; }
@media (min-width: 768px) {
  .reviews__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  margin-top: 24px;
  font-family: var(--font-display);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
}
.link-arrow .i { transition: transform 0.3s var(--ease-out); }
.link-arrow:hover .i { transform: translate(2px, -2px); }
.visit__video { margin-top: 18px; cursor: pointer; }
.visit__video .i { width: 16px; height: 16px; }

/* ---------- Visítanos ---------- */
.visit__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; align-items: start; }
.visit__media { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 0; }
.visit__map { margin-top: 20px; }
.visit__map iframe { display: block; width: 100%; aspect-ratio: 4 / 3; border: 0; border-radius: var(--radius); background: var(--ink-3); }
.address {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  margin-top: 36px;
  padding: 28px 0;
  border-block: 1px solid var(--line);
}
.address .i--lg { color: var(--red); margin-top: 6px; }
.address__lines {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0; /* la dirección se ajusta en vez de empujar la flecha fuera de la pantalla */
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(1.45rem, 1.05rem + 1.3vw, 2.15rem);
  line-height: 1.22;
  letter-spacing: -0.015em;
}
.address__go { width: 28px; height: 28px; margin-top: 6px; transition: transform 0.35s var(--ease-out); }
.address:hover .address__go { transform: translate(3px, -3px); }
.address:hover .address__lines span:first-child { text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 3px; text-underline-offset: 6px; }
.hours { display: flex; align-items: flex-start; gap: 10px; margin-top: 24px; font-family: var(--font-display); font-weight: 500; }
.hours .i { flex: none; width: 20px; height: 20px; margin-top: 0.2em; color: var(--red); }
.hours__note { display: block; }
.visit__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
@media (min-width: 960px) {
  .visit__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(56px, 8vw, 128px); }
  .visit__media { justify-items: stretch; }
}

/* ---------- Cierre ---------- */
.closing {
  position: relative;
  overflow: hidden;
  padding-block: clamp(110px, 15vw, 220px);
  text-align: center;
}
/* Lamas de fondo que se abren al entrar en pantalla (scroll-driven, mejora progresiva). */
.closing::before {
  content: '';
  position: absolute;
  inset: 0;
  --gap: 0px;
  background: repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.045) 0 calc(72px - var(--gap)), transparent calc(72px - var(--gap)) 72px);
  pointer-events: none;
}
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .closing::before { animation: slats-open linear both; animation-timeline: view(); animation-range: entry 0% cover 55%; }
  }
}
@keyframes slats-open { from { --gap: 0px; } to { --gap: 62px; } }
/* minmax(0, 1fr): una palabra más ancha que la pantalla (texto ampliado al 200 %) ya no ensancha la columna del cierre. */
.closing__inner { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; }
.closing__title {
  font-family: var(--font-display);
  font-weight: 250;
  font-size: clamp(2.5rem, 1rem + 7.4vw, 7.6rem);
  line-height: 1;
  letter-spacing: -0.045em;
  text-wrap: balance;
  overflow-wrap: anywhere; /* solo actúa si una palabra no cabe (texto al 200 % en móvil) */
  hyphens: auto;
}
/* La regla amarilla del cierre ocupa espacio real: como inline-block con borde inferior, la línea del título la
   contiene y el párrafo ya no la pisa (el padding de un elemento inline se dibuja fuera de la caja de línea). */
.closing__title .mark {
  display: inline-block;
  padding-bottom: 0.1em;
  border-bottom: clamp(3px, 0.05em, 6px) solid var(--yellow);
  background: none;
}
.closing .lede { margin-inline: auto; margin-top: clamp(24px, 2.4vw, 32px); }
.closing__ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 44px; }
/* Con texto ampliado, el relleno lateral de 2rem crecería con la letra y no dejaría sitio a «WhatsApp». */
.closing__ctas .btn--lg { padding-inline: min(2rem, 8vw); }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--line); padding-top: 72px; padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
.footer { container: footer / inline-size; }
.footer__grid { display: grid; gap: 40px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.footer__brand { grid-column: 1 / -1; }
.footer__brand img { width: 170px; }
.footer__brand p { color: var(--muted); max-width: 34ch; margin-top: 20px; font-size: 0.95rem; }
.footer__h {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}
.footer__list li a, .footer__addr {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  font-size: 0.97rem;
  transition: color 0.2s;
}
.footer__addr { display: block; line-height: 1.5; }
.footer__hours { margin-top: 10px; color: var(--muted); font-size: 0.92rem; line-height: 1.5; }
.footer__list li a { min-height: 44px; flex-wrap: wrap; overflow-wrap: anywhere; } /* correo y usuario largos con texto ampliado */
.footer__note { margin-left: 2px; font-size: 0.78rem; color: var(--muted); }
.footer__list .i { color: var(--muted); }
.footer__list a:hover, .footer__addr:hover { color: var(--yellow); }
.footer__base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 32px;
  margin-top: 64px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.85rem;
}
.footer__base p { padding-block: 6px; }
/* Enlaces legales: visibles en todas las páginas, con área táctil de 44 px. */
.footer__legal ul { display: flex; flex-wrap: wrap; gap: 0 24px; }
.footer__legal a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 4px; }
.footer__legal a:hover { color: var(--yellow); text-decoration-color: currentColor; }
.footer__legal a[aria-current="page"] { text-decoration-color: var(--yellow); text-decoration-thickness: 2px; }
@media (min-width: 900px) {
  .footer { padding-bottom: 40px; }
  /* Las cuatro columnas solo si caben con el tamaño de texto actual (55rem = 880 px al 100 %); si no, sigue en dos. */
  @container footer (min-width: 55rem) {
    .footer__grid { grid-template-columns: 1.5fr 1.1fr 1fr 0.8fr; }
    .footer__brand { grid-column: auto; }
    .footer__list li a { flex-wrap: nowrap; overflow-wrap: normal; }
  }
}
@media (max-width: 400px) {
  .hero .eyebrow { letter-spacing: 0.18em; }
  .hero__ctas { margin-top: 22px; }
}
@media (max-width: 420px) {
  .footer__grid { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Barra móvil ---------- */
.mbar {
  position: fixed;
  inset: auto 0 0;
  z-index: 40;
  display: flex;
  gap: 8px;
  padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, #141416 90%, transparent);
  -webkit-backdrop-filter: blur(12px);
          backdrop-filter: blur(12px);
  --focus: var(--yellow);
  transform: translateY(110%);
  transition: transform 0.45s var(--ease-out);
}
.mbar.is-visible { transform: none; }
.mbar a {
  min-height: 50px;
  line-height: 1.2;
  text-align: center;
  overflow-wrap: anywhere;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: var(--pill);
  font-family: var(--font-display);
  font-weight: 500;
}
.mbar__wa { flex: 1; background: var(--yellow); color: var(--ink); }
.mbar__call { width: 50px; border: 1px solid rgba(242, 242, 239, 0.34); color: var(--bone); }
.mbar .i { width: 20px; height: 20px; }
@media (min-width: 768px) { .mbar { display: none; } }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------- Párrafos de lectura justificados (preferencia de Madeliza, 2026-11-13) ----------
   Solo párrafos de varias líneas; títulos, botones, listas, direcciones, horarios, pies de foto y la aclaración legal no se tocan.
   Se justifica cuando la columna mide al menos 21em (336 px con texto normal; unas 42 letras por línea). En columnas más
   estrechas (320–360 px, pasos de 2 columnas, tarjetas en móvil y texto al 200 %), sin diccionario de guiones en español
   (Chrome de escritorio en Windows no siempre lo trae) los espacios llegaban a 2–5em; ahí queda alineado al inicio.
   La justificación no cambia dónde se parten las líneas. */
.craft__copy, .catalog__head, .product__info, .showroom__copy, .space__text, .story__lead, .value,
.finance__lead, .steps li, .visit__info, .pay__cards { container-type: inline-size; }
@container (min-width: 21em) {
  .craft__copy > .lede, .catalog__head .lede, .product__info > p:not(.ideal), .showroom__copy .lede,
  .space__text p, .story__body, .finance__intro, .steps p, .visit__info > .lede, .pay__lede {
    text-align: justify;
    text-align-last: start;
    -webkit-hyphens: auto;
    hyphens: auto;
  }
}

/* Misión y visión tienen letra mayor (1.02–1.15rem): se justifican cuando el interior de la tarjeta mide 28em (448 px).
   En 1024 px, con dos tarjetas de unas 42 letras por línea, quedaban espacios de casi 2em; en móvil, de 3–4em por
   «distinguiéndonos» y «recubrimiento». Ambos bloques comparten siempre la misma alineación. */
@container (min-width: 28em) {
  .value__text { text-align: justify; text-align-last: start; }
}
/* Pasos del proceso: la lista (.craft__steps) ya es contenedor. Con el verbo al lado (12.5rem + 20 px), el texto solo
   llega a unos 20em cuando la lista mide 34em; apilados (hasta 700 px), basta con 21em. */
@container (min-width: 34em) {
  .craft__steps p { text-align: justify; text-align-last: start; -webkit-hyphens: auto; hyphens: auto; }
}
@media (max-width: 700px) {
  @container (min-width: 21em) {
    .craft__steps p { text-align: justify; text-align-last: start; -webkit-hyphens: auto; hyphens: auto; }
  }
}

/* ---------- Aviso del mapa bajo demanda ---------- */
.visit__map-note { margin-top: 10px; max-width: 52ch; color: var(--muted); font-size: 0.88rem; }
.visit__map-note a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Preguntas frecuentes ---------- */
.faq { background: var(--surface-2); }
.faq__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(32px, 5vw, 56px); }
.faq__head .lede a { color: var(--text); text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.faq__list { display: grid; grid-template-columns: minmax(0, 1fr); border-top: 1px solid var(--line); }
/* Acordeón nativo: toda la fila del summary es pulsable; varias respuestas pueden quedar abiertas; sin altura fija ni animación. */
.faq__item { border-bottom: 1px solid var(--line); container-type: inline-size; }
.faq__q {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 1.3em;
  column-gap: 20px;
  align-items: start;
  min-height: 44px;
  padding-block: 20px;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.1rem, 1.02rem + 0.35vw, 1.3rem);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--text);
}
.faq__q::-webkit-details-marker { display: none; }
/* Signo +/− decorativo: dibujado con fondos, sin texto, así no lo anuncian los lectores de pantalla. */
.faq__q::after {
  content: '';
  width: 1.3em;
  height: 1.3em;
  margin-top: -0.025em;
  border: 1px solid var(--line);
  border-radius: 50%;
  background:
    linear-gradient(currentColor, currentColor) center / 0.5em 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 2px 0.5em no-repeat;
}
.faq__item[open] > .faq__q::after { background: linear-gradient(currentColor, currentColor) center / 0.5em 2px no-repeat; }
@media (hover: hover) { .faq__q:hover::after { border-color: currentColor; } }
@media (forced-colors: active) { .faq__q::after { forced-color-adjust: none; border-color: currentColor; } }
.faq__item[open] > .faq__q { padding-bottom: 12px; }
.faq__a { padding-bottom: 22px; }
.faq__a p { max-width: 62ch; color: var(--muted); }
.faq__a p + p { margin-top: 0.75em; }
@media (min-width: 960px) {
  .faq__grid { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(48px, 7vw, 120px); align-items: start; }
  .faq__head { position: sticky; top: calc(var(--header-h) + 24px); }
}
/* Justificación solo con columna ancha (tableta y escritorio). En teléfonos (hasta ~27em) dejaba huecos de hasta 1,65em. */
@container (min-width: 29em) {
  .faq__item p { text-align: justify; text-align-last: start; -webkit-hyphens: auto; hyphens: auto; }
}

/* ---------- Páginas legales (términos, privacidad, cookies): sin JavaScript ---------- */
.legal-header { background: var(--ink-bg); color: var(--bone); --focus: var(--yellow); }
.legal-header__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; min-height: var(--header-h); padding-block: 8px; }
.legal-header__brand { display: inline-flex; align-items: center; min-height: 44px; }
.legal-header__brand img { width: 120px; height: auto; }
.legal-header .link-arrow { margin-top: 0; }
.legal { padding-block: clamp(40px, 6vw, 88px) clamp(64px, 9vw, 128px); }
.legal__wrap { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
.legal__docs ul { display: flex; flex-wrap: wrap; gap: 8px; }
.legal__docs a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 18px;
  border: 1px solid var(--line);
  border-radius: var(--pill);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.95rem;
  line-height: 1.2;
}
.legal__docs a:hover { border-color: var(--text); }
.legal__docs a[aria-current="page"] { background: var(--yellow); border-color: var(--yellow); color: var(--ink); }
.legal__toc { display: none; }
.legal__toc-title { font-family: var(--font-display); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); }
.legal__toc ol { margin-top: 12px; border-left: 1px solid var(--line); }
.legal__toc a { display: block; padding: 6px 0 6px 14px; color: var(--muted); font-size: 0.92rem; line-height: 1.35; }
.legal__toc a:hover { color: var(--text); }
.legal__doc { max-width: 68ch; container-type: inline-size; }
.legal__doc h1 { font-family: var(--font-display); font-weight: 300; font-size: clamp(2.1rem, 1.4rem + 2.6vw, 3.4rem); line-height: 1.05; letter-spacing: -0.028em; text-wrap: balance; }
.legal__date { margin-top: 14px; color: var(--muted); font-size: 0.95rem; }
.legal__doc h2 { margin-top: 2.2em; font-family: var(--font-display); font-weight: 500; font-size: clamp(1.3rem, 1.15rem + 0.5vw, 1.6rem); line-height: 1.2; letter-spacing: -0.01em; scroll-margin-top: 16px; }
.legal__doc p { margin-top: 1em; line-height: 1.7; }
.legal__doc h2 + p { margin-top: 0.7em; }
.legal__doc strong { font-weight: 600; }
.legal__doc a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; overflow-wrap: anywhere; }
.legal__doc a:hover { text-decoration-color: var(--yellow); text-decoration-thickness: 2px; }
.legal-page .footer { padding-bottom: calc(40px + env(safe-area-inset-bottom)); }
@media (min-width: 1024px) {
  .legal__wrap { grid-template-columns: minmax(200px, 250px) minmax(0, 1fr); column-gap: clamp(48px, 6vw, 96px); align-items: start; }
  .legal__docs { grid-column: 1 / -1; }
  .legal__toc { display: block; position: sticky; top: 24px; }
}
/* Justificado desde 24em de columna (384 px con texto normal). Los textos legales tienen palabras y datos largos
   («sessionStorage», el correo, direcciones): en teléfonos de 375–390 px, sin guiones en español, dejaban huecos de 2–3em,
   así que ahí quedan alineados al inicio. */
@container (min-width: 24em) {
  .legal__doc p { text-align: justify; text-align-last: start; -webkit-hyphens: auto; hyphens: auto; }
}

/* ---------- Preferencias de cookies y analítica (2026-11-22) ----------
   Aviso no modal en la parte inferior (encima de la barra móvil cuando está visible) y panel en <dialog>.
   Capas: intro 100 > menú 60 > header 50 > aviso 45 > barra móvil 40. Sin estilos en línea (CSP). */
.consent {
  position: fixed;
  inset: auto 0 0;
  z-index: 45;
  padding: 16px var(--gutter) calc(16px + env(safe-area-inset-bottom));
  background: var(--ink-bg);
  color: var(--bone);
  border-top: 1px solid rgba(242, 242, 239, 0.18);
  box-shadow: 0 -12px 32px rgba(0, 0, 0, 0.22);
  --focus: var(--yellow);
  max-height: 70vh;
  overflow-y: auto;
}
.consent { bottom: var(--mbar-alto, 0px); } /* consentimiento.js fija --mbar-alto con la altura real de la barra móvil visible */
.consent__inner { max-width: 1120px; margin-inline: auto; display: grid; gap: 10px 32px; }
.consent__title { font-family: var(--font-display); font-weight: 500; font-size: 1.1rem; line-height: 1.25; }
.consent__text { max-width: 70ch; color: rgba(242, 242, 239, 0.86); font-size: 0.95rem; line-height: 1.55; }
.consent__text a { color: var(--bone); text-decoration: underline; text-decoration-color: var(--yellow); text-underline-offset: 3px; }
.consent__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.consent__actions .btn { min-height: 44px; }
@media (min-width: 960px) {
  .consent__inner { grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
  .consent__title { grid-column: 1; }
  .consent__text { grid-column: 1; }
  .consent__actions { grid-column: 2; grid-row: 1 / span 2; }
}
.consent-dialog {
  width: min(560px, calc(100vw - 2 * var(--gutter)));
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  padding: clamp(20px, 4vw, 32px);
  border: 0;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
}
.consent-dialog::backdrop { background: rgba(10, 10, 12, 0.6); }
.consent-dialog > * + * { margin-top: 14px; }
.consent-dialog__title { font-family: var(--font-display); font-weight: 500; font-size: clamp(1.3rem, 1.15rem + 0.5vw, 1.6rem); line-height: 1.2; }
.consent-dialog p { line-height: 1.6; }
.consent-dialog__group { padding: 14px 0; border-top: 1px solid var(--line); }
.consent-dialog__group > p:not(.consent-dialog__name) { margin-top: 4px; color: var(--muted); font-size: 0.95rem; }
.consent-dialog__name { font-family: var(--font-display); font-weight: 500; }
.consent-dialog__name span { margin-left: 8px; color: var(--muted); font-family: var(--font-body); font-weight: 400; font-size: 0.9rem; }
.consent-dialog__toggle { display: flex; align-items: center; gap: 12px; min-height: 44px; cursor: pointer; }
.consent-dialog__toggle input { width: 22px; height: 22px; accent-color: var(--text); flex: none; }
.consent-dialog__status:empty { display: none; }
.consent-dialog__status { font-weight: 600; }
.consent-dialog__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.consent-dialog__more a { text-decoration: underline; text-underline-offset: 3px; }

/* Tablas en las páginas legales (política de cookies). Se desplazan en horizontal dentro de su caja en móvil. */
.legal__table { margin-top: 1.2em; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.legal__table table { width: 100%; min-width: 640px; border-collapse: collapse; font-size: 0.92rem; line-height: 1.45; }
.legal__table th, .legal__table td { padding: 10px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.legal__table thead th { font-family: var(--font-display); font-weight: 500; background: color-mix(in srgb, var(--text) 5%, transparent); }
.legal__table tbody tr:last-child td { border-bottom: 0; }

/* =========================================================================
   Black Friday 2026 (TEMPORAL, 24–30 de noviembre): sección #black-friday de la portada.
   Sistema de urgencia: el rojo de marca solo para «Black Friday»; el amarillo para la oferta.
   Retirar este bloque al terminar la campaña junto con la sección, los enlaces y black-friday.js.
   ========================================================================= */
.nav .nav__bf, .menu__links .nav__bf { color: var(--red); font-weight: 600; }
.header:not(.is-solid) .nav .nav__bf { color: #ff6a63; }

.bf-badge {
  display: inline-flex; align-items: center;
  padding: 0.42em 0.85em 0.36em; border-radius: 6px;
  background: var(--red); color: #fff;
  font-family: var(--font-display); font-weight: 800; font-size: 0.95rem;
  letter-spacing: 0.1em; line-height: 1; text-transform: uppercase;
}
.bf-badge--lg { font-size: clamp(1rem, 0.9rem + 0.5vw, 1.3rem); }
.bf-num { font-weight: 800; white-space: nowrap; background: var(--yellow); color: var(--ink); padding: 0 0.12em; border-radius: 4px; }

.bf { border-top: 6px solid var(--red); }
.bf__top { display: grid; gap: 28px; align-items: end; margin-bottom: clamp(32px, 4.5vw, 56px); }
.bf__title {
  margin-top: 18px;
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(2.3rem, 1.4rem + 3.8vw, 4.6rem);
  line-height: 1.02; letter-spacing: -0.035em; text-wrap: balance;
}
.bf__lede { margin-top: 18px; max-width: 48ch; color: var(--muted); font-size: clamp(1.02rem, 1rem + 0.3vw, 1.2rem); }
.bf__lede strong { color: var(--text); }

.bf-countdown__label {
  font-family: var(--font-display); font-weight: 600; font-size: 0.78rem;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted);
}
.bf-countdown__units { display: flex; gap: 10px; margin-top: 10px; }
.bf-countdown__units span {
  display: grid; justify-items: center; min-width: 70px; padding: 10px 8px 8px;
  border-radius: 8px; background: var(--ink); color: var(--bone);
}
.bf-countdown__units b {
  font-family: var(--font-display); font-weight: 700; line-height: 1;
  font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); font-variant-numeric: tabular-nums;
}
.bf-countdown__units small { margin-top: 4px; font-size: 0.72rem; color: #b9b9bf; }
.bf-countdown.is-over .bf-countdown__units { display: none; }
@media (prefers-color-scheme: dark) { .bf-countdown__units span { background: #26262b; } }
@media (min-width: 960px) { .bf__top { grid-template-columns: minmax(0, 1fr) auto; gap: 48px; } }

.bf-cards { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.bf-card {
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line);
}
.bf-card__media { position: relative; aspect-ratio: 4 / 3; background: var(--ink-3); }
.bf-card__media picture, .bf-card__media img { display: block; width: 100%; height: 100%; }
.bf-card__media img { object-fit: cover; }
.bf-card__flag {
  position: absolute; top: 14px; left: 14px; padding: 6px 12px; border-radius: var(--pill);
  background: var(--ink); color: var(--bone);
  font-family: var(--font-display); font-weight: 600; font-size: 0.8rem;
}
.bf-card__body { display: flex; flex-direction: column; flex: 1; padding: clamp(22px, 2.4vw, 30px); }
.bf-card__pct {
  font-family: var(--font-display); font-weight: 800; line-height: 0.85; letter-spacing: -0.055em;
  font-size: clamp(4rem, 3rem + 4vw, 5.6rem); color: var(--text);
}
.bf-card__pct span { font-size: 0.62em; letter-spacing: -0.02em; margin-left: 0.04em; }
.bf-card__pct::after { content: ''; display: block; width: 64px; height: 6px; margin-top: 14px; background: var(--yellow); }
.bf-card__name { margin-top: 16px; font-family: var(--font-display); font-weight: 600; font-size: clamp(1.4rem, 1.2rem + 0.6vw, 1.7rem); line-height: 1.15; }
.bf-card__desc { margin-top: 8px; color: var(--muted); }
.bf-card__list { display: grid; gap: 8px; margin: 18px 0 24px; font-size: 0.95rem; }
.bf-card__list li { display: flex; gap: 10px; align-items: flex-start; }
.bf-card__list .i { margin-top: 0.2em; color: var(--red); }
.bf-card__cta { margin-top: auto; width: 100%; }
.bf-card--featured {
  --text: var(--bone); --muted: #b9b9bf; --line: rgba(255, 255, 255, 0.12);
  background: var(--ink); color: var(--bone); border-color: var(--ink);
}
.bf-card--featured .bf-card__pct { color: var(--yellow); }
.bf-card--featured .bf-card__pct::after { background: var(--red); }
.bf-card--featured .bf-card__list .i { color: var(--yellow); }
.bf-card--featured .bf-card__flag { background: var(--yellow); color: var(--ink); }
@media (prefers-color-scheme: dark) { .bf-card--featured { background: #000; border-color: rgba(255, 255, 255, 0.14); } }
@media (min-width: 760px) { .bf-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 760px) and (max-width: 1099px) {
  .bf-card--featured { grid-column: 1 / -1; flex-direction: row; }
  .bf-card--featured .bf-card__media { flex: 0 0 50%; aspect-ratio: auto; }
  .bf-card--featured .bf-card__body { flex: 1; }
}
@media (min-width: 1100px) {
  .bf-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
  .bf-card--featured { transform: translateY(-14px); box-shadow: 0 24px 60px rgba(20, 20, 22, 0.22); }
}

.bf-install {
  display: flex; gap: 14px; align-items: flex-start;
  margin-top: clamp(28px, 3.5vw, 44px); padding: 18px 22px; border-radius: 10px;
  background: color-mix(in srgb, var(--yellow) 22%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--yellow) 60%, transparent);
}
.bf-install .i { flex: none; width: 22px; height: 22px; margin-top: 2px; }

.bf-steps { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; margin-top: clamp(28px, 3.5vw, 44px); }
.bf-steps li { display: flex; gap: 18px; padding: 18px 0; border-top: 1px solid var(--line); }
.bf-steps__n { flex: none; padding-top: 3px; font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; color: var(--red); }
.bf-steps h3 { font-family: var(--font-display); font-weight: 600; font-size: 1.15rem; line-height: 1.2; }
.bf-steps p { margin-top: 6px; color: var(--muted); font-size: 0.95rem; }
@media (min-width: 900px) {
  .bf-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
  .bf-steps li { border-top: 3px solid var(--text); }
}

.bf__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; margin-top: clamp(24px, 3vw, 36px); }
.bf__note { display: flex; gap: 10px; align-items: flex-start; max-width: 46ch; font-size: 0.9rem; color: var(--muted); }
.bf__note .i { margin-top: 0.2em; }

.bf-terms { margin-top: clamp(28px, 3.5vw, 40px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.bf-terms summary {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 18px 0; cursor: pointer; list-style: none;
  font-family: var(--font-display); font-weight: 600; font-size: 1.1rem;
}
.bf-terms summary::-webkit-details-marker { display: none; }
.bf-terms summary::after { content: '+'; font-size: 1.5rem; line-height: 1; transition: transform 0.25s var(--ease-out); }
.bf-terms[open] summary::after { transform: rotate(45deg); }
.bf-terms__list { display: grid; gap: 10px; padding-bottom: 22px; font-size: 0.95rem; color: var(--muted); }
.bf-terms__list li { position: relative; padding-left: 20px; }
.bf-terms__list li::before { content: ''; position: absolute; left: 0; top: 0.68em; width: 8px; height: 3px; background: var(--red); }
.bf-terms__list a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; }
