/* ==========================================================================
   tbō · Capa de experiencia
   Tipografía gigante, scroll con peso, tarjetas que se apilan, mapa de
   proyectos, cursor propio, transición de píxeles y la mascota como guía.
   Se carga después de style.css. La intro (sección 34 de style.css) no se toca.
   ========================================================================== */

:root {
  --x-pad: clamp(1rem, 4vw, 2.5rem);
  --x-giant: clamp(3.3rem, 11.6vw, 12.5rem);
  --x-h2: clamp(2.2rem, 5.4vw, 5rem);
  --ease-back: cubic-bezier(.34, 1.56, .64, 1);
  --x-ink: #141418;
  --x-paper: #F6F4EF;
}

.x-mono {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.x-h2 {
  font-family: var(--f-display);
  font-size: var(--x-h2);
  font-weight: 800;
  font-stretch: 80%;
  letter-spacing: -0.035em;
  line-height: 0.95;
  margin-top: 0.75rem;
  text-wrap: balance;
}
.x-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 2rem; flex-wrap: wrap;
  margin-bottom: clamp(2rem, 5vw, 4rem);
}
.x-head .x-h2 { max-width: 16ch; }

/* ---------- Grano de película (muy sutil) ---------- */
.x-grain {
  position: fixed; inset: -50%;
  z-index: 9000;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: xGrain 1s steps(4) infinite;
}
html[data-theme='dark'] .x-grain { opacity: 0.07; }
@keyframes xGrain {
  0% { transform: translate(0, 0); } 25% { transform: translate(-3%, 2%); }
  50% { transform: translate(2%, -3%); } 75% { transform: translate(-2%, -1%); }
}

/* ==========================================================================
   HERO XL
   ========================================================================== */
.x-hero {
  min-height: 100svh;
  padding: 0;
  display: flex;
}
.x-hero__inner {
  position: relative;
  width: 100%;
  max-width: var(--wrap-wide);
  margin-inline: auto;
  padding: calc(var(--nav-h) + clamp(1.25rem, 4vh, 3rem)) var(--x-pad) clamp(1.5rem, 4vh, 2.5rem);
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100svh;
}
.x-hero__top { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.x-hero__coords { color: var(--c-muted-ink); }

.x-hero__title {
  align-self: center;
  margin: clamp(1rem, 4vh, 2.5rem) 0;
  font-family: var(--f-display);
  font-size: var(--x-giant);
  font-weight: 800;
  font-stretch: 75%;
  letter-spacing: -0.045em;
  line-height: 0.86;
  position: relative;
  z-index: 1;
}
.x-hero__title .line { padding-bottom: 0.04em; }
.x-hero__title .line:nth-child(2) { padding-left: 0.9em; }
.x-hero__title .line:nth-child(3) { padding-left: 0.3em; }
.x-hero .hero__outline { -webkit-text-stroke: clamp(1.5px, 0.22vw, 3px) var(--c-brand); }

/* Mascota protagonista */
.x-hero__mascot {
  position: absolute;
  right: clamp(1rem, 6vw, 7rem);
  top: 30%;
  z-index: 2;
  display: grid; justify-items: center; gap: 0.9rem;
  text-decoration: none; color: inherit;
}
.x-hero__mascot .mascot {
  width: clamp(110px, 14vw, 210px);
  border-radius: 24%;
  animation: xFloat 5s ease-in-out infinite;
  transition: transform 500ms var(--ease-back), box-shadow 300ms;
}
.x-hero__mascot:hover .mascot { transform: rotate(-8deg) scale(1.06); animation-play-state: paused; }
.x-bubble {
  position: relative;
  padding: 0.65rem 0.95rem;
  border-radius: 16px;
  background: var(--c-ink);
  color: var(--c-bg);
  font-size: 0.92rem; line-height: 1.3;
  text-align: center;
  box-shadow: var(--sh-2);
  transform-origin: 50% 0;
  animation: xBubble 6s var(--e-out) infinite;
}
.x-bubble::before {
  content: ''; position: absolute; left: 50%; top: -7px;
  width: 14px; height: 14px; margin-left: -7px;
  background: inherit; transform: rotate(45deg); border-radius: 3px;
}
@keyframes xFloat { 50% { transform: translateY(-14px) rotate(3deg); } }
@keyframes xBubble { 0%, 100% { transform: scale(1); } 6% { transform: scale(1.08) rotate(-2deg); } 12% { transform: scale(1); } }

.x-hero__foot {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr) auto;
  gap: clamp(1rem, 3vw, 2.5rem);
  align-items: end;
  position: relative; z-index: 1;
}
.x-hero__foot .hero__rotator { margin: 0; font-size: clamp(1.15rem, 2vw, 1.6rem); }
.x-hero__lead { color: var(--c-ink-soft); font-size: clamp(0.98rem, 1.15vw, 1.1rem); line-height: 1.55; max-width: 44ch; }
.x-hero__foot .hero__cta { margin: 0; justify-content: flex-end; }

.x-scrollcue {
  position: absolute; left: 50%; bottom: 0.4rem;
  transform: translateX(-50%);
  display: flex; align-items: center; gap: 0.6rem;
  color: var(--c-muted-ink);
  white-space: nowrap;
}
.x-scrollcue i { width: 1px; height: 26px; background: currentColor; position: relative; overflow: hidden; }
.x-scrollcue i::after { content: ''; position: absolute; left: 0; top: -100%; width: 1px; height: 100%; background: var(--c-brand); animation: xCue 1.8s var(--e-io) infinite; }
@keyframes xCue { to { top: 100%; } }

@media (max-width: 980px) {
  .x-hero__foot { grid-template-columns: 1fr; }
  .x-hero__foot .hero__cta { justify-content: flex-start; }
  .x-hero__mascot { top: auto; bottom: 46%; right: var(--x-pad); }
  .x-hero__mascot .mascot { width: 92px; }
  .x-bubble { font-size: 0.8rem; }
  .x-scrollcue { display: none; }
}
@media (max-width: 600px) {
  .x-hero__title .line:nth-child(2) { padding-left: 0; }
  .x-hero__mascot { position: relative; right: auto; bottom: auto; justify-self: end; margin: -0.5rem 0 1rem; grid-row: 2; align-self: start; grid-auto-flow: column; }
  .x-hero__inner { grid-template-rows: auto auto auto auto; }
}

/* ==========================================================================
   REEL: tarjeta inclinada que crece a pantalla completa (único bloque fijado)
   ========================================================================== */
