/* ============================================================
   EDWARD PERDOMO — identidad personal
   Sistema: tinta ultravioleta + porcelana fría + fluido iridiscente
   ============================================================ */

:root {
  /* Color */
  --ink: #16121E;
  --ink-soft: #241D31;
  --porcelain: #F5F4F9;
  --porcelain-dim: #E9E7F1;
  --violet: #6C2BD9;
  --magenta: #E93CAC;
  --coral: #FF6B4A;
  --amber: #FFB000;
  --cyan: #29D9D4;
  --text-on-dark: #F5F4F9;
  --text-dim-dark: rgba(245, 244, 249, 0.68);
  --text-dim-light: rgba(22, 18, 30, 0.66);
  --line-dark: rgba(245, 244, 249, 0.14);
  --line-light: rgba(22, 18, 30, 0.12);

  /* Tipo */
  --f-display: 'Syne', sans-serif;
  --f-body: 'Instrument Sans', sans-serif;
  --f-mono: 'JetBrains Mono', monospace;

  /* Ritmo */
  --gutter: clamp(20px, 5vw, 88px);
  --section-gap: clamp(88px, 14vh, 180px);

  --ease-spring: cubic-bezier(0.22, 1.4, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  /* clip en la raíz: evita que el layout viewport móvil se expanda */
  overflow-x: hidden;
  overflow-x: clip;
}

body {
  font-family: var(--f-body);
  background: var(--porcelain);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--magenta); color: #fff; }

img, canvas { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font: inherit; border: 0; background: none; cursor: pointer; color: inherit; }

.mono { font-family: var(--f-mono); }

/* Iconos SVG */
.ic { display: inline-flex; width: 1.15em; height: 1.15em; vertical-align: -0.2em; }
.ic svg { width: 100%; height: 100%; }

/* Accesibilidad */
.skip-link {
  position: fixed; top: -60px; left: 16px; z-index: 300;
  background: var(--ink); color: var(--porcelain);
  padding: 10px 18px; border-radius: 8px;
  font-family: var(--f-mono); font-size: 0.8rem;
  transition: top 0.2s;
}
.skip-link:focus { top: 12px; }

:focus-visible {
  outline: 2px solid var(--magenta);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ============================================================
   CURSOR
   ============================================================ */
.cursor { display: none; }

@media (hover: hover) and (pointer: fine) {
  .cursor { display: block; position: fixed; inset: 0; z-index: 250; pointer-events: none; }
  .cursor-dot,
  .cursor-ring {
    position: fixed; top: 0; left: 0;
    border-radius: 50%;
    will-change: transform;
  }
  .cursor-dot {
    width: 8px; height: 8px; margin: -4px 0 0 -4px;
    background: var(--magenta);
    mix-blend-mode: difference;
  }
  .cursor-ring {
    width: 38px; height: 38px; margin: -19px 0 0 -19px;
    border: 1.5px solid var(--magenta);
    opacity: 0.6;
    mix-blend-mode: difference;
    transition: width 0.25s var(--ease-out), height 0.25s var(--ease-out),
                margin 0.25s var(--ease-out), opacity 0.25s;
  }
  .cursor.is-active .cursor-ring {
    width: 64px; height: 64px; margin: -32px 0 0 -32px; opacity: 1;
  }
  .cursor.is-hidden { opacity: 0; }
}

/* ============================================================
   HEADER
   ============================================================ */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--gutter);
  transition: background 0.35s, box-shadow 0.35s, padding 0.35s;
}
.header.is-scrolled {
  background: rgba(245, 244, 249, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line-light);
  padding-top: 12px; padding-bottom: 12px;
}
.header.on-dark:not(.is-scrolled) { color: var(--text-on-dark); }

.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand-mark {
  font-family: var(--f-display); font-weight: 800; font-size: 1rem;
  letter-spacing: 0.04em;
  padding: 7px 11px; border-radius: 10px;
  background: linear-gradient(120deg, var(--violet), var(--magenta) 55%, var(--coral));
  color: #fff;
}
.brand-name {
  font-family: var(--f-display); font-weight: 700; font-size: 0.95rem;
  letter-spacing: 0.02em;
}

