/* ============================================================
   musi — estilos del sitio
   Oscuro por diseño, de esquinas casi rectas y líneas finas. Todo lo que
   se ve es un componente del vault; aquí solo van el diseño de página
   (rejillas, aire, tipografía de los textos) y los colores del tema.
   ============================================================ */

:root {
  --bg: #09090b;
  --surface: #111114;
  --surface-2: #18181c;
  --border: #212127;
  --border-strong: #34343c;
  --text: #ededf0;
  --muted: #8b8b94;
  --accent: #5b4ff0; /* índigo sólido: fondos de botones y marcas */
  --accent-deep: #3a2fb8; /* el mismo, más profundo */
  --accent-text: #9d94ff; /* el acento cuando es texto o línea sobre el fondo */
  --accent-ink: #ffffff; /* texto sobre el acento */
  --accent-2: #f5b544; /* el segundo color, que contrasta con el acento */
  --accent-2-ink: #0b0b0e; /* texto sobre el segundo color */
  --radius: 4px;
  --gutter: clamp(1rem, 3vw, 2.5rem);
  --header: 3.7rem; /* alto de la barra fija */
  /* Compatibilidad con piezas que aún los usan */
  --dock: #ededf0;
  --dock-text: #0b0b0e;
  --card: #ededf0;
  --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --tok-comment: #62626c;
  --tok-keyword: #b3a8ff;
  --tok-attr: #8ec5ff;
  --tok-string: #9fdcb7;
  --tok-number: #e6c98f;
  --tok-variable: #d5b8ff;
  color-scheme: dark;
}

/* Tema claro: blanco y grises claros */
:root[data-theme="light"] {
  --bg: #f4f4f5;
  --surface: #ffffff;
  --surface-2: #ececef;
  --border: #e1e1e6;
  --border-strong: #c9c9d0;
  --text: #0b0b0e;
  --muted: #62626b;
  --accent-2-ink: #ffffff; /* en claro el segundo color es oscuro */
  --dock: #0b0b0e;
  --dock-text: #f4f4f5;
  --card: #ffffff;
  --tok-comment: #8a8a93;
  --tok-keyword: #4a3fe0;
  --tok-attr: #1d5fbf;
  --tok-string: #2f7a4a;
  --tok-number: #9a6700;
  --tok-variable: #7c3aed;
  color-scheme: light;
}

/* ---------- Paletas ----------
   theme.js pone data-palette en <html>. Cada paleta tiene dos colores que
   contrastan: --accent (sólido, para fondos y marcas) y --accent-2 (el
   detalle: números, índices, lo que se enciende). En modo claro los dos se
   oscurecen para leerse sobre blanco. "musi" (índigo + ámbar) son los
   valores de :root. */
:root[data-theme="light"] {
  --bg: #f4f4f5;
  --surface: #ffffff;
  --surface-2: #ececef;
  --accent: #4338ca;
  --accent-deep: #312e81;
  --accent-text: #3f33d6;
  --accent-2: #b45309;
}

:root[data-palette="forest"] {
  --bg: #080a09;
  --surface: #0f1311;
  --surface-2: #161b18;
  --accent: #1f8a5e;
  --accent-deep: #14523a;
  --accent-text: #5fd39c;
  --accent-2: #f2c46d;
}

:root[data-palette="forest"][data-theme="light"] {
  --bg: #f4f4f5;
  --surface: #ffffff;
  --surface-2: #ececef;
  --accent: #17664a;
  --accent-deep: #0f4a35;
  --accent-text: #17664a;
  --accent-2: #b4441f;
}

:root[data-palette="ocean"] {
  --bg: #08090c;
  --surface: #0f1116;
  --surface-2: #161a21;
  --accent: #2563eb;
  --accent-deep: #1e3a8a;
  --accent-text: #7aa7ff;
  --accent-2: #5eead4;
}

:root[data-palette="ocean"][data-theme="light"] {
  --bg: #f4f4f5;
  --surface: #ffffff;
  --surface-2: #ececef;
  --accent: #1d4ed8;
  --accent-deep: #1e3a8a;
  --accent-text: #1d4ed8;
  --accent-2: #0f766e;
}

:root[data-palette="wine"] {
  --bg: #0b0809;
  --surface: #141012;
  --surface-2: #1c1619;
  --accent: #a3214a;
  --accent-deep: #6b1430;
  --accent-text: #f07a9c;
  --accent-2: #f3c9a8;
}

:root[data-palette="wine"][data-theme="light"] {
  --bg: #f4f4f5;
  --surface: #ffffff;
  --surface-2: #ececef;
  --accent: #8f1d3b;
  --accent-deep: #5e1227;
  --accent-text: #8f1d3b;
  --accent-2: #1f6f6b;
}

:root[data-palette="olive"] {
  --bg: #09090a;
  --surface: #121310;
  --surface-2: #191b16;
  --accent: #5f7a1f;
  --accent-deep: #3c4d12;
  --accent-text: #b5d260;
  --accent-2: #f0d9a0;
}

:root[data-palette="olive"][data-theme="light"] {
  --bg: #f4f4f5;
  --surface: #ffffff;
  --surface-2: #ececef;
  --accent: #4d6318;
  --accent-deep: #33420f;
  --accent-text: #4d6318;
  --accent-2: #9a3412;
}

