/* DASSI — landing page. Sistema de diseño mínimo, sin dependencias externas. */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("fonts/bricolage-grotesque.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --bg: #f7f5f2;
  --bg: oklch(97.5% 0.006 95);
  --bg-elevated: #ffffff;
  --bg-elevated: oklch(100% 0 0);
  --ink: #1c2330;
  --ink: oklch(22% 0.02 260);
  --ink-soft: #4c5566;
  --ink-soft: oklch(42% 0.03 260);
  --accent: #177996;
  --accent: oklch(53.7% 0.094 223.7);
  --accent-strong: #005470;
  --accent-strong: oklch(41% 0.094 223.7);
  --cta: #CB4500;
  --cta: oklch(57.3% 0.181 39.8);
  --cta-strong: #A71F00;
  --cta-strong: oklch(47% 0.181 39.8);
  --line: #dcdfe3;
  --line: oklch(88% 0.01 260);

  --font-sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  --font-display: "Bricolage Grotesque", var(--font-sans);

  --wrap: 72rem;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 5rem; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
}
h1, h2, h3, p, dl, dd, ol, ul { margin: 0; }
h1, h2, h3 { font-family: var(--font-display); text-wrap: balance; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; }
img, svg { display: block; max-width: 100%; }

.wrap {
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 1rem + 2vw, 2.5rem);
}

/* Etiqueta utilitaria: versalitas de la display en vez de la mono del sistema */
.hero-note, .service-tag, .why-kicker, .process-num, .contact-list {
  font-family: var(--font-display);
  font-variant-numeric: tabular-nums;
}

/* Accesibilidad transversal */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  background: var(--ink);
  color: var(--bg);
  padding: 0.6rem 1rem;
  border-radius: 0.25rem;
  transition: top 150ms ease-out;
  z-index: 100;
}
.skip-link:focus { top: 1rem; }

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

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  background: color-mix(in oklch, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px) saturate(1.2);
  border-bottom: 1px solid transparent;
  z-index: 10;
  transition: border-color 200ms, box-shadow 200ms;
}
.site-header.scrolled { border-bottom-color: var(--line); box-shadow: 0 6px 20px -16px color-mix(in oklch, var(--ink) 40%, transparent); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 0.9rem;
  flex-wrap: wrap;
}
.wordmark { display: flex; align-items: center; }
.logo { display: block; height: 2rem; width: auto; }
.site-nav {
  display: flex;
  gap: clamp(1rem, 0.6rem + 1vw, 2rem);
  font-size: 0.95rem;
}
.site-nav a { text-decoration: none; color: var(--ink-soft); position: relative; padding-block: 0.25rem; }
.site-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--cta);
  transform: scaleX(0); transform-origin: left; transition: transform 250ms var(--ease-out);
}
.site-nav a:hover { color: var(--ink); }
.site-nav a:hover::after, .site-nav a.current::after { transform: scaleX(1); }
.site-nav a.current { color: var(--ink); }
.only-narrow { display: none; }
/* Móvil: una sola fila (logo + CTA). La página es corta y lineal; la nav sobra ahí. */
@media (max-width: 40rem) {
  .site-nav { display: none; }
  .header-inner { flex-wrap: nowrap; padding-block: 0.7rem; }
  .only-wide { display: none; }
  .only-narrow { display: inline; }
}

/* Botones */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.4rem;
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  min-height: 44px;
  transition: transform 180ms ease-out, background-color 180ms ease-out, border-color 180ms, box-shadow 180ms;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-cta { background: var(--cta); color: var(--bg-elevated); box-shadow: 0 6px 16px -8px var(--cta); }
.btn-cta:hover { background: var(--cta-strong); box-shadow: 0 10px 22px -10px var(--cta); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--ink-soft); }
.btn-small { padding: 0.55rem 1rem; font-size: 0.85rem; min-height: 40px; }
.btn-large { padding: 1rem 1.8rem; font-size: 1.05rem; }
/* Móvil: cuando los botones se apilan, ambos toman el ancho completo (mismo ancho, más fáciles de tocar). */
@media (max-width: 40rem) {
  .hero-actions, .contact-actions { flex-direction: column; }
  .hero-actions .btn, .contact-actions .btn { width: 100%; }
}