.x-reel { position: relative; height: 230vh; }
.x-reel__sticky {
  position: sticky; top: 0;
  height: 100vh; height: 100svh;
  display: grid; place-items: center;
  overflow: hidden;
}
.x-reel__kicker { position: absolute; top: calc(var(--nav-h) + 1rem); left: var(--x-pad); color: var(--c-muted-ink); z-index: 3; }
.x-reel__card {
  --p: 0;
  position: relative; z-index: 2;
  display: block;
  width: 100vw; height: 100svh;
  overflow: hidden;
  border-radius: calc((1 - var(--p)) * 28px);
  transform: scale(calc(0.4 + var(--p) * 0.6)) rotate(calc((1 - var(--p)) * -7deg));
  box-shadow: 0 40px 90px -40px rgb(0 0 0 / 0.55);
  background: #0D0D10;
  color: #fff;
  will-change: transform;
}
.x-reel__slides img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.12);
  transition: opacity 900ms ease, transform 4.2s linear;
}
.x-reel__slides img.is-on { opacity: 1; transform: scale(1.02); }
.x-reel__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgb(0 0 0 / 0.25), transparent 35%, transparent 55%, rgb(0 0 0 / 0.65)); }
.x-reel__ui {
  position: absolute; inset: auto 0 0 0;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem;
  padding: clamp(1.25rem, 4vw, 3rem);
  opacity: calc(var(--p) * 1.4 - 0.4);
}
.x-reel__name {
  font-family: var(--f-display); font-weight: 800; font-stretch: 75%;
  font-size: clamp(2.2rem, 7vw, 7rem); letter-spacing: -0.04em; line-height: 0.9;
  flex: 1;
}
.x-reel__tag { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.45rem 0.8rem; border-radius: 999px; background: rgb(255 255 255 / 0.14); backdrop-filter: blur(8px); align-self: flex-start; position: absolute; top: clamp(1.25rem, 4vw, 3rem); left: clamp(1.25rem, 4vw, 3rem); }
.x-reel__tag i { width: 8px; height: 8px; border-radius: 50%; background: #3DDC84; box-shadow: 0 0 0 4px rgb(61 220 132 / 0.25); }
.x-reel__count b { color: var(--c-brand); font-weight: 600; }
.x-reel__claim {
  position: absolute; inset: 0; z-index: 1;
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  font-family: var(--f-display); font-weight: 800; font-stretch: 75%;
  font-size: clamp(3rem, 13vw, 13rem); letter-spacing: -0.045em; line-height: 0.82;
  color: var(--c-ink);
  pointer-events: none;
  text-align: center;
}
.x-reel__claim span:nth-child(2) { color: transparent; -webkit-text-stroke: clamp(1.5px, 0.2vw, 3px) var(--c-ink); }
.x-reel__claim span:nth-child(3) { color: var(--c-brand); }
@media (max-width: 700px) { .x-reel { height: 180vh; } }

/* ==========================================================================
   MARCAS: dos filas gigantes que se mueven con el scroll
   ========================================================================== */
.x-brands { padding: clamp(3rem, 8vw, 6rem) 0 clamp(2rem, 5vw, 4rem); overflow: hidden; }
.x-brands__label { text-align: center; color: var(--c-muted-ink); margin-bottom: 1.5rem; }
.x-brands__row { overflow: hidden; white-space: nowrap; padding-block: 0.6rem 1.4rem; }   /* aire para la sombra de las tarjetas */
.x-brands__track {
  display: inline-flex; align-items: center; gap: clamp(0.75rem, 1.6vw, 1.4rem);
  padding-right: clamp(0.75rem, 1.6vw, 1.4rem);   /* = gap: la mitad del ancho cae justo donde empieza la copia, el bucle no salta */
  will-change: transform;
}
.x-dup { display: inline-flex; align-items: center; gap: inherit; }
/* Logos: tarjeta blanca (se leen igual en claro y oscuro). --k = raíz de la proporción del logo:
   así un logo ancho y uno cuadrado ocupan una superficie parecida. */
.x-logo {
  --s: clamp(3rem, 5.4vw, 5rem);
  flex: none; display: grid; place-items: center;
  height: clamp(5.5rem, 9.4vw, 8.75rem);
  min-width: calc(var(--s) * 2.3);
  padding-inline: clamp(1rem, 2vw, 1.9rem);
  border-radius: clamp(18px, 2vw, 28px);
  background: #fff;
  box-shadow: 0 0 0 1px rgb(20 20 25 / 0.07), 0 18px 34px -24px rgb(20 20 25 / 0.4);
  transition: transform 300ms var(--ease-out, ease), filter 300ms, opacity 300ms;
}
.x-logo img { width: calc(var(--s) * var(--k, 1)); height: auto; max-height: 78%; object-fit: contain; transition: filter 300ms, opacity 300ms; }
.x-logo--txt { font: 700 clamp(1.1rem, 1.9vw, 1.7rem)/1 var(--f-ui, var(--f-display)); letter-spacing: -0.02em; color: #141418; }
.x-logo:hover { transform: translateY(-4px) rotate(-1.5deg); }
/* segunda fila: logos en gris (la tarjeta sigue blanca); a color al pasar el cursor */
.x-brands__row--soft .x-logo img { filter: grayscale(1); opacity: 0.6; }
.x-brands__row--soft .x-logo--txt { color: #8A8A92; }
.x-brands__row--soft .x-logo:hover img { filter: none; opacity: 1; }

/* ==========================================================================
   MANIFIESTO: las palabras se encienden con el scroll
   ========================================================================== */
.x-manifest { padding: clamp(4rem, 10vw, 9rem) 0; }
.x-manifest__text {
  margin-top: 1.5rem;
  font-family: var(--f-display); font-weight: 700; font-stretch: 87.5%;
  font-size: clamp(1.9rem, 4.6vw, 4.4rem); letter-spacing: -0.03em; line-height: 1.08;
  max-width: 22ch;
  text-wrap: pretty;
}
.x-manifest__text .xw { opacity: 0.14; transition: opacity 250ms linear, color 250ms linear; }
.x-manifest__text .xw.is-on { opacity: 1; }
.x-manifest__text em { font-style: italic; font-weight: 600; color: var(--c-brand); font-stretch: 100%; }
.x-manifest__text b { color: var(--c-brand); }
.x-inline {
  display: inline-block; vertical-align: middle;
  width: 1.9em; height: 0.95em;
  border-radius: 999px; overflow: hidden;
  margin: -0.15em 0.08em 0;
  transform: rotate(-4deg);
  box-shadow: var(--sh-2);
}
.x-inline img { width: 100%; height: 100%; object-fit: cover; }
.x-inline--mascot { width: 1em; height: 1em; border-radius: 26%; background: var(--c-brand); color: #fff; display: inline-grid; place-items: center; transform: rotate(6deg); animation: xFloat 4s ease-in-out infinite; }
.x-inline--mascot svg { width: 58%; height: 58%; }
.js .x-inline { opacity: 0.14; transition: opacity 300ms; }
.js .x-inline.is-on { opacity: 1; }

.x-stats {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: clamp(3rem, 7vw, 5.5rem);
  border-top: 1px solid var(--c-border-strong);
}
.x-stats > div { padding: 1.5rem 1.25rem 0 0; display: flex; flex-direction: column-reverse; gap: 0.4rem; }
.x-stats > div + div { padding-left: 1.25rem; border-left: 1px solid var(--c-border); }
.x-stats dd { font-family: var(--f-display); font-weight: 800; font-stretch: 75%; font-size: clamp(2.8rem, 6vw, 5.5rem); letter-spacing: -0.04em; line-height: 0.9; }
.x-stats dd sup { font-size: 0.45em; color: var(--c-brand); vertical-align: 0.9em; margin-left: 0.05em; }
.x-stats dt { color: var(--c-muted-ink); font-size: 0.9rem; max-width: 18ch; }
@media (max-width: 760px) {
  .x-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-stats > div:nth-child(3) { padding-left: 0; border-left: 0; }
  .x-stats > div { padding-bottom: 1.25rem; }
}

/* ==========================================================================
   SERVICIOS: tarjetas que se apilan (sticky, sin secuestrar el scroll)
   ========================================================================== */
.x-services { padding: clamp(4rem, 9vw, 8rem) 0 clamp(3rem, 6vw, 5rem); }
.x-stack { display: grid; gap: clamp(1.5rem, 4vh, 3rem); }
.x-card {
  --bg: var(--c-brand); --fg: var(--c-on-brand); --soft: rgb(28 9 0 / 0.14); --pxc: rgb(255 255 255 / 0.18);
  position: sticky;
  top: calc(var(--nav-h) + 0.5rem + var(--i) * 14px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
  min-height: min(76vh, 640px);
  padding: clamp(1.5rem, 4vw, 3.5rem);
  border-radius: clamp(22px, 3vw, 36px);
  background: var(--bg);
  color: var(--fg);
  overflow: hidden;
  transform-origin: 50% 0;
  box-shadow: 0 -20px 50px -30px rgb(0 0 0 / 0.35);
  transition: filter 300ms linear;
}
.x-card:nth-child(odd) { rotate: -0.6deg; }
.x-card:nth-child(even) { rotate: 0.6deg; }
.x-card--orange  { --bg: #FF5000; --fg: #1C0900; --soft: rgb(28 9 0 / 0.12); --pxc: rgb(255 234 30 / 0.35); }
.x-card--ink     { --bg: #141418; --fg: #F4F4F5; --soft: rgb(255 255 255 / 0.1); --pxc: rgb(255 80 0 / 0.35); }
.x-card--violet  { --bg: #773FFF; --fg: #FFFFFF; --soft: rgb(255 255 255 / 0.16); --pxc: rgb(20 20 24 / 0.22); }
.x-card--yellow  { --bg: #FFEA1E; --fg: #141418; --soft: rgb(20 20 24 / 0.1); --pxc: rgb(255 80 0 / 0.3); }
.x-card--paper   { --bg: var(--x-paper); --fg: #141418; --soft: rgb(20 20 24 / 0.08); --pxc: rgb(119 63 255 / 0.22); }
.x-card--orange2 { --bg: linear-gradient(135deg, #FF5000, #FF7A2E 60%, #FFB21E); --fg: #1C0900; --soft: rgb(28 9 0 / 0.12); --pxc: rgb(255 255 255 / 0.28); }
html[data-theme='dark'] .x-card--ink { --bg: #1E1E25; }
html[data-theme='dark'] .x-card--paper { --bg: #ECE9E2; }

.x-card__px { position: absolute; inset: 0; pointer-events: none; }
.x-card__px i { position: absolute; width: var(--s); height: var(--s); background: var(--pxc); }
.x-card__body { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 1.1rem; }
.x-card__kicker { display: flex; align-items: center; gap: 0.6rem; opacity: 0.85; }
.x-card__kicker b { display: inline-grid; place-items: center; min-width: 2.2em; height: 2.2em; border-radius: 8px; background: var(--soft); font-weight: 600; }
.x-card__title {
  font-family: var(--f-display); font-weight: 800; font-stretch: 75%;
  font-size: clamp(2.6rem, 6.4vw, 6.2rem); letter-spacing: -0.045em; line-height: 0.88;
  color: inherit;
  text-wrap: balance;
}
.x-card__tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.x-card__tags span { padding: 0.35rem 0.75rem; border-radius: 999px; background: var(--soft); font-size: 0.8rem; font-weight: 600; }
.x-card__text { font-size: clamp(1rem, 1.2vw, 1.15rem); line-height: 1.55; max-width: 44ch; opacity: 0.9; }
.x-card__link {
  display: inline-flex; align-items: center; gap: 0.55rem;
  padding: 0.75rem 1.15rem; border-radius: 999px;
  background: var(--fg); color: transparent; font-weight: 700; font-size: 0.92rem;
  text-decoration: none;
  transition: transform 300ms var(--ease-back);
}
.x-card__link { color: var(--bg); }
.x-card--orange2 .x-card__link { color: #FF5000; }
.x-card__link:hover { transform: translateX(4px) rotate(-2deg); }
.x-card__link .ico { width: 16px; height: 16px; }

.x-card__visual.svc__visual {
  position: relative; z-index: 1;
  height: clamp(260px, 42vh, 400px);
  margin: 0;
  border-radius: clamp(18px, 2vw, 26px);
  background: var(--c-surface);
  border: 1px solid rgb(0 0 0 / 0.06);
  box-shadow: 0 30px 60px -30px rgb(0 0 0 / 0.45);
  transform: rotate(2deg);
  overflow: hidden;
}
.x-card:nth-child(even) .x-card__visual { transform: rotate(-2deg); }
.x-card__visual .mg { transform: scale(1.18); }
/* ilustración del servicio en la tarjeta: se acerca despacio, la cruza un reflejo y crece al pasar el mouse */
.x-card__visual--art { background: #141418; border-color: rgb(255 255 255 / 0.06); }
.x-card__visual--art img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 72% 50%;
  transform-origin: 70% 50%; animation: xArtDrift 14s ease-in-out infinite alternate; animation-delay: calc(var(--i, 0) * -2.6s);
  transition: scale 700ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
.x-card__visual--art::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 38%, rgb(255 255 255 / 0.14) 49%, transparent 60%);
  transform: translateX(-130%); animation: xArtSheen 7s ease-in-out infinite; animation-delay: calc(var(--i, 0) * 1.1s);
}
.x-card:hover .x-card__visual--art img { scale: 1.06; }
@keyframes xArtDrift { from { transform: scale(1.04) translate(0, 0); } to { transform: scale(1.15) translate(-2.5%, 1%); } }
@keyframes xArtSheen { 0%, 64% { transform: translateX(-130%); } 100% { transform: translateX(130%); } }
@media (prefers-reduced-motion: reduce) { .x-card__visual--art img, .x-card__visual--art::after { animation: none; } }

@media (max-width: 860px) {
  .x-card { grid-template-columns: 1fr; min-height: 0; top: calc(var(--nav-h) + var(--i) * 8px); }
  .x-card__visual.svc__visual { height: 230px; order: -1; }
  .x-card__visual .mg { transform: none; }
}

/* ==========================================================================
   TÍTULO PIXELADO (canvas) — el texto real queda para lectores y buscadores
   ========================================================================== */
.x-pxtitle { position: relative; margin-top: 0.75rem; line-height: 0; }
.x-pxtitle__txt {
  display: block;
  font-family: var(--f-display); font-weight: 800; font-stretch: 75%;
  font-size: clamp(3rem, 10vw, 9.5rem); letter-spacing: -0.04em; line-height: 0.88;
  text-transform: uppercase;
}
.x-pxtitle canvas { display: block; width: 100%; }
.x-pxtitle.is-px .x-pxtitle__txt { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ==========================================================================
   NUESTRO TRABAJO: mapa de proyectos en perspectiva
   ========================================================================== */
.x-work { padding: clamp(4rem, 9vw, 8rem) 0 clamp(3rem, 6vw, 5rem); background: var(--c-bg-alt); overflow: hidden; }
.x-work__head { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 2rem; align-items: end; margin-bottom: clamp(1.5rem, 4vw, 3rem); }
.x-work__head .lead { justify-self: end; max-width: 36ch; }
@media (max-width: 860px) { .x-work__head { grid-template-columns: 1fr; } .x-work__head .lead { justify-self: start; } }

.x-map { position: relative; }
.x-map__viewport {
  position: relative;
  height: min(86vh, 820px);
  perspective: 1300px;
  perspective-origin: 50% 20%;
  overflow: hidden;
  cursor: grab;
  touch-action: pan-y;
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 12%, #000 86%, transparent);
  mask-image: linear-gradient(180deg, transparent, #000 12%, #000 86%, transparent);
}
.x-map.is-drag .x-map__viewport { cursor: grabbing; }
.x-map__plane {
  --cell: clamp(300px, 34vw, 480px);
  --tx: 0px; --ty: 0px; --tilt: 50deg;
  position: absolute; left: 50%; top: 50%;
  width: calc(var(--cell) * 3.4); height: calc(var(--cell) * 3.4);
  margin-left: calc(var(--cell) * -1.7); margin-top: calc(var(--cell) * -1.7);
  transform-style: preserve-3d;
  transform: rotateX(var(--tilt)) translate3d(var(--tx), var(--ty), 0);
  will-change: transform;
}
.x-map__grid {
  position: absolute; inset: -60%;
  background-image:
    linear-gradient(to right, var(--c-border-strong) 1px, transparent 1px),
    linear-gradient(to bottom, var(--c-border-strong) 1px, transparent 1px);
  background-size: calc(var(--cell) / 3) calc(var(--cell) / 3);
  opacity: 0.6;
}
.x-cluster {
  position: absolute;
  left: calc(50% + var(--gx) * var(--cell) * 1.08);
  top: calc(50% + var(--gy) * var(--cell) * 1.08);
  width: var(--cell);
  margin: calc(var(--cell) * -0.36) 0 0 calc(var(--cell) * -0.5);
  text-decoration: none; color: inherit;
  transform-style: preserve-3d;
  transition: transform 500ms var(--e-out);
}
.x-cluster__tiles {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 6px;
  aspect-ratio: 1.4;
  transform-style: preserve-3d;
}
.x-cluster__tiles img, .x-cluster__tiles i {
  width: 100%; height: 100%; min-height: 0;
  object-fit: cover; object-position: var(--op, 50% 50%);
  border-radius: 8px;
  box-shadow: 0 1px 0 rgb(0 0 0 / 0.08);
  transition: transform 600ms var(--e-out), box-shadow 600ms;
}
.x-cluster__tiles img:first-child { grid-row: span 2; }
.x-cluster__name {
  display: grid; place-items: end start;
  padding: 0.7rem;
  background: var(--k);
  color: #fff;
  font-style: normal; font-family: var(--f-display); font-weight: 800; font-stretch: 75%;
  font-size: clamp(0.95rem, 1.6vw, 1.5rem); letter-spacing: -0.02em; line-height: 0.95;
}
.x-cluster:hover .x-cluster__tiles > *, .x-cluster:focus-visible .x-cluster__tiles > * { box-shadow: 0 24px 40px -18px rgb(0 0 0 / 0.5); }
.x-cluster:hover .x-cluster__tiles > :nth-child(1), .x-cluster:focus-visible .x-cluster__tiles > :nth-child(1) { transform: translateZ(70px); }
.x-cluster:hover .x-cluster__tiles > :nth-child(2), .x-cluster:focus-visible .x-cluster__tiles > :nth-child(2) { transform: translateZ(40px); }
.x-cluster:hover .x-cluster__tiles > :nth-child(3), .x-cluster:focus-visible .x-cluster__tiles > :nth-child(3) { transform: translateZ(55px); }
.x-cluster:hover .x-cluster__tiles > :nth-child(4), .x-cluster:focus-visible .x-cluster__tiles > :nth-child(4) { transform: translateZ(30px); }
.x-cluster__label {
  display: block; margin-top: 0.6rem;
  font-family: var(--f-mono); font-size: 0.75rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--c-muted-ink);
}
.x-cluster__label b { color: var(--c-brand); font-weight: 600; margin-right: 0.35rem; }
.x-cluster--tbo .x-cluster__tiles { grid-template-columns: 1fr; grid-template-rows: 1.3fr 0.7fr; }
.x-cluster__mascot { display: grid; place-items: center; background: var(--c-brand); color: #fff; }
.x-cluster__mascot svg { width: 34%; height: auto; animation: xFloat 4s ease-in-out infinite; }
.x-cluster--tbo .x-cluster__name { background: var(--c-ink); color: var(--c-bg); place-items: center; text-align: center; }
.x-cluster:focus-visible { outline: none; }
.x-cluster:focus-visible .x-cluster__label { color: var(--c-ink); }

.x-map__hint {
  position: absolute; left: 50%; bottom: 3.6rem; transform: translateX(-50%);
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.6rem 1rem; border-radius: 999px;
  background: var(--glass-strong); backdrop-filter: blur(10px);
  border: 1px solid var(--c-border);
  color: var(--c-ink-soft);
  pointer-events: none;
  transition: opacity 400ms;
}
.x-map__hint i { width: 18px; height: 18px; border: 2px solid currentColor; border-radius: 50%; position: relative; animation: xDrag 2.2s var(--e-io) infinite; }
@keyframes xDrag { 0%, 100% { transform: translateX(-6px); } 50% { transform: translateX(6px); } }
.x-map.is-used .x-map__hint { opacity: 0; }
.x-map__ticker {
  position: absolute; left: 50%; bottom: 0.8rem; transform: translateX(-50%);
  width: min(560px, 86vw);
  overflow: hidden; white-space: nowrap;
  padding: 0.55rem 0; border-radius: 10px;
  background: var(--c-ink); color: var(--c-bg);
}
.x-map__ticker div { display: inline-block; padding-left: 100%; animation: xTicker 26s linear infinite; }
@keyframes xTicker { to { transform: translateX(-100%); } }
.x-work__foot { display: flex; justify-content: center; margin-top: 2rem; }

/* Ficha del proyecto (diálogo a pantalla completa con bento) */
.x-case {
  width: 100vw; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: var(--c-bg); color: var(--c-ink);
  overflow: auto;
}
.x-case::backdrop { background: rgb(0 0 0 / 0.5); }
.x-case[open] { animation: xCaseIn 600ms var(--e-out); }
@keyframes xCaseIn { from { clip-path: inset(48% 48% 48% 48% round 30px); } to { clip-path: inset(0 0 0 0 round 0); } }
.x-case__inner { min-height: 100%; padding: clamp(4.5rem, 8vw, 6rem) var(--x-pad) 2rem; max-width: var(--wrap-wide); margin-inline: auto; }
.x-case__close {
  position: fixed; top: 1rem; right: 1rem; z-index: 2;
  width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--c-ink); color: var(--c-bg); border: 0; cursor: pointer;
  transition: transform 300ms var(--ease-back);
}
.x-case__close:hover { transform: rotate(90deg); }
.x-case__bento {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-auto-rows: minmax(120px, auto);
  gap: 10px;
}
.x-case__bento > * { border-radius: 18px; overflow: hidden; margin: 0; }
.x-case__bento img { width: 100%; height: 100%; object-fit: cover; display: block; }
.x-case__hero { grid-column: span 8; grid-row: span 3; }
.x-case__info { grid-column: span 4; grid-row: span 3; background: var(--c-surface); border: 1px solid var(--c-border); padding: clamp(1.25rem, 2.5vw, 2rem); display: flex; flex-direction: column; gap: 0.9rem; }
.x-case__num { color: var(--c-brand); }
.x-case__title { font-family: var(--f-display); font-weight: 800; font-stretch: 75%; font-size: clamp(2.2rem, 4.4vw, 4rem); letter-spacing: -0.04em; line-height: 0.9; }
.x-case__client { color: var(--c-muted-ink); }
.x-case__text { color: var(--c-ink-soft); line-height: 1.6; }
.x-case__tags { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.x-case__tags span { padding: 0.3rem 0.7rem; border-radius: 999px; background: var(--c-muted); font-size: 0.8rem; font-weight: 600; }
.x-case__visit { margin-top: auto; align-self: flex-start; }
.x-case__crop--a { grid-column: span 5; grid-row: span 2; }
.x-case__crop--b { grid-column: span 4; grid-row: span 2; }
.x-case__crop--a img { object-position: 15% 80%; transform: scale(1.5); }
.x-case__crop--b img { object-position: 85% 20%; transform: scale(1.7); }
.x-case__url { grid-column: span 3; grid-row: span 2; background: var(--k, var(--c-brand)); color: #fff; display: grid; place-items: center; padding: 1rem; text-align: center; font-size: 0.85rem; word-break: break-all; }
.x-case__nav { display: flex; justify-content: space-between; margin-top: 1.5rem; }
.x-case__nav button { background: none; border: 0; color: var(--c-ink); font: 600 1rem var(--f-body); cursor: pointer; padding: 0.75rem 0; }
.x-case__nav button:hover { color: var(--c-accent); }
@media (max-width: 860px) {
  .x-case__bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-case__hero, .x-case__info { grid-column: 1 / -1; grid-row: auto; }
  .x-case__hero { aspect-ratio: 16 / 10; }
  .x-case__crop--a, .x-case__crop--b { grid-column: span 1; grid-row: auto; aspect-ratio: 1; }
  .x-case__url { grid-column: 1 / -1; grid-row: auto; min-height: 80px; }
}

/* ==========================================================================
   MUNDO tbō (vista previa del juego en el inicio)
   ========================================================================== */
.x-play { padding: clamp(4rem, 9vw, 8rem) 0; }
.x-play__grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.x-play__copy .lead { margin-top: 1.25rem; }
.x-play__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.5rem; margin-top: 2rem; }
.x-keys { color: var(--c-muted-ink); display: inline-flex; align-items: center; gap: 0.3rem; flex-wrap: wrap; }
.x-keys kbd { display: inline-grid; place-items: center; min-width: 1.9em; height: 1.9em; border-radius: 6px; border: 1px solid var(--c-border-strong); border-bottom-width: 3px; font: inherit; color: var(--c-ink); background: var(--c-surface); }
.x-play__screen {
  position: relative; display: block;
  aspect-ratio: 16 / 11;
  border-radius: clamp(20px, 3vw, 34px);
  overflow: hidden;
  background: #7FC46A;
  box-shadow: 0 40px 80px -40px rgb(0 0 0 / 0.5), 0 0 0 8px var(--c-surface), 0 0 0 9px var(--c-border);
  transform: rotate(1.5deg);
  transition: transform 500ms var(--ease-back);
}
.x-play__screen:hover { transform: rotate(0deg) scale(1.02); }
.x-play__canvas { width: 100%; height: 100%; display: block; image-rendering: pixelated; }
.x-play__badge {
  position: absolute; left: 50%; bottom: 1.1rem; transform: translateX(-50%);
  padding: 0.65rem 1.1rem; border-radius: 999px;
  background: var(--x-ink); color: #fff;
  box-shadow: 0 10px 24px -10px rgb(0 0 0 / 0.6);
  animation: xBubble 3s var(--e-out) infinite;
  white-space: nowrap;
}
@media (max-width: 860px) { .x-play__grid { grid-template-columns: 1fr; } }

/* ==========================================================================
   CTA FINAL: marquesina gigante + tarjeta inclinada
   ========================================================================== */
.x-cta { padding: clamp(3rem, 7vw, 6rem) 0 clamp(4rem, 9vw, 8rem); overflow: hidden; }
.x-cta__marquee { overflow: hidden; white-space: nowrap; margin-bottom: clamp(2rem, 5vw, 4rem); transform: rotate(-2deg); background: var(--c-brand); color: var(--c-on-brand); padding: 0.6rem 0; }
.x-cta__track { display: inline-flex; align-items: center; gap: 1.5rem; animation: xMarq 18s linear infinite; font-family: var(--f-display); font-weight: 800; font-stretch: 75%; font-size: clamp(2.5rem, 7vw, 6.5rem); letter-spacing: -0.04em; line-height: 1; }
.x-cta__track i { width: 0.35em; height: 0.35em; background: currentColor; border-radius: 24%; flex: none; }
@keyframes xMarq { to { transform: translateX(-50%); } }
.x-cta__grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.x-cta__title { font-family: var(--f-display); font-weight: 800; font-stretch: 75%; font-size: clamp(2.8rem, 7.5vw, 7.2rem); letter-spacing: -0.045em; line-height: 0.88; text-wrap: balance; }
.x-cta__title .hero__outline { -webkit-text-stroke: clamp(1.5px, 0.2vw, 3px) var(--c-brand); }
.x-cta__card {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: 26px; padding: clamp(1.5rem, 3vw, 2.5rem);
  box-shadow: var(--sh-3);
  transform: rotate(3deg);
  display: flex; flex-direction: column; align-items: flex-start; gap: 1.1rem;
  transition: transform 500ms var(--ease-back);
}
.x-cta__card:hover { transform: rotate(0deg); }
.x-cta__kicker { color: var(--c-brand); }
.x-cta__card > p:not(.x-cta__kicker) { color: var(--c-ink-soft); line-height: 1.6; }
.x-cta__list { list-style: none; padding: 1rem 0 0; margin: 0; width: 100%; border-top: 1px dashed var(--c-border-strong); display: grid; gap: 0.4rem; font-size: 0.92rem; color: var(--c-muted-ink); }
.x-cta__list a { color: var(--c-ink); text-decoration: none; }
.x-cta__list a:hover { color: var(--c-accent); }
@media (max-width: 860px) { .x-cta__grid { grid-template-columns: 1fr; } .x-cta__card { transform: none; } }

/* ==========================================================================
   CAPA GLOBAL: cursor, transición de píxeles, mascota guía
   ========================================================================== */
.x-cursor { position: fixed; left: 0; top: 0; z-index: 9500; pointer-events: none; opacity: 0; transition: opacity 300ms; }
.x-cursor.is-on { opacity: 1; }
.x-cursor__dot { position: absolute; width: 8px; height: 8px; margin: -4px; border-radius: 2px; background: var(--c-brand); }
.x-cursor__ring {
  position: absolute; width: 38px; height: 38px; margin: -19px;
  border: 1.5px solid var(--c-ink); border-radius: 12px;
  display: grid; place-items: center;
  transition: width 300ms var(--e-out), height 300ms var(--e-out), margin 300ms var(--e-out), background 300ms, border-color 300ms, border-radius 300ms;
}
.x-cursor__ring span { font: 600 0.7rem/1 var(--f-mono); letter-spacing: 0.12em; text-transform: uppercase; color: #fff; opacity: 0; transition: opacity 200ms; }
.x-cursor.is-link .x-cursor__ring { width: 56px; height: 56px; margin: -28px; border-color: var(--c-brand); border-radius: 16px; }
.x-cursor.is-label .x-cursor__ring { width: 92px; height: 92px; margin: -46px; background: var(--c-brand); border-color: var(--c-brand); border-radius: 50%; }
.x-cursor.is-label .x-cursor__ring span { opacity: 1; color: var(--c-on-brand); }
.x-cursor.is-label .x-cursor__dot { opacity: 0; }
.x-cursor.is-down .x-cursor__ring { transform: scale(0.85); }
@media (hover: hover) and (pointer: fine) {
  html.x-has-cursor, html.x-has-cursor a, html.x-has-cursor button, html.x-has-cursor [data-cursor] { cursor: none; }
  html.x-has-cursor input, html.x-has-cursor textarea, html.x-has-cursor select { cursor: auto; }
}

/* Transición entre páginas: mosaico de píxeles de marca (eco de la intro) */
.x-pt { position: fixed; inset: 0; z-index: 9800; pointer-events: none; display: grid; }
.x-pt i { background: var(--c-brand); transform: scale(0); transition: transform 380ms var(--e-out); }
.x-pt i:nth-child(5n+2) { background: var(--c-violet); }
.x-pt i:nth-child(7n+3) { background: var(--c-ink); }
.x-pt i:nth-child(11n+5) { background: var(--c-yellow); }
.x-pt.is-cover i { transform: scale(1.02); }
.x-pt.is-cover { pointer-events: auto; }

/* Mascota guía en la esquina */
.x-buddy {
  position: fixed; left: 1rem; bottom: 1rem; z-index: 90;
  display: flex; align-items: flex-end; gap: 0.6rem;
  text-decoration: none; color: inherit;
  transform: translateY(140%);
  transition: transform 700ms var(--ease-back);
}
.x-buddy.is-in { transform: none; }
.x-buddy__face {
  width: 58px; height: 58px; border-radius: 30%;
  background: var(--c-brand);
  display: grid; place-items: center;
  box-shadow: 0 14px 30px -12px rgb(255 80 0 / 0.8);
  transition: transform 400ms var(--ease-back);
}
.x-buddy:hover .x-buddy__face { transform: rotate(-10deg) scale(1.08); }
.x-buddy__face svg { width: 58%; height: 58%; overflow: visible; }
.x-buddy__face .eye { transform-box: fill-box; transform-origin: center; animation: blink 4.5s infinite; }
.x-buddy__face .eyes { transition: transform 160ms var(--e-out); }
.x-buddy__say {
  padding: 0.55rem 0.85rem; border-radius: 14px 14px 14px 4px;
  background: var(--c-ink); color: var(--c-bg);
  font-size: 0.82rem; font-weight: 600; white-space: nowrap;
  opacity: 0; transform: translateY(8px) scale(0.9); transform-origin: 0 100%;
  transition: opacity 300ms, transform 400ms var(--ease-back);
  margin-bottom: 0.9rem;
}
.x-buddy.is-talk .x-buddy__say, .x-buddy:hover .x-buddy__say, .x-buddy:focus-visible .x-buddy__say { opacity: 1; transform: none; }
.to-top { z-index: 91; }

/* ==========================================================================
   Movimiento reducido: todo queda quieto y legible
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  .x-grain, .x-cursor, .x-pt { display: none !important; }
  .x-reel { height: auto; }
  .x-reel__sticky { position: relative; height: auto; padding: 2rem var(--x-pad); }
  .x-reel__card { --p: 1 !important; width: 100%; height: auto; aspect-ratio: 16 / 9; border-radius: 24px; transform: none; }
  .x-reel__claim { display: none; }
  .x-reel__slides img:first-child { opacity: 1; transform: none; }
  .x-card { position: relative; top: 0; rotate: none; }
  .x-manifest__text .xw, .js .x-inline { opacity: 1; }
  .x-hero__mascot .mascot, .x-bubble, .x-inline--mascot, .x-cluster__mascot svg, .x-play__badge { animation: none; }
  .x-map__plane { --tilt: 0deg; }
  .x-cta__track, .x-map__ticker div { animation: none; }
}

/* ==========================================================================
   PANTALLA COMPLETA: láminas que suben, secciones de alto completo
   ========================================================================== */

/* Tokens oscuros locales: una sección puede ser oscura aunque la página sea clara */
.x-dark {
  color-scheme: dark;
  --c-bg: #0D0D10; --c-bg-alt: #0D0D10; --c-surface: #18181D;
  --c-ink: #F4F4F5; --c-ink-soft: #CACAD2; --c-muted: #222229; --c-muted-ink: #9C9CA6;
  --c-border: #26262E; --c-border-strong: #383842;
  --c-primary: #F4F4F5; --c-on-primary: #0D0D10; --c-accent: #FF7A45; --c-brand-soft: #26140A;
  --c-line: rgb(255 255 255 / 0.045); --c-hover: rgb(255 255 255 / 0.06);
  --glass: rgb(24 24 29 / 0.7); --glass-strong: rgb(24 24 29 / 0.88); --glass-solid: rgb(20 20 24 / 0.97);
  --c-shadow: 0 0 0; --mg-yellow: #FFEA1E;
  background: var(--c-bg);
  color: var(--c-ink);
}
html[data-theme='dark'] .x-dark { --c-bg: #141419; --c-bg-alt: #141419; --c-surface: #1D1D24; }

.x-sheet {
  --sp: 1;
  position: relative; z-index: 1;
  margin-top: -3rem;
  border-radius: clamp(28px, 4vw, 56px) clamp(28px, 4vw, 56px) 0 0;
  transform: scale(calc(0.94 + var(--sp) * 0.06));
  transform-origin: 50% 0;
  box-shadow: 0 -30px 60px -40px rgb(0 0 0 / 0.45);
}
.x-sheet--brand {
  --c-ink: #1C0900; --c-ink-soft: #3A1600; --c-muted-ink: #5A2A08; --c-border-strong: rgb(28 9 0 / 0.25); --c-surface: #FFF6EF;
  background: var(--c-brand);
  color: var(--c-ink);
}
.x-sheet--brand .grad-text { background: none; -webkit-text-fill-color: #fff; color: #fff; }
.x-sheet--brand .btn--accent { --btn-bg: #141418; --btn-fg: #fff; box-shadow: 0 12px 24px -12px rgb(0 0 0 / 0.6); }
.x-sheet--brand .btn--accent::before { background: #fff; }
.x-sheet--brand .btn--accent:hover { color: #141418; }
.x-sheet--brand .eyebrow { color: #1C0900; }
.x-sheet--brand .x-keys kbd { background: #fff; border-color: rgb(28 9 0 / 0.3); color: #1C0900; }
.x-cta.x-sheet { background: var(--c-bg); }

/* Alto completo y contenido centrado */
.x-manifest, .x-work, .x-play, .x-cta { min-height: 100svh; display: flex; flex-direction: column; justify-content: center; }
.x-work { padding-top: clamp(5rem, 10vw, 8rem); }
.x-work__head { grid-template-columns: 1fr; }
.x-work__head .lead { justify-self: start; }
.x-work .x-pxtitle__txt { font-size: clamp(3.5rem, 15vw, 15rem); }
.x-play { padding-block: clamp(5rem, 10vw, 9rem); }
.x-play .x-h2 { font-size: clamp(2.8rem, 7vw, 6.5rem); }
.x-play__screen { box-shadow: 0 50px 90px -40px rgb(0 0 0 / 0.6), 0 0 0 10px #fff, 0 0 0 11px rgb(28 9 0 / 0.2); transform: rotate(-2.5deg); }

/* ---------- Productos: cada uno a pantalla completa ---------- */
.x-products { padding-block: clamp(6rem, 11vw, 10rem) clamp(4rem, 8vw, 7rem); }
.x-products .section-head .title-lg { font-family: var(--f-display); font-size: clamp(2.6rem, 6.5vw, 6rem); font-weight: 800; font-stretch: 75%; letter-spacing: -0.045em; line-height: 0.9; max-width: 14ch; }
.x-products .product { min-height: 92svh; padding-block: clamp(2rem, 5vw, 4rem); }
.x-products .product + .product { margin-top: 0; border-top: 1px solid var(--c-border); }
.x-products .product .title-lg { font-family: var(--f-display); font-size: clamp(2.6rem, 6vw, 5.8rem); font-weight: 800; font-stretch: 75%; letter-spacing: -0.045em; line-height: 0.88; }
.x-products .product .lead { color: var(--c-ink-soft); }
.x-products .browser-wrap { transform: rotate(2.5deg); transition: transform 600ms var(--ease-back); }
.x-products .product--rev .browser-wrap { transform: rotate(-2.5deg); }
.x-products .browser-wrap:hover { transform: rotate(0) scale(1.02); }
.x-products .browser { box-shadow: 0 50px 100px -40px rgb(0 0 0 / 0.8), 0 0 0 1px var(--c-border); }
.x-products .product__name { background: var(--c-surface); }
.x-products .btn--ghost { --btn-bg: transparent; --btn-fg: var(--c-ink); border-color: var(--c-border-strong); }

/* ---------- Proceso: pasos en horizontal (fijado mientras se recorre) ---------- */
.x-process { position: relative; }
.x-process__sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; display: flex; flex-direction: column; justify-content: center; gap: clamp(1.5rem, 4vh, 3rem); padding-top: var(--nav-h); }
.x-process__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; flex-wrap: wrap; padding-inline: var(--x-pad); max-width: var(--wrap-wide); width: 100%; margin-inline: auto; }
.x-process__head .x-h2 { max-width: 15ch; font-size: clamp(2.2rem, 5vw, 4.6rem); }
.x-process__meter { display: flex; align-items: center; gap: 0.8rem; color: var(--c-muted-ink); }
.x-process__meter b { color: var(--c-brand); font-weight: 600; }
.x-process__bar { width: 160px; height: 3px; background: var(--c-border); border-radius: 3px; overflow: hidden; }
.x-process__bar i { display: block; height: 100%; background: var(--c-brand); transform-origin: 0 50%; transform: scaleX(0.2); }
.x-process__track {
  list-style: none; margin: 0;
  display: flex; gap: clamp(1rem, 2vw, 1.5rem);
  padding: 0 var(--x-pad);
  width: max-content;
  will-change: transform;
}
.x-step {
  --bg: var(--x-paper); --fg: #141418;
  position: relative;
  flex: none;
  width: clamp(300px, 36vw, 520px);
  height: clamp(320px, 54vh, 520px);
  padding: clamp(1.5rem, 3vw, 2.5rem);
  border-radius: clamp(22px, 3vw, 34px);
  background: var(--bg); color: var(--fg);
  display: flex; flex-direction: column; justify-content: flex-end;
  overflow: hidden;
}
.x-step:nth-child(odd) { rotate: -1.2deg; }
.x-step:nth-child(even) { rotate: 1.2deg; translate: 0 18px; }
.x-step--orange { --bg: #FF5000; --fg: #1C0900; }
.x-step--ink { --bg: #141418; --fg: #F4F4F5; }
.x-step--violet { --bg: #773FFF; --fg: #fff; }
.x-step--yellow { --bg: #FFEA1E; --fg: #141418; }
html[data-theme='dark'] .x-step--ink { --bg: #22222A; }
.x-step__num {
  position: absolute; top: -0.12em; right: 0.05em;
  font-family: var(--f-display); font-weight: 800; font-stretch: 75%;
  font-size: clamp(9rem, 18vw, 16rem); letter-spacing: -0.06em; line-height: 1;
  color: transparent; -webkit-text-stroke: 2px currentColor; opacity: 0.35;
}
.x-step__body { position: relative; display: grid; gap: 0.7rem; }
.x-step__body .x-mono { opacity: 0.75; }
.x-step__title { font-family: var(--f-display); font-weight: 800; font-stretch: 75%; font-size: clamp(2rem, 3.6vw, 3.4rem); letter-spacing: -0.04em; line-height: 0.92; }
.x-step__body p:last-child { line-height: 1.55; opacity: 0.9; max-width: 38ch; }
.x-step--end { --bg: transparent; --fg: var(--c-ink); justify-content: center; align-items: flex-start; gap: 1.25rem; width: clamp(280px, 30vw, 420px); }
.x-step__mascot { width: 96px; height: 96px; border-radius: 26%; background: var(--c-brand); display: grid; place-items: center; animation: xFloat 4s ease-in-out infinite; box-shadow: 0 18px 36px -14px rgb(255 80 0 / 0.8); }
.x-step__mascot svg { width: 58%; }
/* Celular: también avanza en horizontal; solo con movimiento reducido queda como lista */
@media (max-width: 760px) and (prefers-reduced-motion: reduce) {
  .x-process__sticky { position: relative; height: auto; padding-block: 5rem 3rem; }
  .x-process__track { flex-direction: column; width: auto; transform: none !important; }
  .x-step { width: auto; height: auto; min-height: 280px; }
  .x-step:nth-child(even) { translate: none; }
  .x-step--end { min-height: 0; }
}

/* ---------- Preguntas: título gigante ---------- */
.x-faq .faq__head .title-lg { font-family: var(--f-display); font-size: clamp(2.4rem, 5.5vw, 5rem); font-weight: 800; font-stretch: 75%; letter-spacing: -0.045em; line-height: 0.9; }

@media (prefers-reduced-motion: reduce) {
  .x-sheet { transform: none; }
  .x-process__sticky { position: relative; height: auto; padding-block: 5rem 3rem; }
  .x-process__track { flex-wrap: wrap; width: auto; }
  .x-step__mascot { animation: none; }
}

/* Mascota guía más discreta en pantallas pequeñas */
@media (max-width: 700px) {
  .x-buddy { left: 0.6rem; bottom: 0.6rem; }
  .x-buddy__face { width: 42px; height: 42px; border-radius: 28%; }
  .x-buddy__say { font-size: 0.75rem; margin-bottom: 0.4rem; }
}

/* ==========================================================================
   v3 · ARREGLO DE SCROLL + PORTADA MÁS LIMPIA
   ========================================================================== */

/* Lenis: el scroll suave del navegador no debe sumarse al de Lenis (causaba tirones) */
html.lenis, html.lenis body { height: auto; }
html.lenis, html.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }

/* Grano estático: sin repintar toda la pantalla en cada fotograma */
.x-grain { inset: 0; animation: none; opacity: 0.035; }
html[data-theme='dark'] .x-grain { opacity: 0.05; }

/* ---------- Hero limpio ---------- */
.x-hero .hero__field { opacity: 0.55; }
.x-hero__inner { grid-template-rows: 1fr auto; padding-bottom: clamp(1.25rem, 3.5vh, 2.25rem); }
.x-hero__title { margin: 0; align-self: center; font-size: clamp(3.4rem, 12.4vw, 13.5rem); }
.x-hero__mascot { top: auto; bottom: 26%; right: clamp(1rem, 5vw, 6rem); }
.x-hero__foot { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; border-top: 1px solid var(--c-border); padding-top: clamp(1rem, 2.5vh, 1.5rem); }
.x-hero__foot .hero__rotator { margin: 0; min-height: 0; }
.x-hero__foot .x-scrollcue { position: static; transform: none; }
@media (max-width: 980px) {
  .x-hero__mascot { bottom: auto; top: calc(var(--nav-h) + 1rem); }
  .x-hero__foot .x-scrollcue { display: none; }
}
@media (max-width: 600px) {
  .x-hero__inner { grid-template-rows: auto 1fr auto; }
  .x-hero__mascot { position: relative; top: auto; right: auto; justify-self: end; grid-row: 1; margin-top: 0.5rem; }
  .x-hero__foot .btn { width: 100%; justify-content: center; }
}

/* ---------- Manifiesto: una frase gigante ---------- */
.x-manifest__text { font-size: clamp(3rem, 10vw, 10rem); font-weight: 800; font-stretch: 75%; letter-spacing: -0.045em; line-height: 0.9; max-width: none; }
.x-manifest__text em { font-weight: 800; font-stretch: 75%; font-style: normal; }
.x-manifest__text .xw.is-on:last-of-type { color: inherit; }

/* ---------- Tarjetas de servicio sin párrafo: más aire, título protagonista ---------- */
.x-card { min-height: min(72vh, 600px); }
.x-card__title { font-size: clamp(3rem, 7.4vw, 7.4rem); }
.x-card::after { content: ''; position: absolute; inset: 0; z-index: 3; background: #000; opacity: var(--dim, 0); pointer-events: none; border-radius: inherit; }

/* ---------- Productos mínimos ---------- */
.x-products { padding-block: clamp(6rem, 11vw, 9rem) clamp(4rem, 8vw, 6rem); }
.x-products .x-h2 { font-size: clamp(2.6rem, 6.5vw, 6rem); }
.x-prod {
  display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 5vw, 5rem); align-items: center;
  min-height: 86svh; padding-block: clamp(2rem, 5vw, 4rem);
}
.x-prod + .x-prod { border-top: 1px solid var(--c-border); }
.x-prod--rev .x-prod__copy { order: 2; }
.x-prod__copy { display: flex; flex-direction: column; align-items: flex-start; gap: 1.4rem; }
.x-prod__name { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--c-muted-ink); }
.x-prod__name i { width: 22px; height: 22px; border-radius: 7px; background: var(--c-brand); }
.x-prod__title { font-family: var(--f-display); font-weight: 800; font-stretch: 75%; font-size: clamp(3rem, 7vw, 7rem); letter-spacing: -0.045em; line-height: 0.88; }
.x-prod__tags { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.x-prod__tags span { padding: 0.4rem 0.85rem; border-radius: 999px; background: var(--c-muted); color: var(--c-ink-soft); font-size: 0.85rem; font-weight: 600; }
.x-prod__cta { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-top: 0.4rem; }
.x-prod__cta .btn--ghost { --btn-bg: transparent; --btn-fg: var(--c-ink); border-color: var(--c-border-strong); }
.x-prod__shot {
  display: block; border-radius: clamp(18px, 2vw, 28px); overflow: hidden;
  background: var(--c-surface);
  box-shadow: 0 50px 100px -40px rgb(0 0 0 / 0.85), 0 0 0 1px var(--c-border);
  transform: rotate(2.5deg);
  transition: transform 600ms var(--ease-back);
}
.x-prod--rev .x-prod__shot { transform: rotate(-2.5deg); }
.x-prod__shot:hover { transform: rotate(0) scale(1.02); }
.x-prod__bar { display: flex; align-items: center; gap: 0.4rem; padding: 0.75rem 1rem; border-bottom: 1px solid var(--c-border); }
.x-prod__bar i { width: 10px; height: 10px; border-radius: 50%; background: #FF5F57; }
.x-prod__bar i:nth-child(2) { background: #FEBC2E; } .x-prod__bar i:nth-child(3) { background: #28C840; }
.x-prod__bar b { margin-left: 0.6rem; font: 500 0.72rem var(--f-mono); color: var(--c-muted-ink); }
.x-prod__shot img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top center; display: block; }
@media (max-width: 900px) {
  .x-prod { grid-template-columns: 1fr; min-height: 0; }
  .x-prod--rev .x-prod__copy { order: 0; }
  .x-prod__shot, .x-prod--rev .x-prod__shot { transform: none; }
}

/* ---------- Cierre mínimo ---------- */
.x-cta__card { gap: 0.9rem; transform: rotate(2deg); }
.x-cta__card .btn { width: 100%; justify-content: center; }
.x-cta__mail { color: var(--c-ink-soft); text-decoration: none; font-weight: 600; }
.x-cta__mail:hover { color: var(--c-accent); }

/* ---------- Juego: solo título y botón ---------- */
.x-play__cta { margin-top: 2.25rem; }
.x-hero__mascot { top: 21%; bottom: auto; }
.x-hero__mascot .mascot { width: clamp(100px, 11vw, 170px); }
@media (max-width: 980px) { .x-hero__mascot { top: calc(var(--nav-h) + 1rem); } }
@media (max-width: 600px) { .x-hero__mascot { top: auto; } }
/* Pasos solo con título: color propio, más compactos y número protagonista */
.x-step__title { color: inherit; }
.x-step { height: clamp(260px, 44vh, 420px); width: clamp(280px, 30vw, 440px); }
.x-step__num { opacity: 0.55; font-size: clamp(8rem, 15vw, 14rem); }
.x-step__title { font-size: clamp(2.1rem, 3.4vw, 3.3rem); }
@media (max-width: 760px) { .x-step { min-height: 170px; height: auto; } .x-step__num { font-size: 7rem; } }

/* ==========================================================================
   v4 · FUENTES DE MARCA: Timun (titulares gigantes) + Poppins (interfaz)
   Open Sans sigue para el texto corrido. La intro no se toca: usa --f-display.
   ========================================================================== */
@font-face { font-family: 'Timun'; src: url('../fonts/Timun-SemiBold.woff') format('woff'); font-weight: 500 900; font-style: normal; font-display: swap; }
@font-face { font-family: 'Timun'; src: url('../fonts/Timun-Light.woff') format('woff'); font-weight: 100 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Poppins'; src: url('../fonts/Poppins-Light.woff') format('woff'); font-weight: 300; font-display: swap; }
@font-face { font-family: 'Poppins'; src: url('../fonts/Poppins-Regular.woff') format('woff'); font-weight: 400 500; font-display: swap; }
@font-face { font-family: 'Poppins'; src: url('../fonts/Poppins-Bold.woff') format('woff'); font-weight: 600 800; font-display: swap; }
:root {
  --f-x: 'Timun', 'Open Sans', system-ui, sans-serif;
  --f-ui: 'Poppins', 'Open Sans', system-ui, sans-serif;
}

/* Titulares gigantes en Timun (es extendida: tamaños ~40 % menores que con Open Sans condensada) */
.x-hero__title, .x-h2, .x-manifest__text, .x-card__title, .x-stats dd,
.x-prod__title, .x-step__title, .x-step__num, .x-cta__track, .x-cta__title, .x-case__title,
.x-pxtitle__txt, .x-zoom__text, .x-zoom__after, .x-cluster__name, .title-xl, .title-lg,
.w-start__title, .w-panel__title {
  font-family: var(--f-x);
  font-stretch: normal;
  font-weight: 600;
  letter-spacing: -0.035em;
  hyphens: manual;
}
.x-hero__title { font-size: clamp(2.05rem, 7.6vw, 8.6rem); line-height: 0.95; letter-spacing: -0.045em; }
.x-hero__title .line:nth-child(2) { padding-left: 0.5em; }
.x-hero__title .line:nth-child(3) { padding-left: 0.15em; }
.x-hero .hero__outline { font-weight: 300; -webkit-text-stroke: clamp(1px, 0.14vw, 2px) var(--c-brand); }
.x-h2 { font-size: clamp(1.8rem, 3.7vw, 3.6rem); line-height: 1; }
.x-head .x-h2 { max-width: 18ch; }
.x-manifest__text { font-size: clamp(2.1rem, 6.6vw, 6.8rem); line-height: 0.98; }
.x-manifest__text em { font-family: var(--f-x); font-weight: 300; }
.x-card__title { font-size: clamp(1.75rem, 4vw, 4.4rem); line-height: 0.98; overflow-wrap: anywhere; }
.x-stats dd { font-size: clamp(2.2rem, 4.4vw, 4rem); }
.x-prod__title { font-size: clamp(2.1rem, 4.6vw, 4.8rem); line-height: 0.98; }
.x-step__title { font-size: clamp(1.5rem, 2.3vw, 2.3rem); line-height: 1; }
.x-step__num { font-size: clamp(6rem, 10vw, 9.5rem); font-weight: 300; }
.x-cta__track { font-size: clamp(1.8rem, 4.8vw, 4.6rem); }
.x-cta__title { font-size: clamp(2rem, 5vw, 5rem); line-height: 0.98; }
.x-cta__title .hero__outline { font-weight: 300; }
.x-case__title { font-size: clamp(1.7rem, 3vw, 2.8rem); line-height: 1; }
.x-pxtitle__txt { font-size: clamp(2.4rem, 9vw, 9rem); }
.x-cluster__name { font-size: clamp(0.8rem, 1.1vw, 1.05rem); }
.title-xl { font-size: clamp(2rem, 4.6vw, 4.2rem); line-height: 1; }
.title-lg { font-size: clamp(1.6rem, 2.9vw, 2.7rem); line-height: 1.05; }
.x-products .x-h2, .x-play .x-h2 { font-size: clamp(2rem, 4.4vw, 4.4rem); }
.x-process__head .x-h2 { font-size: clamp(1.8rem, 3.4vw, 3.4rem); }
.x-faq .faq__head .title-lg { font-size: clamp(1.8rem, 3.6vw, 3.4rem); }
.w-start__title { font-size: clamp(2.2rem, 7vw, 3.4rem); }
.w-panel__title { font-size: clamp(1.6rem, 4.5vw, 2.3rem); }

/* Interfaz en Poppins */
.btn, .nav__link, .x-card__link, .x-card__tags span, .x-prod__tags span, .x-case__tags span,
.x-bubble, .x-buddy__say, .chip, .badge, .x-cta__mail, .link-arrow, .w-btn--text, .w-ideas, .w-toast, .w-act {
  font-family: var(--f-ui);
}
.btn { letter-spacing: 0; font-weight: 600; }

/* ==========================================================================
   ZOOM · «Ideas que se viven»: entrar en el cuadro naranja y cambiar de sección
   ========================================================================== */
.x-zoom { position: relative; height: 320vh; }
.x-zoom__sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; display: grid; place-items: center; }
.x-zoom__text {
  display: flex; flex-direction: column; align-items: center;
  font-size: clamp(2.6rem, 10vw, 10.5rem); line-height: 0.92; letter-spacing: -0.05em;
  text-align: center;
  will-change: transform;
}
.x-zoom__l { display: block; }
.x-zoom__l--outline { font-weight: 300; color: transparent; -webkit-text-stroke: clamp(1px, 0.16vw, 2.5px) var(--c-ink); }
.x-zoom__l--brand { color: var(--c-brand); }
.x-zoom__dot { display: inline-block; width: 0.2em; height: 0.2em; margin-left: 0.06em; background: var(--c-brand); vertical-align: baseline; }
.x-zoom__flood {
  position: absolute; inset: 0;
  background: var(--c-brand);
  opacity: 0;
  display: grid; place-items: center;
  pointer-events: none;
}
.x-zoom__after {
  display: flex; flex-direction: column; align-items: center;
  font-size: clamp(2rem, 7.5vw, 7.5rem); line-height: 0.95; letter-spacing: -0.045em;
  color: var(--c-on-brand);
}
.x-zoom__after span:nth-child(even) { font-weight: 300; color: transparent; -webkit-text-stroke: clamp(1px, 0.15vw, 2px) var(--c-on-brand); }
.x-brands.x-sheet { background: var(--c-bg); margin-top: -18vh; padding-top: clamp(4rem, 9vw, 7rem); }
@media (prefers-reduced-motion: reduce) {
  .x-zoom { height: auto; }
  .x-zoom__sticky { position: relative; height: auto; padding: 6rem 1rem; }
  .x-zoom__flood { display: none; }
  .x-brands.x-sheet { margin-top: 0; }
}
/* Ajustes de Timun: palabras completas, sin cortes */
.x-card__title { font-size: clamp(1.45rem, 3.05vw, 3.4rem); overflow-wrap: normal; }
.x-prod__title { font-size: clamp(1.9rem, 3.7vw, 4rem); }
.x-process__track { padding-right: calc(var(--x-pad) + 6vw); }
.x-step--end .x-step__title { font-size: clamp(1.4rem, 2vw, 2rem); }


/* ==========================================================================
   v5 · cursor sin contorno, «en Ecuador.» animado, zoom en toda la página
   ========================================================================== */
.x-cursor__ring, .x-cursor.is-link .x-cursor__ring { border-color: transparent; }
.x-cursor__dot { transition: width 200ms, height 200ms, margin 200ms; }
.x-cursor.is-link .x-cursor__dot { width: 14px; height: 14px; margin: -7px; border-radius: 4px; }

.x-sweep { position: relative; display: inline-block; }
.x-sweep::after {
  content: attr(data-text);
  position: absolute; left: 0; top: 0;
  color: var(--c-brand); -webkit-text-stroke: 0;
  clip-path: inset(0 100% 0 0);
  animation: xSweep 5s var(--e-io) 1.4s infinite;
  pointer-events: none;
}
@keyframes xSweep {
  0% { clip-path: inset(0 100% 0 0); }
  35%, 62% { clip-path: inset(0 0 0 0); }
  100% { clip-path: inset(0 0 0 100%); }
}
[data-zoom] { transform-origin: 50% 50%; }
.x-zoom__text { position: relative; }
@media (prefers-reduced-motion: reduce) { .x-sweep::after { animation: none; clip-path: none; } }

/* Titular del hero siempre en 3 líneas */
.x-hero__title { font-size: clamp(1.9rem, 7.2vw, 7.6rem); }
.x-hero__title .line > span { white-space: nowrap; }

/* v6 · páginas internas */
.x-internal, .x-legal {
  --xi-white: #FFFFFF;
  --xi-gutter: clamp(1rem, 4vw, 2.5rem);
  --xi-space: clamp(4.5rem, 8vw, 8rem);
}
.x-internal #main { overflow-x: clip; }
.x-internal #main :is(h1, h2, h3), .x-page-hero__title {
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}
.x-internal :is(button, .btn, .x-text-link), .x-legal .btn { min-height: 44px; }
.x-internal :focus-visible, .x-legal :focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 5px;
}
.x-internal :is(.footer__social a, .icon-btn), .x-legal :is(.footer__social a, .icon-btn) {
  min-width: 44px;
  min-height: 44px;
}
.x-internal .x-buddy__face, .x-legal .x-buddy__face { min-width: 44px; min-height: 44px; }
.x-internal .x-sheet { background: var(--c-bg); }
.x-internal [id] { scroll-margin-top: 1rem; }
.x-internal :is(.x-section, .x-end, .x-product-page) {
  padding-block: var(--xi-space) calc(var(--xi-space) + 3rem);
}
.x-internal .x-section {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.x-internal .wrap { min-width: 0; }
.x-internal :is(.x-section-title, .x-project__title) {
  font: 600 clamp(1.65rem, 4.6vw, 4.6rem)/1.06 var(--f-x);
  letter-spacing: -0.035em;
  color: inherit;
}
.x-internal .x-section-title { margin-top: 1rem; }
.x-internal .x-mono { font-size: 0.75rem; letter-spacing: 0.1em; }
.x-internal .x-text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding-block: 0.75rem;
  font: 600 1rem/1.5 var(--f-ui);
  text-decoration: underline;
  text-underline-offset: 0.3em;
}
.x-internal .x-text-link svg { flex: none; width: 20px; height: 20px; }
.x-internal .x-text-link:hover { color: var(--c-accent); }

/* Cabeceras: una idea, todo el espacio. */
.x-page-hero {
  position: relative;
  min-height: 100svh;
  overflow: clip;
  background: var(--c-bg);
  color: var(--c-ink);
}
.x-page-hero__inner {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: clamp(1.5rem, 4vh, 3rem);
  min-height: 100svh;
  max-width: var(--wrap-wide);
  padding-block: calc(var(--nav-h) + 1.25rem) 5.5rem;
}
.x-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  font: 400 0.8rem/1.5 var(--f-ui);
  color: var(--c-muted-ink);
}
.x-breadcrumb a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: underline; text-underline-offset: 4px; }
.x-breadcrumb a:hover { color: var(--c-accent); }
.x-breadcrumb [aria-current] { color: var(--c-ink); }
.x-page-hero__body { align-self: center; min-width: 0; padding-block: 1rem; }
.x-page-hero__body > .x-mono { color: var(--c-muted-ink); margin-bottom: 1.5rem; }
.x-page-hero__title {
  position: relative;
  font: 600 clamp(2rem, 9vw, 8.5rem)/0.99 var(--f-x);
  letter-spacing: -0.035em;
  transform-origin: 0 50%;
  max-width: 100%;
  margin: 0;
}
.x-page-hero__title > span { display: block; }
.x-page-hero__accent { color: var(--c-accent); }
.x-page-hero__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem 2rem;
  border-top: 1px solid var(--c-border-strong);
  padding-top: 1.5rem;
}
.x-page-hero__foot p { max-width: 40ch; color: var(--c-ink-soft); font-size: clamp(1rem, 1.5vw, 1.2rem); }
.x-page-hero__stamp {
  position: absolute;
  right: var(--xi-gutter);
  top: 45%;
  z-index: -1;
  display: grid;
  justify-items: end;
  gap: 1rem;
  font: 600 clamp(1.5rem, 4vw, 4rem)/1 var(--f-x);
  color: var(--c-ink);
  rotate: 8deg;
}
.x-page-hero__stamp i {
  display: block;
  width: clamp(44px, 7vw, 110px);
  aspect-ratio: 1;
  background: var(--c-brand);
  box-shadow: -1em 1em 0 var(--c-violet), -2em 2em 0 var(--c-yellow);
}
.x-page-hero--legal .x-page-hero__title { font-size: clamp(1.75rem, 6.3vw, 6rem); }
.x-page-hero--legal .x-page-hero__foot p { max-width: 65ch; }
.x-page-hero--legal .x-page-hero__inner { padding-bottom: 3rem; }

/* Zoom con texto siempre legible. */
.x-internal [data-zoom], .x-legal [data-zoom] { opacity: 1 !important; }
.x-internal [data-zoom]:focus-within { scale: 1 !important; }

/* Servicios: tarjetas amplias y gráficos existentes. */
.x-internal .x-services { padding-top: 3rem; }
.x-internal .x-stack { gap: clamp(2rem, 5vh, 4rem); }
.x-internal .x-card {
  top: calc(var(--nav-h) + 0.5rem + var(--i) * 6px);
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  min-height: min(72svh, 660px);
  padding: clamp(1.5rem, 3.5vw, 3rem);
  gap: clamp(1.5rem, 3vw, 3rem);
}
.x-internal .x-card--orange { --bg: var(--c-brand); --fg: var(--c-on-brand); }
.x-internal .x-card--ink { --bg: var(--x-ink); --fg: var(--xi-white); }
.x-internal .x-card--violet { --bg: var(--c-violet); --fg: var(--xi-white); }
.x-internal .x-card--yellow { --bg: var(--c-yellow); --fg: var(--x-ink); }
.x-internal .x-card--paper { --bg: var(--c-surface); --fg: var(--c-ink); border: 1px solid var(--c-border-strong); }
.x-internal .x-card__body { gap: 1.25rem; min-width: 0; }
.x-internal .x-card__title { font-size: clamp(1.375rem, 2.45vw, 2.8rem); line-height: 1.08; margin: 0; }
.x-internal .x-card__kicker { opacity: 1; }
.x-internal .x-card__kicker b { background: none; border: 1px solid currentColor; }
.x-internal .x-card__tags span { background: none; border: 1px solid currentColor; font-size: 0.8rem; }
.x-internal .x-card__list { list-style: disc; padding-left: 1.2rem; display: grid; gap: 0.4rem; font-size: 1rem; line-height: 1.55; }
.x-internal .x-card__visual { height: clamp(260px, 40vh, 400px); }
.x-internal .x-card__visual .mg { transform: none; }
.x-internal .mg-flow .lead text { font-size: 9px; }
.x-internal :is(.mg-av .rec, .mg-ev .live, .mg-code .ok) {
  background: var(--x-ink);
  color: var(--xi-white);
  padding: 0.3rem 0.6rem;
  border-radius: var(--r-pill);
}
.x-internal .mg-chat .who em { color: var(--c-ink); }
.x-internal .x-card::after { display: none; }
.x-internal .x-card:target, .x-internal .x-card:focus-within {
  translate: none !important;
  rotate: none !important;
  transform: none !important;
}
.x-internal .x-card:focus-within { z-index: 2; }

/* Galería vertical: imagen protagonista y enlace directo. */
.x-gallery { position: relative; }
.x-project { padding-block: clamp(4.5rem, 7vw, 7rem) 6rem; }
.x-project__inner { display: grid; gap: 1.75rem; min-height: calc(100svh - 10.5rem); align-content: center; }
.x-project__head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0.75rem 2rem; align-items: end; }
.x-project__head > .x-mono { grid-column: 1 / -1; color: var(--c-accent); }
.x-internal .x-project__title { font-size: clamp(1.65rem, 3.8vw, 3.8rem); }
.x-project__client { color: var(--c-ink-soft); font-size: 0.95rem; }
.x-project__image {
  margin: 0;
  overflow: clip;
  border: 1px solid var(--c-border-strong);
  border-radius: clamp(16px, 2vw, 28px);
  background: var(--c-surface);
}
.x-project__image img { display: block; width: 100%; height: auto; max-height: 62svh; object-fit: contain; }
.x-project__foot { display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: center; justify-content: space-between; }
.x-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.x-tags span { padding: 0.4rem 0.9rem; border: 1px solid var(--c-border-strong); border-radius: var(--r-pill); font: 500 0.85rem/1.5 var(--f-ui); }

/* Productos y tarjetas breves. */
.x-product-page .x-prod { min-height: 80svh; padding-top: 0; }
.x-internal .x-prod__copy { min-width: 0; }
.x-internal .x-prod__title { font-size: clamp(1.8rem, 3.4vw, 3.7rem); line-height: 1.08; }
.x-internal .x-prod__name { color: var(--c-ink); }
.x-internal .x-prod__tags span { color: var(--c-ink); }
.x-internal .x-prod__shot { margin: 0; min-width: 0; }
.x-small-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.x-small-grid--four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.x-mini {
  --bg: var(--c-surface); --fg: var(--c-ink);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 1rem;
  min-width: 0;
  min-height: 230px;
  padding: clamp(1.25rem, 2.3vw, 2rem);
  border-radius: 24px;
  background: var(--bg);
  color: var(--fg);
}
.x-mini--orange { --bg: var(--c-brand); --fg: var(--c-on-brand); }
.x-mini--violet { --bg: var(--c-violet); --fg: var(--xi-white); }
.x-mini--yellow { --bg: var(--c-yellow); --fg: var(--x-ink); }
.x-mini--ink { --bg: var(--x-ink); --fg: var(--xi-white); }
.x-mini--paper { border: 1px solid var(--c-border-strong); }
.x-mini--link { background: transparent; justify-content: center; }
.x-internal .x-mini h3 { font: 600 clamp(1rem, 1.4vw, 1.3rem)/1.2 var(--f-x); letter-spacing: -0.035em; color: inherit; }
.x-mini > .x-mono { margin-bottom: auto; padding-bottom: 1.5rem; }
.x-mini p { font-size: 1rem; line-height: 1.6; }
.x-product-features { margin-top: 1.5rem; }

/* Manifiesto y preguntas con controles nativos. */
.x-internal .x-page-hero.x-manifest { padding: 0; display: block; }
.x-purpose { padding-block: var(--xi-space) calc(var(--xi-space) + 3rem); }
.x-internal .x-purpose .x-manifest__text { font-size: clamp(1.9rem, 5.6vw, 5.6rem); line-height: 1.1; max-width: 19ch; }
.x-internal .x-manifest__text em { color: var(--c-accent); font-weight: 600; }
.x-internal .x-manifest__text .xw { opacity: 1; }
.x-internal .x-manifest__text .xw:not(.is-on) { color: var(--c-ink-soft); }
.x-purpose__foot { margin-top: 3rem; display: flex; justify-content: space-between; flex-wrap: wrap; align-items: center; gap: 2rem; }
.x-purpose__foot p { max-width: 38ch; font-size: 1.125rem; color: var(--c-ink-soft); }
.x-faq__grid { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: clamp(2.5rem, 6vw, 6rem); }
.x-faq__intro { align-self: start; }
.x-internal .x-faq__intro .x-section-title { font-size: clamp(1.6rem, 3.2vw, 3.2rem); }
.x-faq__intro .x-text-link { margin-top: 1.75rem; }
.x-question { border-top: 1px solid var(--c-border-strong); }
.x-question:last-child { border-bottom: 1px solid var(--c-border-strong); }
.x-question summary { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 72px; padding: 1.25rem 0.25rem; cursor: pointer; list-style: none; }
.x-question summary::-webkit-details-marker { display: none; }
.x-internal .x-question h3 { font: 600 1rem/1.6 var(--f-ui); letter-spacing: 0; color: var(--c-ink); }
.x-question summary > span { flex: none; font: 400 1.75rem/1 var(--f-ui); color: var(--c-accent); }
.x-question[open] summary > span { rotate: 45deg; }
.x-question__answer { padding: 0 2rem 1.5rem 0.25rem; color: var(--c-ink-soft); }
.x-question__answer a { color: var(--c-accent); text-decoration: underline; }

/* Contacto: datos grandes y formulario intacto. */
.x-contact__links { margin-top: 3rem; display: grid; gap: 1.5rem; }
.x-contact__mail { display: block; width: fit-content; max-width: 100%; padding-block: 0.5rem; font: 600 clamp(1.1rem, 3.5vw, 3.5rem)/1.4 var(--f-ui); letter-spacing: -0.035em; }
.x-contact__phones { display: flex; flex-wrap: wrap; gap: 0.5rem 3rem; font: 500 clamp(1.25rem, 2.8vw, 2.5rem)/1.5 var(--f-ui); }
.x-contact__phones a { display: flex; align-items: center; min-height: 44px; padding-block: 0.5rem; }
.x-contact__links a:hover { color: var(--c-accent); text-decoration: underline; text-underline-offset: 0.2em; }
.x-contact__details { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--c-border-strong); display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr) auto; gap: 2rem; }
.x-internal .x-contact__details h3 { font-family: var(--f-mono); font-weight: 500; line-height: 1.6; margin-bottom: 1rem; color: var(--c-muted-ink); }
.x-contact__details :is(address, p) { font-style: normal; color: var(--c-ink-soft); }
.x-contact__actions { display: flex; flex-direction: column; align-items: flex-start; gap: 0.75rem; }
.x-form-layout { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: clamp(2.5rem, 6vw, 6rem); }
.x-form-intro > p:last-child { margin-top: 1.5rem; color: var(--c-ink-soft); }
.x-internal .x-form-intro .x-section-title { font-size: clamp(1.45rem, 2.7vw, 2.8rem); }
.x-form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
.x-contact-form, .x-contact-form .field { min-width: 0; }
.x-contact-form .field :is(input, textarea, select) { min-width: 0; max-width: 100%; font-size: 1rem; }
.x-contact-form .field label { font-family: var(--f-ui); color: var(--c-ink); }
.x-contact-form .field :is(input, textarea)::placeholder { opacity: 1; }
.x-contact-form .field :is(input, textarea, select):focus-visible { outline: 3px solid var(--c-ink); outline-offset: 3px; }
.x-contact-form :is(.hint, .error, .form__note) { font-size: 0.875rem; }
.x-contact-form .checkbox { min-height: 44px; padding-block: 0.5rem; line-height: 1.65; }
.x-contact-form .checkbox input { width: 22px; height: 22px; min-height: 22px; padding: 0; }
.x-contact-form .btn:disabled { cursor: wait; opacity: 1; box-shadow: none; }
.x-contact-form .form__status { overflow-wrap: anywhere; }
.x-end { min-height: 85svh; display: flex; align-items: center; }
.x-end__inner { display: flex; flex-direction: column; align-items: flex-start; gap: 2rem; }
.x-internal .x-end .x-section-title { margin: 0; }

/* En pantallas cortas o estrechas, cada tarjeta se lee completa. */
@media (max-width: 1050px), (max-height: 780px) {
  .x-internal .x-card { position: relative; top: auto; translate: none !important; rotate: none !important; transform: none !important; }
}
@media (max-width: 1050px) {
  .x-internal .x-card { grid-template-columns: 1fr; }
  .x-internal .x-card__visual { order: 0; height: 260px; transform: none; }
  .x-small-grid--four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-contact__details { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-contact__actions { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 1rem 2rem; }
  .x-project__head { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .x-small-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-product-features { grid-template-columns: 1fr; }
  .x-product-features .x-mini { min-height: 0; }
  .x-product-page .x-prod { min-height: 0; gap: 3rem; }
  .x-internal .x-prod__shot { transform: none; }
  .x-faq__grid, .x-form-layout { grid-template-columns: 1fr; }
  .x-page-hero__stamp { display: none; }
}
@media (max-width: 600px) {
  .x-page-hero__inner { gap: 1.25rem; padding-top: calc(var(--nav-h) + 0.5rem); }
  .x-page-hero__body { padding-block: 2rem; }
  .x-page-hero__foot { align-items: stretch; }
  .x-page-hero__foot .btn { width: 100%; justify-content: center; }
  .x-small-grid, .x-form-row, .x-contact__details { grid-template-columns: 1fr; }
  .x-mini { min-height: 200px; }
  .x-internal .x-mini h3 { font-size: 1.25rem; }
  .x-internal .x-card__visual { height: 220px; }
  .x-project__inner { gap: 1.5rem; }
  .x-project__image img { max-height: none; }
  .x-project__foot { align-items: stretch; }
  .x-project__foot .btn { width: 100%; justify-content: center; }
  .x-contact-form .btn { width: 100%; justify-content: center; }
  .x-contact__actions { grid-column: auto; flex-direction: column; align-items: flex-start; }
  .x-question__answer { padding-right: 0.25rem; }
}
@media (prefers-reduced-motion: reduce) {
  .x-internal [data-zoom], .x-legal [data-zoom] { scale: none !important; }
  .x-internal .x-sheet, .x-internal .x-card { transform: none !important; rotate: none !important; translate: none !important; }
  .x-internal .x-card { position: relative; top: auto; }
  .x-internal .x-prod__shot { transform: none; transition: none; }
}


/* ==========================================================================
   v7 · logo con colores, tarjetas más bajas, proyectos más limpios, fondo de código
   ========================================================================== */
/* Logo del manifiesto: recorre los colores de la marca */
.x-inline--mascot { animation: xFloat 4s ease-in-out infinite, xHue 6s steps(1) infinite; }
@keyframes xHue {
  0%   { background: #FF5000; color: #fff; }
  25%  { background: #773FFF; color: #fff; }
  50%  { background: #FFEA1E; color: #141418; }
  75%  { background: #141418; color: #FF5000; }
}
html[data-theme='dark'] .x-inline--mascot { animation-name: xFloat, xHueDark; }
@keyframes xHueDark {
  0%   { background: #FF5000; color: #fff; }
  25%  { background: #773FFF; color: #fff; }
  50%  { background: #FFEA1E; color: #141418; }
  75%  { background: #F4F4F5; color: #FF5000; }
}

/* Tarjetas de servicio: mismo ancho, menos alto (la entrada desde las esquinas luce más) */
.x-card { min-height: min(50vh, 420px); padding: clamp(1.25rem, 3vw, 2.5rem); gap: clamp(1.25rem, 3vw, 2.5rem); }
.x-card__visual.svc__visual { height: clamp(200px, 30vh, 300px); }
.x-card__body { gap: 0.9rem; }
.x-stack { gap: clamp(1rem, 3vh, 2rem); }

/* Repositorio: capturas con marco de navegador */
.x-project__image {
  border-radius: clamp(14px, 1.6vw, 22px); overflow: hidden;
  background: var(--c-surface);
  box-shadow: 0 50px 90px -40px rgb(0 0 0 / 0.75), 0 0 0 1px var(--c-border);
}
.x-project__image::before {
  content: ''; display: block; height: 30px;
  background:
    radial-gradient(circle at 16px 50%, #FF5F57 4.5px, transparent 5px),
    radial-gradient(circle at 34px 50%, #FEBC2E 4.5px, transparent 5px),
    radial-gradient(circle at 52px 50%, #28C840 4.5px, transparent 5px),
    var(--c-muted);
  border-bottom: 1px solid var(--c-border);
}
.x-project__image img { aspect-ratio: 16 / 9; max-height: none; object-fit: cover; object-position: top center; }

/* Fondo de código */
[data-codebg] { position: relative; overflow: hidden; isolation: isolate; }
[data-codebg] > :not(.x-code) { position: relative; z-index: 1; }
.x-code {
  position: absolute; inset: -20% 0 auto 0; z-index: 0;
  margin: 0; padding: 0 var(--x-pad);
  display: grid; gap: 0.35em;
  font: 500 clamp(0.95rem, 1.6vw, 1.45rem)/1.5 var(--f-mono);
  white-space: pre; overflow: hidden;
  opacity: 0.16;
  pointer-events: none; user-select: none;
  -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 45%, transparent 85%);
  mask-image: linear-gradient(90deg, #000 0%, #000 45%, transparent 85%);
}
.x-code__ln i { display: inline-block; width: 3ch; margin-right: 1.5ch; font-style: normal; opacity: 0.45; }
.x-code b { font-weight: 500; }
.x-code__k { color: #C792EA; } .x-code__f { color: #FF7A45; } .x-code__v { color: var(--c-ink); }
.x-code__s { color: #C3E88D; } .x-code__c { color: var(--c-muted-ink); font-style: italic; } .x-code__n { color: #F78C6C; }
.x-code__t { color: #FF5000; } .x-code__a { color: #FFCB6B; } .x-code__p { color: var(--c-ink-soft); }
:not(.x-dark) > .x-code, .x-project:not(.x-dark) .x-code { opacity: 0.1; }
.x-project:not(.x-dark) .x-code__s { color: #2E8B57; } .x-project:not(.x-dark) .x-code__a { color: #B8860B; }
@media (max-width: 700px) { .x-code { font-size: 0.8rem; opacity: 0.12; } }
@media (prefers-reduced-motion: reduce) { .x-inline--mascot { animation: none; } }

/* Pasos: más bajos, con ícono pixelado arriba y títulos que no se cortan */
.x-step { height: clamp(240px, 38vh, 340px); width: clamp(270px, 27vw, 400px); justify-content: space-between; }
.x-step__title { font-size: clamp(1.25rem, 1.8vw, 1.9rem); }
.x-step__num { font-size: clamp(5rem, 8vw, 7.5rem); top: 0.1em; right: 0.15em; }
.x-step__px { position: relative; display: grid; grid-template-columns: repeat(8, 1fr); gap: 3px; width: clamp(64px, 6vw, 92px); }
.x-step__px i { aspect-ratio: 1; }
.x-step__px i.on { background: currentColor; transform: scale(0); transition: transform 380ms var(--ease-back) var(--d); }
.x-step.is-px .x-step__px i.on { transform: scale(1); }
.x-step--orange .x-step__px, .x-step--yellow .x-step__px { color: #141418; }
.x-step--ink .x-step__px { color: #FF5000; }
.x-step--violet .x-step__px { color: #FFEA1E; }
.x-step--paper .x-step__px { color: #773FFF; }
@media (max-width: 760px) { .x-step { min-height: 200px; gap: 1.5rem; } }


/* ==========================================================================
   v8 · líquido dentro de las letras del hero
   El lienzo se mezcla con «lighten» (claro) o «darken» (oscuro): sobre el
   fondo no se ve, sobre las letras sí. Por eso el hero necesita fondo opaco.
   ========================================================================== */
.x-hero { background: var(--c-bg); }
.x-hero__title { z-index: auto; }
.x-liquid {
  position: absolute; left: 0; top: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  mix-blend-mode: lighten;
}
html[data-theme='dark'] .x-liquid { mix-blend-mode: darken; }

/* Letras que se juntan desde los extremos */
.x-word { display: inline-block; white-space: nowrap; }
.x-ch { display: inline-block; transform-origin: 50% 60%; will-change: transform; }
.x-word.grad-text .x-ch { background: inherit; -webkit-background-clip: text; background-clip: text; }

/* v9 · móvil */
@media (max-width: 600px) {
  /* Ancho útil / avance en em de Timun, incluido el espaciado de letras.
     Sin mínimos rígidos: las palabras también caben a 360 px. */
  .x-hero__title,
  .x-page-hero__title,
  .x-zoom__text,
  .x-zoom__after,
  .x-manifest__text,
  .x-card__title,
  .x-prod__title,
  .x-cta__title,
  .x-h2,
  .x-section-title,
  .x-project__title {
    min-width: 0;
    max-width: 100%;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
  }

  /* Título arriba, mascota y frase juntas en el centro, botón al pie. */
  .x-hero__inner {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(min-content, 1fr) minmax(min-content, 1fr) auto;
    gap: clamp(var(--s-3), 3svh, var(--s-4));
    padding: calc(var(--nav-h) + var(--s-3)) var(--x-pad) var(--s-3);
  }
  .x-hero__title {
    grid-area: 1 / 1;
    align-self: start;
    font-size: min(3.5rem, calc((100vw - var(--x-pad) * 2) / 10.5));
    line-height: 1.04;
  }
  /* «publicidad 360»: 10.23 em; las líneas cortas crecen por separado. */
  .x-hero__title .line:nth-child(n) { padding-left: 0; }
  .x-hero__title .line:first-child { font-size: 1.3em; }
  .x-hero__title .line:nth-child(3) { font-size: 1.4em; }
  .x-hero__mascot {
    position: relative;
    inset: auto;
    grid-area: 2 / 1;
    align-self: end;
    justify-self: center;
    grid-template-columns: auto auto;
    align-items: center;
    gap: var(--s-3);
    margin: 0;
  }
  .x-hero__mascot .mascot { width: clamp(6rem, 26vw, 7rem); }
  .x-hero__mascot .x-bubble::before {
    left: -7px;
    top: 50%;
    margin: -7px 0 0;
  }
  .x-hero__foot { display: contents; }
  .x-hero__foot .hero__rotator {
    grid-area: 3 / 1;
    align-self: start;
    justify-content: center;
    min-width: 0;
    text-align: center;
  }
  .x-hero__foot .btn { grid-area: 4 / 1; align-self: end; }

  /* «en acción.» / «Software» / «Hagamos»: hasta 6.89 em.
     Reserva para el pequeño zoom de las cabeceras internas. */
  .x-page-hero__title {
    font-size: min(5rem, calc((100vw - var(--x-pad) * 2) / 7.3));
    line-height: 1.05;
  }
  .x-page-hero.x-manifest .x-page-hero__title,
  .x-page-hero--legal .x-page-hero__title {
    /* «tus aliados.» / «protección»: hasta 7.72 em. */
    font-size: min(4.5rem, calc((100vw - var(--x-pad) * 2) / 8.2));
  }

  .x-zoom__text {
    /* «que se» en Timun Light: 4.14 em, más el contorno. */
    font-size: min(6.5rem, calc((100vw - var(--x-pad) * 2) / 4.4));
    line-height: 1;
  }
  .x-zoom__after {
    font-size: min(4rem, calc((100vw - var(--x-pad) * 2) / 8.4));
  }
  .x-manifest__text {
    /* «anuncia.»: 5.83 em. */
    font-size: min(5rem, calc((100vw - var(--x-pad) * 2) / 6.2));
    line-height: 1.08;
  }
  .x-internal .x-purpose .x-manifest__text {
    /* «personas.»: 6.88 em. */
    max-width: 100%;
    font-size: min(4.5rem, calc((100vw - var(--x-pad) * 2) / 7.25));
  }
  /* El zoom de entrada no debe volver a sacar estas palabras del ancho útil. */
  .x-manifest__text[data-zoom], .x-cta__title[data-zoom] { scale: none !important; }

  .x-card, .x-internal .x-card { padding-inline: var(--x-pad); }
  .x-card__title, .x-internal .x-card__title {
    /* Dos márgenes exteriores + dos interiores + borde de la tarjeta. */
    --x-mobile-em: 8.65; /* «publicitarias»: 8.39 em. */
    font-size: min(3.5rem, calc((100vw - var(--x-pad) * 4 - 2px) / var(--x-mobile-em)));
    line-height: 1.08;
  }
  .x-card__title:is(#xs-comunicacion, #service-comunicacion) {
    --x-mobile-em: 10.45; /* «Comunicación»: 10.14 em. */
  }
  .x-card__title:is(#xs-automatizacion, #service-automatizacion) {
    --x-mobile-em: 11.7; /* «Automatización»: 11.40 em. */
  }

  .x-prod__title, .x-internal .x-prod__title, .x-cta__title {
    /* «entendidas.»: 8.27 em; «experiencia?» en Light: 8.14 em. */
    font-size: min(4rem, calc((100vw - var(--x-pad) * 2) / 8.6));
    line-height: 1.08;
  }
  .x-h2, .x-products .x-h2, .x-play .x-h2, .x-process__head .x-h2 {
    font-size: min(4.5rem, calc((100vw - var(--x-pad) * 2) / 7.2));
    line-height: 1.08;
  }
  .x-internal .x-section-title,
  .x-internal .x-faq__intro .x-section-title {
    font-size: min(4.5rem, calc((100vw - var(--x-pad) * 2) / 7.6));
    line-height: 1.08;
  }
  .x-internal .x-form-intro .x-section-title {
    /* «escuchamos.»: 9.42 em. */
    font-size: min(3.5rem, calc((100vw - var(--x-pad) * 2) / 9.7));
  }
  .x-internal .x-project__title {
    /* «Automundo» / «NexumCorp»: hasta 8.67 em. */
    font-size: min(4rem, calc((100vw - var(--x-pad) * 2) / 9));
  }
}

@media (max-width: 420px) {
  .x-hero__inner {
    gap: var(--s-3);
    padding-top: calc(var(--nav-h) + var(--s-2));
    padding-bottom: var(--s-2);
  }
  .x-hero__mascot .mascot { width: 6rem; }
  .x-hero__foot .hero__rotator { flex-direction: column; align-items: center; }
}


/* ==========================================================================
   v10 · Header de vidrio líquido (todas las páginas)
   Translúcido, con desenfoque fuerte, saturación, brillo en el borde y
   reflejo interior. Se esconde al bajar y vuelve al subir.
   ========================================================================== */
.header { transition: transform 600ms var(--e-out), padding var(--d-base) var(--e-out); }
.header.is-hidden { transform: translateY(-140%); }
.header .header__inner,
.header.is-stuck .header__inner {
  background:
    linear-gradient(180deg, rgb(255 255 255 / 0.42), rgb(255 255 255 / 0.12)),
    rgb(255 255 255 / 0.08);
  -webkit-backdrop-filter: blur(22px) saturate(190%) contrast(1.05);
  backdrop-filter: blur(22px) saturate(190%) contrast(1.05);
  border: 1px solid rgb(255 255 255 / 0.55);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.85),
    inset 0 -1px 0 rgb(255 255 255 / 0.25),
    inset 0 0 18px rgb(255 255 255 / 0.35),
    0 18px 40px -20px rgb(20 20 24 / 0.35);
  position: relative;
}
/* reflejo que recorre el vidrio */
.header .header__inner::after {
  content: '';
  position: absolute; inset: 0;
  border-radius: inherit;
  background: linear-gradient(105deg, transparent, rgb(255 255 255 / 0.5), transparent) no-repeat;
  background-size: 35% 100%;
  background-position: -60% 0;
  animation: xGlass 7s var(--e-io) infinite 2s;
  pointer-events: none;
}
@keyframes xGlass { 0%, 70% { background-position: -60% 0; } 100% { background-position: 160% 0; } }
html[data-theme='dark'] .header .header__inner,
html[data-theme='dark'] .header.is-stuck .header__inner {
  background:
    linear-gradient(180deg, rgb(255 255 255 / 0.14), rgb(255 255 255 / 0.03)),
    rgb(20 20 24 / 0.35);
  border-color: rgb(255 255 255 / 0.18);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.28),
    inset 0 0 18px rgb(255 255 255 / 0.06),
    0 18px 40px -20px rgb(0 0 0 / 0.7);
}
html[data-theme='dark'] .header .header__inner::after { background-image: linear-gradient(105deg, transparent, rgb(255 255 255 / 0.14), transparent); }
.header .header__inner > * { position: relative; z-index: 1; }
@media (prefers-reduced-motion: reduce) { .header .header__inner::after { animation: none; display: none; } }


/* v11 · Mapa de proyectos: protagonismo para el trabajo (mosaicos grandes, menos inclinación) */
.x-map__viewport { height: min(92vh, 900px); perspective: 1600px; perspective-origin: 50% 35%; }
.x-map__plane { --cell: clamp(380px, 42vw, 600px); --tilt: 34deg; }
.x-cluster__tiles { gap: 8px; }
.x-cluster__tiles img, .x-cluster__tiles i { border-radius: 12px; }
.x-cluster__name { font-size: clamp(0.95rem, 1.4vw, 1.4rem); }
.x-work .x-pxtitle { max-width: 760px; }
.x-work .x-code { opacity: 0.07; }
.x-work { padding-top: clamp(4rem, 8vw, 6rem); }


/* v12 · Del proceso a Productos: zoom al logo y fundido al negro */
.x-step--end { position: relative; z-index: 3; }
.x-step__mascot { position: relative; z-index: 3; will-change: transform; }
.x-process__flood { position: absolute; inset: 0; z-index: 6; background: #0D0D10; opacity: 0; pointer-events: none; }
html[data-theme='dark'] .x-process__flood { background: #141419; }
.x-process + .x-products.x-sheet { margin-top: 0; border-radius: 0; box-shadow: none; }

/* La tarjeta final no recorta el logo mientras crece */
.x-step--end { overflow: visible; }

/* El punto de «mejor.» es un cuadro naranja: allí entra la cámara */
.x-step__dot { display: inline-block; width: 0.2em; height: 0.2em; margin-left: 0.05em; background: var(--c-brand); vertical-align: baseline; position: relative; z-index: 4; will-change: transform; }


/* Footer: «Powered by TEBUSCO» */
.footer__powered { margin-left: 0.6rem; padding-left: 0.6rem; border-left: 1px solid var(--c-border-strong); white-space: nowrap; }
.footer__powered a { color: var(--c-ink); font-weight: 700; text-decoration: none; }
.footer__powered a:hover { color: var(--c-accent); }


/* v13 · Tarjetas de servicio de borde a borde (estilo 1minus1): ocupan toda la pantalla, inclinadas, y entran desde una esquina */
.x-card {
  width: calc(100vw + 6vw);
  max-width: none;
  margin-left: calc(50% - 50vw - 3vw);
  min-height: min(68vh, 640px);
  border-radius: clamp(24px, 3vw, 40px);
  padding-block: clamp(2.5rem, 6vh, 4.5rem);
  padding-inline: calc(3vw + max(var(--x-pad), (100vw - var(--wrap)) / 2 + var(--x-pad)));
  gap: clamp(2rem, 6vw, 6rem);
  box-shadow: 0 -30px 60px -30px rgb(0 0 0 / 0.4);
}
.x-card__title { font-size: clamp(1.8rem, 4.4vw, 4.8rem); }
/* La palabra más larga de cada título cabe siempre en su columna (a 4.4vw «Automatización»
   medía más que la columna en toda pantalla de escritorio y quedaba cortada bajo el dibujo).
   --em: ancho de esa palabra en em de Timun, con un poco de aire */
@media (min-width: 761px) {
  .x-card__body { container-type: inline-size; }
  .x-card__title { --em: 8.4; font-size: min(clamp(1.8rem, 4.4vw, 4.8rem), 100cqi / var(--em)); overflow-wrap: normal; }
  .x-card__title:is(#xs-comunicacion, #service-comunicacion) { --em: 10.4; }
  .x-card__title:is(#xs-automatizacion, #service-automatizacion) { --em: 11.7; }
}
.x-card__visual.svc__visual { height: clamp(240px, 40vh, 380px); }
.x-stack { gap: clamp(2rem, 8vh, 6rem); }
@media (max-width: 860px) {
  .x-card { padding-inline: calc(3vw + var(--x-pad)); min-height: 0; }
}


/* Arreglos de la pila de tarjetas: nitidez, espacio para leer cada una y franja visible de las anteriores */
.x-card { top: calc(var(--nav-h) + var(--i) * 26px); backface-visibility: hidden; transition: none; }
.x-stack { gap: 0; }
.x-card + .x-card { margin-top: 45vh; }
.x-stack { padding-bottom: 20vh; }


/* ==========================================================================
   Quiénes somos (inicio): reemplaza a «Software que creamos y usamos».
   Textos de tbo.com.ec (lema, presentación, 18 años) y los cinco valores en
   cartas: llegan apiladas boca abajo, se reparten y se voltean con el scroll
   (initAboutDeal en experience.js). Al pasar el mouse se inclinan en 3D.
   ========================================================================== */
.x-about { padding-block: clamp(6rem, 11vw, 9rem) clamp(4rem, 8vw, 6rem); }
.x-about__title {
  margin-top: 1.25rem;
  max-width: 100%;
  font-family: var(--f-x); font-weight: 600; line-height: 1; letter-spacing: -0.04em;
  font-size: clamp(2.1rem, 5.2vw, 4.8rem);
}
.x-about__intro {
  margin-top: clamp(1.75rem, 3.5vw, 3rem);
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end;
  gap: clamp(1.5rem, 4vw, 4rem);
}
.x-about__lead {
  max-width: 50ch;
  font: 400 clamp(1.05rem, 1.4vw, 1.3rem)/1.55 var(--f-ui);
  color: var(--c-ink-soft);
}
.x-about__chips { list-style: none; margin: 1.25rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem; }
.x-about__chips li {
  display: inline-flex; align-items: center; gap: 0.55rem;
  padding: 0.5rem 0.95rem; border-radius: 999px;
  border: 1px solid var(--c-border-strong);
  font: 500 0.85rem/1 var(--f-ui); color: var(--c-ink);
}
.x-about__chips li::before { content: ''; width: 0.5em; height: 0.5em; border-radius: 22%; background: var(--c-brand); }
.x-about__chips li + li::before { background: var(--c-violet); }
.x-about__years { display: flex; align-items: flex-end; gap: 0.75rem; margin: 0; }
.x-about__years b {
  /* el degradado solo se pinta dentro de la caja: interlineado 1 y aire a la derecha para que no se corte */
  display: inline-block;
  padding: 0.04em 0.08em 0 0.02em;
  margin: -0.12em -0.08em -0.08em -0.02em;
  font-family: var(--f-x); font-weight: 600; letter-spacing: -0.06em; line-height: 1;
  font-size: clamp(5rem, 11vw, 10rem);
  background: linear-gradient(100deg, var(--c-brand), #FF7A2E 45%, var(--c-violet));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.x-about__years > span { max-width: 9ch; padding-bottom: 0.4em; font: 500 clamp(0.95rem, 1.2vw, 1.15rem)/1.25 var(--f-ui); color: var(--c-ink-soft); }
.x-about__label { margin-top: clamp(3rem, 6vw, 5rem); font-size: 0.75rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--c-muted-ink); }

/* Cartas: 3 arriba y 2 abajo, más grandes y legibles que 5 en fila */
.x-about__values {
  position: relative;               /* referencia de offsetLeft/Top para el reparto */
  list-style: none; margin: 1.25rem 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: clamp(0.75rem, 1.4vw, 1.25rem);
  perspective: 1600px;
}
.x-about__value { grid-column: span 2; position: relative; min-width: 0; transform-style: preserve-3d; will-change: transform; }
.x-about__value:nth-child(n+4) { grid-column: span 3; }
.x-about__value:nth-child(odd) { rotate: -1deg; }
.x-about__value:nth-child(even) { rotate: 1deg; }
.x-about__value--orange { --bg: #FF5000; --fg: #1C0900; }
.x-about__value--paper  { --bg: var(--x-paper); --fg: #141418; }
.x-about__value--violet { --bg: #773FFF; --fg: #FFFFFF; }
.x-about__value--yellow { --bg: #FFEA1E; --fg: #141418; }
.x-about__value--line   { --bg: #1D1D24; --fg: var(--c-ink); }
.x-about__front, .x-about__back {
  border-radius: clamp(18px, 2vw, 26px);
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
}
.x-about__front {
  position: relative; overflow: hidden;
  height: 100%;
  display: flex; flex-direction: column; gap: 0.5rem;
  padding: clamp(1.15rem, 1.9vw, 1.75rem);
  background: var(--bg); color: var(--fg);
  box-shadow: 0 30px 60px -32px rgb(0 0 0 / 0.75);
  container-type: inline-size;      /* el título se mide contra el ancho de su carta */
}
.x-about__value--line .x-about__front { border: 1px solid var(--c-border-strong); }
.x-about__front .x-mono { font-size: 0.75rem; letter-spacing: 0.16em; opacity: 0.7; }
.x-about__front h3 {
  position: relative; margin-top: clamp(0.9rem, 2vw, 1.6rem);
  font-family: var(--f-x); font-weight: 600; line-height: 1.05; letter-spacing: -0.03em;
  font-size: 1.35rem;                     /* respaldo si el navegador no entiende cqi */
  font-size: min(2.1rem, 8.6cqi);         /* «Transparencia» mide ~10.4 em: así cabe en su carta */
  color: inherit;
}
.x-about__front p { position: relative; max-width: 30ch; font: 400 0.95rem/1.5 var(--f-ui); opacity: 0.85; }
/* número gigante de fondo: llena la carta sin agregar texto */
.x-about__ghost {
  position: absolute; right: -0.04em; bottom: -0.2em;
  font-family: var(--f-x); font-weight: 600; letter-spacing: -0.06em; line-height: 1;
  font-size: min(9rem, 34cqi);
  color: currentColor; opacity: 0.08;
  pointer-events: none;
}
/* brillo que sigue al mouse */
.x-about__front::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(circle at var(--gx, 50%) var(--gy, 50%), rgb(255 255 255 / 0.32), transparent 55%);
  opacity: 0; transition: opacity 300ms;
}
.x-about__value:hover .x-about__front::after { opacity: 1; }
/* reverso: el isotipo sobre una trama, como el dorso de una carta */
.x-about__back {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  transform: rotateY(180deg);
  background:
    repeating-linear-gradient(45deg, rgb(255 255 255 / 0.05) 0 2px, transparent 2px 12px),
    #18181D;
  border: 1px solid var(--c-border-strong);
}
.x-about__back svg { width: min(34%, 110px); fill: var(--bg); }
.x-about__value--line .x-about__back svg { fill: var(--c-ink); }

.x-about__foot {
  margin-top: clamp(3.5rem, 7vw, 6rem);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1.5rem;
}
.x-about__foot .x-mono { font-size: 0.75rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--c-muted-ink); }

@media (max-width: 1024px) {
  .x-about__values { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .x-about__value, .x-about__value:nth-child(n+4) { grid-column: span 1; }
  .x-about__value:last-child { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .x-about__intro { grid-template-columns: 1fr; align-items: start; }
  .x-about__values { grid-template-columns: 1fr; }
  .x-about__value:last-child { grid-column: auto; }
  .x-about__value { rotate: 0deg !important; }
}


/* ==========================================================================
   Nuestro trabajo: recorrido con scroll (initMapTour en experience.js).
   El mapa queda fijo en pantalla y el scroll lo desliza, sin paradas, por
   todos los proyectos; se puede seguir arrastrando. Sin JS o con movimiento
   reducido queda el mapa de antes, solo arrastrable.
   ========================================================================== */
.x-work--scroll { overflow: clip; }            /* overflow hidden impediría que el mapa se quede fijo */
/* recorrido vertical: el mapa sube mientras bajas, se mece a los lados y cada
   proyecto levanta sus mosaicos al pasar por el centro (--lift, de 0 a 1) */
.x-map--scroll { height: 320svh; }
.x-map--scroll .x-map__viewport {
  position: sticky; top: 0;
  height: 100vh; height: 100svh;
}
.x-map--scroll .x-map__plane { transform: rotateX(var(--tilt)) rotateZ(var(--rz, 0deg)) translate3d(var(--tx), var(--ty), 0); }
.x-map--scroll .x-cluster__tiles > * {
  transition: transform 160ms linear, box-shadow 160ms linear;
  box-shadow: 0 calc(var(--lift, 0) * 30px) calc(var(--lift, 0) * 46px) -18px rgb(0 0 0 / 0.6);
}
.x-map--scroll .x-cluster__tiles > :nth-child(1) { transform: translateZ(calc(var(--lift, 0) * 80px)); }
.x-map--scroll .x-cluster__tiles > :nth-child(2) { transform: translateZ(calc(var(--lift, 0) * 45px)); }
.x-map--scroll .x-cluster__tiles > :nth-child(3) { transform: translateZ(calc(var(--lift, 0) * 62px)); }
.x-map--scroll .x-cluster__tiles > :nth-child(4) { transform: translateZ(calc(var(--lift, 0) * 34px)); }
.x-map--scroll .x-map__hint { bottom: 2.6rem; }
.x-map__progress {
  position: absolute; left: 50%; bottom: 1.4rem; translate: -50% 0;
  width: min(260px, 50vw); height: 3px; border-radius: 3px; overflow: hidden;
  background: var(--c-border-strong);
}
.x-map__progress i {
  display: block; width: 100%; height: 100%;
  transform-origin: left; transform: scaleX(var(--mp, 0));
  background: linear-gradient(90deg, var(--c-brand), var(--c-violet));
}
.x-map--scroll .x-map__hint { white-space: nowrap; }
@media (max-width: 560px) { .x-map--scroll .x-map__hint { font-size: 0.6rem; letter-spacing: 0.06em; padding: 0.5rem 0.85rem; } }


/* ==========================================================================
   Páginas internas (Servicios): las tarjetas de servicio miden 106vw y
   arrancan 3vw antes del borde (bloque v13, de borde a borde). El margen
   interior tiene que compensar ese exceso; con el de .x-internal (3rem) el
   título, las etiquetas y la lista quedaban fuera de la pantalla.
   ========================================================================== */
.x-internal .x-card { padding-inline: calc(3vw + max(var(--x-pad), (100vw - var(--wrap)) / 2 + var(--x-pad))); }
@media (max-width: 860px) {
  .x-internal .x-card { padding-inline: calc(3vw + var(--x-pad)); }
}


/* ==========================================================================
   Celular (auditoría responsive): textos de al menos 12 px y áreas táctiles
   de 44 px en enlaces del pie, teléfonos y correo, sin cambiar cómo se ven.
   ========================================================================== */
@media (max-width: 600px) {
  .x-mono, .x-card__kicker { font-size: 0.75rem; }
  .header .brand { min-height: 44px; }
  .footer li a { min-height: 44px; }
  .footer address a, .footer__links a { display: inline-block; padding-block: 0.75rem; margin-block: -0.75rem; }
  .x-cta__mail { display: inline-flex; align-items: center; min-height: 44px; }
}


/* ==========================================================================
   Menú en tablet y celular. La regla del header de vidrio
   (.header .header__inner > * { position: relative }) le quitaba al menú su
   posición flotante: ocupaba espacio en la barra y empujaba el botón ☰ fuera
   de la pantalla (en 390 px quedaba entre 411 y 457 px). Ahora es un panel
   bajo la barra, del mismo ancho; absoluto y no fijo, porque el desenfoque de
   la barra cambia la referencia de los elementos fijos.
   ========================================================================== */
@media (max-width: 1100px) {
  .header .header__inner > .nav {
    position: absolute;
    top: calc(100% + 10px); left: 0; right: 0;
    max-height: calc(100svh - 110px);
    overflow-y: auto; overscroll-behavior: contain;
  }
}
/* ☰ → ✕: con display:grid las tres líneas se repartían en todo el alto del botón y la ✕ salía como «>» */
.burger { align-content: center; justify-content: center; }
/* initZoomFx mide el ancho real del texto sin los desplazamientos de letras ni el zoom */
.x-measuring [data-zoom] * { transform: none !important; translate: none !important; scale: none !important; }
/* Celular: bloques del recorrido más chicos para que al mecerse no queden cortados */
@media (max-width: 600px) { .x-map--scroll .x-map__plane { --cell: 72vw; } }

/* ==========================================================================
   Teléfonos en vertical: intro, portada, proceso, mapa, botones flotantes y pie
   ========================================================================== */
/* Intro: con left: 50% el bloque del logo solo tenía media pantalla de ancho y
   la «ō» de tbō se salía por la derecha; ahora mide lo que su contenido */
.intro__logo { width: max-content; }
@media (max-width: 600px) {
  /* las palabras de fondo caben enteras («AUDIOVISUAL» mide unas 5 veces su tamaño) */
  .intro__words span { font-size: 15.5vw; }
  .intro__tag { width: calc(100% - 2 * var(--x-pad)); white-space: normal; text-align: center; letter-spacing: 0.22em; line-height: 1.9; }
}

/* Portada: titular arriba, mascota grande al centro y el titular rotativo al pie */
@media (max-width: 600px) and (orientation: portrait) {
  .x-hero__inner { grid-template-rows: auto minmax(0, 1fr) auto; padding-bottom: max(1.75rem, env(safe-area-inset-bottom)); }
  .x-hero__title { grid-row: 1; }
  .x-hero__mascot { grid-area: 2 / 1; align-self: center; justify-self: center; margin: 0; }
  .x-hero__mascot .mascot { width: min(44vw, 26svh); }
  .x-hero__foot .hero__rotator { grid-area: 3 / 1; align-self: end; font-size: 1.35rem; }
}

/* Proceso: en el celular también avanza en horizontal, un paso por pantalla */
@media (max-width: 760px) {
  .x-process__sticky { gap: 1.25rem; justify-content: center; }
  .x-process__head { flex-direction: column; align-items: flex-start; gap: 0.9rem; }
  .x-process__head .x-h2 { font-size: clamp(2rem, 9.5vw, 2.8rem); max-width: none; }
  .x-process__track { gap: 0.9rem; }
  .x-step, .x-step--end { width: 80vw; height: min(46svh, 380px); min-height: 0; }
  .x-step:nth-child(even) { translate: 0 10px; }
  .x-step__num { font-size: 7.5rem; }
}

/* Mapa en vertical: los proyectos van en una sola columna (experience.js) y la
   cámara baja por ella; más recorrido y una cuadrícula que alcanza toda la columna */
@media (max-width: 760px) and (orientation: portrait) {
  .x-map--scroll { height: 480svh; }
}
.x-map--column .x-map__grid { inset: -120% -60%; }

/* Cierre: en el celular no ocupa una pantalla entera (quedaba un hueco antes del pie) */
@media (max-width: 760px) {
  .x-cta { min-height: 0; justify-content: flex-start; padding-bottom: 3.5rem; }
}


/* Pie en el celular: navegación y servicios lado a lado, contacto debajo y
   las redes primero; el final deja espacio a los botones flotantes */
@media (max-width: 600px) {
  .footer { padding-top: var(--s-6); }
  .footer__top { grid-template-columns: minmax(0, 1fr); gap: 2rem; padding-bottom: var(--s-5); }
  /* la navegación ya está en el menú de arriba: en el celular el pie no la repite */
  .footer__top > nav[aria-labelledby="f-nav"] { display: none; }
  .footer__top > nav[aria-labelledby="f-serv"] ul { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 1rem; }
  .footer__about { max-width: none; }
  .footer ul { gap: 0; }
  .footer li a { gap: 0; font-size: 0.92rem; line-height: 1.3; }
  .footer li a::before { display: none; }
  .footer__contact { gap: 0.9rem; }
  .footer__bottom { flex-direction: column; align-items: flex-start; gap: 1.1rem; padding-bottom: 6rem; }
  .footer__social { order: -1; }
  .footer__bottom > p { order: 1; }
  .footer__powered { display: block; margin: 0.35rem 0 0; padding: 0; border: 0; }
}

/* ==========================================================================
   Tablet y celular en horizontal (el celular en vertical va en mobile.css)
   ========================================================================== */
/* Tablet en vertical: titular grande arriba, mascota al centro y el rotativo al pie
   (antes: titular chico a media pantalla y la mitad vacía) */
@media (min-width: 761px) and (max-width: 1100px) and (orientation: portrait) {
  .x-hero__inner { grid-template-rows: auto minmax(0, 1fr) auto; }
  .x-hero__title { grid-row: 1; align-self: start; margin-top: 1.5rem; font-size: 8.2vw; }
  .x-hero__mascot { position: relative; top: auto; right: auto; bottom: auto; grid-area: 2 / 1; align-self: center; justify-self: center; margin: 0; }
  .x-hero__mascot .mascot { width: min(34vw, 30svh); }
  .x-hero__foot { grid-row: 3; }
}

/* Celular en horizontal (pantalla baja): las tarjetas fijas eran más altas que la pantalla
   y su título y botón nunca se veían. Aquí no se quedan fijas y van en dos columnas */
@media (min-width: 761px) and (max-height: 520px) {
  .x-card { position: relative; top: auto; min-height: 0; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; padding: 1.25rem 1.5rem; }
  .x-card + .x-card { margin-top: 1.5rem; }
  .x-card__visual.svc__visual { height: 210px; order: 0; }
  .x-card__title { font-size: 1.7rem; }
  /* proceso: encabezado en una fila y pasos que caben en la altura */
  .x-process__sticky { gap: 0.75rem; padding-top: 0.5rem; }
  .x-process__head { flex-wrap: nowrap; align-items: center; }
  .x-process__head .x-h2 { font-size: 1.5rem; max-width: none; }
  .x-step, .x-step--end { height: min(58svh, 240px); padding: 1rem 1.25rem; }
  .x-step__title { font-size: 1.25rem; }
  .x-step__num { font-size: 5rem; }
  .x-step__px { width: 48px; }
  .x-step__mascot { width: 64px; height: 64px; }
}

/* Pantallas táctiles: enlaces con altura para el dedo y sin la pista del mouse */
@media (pointer: coarse) {
  .link-arrow, .x-cta__mail { display: inline-flex; align-items: center; min-height: 44px; }
  .footer li a { min-height: 44px; }
  .header .brand { min-height: 44px; }
  .w-start__alt { display: inline-block; padding-block: 0.7rem; }
  .x-hero__hint { display: none; }
}

/* Ficha del proyecto: imágenes propias abajo (sin el zoom de los recortes de antes);
   sin ellas, solo la portada y la información, sin repetir la misma foto */
.x-case.has-shots .x-case__crop img { transform: none; object-position: 50% 50%; }
.x-case.is-single .x-case__crop, .x-case.is-single .x-case__url { display: none; }

/* ==========================================================================
   Ficha del proyecto v2: sala oscura con la portada desenfocada de fondo, el color
   del proyecto y su nombre gigante. La apertura (is-enter), el paso de proyecto
   (is-swap) y el cierre (is-leave) los pone initCaseFx en experience.js
   ========================================================================== */
.x-case {
  /* 100vw contaba la barra de scroll y la ✕ quedaba debajo, cortada */
  position: fixed; inset: 0; width: 100%; height: 100%;
  background: #0B0B0E; color: #F4F4F5;
  overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain;
  isolation: isolate;
  scrollbar-color: rgb(255 255 255 / 0.25) transparent;
  --k: #FF5000;
  --c-ink: #F4F4F5; --c-ink-soft: rgb(244 244 245 / 0.8); --c-muted-ink: rgb(244 244 245 / 0.62);
  --c-surface: rgb(22 22 28 / 0.62); --c-border: rgb(255 255 255 / 0.12); --c-muted: rgb(255 255 255 / 0.1);
  --c-bg: #0B0B0E;
}
.x-case[open] { animation: none; }
.x-case::backdrop { background: rgb(5 5 8 / 0.7); }

/* Fondo: la portada muy desenfocada, un brillo con el color del proyecto y el nombre gigante */
.x-case__bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.x-case__bg canvas { position: absolute; inset: -10%; width: 120%; height: 120%; max-width: none; max-height: none; opacity: 0.5; transform: scale(1.1); will-change: transform, opacity; }
.x-case__bg::after {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(60% 55% at 30% 35%, color-mix(in oklab, var(--k) 55%, transparent), transparent 70%),
    linear-gradient(180deg, rgb(11 11 14 / 0.2), rgb(11 11 14 / 0.85) 75%);
}
.x-case__giant {
  position: fixed; left: 0; bottom: -0.16em; z-index: -1; margin: 0; pointer-events: none;
  font: 800 clamp(5rem, 19vw, 20rem)/1 var(--f-display); font-stretch: 75%; letter-spacing: -0.05em;
  white-space: nowrap; color: transparent; -webkit-text-stroke: 1.5px rgb(255 255 255 / 0.13);
  animation: xGiantDrift 38s linear infinite alternate;
}
@keyframes xGiantDrift { from { translate: 2vw 0; } to { translate: calc(100vw - 100% - 2vw) 0; } }

/* Contenido */
.x-case__inner { position: relative; padding-top: clamp(5rem, 9vw, 6.5rem); padding-bottom: 2.5rem; }
.x-case__close {
  top: clamp(1rem, 2vw, 1.5rem); right: clamp(1rem, 2vw, 1.5rem); z-index: 5;
  background: #F4F4F5; color: #0B0B0E;
  box-shadow: 0 10px 30px -10px rgb(0 0 0 / 0.6);
}
.x-case__close:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 3px; }
.x-case__bento { grid-auto-rows: minmax(clamp(110px, 16vh, 170px), auto); gap: 12px; }
.x-case__bento > * { border-radius: 22px; }
.x-case__hero { position: relative; box-shadow: 0 40px 90px -40px color-mix(in oklab, var(--k) 70%, #000), 0 0 0 1px rgb(255 255 255 / 0.08); }
.x-case__hero img { transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1); }
.x-case__hero:hover img { transform: scale(1.04); }
.x-case__info { background: rgb(20 20 26 / 0.82); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.08); }
.x-case__num { color: var(--c-brand); letter-spacing: 0.14em; }
.x-case__title { color: #fff; }
.x-case__tags span { border: 1px solid rgb(255 255 255 / 0.14); background: rgb(255 255 255 / 0.06); color: #F4F4F5; }
.x-case__crop { box-shadow: 0 0 0 1px rgb(255 255 255 / 0.08); }
.x-case__url {
  background: linear-gradient(135deg, var(--k), color-mix(in oklab, var(--k) 60%, #FF5000));
  font-size: 0.95rem; letter-spacing: 0.08em; box-shadow: 0 0 0 1px rgb(255 255 255 / 0.12);
}
.x-case__nav { gap: 1rem; margin-top: 1.75rem; }
.x-case__nav button {
  padding: 0.85rem 1.4rem; min-height: 48px; border-radius: 999px;
  border: 1px solid rgb(255 255 255 / 0.18); color: #F4F4F5; background: rgb(255 255 255 / 0.04);
  transition: background-color 200ms, color 200ms, border-color 200ms, transform 300ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.x-case__nav button:hover { background: #F4F4F5; color: #0B0B0E; border-color: #F4F4F5; }
.x-case__prev:hover { transform: translateX(-4px); }
.x-case__next:hover { transform: translateX(4px); }
.x-case__nav button:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 3px; }

/* Sin imágenes propias: portada e información grandes, ocupan la pantalla (antes quedaba
   media pantalla vacía) */
@media (min-width: 861px) {
  .x-case.is-single .x-case__hero, .x-case.is-single .x-case__info { grid-row: span 4; }
  .x-case.is-single .x-case__hero { grid-column: span 7; }
  .x-case.is-single .x-case__info { grid-column: span 5; justify-content: center; }
}
@media (max-width: 860px) {
  .x-case__hero { box-shadow: 0 24px 50px -30px color-mix(in oklab, var(--k) 70%, #000); }
  .x-case__giant { font-size: 30vw; }
}

/* --- Apertura: la ficha se abre desde el mosaico que se tocó --- */
.x-case.is-enter { animation: xCaseOpen 900ms cubic-bezier(0.77, 0, 0.18, 1) both; }
@keyframes xCaseOpen {
  from { transform: translate(var(--otx, 0), var(--oty, 0)) scale(var(--osc, 0.3)); opacity: 0.25; }
  55%  { opacity: 1; }
  to   { transform: none; opacity: 1; }
}
.x-case.is-enter::backdrop { animation: xFadeIn 500ms ease-out both; }
@keyframes xFadeIn { from { opacity: 0; } }
.x-case.is-enter .x-case__bg canvas { animation: xBgIn 1500ms cubic-bezier(0.16, 1, 0.3, 1) both; }
@keyframes xBgIn { from { opacity: 0; transform: scale(1.6); } }
.x-case.is-enter .x-case__bg::after { animation: xGlowIn 1600ms cubic-bezier(0.16, 1, 0.3, 1) 150ms both; }
@keyframes xGlowIn { from { opacity: 0; transform: scale(0.4); } }
.x-case.is-enter .x-case__giant { animation: xGiantIn 1500ms cubic-bezier(0.16, 1, 0.3, 1) 250ms both, xGiantDrift 38s linear 1750ms infinite alternate; }
@keyframes xGiantIn { from { opacity: 0; translate: 40vw 0; letter-spacing: 0.1em; } to { translate: 2vw 0; } }
/* la portada llega girando en 3D, desenfocada, y se asienta */
.x-case.is-enter .x-case__hero { animation: xHeroIn 1150ms cubic-bezier(0.16, 1, 0.3, 1) 280ms both; transform-origin: 30% 60%; will-change: transform, opacity; }
@keyframes xHeroIn {
  from { opacity: 0; transform: perspective(1400px) translate3d(-6%, 90px, 0) rotateX(16deg) rotateY(18deg) scale(0.82); }
  to   { opacity: 1; transform: none; }
}
.x-case.is-enter .x-case__hero img { animation: xKen 1700ms cubic-bezier(0.16, 1, 0.3, 1) 280ms both; }
@keyframes xKen { from { transform: scale(1.35); } }
.x-case.is-enter .x-case__info { animation: xInfoIn 900ms cubic-bezier(0.16, 1, 0.3, 1) 420ms both; }
@keyframes xInfoIn { from { opacity: 0; transform: translate3d(70px, 0, 0); } }
.x-case.is-enter .x-case__info > * { animation: xUp 700ms cubic-bezier(0.16, 1, 0.3, 1) both; }
.x-case.is-enter .x-case__info > :nth-child(1) { animation-delay: 560ms; }
.x-case.is-enter .x-case__info > :nth-child(2) { animation: xTitleIn 900ms cubic-bezier(0.16, 1, 0.3, 1) 600ms both; }
.x-case.is-enter .x-case__info > :nth-child(3) { animation-delay: 700ms; }
.x-case.is-enter .x-case__info > :nth-child(4) { animation-delay: 760ms; }
.x-case.is-enter .x-case__info > :nth-child(5) { animation-delay: 820ms; }
.x-case.is-enter .x-case__info > :nth-child(6) { animation: xPop 700ms cubic-bezier(0.34, 1.56, 0.64, 1) 900ms both; }
@keyframes xUp { from { opacity: 0; transform: translateY(18px); } }
@keyframes xTitleIn { from { opacity: 0; transform: translateY(0.5em); clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 -20% 0); } }
@keyframes xPop { from { opacity: 0; transform: scale(0.6); } }
.x-case.is-enter .x-case__tags span { animation: xPop 600ms cubic-bezier(0.34, 1.56, 0.64, 1) both; }
.x-case.is-enter .x-case__tags span:nth-child(1) { animation-delay: 840ms; }
.x-case.is-enter .x-case__tags span:nth-child(2) { animation-delay: 900ms; }
.x-case.is-enter .x-case__tags span:nth-child(3) { animation-delay: 960ms; }
/* las imágenes de abajo salen de detrás de la portada */
.x-case.is-enter .x-case__crop--a { animation: xCropA 1000ms cubic-bezier(0.16, 1, 0.3, 1) 640ms both; }
.x-case.is-enter .x-case__crop--b { animation: xCropB 1000ms cubic-bezier(0.16, 1, 0.3, 1) 740ms both; }
@keyframes xCropA { from { opacity: 0; transform: translate3d(20%, -55%, 0) rotate(-7deg) scale(0.7); } }
@keyframes xCropB { from { opacity: 0; transform: translate3d(-10%, -60%, 0) rotate(6deg) scale(0.7); } }
.x-case.is-enter .x-case__url { animation: xFlip 900ms cubic-bezier(0.16, 1, 0.3, 1) 860ms both; }
@keyframes xFlip { from { opacity: 0; transform: perspective(800px) rotateY(85deg); } }
.x-case.is-enter .x-case__close { animation: xCloseIn 700ms cubic-bezier(0.34, 1.56, 0.64, 1) 650ms both; }
@keyframes xCloseIn { from { opacity: 0; transform: rotate(-180deg) scale(0.2); } }
.x-case.is-enter .x-case__nav { animation: xUp 700ms cubic-bezier(0.16, 1, 0.3, 1) 1000ms both; }

/* --- Paso a otro proyecto: todo se desliza hacia el lado elegido --- */
.x-case { --dir: 1; }
.x-case.is-swap .x-case__hero { animation: xSwapHero 800ms cubic-bezier(0.16, 1, 0.3, 1) both; }
@keyframes xSwapHero {
  from { opacity: 0; transform: perspective(1400px) translate3d(calc(var(--dir) * 14%), 0, 0) rotateY(calc(var(--dir) * -14deg)) scale(0.9); }
}
.x-case.is-swap .x-case__hero img { animation: xKen 1100ms cubic-bezier(0.16, 1, 0.3, 1) both; }
.x-case.is-swap .x-case__bg canvas { animation: xSwapFade 900ms ease-out both; }
@keyframes xSwapFade { from { opacity: 0; } }
.x-case.is-swap .x-case__giant { animation: xSwapGiant 900ms cubic-bezier(0.16, 1, 0.3, 1) both, xGiantDrift 38s linear 900ms infinite alternate; }
@keyframes xSwapGiant { from { opacity: 0; translate: calc(var(--dir) * 30vw + 2vw) 0; } to { translate: 2vw 0; } }
.x-case.is-swap .x-case__info > * { animation: xSwapIn 650ms cubic-bezier(0.16, 1, 0.3, 1) both; }
.x-case.is-swap .x-case__info > :nth-child(2) { animation-delay: 60ms; }
.x-case.is-swap .x-case__info > :nth-child(3) { animation-delay: 110ms; }
.x-case.is-swap .x-case__info > :nth-child(4) { animation-delay: 150ms; }
.x-case.is-swap .x-case__info > :nth-child(5) { animation-delay: 190ms; }
.x-case.is-swap .x-case__info > :nth-child(6) { animation-delay: 230ms; }
@keyframes xSwapIn { from { opacity: 0; transform: translate3d(calc(var(--dir) * 40px), 0, 0); } }
.x-case.is-swap .x-case__crop--a { animation: xSwapIn 700ms cubic-bezier(0.16, 1, 0.3, 1) 120ms both; }
.x-case.is-swap .x-case__crop--b { animation: xSwapIn 700ms cubic-bezier(0.16, 1, 0.3, 1) 180ms both; }
.x-case.is-swap .x-case__url { animation: xFlip 700ms cubic-bezier(0.16, 1, 0.3, 1) 220ms both; }

/* --- Cierre: se recoge hacia donde se abrió --- */
.x-case.is-leave { animation: xCaseClose 420ms cubic-bezier(0.7, 0, 0.84, 0) both; pointer-events: none; }
@keyframes xCaseClose {
  to { transform: translate(var(--otx, 0), var(--oty, 0)) scale(var(--osc, 0.3)); opacity: 0; }
}
.x-case.is-leave::backdrop { animation: xFadeOut 420ms ease-in both; }
@keyframes xFadeOut { to { opacity: 0; } }
.x-case.is-leave .x-case__inner { animation: xLeaveIn 420ms cubic-bezier(0.7, 0, 0.84, 0) both; }
@keyframes xLeaveIn { to { opacity: 0.4; transform: scale(0.94); } }

/* En el celular, sin desenfoques animados (cuestan mucho en pantallas pequeñas) */
@media (max-width: 760px) {
  @keyframes xHeroIn {
    from { opacity: 0; transform: perspective(1000px) translate3d(0, 60px, 0) rotateX(14deg) scale(0.88); }
    to   { opacity: 1; transform: none; }
  }
  .x-case__info { background: rgb(22 22 28 / 0.88); }
}
@media (prefers-reduced-motion: reduce) {
  .x-case__giant { animation: none; }
  .x-case__hero img { transition: none; }
}

/* ==========================================================================
   Nuestro trabajo v3: vuelo de dron (initMapTour). Vista de todo el mapa, picada al
   01, se posa casi de frente con su ficha al lado, despega ladeándose y vuela al
   siguiente. Una parada por proyecto (--stops)
   ========================================================================== */
.x-map--scroll { height: calc(100svh + var(--stops, 9) * 58svh); }
.x-map--scroll .x-map__viewport { perspective: 1600px; perspective-origin: 50% 50%; }
.x-map--scroll .x-map__plane { will-change: transform; }
/* foco: oscurece los bordes y la izquierda, donde va la ficha, cuando la cámara se posa */
.x-map__spot {
  position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0;
  background:
    radial-gradient(44% 56% at 62% 50%, transparent 50%, rgb(13 13 16 / 0.82) 100%),
    linear-gradient(90deg, rgb(13 13 16 / 0.92) 0%, rgb(13 13 16 / 0.55) 30%, transparent 48%);
}
.x-map__hud {
  position: absolute; z-index: 2; top: 50%; translate: 0 -50%;
  left: max(var(--x-pad), (100vw - var(--wrap)) / 2 + var(--x-pad));
  width: min(29vw, 420px);
  display: flex; flex-direction: column; align-items: flex-start; gap: 0.9rem;
  pointer-events: none; color: #F4F4F5;
}
.x-map__hud-num { margin: 0; font-size: 0.8rem; letter-spacing: 0.18em; text-transform: uppercase; color: rgb(244 244 245 / 0.6); }
.x-map__hud-num b {
  display: block; margin-bottom: 0.35rem;
  font: 600 clamp(3.5rem, 6.5vw, 6.5rem)/0.85 var(--f-x); letter-spacing: -0.04em;
  color: transparent; -webkit-text-stroke: 2px var(--c-brand);
}
.x-map__hud-title {
  margin: 0; font: 600 clamp(1.5rem, 2.3vw, 2.4rem)/1.02 var(--f-x); letter-spacing: -0.035em;
  text-wrap: balance; color: #fff;
}
.x-map__hud-client { margin: 0; font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--c-brand); }
.x-map__hud-client:empty, .x-map__hud-tags:empty { display: none; }
.x-map__hud-tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0; }
.x-map__hud-tags span { padding: 0.3rem 0.75rem; border-radius: 999px; border: 1px solid rgb(255 255 255 / 0.18); font-size: 0.8rem; font-weight: 600; }
.x-map__hud-go { pointer-events: auto; margin-top: 0.4rem; }
/* entra por partes al posarse; al despegar se va rápido */
.x-map__hud > * { opacity: 0; transform: translate3d(-24px, 0, 0); transition: opacity 220ms ease-in, transform 220ms ease-in; }
.x-map__hud-title { clip-path: inset(0 0 100% 0); transition: opacity 220ms ease-in, transform 220ms ease-in, clip-path 220ms ease-in; }
.x-map__hud.is-in > * { opacity: 1; transform: none; transition: opacity 600ms cubic-bezier(0.16, 1, 0.3, 1), transform 800ms cubic-bezier(0.16, 1, 0.3, 1), clip-path 800ms cubic-bezier(0.16, 1, 0.3, 1); }
.x-map__hud.is-in .x-map__hud-title { clip-path: inset(-10% -10% -20% -10%); transition-delay: 90ms; }
.x-map__hud.is-in > :nth-child(3) { transition-delay: 170ms; }
.x-map__hud.is-in > :nth-child(4) { transition-delay: 230ms; }
.x-map__hud.is-in > :nth-child(5) { transition-delay: 300ms; }
.x-map__hud:not(.is-in) .x-map__hud-go { pointer-events: none; }
/* el nombre y la etiqueta del mosaico sobran cuando está la ficha al lado */
.x-map--scroll .x-cluster__label { transition: opacity 300ms; }
/* en vertical (tablet): la ficha va abajo y el proyecto arriba */
@media (max-aspect-ratio: 10/9) {
  .x-map__hud { top: auto; bottom: 4.5rem; translate: none; left: var(--x-pad); right: var(--x-pad); width: auto; }
  .x-map__hud-num b { font-size: clamp(3.5rem, 10vw, 6rem); }
  .x-map__spot { background: radial-gradient(60% 40% at 50% 40%, transparent 50%, rgb(13 13 16 / 0.8) 100%), linear-gradient(0deg, rgb(13 13 16 / 0.92) 0%, rgb(13 13 16 / 0.5) 30%, transparent 50%); }
}


/* ==========================================================================
   Hélice de proyectos: tarjeta compartida (repositorio y «Nuestro trabajo»)
   ========================================================================== */
.tunnel__card {
  position: absolute; left: 0; top: 0;
  display: block; padding: 0; border: 0; margin: 0;
  border-radius: 18px; overflow: hidden;
  background: var(--tile-color, #141418);
  color: #fff; text-align: left; cursor: pointer;
  backface-visibility: visible;
  box-shadow: 0 30px 60px -30px rgb(0 0 0 / 0.8), 0 0 0 1px rgb(255 255 255 / 0.06);
  -webkit-tap-highlight-color: transparent;
}
.tunnel__card img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 900ms cubic-bezier(0.16, 1, 0.3, 1); }
.tunnel__card::after {                     /* degradado para que el nombre se lea */
  content: ''; position: absolute; inset: 45% 0 0 0; pointer-events: none;
  background: linear-gradient(180deg, transparent, rgb(0 0 0 / 0.72));
}
.tunnel__card-text {
  position: absolute; left: 6%; right: 6%; bottom: 6%; z-index: 1;
  display: grid; gap: 0.35rem; pointer-events: none;
}
.tunnel__card-text small { font: 500 0.72rem/1.3 var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; color: rgb(255 255 255 / 0.72); }
.tunnel__card-text strong {
  font: 600 clamp(1.3rem, 2.3vw, 2.3rem)/1.02 var(--f-x); letter-spacing: -0.035em;
  white-space: nowrap; overflow: hidden; text-overflow: clip;
  text-shadow: 0 2px 18px rgb(0 0 0 / 0.5);
}
.tunnel__card-shade { position: absolute; inset: 0; z-index: 2; background: #070709; opacity: 0; pointer-events: none; }
.tunnel__card:hover img, .tunnel__card:focus-visible img { transform: scale(1.05); }
.tunnel__card:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 4px; }
@media (max-width: 699px) {
  .tunnel__card { border-radius: 14px; }
  .tunnel__card-text strong { font-size: 1.15rem; }
  .tunnel__card-text small { font-size: 0.62rem; }
}

/* «Nuestro trabajo» en hélice (initWorkHelix): mismo escenario que el repositorio */
.x-map--helix .x-map__viewport, .x-map--helix .x-map__hint, .x-map--helix .x-map__progress { display: none; }
.x-work--helix { overflow: clip; padding-bottom: 0; }
.x-map--helix { position: relative; }
.x-helix {
  position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; isolation: isolate;
  background: radial-gradient(90% 70% at 50% 50%, #16161B 0%, #0B0B0E 55%, #070709 100%);
  color: #F4F4F5;
}
.x-helix__viewport { position: absolute; inset: 0; overflow: hidden; perspective: 1400px; perspective-origin: 50% 50%; }
.x-helix__camera, .x-helix__world { position: absolute; width: 0; height: 0; transform-style: preserve-3d; }
.x-helix__camera { left: 50%; top: 50%; }
.x-helix__world { left: 0; top: 0; will-change: transform; }
.x-helix__hud {
  position: absolute; z-index: 3; left: 0; right: 0; bottom: 0;
  padding: 0 max(var(--x-pad), (100vw - var(--wrap)) / 2 + var(--x-pad)) 1.4rem;
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0.9rem 1.5rem;
  background: linear-gradient(180deg, transparent, rgb(7 7 9 / 0.85) 45%);
  padding-top: 3rem;
}
.x-helix__status { display: flex; align-items: baseline; gap: 1.2rem; min-width: 0; margin: 0; }
.x-helix__counter { flex: none; color: var(--c-brand); font-size: 0.8rem; }
.x-helix__name { font: 600 clamp(1rem, 1.8vw, 1.5rem)/1.2 var(--f-x); letter-spacing: -0.03em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.x-helix__controls { display: flex; align-items: center; gap: 0.45rem; }
.x-helix__btn {
  min-width: 48px; min-height: 48px; padding: 0 1rem; border-radius: 999px;
  border: 1px solid rgb(255 255 255 / 0.2); background: rgb(255 255 255 / 0.04); color: #F4F4F5;
  font: 600 0.95rem/1 var(--f-ui); cursor: pointer;
  transition: background-color 200ms, color 200ms, transform 300ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.x-helix__btn:hover:not(:disabled) { background: #F4F4F5; color: #0B0B0E; transform: translateY(-2px); }
.x-helix__btn:disabled { opacity: 0.3; cursor: default; }
.x-helix__btn:focus-visible, .x-helix__all:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 3px; }
.x-helix__open { background: var(--c-brand); border-color: var(--c-brand); color: var(--c-on-brand, #fff); }
.x-helix__all { margin-left: 0.6rem; display: inline-flex; align-items: center; min-height: 44px; font: 600 0.9rem/1 var(--f-ui); color: #F4F4F5; text-decoration: underline; text-underline-offset: 5px; }
.x-helix__progress { grid-column: 1 / -1; height: 2px; border-radius: 2px; background: rgb(255 255 255 / 0.14); overflow: hidden; }
.x-helix__progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--c-brand), var(--c-violet)); transform: scaleX(0); transform-origin: left; }
@media (max-width: 760px) {
  .x-helix__hud { grid-template-columns: minmax(0, 1fr); padding-bottom: 1rem; }
  .x-helix__status { justify-content: space-between; }
  .x-helix__name { font-size: 0.95rem; }
  .x-helix__controls { justify-content: space-between; }
  .x-helix__open { flex: 1; }
  .x-helix__all { display: none; }
  .x-helix__camera { top: 44%; }              /* sobre la barra de abajo */
}

.in-helix .to-top { opacity: 0 !important; pointer-events: none !important; transform: translateY(12px); }

/* Formulario de contacto: campo trampa para robots y estado de error */
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form__status.is-error { background: rgb(229 72 77 / 0.1); border-color: rgb(229 72 77 / 0.4); }

/* El menú queda fijo: ya no se esconde al bajar */
.header.is-hidden { transform: none; }

/* contacto: la mascota de tbō sobre Quito de noche, de fondo (assets/img/arte); se acerca despacio */
.x-page-hero--art { background: #101014; color: #F4F4F5; }
.x-page-hero__art { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.x-page-hero__art img { width: 100%; height: 100%; object-fit: cover; object-position: 0% 55%; transform-origin: 70% 50%; animation: xHeroArt 26s ease-in-out infinite alternate; }
.x-page-hero__art::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, #101014 8%, rgb(16 16 20 / 0.82) 34%, rgb(16 16 20 / 0.2) 62%, transparent 78%),
              linear-gradient(0deg, #101014 0%, rgb(16 16 20 / 0.5) 18%, transparent 40%);
}
.x-page-hero--art .x-page-hero__inner { z-index: 1; }
.x-page-hero--art .x-page-hero__stamp { display: none; }
/* sobre la imagen el texto va siempre claro, en tema claro y oscuro */
.x-page-hero--art .x-page-hero__title { color: #F4F4F5; text-shadow: 0 2px 30px rgb(0 0 0 / 0.35); }
.x-page-hero--art .x-page-hero__accent { color: #FF6A1F; }
.x-page-hero--art .btn--light { --btn-bg: #FFFFFF; --btn-fg: #141418; background: #FFFFFF; color: #141418; }
.x-page-hero--art .x-breadcrumb, .x-page-hero--art .x-page-hero__body > .x-mono { color: rgb(244 244 245 / 0.65); }
.x-page-hero--art .x-breadcrumb [aria-current] { color: #F4F4F5; }
.x-page-hero--art .x-page-hero__foot { border-top-color: rgb(255 255 255 / 0.16); }
.x-page-hero--art .x-page-hero__foot p { color: rgb(244 244 245 / 0.78); }
@keyframes xHeroArt { from { transform: scale(1.02); } to { transform: scale(1.1) translate(-1.5%, 0); } }
@media (prefers-reduced-motion: reduce) { .x-page-hero__art img { animation: none; } }
@media (max-width: 760px) {
  .x-page-hero__art img { object-position: 74% 38%; opacity: 0.75; }
  .x-page-hero__art::after { background: linear-gradient(0deg, #101014 12%, rgb(16 16 20 / 0.62) 48%, rgb(16 16 20 / 0.12) 100%); }
}
