@layer reset, tokens, base, layout, components, utilities;

@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url("../fonts/archivo-latin-var.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@layer reset {
  *, *::before, *::after { box-sizing: border-box; }
  * { margin: 0; }
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
  img, svg, picture { display: block; max-width: 100%; }
  input, button, textarea, select { font: inherit; color: inherit; }
  button { cursor: pointer; background: none; border: 0; padding: 0; }
  ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }
  a { color: inherit; }
}

@layer tokens {
  :root {
    --steel: #eef0f2;
    --steel-2: #e1e5e9;
    --steel-3: #c6cdd5;
    --module: #ffffff;
    --ink: #161e35;
    --ink-2: #39425e;
    --ink-3: #59627d;
    --blue: #0070b3;
    --blue-ink: #005a91;
    --mint: #2ce6b0;
    --lilac: #c75ef5;
    --sun: #ffd21f;
    --heat: #ff5a1f;

    --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
    --fs-label: 0.75rem;
    --fs-small: 0.875rem;
    --fs-body: 1.0625rem;
    --fs-lead: clamp(1.125rem, 0.4vw + 1rem, 1.3125rem);
    --fs-h3: clamp(1.375rem, 0.9vw + 1.05rem, 1.75rem);
    --fs-h2: clamp(2.125rem, 3.1vw + 1rem, 3.5rem);
    --fs-h1: clamp(2.5rem, 4.2vw + 0.75rem, 4.5rem);

    --space-1: 0.25rem; --space-2: 0.5rem; --space-3: 0.75rem; --space-4: 1rem;
    --space-5: 1.5rem; --space-6: 2rem; --space-7: 3rem; --space-8: 4rem;
    --space-9: 6rem; --space-10: 8rem;
    --section: clamp(4.5rem, 8vw, 8rem);

    --gutter: clamp(1.25rem, 4.5vw, 4rem);
    --max: 82rem;
    --radius-module: 12px;
    --radius-control: 6px;
    --header-h: 4.5rem;

    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
    --dur-fast: 160ms;
    --dur: 240ms;

    --focus: 0 0 0 3px var(--steel), 0 0 0 5px var(--blue);
  }
}

@layer base {
  html { scroll-padding-top: calc(var(--header-h) + var(--space-4)); }
  @media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
  body {
    background: var(--steel);
    color: var(--ink);
    font-family: var(--font);
    font-size: var(--fs-body);
    line-height: 1.6;
    font-variant-numeric: lining-nums;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
  }
  ::selection { background: var(--sun); color: var(--ink); }
  h1, h2, h3 { line-height: 1.02; letter-spacing: -0.03em; font-weight: 800; text-wrap: balance; }
  h1 { font-size: var(--fs-h1); line-height: 0.96; }
  h2 { font-size: var(--fs-h2); }
  h3 { font-size: var(--fs-h3); letter-spacing: -0.02em; line-height: 1.12; }
  p { text-wrap: pretty; }
  a { text-underline-offset: 0.2em; text-decoration-thickness: 1.5px; }
  :focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--radius-control); }
  [hidden] { display: none !important; }
}