/* ---------- Hero ---------- */
.hero { padding-block: clamp(2.5rem, 1.5rem + 4vw, 5.5rem) clamp(3rem, 2rem + 4vw, 6rem); overflow: clip; }
.hero-inner { display: grid; gap: 2.5rem; align-items: center; }
.hero-content { display: grid; gap: 1.6rem; max-width: 40rem; }
@media (min-width: 56rem) {
  .hero-inner { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); column-gap: 3rem; }
}
.hero h1 {
  font-size: clamp(2.2rem, 1.2rem + 3.6vw, 3.6rem);
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.025em;
}
/* Subrayado que se dibuja bajo "funcione mejor." */
.mark {
  background-image: linear-gradient(var(--cta), var(--cta));
  background-repeat: no-repeat;
  background-position: 0 92%;
  background-size: 100% 0.12em;
  padding-bottom: 0.04em;
}
.hero-sub {
  font-size: clamp(1.05rem, 0.95rem + 0.4vw, 1.2rem);
  color: var(--ink-soft);
  max-width: 40rem;
}
.hero-actions { display: flex; gap: 0.9rem; flex-wrap: wrap; }
.hero-note { font-size: 0.9rem; color: var(--ink-soft); }

.hero-art { width: 100%; height: auto; overflow: visible; max-width: 38rem; justify-self: center; }
/* Paralaje con `translate` (propiedad individual): se suma a las animaciones de `transform` sin pisarlas. */
.hero-art .layer { transition: translate 600ms var(--ease-out); }
.hero-art .layer-back  { translate: calc(var(--px, 0) * -6px) calc(var(--py, 0) * -6px); }
.hero-art .layer-mid   { translate: calc(var(--px, 0) * 6px)  calc(var(--py, 0) * 6px); }
.hero-art .layer-front { translate: calc(var(--px, 0) * 14px) calc(var(--py, 0) * 14px); }
.hero-art .pulse { opacity: 0; }