.nav { display: flex; align-items: center; gap: clamp(16px, 3vw, 34px); }
.nav-link {
  font-family: var(--f-mono); font-size: 0.78rem; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  position: relative; padding: 6px 2px;
}
.nav-link::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 100%; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, var(--violet), var(--magenta), var(--coral), var(--amber), var(--cyan));
  transform: scaleX(0); transform-origin: left;
  transition: transform 0.35s var(--ease-out);
}
.nav-link:hover::after { transform: scaleX(1); }
.nav-cta {
  padding: 8px 16px; border-radius: 999px;
  border: 1.5px solid currentColor;
}
.nav-cta::after { display: none; }
.nav-cta:hover { background: var(--magenta); border-color: var(--magenta); color: #fff; }

.burger {
  display: none;
  width: 44px; height: 44px;
  flex-direction: column; align-items: center; justify-content: center; gap: 7px;
  border-radius: 12px;
}
.burger span {
  display: block; width: 22px; height: 2px; border-radius: 2px;
  background: currentColor;
  transition: transform 0.3s var(--ease-out);
}
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(4.5px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4.5px) rotate(-45deg); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  background: var(--ink);
  color: var(--text-on-dark);
  overflow: hidden;
  padding: 120px var(--gutter) 90px;
  text-align: center;
}

.fluid {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  image-rendering: auto;
  /* funde los bordes de píxel del búfer de baja resolución (filtro GPU);
     el scale oculta el halo del desenfoque bajo el overflow:hidden */
  filter: blur(8px) saturate(1.08);
  transform: scale(1.05);
}
@media (max-width: 768px) {
  .fluid { filter: blur(5px) saturate(1.08); }
}
/* En WebGL se renderiza a resolución casi nativa: sin desenfoque */
.fluid.is-gl { filter: saturate(1.08); transform: none; }
@media (max-width: 768px) {
  /* de cerca, en un móvil, el fluido a plena saturación compite con el
     texto (sobre todo con "plantilla." en degradado): se calma para
     quedar como fondo, no como patrón que hay que leer alrededor */
  .fluid.is-gl { filter: saturate(0.62) brightness(0.7) contrast(1.03); }
}
.hero-veil {
  position: absolute; inset: 0;
  background:
    linear-gradient(rgba(22, 18, 30, 0.18), rgba(22, 18, 30, 0.18)),
    radial-gradient(ellipse 90% 70% at 50% 45%, transparent 30%, rgba(22, 18, 30, 0.55) 100%),
    linear-gradient(180deg, rgba(22, 18, 30, 0.35), transparent 30%, transparent 68%, rgba(22, 18, 30, 0.7));
  pointer-events: none;
}

.hero-inner { position: relative; max-width: 1000px; }

.eyebrow {
  font-size: 0.75rem; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase;
  margin-bottom: 26px;
  opacity: 0.85;
}