@layer layout {
  .wrap { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
  .section { padding-block: var(--section); }
  .section--tight { padding-block: calc(var(--section) * 0.6); }
  .skip-link {
    position: absolute; left: var(--space-4); top: -100px; z-index: 100;
    background: var(--ink); color: #fff; padding: var(--space-3) var(--space-4);
    border-radius: var(--radius-control); font-weight: 600; text-decoration: none;
  }
  .skip-link:focus { top: var(--space-4); }
}

@layer components {
  /* Label: port codes and strip text */
  .code {
    font-size: var(--fs-label); font-weight: 700; font-stretch: 112%;
    letter-spacing: 0.1em; text-transform: uppercase; font-variant-numeric: tabular-nums;
    color: var(--ink-3);
  }

  /* Buttons */
  .btn {
    display: inline-flex; align-items: center; gap: var(--space-3);
    min-height: 3rem; padding: 0.8rem 1.35rem;
    border-radius: var(--radius-control);
    font-weight: 650; font-size: 1rem; line-height: 1.2; text-decoration: none;
    transition: background-color var(--dur-fast) ease, color var(--dur-fast) ease, transform var(--dur-fast) var(--ease-out);
  }
  .btn:active { transform: scale(0.97); }
  .btn--primary { background: var(--ink); color: #fff; }
  .btn--primary:hover { background: #0d1326; }
  .btn--primary .jack { color: var(--mint); }
  .btn--light { background: #fff; color: var(--ink); }
  .btn--light:hover { background: var(--steel); }
  .btn--light .jack { color: var(--blue); }
  .jack {
    flex: none; width: 16px; height: 13px; border: 2px solid currentColor; border-radius: 2px;
    position: relative;
  }
  .jack::after { content: ""; position: absolute; left: 3px; right: 3px; bottom: 2px; height: 3px; background: currentColor; border-radius: 1px; }
  .jack::before { content: ""; position: absolute; left: 50%; top: -2px; width: 6px; height: 3px; margin-left: -3px; background: var(--jack-ground, var(--ink)); }
  .btn--light .jack::before { --jack-ground: #fff; }
  .link {
    font-weight: 650; text-decoration: underline; text-decoration-color: var(--steel-3);
    transition: text-decoration-color var(--dur-fast) var(--ease-out);
  }
  .link:hover { text-decoration-color: currentColor; }
  .link-arrow { display: inline-flex; align-items: center; gap: var(--space-2); font-weight: 650; text-decoration: none; }
  .link-arrow svg { width: 18px; height: 18px; transition: transform var(--dur-fast) var(--ease-out); }
  @media (hover: hover) and (pointer: fine) { .link-arrow:hover svg { transform: translateX(3px); } }
  .link-arrow span { text-decoration: underline; text-decoration-color: var(--steel-3); }
  .link-arrow:hover span { text-decoration-color: currentColor; }

  /* Header */
  .site-header {
    position: sticky; top: 0; z-index: 50;
    background: color-mix(in srgb, var(--steel) 94%, transparent);
    border-bottom: 1px solid transparent;
    transition: border-color var(--dur) var(--ease-out);
  }
  @supports (backdrop-filter: blur(8px)) {
    .site-header { backdrop-filter: saturate(1.4) blur(10px); }
  }
  .site-header.is-scrolled { border-bottom-color: var(--steel-2); }
  .site-header__bar { display: flex; align-items: center; justify-content: space-between; gap: var(--space-5); height: var(--header-h); }
  .brand img { width: auto; height: 34px; }
  .nav { display: none; }
  .nav__list { display: flex; align-items: center; gap: var(--space-1); }
  .nav__item { position: relative; }
  .nav__link {
    display: inline-flex; align-items: center; gap: var(--space-2);
    padding: 0.6rem 0.8rem; border-radius: var(--radius-control);
    font-weight: 550; font-size: 0.9375rem; text-decoration: none; color: var(--ink);
    transition: background-color var(--dur-fast) var(--ease-out);
  }
  .nav__link:hover, .nav__link[aria-expanded="true"] { background: var(--steel-2); }
  .nav__link[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--blue); text-decoration-thickness: 2px; }
  .nav__link svg { width: 14px; height: 14px; transition: transform var(--dur-fast) var(--ease-out); }
  .nav__link[aria-expanded="true"] svg { transform: rotate(180deg); }
  .dropdown {
    position: absolute; top: calc(100% + 8px); left: -0.5rem; width: 26rem;
    background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module);
    padding: var(--space-2);
    box-shadow: 0 18px 40px -18px rgb(22 30 53 / 0.28);
    transform-origin: top left;
  }
  @media (prefers-reduced-motion: no-preference) {
    .dropdown:not([hidden]) { animation: drop-in var(--dur) var(--ease-out); }
  }
  @keyframes drop-in { from { opacity: 0; transform: translateY(-4px) scale(0.98); } }
  .dropdown a {
    display: grid; grid-template-columns: 2.5rem 1fr; gap: 0 var(--space-3); align-items: baseline;
    padding: var(--space-3); border-radius: 8px; text-decoration: none;
  }
  .dropdown a:hover { background: var(--steel); }
  .dropdown .code { grid-row: span 2; }
  .dropdown strong { font-weight: 650; font-size: 0.9375rem; }
  .dropdown span:last-child { grid-column: 2; font-size: var(--fs-small); color: var(--ink-3); line-height: 1.4; }
  .dropdown .dropdown__all { display: block; margin-top: var(--space-1); border-top: 1px solid var(--steel-2); border-radius: 0 0 8px 8px; font-weight: 650; font-size: var(--fs-small); }
  .site-header__cta { display: none; }
  .menu-toggle {
    display: inline-flex; align-items: center; gap: var(--space-2);
    min-height: 2.75rem; padding: 0 var(--space-3); border-radius: var(--radius-control);
    font-weight: 600; font-size: 0.9375rem;
  }
  .menu-toggle svg { width: 22px; height: 22px; }
  .mobile-nav {
    position: fixed; inset: var(--header-h) 0 0; z-index: 49; overflow-y: auto;
    background: var(--steel); padding: var(--space-5) var(--gutter) var(--space-8);
    border-top: 1px solid var(--steel-2);
  }
  .mobile-nav ul { display: grid; gap: 0; }
  .mobile-nav li { border-bottom: 1px solid var(--steel-2); }
  .mobile-nav a { display: flex; align-items: baseline; gap: var(--space-3); padding: var(--space-4) 0; text-decoration: none; font-size: 1.25rem; font-weight: 650; }
  .mobile-nav .sub a { font-size: 1.0625rem; font-weight: 550; padding-left: var(--space-2); }
  .mobile-nav .btn { margin-top: var(--space-6); width: 100%; justify-content: center; }
  body.nav-open { overflow: hidden; }
  @media (min-width: 68.75em) {
    .nav, .site-header__cta { display: flex; }
    .menu-toggle, .mobile-nav { display: none !important; }
  }

  /* Hero: forma a medida */
  .hero { padding-top: clamp(2rem, 5vw, 4rem); padding-bottom: clamp(3rem, 6vw, 5rem); overflow: clip; }
  .hero__grid { display: grid; gap: var(--space-6); align-items: center; }
  .hero__copy { display: grid; gap: var(--space-6); max-width: 38rem; position: relative; z-index: 2; }
  .hero__title { max-width: 14ch; }
  .tape { background: linear-gradient(transparent 60%, var(--sun) 60%, var(--sun) 92%, transparent 92%); padding-inline: 0.04em; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
  .hero__lead { font-size: var(--fs-lead); line-height: 1.5; color: var(--ink-2); max-width: 34rem; }
  .hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-4) var(--space-5); }
  @media (min-width: 64em) {
    .hero__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); min-height: min(42rem, calc(100svh - var(--header-h) - 4rem)); }
  }
  @media (prefers-reduced-motion: no-preference) {
    .hero__copy > * { animation: rise 640ms var(--ease-out) both; }
    .hero__copy > :nth-child(2) { animation-delay: 70ms; }
    .hero__copy > :nth-child(3) { animation-delay: 140ms; }
    .field { animation: fade-in 900ms var(--ease-out) 120ms both; }
  }
  @keyframes rise { from { opacity: 0; transform: translateY(12px); } }
  @keyframes fade-in { from { opacity: 0; } }

  .field { position: relative; height: clamp(19rem, 70vw, 26rem); }
  @media (min-width: 64em) { .field { height: clamp(28rem, 42vw, 38rem); margin-right: calc(-1 * var(--gutter)); overflow: hidden; } }
  .field__inner { position: absolute; inset: 0; }
  .field canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
  .field.is-static .field__inner {
    background:
      radial-gradient(closest-side at 46% 50%, var(--blue) 0 58%, transparent 60%),
      radial-gradient(closest-side at 58% 40%, var(--mint) 0 46%, transparent 48%),
      radial-gradient(closest-side at 54% 62%, var(--lilac) 0 38%, transparent 40%);
    background-repeat: no-repeat; background-size: 70% 82%; background-position: center;
  }
  .field-tabs { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-4); }
  .field-tab {
    position: relative; overflow: hidden;
    display: inline-flex; align-items: center; gap: var(--space-2);
    min-height: 2.75rem; padding: 0.5rem 1rem;
    border: 1px solid var(--steel-3); border-radius: 999px; background: color-mix(in srgb, var(--module) 70%, transparent);
    font-weight: 600; font-size: 0.875rem; color: var(--ink-2);
    transition: color var(--dur-fast) ease, border-color var(--dur-fast) ease, background-color var(--dur-fast) ease, transform var(--dur-fast) var(--ease-out);
  }
  .field-tab:active { transform: scale(0.97); }
  @media (hover: hover) and (pointer: fine) { .field-tab:hover { color: var(--ink); border-color: var(--ink-3); } }
  .field-tab[aria-selected="true"] { color: #fff; background: var(--ink); border-color: var(--ink); }
  .field-tab__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); flex: none; }
  .field-tab__progress { position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: var(--c); transform-origin: left; transform: scaleX(0); }
  .field-tab[aria-selected="true"] .field-tab__progress.is-running { animation: tab-progress var(--cycle, 6s) linear forwards; }
  @keyframes tab-progress { to { transform: scaleX(1); } }
  .field-panel { margin-top: var(--space-4); min-height: 3.2em; font-size: var(--fs-small); color: var(--ink-3); max-width: 46ch; }
  .field-panel strong { color: var(--ink); font-weight: 650; }
  .field-panel .link { color: var(--ink); white-space: nowrap; }

  /* Scroll reveal (solo con JS y sin reduced motion) */
  .motion [data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity 640ms var(--ease-out) calc(var(--stagger, 0) * 60ms), transform 640ms var(--ease-out) calc(var(--stagger, 0) * 60ms), border-color var(--dur) ease; }
  .reveal-all [data-reveal] { opacity: 1 !important; transform: none !important; }
  .motion [data-reveal].is-visible { opacity: 1; transform: none; }

  /* Section heading */
  .section--flush-top { padding-top: 0; }
  .section-head { display: grid; gap: var(--space-5); margin-bottom: clamp(2.5rem, 5vw, 4rem); }
  .section-head p { font-size: var(--fs-lead); color: var(--ink-2); max-width: 60ch; line-height: 1.55; }
  @media (min-width: 64em) {
    .section-head--split { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: var(--space-8); align-items: end; }
  }

  /* Client logos */
  .trust { display: grid; gap: var(--space-6); margin-bottom: var(--space-7); }
  @media (min-width: 64em) { .trust { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr); gap: var(--space-8); align-items: start; } }
  .trust p { color: var(--ink-2); max-width: 52ch; }
  .trust p + p { margin-top: var(--space-4); }
  .logos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--steel-3); }
  .logos li { display: grid; place-items: center; padding: var(--space-5) var(--space-4); border-bottom: 1px solid var(--steel-2); }
  .logos img { width: 100%; max-width: 168px; height: auto; mix-blend-mode: multiply; filter: grayscale(1) contrast(1.05); opacity: 0.8; transition: filter var(--dur) ease, opacity var(--dur) ease; }
  @media (hover: hover) and (pointer: fine) { .logos li:hover img { filter: none; opacity: 1; } }
  @media (min-width: 48em) { .logos { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
  @media (min-width: 72em) { .logos { grid-template-columns: repeat(6, minmax(0, 1fr)); } .logos li { border-bottom: 0; } }

  /* Rack: especialidades como filas 1U */
  .rack { display: grid; gap: var(--space-3); }
  .unit {
    position: relative; display: grid; gap: var(--space-4);
    background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module);
    padding: clamp(1.25rem, 2.6vw, 2rem);
    transition: border-color var(--dur) ease;
  }
  .unit::before {
    content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none;
    background: radial-gradient(28rem circle at var(--mx, 50%) var(--my, 50%), color-mix(in srgb, var(--c) 14%, transparent), transparent 60%);
    opacity: 0; transition: opacity var(--dur) ease;
  }
  @media (hover: hover) and (pointer: fine) {
    .unit:hover { border-color: var(--steel-3); }
    .unit:hover::before { opacity: 1; }
    .unit:hover .unit__swatch { transform: scaleX(1.6); }
  }
  .unit__label { display: flex; align-items: center; gap: var(--space-3); }
  .unit__swatch { width: 22px; height: 6px; border-radius: 3px; background: var(--c); box-shadow: 0 0 0 2px var(--ink); transform-origin: left; transition: transform var(--dur) var(--ease-out); }
  .unit h3 small { display: block; margin-top: var(--space-2); font-size: 0.6em; font-weight: 600; letter-spacing: -0.01em; color: var(--blue-ink); }
  .unit p { color: var(--ink-2); max-width: 62ch; }
  .unit__link a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
  .unit__link a:focus-visible { box-shadow: none; }
  .unit:has(.unit__link a:focus-visible) { box-shadow: var(--focus); }
  @media (min-width: 64em) {
    .unit { grid-template-columns: 9rem minmax(0, 1fr) minmax(0, 1.25fr); align-items: start; gap: var(--space-4) var(--space-7); }
    .unit__label { flex-direction: column; align-items: flex-start; padding-top: 0.4rem; }
    .unit__link { grid-column: 3; }
  }
  .rack__aux {
    display: grid; gap: var(--space-4); margin-top: var(--space-5);
    padding: var(--space-5) clamp(1.25rem, 2.6vw, 2rem); border: 1px dashed var(--steel-3); border-radius: var(--radius-module);
  }
  .rack__aux ul { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); }
  .rack__aux li a { font-weight: 600; }
  @media (min-width: 64em) { .rack__aux { grid-template-columns: 9rem 1fr auto; align-items: center; gap: var(--space-6); } }

  /* Integraciones */
  .integrations { display: grid; gap: var(--space-7); }
  .integrations__intro { display: grid; gap: var(--space-5); align-content: start; }
  .integrations__intro p { color: var(--ink-2); max-width: 54ch; }
  .integrations__intro p:first-of-type { font-size: var(--fs-lead); line-height: 1.55; }
  @media (min-width: 64em) { .integrations { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-8); } .integrations__intro { position: sticky; top: calc(var(--header-h) + var(--space-6)); } }
  .flowlist { display: grid; border-top: 1px solid var(--steel-3); }
  .flowlist li { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); gap: var(--space-2) var(--space-4); padding: var(--space-6) 0; border-bottom: 1px solid var(--steel-3); }
  .flowlist__mark { width: 28px; height: 8px; margin-top: 0.6rem; border-radius: 4px; background: var(--c); box-shadow: 0 0 0 2px var(--ink); }
  .flowlist strong { font-size: var(--fs-h3); font-weight: 750; letter-spacing: -0.02em; line-height: 1.2; }
  .flowlist p { grid-column: 2; color: var(--ink-2); }

  /* KonexCommerce */
  .kc {
    display: grid; gap: var(--space-7);
    background: var(--module); border: 1px solid var(--steel-2); border-radius: 20px;
    padding: clamp(1.75rem, 5vw, 4.5rem);
    position: relative; overflow: hidden;
  }
  .kc::after {
    content: ""; position: absolute; right: -12rem; top: -12rem; width: 32rem; height: 32rem; border-radius: 50%; pointer-events: none;
    background: radial-gradient(closest-side, color-mix(in srgb, var(--mint) 22%, transparent), transparent);
  }
  .kc__head { display: grid; gap: var(--space-5); max-width: 46rem; position: relative; z-index: 1; }
  .kc__logo { width: auto; height: clamp(2rem, 3vw, 2.5rem); }
  .kc__head p { color: var(--ink-2); max-width: 60ch; }
  .kc__head p:first-of-type { font-size: var(--fs-lead); line-height: 1.55; }
  .kc__features { display: grid; gap: var(--space-5) var(--space-6); position: relative; z-index: 1; }
  .kc__features li { display: grid; gap: var(--space-2); padding-top: var(--space-4); border-top: 2px solid var(--ink); }
  .kc__features strong { font-size: 1.125rem; font-weight: 700; }
  .kc__features p { color: var(--ink-2); font-size: 0.9375rem; }
  @media (min-width: 48em) { .kc__features { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
  @media (min-width: 72em) { .kc__features { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
  .kc__foot { display: grid; gap: var(--space-5); position: relative; z-index: 1; }
  .kc__foot p { color: var(--ink-2); max-width: 52ch; }
  .kc__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-4) var(--space-5); }
  @media (min-width: 64em) { .kc__foot { grid-template-columns: 1fr auto; align-items: center; } }

  /* Proyectos */
  .projects { display: grid; gap: var(--space-6); padding-block: clamp(1rem, 3vw, 2rem); border-top: 1px solid var(--steel-3); border-bottom: 1px solid var(--steel-3); padding-top: var(--space-7); padding-bottom: var(--space-7); }
  .projects h2 { font-size: clamp(2.5rem, 5vw + 0.5rem, 4.5rem); max-width: 12ch; }
  .projects__body { display: grid; gap: var(--space-4); align-content: end; }
  .projects__body p { color: var(--ink-2); max-width: 56ch; }
  .projects__lead { font-size: var(--fs-lead); line-height: 1.5; color: var(--ink) !important; }
  .projects__body .link-arrow { margin-top: var(--space-3); }
  @media (min-width: 64em) { .projects { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: var(--space-8); } }

  /* Método */
  .method { display: grid; gap: var(--space-6); counter-reset: step; position: relative; }
  .method__step { display: grid; gap: var(--space-3); align-content: start; position: relative; }
  .method__num {
    display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 50%;
    background: var(--module); border: 1.5px solid var(--ink); font-weight: 750; font-variant-numeric: tabular-nums;
    position: relative; z-index: 1;
  }
  .method__step p { color: var(--ink-2); font-size: 0.9375rem; }
  @media (min-width: 64em) {
    .method { grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); gap: var(--space-6); }
    .method::before {
      content: ""; position: absolute; left: 1.375rem; right: calc((100% - (var(--n, 4) - 1) * var(--space-6)) / var(--n, 4) - 1.375rem); top: 1.375rem; height: 2px; background: var(--steel-3);
    }
    .method::after {
      content: ""; position: absolute; left: 1.375rem; right: calc((100% - (var(--n, 4) - 1) * var(--space-6)) / var(--n, 4) - 1.375rem); top: 1.375rem; height: 2px;
      background: linear-gradient(90deg, var(--mint), var(--lilac), var(--blue), var(--heat));
      transform-origin: left; transform: scaleX(var(--progress, 1));
    }
    .motion .method::after { transform: scaleX(0); transition: transform 1400ms var(--ease-in-out) 200ms; }
    .motion .method.is-visible::after { transform: scaleX(1); }
  }
  .method__foot { margin-top: var(--space-7); }

  /* Insights */
  .posts { display: grid; gap: var(--space-7) var(--space-6); }
  @media (min-width: 52em) { .posts { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
  .post { position: relative; display: grid; gap: var(--space-3); align-content: start; }
  .post__media { border-radius: var(--radius-module); overflow: hidden; aspect-ratio: 16 / 10; background: var(--steel-2); margin-bottom: var(--space-2); }
  .post__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms var(--ease-out); }
  @media (hover: hover) and (pointer: fine) { .post:hover .post__media img { transform: scale(1.03); } }
  .post__meta { display: flex; gap: var(--space-3); font-size: var(--fs-small); color: var(--ink-3); }
  .post__meta span { font-weight: 650; color: var(--blue-ink); }
  .post h3 { font-size: 1.25rem; line-height: 1.3; letter-spacing: -0.015em; }
  .post h3 a { text-decoration: none; }
  .post h3 a::after { content: ""; position: absolute; inset: 0; }
  @media (hover: hover) and (pointer: fine) { .post:hover h3 a { text-decoration: underline; text-decoration-color: var(--steel-3); } }
  .post p { color: var(--ink-2); font-size: 0.9375rem; }
  .post:has(a:focus-visible) { box-shadow: var(--focus); border-radius: var(--radius-module); }
  .post h3 a:focus-visible { box-shadow: none; }
  .posts__foot { margin-top: var(--space-7); }

  /* Banda de cierre */
  .close {
    background: var(--ink); color: #fff; border-radius: 20px;
    padding: clamp(2.5rem, 6vw, 5rem) clamp(1.5rem, 5vw, 4.5rem);
    display: grid; position: relative; overflow: hidden;
  }
  .close__copy { display: grid; gap: var(--space-5); position: relative; z-index: 1; max-width: 40rem; }
  .close h2 { max-width: 18ch; }
  .close p { color: #c9cfe0; font-size: var(--fs-lead); max-width: 56ch; }
  .close__actions { display: grid; gap: var(--space-5); margin-top: var(--space-3); justify-items: start; }
  .close__contact { display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-6); font-size: 0.9375rem; color: #c9cfe0; }
  .close__contact a { color: #fff; font-weight: 600; text-decoration-color: rgb(255 255 255 / 0.35); }
  .close__contact a:hover { text-decoration-color: #fff; }
  .close__lines { position: absolute; right: 0; top: 0; height: 100%; width: 55%; pointer-events: none; opacity: 0.5; }
  @media (max-width: 63.99em) { .close__lines { width: 100%; opacity: 0.22; } }
  .close :focus-visible { box-shadow: 0 0 0 3px var(--ink), 0 0 0 5px var(--mint); }

  .integrations__foot { display: grid; gap: var(--space-5); }
  .integrations__foot p { color: var(--ink-2); max-width: 60ch; }
  .close__micro { font-size: 0.9375rem !important; color: #aeb6cc !important; }

  /* Selector de modelos (KonexCommerce) */
  .model-tabs { display: grid; gap: var(--space-5); }
  .model-tabs__list { display: flex; flex-wrap: wrap; gap: var(--space-2); }
  .model-tab {
    display: inline-flex; align-items: center; gap: var(--space-3); min-height: 3rem; padding: 0.6rem 1.2rem;
    border: 1.5px solid var(--steel-3); border-radius: 999px; background: var(--module); font-weight: 650;
    transition: background-color var(--dur-fast) ease, color var(--dur-fast) ease, border-color var(--dur-fast) ease, transform var(--dur-fast) var(--ease-out);
  }
  .model-tab:active { transform: scale(0.97); }
  @media (hover: hover) and (pointer: fine) { .model-tab:hover { border-color: var(--ink-3); } }
  .model-tab[aria-selected="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
  .model-tab__mark { width: 22px; height: 6px; border-radius: 3px; background: var(--c); box-shadow: 0 0 0 2px currentColor; }
  .model-panel { display: grid; gap: var(--space-4); background: var(--module); border: 1px solid var(--steel-2); border-radius: 20px; padding: clamp(1.5rem, 4vw, 3rem); position: relative; overflow: hidden; }
  .model-panel::after { content: ""; position: absolute; right: -6rem; bottom: -8rem; width: 22rem; height: 22rem; border-radius: 50%; background: radial-gradient(closest-side, color-mix(in srgb, var(--c) 26%, transparent), transparent); pointer-events: none; }
  .model-panel h3 { font-size: var(--fs-h3); position: relative; }
  .model-panel p { font-size: var(--fs-lead); line-height: 1.55; color: var(--ink-2); max-width: 58ch; position: relative; }
  @media (prefers-reduced-motion: no-preference) { .model-panel:not([hidden]) { animation: fade-in 200ms ease-out; } }

  .checklist { display: grid; gap: var(--space-3); }
  .checklist li { display: grid; grid-template-columns: 1.5rem 1fr; gap: var(--space-3); color: var(--ink-2); }
  .checklist li::before { content: ""; width: 14px; height: 8px; margin-top: 0.45rem; border-left: 2.5px solid var(--blue); border-bottom: 2.5px solid var(--blue); transform: rotate(-45deg); }
  .kc__note { position: relative; z-index: 1; max-width: 68ch; }

  /* Migas de pan */
  .crumbs ol { display: flex; flex-wrap: wrap; gap: var(--space-2); font-size: var(--fs-small); color: var(--ink-3); }
  .crumbs li + li::before { content: "/"; margin-right: var(--space-2); color: var(--steel-3); }
  .crumbs a { text-decoration: none; color: var(--ink-3); }
  .crumbs a:hover { color: var(--ink); text-decoration: underline; }
  .crumbs [aria-current] { color: var(--ink); font-weight: 600; }

  /* Héroe de página interior */
  .hero--page .hero__title { font-size: clamp(2.375rem, 3.6vw + 0.75rem, 4rem); max-width: 16ch; }
  .hero__sub { color: var(--ink-2); max-width: 34rem; }
  .hero__keywords { display: flex; flex-wrap: wrap; gap: var(--space-2); }
  .hero__keywords li { font-size: 0.8125rem; font-weight: 600; color: var(--ink-2); padding: 0.3rem 0.75rem; border: 1px solid var(--steel-3); border-radius: 999px; }
  .field--page { height: clamp(16rem, 60vw, 22rem); }
  @media (min-width: 64em) {
    .hero--page .hero__grid { min-height: min(36rem, calc(100svh - var(--header-h) - 4rem)); }
    .field--page { height: clamp(24rem, 36vw, 32rem); }
  }

  /* Bloque de texto en dos columnas */
  .prose-split { display: grid; gap: var(--space-6); }
  .prose-split__body { display: grid; gap: var(--space-4); align-content: start; }
  .prose-split__body p { color: var(--ink-2); max-width: 60ch; }
  .prose-split__body p:first-child { font-size: var(--fs-lead); line-height: 1.55; color: var(--ink); }
  @media (min-width: 64em) { .prose-split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-8); } }

  /* Puntos con filete superior */
  .points { display: grid; gap: var(--space-6) var(--space-6); }
  @media (min-width: 48em) { .points--2, .points--3, .points--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
  @media (min-width: 64em) { .points--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .points--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
  .points li { display: grid; gap: var(--space-2); align-content: start; padding-top: var(--space-4); border-top: 2px solid var(--ink); position: relative; }
  .points li::before { content: ""; position: absolute; left: 0; top: -2px; width: 2.5rem; height: 2px; background: var(--c, var(--blue)); }
  .points h3 { font-size: 1.1875rem; letter-spacing: -0.015em; line-height: 1.3; }
  .points p { color: var(--ink-2); font-size: 0.9375rem; }
  .points__note { display: inline-block; margin-bottom: var(--space-5); font-size: var(--fs-label); font-weight: 700; font-stretch: 112%; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); }

  /* Opciones (plataformas, enfoques, rutas) */
  .options { display: grid; gap: var(--space-3); }
  .option { display: grid; gap: var(--space-2) var(--space-6); background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module); padding: clamp(1.25rem, 2.4vw, 1.75rem); }
  .option h3 { font-size: 1.375rem; letter-spacing: -0.02em; display: flex; align-items: center; gap: var(--space-3); }
  .option h3::before { content: ""; width: 22px; height: 6px; border-radius: 3px; background: var(--c, var(--blue)); box-shadow: 0 0 0 2px var(--ink); flex: none; }
  .option p { color: var(--ink-2); max-width: 64ch; }
  .option--own { border-color: var(--ink); }
  .option__tag { justify-self: start; font-size: var(--fs-label); font-weight: 700; font-stretch: 112%; letter-spacing: 0.1em; text-transform: uppercase; color: #fff; background: var(--ink); padding: 0.2rem 0.55rem; border-radius: 4px; }
  @media (min-width: 64em) { .option { grid-template-columns: 18rem minmax(0, 1fr); align-items: start; } .option__tag { grid-column: 1; } }
  .options__foot { margin-top: var(--space-6); }

  /* Frase destacada */
  .statement { display: flex; gap: var(--space-4); align-items: baseline; margin-top: clamp(2.5rem, 5vw, 4rem); font-size: clamp(1.375rem, 1.4vw + 0.9rem, 2rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.3; max-width: 32ch; text-wrap: balance; }
  .statement__mark { flex: none; width: 28px; height: 8px; border-radius: 4px; background: var(--c); box-shadow: 0 0 0 2px var(--ink); transform: translateY(-0.2em); }

  /* Chips de ámbitos */
  .chips { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-5); }
  .chips li { font-size: 0.875rem; font-weight: 600; padding: 0.4rem 0.9rem; border-radius: 999px; background: var(--module); border: 1px solid var(--steel-2); }

  /* Tabla de flujos */
  .table-wrap { overflow-x: auto; border: 1px solid var(--steel-2); border-radius: var(--radius-module); background: var(--module); }
  .data-table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; min-width: 40rem; }
  .data-table caption { text-align: left; padding: var(--space-4) var(--space-5); font-size: var(--fs-small); color: var(--ink-3); caption-side: bottom; border-top: 1px solid var(--steel-2); }
  .data-table th, .data-table td { text-align: left; padding: var(--space-4) var(--space-5); border-bottom: 1px solid var(--steel-2); vertical-align: top; }
  .data-table thead th { font-size: var(--fs-label); font-weight: 700; font-stretch: 112%; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); }
  .data-table tbody th { font-weight: 650; }
  .data-table tbody tr:last-child > * { border-bottom: 0; }
  .data-table .route { font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--ink); font-weight: 600; }

  /* Citas de situaciones */
  .quotes { display: grid; gap: var(--space-5); }
  @media (min-width: 48em) { .quotes { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
  .quotes li { display: grid; gap: var(--space-3); padding: clamp(1.25rem, 2.4vw, 1.75rem); background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module); }
  .quotes q { font-size: 1.25rem; font-weight: 700; letter-spacing: -0.015em; line-height: 1.3; quotes: "«" "»"; }
  .quotes p { color: var(--ink-2); font-size: 0.9375rem; }

  /* FAQ */
  .faq { display: grid; gap: var(--space-6); }
  @media (min-width: 64em) { .faq { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr); gap: var(--space-8); align-items: start; } }
  .faq__list { border-top: 1px solid var(--steel-3); }
  .faq__item { border-bottom: 1px solid var(--steel-3); }
  .faq__item summary {
    display: flex; justify-content: space-between; align-items: center; gap: var(--space-5);
    padding: var(--space-5) 0; cursor: pointer; list-style: none; font-weight: 650; font-size: 1.0625rem; border-radius: var(--radius-control);
  }
  .faq__item summary::-webkit-details-marker { display: none; }
  .faq__item summary svg { width: 20px; height: 20px; flex: none; transition: transform var(--dur) var(--ease-out); }
  .faq__item[open] summary svg { transform: rotate(45deg); }
  .faq__item p { padding: 0 0 var(--space-5); color: var(--ink-2); max-width: 64ch; }
  @media (hover: hover) and (pointer: fine) { .faq__item summary:hover span { text-decoration: underline; text-decoration-color: var(--steel-3); } }

  /* Hub: especialidades complementarias */
  .aux-services { display: grid; gap: var(--space-5); }
  @media (min-width: 64em) { .aux-services { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
  .aux-services article { display: grid; gap: var(--space-3); align-content: start; padding-top: var(--space-4); border-top: 1px dashed var(--steel-3); scroll-margin-top: calc(var(--header-h) + var(--space-6)); }
  .aux-services h3 { font-size: 1.25rem; }
  .aux-services p, .aux-services li { color: var(--ink-2); font-size: 0.9375rem; }
  .aux-services ul { display: grid; gap: var(--space-1); padding-left: 1.1rem; }

  /* Contacto */
  .contact { display: grid; gap: var(--space-8); }
  @media (min-width: 64em) { .contact { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: var(--space-8); align-items: start; } }
  .contact-page { padding-top: clamp(2rem, 5vw, 4rem); }
  .contact__intro { display: grid; gap: var(--space-5); }
  .contact__title { font-size: clamp(2.25rem, 3vw + 0.75rem, 3.5rem); max-width: 16ch; }
  @media (prefers-reduced-motion: no-preference) { .contact__intro > *, .contact .form { animation: rise 640ms var(--ease-out) both; } .contact .form { animation-delay: 120ms; } }
  .contact__aside { display: grid; gap: var(--space-7); }
  .contact__direct { display: grid; gap: var(--space-3); }
  .contact__direct h2, .contact__next h2 { font-size: var(--fs-h3); }
  .contact__direct a { font-weight: 650; font-size: 1.125rem; }
  .contact__direct p { color: var(--ink-2); }
  .contact__next ol { display: grid; gap: var(--space-4); margin-top: var(--space-4); }
  .contact__next li { display: grid; grid-template-columns: 2rem 1fr; gap: var(--space-1) var(--space-3); }
  .contact__next li span { grid-row: span 2; display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; border: 1.5px solid var(--ink); font-weight: 750; font-size: 0.875rem; }
  .contact__next li strong { font-weight: 650; }
  .contact__next li p { color: var(--ink-2); font-size: 0.9375rem; }
  .contact__note { font-size: var(--fs-small); color: var(--ink-3); margin-top: var(--space-4); }

  .form { background: var(--module); border: 1px solid var(--steel-2); border-radius: 20px; padding: clamp(1.5rem, 4vw, 3rem); display: grid; gap: var(--space-5); scroll-margin-top: calc(var(--header-h) + var(--space-4)); }
  .form h2 { font-size: var(--fs-h3); }
  .form > p { color: var(--ink-2); }
  .form__grid { display: grid; gap: var(--space-5); }
  @media (min-width: 48em) { .form__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .form__full { grid-column: 1 / -1; } }
  .field-group { display: grid; gap: var(--space-2); }
  .field-group label { font-weight: 650; font-size: 0.9375rem; }
  .field-group label .req { color: var(--heat); margin-left: 2px; }
  .field-group label .opt { font-weight: 500; color: var(--ink-3); font-size: 0.8125rem; margin-left: var(--space-1); }
  .input {
    width: 100%; min-height: 3rem; padding: 0.7rem 0.9rem; font-size: 1rem;
    background: var(--steel); border: 1.5px solid var(--steel-3); border-radius: 8px; color: var(--ink);
    transition: border-color var(--dur-fast) ease, background-color var(--dur-fast) ease, box-shadow var(--dur-fast) ease;
  }
  .input::placeholder { color: var(--ink-3); opacity: 1; }
  .input:hover { border-color: var(--ink-3); }
  .input:focus { outline: none; background: #fff; border-color: var(--blue); box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 22%, transparent); }
  textarea.input { min-height: 9rem; resize: vertical; line-height: 1.5; }
  select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 6l4.5 4.5L12.5 6' fill='none' stroke='%23161e35' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 0.9rem center; background-size: 16px; padding-right: 2.5rem; }
  .input[aria-invalid="true"] { border-color: #c2410c; background: #fff7f3; }
  .field-error { font-size: var(--fs-small); color: #b3370b; font-weight: 600; }
  .field-help { font-size: var(--fs-small); color: var(--ink-3); }
  .form__hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
  .form__micro { font-size: 0.9375rem; color: var(--ink-2); }
  .form__privacy { font-size: var(--fs-small); color: var(--ink-3); }
  .form__privacy a { color: var(--ink-2); }
  .form__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-4); }
  .form .btn[disabled] { opacity: 0.7; cursor: progress; }
  .form__status { border-radius: 10px; padding: var(--space-4) var(--space-5); font-weight: 600; }
  .form__status--error { background: #fff1ea; color: #8a2a06; border: 1px solid #f6c3ad; }
  .form__status--success { background: #e9fbf4; color: #0b5a43; border: 1px solid #9fe8cf; }
  .form__status:focus { outline: none; box-shadow: var(--focus); }
  .form__done { display: grid; gap: var(--space-4); }
  .form__done h2 { font-size: var(--fs-h3); }
  .form__done p { color: var(--ink-2); }

  /* Blog: cabecera, filtros y listado */
  .blog-head { padding-top: clamp(2rem, 5vw, 4rem); padding-bottom: var(--space-7); }
  .blog-head__grid { display: grid; gap: var(--space-6); align-items: end; }
  .blog-head__copy { display: grid; gap: var(--space-5); max-width: 46rem; }
  .blog-head__title { font-size: clamp(2.25rem, 3.4vw + 0.75rem, 3.75rem); max-width: 18ch; }
  @media (min-width: 64em) { .blog-head__grid { grid-template-columns: minmax(0, 1fr) 24rem; gap: var(--space-8); } }
  .blog-search { display: flex; gap: var(--space-2); }
  .blog-search .input { background: var(--module); }
  .blog-filters { margin-top: var(--space-7); overflow-x: auto; scrollbar-width: none; }
  .blog-filters::-webkit-scrollbar { display: none; }
  .blog-filters ul { display: flex; gap: var(--space-2); padding-bottom: var(--space-1); }
  .blog-filter {
    display: inline-flex; align-items: center; gap: var(--space-2); white-space: nowrap; min-height: 2.5rem; padding: 0.45rem 0.95rem;
    border: 1px solid var(--steel-3); border-radius: 999px; background: var(--module); text-decoration: none; font-weight: 600; font-size: 0.875rem; color: var(--ink-2);
    transition: border-color var(--dur-fast) ease, color var(--dur-fast) ease, background-color var(--dur-fast) ease;
  }
  .blog-filter span { font-variant-numeric: tabular-nums; color: var(--ink-3); font-weight: 500; }
  @media (hover: hover) and (pointer: fine) { .blog-filter:hover { border-color: var(--ink-3); color: var(--ink); } }
  .blog-filter[aria-current] { background: var(--ink); border-color: var(--ink); color: #fff; }
  .blog-filter[aria-current] span { color: #aeb6cc; }
  .blog-active { margin-top: var(--space-5); color: var(--ink-2); font-size: 0.9375rem; }
  .posts--grid { row-gap: var(--space-8); }
  .post h2 { font-size: 1.25rem; line-height: 1.3; letter-spacing: -0.015em; }
  .post h2 a { text-decoration: none; }
  .post h2 a::after { content: ""; position: absolute; inset: 0; }
  @media (hover: hover) and (pointer: fine) { .post:hover h2 a { text-decoration: underline; text-decoration-color: var(--steel-3); } }
  .post h2 a:focus-visible { box-shadow: none; }
  .empty { display: grid; gap: var(--space-4); justify-items: start; padding: var(--space-8) 0; }
  .empty p { color: var(--ink-2); }
  .blog-tags { margin-top: var(--space-9); padding-top: var(--space-6); border-top: 1px solid var(--steel-3); }
  .blog-tags h2 { font-size: var(--fs-label); font-weight: 700; font-stretch: 112%; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: var(--space-4); }
  .blog-tags ul { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); }
  .blog-tags a { font-weight: 600; font-size: 0.9375rem; text-decoration-color: var(--steel-3); }

  /* Paginación (plantilla default_full de CodeIgniter) */
  .pager { margin-top: var(--space-8); }
  .pager .pagination { display: flex; flex-wrap: wrap; gap: var(--space-2); list-style: none; padding: 0; }
  .pager .pagination a, .pager .pagination span { display: grid; place-items: center; min-width: 2.75rem; height: 2.75rem; padding: 0 var(--space-3); border-radius: 8px; border: 1px solid var(--steel-3); background: var(--module); text-decoration: none; font-weight: 600; font-variant-numeric: tabular-nums; }
  .pager .pagination .active a { background: var(--ink); color: #fff; border-color: var(--ink); }
  @media (hover: hover) and (pointer: fine) { .pager .pagination a:hover { border-color: var(--ink-3); } }

  /* Artículo */
  .article__head { padding-top: clamp(2rem, 5vw, 4rem); padding-bottom: var(--space-7); }
  .article__head-inner { display: grid; gap: var(--space-5); max-width: 60rem; }
  .article__cats { display: flex; flex-wrap: wrap; gap: var(--space-2); }
  .article__cats a { font-size: 0.8125rem; font-weight: 650; color: var(--blue-ink); text-decoration: none; padding: 0.25rem 0.7rem; border-radius: 999px; background: color-mix(in srgb, var(--blue) 10%, var(--module)); }
  .article__title { font-size: clamp(2.125rem, 3vw + 0.9rem, 3.75rem); max-width: 22ch; }
  .article__meta { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); font-size: var(--fs-small); color: var(--ink-3); }
  .article__meta a { color: var(--ink-2); }
  .article__cover { margin-bottom: var(--space-8); }
  .article__cover img { width: 100%; height: auto; aspect-ratio: 1200 / 630; object-fit: cover; border-radius: 20px; background: var(--steel-2); }
  .article__layout { display: grid; gap: var(--space-8); padding-bottom: var(--space-9); }
  @media (min-width: 72em) {
    .article__layout { grid-template-columns: minmax(0, 46rem) minmax(0, 18rem); justify-content: space-between; }
    .article__aside { position: sticky; top: calc(var(--header-h) + var(--space-6)); align-self: start; }
  }
  .article__body { min-width: 0; display: grid; gap: var(--space-7); align-content: start; }
  .article-tldr { padding: var(--space-5) var(--space-6); background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module); position: relative; }
  .article-tldr::before { content: ""; position: absolute; left: var(--space-6); top: -1px; width: 2.5rem; height: 3px; background: var(--blue); border-radius: 0 0 2px 2px; }
  .article-tldr__label { font-size: var(--fs-label); font-weight: 700; font-stretch: 112%; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: var(--space-2); }
  .article-tldr p:last-child { font-size: 1.0625rem; line-height: 1.6; }
  .article__aside { display: grid; gap: var(--space-6); }
  .article-toc { border-top: 2px solid var(--ink); padding-top: var(--space-4); }
  .article-toc__title { font-size: var(--fs-label); font-weight: 700; font-stretch: 112%; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: var(--space-3); }
  .article-toc ol { display: grid; gap: var(--space-2); counter-reset: toc; }
  .article-toc li { counter-increment: toc; display: grid; grid-template-columns: 1.75rem 1fr; font-size: 0.9375rem; line-height: 1.4; }
  .article-toc li::before { content: counter(toc, decimal-leading-zero); font-variant-numeric: tabular-nums; color: var(--ink-3); font-size: 0.8125rem; padding-top: 0.1rem; }
  .article-toc a { text-decoration: none; color: var(--ink-2); }
  .article-toc a:hover { color: var(--ink); text-decoration: underline; }
  .article__cta { display: grid; gap: var(--space-3); padding: var(--space-5); background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module); }
  .article__cta p { font-size: 0.9375rem; color: var(--ink-2); }
  .article__cta p strong { color: var(--ink); font-size: 1.0625rem; }
  .article__cta .btn { justify-self: stretch; justify-content: center; }
  .article__gallery { display: grid; gap: var(--space-4); }
  .article__gallery img { width: 100%; height: auto; border-radius: var(--radius-module); }
  .article__tags { display: flex; flex-wrap: wrap; gap: var(--space-2); }
  .article__tags a { font-size: 0.8125rem; font-weight: 600; padding: 0.3rem 0.75rem; border: 1px solid var(--steel-3); border-radius: 999px; text-decoration: none; color: var(--ink-2); }
  .article__share { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3) var(--space-5); font-size: 0.9375rem; padding-top: var(--space-5); border-top: 1px solid var(--steel-3); }
  .article__share span { font-weight: 650; }
  .article__share a { font-weight: 600; }
  .article__author { display: grid; gap: var(--space-3); padding: var(--space-6); background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module); }
  .article__author p { color: var(--ink-2); font-size: 0.9375rem; max-width: 62ch; }
  .article__author p:first-child { color: var(--ink); }
  .related__title { font-size: var(--fs-h3); margin-bottom: var(--space-6); }

  /* Tipografía de contenido (artículos y textos legales) */
  .prose { font-size: 1.0625rem; line-height: 1.75; color: var(--ink-2); overflow-wrap: break-word; }
  .prose > * + * { margin-top: 1.1em; }
  .prose p, .prose li, .prose blockquote, .article-tldr p { max-width: 62ch; }
  .prose h2 { font-size: clamp(1.5rem, 1vw + 1.1rem, 1.875rem); color: var(--ink); margin-top: 2.2em; line-height: 1.2; letter-spacing: -0.02em; scroll-margin-top: calc(var(--header-h) + var(--space-5)); }
  .prose h3 { font-size: 1.25rem; color: var(--ink); margin-top: 1.8em; line-height: 1.3; scroll-margin-top: calc(var(--header-h) + var(--space-5)); }
  .prose h4 { font-size: 1.0625rem; color: var(--ink); margin-top: 1.6em; }
  .prose strong { color: var(--ink); font-weight: 650; }
  .prose a { color: var(--blue-ink); font-weight: 550; text-decoration-color: color-mix(in srgb, var(--blue) 40%, transparent); }
  .prose a:hover { text-decoration-color: currentColor; }
  .prose ul, .prose ol { padding-left: 1.3em; }
  .prose li + li { margin-top: 0.4em; }
  .prose li::marker { color: var(--blue); }
  .prose blockquote { border-left: 2px solid var(--ink); padding-left: var(--space-5); color: var(--ink); font-size: 1.125rem; }
  .prose img { border-radius: var(--radius-module); height: auto; }
  .prose figure figcaption { font-size: var(--fs-small); color: var(--ink-3); margin-top: var(--space-2); }
  .prose code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.875em; background: var(--steel-2); padding: 0.1em 0.35em; border-radius: 4px; color: var(--ink); }
  .prose pre { background: var(--ink); color: #e6e9f2; padding: var(--space-5); border-radius: var(--radius-module); overflow-x: auto; font-size: 0.875rem; line-height: 1.6; }
  .prose pre code { background: none; color: inherit; padding: 0; }
  .prose table { display: block; width: 100%; overflow-x: auto; border-collapse: collapse; font-size: 0.9375rem; line-height: 1.5; }
  .prose th, .prose td { border-bottom: 1px solid var(--steel-3); padding: 0.7rem 0.9rem 0.7rem 0; text-align: left; vertical-align: top; }
  .prose th { color: var(--ink); font-weight: 650; }
  .prose hr { border: 0; border-top: 1px solid var(--steel-3); margin: 2.4em 0; }
  .prose dl { display: grid; gap: var(--space-1) var(--space-5); }
  @media (min-width: 48em) { .prose dl { grid-template-columns: max-content 1fr; } }
  .prose dt { font-weight: 650; color: var(--ink); }
  .prose dd { margin: 0; }

  /* Páginas legales y 404 */
  .legal { padding-top: clamp(2rem, 5vw, 4rem); padding-bottom: var(--section); }
  .legal__inner { display: grid; gap: var(--space-6); max-width: 48rem; }
  .legal__title { font-size: clamp(2.25rem, 3vw + 0.75rem, 3.5rem); }
  .legal__card { padding: var(--space-5) var(--space-6); background: var(--module); border: 1px solid var(--steel-2); border-radius: var(--radius-module); }
  .notfound { padding-block: clamp(4rem, 10vw, 8rem); }
  .notfound__inner { display: grid; gap: var(--space-5); justify-items: start; max-width: 40rem; }
  .notfound .notfound__code { font-size: clamp(4rem, 10vw, 7rem); font-weight: 800; line-height: 1; letter-spacing: -0.04em; background: none; color: var(--ink); }
  .notfound__code span { color: var(--blue); }
  .notfound p { color: var(--ink-2); font-size: var(--fs-lead); }
  .notfound__links { display: flex; flex-wrap: wrap; gap: var(--space-4) var(--space-5); align-items: center; margin-top: var(--space-3); }

  /* Footer */
  .site-footer { padding-block: var(--space-8) var(--space-6); border-top: 1px solid var(--steel-3); }
  .footer__col li { font-size: 0.9375rem; }
  .footer__grid { display: grid; gap: var(--space-7); }
  .footer__brand p { margin-top: var(--space-4); color: var(--ink-2); max-width: 36ch; font-size: 0.9375rem; }
  .footer__brand img { height: 30px; width: auto; }
  .footer__col h2 { font-size: var(--fs-label); font-weight: 700; font-stretch: 112%; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: var(--space-4); }
  .footer__col ul { display: grid; gap: var(--space-2); }
  .footer__col a { text-decoration: none; font-size: 0.9375rem; }
  .footer__col a:hover { text-decoration: underline; }
  .footer__legal { margin-top: var(--space-8); padding-top: var(--space-5); border-top: 1px solid var(--steel-2); display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-5); justify-content: space-between; font-size: var(--fs-small); color: var(--ink-3); }
  .footer__legal ul { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-5); }
  .footer__legal a, .footer__legal button { text-decoration: underline; text-decoration-color: var(--steel-3); font-size: inherit; }
  @media (min-width: 52em) { .footer__grid { grid-template-columns: 1.4fr repeat(3, 1fr); } }

  /* Cookies */
  .cookie-bar {
    position: fixed; z-index: 60; left: var(--space-4); right: var(--space-4); bottom: var(--space-4);
    max-width: 42rem; margin-inline: auto;
    background: var(--ink); color: #fff; border-radius: var(--radius-module);
    padding: var(--space-5); display: grid; gap: var(--space-4);
    box-shadow: 0 24px 48px -20px rgb(22 30 53 / 0.5);
  }
  .cookie-bar p { font-size: 0.9375rem; color: #d3d8e6; }
  .cookie-bar p strong { color: #fff; }
  .cookie-bar a { color: #fff; }
  .cookie-bar__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); }
  .cookie-bar .btn { min-height: 2.75rem; padding: 0.6rem 1.1rem; font-size: 0.9375rem; }
  .btn--ghost-light { color: #fff; border: 1.5px solid rgb(255 255 255 / 0.5); }
  .btn--ghost-light:hover { border-color: #fff; }
  .cookie-bar :focus-visible { box-shadow: 0 0 0 3px var(--ink), 0 0 0 5px var(--mint); }
  .cookie-dialog {
    border: 0; border-radius: var(--radius-module); padding: 0; width: min(100% - 2rem, 34rem);
    background: var(--module); color: var(--ink); box-shadow: 0 30px 60px -20px rgb(22 30 53 / 0.45);
  }
  .cookie-dialog::backdrop { background: rgb(22 30 53 / 0.45); }
  .cookie-dialog form { padding: var(--space-6); display: grid; gap: var(--space-5); }
  .cookie-dialog h2 { font-size: 1.5rem; }
  .cookie-dialog p { font-size: 0.9375rem; color: var(--ink-2); }
  .cookie-opt { display: grid; grid-template-columns: 1fr auto; gap: var(--space-1) var(--space-4); padding-block: var(--space-4); border-top: 1px solid var(--steel-2); }
  .cookie-opt label, .cookie-opt strong { font-weight: 650; }
  .cookie-opt p { grid-column: 1; font-size: var(--fs-small); }
  .cookie-opt input { width: 1.25rem; height: 1.25rem; accent-color: var(--blue); grid-row: 1; grid-column: 2; }
  .cookie-opt .always { grid-row: 1; grid-column: 2; font-size: var(--fs-small); color: var(--ink-3); }
  .cookie-dialog__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); justify-content: flex-end; }
  .btn--outline { border: 1.5px solid var(--ink); color: var(--ink); }
  .btn--outline:hover { background: var(--steel); }
}

@layer utilities {
  .visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  @media (prefers-reduced-motion: reduce) {
    .btn:active, .link-arrow:hover svg { transform: none; }
  }
}