@media (prefers-reduced-motion: no-preference) {
  .hero-content > * { animation: rise 700ms var(--ease-out) both; }
  .hero-content > :nth-child(2) { animation-delay: 80ms; }
  .hero-content > :nth-child(3) { animation-delay: 160ms; }
  .hero-content > :nth-child(4) { animation-delay: 240ms; }
  .mark { animation: underline 900ms var(--ease-out) 500ms both; }

  /* Secuencia: las fuentes llegan torcidas y se ordenan, las líneas se dibujan, el panel aparece. */
  .hero-art .src { transform-box: fill-box; transform-origin: center; animation: settle 1100ms var(--ease-out) both; }
  .hero-art .s1 { --r: -7deg; animation-delay: 150ms; }
  .hero-art .s2 { --r: 5deg;  animation-delay: 250ms; }
  .hero-art .s3 { --r: -4deg; animation-delay: 350ms; }
  .hero-art .s4 { --r: 8deg;  animation-delay: 450ms; }
  .hero-art .link { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 900ms var(--ease-out) forwards; }
  .hero-art .l1 { animation-delay: 700ms; } .hero-art .l2 { animation-delay: 780ms; }
  .hero-art .l3 { animation-delay: 860ms; } .hero-art .l4 { animation-delay: 940ms; }
  .hero-art .l5 { animation-delay: 1250ms; }
  .hero-art .node { transform-box: fill-box; transform-origin: center; animation: pop 600ms var(--ease-out) 1050ms both; }
  .hero-art .node-ring { transform-box: fill-box; transform-origin: center; animation: ring 2.4s ease-out 1.8s infinite; }
  .hero-art .panel { animation: rise 800ms var(--ease-out) 1300ms both; }
  .hero-art .chart-line { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 1400ms var(--ease-out) 1700ms forwards; }
  .hero-art .chart-area { animation: fade 800ms ease-out 2400ms both; }
  .hero-art .chart-dot { transform-box: fill-box; transform-origin: center; animation: pop 500ms var(--ease-out) 2900ms both; }
  .hero-art .alert { animation: rise 600ms var(--ease-out) 3300ms both; }
  .hero-art .orbit { transform-box: fill-box; transform-origin: center; animation: spin 60s linear infinite; }

  /* Datos que viajan de cada fuente al nodo y del nodo al panel, en bucle. */
  .hero-art .pulse { offset-rotate: 0deg; animation: travel 2.6s cubic-bezier(0.5, 0, 0.3, 1) infinite; }
  .hero-art .p1 { offset-path: path("M146 62 C 220 62, 220 212, 274 216"); animation-delay: 2.0s; }
  .hero-art .p2 { offset-path: path("M146 162 C 210 162, 230 214, 274 218"); animation-delay: 2.7s; }
  .hero-art .p3 { offset-path: path("M146 272 C 210 272, 230 224, 274 222"); animation-delay: 3.4s; }
  .hero-art .p4 { offset-path: path("M146 372 C 220 372, 220 228, 274 224"); animation-delay: 4.1s; }
  .hero-art .p5 { offset-path: path("M326 220 L 372 220"); animation-duration: 1.3s; animation-delay: 2.4s; }
}

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } }
@keyframes underline { from { background-size: 0% 0.12em; } }
@keyframes settle { from { opacity: 0; transform: translateX(-24px) rotate(var(--r)); } 60% { opacity: 1; transform: rotate(var(--r)); } to { opacity: 1; transform: none; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes pop { from { opacity: 0; transform: scale(0.4); } }
@keyframes ring { from { opacity: 0.8; transform: scale(1); } to { opacity: 0; transform: scale(2.2); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes travel { 0% { offset-distance: 0%; opacity: 0; } 12% { opacity: 1; } 88% { opacity: 1; } 100% { offset-distance: 100%; opacity: 0; } }

/* ---------- Secciones generales ---------- */
section { padding-block: clamp(3.5rem, 2rem + 4vw, 6.5rem); }
section h2 {
  font-size: clamp(1.8rem, 1.3rem + 1.8vw, 2.8rem);
  line-height: 1.08;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.section-lede {
  margin-top: 0.8rem;
  color: var(--ink-soft);
  font-size: 1.08rem;
  max-width: 38rem;
}

/* Aparición al scroll: la clase .reveal la agrega main.js, así sin JS todo queda visible. */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(18px); }
  .reveal.in { opacity: 1; transform: none; transition: opacity 700ms var(--ease-out) var(--d, 0ms), transform 700ms var(--ease-out) var(--d, 0ms); }
}

/* ---------- Por qué DASSI: editorial, sin tarjetas ---------- */
.why-grid {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr));
  gap: 2.5rem 3rem;
}
.why-grid article { border-top: 2px solid var(--ink); padding-top: 1.25rem; display: grid; gap: 0.6rem; align-content: start; }
.why-kicker {
  font-size: clamp(2.2rem, 1.6rem + 2vw, 3.2rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--accent);
}
.why-grid h3 { font-size: 1.2rem; font-weight: 700; }
.why-grid p:not(.why-kicker) { color: var(--ink-soft); }

/* ---------- Servicios ---------- */
/* Fondos alternados: hero crema → sistemas blanco → problemas crema → servicios blanco →
   continuidad teal → comparación crema → cómo trabajamos blanco → preguntas crema → contacto oscuro */
.band-white { background: var(--bg-elevated); border-block: 1px solid var(--line); }
.services-grid {
  margin-top: 2.75rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
  gap: 1.25rem;
}
.service-card {
  --mx: 50%; --my: 0%;
  display: flex; flex-direction: column;
  text-decoration: none; color: inherit;
  position: relative;
  padding: 1.75rem;
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  background:
    radial-gradient(22rem circle at var(--mx) var(--my), color-mix(in oklch, var(--accent) 9%, transparent), transparent 70%),
    var(--bg-elevated);
  transition: transform 250ms var(--ease-out), box-shadow 250ms var(--ease-out), border-color 250ms;
}
.service-card:hover { transform: translateY(-4px); border-color: color-mix(in oklch, var(--accent) 35%, var(--line)); box-shadow: 0 18px 36px -22px color-mix(in oklch, var(--ink) 35%, transparent); }
.service-card h3 { font-size: clamp(1.15rem, 1rem + 0.5vw, 1.35rem); font-weight: 700; margin-bottom: 0.5rem; line-height: 1.2; }
.service-card p { color: var(--ink-soft); }
.service-tag {
  display: inline-block;
  margin-top: 1rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent-strong);
  background: color-mix(in oklch, var(--accent) 10%, transparent);
  padding: 0.3rem 0.7rem;
  border-radius: 0.4rem;
}