.hero-title {
  font-family: var(--f-display);
  /* proporcional al viewport en móvil para que "no parecen" quepa siempre */
  font-size: min(12vw, 7.2rem);
  line-height: 0.98;
  letter-spacing: -0.02em;
  font-weight: 700;
  text-wrap: balance;
  margin-bottom: 30px;
  cursor: default;
}
.hero-title .line { display: block; }
.hero-title .char {
  display: inline-block;
  font-variation-settings: "wght" var(--w, 700);
  transform: translateY(var(--y, 0));
  color: var(--ch-c, currentColor);
  will-change: font-variation-settings, transform;
}
.accent-line {
  background: linear-gradient(100deg, var(--violet) 0%, var(--magenta) 30%, var(--coral) 55%, var(--amber) 78%, var(--cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.accent-line .char { color: inherit; }
/* Cuando JS parte la línea en letras, el clip del degradado no pinta
   sobre los spans: pasamos a color sólido por letra (espectro en JS) */
.accent-line.split {
  background: none;
  -webkit-text-fill-color: initial;
  color: inherit;
}
.accent-line.split .char {
  color: var(--ch-c, currentColor);
  text-shadow: 0 3px 30px rgba(22, 18, 30, 0.85), 0 1px 8px rgba(22, 18, 30, 0.6);
}

.hero-sub {
  max-width: 560px; margin: 0 auto 42px;
  font-size: clamp(1rem, 1.6vw, 1.18rem);
  color: rgba(245, 244, 249, 0.82);
  text-shadow: 0 1px 20px rgba(22, 18, 30, 0.65);
  text-wrap: pretty;
}

.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-display); font-weight: 700; font-size: 0.95rem;
  padding: 16px 30px; border-radius: 999px;
  transition: background 0.3s, color 0.3s, border-color 0.3s, box-shadow 0.3s;
  will-change: transform;
}
.btn-solid {
  background: linear-gradient(115deg, var(--violet), var(--magenta) 60%, var(--coral));
  color: #fff;
  box-shadow: 0 10px 34px -10px rgba(233, 60, 172, 0.55);
}
.btn-solid:hover { box-shadow: 0 14px 44px -8px rgba(233, 60, 172, 0.8); }
.btn-ghost {
  border: 1.5px solid rgba(245, 244, 249, 0.4);
  color: var(--text-on-dark);
}
.btn-ghost:hover { border-color: var(--cyan); color: var(--cyan); }

.hero-hint {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--text-dim-dark);
  animation: hintPulse 3s ease-in-out infinite;
}
@keyframes hintPulse { 0%, 100% { opacity: 0.45; } 50% { opacity: 0.9; } }

/* ============================================================
   TICKER
   ============================================================ */
.ticker {
  background: var(--ink);
  border-top: 1px solid var(--line-dark);
  overflow: hidden;
  padding: 18px 0;
}
.ticker-track {
  display: flex; width: max-content;
  animation: tickerMove 26s linear infinite;
}
.ticker-seq {
  display: flex; align-items: center; gap: 38px;
  padding-right: 38px;
  font-family: var(--f-display); font-weight: 700;
  font-size: clamp(0.95rem, 1.8vw, 1.25rem);
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-on-dark);
  white-space: nowrap;
}
.ticker-seq span:nth-child(odd) {
  background: linear-gradient(100deg, var(--magenta), var(--amber));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.tick-gem {
  width: 10px; height: 10px; flex: none;
  background: linear-gradient(135deg, var(--cyan), var(--violet));
  transform: rotate(45deg); border-radius: 2px;
}
@keyframes tickerMove { to { transform: translateX(-50%); } }

/* ============================================================
   SECCIONES (base clara)
   ============================================================ */
.section { padding: var(--section-gap) var(--gutter); max-width: 1440px; margin: 0 auto; }

.section-head { max-width: 780px; margin-bottom: clamp(48px, 7vh, 80px); }
.section-head .eyebrow {
  background: linear-gradient(90deg, var(--violet), var(--magenta));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  opacity: 1; margin-bottom: 16px;
}
.section-title {
  font-family: var(--f-display);
  font-size: clamp(2.1rem, 5vw, 3.8rem);
  line-height: 1.02; letter-spacing: -0.02em; font-weight: 800;
  margin-bottom: 20px;
}
.section-sub { color: var(--text-dim-light); font-size: 1.05rem; max-width: 560px; text-wrap: pretty; }

/* Revelado en scroll */
.reveal { opacity: 0; transform: translateY(34px); }
.reveal.in {
  opacity: 1; transform: none;
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
  transition-delay: calc(var(--d, 0) * 90ms);
}

/* ============================================================
   SERVICIOS — tarjetas demo
   ============================================================ */
.cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(18px, 2.5vw, 30px);
}

.card {
  position: relative;
  background: #fff;
  border: 1px solid var(--line-light);
  border-radius: 22px;
  padding: clamp(24px, 3vw, 36px);
  display: flex; flex-direction: column; gap: 12px;
  transform-style: preserve-3d;
  transition: box-shadow 0.35s;
}
.card:hover { box-shadow: 0 24px 60px -24px rgba(108, 43, 217, 0.28); }

.card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.card-ic { width: 30px; height: 30px; color: var(--violet); }
.card-num { font-size: 0.72rem; letter-spacing: 0.14em; color: var(--text-dim-light); }