/* Contacto: más oscuro que el resto en modo oscuro, teñido con el acento de
   la paleta; el Mesh Background y la foto también siguen la paleta. */
:root:has(main.page--contact):not([data-theme="light"]) {
  --bg: color-mix(in srgb, var(--accent) 9%, #040406);
  --surface: color-mix(in srgb, var(--accent) 12%, #09090c);
  --surface-2: color-mix(in srgb, var(--accent) 16%, #0e0e12);
  --border: color-mix(in srgb, var(--accent) 22%, #17171c);
  --border-strong: color-mix(in srgb, var(--accent) 32%, #24242b);
}

.page--contact {
  --mesh-bg: var(--bg);
  --mesh-c1: color-mix(in srgb, var(--accent) 75%, #000000);
  --mesh-c2: color-mix(in srgb, var(--accent-deep) 80%, var(--accent-2));
  --mesh-c3: color-mix(in srgb, var(--accent) 22%, #000000);
  --mesh-c4: color-mix(in srgb, var(--accent-deep) 85%, #000000);
  /* La foto: su luz es índigo; cada paleta la gira hacia su propio tono */
  --photo-hue: 0deg;
  --photo-tone: contrast(1.06) saturate(1.08);
  --photo-grain: 0.32;
}

:root[data-theme="light"] .page--contact {
  --mesh-c1: color-mix(in srgb, var(--accent) 30%, #ffffff);
  --mesh-c2: color-mix(in srgb, var(--accent-2) 28%, #ffffff);
  --mesh-c3: #ffffff;
  --mesh-c4: color-mix(in srgb, var(--accent) 18%, #ffffff);
  --photo-tone: contrast(1.02) saturate(0.95) brightness(1.06);
  --photo-grain: 0.42;
}

:root[data-palette="forest"] .page--contact { --photo-hue: -92deg; }
:root[data-palette="ocean"] .page--contact { --photo-hue: -24deg; }
:root[data-palette="wine"] .page--contact { --photo-hue: 96deg; --photo-tone: contrast(1.04) saturate(0.78); }
:root[data-palette="olive"] .page--contact { --photo-hue: -165deg; }

/* Al cambiar de paleta la página se funde de una a otra */
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.45s;
  animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}

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

[hidden] {
  display: none !important;
}

html {
  scroll-padding-top: calc(var(--header) + 1rem);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 300 16px/1.5 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.5s ease-out;
}

h1,
h2,
h3 {
  font-weight: 400;
}

strong {
  font-weight: 500;
}

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

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

:focus-visible {
  outline: 2px solid var(--accent-text);
  outline-offset: 3px;
}

main {
  max-width: 100%;
  margin: 0 auto;
  padding: var(--header) var(--gutter) 4rem;
  /* Las piezas con parallax pueden asomarse por los lados: se recortan en el
     borde de la ventana sin crear scroll horizontal (clip no rompe sticky) */
  overflow-x: clip;
}

/* Nota: las reglas que cambian piezas de los componentes musi llevan
   ":not(#_):not(#_)". Los componentes son etiquetas con su CSS blindado
   (pesa como un id); así estas reglas del sitio siguen mandando. */

/* Los tokens de un componente se heredan a los que lleva dentro: estos
   envoltorios los cortan (initial = sin valor, cada componente usa el suyo). */
.site-header__tools,
.hero__copy,
.contact__photo,
.contact__info,
.compare-pane,
.twin-piece,
.spot-live,
.spot-actions,
.reel-scene__pieces,
.closing__content,
.usage-live {
  --musi-pad: initial;
  --musi-gap: initial;
  --musi-rest: initial;
  --musi-width: initial;
  --musi-height: initial;
  --musi-radius: initial;
  --musi-bg: initial;
  --musi-fg: initial;
  --musi-size: initial;
  --musi-accent: initial;
  --musi-dot: initial;
  --musi-reach: initial;
  --musi-blur: initial;
  --musi-blob: initial;
  --musi-speed: initial;
  --musi-grain: initial;
  --musi-duration: initial;
  --musi-ease: initial;
}

/* ---------- Barra: el Line Header, fijo arriba ---------- */
.site-header:not(#_):not(#_) {
  min-height: var(--header);
  padding-inline: var(--gutter);
  border-bottom-color: var(--border);
  color: var(--text);
  /* Sin backdrop-filter: desenfocar lo que pasa por detrás (fondos animados)
     obliga a repintar la barra en cada cuadro. Casi opaca se ve igual. */
}

.site-header .musi-header__logo:not(#_):not(#_) {
  font-size: 1.25rem;
  font-weight: 500;
  letter-spacing: -0.05em;
}

.site-header .musi-header__logo sup:not(#_):not(#_) {
  margin-left: 0.1em;
  font-size: 0.45em;
  font-weight: 300;
  vertical-align: super;
}

/* El enlace de la página en la que estás queda subrayado */
.site-header [data-site-link][aria-current="page"]:not(#_):not(#_) {
  --musi-rest: 1 !important;
}

.site-header [data-site-link]:not(#_):not(#_) {
  letter-spacing: 0.01em;
}

.site-header__tools {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.site-settings .musi-linemenu__trigger:not(#_):not(#_) {
  color: var(--muted);
  font-size: 0.82rem;
}

.site-settings .musi-linemenu__item[aria-checked="true"]:not(#_):not(#_) {
  color: var(--accent-text);
}

/* La muestra de color de cada paleta en el menú de ajustes */
.site-swatch {
  display: inline-block;
  width: 1.4em;
  height: 0.7em;
  border-radius: 1px;
  vertical-align: -0.05em;
}

@media (max-width: 640px) {
  .site-header__tools {
    order: 2;
    margin-left: auto;
    gap: 0.8rem;
  }

  .site-header__talk {
    display: none;
  }
}

/* ---------- Tipografía de página ---------- */

.eyebrow {
  display: inline-flex;
  align-items: baseline;
  gap: 0.8rem;
  color: var(--muted);
  font: 400 0.72rem/1.2 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow > span {
  color: var(--accent-2);
}

.eyebrow > span::before {
  content: "[";
}

.eyebrow > span::after {
  content: "]";
}

/* Título grande: un Weight Title por línea */
.big-title {
  margin: 0;
}

.big-title__line:not(#_):not(#_) {
  display: block;
  --musi-size: clamp(3.2rem, 11.5vw, 11rem);
  --musi-weight: 300;
  line-height: 0.9;
  letter-spacing: -0.065em;
}

.hero__lead {
  max-width: 34rem;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  line-height: 1.55;
  text-wrap: pretty;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.1rem 2rem;
}

/* Componentes del vault usados como <button> en vez de enlace */
button.musi-basic:not(#_):not(#_),
button.musi-underline:not(#_):not(#_) {
  border: 0;
  cursor: pointer;
  font-family: inherit;
}

button.musi-underline:not(#_):not(#_) {
  padding-top: 0;
  padding-inline: 0;
  background: none;
}

/* ---------- Portadas de página ---------- */

.page-head {
  display: grid;
  justify-items: start;
  gap: 1.75rem;
  padding: clamp(4rem, 11vw, 8rem) 0 clamp(2.5rem, 6vw, 4rem);
}

/* Título a la izquierda y la entrada abajo a la derecha */
.page-head--split {
  grid-template-columns: minmax(0, 1fr) minmax(16rem, 26rem);
  align-items: end;
  gap: 1.75rem 3rem;
}

.page-head--split > div {
  display: grid;
  gap: 1.75rem;
  justify-items: start;
}

@media (max-width: 760px) {
  .page-head--split {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Home: portada ---------- */
/* El Dots Background ocupa todo el ancho; dentro va la portada */
.hero {
  margin-inline: calc(var(--gutter) * -1);
  margin-top: calc(var(--header) * -1);
}

.hero .musi-dots:not(#_):not(#_) {
  min-height: 100svh;
  border-bottom: 1px solid var(--border);
}

.hero__content:not(#_):not(#_) {
  box-sizing: border-box;
  justify-items: stretch;
  align-self: end;
  width: 100%;
  padding: calc(var(--header) + 5rem) var(--gutter) 1rem;
  text-align: left;
  pointer-events: none;
}

/* Lo que se puede tocar recibe el cursor; el resto deja pasar al canvas.
   El reinicio del kit (all: revert) lo heredaría en "none": va blindado. */
.hero__content :is(a, button, input, label, .big-title, .musi-weight):not(#_):not(#_),
.closing__content :is(a, button, input, label, .big-title, .musi-weight):not(#_):not(#_) {
  pointer-events: auto;
}

.hero__copy {
  display: grid;
  justify-items: start;
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

/* El titular MUSI: la inicial de cada línea, fija y del segundo color; el
   resto de la palabra rota (Rotate Text) */
.musi-title {
  display: grid;
  margin: 0;
}

.musi-title__line:not(#_):not(#_) {
  display: block;
  line-height: 0.92;
  white-space: nowrap;
}

.hero-initial {
  color: var(--accent-2);
  font-weight: 500;
}

.hero__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: end;
  gap: 1.5rem 3rem;
  width: 100%;
}

.hero__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: 100%;
  margin-top: clamp(1rem, 4vw, 3rem);
  border-top: 1px solid var(--border);
}

.hero__stats > * {
  padding: 1.25rem 1rem 1.5rem 0;
}

.hero__stats > * + * {
  padding-left: 1rem;
  border-left: 1px solid var(--border);
}

.hero__stats .musi-count:not(#_):not(#_) {
  --musi-muted: var(--muted);
}

@media (max-width: 760px) {
  .hero__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero__stats > :nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }

  .hero__stats > :nth-child(n + 3) {
    border-top: 1px solid var(--border);
  }
}

.home-marquee {
  margin-inline: calc(var(--gutter) * -1);
  padding-block: 1.25rem;
  border-bottom: 1px solid var(--border);
}

/* El home va más ágil: las animaciones de sus componentes duran menos.
   Los componentes toman estos tokens si no definen los suyos en línea. */
.page--home {
  --musi-duration: 0.36s;
  --musi-tempo: 0.65;
  --musi-grow-duration: 0.55s;
}

/* ---------- Bloques: cada sección del home ---------- */
.block {
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
  padding-block: clamp(4.5rem, 10vw, 8rem);
  border-bottom: 1px solid var(--border);
}

.block__head {
  display: grid;
  grid-template-columns: minmax(9rem, 0.6fr) minmax(0, 2fr) minmax(14rem, 1fr);
  align-items: start;
  gap: 1.5rem 2.5rem;
}

.block__title {
  margin: 0;
  font-size: clamp(2.1rem, 5vw, 4.6rem);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.055em;
}

.block__title span {
  color: var(--muted);
}

.block__aside {
  display: grid;
  justify-items: start;
  gap: 1rem;
  padding-top: 0.4rem;
}

.block__aside p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

@media (max-width: 960px) {
  .block__head {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Rejilla de celdas: líneas finas, como un índice ---------- */
.grid-cells {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr));
  gap: 1px;
  border: 1px solid var(--border);
  background: var(--border);
}

.cell {
  position: relative;
  overflow: clip;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 1rem;
  min-width: 0;
  min-height: 15rem;
  padding: 1rem;
  background: var(--bg);
  transition: background-color 0.5s ease-out;
}

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

.cell--wide {
  grid-column: span 2;
}

.cell__caption {
  display: flex;
  gap: 0.7rem;
  color: var(--muted);
  font: 400 0.68rem/1.2 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cell__caption > span {
  color: var(--accent-2);
}

.cell__caption a:hover {
  color: var(--text);
}

.cell__stage {
  display: grid;
  place-items: center;
  min-width: 0;
  padding-block: 1rem;
}

/* Columnas fijas según cuántas piezas hay: ninguna celda queda vacía */
.grid-cells--buttons {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.grid-cells--variants,
.grid-cells--controls,
.grid-cells--cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-cells--play {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 1100px) {
  .grid-cells--buttons,
  .grid-cells--play {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .grid-cells--variants,
  .grid-cells--controls,
  .grid-cells--cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .grid-cells--buttons,
  .grid-cells--variants,
  .grid-cells--controls,
  .grid-cells--cards,
  .grid-cells--play {
    grid-template-columns: minmax(0, 1fr);
  }
}

.grid-cells--cards .cell {
  min-height: 30rem;
}

.grid-cells--variants .cell {
  min-height: 13rem;
}

@media (max-width: 560px) {
  .cell--wide {
    grid-column: auto;
  }
}

/* Tipografía: el Weight Title grande arriba, las muestras en celdas */
.type-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  border: 1px solid var(--border);
  background: var(--border);
}

.type-grid__main {
  grid-column: 1 / -1;
  padding: clamp(2rem, 6vw, 4.5rem) 1rem;
  background: var(--bg);
}

.type-grid__main .musi-weight:not(#_):not(#_) {
  --musi-size: clamp(2.8rem, 9vw, 8.5rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

@media (max-width: 860px) {
  .type-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* El Infinite Grid, a todo lo ancho */
.infinite-stage {
  margin-inline: calc(var(--gutter) * -1);
  border-block: 1px solid var(--border);
}

.block--infinite {
  padding-bottom: 0;
  border-bottom: 0;
}

/* Formal o creativo: cada lado del comparador es un escenario con su card */
.compare-stage .musi-linecompare:not(#_):not(#_) {
  min-height: 30rem;
}

.compare-pane:not(#_):not(#_) {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  padding: 2rem;
  box-sizing: border-box;
}

/* Cada lado lleva las tres piezas; el Line Radio de arriba elige cuál se ve */
.compare-pane__item:not(#_):not(#_) {
  grid-area: 1 / 1;
  display: grid;
  place-items: center;
}

.compare-stage:has(input[name="compare"][value="card"]:checked) .compare-pane__item:not([data-compare-item="card"]),
.compare-stage:has(input[name="compare"][value="button"]:checked) .compare-pane__item:not([data-compare-item="button"]),
.compare-stage:has(input[name="compare"][value="switch"]:checked) .compare-pane__item:not([data-compare-item="switch"]) {
  display: none !important;
}

.compare-stage {
  display: grid;
  gap: 1.25rem;
}

.compare-pane--formal {
  background: #e7e7ea;
}

.compare-pane--creative {
  background: var(--accent-deep);
}

/* Reel Carousel: cada marco es una escena de color con piezas en vivo */
.reel-stage {
  margin-inline: calc(var(--gutter) * -1);
}

.reel-scene:not(#_):not(#_) {
  display: grid;
  place-items: center;
  padding-bottom: 14%;
  box-sizing: border-box;
}

/* Las piezas del Reel se activan solas (showcase.js) y no reciben el
   cursor: así el carrusel se arrastra o se gira desde cualquier punto */
.reel-scene__pieces,
.reel-scene__pieces * {
  pointer-events: none !important;
}

.reel-scene__pieces {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1.25rem 2rem;
}

.reel-scene--deep:not(#_):not(#_) { background: var(--accent-deep); color: #ffffff; }
.reel-scene--light:not(#_):not(#_) { background: #ededf0; color: #0b0b0e; }
.reel-scene--accent:not(#_):not(#_) { background: var(--accent); color: #ffffff; }
.reel-scene--second:not(#_):not(#_) { background: var(--accent-2); color: var(--accent-2-ink); }
.reel-scene--dark:not(#_):not(#_) { background: var(--surface-2); color: var(--text); }

/* El título y el botón del pie toman el color de texto de su escena */
.musi-reelcarousel__frame:has(.reel-scene--light) .musi-reelcarousel__caption:not(#_):not(#_) { color: #0b0b0e; }
.musi-reelcarousel__frame:has(.reel-scene--second) .musi-reelcarousel__caption:not(#_):not(#_) { color: var(--accent-2-ink); }
.musi-reelcarousel__frame:has(.reel-scene--dark) .musi-reelcarousel__caption:not(#_):not(#_) { color: var(--text); }

/* En foco: el Spotlight. En el panel va el componente propuesto, en vivo */
.spot-element {
  display: grid;
  justify-items: center;
  gap: 0.6rem;
  color: #ffffff;
  text-align: center;
}

.spot-live {
  display: grid;
  place-items: center;
  min-height: 9rem;
  padding: 1rem;
  box-sizing: border-box;
}

.spot-element__number {
  margin-top: 1rem;
  color: var(--accent-2);
  font: 400 0.68rem/1 var(--font-mono);
  letter-spacing: 0.1em;
}

.spot-element__name {
  margin: 0;
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: -0.03em;
}

.spot-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
}

.spot-stage .musi-spot__name:not(#_):not(#_) {
  letter-spacing: -0.05em;
}

.spot-stage .musi-spot__foot:not(#_):not(#_) {
  font: 400 0.72rem/1.3 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.75;
}

/* Reel en pantallas angostas: las piezas se reducen para caber en el marco
   y el título del pie es más pequeño */
@media (max-width: 640px) {
  .reel-scene:not(#_):not(#_) {
    padding: 1rem 0.75rem 34%;
  }

  .reel-scene__pieces {
    zoom: 0.68;
    max-width: 100%;
  }

  .reel-stage .musi-reelcarousel__caption .musi-weight:not(#_):not(#_) {
    --musi-size: 1.5em;
  }
}

/* Piezas pequeñas: el componente, centrado en su marco del carrusel */
.twin-stage {
  margin-inline: calc(var(--gutter) * -1);
}

.twin-piece {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  padding: 1rem;
  box-sizing: border-box;
  background: var(--surface);
  border: 1px solid var(--border);
}

.depth-scene,
.steps-scene {
  min-width: 0;
}

.steps-scene {
  margin-bottom: 2rem;
}

/* El cierre del home, sobre el Lines Background a todo lo ancho */
.closing {
  margin-inline: calc(var(--gutter) * -1);
}

.closing__lines:not(#_):not(#_) {
  box-sizing: border-box;
  justify-items: start;
  width: 100%;
  padding: clamp(6rem, 14vw, 11rem) var(--gutter);
  text-align: left;
  pointer-events: none;
}

.closing__content {
  display: grid;
  justify-items: start;
  gap: 2rem;
}

/* ---------- Pie: el Capsule Footer, en versión formal ---------- */
.site-footer {
  padding: 0;
}

/* A todo lo ancho: sin redondeo ni bordes a los lados */
.site-footer .musi-capfooter:not(#_):not(#_) {
  width: 100%;
  max-width: none;
  border-top: 1px solid var(--border);
  border-radius: 0;
  box-shadow: none;
  padding-inline: var(--gutter);
}

.site-footer .musi-capfooter__claim:not(#_):not(#_) {
  font-weight: 400;
  letter-spacing: -0.05em;
}

.site-footer .musi-capfooter__logo:not(#_):not(#_) {
  font-weight: 500;
  letter-spacing: -0.07em;
}

/* ---------- Transiciones entre páginas ----------
   La cortina no ocupa sitio: solo se ve mientras cubre la ventana. */
.site-transitions {
  height: 0;
}

/* ---------- Vault: índice lateral y tarjetas ---------- */
.vault {
  display: grid;
  grid-template-columns: 15.5rem minmax(0, 1fr);
  align-items: start;
  gap: clamp(1.5rem, 3vw, 3rem);
  border-top: 1px solid var(--border);
}

.vault__side {
  position: sticky;
  top: var(--header);
  display: grid;
  gap: 1.75rem;
  max-height: calc(100svh - var(--header));
  padding: 1.5rem 0.5rem 2rem 0;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

.vault__tools {
  display: grid;
  gap: 1.25rem;
}

.vault__switches {
  display: grid;
  gap: 0.9rem;
}

.vault__index {
  display: grid;
  gap: 1.6rem;
}

.vault__group {
  display: grid;
  gap: 0.65rem;
}

.vault__group-name {
  display: flex;
  justify-content: space-between;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  font: 400 0.66rem/1.2 var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.vault__group-name > span {
  color: var(--accent-2);
}

.vault__radios:not(#_):not(#_) {
  gap: 0.45rem;
}

.vault__radios .musi-lineradio__option:not(#_):not(#_) {
  width: 100%;
}

.vault__radios .musi-lineradio__text:not(#_):not(#_) {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
}

.vault__count {
  color: var(--muted);
  font: 400 0.7em/1.6 var(--font-mono);
}

/* Las categorías sin resultados se apagan */
.vault__radios [data-empty]:not(#_):not(#_) {
  opacity: 0.3;
}

.vault__toggle:not(#_):not(#_) {
  display: none;
}

.vault__main {
  min-width: 0;
  padding-top: 1.5rem;
}

.vault__current {
  margin: 0;
  color: var(--muted);
  font: 400 0.7rem/1.2 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.vault__current [data-index-current] {
  color: var(--text);
}

.category {
  padding-top: 2.5rem;
  /* Las secciones fuera de pantalla no se maquetan ni se pintan: con cientos
     de tarjetas, así la cortina de entrada al vault no da tirones. */
  content-visibility: auto;
  contain-intrinsic-size: auto 900px;
}

.category:first-child {
  padding-top: 1.25rem;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 21rem), 1fr));
  gap: 0.75rem;
  padding-top: 1.25rem;
}

.card {
  display: block;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.vault-card:not(#_):not(#_) {
  width: 100%;
  height: 100%;
  border: 1px solid var(--border);
  transition: border-color 0.4s ease-out;
}

.card:hover .vault-card:not(#_):not(#_),
.card:focus-visible .vault-card:not(#_):not(#_) {
  border-color: var(--border-strong);
}

.vault-card__preview:not(#_):not(#_) {
  display: block;
  width: 100%;
  height: clamp(17rem, 23vw, 22rem);
  border: 0;
  border-radius: 2px;
  background: var(--surface-2);
  /* Recibe el cursor para que el hover del componente funcione en la tarjeta;
     preview-runtime.js convierte el clic en abrir la página de detalle. */
}

.vault-card__title:not(#_):not(#_) {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
  padding: 0.75rem 0.4rem 0.35rem;
  overflow-wrap: anywhere;
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.empty {
  margin-top: 3rem;
  color: var(--muted);
}

/* Pantallas angostas: el índice va arriba y se pliega tras su botón */
@media (max-width: 900px) {
  .vault {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }

  .vault__side {
    position: static;
    max-height: none;
    padding-right: 0;
    overflow: visible;
  }

  .vault__toggle:not(#_):not(#_) {
    display: inline-flex;
    justify-self: start;
  }

  .vault__panel:not([data-open]) {
    display: none;
  }
}

/* ---------- Vault: vista en rueda ----------
   A la izquierda un Curve List con todos los componentes; a la derecha, el
   del centro en grande. */
.wheel {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 2rem;
  align-items: center;
  padding-top: 1.5rem;
}

.wheel[hidden],
.wheel[data-empty] {
  display: none;
}

.wheel__list {
  position: relative;
  min-width: 0;
}

.wheel__curve:not(#_):not(#_) {
  --musi-size: clamp(1.6rem, 3vw, 2.6rem);
  --musi-height: min(70vh, 38rem);
  --musi-inset: 0.5em;
  --musi-accent: var(--accent-text);
  --musi-muted: color-mix(in srgb, var(--text) 30%, transparent);
}

/* Las orillas de la rueda se desvanecen */
.wheel__list::before,
.wheel__list::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  z-index: 1;
  height: 18%;
  pointer-events: none;
}

.wheel__list::before {
  top: 0;
  background: linear-gradient(var(--bg), transparent);
}

.wheel__list::after {
  bottom: 2rem;
  background: linear-gradient(transparent, var(--bg));
}

.wheel__hint {
  margin: 0.6rem 0 0;
  color: var(--muted);
  font: 400 0.7rem/1.4 var(--font-mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.wheel__stage {
  display: grid;
  gap: 1rem;
  min-width: 0;
  padding: 0.6rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.wheel__preview {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  border: 0;
  border-radius: 2px;
  background: var(--surface-2);
  transition: opacity 0.35s ease-out;
}

/* Mientras llega el siguiente componente, el actual se apaga un poco */
.wheel[data-loading] .wheel__preview {
  opacity: 0.35;
}

.wheel__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.8rem 1.2rem;
  padding: 0 0.4rem 0.4rem;
}

.wheel__meta > div {
  flex: 1 1 12rem;
  min-width: 0;
}

.wheel__category {
  color: var(--muted);
  font: 400 0.7rem/1.2 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.wheel__name {
  margin: 0.25rem 0 0;
  overflow-wrap: anywhere;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 400;
  letter-spacing: -0.04em;
}

@media (max-width: 760px) {
  .wheel {
    grid-template-columns: minmax(0, 1fr);
    gap: 1rem;
  }

  .wheel__curve:not(#_):not(#_) {
    --musi-size: 1.6rem;
    --musi-height: 16rem;
  }
}

/* ---------- Detalle de un componente ---------- */

.back {
  padding-top: 1.75rem;
}

.head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  margin: 1.5rem 0 1.25rem;
}

.head > div {
  display: grid;
  justify-items: start;
  gap: 0.7rem;
}

.head h1 {
  margin: 0;
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
}

.head p {
  max-width: 44rem;
  margin: 0;
  color: var(--muted);
}

/* El banco de trabajo: el escenario fijo y, al lado, Personalizar o Código.
   Los dos miden lo mismo y no cambian de tamaño: el componente se queda
   quieto y centrado mientras cambias de pestaña o de control. */
.workbench {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(20rem, 1fr);
  gap: 0.75rem;
  height: clamp(32rem, calc(100svh - var(--header) - 2rem), 52rem);
}

.stage {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.stage iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Nombre y Reproducir, sobre la vista previa */
.stage__bar {
  position: absolute;
  inset: auto 0.75rem 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  pointer-events: none;
}

.stage__bar > * {
  pointer-events: auto;
}

.stage__name {
  color: var(--muted);
  font: 400 0.68rem/1.2 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.bench {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
  min-height: 0;
  padding: 0.9rem 1rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.bench__pane {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 0.9rem;
  min-height: 0;
}

.bench__pane--controls {
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

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

.panel__note {
  color: var(--muted);
  font-size: 0.82rem;
}

.controls {
  display: grid;
  gap: 1.4rem;
  padding-bottom: 0.5rem;
}

.code__bar {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 0.75rem;
}

.code__bar .musi-tabs:not(#_):not(#_) {
  flex: 1;
}

/* El código llena lo que queda del panel y hace scroll por dentro */
.bench__pane--code .musi-linescroll:not(#_):not(#_) {
  flex: 1;
  min-height: 0;
}

.code__pre {
  height: 100%;
  margin: 0;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  font: 300 0.78rem/1.65 var(--font-mono);
  tab-size: 2;
}

@media (max-width: 960px) {
  .workbench {
    grid-template-columns: minmax(0, 1fr);
    height: auto;
  }

  .stage {
    height: 62svh;
    min-height: 24rem;
  }

  .bench {
    height: 34rem;
  }
}

.deps {
  display: grid;
  gap: 1rem;
  margin-top: 4rem;
}

.deps p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.deps ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.deps li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.deps code {
  padding: 0.35em 0.7em;
  border: 1px solid var(--border);
  border-radius: 2px;
  background: var(--surface);
  font: 300 0.8rem/1.5 var(--font-mono);
  overflow-wrap: anywhere;
}

.tok-comment {
  color: var(--tok-comment);
  font-style: italic;
}

.tok-tag,
.tok-keyword {
  color: var(--tok-keyword);
}

.tok-attr {
  color: var(--tok-attr);
}

.tok-string {
  color: var(--tok-string);
}

.tok-number {
  color: var(--tok-number);
}

.tok-variable {
  color: var(--tok-variable);
}

/* ---------- Cómo se usa ---------- */

.prose {
  display: grid;
  gap: 1.25rem;
  max-width: 46rem;
  padding-top: 4.5rem;
}

.prose p {
  margin: 0;
  color: var(--muted);
}

.prose code {
  color: var(--text);
  font: 300 0.9em var(--font-mono);
}

.snippet {
  margin: 0;
  padding: 1.25rem 1.4rem;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  font: 300 0.82rem/1.65 var(--font-mono);
  tab-size: 2;
}

.snippet code {
  font: inherit;
}

/* El Copy Button de cada bloque de código, en su esquina */
.snippet-box {
  position: relative;
  min-width: 0;
}

.snippet-box__copy {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  z-index: 1;
}

.prose.example {
  max-width: 64rem;
}

.example__step {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 1.5rem 2.5rem;
  align-items: center;
  padding: 1.8rem 0;
  border-top: 1px solid var(--border);
}

.example__text {
  min-width: 0;
}

.example__number {
  color: var(--accent-text);
  font: 400 0.72rem var(--font-mono);
  letter-spacing: 0.1em;
}

.example__title {
  margin: 0.35rem 0 0.4rem;
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

/* El resultado en vivo: un escenario donde vive el componente */
.example__result {
  display: grid;
  place-items: center;
  min-height: 10rem;
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.example__subtitle {
  margin: 2.2rem 0 0;
  font-size: 1.25rem;
  font-weight: 400;
}

.example__gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr));
  gap: 1px;
  margin-top: 1rem;
  border: 1px solid var(--border);
  background: var(--border);
}

.example__piece {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 1rem;
  min-height: 10rem;
  padding: 1rem;
  background: var(--bg);
}

.example__piece > code {
  justify-self: start;
  color: var(--muted);
  font-size: 0.72rem;
}

.example__live {
  display: grid;
  place-items: center;
}

/* Celdas de texto: lo esencial y las variables */
.grid-cells--facts {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cell--text {
  grid-template-rows: auto 1fr;
  min-height: 11rem;
  padding: 1.25rem;
}

.cell__text {
  align-self: end;
  max-width: 26rem;
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
}

.cell__text strong,
.usage-note strong {
  color: var(--text);
  font-weight: 400;
}

.cell code,
.cell__text code,
.usage-note code,
.example code,
.musi-timeline__text code {
  color: var(--text);
  font: 400 0.88em var(--font-mono);
}

.cell__caption code {
  color: var(--accent-2);
  font-size: 1.15em;
  letter-spacing: 0;
  text-transform: none;
}

.usage-note {
  max-width: 46rem;
  margin: 0;
  color: var(--muted);
}

.usage-timeline,
.usage-faq {
  max-width: 52rem;
}

.usage-live {
  margin-top: 1rem;
}

.example__result.usage-live {
  margin-top: 0;
}

.example__pair {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

.closing--usage {
  margin-inline: 0;
  padding-block: clamp(5rem, 10vw, 8rem);
}

@media (max-width: 860px) {
  .grid-cells--facts {
    grid-template-columns: minmax(0, 1fr);
  }
}

.usage-help {
  margin-top: 3rem;
  border-top: 1px solid var(--border);
}

@media (max-width: 760px) {
  .example__step {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Contacto ---------- */
.contact {
  margin-inline: calc(var(--gutter) * -1);
  margin-top: calc(var(--header) * -1);
}

.contact .musi-mesh:not(#_):not(#_) {
  overflow: clip;
  min-height: 100svh;
  border-bottom: 1px solid var(--border);
}

.contact__content:not(#_):not(#_) {
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 6rem);
  width: 100%;
  padding: calc(var(--header) + 3rem) var(--gutter) 4rem;
  text-align: left;
  pointer-events: auto;
}

.contact__photo {
  justify-self: stretch;
  width: 100%;
  min-width: 0;
}

/* La foto: grande, quieta y con relieve. Una textura de papel (ruido con
   luz rasante) se mezcla en "overlay": marca el grano sin apagar el color. */
.contact__photo .musi-card:not(#_):not(#_) {
  position: relative;
  aspect-ratio: 3 / 4;
  width: min(100%, calc((100svh - var(--header) - 7rem) * 0.75));
  max-width: none;
  margin-inline: auto;
  background-position: 50% 38%;
  filter: hue-rotate(var(--photo-hue)) var(--photo-tone);
  transition: filter 0.6s ease-out;
  overflow: hidden;
}

.contact__photo .musi-card:not(#_):not(#_)::after {
  content: "";
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='r'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeDiffuseLighting lighting-color='%23ffffff' surfaceScale='2.2'%3E%3CfeDistantLight azimuth='225' elevation='48'/%3E%3C/feDiffuseLighting%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23r)'/%3E%3C/svg%3E") 0 0 / 260px 260px;
  mix-blend-mode: overlay;
  opacity: var(--photo-grain);
  pointer-events: none;
}

.contact__info {
  justify-self: stretch;
  display: grid;
  justify-items: start;
  gap: 2rem;
  min-width: 0;
  /* El correo es una palabra larga: en pantallas angostas se parte */
  overflow-wrap: anywhere;
}

.contact__info .hero__lead {
  color: var(--muted);
}

.contact__block {
  display: grid;
  gap: 1rem;
  width: 100%;
}

/* Rótulo pequeño delante de cada vía de contacto */
.contact__way {
  display: inline-block;
  min-width: 5.5rem;
  margin-right: 0.6rem;
  color: var(--muted);
  font: 400 0.62em/1 var(--font-mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.contact__note {
  max-width: 34em;
  margin: 0;
  color: var(--muted);
}

.contact__follow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.block--play .cell {
  min-height: 12rem;
}

@media (max-width: 860px) {
  .contact__content:not(#_):not(#_) {
    grid-template-columns: minmax(0, 1fr);
  }

  .contact__photo .musi-card:not(#_):not(#_) {
    width: 100%;
  }

  .contact__way {
    display: block;
    margin-bottom: 0.25rem;
  }
}

/* ---------- Demos: galería ----------
   Cada demo es una fila grande: su vista previa en vivo y su ficha. */
.demos {
  display: grid;
  gap: clamp(3rem, 7vw, 6rem);
  padding-block: 3rem 2rem;
  border-top: 1px solid var(--border);
}

.demo-entry {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(16rem, 1fr);
  align-items: center;
  gap: clamp(1.5rem, 4vw, 4rem);
  color: inherit;
  text-decoration: none;
}

.demo-entry:nth-child(even) {
  grid-template-columns: minmax(16rem, 1fr) minmax(0, 1.5fr);
}

.demo-entry:nth-child(even) .demo-entry__frame {
  order: 2;
}

.demo-entry__frame {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color 0.5s ease-out;
}

/* La demo a 1440 × 900, escalada al ancho del marco (--scale lo pone la página) */
.demo-entry__frame iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 1440px;
  height: 900px;
  border: 0;
  transform: scale(var(--scale, 0.5));
  transform-origin: 0 0;
  pointer-events: none;
}

.demo-entry:hover .demo-entry__frame,
.demo-entry:focus-visible .demo-entry__frame {
  border-color: var(--accent-text);
}

.demo-entry:focus-visible {
  outline: none;
}

.demo-entry__info {
  display: grid;
  justify-items: start;
  gap: 1rem;
}

.demo-entry__name {
  margin: 0;
  font: 500 clamp(2.2rem, 4.5vw, 4rem)/0.95 var(--font-sans);
  letter-spacing: -0.06em;
}

.demo-entry__summary {
  max-width: 30rem;
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.6;
}

.demo-entry__colors {
  display: flex;
}

.demo-entry__colors span {
  width: 1.4rem;
  height: 1.4rem;
  margin-right: 2px;
  border-radius: 2px;
}

.demo-entry__meta {
  color: var(--muted);
  font: 400 0.7rem/1.4 var(--font-mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.demo-entry__open {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding-bottom: 0.2rem;
  border-bottom: 1px solid currentColor;
}

.demo-entry__open svg {
  width: 1rem;
  height: 1rem;
  transition: translate 0.3s ease-out;
}

.demo-entry:hover .demo-entry__open svg {
  translate: 0.15rem -0.15rem;
}

@media (max-width: 800px) {
  .demo-entry,
  .demo-entry:nth-child(even) {
    grid-template-columns: 1fr;
  }

  .demo-entry:nth-child(even) .demo-entry__frame {
    order: 0;
  }
}

/* ---------- Profundidad (parallax del sitio) ----------
   depth.js mueve cada pieza ([data-depth]) según su profundidad, con el
   scroll y el cursor. --depth-range y --depth-pointer son sus recorridos. */
:root {
  --depth-range: 15rem;
  --depth-pointer: 1.4rem;
}

/* depth.js escribe el transform de cada pieza; aquí solo se le avisa al
   navegador que se va a mover, para que la pinte en su propia capa. */
[data-depth-ready] [data-depth] {
  will-change: transform;
}

@media (max-width: 800px) {
  :root {
    --depth-range: 5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  [data-depth] {
    transform: none !important;
  }

  body,
  .cell {
    transition: none;
  }
}