/* Micro-ilustraciones: color desde tokens (los atributos SVG no leen variables CSS). */
.service-art { width: 7.5rem; height: 3.5rem; margin-bottom: 1.1rem; overflow: visible; }
.f-accent { fill: var(--accent); }
.f-cta { fill: var(--cta); }
.s-ink { fill: none; stroke: var(--ink); stroke-width: 1.6; }
.s-line { stroke: var(--line); stroke-width: 1.5; }
.s-accent { fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-linecap: round; }
.s-cta { fill: none; stroke: var(--cta); stroke-width: 1.5; }
.art-auto .check { fill: none; stroke: var(--bg-elevated); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.art-auto .flow { stroke-dasharray: 3 4; }

@media (prefers-reduced-motion: no-preference) {
  /* Cada una se activa al pasar el cursor / foco, o una vez al entrar en pantalla (móvil). */
  .art-modulo .piece { transform: translateX(22px); transition: transform 600ms var(--ease-out); }
  .service-card:is(:hover, :focus-within, .play) .art-modulo .piece { transform: none; }

  .art-nube .ticks rect { transform-box: fill-box; transform-origin: bottom; }
  .service-card:is(:hover, :focus-within, .play) .art-nube .ticks rect { animation: tick 900ms var(--ease-out) both; }
  .art-nube .ticks rect:nth-child(2) { animation-delay: 50ms; } .art-nube .ticks rect:nth-child(3) { animation-delay: 100ms; }
  .art-nube .ticks rect:nth-child(4) { animation-delay: 150ms; } .art-nube .ticks rect:nth-child(5) { animation-delay: 200ms; }
  .art-nube .ticks rect:nth-child(6) { animation-delay: 250ms; } .art-nube .ticks rect:nth-child(7) { animation-delay: 300ms; }
  .art-nube .ticks rect:nth-child(8) { animation-delay: 350ms; } .art-nube .ticks rect:nth-child(9) { animation-delay: 400ms; }
  .art-nube .live-ring { transform-box: fill-box; transform-origin: center; animation: ring 2s ease-out infinite; }

  /* En reposo el gráfico está completo; al activarse vuelve a crecer desde abajo. */
  .art-datos .bars rect { transform-box: fill-box; transform-origin: bottom; }
  .service-card:is(:hover, :focus-within, .play) .art-datos .bars rect { animation: grow 700ms var(--ease-out) both; }
  .art-datos .bars rect:nth-child(2) { animation-delay: 60ms; } .art-datos .bars rect:nth-child(3) { animation-delay: 120ms; }
  .art-datos .bars rect:nth-child(4) { animation-delay: 180ms; } .art-datos .bars rect:nth-child(5) { animation-delay: 240ms; }

  .art-auto .gear { transform-box: fill-box; transform-origin: center; transition: transform 1200ms var(--ease-out); }
  .service-card:is(:hover, :focus-within, .play) .art-auto .gear { transform: rotate(180deg); }
  .art-auto .check { stroke-dasharray: 1; }
  .service-card:is(:hover, :focus-within, .play) .art-auto .check { animation: redraw 700ms var(--ease-out) 400ms both; }
  .service-card:is(:hover, :focus-within, .play) .art-auto .flow { animation: dash 700ms linear infinite; }
}
@keyframes tick { 0% { transform: scaleY(0.2); opacity: 0.3; } 60% { transform: scaleY(1.15); } 100% { transform: none; opacity: 1; } }
@keyframes dash { to { stroke-dashoffset: -7; } }
@keyframes grow { from { transform: scaleY(0.2); } }
@keyframes redraw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }

/* ---------- Cómo trabajamos: línea de tiempo ---------- */
.process-list {
  --fill: 1;
  position: relative;
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
  gap: 2rem 2.5rem;
}
.process-list li { position: relative; padding-top: 4.25rem; }
.process-num {
  position: absolute; top: 0; left: 0;
  width: 3rem; height: 3rem; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--bg-elevated); border: 2px solid var(--accent);
  color: var(--accent-strong); font-size: 1rem; font-weight: 700;
  z-index: 1;
}
.process-list h3 { margin-bottom: 0.5rem; font-size: 1.25rem; font-weight: 700; }
.process-list p { color: var(--ink-soft); }
/* Línea base y línea de progreso que se llena al hacer scroll (solo si hay 3 columnas). */
@media (min-width: 52rem) {
  .process-list::before, .process-list::after {
    content: ""; position: absolute; left: 1.5rem; right: 1.5rem; top: 1.5rem; height: 2px; background: var(--line);
  }
  .process-list::after { background: var(--accent); transform-origin: left; transform: scaleX(var(--fill)); }
  @supports (animation-timeline: view()) {
    @media (prefers-reduced-motion: no-preference) {
      .process-list::after { animation: fill-line linear both; animation-timeline: view(); animation-range: entry 30% cover 55%; }
    }
  }
}
@keyframes fill-line { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ---------- Contacto ---------- */
.contact { position: relative; background: var(--ink); color: var(--bg); overflow: hidden; isolation: isolate; }
.contact-net { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: 0.55; }
.contact h2 { color: var(--bg-elevated); font-size: clamp(2rem, 1.3rem + 2.6vw, 3.4rem); max-width: 22ch; }
.contact p { color: color-mix(in oklch, var(--bg) 80%, transparent); margin-top: 1rem; max-width: 36rem; font-size: 1.08rem; }
.contact-actions { margin-top: 2.25rem; display: flex; flex-wrap: wrap; gap: 0.9rem; }
.btn-on-dark { color: var(--bg); border-color: color-mix(in oklch, var(--bg) 35%, transparent); }
.btn-on-dark:hover { border-color: var(--bg); }
.contact-list {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2.5rem;
  font-size: 1rem;
  color: color-mix(in oklch, var(--bg) 75%, transparent);
}
.contact-list a { color: var(--bg); text-decoration: underline; text-decoration-color: color-mix(in oklch, var(--bg) 35%, transparent); text-underline-offset: 4px; }
.contact-list a:hover { text-decoration-color: var(--cta); }

/* Footer: cierre claro tras el bloque oscuro, con marca, secciones y contacto */
.site-footer { background: var(--bg); font-size: 0.95rem; }
.footer-inner {
  padding-block: clamp(2.5rem, 2rem + 2vw, 3.5rem) 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem 1.5rem;
}
.footer-brand { grid-column: 1 / -1; display: grid; gap: 0.75rem; max-width: 22rem; }
.footer-brand .logo { height: 2.25rem; }
.footer-brand p { color: var(--ink-soft); text-wrap: balance; }
.footer-title {
  font-family: var(--font-display);
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink); margin-bottom: 0.75rem;
}
.footer-col ul { display: grid; gap: 0.5rem; color: var(--ink-soft); }
.footer-col a { color: var(--ink-soft); text-decoration: none; }
.footer-col a:hover { color: var(--cta); }
@media (min-width: 48rem) {
  .footer-inner { grid-template-columns: 2fr 1fr 1fr; }
  .footer-brand { grid-column: auto; }
}
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap;
  padding-block: 1.25rem calc(1.25rem + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--line);
  font-size: 0.85rem; color: var(--ink-soft);
}
.to-top { text-decoration: none; color: var(--ink-soft); min-height: 44px; display: inline-flex; align-items: center; gap: 0.35rem; }
.to-top:hover { color: var(--ink); }
.to-top span { transition: transform 200ms var(--ease-out); }
.to-top:hover span { transform: translateY(-3px); }

/* =====================================================================
   Versión 2: portada con más secciones y páginas por servicio
   ===================================================================== */

.eyebrow {
  font-family: var(--font-display);
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--accent-strong);
}
.section-head { display: grid; gap: 0.8rem; max-width: 44rem; }
.section-head .section-lede { margin-top: 0; }

/* ---------- Hero: comparación Hoy / Con DASSI ---------- */
.compare {
  --pos: 50%;
  position: relative;
  width: 100%; max-width: 38rem; justify-self: center;
  aspect-ratio: 548 / 380;
  border-radius: 1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  box-shadow: 0 30px 60px -40px color-mix(in oklch, var(--ink) 45%, transparent);
  overflow: hidden;
  user-select: none;
}
.compare-layer { position: absolute; inset: 0; width: 100%; height: 100%; }
.compare-before { background: repeating-linear-gradient(0deg, transparent 0 27px, color-mix(in oklch, var(--line) 55%, transparent) 27px 28px), var(--bg); }
.compare-after { background: var(--bg-elevated); clip-path: inset(0 0 0 var(--pos)); }
.compare .hero-art { max-width: none; width: 100%; height: 100%; }
.compare-tag {
  position: absolute; top: 0.8rem; z-index: 2;
  font-family: var(--font-display); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.3rem 0.65rem; border-radius: 999px;
  pointer-events: none;
}
.compare-tag.is-before { left: 0.8rem; background: var(--ink); color: var(--bg); }
.compare-tag.is-after { right: 0.8rem; background: var(--accent-strong); color: var(--bg-elevated); }
.compare-handle {
  position: absolute; top: 0; bottom: 0; left: var(--pos); z-index: 3;
  width: 44px; margin-left: -22px;
  display: grid; place-items: center;
  cursor: ew-resize; touch-action: none;
  outline: none;
}
.compare-handle::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; margin-left: -1px; background: var(--bg-elevated); box-shadow: 0 0 0 1px color-mix(in oklch, var(--ink) 18%, transparent); }
.compare-knob {
  position: relative; width: 44px; height: 44px; border-radius: 50%;
  background: var(--cta); color: var(--bg-elevated);
  display: grid; place-items: center;
  box-shadow: 0 8px 18px -8px var(--cta);
  transition: transform 200ms var(--ease-out);
}
.compare-knob svg { width: 22px; height: 22px; }
.compare-handle:hover .compare-knob, .compare-handle:focus-visible .compare-knob, .compare.dragging .compare-knob { transform: scale(1.1); }
.compare-handle:focus-visible .compare-knob { outline: 2px solid var(--ink); outline-offset: 3px; }
.compare-hint { margin-top: 0.6rem; text-align: center; font-size: 0.85rem; color: var(--ink-soft); }
.hero-visual { display: grid; justify-items: center; }