.card h3 { font-family: var(--f-display); font-size: 1.4rem; font-weight: 700; letter-spacing: -0.01em; }
.card > p { color: var(--text-dim-light); font-size: 0.98rem; }

.demo {
  margin-top: auto;
  border-radius: 14px;
  min-height: 150px;
  overflow: hidden;
  position: relative;
}
.demo-hint {
  font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase;
  opacity: 0.55; margin-top: 10px;
}

/* Demo 1: paleta */
.demo-palette {
  background: var(--porcelain-dim);
  padding: 18px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
}
.chip {
  width: 52px; height: 64px; border-radius: 10px;
  background: var(--chip, #ccc);
  border: 1px solid rgba(22, 18, 30, 0.08);
  transition: transform 0.4s var(--ease-spring), background 0.5s;
}
.chip:hover { transform: translateY(-6px) rotate(-3deg); }
.chip:active { transform: scale(0.94); }
.demo-palette .demo-hint { width: 100%; margin-top: 4px; }

/* Demo 2: código */
.demo-code {
  background: var(--ink);
  color: #B9B3CC;
  font-size: 0.74rem;
  display: flex; flex-direction: column;
}
.code-bar {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line-dark);
}
.code-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-dark); }
.code-bar i:nth-child(1) { background: var(--coral); }
.code-bar i:nth-child(2) { background: var(--amber); }
.code-bar i:nth-child(3) { background: var(--cyan); }
.code-file { margin-left: auto; font-size: 0.62rem; opacity: 0.5; }
.code-body {
  padding: 14px; margin: 0;
  font-family: var(--f-mono);
  line-height: 1.7; white-space: pre-wrap;
  min-height: 108px;
}
.code-body .tk-k { color: var(--magenta); }
.code-body .tk-f { color: var(--cyan); }
.code-body .tk-s { color: var(--amber); }
.code-caret {
  display: inline-block; width: 7px; height: 1em;
  background: var(--magenta); vertical-align: -0.15em;
  animation: caretBlink 0.9s steps(1) infinite;
}
@keyframes caretBlink { 50% { opacity: 0; } }

/* Demo 3: retícula de puntos */
.demo-dots { background: var(--ink); padding: 0; touch-action: pan-y; }
.dots-canvas { width: 100%; height: 150px; }
.demo-dots .demo-hint {
  position: absolute; bottom: 8px; left: 14px; margin: 0;
  color: var(--text-dim-dark);
}

/* Demo 4: IA */
.demo-ai {
  background: var(--porcelain-dim);
  padding: 18px;
  display: flex; flex-direction: column; justify-content: center; gap: 14px;
}
.ai-line {
  font-size: 0.8rem; line-height: 1.5; min-height: 3em;
  color: var(--ink-soft);
}
.ai-cursor {
  display: inline-block; width: 8px; height: 1em;
  background: var(--violet); vertical-align: -0.15em;
  animation: caretBlink 0.9s steps(1) infinite;
}
.ai-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.ai-tags span {
  font-size: 0.62rem; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 5px 10px; border-radius: 999px;
  border: 1px solid rgba(108, 43, 217, 0.35);
  color: var(--violet);
}

/* ============================================================
   PROCESO
   ============================================================ */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(18px, 2.5vw, 30px);
  counter-reset: step;
}
.step {
  position: relative;
  padding: 26px 22px 28px;
  border-top: 2px solid var(--line-light);
}
.step::before {
  content: ""; position: absolute; top: -2px; left: 0;
  width: 46px; height: 2px;
  background: linear-gradient(90deg, var(--violet), var(--magenta));
}
.step-num {
  display: block;
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.14em;
  background: linear-gradient(90deg, var(--violet), var(--magenta));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  margin-bottom: 14px;
}
.step h3 { font-family: var(--f-display); font-size: 1.2rem; font-weight: 700; margin-bottom: 8px; }
.step p { color: var(--text-dim-light); font-size: 0.94rem; }

/* ============================================================
   CAPACIDADES
   ============================================================ */