/* Desorden del lado "Hoy": se mueve apenas, como papeles sobre un escritorio */
@media (prefers-reduced-motion: no-preference) {
  .mess > g { transform-box: fill-box; transform-origin: center; animation: jitter 6s ease-in-out infinite; }
  .mess > g:nth-child(2n) { animation-duration: 7.5s; animation-delay: -2s; }
  .mess > g:nth-child(3n) { animation-duration: 5.2s; animation-delay: -3.5s; }
  .mess .blink { animation: blink 1.6s steps(2, jump-none) infinite; }
}
@keyframes jitter { 0%, 100% { translate: 0 0; } 50% { translate: 0 -3px; } }
@keyframes blink { 50% { opacity: 0.25; } }

/* ---------- Banda de sistemas que ya usa una pyme ---------- */
.systems { padding-block: 2.25rem; }
.systems .wrap { display: grid; gap: 1.1rem; }
.systems p { color: var(--ink-soft); text-align: center; text-wrap: balance; }
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track { display: flex; gap: 0.75rem; width: max-content; }
.marquee ul { display: flex; gap: 0.75rem; }
.marquee li {
  white-space: nowrap;
  font-family: var(--font-display); font-weight: 600;
  padding: 0.5rem 1rem; border-radius: 999px;
  border: 1px solid var(--line); background: var(--bg);
}
@media (prefers-reduced-motion: no-preference) {
  .marquee-track { animation: marquee 45s linear infinite; }
  .marquee:hover .marquee-track { animation-play-state: paused; }
}
@media (prefers-reduced-motion: reduce) {
  .marquee { -webkit-mask-image: none; mask-image: none; }
  .marquee-track { width: auto; }
  .marquee ul { flex-wrap: wrap; justify-content: center; }
  .marquee ul[aria-hidden] { display: none; }
}
@keyframes marquee { to { transform: translateX(calc(-50% - 0.375rem)); } }

/* ---------- ¿Qué te está pasando? (pestañas) ---------- */
.pains-layout { margin-top: 2.5rem; display: grid; gap: 1.5rem; }
@media (min-width: 56rem) { .pains-layout { grid-template-columns: minmax(0, 20rem) minmax(0, 1fr); gap: 2.5rem; align-items: start; } }
.pain-tabs { display: grid; gap: 0.5rem; }
.pain-tab {
  text-align: left; font: inherit; font-weight: 600;
  padding: 0.9rem 1.1rem; border-radius: 0.6rem;
  border: 1px solid var(--line); background: var(--bg-elevated); color: var(--ink);
  cursor: pointer; transition: border-color 200ms, background 200ms, color 200ms;
}
.pain-tab:hover { border-color: var(--ink-soft); }
.pain-tab[aria-selected="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.pain-panel {
  display: grid; gap: 1rem;
  padding: clamp(1.5rem, 1rem + 2vw, 2.5rem);
  border-radius: 1rem; background: var(--bg-elevated); border: 1px solid var(--line);
}
.pain-panel h3 { font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.7rem); line-height: 1.15; }
.pain-panel p { color: var(--ink-soft); max-width: 40rem; }
.pain-steps { display: grid; gap: 0.6rem; }
.pain-steps li { display: grid; grid-template-columns: 1.6rem 1fr; gap: 0.6rem; color: var(--ink); }
.pain-steps li::before { content: "→"; color: var(--cta); font-weight: 700; }
.link-arrow { font-weight: 600; color: var(--accent-strong); text-decoration: none; justify-self: start; border-bottom: 2px solid color-mix(in oklch, var(--accent) 35%, transparent); }
.link-arrow:hover { border-bottom-color: var(--cta); }
/* Sin JS se ven todos los paneles y no hay pestañas. */
.pain-tabs { display: none; }
.tabs-ready .pain-tabs { display: grid; }
.pain-panels { display: grid; gap: 1rem; }
.tabs-ready .pain-panel[hidden] { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .tabs-ready .pain-panel:not([hidden]) { animation: rise 450ms var(--ease-out); }
}

/* ---------- Servicios: grilla 2 + 3 que enlaza a cada página ---------- */
.services-grid.five { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.services-grid.five > * { grid-column: span 2; }
.services-grid.five > :nth-child(-n+2) { grid-column: span 3; }
@media (max-width: 60rem) {
  .services-grid.five { grid-template-columns: 1fr 1fr; }
  .services-grid.five > *, .services-grid.five > :nth-child(-n+2) { grid-column: auto; }
  .services-grid.five > :last-child { grid-column: 1 / -1; }
}
@media (max-width: 40rem) {
  .services-grid.five { grid-template-columns: 1fr; }
}
.service-card .service-tag { margin-top: auto; }
.service-card p { margin-bottom: 1rem; }
.card-more { margin-top: 1rem; font-weight: 600; color: var(--accent-strong); }
.service-card:hover .card-more span { translate: 4px 0; }
.card-more span { display: inline-block; transition: translate 200ms var(--ease-out); }
.art-mant .pulse-line { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; }
@media (prefers-reduced-motion: no-preference) {
  .service-card:is(:hover, :focus-within, .play) .art-mant .pulse-line { animation: redraw 1s var(--ease-out) both; }
  .art-mant .beat { transform-box: fill-box; transform-origin: center; animation: ring 2s ease-out infinite; }
}

/* ---------- Después de entregar (continuidad) ---------- */
.continuity { background: var(--accent-strong); color: var(--bg-elevated); position: relative; overflow: hidden; isolation: isolate; }
.continuity::before {
  content: ""; position: absolute; inset: -20% -10% auto auto; width: 38rem; aspect-ratio: 1; z-index: -1;
  background: radial-gradient(circle, color-mix(in oklch, var(--accent) 60%, transparent), transparent 65%);
}
.continuity .eyebrow { color: color-mix(in oklch, var(--bg) 75%, transparent); }
.continuity h2 { color: var(--bg-elevated); max-width: 20ch; }
.continuity .section-lede { color: color-mix(in oklch, var(--bg) 82%, transparent); }
.continuity-grid { margin-top: 2.75rem; display: grid; gap: 1px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); background: color-mix(in oklch, var(--bg) 22%, transparent); border: 1px solid color-mix(in oklch, var(--bg) 22%, transparent); border-radius: 1rem; overflow: hidden; }
.continuity-grid article { background: var(--accent-strong); padding: 1.6rem; display: grid; gap: 0.5rem; align-content: start; }
.continuity-grid svg { width: 2rem; height: 2rem; color: var(--bg-elevated); margin-bottom: 0.4rem; }
.continuity-grid h3 { font-size: 1.15rem; }
.continuity-grid p { color: color-mix(in oklch, var(--bg) 80%, transparent); font-size: 0.97rem; }
.continuity-stat { margin-top: 2.5rem; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.5rem 1.25rem; }
.continuity-stat strong { font-family: var(--font-display); font-size: clamp(3rem, 2rem + 4vw, 5rem); line-height: 1; letter-spacing: -0.04em; }
.continuity-stat span { max-width: 34rem; color: color-mix(in oklch, var(--bg) 85%, transparent); }

/* ---------- Dónde encaja DASSI (comparación) ---------- */
.versus-wrap { margin-top: 2.5rem; overflow-x: auto; border: 1px solid var(--line); border-radius: 1rem; background: var(--bg-elevated); }
.versus { width: 100%; min-width: 46rem; border-collapse: collapse; font-size: 0.95rem; }
.versus th, .versus td { padding: 0.9rem 1rem; text-align: center; border-bottom: 1px solid var(--line); }
.versus thead th { font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; vertical-align: bottom; }
.versus tbody th { text-align: left; font-weight: 500; color: var(--ink); position: sticky; left: 0; background: var(--bg-elevated); }
.versus tr:last-child > * { border-bottom: 0; }
.versus .is-dassi { background: color-mix(in oklch, var(--accent) 9%, var(--bg-elevated)); }
.versus thead .is-dassi { color: var(--accent-strong); }
.mark-yes, .mark-mid, .mark-no { display: inline-grid; place-items: center; width: 1.5rem; height: 1.5rem; border-radius: 50%; font-size: 0.8rem; font-weight: 700; }
.mark-yes { background: var(--accent); color: var(--bg-elevated); }
.mark-mid { background: color-mix(in oklch, var(--accent) 22%, transparent); color: var(--accent-strong); }
.mark-no { border: 1.5px solid var(--line); color: var(--ink-soft); }
.versus-legend { margin-top: 1rem; display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; font-size: 0.88rem; color: var(--ink-soft); align-items: center; }
.versus-legend span { display: inline-flex; gap: 0.4rem; align-items: center; }
.honest {
  margin-top: 2rem; padding: 1.25rem 1.5rem; border-radius: 0.8rem;
  border: 1px dashed color-mix(in oklch, var(--cta) 55%, var(--line)); background: color-mix(in oklch, var(--cta) 5%, var(--bg-elevated));
  display: grid; gap: 0.3rem; max-width: 46rem;
}
.honest strong { font-family: var(--font-display); font-size: 1.1rem; }
.honest p { color: var(--ink-soft); }