.stack { padding-top: 0; }
.stack .eyebrow {
  background: linear-gradient(90deg, var(--violet), var(--magenta));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  opacity: 1; margin-bottom: 22px;
}
.stack-list {
  display: flex; flex-wrap: wrap; gap: 10px;
}
.stack-list li {
  font-size: 0.78rem; letter-spacing: 0.04em;
  padding: 10px 18px;
  border: 1px solid var(--line-light);
  border-radius: 999px;
  transition: border-color 0.3s, color 0.3s, transform 0.3s var(--ease-spring);
}
.stack-list li:hover {
  border-color: var(--magenta); color: var(--magenta);
  transform: translateY(-3px);
}

/* ============================================================
   CONTACTO
   ============================================================ */
.contact {
  position: relative;
  background: var(--ink);
  color: var(--text-on-dark);
  overflow: hidden;
  padding: var(--section-gap) var(--gutter);
  text-align: center;
}
.contact-veil {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 65% at 50% 50%, transparent 20%, rgba(22, 18, 30, 0.72) 100%);
  pointer-events: none;
}
.contact-inner { position: relative; max-width: 820px; margin: 0 auto; }
.contact-title {
  font-family: var(--f-display);
  /* proporcional al viewport: "¿Construimos" (Syne es muy ancha)
     cabe en cualquier pantalla porque el ancho del texto escala con vw */
  font-size: min(8vw, 5.4rem);
  line-height: 1; letter-spacing: -0.02em; font-weight: 800;
  margin-bottom: 22px;
  text-shadow: 0 3px 30px rgba(22, 18, 30, 0.55);
}
.contact-sub {
  color: rgba(245, 244, 249, 0.85);
  text-shadow: 0 1px 18px rgba(22, 18, 30, 0.7);
  margin-bottom: 44px; font-size: 1.05rem;
}
.contact-mail {
  display: inline-flex; align-items: center; gap: 14px;
  font-family: var(--f-mono); font-size: clamp(0.85rem, 2.4vw, 1.15rem); font-weight: 500;
  padding: 20px 32px; border-radius: 999px;
  background: rgba(22, 18, 30, 0.4);
  border: 1.5px solid rgba(245, 244, 249, 0.35);
  transition: border-color 0.3s, background 0.3s, box-shadow 0.3s;
  will-change: transform;
}
.contact-mail:hover {
  border-color: var(--magenta);
  background: rgba(233, 60, 172, 0.12);
  box-shadow: 0 12px 50px -12px rgba(233, 60, 172, 0.6);
}
.contact-mail .ic { color: var(--magenta); }
.contact-actions {
  display: flex; gap: 16px; justify-content: center; flex-wrap: wrap;
}
.contact-wa .ic { color: var(--cyan); }
.contact-wa:hover {
  border-color: var(--cyan);
  background: rgba(41, 217, 212, 0.12);
  box-shadow: 0 12px 50px -12px rgba(41, 217, 212, 0.6);
}

/* ============================================================
   SOLUCIONES / PRECIOS
   ============================================================ */
.sol-list { display: flex; flex-direction: column; }
.sol {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  gap: clamp(16px, 3vw, 40px);
  padding: clamp(22px, 3vw, 32px) 0;
  border-top: 1px solid var(--line-light);
  transition: background 0.3s;
}
.sol:last-child { border-bottom: 1px solid var(--line-light); }
.sol:hover { background: rgba(108, 43, 217, 0.04); }
.sol-num {
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em;
  background: linear-gradient(90deg, var(--violet), var(--magenta));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.sol-body h3 {
  font-family: var(--f-display); font-size: clamp(1.15rem, 2.2vw, 1.5rem);
  font-weight: 700; letter-spacing: -0.01em; margin-bottom: 6px;
}
.sol-body > p { color: var(--text-dim-light); font-size: 0.97rem; max-width: 58ch; }

/* qué incluye cada producto */
.sol-incluye {
  display: flex; flex-wrap: wrap; gap: 7px 16px;
  margin-top: 14px; max-width: 58ch;
}
.sol-incluye li {
  font-size: 0.71rem; letter-spacing: 0.03em;
  color: var(--ink); opacity: 0.72;
}
/* marca en todos los elementos: al envolver, ninguna línea empieza suelta */
.sol-incluye li::before {
  content: "+";
  margin-right: 5px;
  color: var(--magenta); opacity: 0.8;
}

/* qué mueve el precio */
.sol-nota {
  margin-top: 12px; max-width: 58ch;
  font-size: 0.87rem; color: var(--text-dim-light);
}
.sol-nota .mono {
  font-size: 0.66rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--violet); margin-right: 7px;
}

.sol-pie {
  margin-top: 32px;
  font-size: 0.9rem; color: var(--text-dim-light);
  max-width: 60ch;
}
.sol-price {
  text-align: right; white-space: nowrap;
  display: flex; flex-direction: column; gap: 2px;
}
.sol-price span { font-size: 0.95rem; font-weight: 700; }
.sol-price em {
  font-style: normal; font-size: 0.78rem; color: var(--text-dim-light);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 26px var(--gutter);
  background: var(--ink); color: var(--text-dim-dark);
  border-top: 1px solid var(--line-dark);
  font-size: 0.85rem;
}
.to-top { font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; }
.to-top:hover { color: var(--cyan); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .brand-name { display: none; }
  .burger { display: flex; position: relative; z-index: 160; }
  .brand { position: relative; z-index: 160; }
  .nav {
    position: fixed; inset: 0; z-index: -1;
    flex-direction: column; justify-content: center; gap: 34px;
    background: var(--ink);
    color: var(--porcelain);
    opacity: 0; pointer-events: none;
    transition: opacity 0.3s;
  }
  .header.nav-open .nav { opacity: 1; pointer-events: auto; z-index: 150; }
  .header.nav-open { color: var(--porcelain); }
  /* con el menú abierto, el header no debe pintar su barra clara encima */
  .header.nav-open.is-scrolled {
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .nav-link { font-size: 1.05rem; }
  .cards { grid-template-columns: 1fr; }
  .hero-hint { display: none; }

  /* los saltos de línea manuales de los títulos no caben aquí */
  .section-title br { display: none; }

  /* 5 fichas de paleta en una sola fila flexible */
  .demo-palette .chip { width: auto; flex: 1 1 0; min-width: 0; height: 58px; }

  /* el fluido brilla más de cerca: velo central más firme en contacto */
  .contact-veil {
    background:
      linear-gradient(rgba(22, 18, 30, 0.32), rgba(22, 18, 30, 0.32)),
      radial-gradient(ellipse 80% 65% at 50% 50%, transparent 20%, rgba(22, 18, 30, 0.72) 100%);
  }

  /* mismo problema en el hero: el bloque de texto ocupa casi toda la
     pantalla, así que el velo tiene que ser mucho más firme que en
     escritorio para que el titular (y sobre todo "plantilla." en
     degradado) se lea sin esfuerzo sobre el fluido */
  .hero-veil {
    background:
      linear-gradient(rgba(22, 18, 30, 0.42), rgba(22, 18, 30, 0.42)),
      radial-gradient(ellipse 140% 95% at 50% 46%, transparent 4%, rgba(22, 18, 30, 0.78) 100%),
      linear-gradient(180deg, rgba(22, 18, 30, 0.55), transparent 20%, transparent 68%, rgba(22, 18, 30, 0.82));
  }
  .accent-line.split .char {
    text-shadow: 0 3px 22px rgba(22, 18, 30, 0.95), 0 1px 5px rgba(22, 18, 30, 0.9);
  }
  .eyebrow {
    text-shadow: 0 1px 14px rgba(22, 18, 30, 0.8);
  }

  /* el precio pasa debajo del texto, alineado con él */
  .sol {
    grid-template-columns: auto 1fr;
    row-gap: 12px;
  }
  .sol-price {
    grid-column: 2; text-align: left;
    flex-direction: row; align-items: baseline; gap: 8px;
  }
}

@media (max-width: 480px) {
  .steps { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .contact-mail { width: 100%; justify-content: center; padding: 18px 14px; }
  .contact-actions { flex-direction: column; }
  .footer { justify-content: center; text-align: center; }
}

/* ============================================================
   MOVIMIENTO REDUCIDO
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker-track { animation: none; }
  .hero-hint { animation: none; display: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .cursor { display: none !important; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