/* ---------- Preguntas frecuentes ---------- */
.faq-list { margin-top: 2.5rem; display: grid; gap: 0.75rem; max-width: 48rem; }
.faq-list details { border: 1px solid var(--line); border-radius: 0.8rem; background: var(--bg-elevated); }
.faq-list summary {
  cursor: pointer; list-style: none; padding: 1.1rem 1.25rem;
  font-family: var(--font-display); font-weight: 600; font-size: 1.08rem;
  display: flex; justify-content: space-between; gap: 1rem; align-items: center;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; font-size: 1.5rem; line-height: 1; color: var(--accent); transition: rotate 250ms var(--ease-out); flex: none; }
.faq-list details[open] summary::after { rotate: 45deg; }
.faq-list details > div { padding: 0 1.25rem 1.25rem; color: var(--ink-soft); display: grid; gap: 0.6rem; }

/* ---------- Páginas de servicio ---------- */
.crumbs { font-size: 0.9rem; color: var(--ink-soft); display: flex; flex-wrap: wrap; gap: 0.4rem; }
.crumbs a { color: var(--ink-soft); }
.crumbs a:hover { color: var(--ink); }
.page-hero { padding-block: clamp(2.5rem, 1.5rem + 3vw, 4.5rem) clamp(2.5rem, 2rem + 3vw, 4.5rem); }
.page-hero .wrap { display: grid; gap: 1.25rem; }
.page-hero-grid { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 56rem) { .page-hero-grid { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 3rem; } }
.page-hero h1 { font-size: clamp(2.1rem, 1.3rem + 3.2vw, 3.3rem); line-height: 1.04; letter-spacing: -0.025em; }
.page-hero .hero-sub { max-width: 38rem; }
.page-hero-art { width: 100%; max-width: 22rem; justify-self: center; padding: 2rem; border-radius: 1.25rem; background: var(--bg-elevated); border: 1px solid var(--line); }
.page-hero-art svg { width: 100%; height: auto; overflow: visible; }
.two-col { margin-top: 2.5rem; display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); }
.box { padding: 1.75rem; border-radius: 1rem; border: 1px solid var(--line); background: var(--bg-elevated); display: grid; gap: 1rem; align-content: start; }
.band-white .box { background: var(--bg); }
.box h3 { font-size: 1.2rem; }
.check-list, .x-list { display: grid; gap: 0.7rem; }
.check-list li, .x-list li { display: grid; grid-template-columns: 1.4rem 1fr; gap: 0.6rem; color: var(--ink-soft); }
.check-list li::before { content: "✓"; color: var(--accent); font-weight: 700; }
.x-list li::before { content: "•"; color: var(--cta); font-weight: 700; font-size: 1.2rem; line-height: 1.2; }
.example {
  margin-top: 2rem; padding: 1.5rem 1.75rem; border-left: 4px solid var(--cta);
  background: var(--bg-elevated); border-radius: 0 0.8rem 0.8rem 0; max-width: 48rem; display: grid; gap: 0.4rem;
}
.band-white .example { background: var(--bg); }
.example strong { font-family: var(--font-display); }
.example p { color: var(--ink-soft); }
.cta-band { display: grid; gap: 1.25rem; justify-items: start; }
.other-services { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: 0.6rem; }
.other-services a { text-decoration: none; padding: 0.55rem 1rem; border-radius: 999px; border: 1px solid var(--line); background: var(--bg-elevated); font-weight: 500; }
.other-services a:hover { border-color: var(--accent); color: var(--accent-strong); }

/* Footer con columna de servicios */
@media (min-width: 48rem) { .footer-inner.has-services { grid-template-columns: 1.6fr 1fr 1fr 1fr; } }
.page-hero-art .service-art { width: 100%; height: auto; margin: 0; }
.page-hero-art:hover { transform: none; }
@media (max-width: 40rem) { .page-hero-art { max-width: 15rem; padding: 1.25rem; } }
