/* stylelint-disable declaration-block-single-line-max-declarations, color-function-alias-notation, color-function-notation, alpha-value-notation, rule-empty-line-before, at-rule-empty-line-before, comment-empty-line-before, declaration-empty-line-before, no-duplicate-selectors, media-feature-range-notation, property-no-vendor-prefix, font-family-name-quotes -- rgba(var(--x-rgb), a) needs the legacy comma syntax, and later layers override earlier rules on purpose */
/* Alista AI Consulting: shared stylesheet for consulting.html and consulting-en.html */
:root {
  --bg-base:      #04142C;
  --bg-elevated:  #06203F;
  --bg-card:      #0A2A52;
  /* brand accent: the logo's CONSULTING blue, electrified for the navy */
  --accent:       #4FB3FF;
  --accent-dark:  #1673DC;
  --accent-rgb:   79, 179, 255;
  /* the orange arc of the ring, used sparingly */
  --spark:        #FF9142;
  --spark-rgb:    255, 145, 66;
  /* the steel of the ring itself */
  --slate-dark:   #54606C;
  --slate-mid:    #7C8C98;
  --slate-light:  #A7BCC6;
  --slate-dark-rgb:  84, 96, 108;
  --slate-light-rgb: 167, 196, 220;
  --text-primary: #fff;
  --text-muted:   #c6daec;
  --border:       rgba(143, 208, 255, 0.2);
  --border-accent:    rgba(79, 179, 255, 0.42);
  --ease-out:     cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out:  cubic-bezier(0.77, 0, 0.175, 1);
}

/* ── Reset ──────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 112.5%; }
body {
  background: var(--bg-base);
  color: var(--text-primary);
  font-family: 'Montserrat', sans-serif;
  font-weight: 400;
  line-height: 1.75;
  overflow-x: clip;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

/* ── Scrollbar ───────────────────────────────── */
::-webkit-scrollbar { width: 3px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--accent-dark); border-radius: 2px; }

/* ── Grain overlay ───────────────────────────── */
.grain {
  position: fixed; inset: 0; z-index: 9998; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  opacity: 0.035;
}

/* ── Scroll reveal ───────────────────────────── */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity 400ms var(--ease-out), transform 400ms var(--ease-out); }
.js .reveal.in { opacity: 1; transform: none; }

/* ── Section common ──────────────────────────── */
.section { padding: 7rem 2rem; position: relative; overflow: hidden; }
.section--alt { background: var(--bg-elevated); }
.section-inner { max-width: 1180px; margin: 0 auto; }
.eyebrow {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.6rem; font-weight: 400;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--spark); margin-bottom: 0.9rem;
}
.section-title {
  font-family: 'Roboto Mono', monospace;
  font-size: clamp(1.8rem, 3.8vw, 3rem);
  font-weight: 400; line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--text-primary); margin-bottom: 1.2rem;
}
.section-rule {
  width: 44px; height: 1px;
  background: linear-gradient(90deg, var(--spark), transparent);
  margin-bottom: 1.6rem;
}
.section-lead {
  font-size: 0.95rem; font-weight: 300;
  color: var(--text-muted); max-width: 520px;
  line-height: 1.8;
}

/* ── Buttons ─────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: 'Roboto Mono', monospace;
  font-size: 0.7rem; font-weight: 400;
  letter-spacing: 0.14em; text-transform: uppercase;
  padding: 0.85rem 2rem; border-radius: 3px;
  transition: opacity 160ms var(--ease-out), transform 160ms var(--ease-out), box-shadow 200ms var(--ease-out), border-color 160ms var(--ease-out), color 160ms var(--ease-out);
  cursor: pointer; border: none;
  will-change: transform;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: linear-gradient(135deg, var(--accent-dark), var(--accent));
  color: #fff;
  box-shadow: 0 4px 20px rgba(var(--accent-rgb), 0.3);
}
.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border-accent);
}
@media (hover: hover) and (pointer: fine) {
  .btn:hover { opacity: 0.88; transform: translateY(-2px); }
  .btn:hover:active { transform: scale(0.97); }
  .btn-primary:hover { box-shadow: 0 8px 28px rgba(var(--accent-rgb), 0.45); }
  .btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
}

/* ════════════════════════════════════════════
   NAVIGATION
════════════════════════════════════════════ */
#nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  transition: background 220ms var(--ease-out), border-color 220ms var(--ease-out), backdrop-filter 220ms var(--ease-out);
}
#nav.scrolled {
  background: rgba(9,20,28,0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center; gap: 1.5rem;
  padding: 1.1rem 2rem;
}
.nav-logo {
  display: flex; align-items: center; gap: 0.7rem;
  flex-shrink: 0; margin-right: auto;
}
.nav-logo img { height: 62px; width: auto; }
.nav-links {
  display: flex; align-items: center; gap: 0.15rem;
  list-style: none;
}
.nav-links a {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.58rem; font-weight: 400;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-muted); padding: 0.4rem 0.6rem;
  border-radius: 2px;
  transition: color 180ms var(--ease-out), background 180ms var(--ease-out);
  position: relative;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -1px; left: 0.6rem; right: 0.6rem;
  height: 1px; background: var(--spark);
  transform: scaleX(0); transform-origin: left;
  transition: transform 220ms var(--ease-out);
}
.nav-links a.active { color: var(--text-primary); }
.nav-links a.active::after { transform: scaleX(1); }
.nav-ext {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.58rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--accent); padding: 0.4rem 0.8rem;
  border: 1px solid var(--border-accent); border-radius: 2px;
  transition: background 180ms var(--ease-out), color 180ms var(--ease-out);
  flex-shrink: 0;
}
@media (hover: hover) and (pointer: fine) {
  .nav-links a:hover { color: var(--text-primary); }
  .nav-links a:hover::after { transform: scaleX(1); }
  .nav-ext:hover { background: rgba(var(--accent-rgb), 0.1); }
}
.hamburger {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: none; padding: 4px; cursor: pointer;
}
.hamburger span {
  display: block; width: 22px; height: 1.5px;
  background: var(--text-muted);
  transition: transform 0.3s, opacity 0.3s;
}

/* ── Mobile drawer ───────────────────────────── */
#mobile-drawer {
  display: none; position: fixed; inset: 0; z-index: 99;
  background: var(--bg-base); flex-direction: column;
  align-items: center; justify-content: center; gap: 0.6rem;
  opacity: 0; transition: opacity 0.3s;
}
#mobile-drawer.open { display: flex; opacity: 1; }
#mobile-drawer a {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.75rem; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-muted); padding: 0.6rem 1rem;
  transition: color 0.2s;
}
#mobile-drawer a:hover { color: var(--accent); }
#drawer-close {
  position: absolute; top: 1.2rem; right: 1.5rem;
  background: none; border: none; color: var(--text-muted);
  font-size: 1.4rem; cursor: pointer;
  transition: color 0.2s;
}
#drawer-close:hover { color: var(--accent); }

/* ════════════════════════════════════════════
   SERVICIOS
════════════════════════════════════════════ */
#servicios { background: var(--bg-elevated); }
.svc-header { margin-bottom: 3.5rem; }

/* Features-4 bordered grid */
.feat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
}
.feat-cell {
  padding: 2.5rem 2rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transition: background 0.25s;
}
.feat-cell:hover { background: rgba(var(--slate-light-rgb), 0.03); }
.feat-icon-row {
  display: flex; align-items: center; gap: 0.55rem;
  margin-bottom: 0.8rem;
}
.feat-icon-row svg {
  width: 16px; height: 16px;
  color: var(--accent); flex-shrink: 0;
}
.feat-title {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.78rem; font-weight: 500;
  color: var(--text-primary);
}
.feat-desc {
  font-size: 0.9rem; color: var(--text-muted);
  line-height: 1.7;
}

/* ════════════════════════════════════════════
   FORGE FRAMEWORK
════════════════════════════════════════════ */
#framework { background: var(--bg-base); }
.forge-header { text-align: center; margin-bottom: 4rem; }
.forge-header .section-rule { margin: 0 auto 1.6rem; }
.forge-row {
  display: flex; gap: 0;
  position: relative;
}
.forge-row::before {
  content: '';
  position: absolute;
  top: 50%; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg,
    transparent 0%, rgba(var(--accent-rgb),0.25) 10%,
    rgba(var(--accent-rgb),0.25) 90%, transparent 100%);
  pointer-events: none; z-index: 0;
}
.forge-card {
  flex: 1; padding: 2.5rem 1.6rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 2px solid transparent;
  position: relative; overflow: hidden; z-index: 1;
  transition: border-top-color 0.3s, transform 0.35s, box-shadow 0.35s;
}
.forge-card + .forge-card { border-left: none; }
.forge-card:hover {
  border-top-color: var(--accent);
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(0,0,0,0.35);
  z-index: 2;
}
.forge-letter {
  position: absolute; bottom: -10px; right: 4px;
  font-family: 'Roboto Mono', monospace;
  font-size: clamp(80px, 10vw, 120px);
  font-weight: 500; line-height: 1;
  color: var(--accent);
  opacity: 0.055;
  pointer-events: none; user-select: none;
  transition: opacity 0.35s;
}
.forge-card:hover .forge-letter { opacity: 0.16; }
.forge-phase {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.52rem; letter-spacing: 0.2em;
  color: var(--accent); margin-bottom: 0.7rem;
  text-transform: uppercase;
}
.forge-name {
  font-family: 'Roboto Mono', monospace;
  font-size: 1.05rem; font-weight: 500;
  color: var(--text-primary); margin-bottom: 0.3rem;
  line-height: 1.3;
}
.forge-name-es {
  font-size: 0.7rem; color: var(--accent);
  font-family: 'Roboto Mono', monospace;
  letter-spacing: 0.08em; margin-bottom: 1rem;
}
.forge-desc {
  font-size: 0.9rem; color: var(--text-muted);
  line-height: 1.7;
}
#alliances { background: var(--bg-base); }
.cs-header { text-align: center; margin-bottom: 3.5rem; }
.cs-header .section-rule { margin: 0 auto 1.6rem; }
.cs-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 2px solid var(--border-accent);
  padding: 3rem 2.5rem;
  max-width: 820px; margin: 0 auto;
  position: relative; overflow: hidden;
  transition: border-top-color 0.3s, box-shadow 0.3s;
}
.cs-card:hover {
  border-top-color: var(--accent);
  box-shadow: 0 12px 40px rgba(0,0,0,0.3);
}
.cs-badge {
  display: inline-block;
  font-family: 'Roboto Mono', monospace;
  font-size: 0.5rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); border: 1px solid var(--border-accent);
  padding: 0.25rem 0.6rem; border-radius: 2px;
  margin-bottom: 1rem;
}
.cs-title {
  font-family: 'Roboto Mono', monospace;
  font-size: 1.15rem; font-weight: 500;
  color: var(--text-primary); margin-bottom: 0.6rem;
}
.cs-subtitle {
  font-size: 0.9rem; color: var(--text-muted);
  line-height: 1.7; margin-bottom: 2rem;
}
.cs-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px; margin-bottom: 2rem;
  background: var(--border);
}
.cs-metric {
  background: var(--bg-card);
  padding: 1.5rem 1rem;
  text-align: center;
}
.cs-metric-val {
  display: block;
  font-family: 'Roboto Mono', monospace;
  font-size: 1.6rem; font-weight: 500;
  color: var(--accent); margin-bottom: 0.4rem;
}
.cs-metric-lbl {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.55rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-muted);
}
.cs-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem; margin-bottom: 2rem;
}
.cs-body-title {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.6rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 0.6rem;
}
.cs-body-text {
  font-size: 0.9rem; color: var(--text-muted);
  line-height: 1.7;
}
.cs-quote {
  position: relative;
  font-style: italic; font-size: 0.95rem;
  color: var(--text-muted); line-height: 1.8;
  padding: 0.2rem 0 0.2rem 2.2rem;
}
.cs-quote::before {
  content: '\201C';
  position: absolute; left: 0; top: -0.4rem;
  font-family: 'Roboto Mono', monospace;
  font-style: normal;
  font-size: 2.4rem; line-height: 1;
  color: var(--accent);
  opacity: 0.8;
}
/* ════════════════════════════════════════════
   ALLIANCES
════════════════════════════════════════════ */
.allia-header { text-align: center; margin-bottom: 3.5rem; }
.allia-header .section-rule { margin: 0 auto 1.6rem; }
.allia-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem; max-width: 820px; margin: 0 auto;
}
.allia-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 2px solid var(--border-accent);
  padding: 2.5rem 2rem;
  position: relative; overflow: hidden;
  transition: border-top-color 220ms var(--ease-out), box-shadow 220ms var(--ease-out), transform 220ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .allia-card:hover {
    border-top-color: var(--accent);
    box-shadow: 0 12px 40px rgba(0,0,0,0.3);
    transform: translateY(-3px);
  }
}
.allia-logo {
  height: 36px; width: auto; max-width: 140px;
  object-fit: contain;
  background: #fff;
  padding: 6px 10px;
  border-radius: 4px;
  margin-bottom: 1.4rem;
}
/* Stretched-link: .allia-link::after covers entire .allia-card */
.allia-card { cursor: pointer; }
.allia-link::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
}
.allia-badge {
  display: inline-block;
  font-family: 'Roboto Mono', monospace;
  font-size: 0.5rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent); border: 1px solid var(--border-accent);
  padding: 0.25rem 0.6rem; border-radius: 2px;
  margin-bottom: 0.9rem;
}
.allia-name {
  font-family: 'Roboto Mono', monospace;
  font-size: 1.15rem; font-weight: 500;
  color: var(--text-primary); margin-bottom: 0.9rem;
}
.allia-desc {
  font-size: 0.9rem; color: var(--text-muted);
  line-height: 1.7; margin-bottom: 1.5rem;
}
.allia-link {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--accent);
  transition: letter-spacing 0.2s;
}
.allia-link:hover { letter-spacing: 0.18em; }
/* ════════════════════════════════════════════
   ABOUT
════════════════════════════════════════════ */
#about { background: var(--bg-base); }
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 5rem; align-items: start;
}
.about-left { display: flex; flex-direction: column; gap: 2.5rem; }
.about-mv { display: flex; flex-direction: column; gap: 2rem; }
.about-mv-label {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.55rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 0.5rem;
}
.about-mv-text {
  font-size: 0.88rem; color: var(--text-muted); line-height: 1.8;
}
.pillars-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1rem;
}
.pillar-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 2px solid var(--border-accent);
  padding: 1.3rem;
  transition: border-top-color 0.25s;
}
.pillar-card:hover { border-top-color: var(--accent); }
.pillar-card p {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.7rem; color: var(--text-muted);
  line-height: 1.6;
}
.founder-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 2.5rem;
}
.founder-name {
  font-family: 'Roboto Mono', monospace;
  font-size: 1.15rem; font-weight: 500;
  color: var(--text-primary); margin-bottom: 0.3rem;
}
.founder-title {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.6rem; letter-spacing: 0.12em;
  color: var(--accent); margin-bottom: 1.4rem;
}
.founder-bio {
  font-size: 0.88rem; color: var(--text-muted); line-height: 1.9;
  margin-bottom: 1.8rem;
}
.founder-stats {
  display: flex; gap: 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.founder-stat {
  flex: 1; padding: 1rem 0.5rem; text-align: center;
  border-right: 1px solid var(--border);
}
.founder-stat:last-child { border-right: none; }
.founder-stat-val {
  font-family: 'Roboto Mono', monospace;
  font-size: 1.3rem; font-weight: 500;
  color: var(--accent); display: block;
}
.founder-stat-lbl {
  font-size: 0.62rem; color: var(--text-muted);
  display: block; margin-top: 0.2rem;
}
.founder-career {
  margin-top: 1.8rem;
  display: flex; flex-direction: column; gap: 0.6rem;
}
.founder-career-label {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.55rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 0.3rem;
}
.career-item {
  display: flex; align-items: center; gap: 0.7rem;
  font-size: 0.78rem; color: var(--text-muted);
}
.career-item::before {
  content: '';
  width: 5px; height: 5px; border-radius: 50%;
  background: rgba(var(--accent-rgb), 0.5); flex-shrink: 0;
}

/* ════════════════════════════════════════════
   CONTACT
════════════════════════════════════════════ */
#contact { background: var(--bg-base); }
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.6fr; gap: 5rem;
  align-items: start;
}
.contact-info { display: flex; flex-direction: column; gap: 2rem; }
.contact-item {
  display: flex; flex-direction: column; gap: 0.3rem;
}
.contact-item-label {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.52rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--accent);
}
.contact-item-val {
  font-size: 0.88rem; color: var(--text-muted);
  transition: color 0.2s;
}
.contact-item-val:hover { color: var(--accent); }
.contact-form { display: flex; flex-direction: column; gap: 1.1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-label {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.54rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-muted);
}
.form-input, .form-select, .form-textarea {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 2px;
  padding: 0.75rem 1rem;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem; color: var(--text-primary);
  outline: none; width: 100%;
  transition: border-color 0.2s;
}
.form-input::placeholder, .form-textarea::placeholder { color: var(--text-muted); opacity: 0.5; }
.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--border-accent);
}
.form-select { appearance: none; cursor: pointer; }
.form-select option { background: var(--bg-card); }
.form-textarea { resize: vertical; min-height: 100px; }
.form-note {
  font-size: 0.72rem; color: var(--text-muted);
  font-style: italic;
}

/* ════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════ */
#footer {
  background: #060d14;
  border-top: 1px solid var(--border);
  padding: 4rem 2rem 2rem;
}
.footer-inner {
  max-width: 1180px; margin: 0 auto;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr; gap: 3rem;
  margin-bottom: 3rem;
}
.footer-brand img { height: 48px; margin-bottom: 1rem; opacity: 0.8; }
.footer-tagline {
  font-size: 0.78rem; color: var(--text-muted); max-width: 240px;
  line-height: 1.7; margin-bottom: 1.4rem;
}
.footer-socials { display: flex; gap: 0.6rem; }
.footer-social {
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  transition: border-color 0.2s, color 0.2s;
}
.footer-social:hover { border-color: var(--accent); color: var(--accent); }
.footer-col-title {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.6rem; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 1.2rem;
}
.footer-nav { display: flex; flex-direction: column; gap: 0.55rem; }
.footer-nav a {
  font-size: 0.8rem; color: var(--text-muted);
  transition: color 0.2s;
}
.footer-nav a:hover { color: var(--accent); }
.ppt-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: 'Roboto Mono', monospace;
  font-size: 0.6rem; letter-spacing: 0.1em;
  color: rgba(var(--accent-rgb), 0.4);
  border: 1px dashed rgba(var(--accent-rgb), 0.2);
  padding: 0.4rem 0.8rem; border-radius: 2px;
  margin-top: 0.6rem; cursor: default;
}
.footer-bottom {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem;
  padding-top: 2rem; border-top: 1px solid var(--border);
}
.footer-ga-link {
  display: flex; align-items: center; gap: 0.7rem;
  font-family: 'Roboto Mono', monospace;
  font-size: 0.55rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer-ga-link:hover { color: var(--accent); }
.footer-ga-link img { height: 22px; opacity: 0.5; }
.footer-copy {
  font-family: 'Roboto Mono', monospace;
  font-size: 0.55rem; letter-spacing: 0.1em;
  color: rgba(var(--slate-light-rgb), 0.35);
}

/* ── WhatsApp FAB ─────────────────────────── */
.wa-fab {
  position: fixed; bottom: 1.75rem; right: 1.75rem; z-index: 9000;
  width: 56px; height: 56px; border-radius: 50%;
  background: linear-gradient(135deg, #25d366, #128c7e);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 18px rgba(37,211,102,0.35);
  transition: transform 0.25s, box-shadow 0.25s;
  animation: wa-pulse 2.8s ease-in-out infinite;
}
.wa-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 28px rgba(37,211,102,0.5);
  animation-play-state: paused;
}
@keyframes wa-pulse {
  0%,100% { box-shadow: 0 4px 18px rgba(37,211,102,0.3); }
  50%      { box-shadow: 0 4px 28px rgba(37,211,102,0.55); }
}

/* ── Responsive ──────────────────────────── */
@media (max-width: 1024px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .forge-row { flex-direction: column; gap: 1px; }
  .forge-row::before { display: none; }
  .forge-card + .forge-card { border-left: 1px solid var(--border); border-top: none; }
  .about-grid { grid-template-columns: 1fr; gap: 3rem; }
  .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .allia-grid { grid-template-columns: 1fr; }
  .cs-body { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .section { padding: 5rem 1.5rem; }
  .nav-ext { display: none; }
  .form-row { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .pillars-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .cs-metrics { grid-template-columns: 1fr; }
  .cs-card { padding: 2rem 1.5rem; }
}
/* ── Section artwork ──────────────────────────────────── */
.section-art {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-repeat: no-repeat; background-position: right center;
  background-size: contain; opacity: 0.3;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, transparent 52%, rgba(0,0,0,0.5) 78%, #000 100%);
  mask-image: linear-gradient(to right, transparent 0%, transparent 52%, rgba(0,0,0,0.5) 78%, #000 100%);
}
.section-art--servicios { background-image: url('../images/consulting/servicios.webp'); }
.section-art--framework { background-image: url('../images/consulting/framework.webp');
  background-position: right bottom; background-size: 58% auto; opacity: 0.26; }
.section-art--proceso   { background-image: url('../images/consulting/proceso.webp'); }
.section--art { position: relative; overflow: hidden; }
.section--art > *:not(.section-art) { position: relative; z-index: 1; }
@media (max-width: 900px) {
  .section-art { opacity: 0.16; background-size: cover; background-position: center;
    -webkit-mask-image: none; mask-image: none; }
}

/* ── Mobile: the About column would not shrink below its
     content, so the section was being clipped ─────────── */
.about-left, .about-right { min-width: 0; }
.founder-stat { min-width: 0; }
@media (max-width: 560px) {
  .founder-card { padding: 1.75rem 1.25rem; }
  .founder-stats { flex-wrap: wrap; }
  .founder-stat { flex: 1 1 33%; border-right: none; }
  .founder-stat-lbl { font-size: 0.58rem; }
}

#mobile-drawer .drawer-lang {
  margin-top: 1.5rem; padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  font-family: 'Roboto Mono', monospace; font-size: 0.7rem;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--spark);
}
/* ════════════════════════════════════════════
   SERVICIOS · riel arrastrable (≤1024px)
   Mismo .feat-grid: 5+4 tarjetas en desktop,
   riel horizontal con snap debajo.
════════════════════════════════════════════ */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap; border: 0;
}

@media (max-width: 1024px) {
  .feat-grid {
    --rail-pad:  2rem;              /* == padding lateral de .section */
    --rail-gap:  1rem;
    --rail-card: clamp(18rem, 44vw, 23rem);

    display: flex;
    grid-template-columns: none;
    gap: var(--rail-gap);
    align-items: stretch;

    border: none;
    border-radius: 0;
    overflow: auto hidden;

    /* sangra hasta el borde de la sección, pero la primera tarjeta
       sigue alineada con el titular */
    margin-inline: calc(var(--rail-pad) * -1);
    padding-inline: var(--rail-pad);
    scroll-padding-inline: var(--rail-pad);
    padding-block: 2px;

    scroll-snap-type: x mandatory;
    scroll-behavior: auto;          /* la inercia escribe scrollLeft directo */
    overscroll-behavior-x: contain; /* corta el swipe-atrás de iOS */
    -webkit-overflow-scrolling: touch;

    scrollbar-width: none;
    -ms-overflow-style: none;
  }
  .feat-grid::-webkit-scrollbar { display: none; }

  .feat-grid .feat-cell {
    flex: 0 0 var(--rail-card);
    min-width: 0;
    padding: 2.25rem 1.6rem;
    border: 1px solid var(--border);
    border-radius: 4px;
    scroll-snap-align: start;
  }
  /* con snap mandatory, garantiza que el final del riel sea alcanzable */
  .feat-grid .feat-cell:last-child { scroll-snap-align: end; }

  /* El IntersectionObserver del reveal nunca ve las tarjetas que están
     fuera del viewport en horizontal. Dentro del riel se desactiva: si no,
     entran vacías y animan en vertical durante un gesto horizontal. */
  .feat-grid .feat-cell.reveal,
  .feat-grid .feat-cell.reveal.in {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .feat-grid.is-draggable { cursor: grab; }
  .feat-grid.is-dragging {
    cursor: grabbing;
    user-select: none;
    -webkit-user-select: none;
    scroll-snap-type: none;            /* se reengancha al soltar */
  }
  
  /* anillo interior: .section recorta con overflow:hidden */
  .feat-grid:focus { outline: none; }
  .feat-grid:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: -2px;
    border-radius: 4px;
    box-shadow: inset 0 0 0 5px rgba(var(--accent-rgb), 0.14);
  }
}
@media (max-width: 768px) {
  .feat-grid { --rail-pad: 1.5rem; --rail-card: min(76vw, 18rem); }
}
@media (max-width: 480px) {
  .feat-grid { --rail-card: min(80vw, 17rem); }
  .feat-grid .feat-cell { padding: 2rem 1.4rem; }
}

/* ════════════════════════════════════════════
   Cursor contextual — solo puntero fino
   El punto se mueve en el propio evento del
   ratón (sin esperar al fotograma). El anillo
   lo persigue interpolado: ahí el retraso es
   el efecto, no un defecto.
   Los estados animan SOLO `scale`, nunca
   width/height: cambiar tamaño fuerza layout
   en cada fotograma y eso es lo que se siente
   como tirón.
════════════════════════════════════════════ */
@media (hover: hover) and (pointer: fine) {
  body.cc-on,
  body.cc-on a,
  body.cc-on button,
  body.cc-on [role="button"],
  body.cc-on summary { cursor: none; }
  /* los campos conservan su I-beam: escribir sin cursor es hostil */
  body.cc-on input,
  body.cc-on textarea,
  body.cc-on select { cursor: auto; }

  .cc {
    position: fixed; top: 0; left: 0; z-index: 9999;
    pointer-events: none;
    opacity: 0; transition: opacity 0.2s var(--ease-out);
    /* contain aísla el elemento del resto del árbol: sus repintados
       no invalidan nada más de la página */
    contain: layout style paint;
  }
  body.cc-ready .cc { opacity: 1; }

  .cc-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--accent);
    will-change: transform;
    transition: opacity 0.18s var(--ease-out);
  }

  /* caja de tamaño FIJO: nunca cambia, así no hay layout */
  .cc-ring {
    display: grid; place-items: center;
    width: 84px; height: 84px;
    will-change: transform;
  }
  /* el círculo visible es lo único que escala */
  .cc-ring-fill {
    grid-area: 1 / 1;
    width: 84px; height: 84px; border-radius: 50%;
    border: 2px solid rgba(var(--accent-rgb), 0.5);
    transform: scale(0.452);          /* 38px efectivos */
    will-change: transform;
    transition: transform 0.26s var(--ease-out),
                background-color 0.26s var(--ease-out),
                border-color 0.26s var(--ease-out);
  }

  body[data-cc="link"] .cc-ring-fill {
    transform: scale(0.667);          /* 56px */
    background: rgba(var(--accent-rgb), 0.14);
    border-color: var(--accent);
  }
  body[data-cc="link"] .cc-dot { opacity: 0; }

  body[data-cc="drag"] .cc-ring-fill {
    transform: scale(1);              /* 84px */
    background: var(--accent);
    border-color: var(--accent);
  }
  body[data-cc="drag"] .cc-dot { opacity: 0; }
  /* al arrastrar el disco se encoge: feedback físico del gesto */
  body[data-cc="drag"].cc-dragging .cc-ring-fill { transform: scale(0.762); }

  .cc-label {
    grid-area: 1 / 1;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.55rem; letter-spacing: 0.14em;
    text-transform: uppercase; color: var(--bg-base);
    opacity: 0; transition: opacity 0.18s var(--ease-out);
    white-space: nowrap; user-select: none;
  }
  body[data-cc="drag"] .cc-label { opacity: 1; }
}

/* ════════════════════════════════════════════
   prefers-reduced-motion — cobertura global
════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal, .js .reveal.in {
    opacity: 1; transform: none;
    transition: none; transition-delay: 0s !important;
  }
  .feat-grid { scroll-behavior: auto; }
  .feat-grid .feat-cell { transition: none; }
  .cc { display: none !important; }
  body.cc-on, body.cc-on * { cursor: auto !important; }
  .wa-fab { animation: none !important; }
}

/* ════════════════════════════════════════════
   AI CONSULTING LAYER
   Everything below belongs to the AI redesign.
════════════════════════════════════════════ */
html { scroll-padding-top: 5.5rem; }
body.no-scroll { overflow: hidden; }
:focus-visible { outline: 2px solid var(--spark); outline-offset: 3px; border-radius: 2px; }
.form-input:focus-visible, .form-select:focus-visible, .form-textarea:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 0;
}
.skip-link {
  position: fixed; top: 0.5rem; left: 0.5rem; z-index: 10000;
  padding: 0.6rem 1rem; background: var(--bg-card); color: var(--text-primary);
  font-family: 'Roboto Mono', monospace; font-size: 0.7rem;
  transform: translateY(-200%); transition: transform 160ms var(--ease-out);
}
.skip-link:focus { transform: none; }
.section-inner--wide { max-width: 1380px; }
.form-status {
  margin-top: 0.75rem; padding: 0.75rem 1rem; border-radius: 4px;
  font-size: 0.82rem; border: 1px solid transparent;
}
.form-status.is-ok { color: #25d366; border-color: rgba(37,211,102,0.28); background: rgba(37,211,102,0.07); }
.form-status.is-err { color: #ff8a7a; border-color: rgba(231,76,60,0.28); background: rgba(231,76,60,0.07); }
.form-input:user-invalid, .form-textarea:user-invalid { border-color: #e5604d; }
.btn:disabled { opacity: 0.65; cursor: wait; }

/* the hero already shows the full mark: the nav one arrives with the scroll */
.nav-logo { transition: opacity 220ms var(--ease-out); }
#nav:not(.scrolled) .nav-logo { opacity: 0; pointer-events: none; }
@media (max-width: 1024px) { #nav:not(.scrolled) { background: none; } }

/* Drawer: real fade, above the fixed nav */
#mobile-drawer {
  display: flex; visibility: hidden; z-index: 110; overflow-y: auto;
  transition: opacity 0.25s var(--ease-out), visibility 0.25s;
}
#mobile-drawer.open { visibility: visible; opacity: 1; transition: opacity 0.25s var(--ease-out), visibility 0s; }
#mobile-drawer a { padding: 0.8rem 1rem; }
#drawer-close { padding: 0.5rem 0.75rem; }
.hamburger { padding: 10px; margin-right: -10px; }
@media (min-width: 1025px) { #mobile-drawer { display: none; } }

/* ── Hero ─────────────────────────────────────
   The stage keeps the plate's aspect ratio and covers the viewport, so
   every overlay stays glued to the arc and the podium at any size. */
#hero {
  --px: 0; --py: 0;
  position: relative; overflow: hidden; isolation: isolate;
  min-height: 100svh; background: var(--bg-base);
  display: grid; place-items: center;
}
.hero-stage {
  position: absolute; left: 50%; top: 50%; z-index: -2;
  width: max(100%, 177.7vh); aspect-ratio: 1672 / 941;
  transform: translate(-50%, -50%);
}
.hero-plate { width: 100%; height: 100%; object-fit: cover; }
.hero-net { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0.75; mix-blend-mode: screen; }
.hero-fx { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.hero-fx path, .hero-fx ellipse { fill: none; stroke-linecap: round; stroke-dasharray: 0.12 0.88; }
.fx-arc { stroke: #ffe3bd; stroke-width: 3.5; filter: drop-shadow(0 0 7px #f69642); animation: fx-run 7s linear infinite; }
.fx-ring { stroke: #fff1dc; stroke-width: 3; filter: drop-shadow(0 0 8px #f69642); animation: fx-run 5s linear infinite; }
.fx-ring--in { stroke: #bfe2ff; filter: drop-shadow(0 0 7px #5b9ad0); animation-duration: 3.8s; animation-direction: reverse; }
.fx-trace { stroke: #a9d7ff; stroke-width: 2.4; filter: drop-shadow(0 0 5px #5b9ad0); animation: fx-run 3.2s linear infinite; }
.fx-trace--2 { animation-delay: -1s; }
.fx-trace--3 { animation-delay: -2.1s; }
@keyframes fx-run { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
.hero-beam {
  position: absolute; left: 50%; top: 36%; width: 20%; height: 42%;
  transform: translateX(-50%); transform-origin: 50% 100%;
  background: radial-gradient(ellipse 45% 100% at 50% 100%, rgba(120,190,255,0.3), transparent 72%);
  animation: beam 5s ease-in-out infinite alternate;
}
@keyframes beam { from { opacity: 0.45; transform: translateX(-50%) scaleY(0.92); } to { opacity: 1; transform: translateX(-50%) scaleY(1.05); } }
.hero-shade {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse 32% 34% at 50% 44%, rgba(9,20,28,0.72), transparent 76%),
    linear-gradient(to bottom, rgba(9,20,28,0.55), transparent 16%, transparent 84%, var(--bg-base));
}
#hero:not(.is-live) .hero-fx *, #hero:not(.is-live) .hero-beam { animation-play-state: paused; }

.hero-content {
  --u: min(1vw, 1.78vh);
  width: min(46 * var(--u), 92vw);
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding-top: calc(5.2 * var(--u));
  animation: hero-rise 0.9s 0.15s both var(--ease-out);
}
@keyframes hero-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.hero-eyebrow {
  font-family: 'Roboto Mono', monospace; font-size: 0.58rem; letter-spacing: 0.24em;
  text-transform: uppercase; color: var(--spark); margin-bottom: 0.9rem;
}
.hero-mark { width: min(23 * var(--u), 64vw); margin-bottom: 1rem; }
.hero-logo { display: block; width: 100%; height: auto; overflow: visible; filter: drop-shadow(0 6px 26px rgba(9,20,28,0.9)); }
.logo-ring { stroke-dasharray: 1; animation: logo-draw 1.5s 0.25s both var(--ease-in-out); }
.logo-arc {
  stroke-dasharray: 1; filter: drop-shadow(0 0 6px rgba(234,122,42,0.75));
  animation: logo-draw 0.7s 1.45s both var(--ease-out), logo-glow 3.6s 2.2s ease-in-out infinite alternate;
}
.logo-word { animation: logo-fade 0.9s 0.8s both var(--ease-out); }
@keyframes logo-draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes logo-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes logo-glow { from { opacity: 0.8; } to { opacity: 1; } }
.hero-title {
  font-family: 'Roboto Mono', monospace; font-weight: 400;
  font-size: clamp(1.25rem, calc(2.5 * var(--u)), 2.4rem);
  line-height: 1.2; letter-spacing: -0.015em; text-wrap: balance;
  max-width: calc(36 * var(--u));
  text-shadow: 0 2px 22px rgba(9,20,28,0.95);
}
.hero-desc {
  margin-top: 0.8rem; max-width: calc(34 * var(--u));
  font-size: 0.82rem; font-weight: 400; line-height: 1.65; color: var(--text-primary);
  text-shadow: 0 1px 14px rgba(9,20,28,0.95);
}
.hero-ctas { display: flex; gap: 0.8rem; flex-wrap: wrap; justify-content: center; margin-top: 1.15rem; }
#hero .btn { backdrop-filter: blur(6px); }
#hero .btn-ghost { background: rgba(9,20,28,0.55); color: var(--text-primary); }

.hero-cards { position: absolute; inset: 0; pointer-events: none; perspective: 1400px; display: grid; place-items: center; }
.hero-card {
  --tilt: 14deg; --u: min(1vw, 1.78vh); --dx: 1; --dy: 1;
  position: absolute; left: 50%; top: 50%;
  width: calc(16.5 * var(--u));
  transform:
    translate(-50%, -50%)
    translate(calc(var(--cx) * var(--u) + var(--px) * var(--dx) * 22px), calc(var(--cy) * var(--u) + var(--py) * var(--dy) * 22px))
    rotateY(var(--tilt));
  transition: transform 500ms var(--ease-out);
}
.hero-card--1 { --cx: -29; --cy: -13.5; --dx: 0.8; }
.hero-card--2 { --cx: 29; --cy: -13.5; --tilt: -14deg; --dx: 0.8; }
.hero-card--3 { --cx: -38; --cy: 3.5; --dx: 1.5; --dy: 1.4; }
.hero-card--4 { --cx: 38; --cy: 3.5; --tilt: -14deg; --dx: 1.5; --dy: 1.4; }
.hero-card-inner {
  position: relative; overflow: hidden; text-align: center;
  padding: 1.15rem 0.8rem 1.25rem; border-radius: 22px;
  background: linear-gradient(155deg, rgba(120,160,190,0.16), rgba(12,26,36,0.52) 58%);
  border: 1px solid rgba(214,190,150,0.3);
  backdrop-filter: blur(9px) saturate(1.2);
  box-shadow: 0 24px 60px rgba(3,10,16,0.55), inset 0 1px 0 rgba(255,235,205,0.28);
  animation: card-float 7s ease-in-out infinite alternate;
}
.hero-card--2 .hero-card-inner { animation-delay: -2.5s; }
.hero-card--3 .hero-card-inner { animation-delay: -4s; }
.hero-card--4 .hero-card-inner { animation-delay: -1.2s; }
.hero-card-inner::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 38%, rgba(255,240,215,0.2) 50%, transparent 62%);
  transform: translateX(-110%); animation: card-sheen 8s ease-in-out infinite;
}
.hero-card--2 .hero-card-inner::after { animation-delay: 2s; }
.hero-card--3 .hero-card-inner::after { animation-delay: 4s; }
.hero-card--4 .hero-card-inner::after { animation-delay: 6s; }
@keyframes card-float { from { transform: translateY(-5px); } to { transform: translateY(7px); } }
@keyframes card-sheen { 0%, 62% { transform: translateX(-110%); } 80%, 100% { transform: translateX(110%); } }
.hero-card svg { width: calc(4.6 * var(--u)); height: auto; margin: 0 auto 0.45rem; overflow: visible; }
.hero-card p {
  font-family: 'Montserrat', sans-serif; font-weight: 600; line-height: 1.22;
  font-size: clamp(0.58rem, calc(1.08 * var(--u)), 0.86rem); color: #f3f7fa;
}
.hero-card p::after {
  content: ''; display: block; width: 44%; height: 1px; margin: 0.55rem auto 0;
  background: linear-gradient(90deg, transparent, #d6a56e, transparent);
}
.ico-gear { animation: spin 14s linear infinite; }
.ico-gear--rev { animation-direction: reverse; animation-duration: 11s; }
@keyframes spin { to { transform: rotate(360deg); } }
.ico-bar { transform-box: fill-box; transform-origin: 50% 100%; animation: bar-up 1s 1.1s both var(--ease-out); }
.ico-bar:nth-child(2) { animation-delay: 1.2s; }
.ico-bar:nth-child(3) { animation-delay: 1.3s; }
.ico-bar:nth-child(4) { animation-delay: 1.4s; }
@keyframes bar-up { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.ico-arrow { stroke-dasharray: 100; animation: ico-draw 1.4s 1.5s both var(--ease-out); }
@keyframes ico-draw { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }

@media (max-width: 1024px) {
  #hero { --stage-h: max(150vw, 100svh); display: block; min-height: 0; padding: 6.2rem 1.25rem 3.5rem; }
  .hero-stage { top: 0; transform: translateX(-50%); width: max(100%, 66.6svh); aspect-ratio: 1024 / 1536; }
  .hero-fx--wide { display: none; }
  .hero-beam { display: none; }
  .hero-shade {
    background:
      radial-gradient(ellipse 72% 34% at 50% 36%, rgba(9,20,28,0.78), transparent 78%),
      linear-gradient(to bottom, transparent calc(var(--stage-h) * 0.8), var(--bg-base) var(--stage-h));
  }
  /* the copy fills the arc; the cards start under the podium of the plate */
  .hero-content {
    width: 100%; max-width: 34rem; margin: 0 auto; padding-top: 0;
    min-height: calc(var(--stage-h) * 0.85 - 6.2rem);
  }
  .hero-mark { width: min(62vw, 300px); }
  .hero-title { font-size: clamp(1.3rem, 5.6vw, 1.9rem); max-width: none; }
  .hero-desc { font-size: 0.86rem; max-width: 30rem; }
  /* the cards land under the podium */
  .hero-cards {
    position: relative; inset: auto; perspective: none;
    display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem;
    place-items: stretch;
    width: 100%; max-width: 34rem; margin: 0.5rem auto 0;
  }
  .hero-card { position: relative; left: auto; top: auto; width: auto; transform: none; transition: none; }
  .hero-card-inner { height: 100%; padding: 1rem 0.6rem; border-radius: 16px; animation: none; }
  .hero-card svg { width: 3rem; }
  .hero-card p { font-size: 0.72rem; }
}
@media (min-width: 640px) and (max-width: 1024px) {
  .hero-cards { grid-template-columns: repeat(4, 1fr); max-width: 46rem; }
}
@media (max-width: 480px) {
  .hero-ctas { flex-direction: column; width: 100%; }
  .hero-ctas .btn { justify-content: center; text-align: center; }
}

/* ── Servicios ────────────────────────────────
   Nine equal cards in two rows (5 + 4, the second centred). A beam of
   light visits them one by one. */
#servicios {
  background:
    radial-gradient(ellipse 58% 42% at 88% 0%, rgba(30,144,255,0.22), transparent 70%),
    radial-gradient(ellipse 40% 34% at 0% 100%, rgba(var(--spark-rgb),0.1), transparent 70%),
    radial-gradient(rgba(143,208,255,0.16) 1px, transparent 1.5px) 0 0 / 26px 26px,
    var(--bg-elevated);
}
.feat-grid { gap: 0.9rem; border: none; border-radius: 0; overflow: visible; }
.feat-cell {
  position: relative; isolation: isolate; overflow: hidden; padding: 1.5px;
  display: flex; flex-direction: column;
  border: 0; border-radius: 12px; background: #1d5596;
  box-shadow: 0 20px 40px -22px rgba(1,8,20,0.95);
  transition: opacity 600ms var(--ease-out), transform 700ms var(--ease-out), box-shadow 220ms var(--ease-out);
}
.feat-cell:hover { background: #1d5596; }
.feat-cell::before { /* the beam: spins behind the content, shows through the 1.5px rim */
  content: ''; position: absolute; z-index: 0; left: 50%; top: 50%; width: 320%; aspect-ratio: 1;
  margin: -160% 0 0 -160%; opacity: 0;
  background: conic-gradient(transparent 0 58%, #2e9bff 76%, #fff 84%, #ff8a2e 92%, transparent 100%);
  animation: svc-spin 2.2s linear infinite, svc-turn 9.9s linear infinite;
  animation-delay: 0s, calc(var(--turn) * 1.1s);
}
@keyframes svc-spin { to { transform: rotate(360deg); } }
@keyframes svc-turn { 0%, 30%, 100% { opacity: 0; } 5%, 22% { opacity: 1; } }
.svc-media {
  position: relative; z-index: 1; flex: none; overflow: hidden; aspect-ratio: 16 / 10;
  border-radius: 10.5px 10.5px 0 0; background: #030b14;
}
.svc-stage {
  position: absolute; inset: 0;
  animation: svc-float 8s ease-in-out infinite alternate; animation-delay: calc(var(--turn) * -1.3s);
}
@keyframes svc-float { from { transform: translate3d(0, -1.8%, 0) scale(1.06); } to { transform: translate3d(0, 1.8%, 0) scale(1.1); } }
.svc-stage img { width: 100%; height: 100%; object-fit: cover; }
.svc-ov { position: absolute; inset: 0; width: 100%; height: 100%; }
.svc-media::after { /* scan bar that crosses the screen on the card's turn */
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 30%; z-index: 2; pointer-events: none;
  background: linear-gradient(to bottom, transparent, rgba(120,195,255,0.42) 88%, #bfe3ff);
  transform: translateY(-110%);
  animation: svc-scan 9.9s var(--ease-in-out) infinite; animation-delay: calc(var(--turn) * 1.1s);
}
@keyframes svc-scan { 0% { transform: translateY(-110%); } 18%, 100% { transform: translateY(350%); } }
/* !important: the `animation` shorthands below reset play-state to running */
.feat-cell::before, .svc-stage, .svc-media::after, .svc-ov * { animation-play-state: paused !important; }
.feat-cell.is-live::before, .feat-cell.is-live .svc-stage, .feat-cell.is-live .svc-media::after, .feat-cell.is-live .svc-ov * { animation-play-state: running !important; }

/* overlays: light that runs over the shapes of each image */
.sv-run path { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 0.14 0.86; animation: fx-run var(--t) linear infinite; animation-delay: var(--dl); }
.sv-run--long path { stroke-dasharray: 0.3 0.7; }
.sv-halo { stroke-width: 15; opacity: 0.26; }
.sv-core { stroke-width: 4.5; }
.sv-run--b .sv-halo { stroke: #49b0ff; } .sv-run--b .sv-core { stroke: #dff2ff; }
.sv-run--o .sv-halo { stroke: #ff8a2e; } .sv-run--o .sv-core { stroke: #fff0dc; }
.sv-node { transform-box: fill-box; transform-origin: center; animation: sv-blink 1.9s ease-in-out infinite alternate; animation-delay: var(--dl); }
.sv-node--b { fill: #bfe6ff; } .sv-node--o { fill: #ffc48f; }
@keyframes sv-blink { from { opacity: 0.35; transform: scale(0.7); } to { opacity: 1; transform: scale(1.5); } }
.sv-ripple { fill: none; stroke-width: 2.5; transform-box: fill-box; transform-origin: center; animation: sv-ripple var(--t) ease-out infinite; animation-delay: var(--dl); }
.sv-ripple--b { stroke: #8fd0ff; } .sv-ripple--o { stroke: #ffb26e; }
@keyframes sv-ripple { from { opacity: 0.85; transform: scale(0.72); } to { opacity: 0; transform: scale(1.5); } }
.sv-gear { fill: none; stroke: #bfe6ff; stroke-width: 8; opacity: 0.6; transform-box: fill-box; transform-origin: center; animation: spin var(--t) linear infinite; }
.sv-gear--rev { animation-direction: reverse; }
.sv-sweep { fill: rgba(120,200,255,0.3); animation: spin 4.5s linear infinite; }
.sv-sweep--o { fill: rgba(255,150,70,0.24); animation: sv-gauge 2.6s ease-in-out infinite alternate; }
@keyframes sv-gauge { from { transform: rotate(-58deg); } to { transform: rotate(26deg); } }
.sv-pane { fill: rgba(120,200,255,0.14); stroke: #9fd8ff; stroke-width: 2; animation: sv-pane 3.6s ease-in-out infinite; animation-delay: var(--dl); }
@keyframes sv-pane { 0%, 100% { opacity: 0; } 18%, 34% { opacity: 1; } 56% { opacity: 0; } }
.sv-line { fill: #e4f4ff; transform-box: fill-box; transform-origin: 0 50%; animation: sv-type 3s var(--ease-out) infinite; animation-delay: var(--dl); }
@keyframes sv-type { 0% { transform: scaleX(0); opacity: 0; } 30%, 78% { transform: scaleX(1); opacity: 0.92; } 100% { transform: scaleX(1); opacity: 0; } }
.sv-bar { fill: #ffc48f; transform-box: fill-box; transform-origin: 50% 100%; animation: sv-bar 3s var(--ease-out) infinite; animation-delay: var(--dl); }
@keyframes sv-bar { 0% { transform: scaleY(0); } 30%, 80% { transform: scaleY(1); opacity: 0.95; } 100% { transform: scaleY(1); opacity: 0; } }
.sv-orbit { fill: none; stroke: rgba(170,222,255,0.45); stroke-width: 2; stroke-dasharray: 5 9; }
.sv-orbit-rot { animation: sv-orbit 4.4s linear infinite; }
@keyframes sv-orbit { /* an ellipse: scale the circle's radius by 74/252 */
  from { transform: scaleY(0.294) rotate(0deg); } to { transform: scaleY(0.294) rotate(360deg); }
}

.svc-body { position: relative; z-index: 1; flex: 1; display: flex; flex-direction: column; padding: 0.7rem 0.85rem 0.85rem; border-radius: 0 0 10.5px 10.5px; background: linear-gradient(170deg, #0d3264, var(--bg-card) 70%); }
.svc-num { font-family: 'Roboto Mono', monospace; font-size: 0.58rem; font-weight: 500; letter-spacing: 0.18em; color: var(--spark); margin-bottom: 0.2rem; }
.feat-title { font-size: 0.78rem; font-weight: 600; margin-bottom: 0.4rem; line-height: 1.3; }
.feat-desc { font-size: 0.68rem; line-height: 1.55; color: var(--text-muted); margin-bottom: 0.7rem; }
.svc-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 0.25rem; margin-top: auto; }
.svc-chips li {
  font-family: 'Roboto Mono', monospace; font-size: 0.52rem; letter-spacing: 0.02em; line-height: 1.35;
  color: #bfe3ff; padding: 0.14rem 0.4rem; border-radius: 3px;
  border: 1px solid var(--border-accent); background: rgba(var(--accent-rgb),0.07);
}
@media (min-width: 1025px) {
  #servicios .section-inner { max-width: 1340px; }
  #servicios { padding-block: 5.5rem 4.5rem; }
  .svc-header { display: grid; grid-template-columns: 1fr 1fr; align-items: end; gap: 0 3rem; margin-bottom: 2rem; }
  .svc-header .eyebrow, .svc-header .section-rule { grid-column: 1; }
  .svc-header .section-title { grid-column: 1; margin-bottom: 0.8rem; }
  .svc-header .section-rule { margin-bottom: 0; }
  .svc-header .section-lead { grid-column: 2; grid-row: 1 / span 3; justify-self: end; }
  .feat-grid { grid-template-columns: repeat(10, minmax(0, 1fr)); grid-auto-rows: 1fr; }
  .feat-cell { grid-column: span 2; }
  .feat-cell:nth-child(6) { grid-column: 2 / span 2; }
  /* entrance: the cards deal themselves out one after another */
  .js .feat-cell.reveal { transform: translateY(38px) scale(0.93); transition-delay: calc(var(--turn) * 75ms); }
  .js .feat-cell.reveal.in { transform: none; }
  .js .feat-cell.reveal .svc-ov { opacity: 0; transition: opacity 700ms var(--ease-out) calc(var(--turn) * 75ms + 450ms); }
  .js .feat-cell.reveal.in .svc-ov { opacity: 1; }
  .js .feat-cell.is-settled { transition: transform 180ms var(--ease-out), box-shadow 220ms var(--ease-out); transition-delay: 0s; }
  .js .feat-cell.reveal.in.is-tilting {
    z-index: 3; transform: perspective(900px) rotateX(var(--svc-rx, 0deg)) rotateY(var(--svc-ry, 0deg)) translateY(-6px) scale(1.02);
    box-shadow: 0 34px 60px -16px rgba(1,8,20,0.95), 0 0 40px rgba(30,144,255,0.35);
  }
}
@media (min-width: 1025px) and (max-width: 1279px) {
  .svc-chips { display: none; }
  .feat-desc { margin-bottom: 0; }
}
@media (hover: hover) and (pointer: fine) {
  .feat-cell:hover::before { animation: svc-spin 2.2s linear infinite; opacity: 1; }
}
@media (max-width: 1024px) {
  .feat-grid { gap: var(--rail-gap); overflow: auto hidden; padding-block: 2px 1.6rem; }
  .feat-grid .feat-cell { padding: 1.5px; border: 0; border-radius: 12px; }
  .feat-grid .feat-cell.reveal, .feat-grid .feat-cell.reveal.in { transition: none; }
  .svc-body { padding: 0.9rem 1rem 1rem; }
  .feat-title { font-size: 0.9rem; }
  .feat-desc { font-size: 0.8rem; }
}
@media (max-width: 480px) { .feat-grid .feat-cell { padding: 1.5px; } }

/* ── Proceso ──────────────────────────────── */
#engagement.proc {
  overflow: visible;
  background:
    radial-gradient(ellipse 50% 40% at 15% 20%, rgba(var(--accent-rgb),0.08), transparent 70%),
    var(--bg-base);
}
.eng-header { display: grid; gap: 0.2rem; margin-bottom: 2.5rem; }
.proc-rail { display: none; }
.proc-list { list-style: none; position: relative; display: grid; gap: 2.5rem; padding-left: 1.6rem; }
.proc-list::before, .proc-list::after {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: rgba(var(--slate-light-rgb),0.14);
}
.proc-list::after {
  background: linear-gradient(to bottom, var(--accent), var(--spark));
  transform: scaleY(var(--p, 0)); transform-origin: top;
  box-shadow: 0 0 12px rgba(var(--accent-rgb),0.6);
}
#engagement { --p: 0; --u: 0; }
.proc-item { position: relative; display: grid; gap: 1.1rem; }
.proc-item::before {
  content: ''; position: absolute; left: calc(-1.6rem - 4px); top: 0.3rem;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--bg-base); border: 2px solid rgba(var(--slate-light-rgb),0.4);
  transition: background 240ms var(--ease-out), border-color 240ms var(--ease-out);
}
.proc-item.is-active::before { background: var(--spark); border-color: var(--spark); }
.proc-fig {
  position: relative; overflow: hidden; margin: 0; aspect-ratio: 3 / 2; border-radius: 10px;
  border: 1px solid var(--border-accent); background: #081219;
  box-shadow: 0 24px 64px rgba(3,10,16,0.5), 0 0 40px rgba(var(--accent-rgb),0.08);
}
.proc-fig img { width: 100%; height: 100%; object-fit: cover; transform: scale(calc(1.03 + var(--u) * 0.07)); }
.proc-fig::after { /* HUD frame */
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(9,20,28,0.7), transparent 34%);
}
.proc-ov { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; transform: scale(calc(1.03 + var(--u) * 0.07)); }
.proc-ov * { animation-play-state: paused !important; }
.proc-item.is-active .proc-fig.is-live .proc-ov * { animation-play-state: running !important; }
.proc-hud {
  position: absolute; z-index: 2; left: 0.8rem; bottom: 0.6rem;
  font-family: 'Roboto Mono', monospace; font-size: 0.54rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: #cfe4f2;
}
.proc-label { font-family: 'Roboto Mono', monospace; font-size: 0.58rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--spark); margin-bottom: 0.5rem; }
.proc-copy h3 { font-family: 'Roboto Mono', monospace; font-weight: 500; font-size: 1.1rem; line-height: 1.3; margin-bottom: 0.7rem; }
.proc-desc { font-size: 0.88rem; color: var(--text-muted); line-height: 1.75; margin-bottom: 0.9rem; }
.proc-deliverable { font-size: 0.8rem; color: var(--text-primary); line-height: 1.55; padding-left: 0.8rem; border-left: 2px solid var(--spark); }
.proc-deliverable span { display: block; font-family: 'Roboto Mono', monospace; font-size: 0.52rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); }
.proc-foot { margin-top: 2rem; font-size: 0.82rem; color: var(--text-muted); }
.proc-foot a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

/* overlays: Claude's animation layer over each Codex image */
.ov-wave rect { fill: #9fd3ff; transform-box: fill-box; transform-origin: 50% 50%; animation: ov-wave 1.5s ease-in-out infinite alternate; animation-delay: calc(var(--i) * -0.13s); opacity: 0.8; }
@keyframes ov-wave { from { transform: scaleY(0.12); } to { transform: scaleY(1); } }
.ov-scan { animation: ov-scan 3.4s ease-in-out infinite alternate; }
.ov-scan-plane { fill: #bfe3ff; filter: drop-shadow(0 0 7px #5b9ad0); }
.ov-scan-glow { fill: rgba(91,154,208,0.16); }
@keyframes ov-scan { from { transform: translateY(70px); } to { transform: translateY(330px); } }
.ov-hot circle { fill: #ea7a2a; filter: drop-shadow(0 0 8px #ea7a2a); transform-box: fill-box; transform-origin: center; animation: ov-hot 1.6s ease-in-out infinite alternate; }
.ov-hot circle:nth-child(2) { animation-delay: -0.5s; }
.ov-hot circle:nth-child(3) { animation-delay: -1s; }
@keyframes ov-hot { from { opacity: 0.3; transform: scale(0.7); } to { opacity: 1; transform: scale(1.25); } }
.ov-route { fill: none; stroke: #fff1dc; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 0.16 0.84; filter: drop-shadow(0 0 6px #ea7a2a); animation: fx-run 2.8s linear infinite; }
.ov-dock path { fill: none; stroke: #bfe3ff; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 5px #5b9ad0); animation: ov-dock 1.8s var(--ease-in-out) infinite alternate; }
.ov-dock path:nth-child(1) { --tx: 44px; }
.ov-dock path:nth-child(2) { --tx: -44px; }
.ov-dock path:nth-child(3) { --ty: 34px; }
@keyframes ov-dock { from { transform: translate(0, 0); opacity: 0.35; } to { transform: translate(var(--tx, 0), var(--ty, 0)); opacity: 1; } }
.ov-pulse { fill: none; stroke: #f6a35f; stroke-width: 2; transform-box: fill-box; transform-origin: center; animation: ov-pulse 2.6s ease-out infinite; }
.ov-pulse--2 { animation-delay: 1.3s; }
@keyframes ov-pulse { from { transform: scale(0.7); opacity: 0.9; } to { transform: scale(2.6); opacity: 0; } }
.ov-orbit { animation: spin 9s linear infinite; }
.ov-orbit ellipse { fill: none; stroke: rgba(191,227,255,0.3); stroke-width: 1.2; stroke-dasharray: 4 7; }
.ov-orbit circle { fill: #ffdcb5; filter: drop-shadow(0 0 7px #ea7a2a); }
.ov-beat { fill: none; stroke: #bfe3ff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 0.3 0.7; filter: drop-shadow(0 0 5px #5b9ad0); animation: fx-run 3s linear infinite; }

@media (min-width: 640px) and (max-width: 1024px) {
  .proc-item { grid-template-columns: 1fr 1fr; align-items: center; gap: 1.6rem; }
}

/* pinned mode (desktop): set by JS */
#engagement.is-pinned { padding: 0; }
.is-pinned .proc-track { height: calc(100vh + 4 * 80vh); }
.is-pinned .proc-sticky {
  position: sticky; top: 0; height: 100vh; overflow: hidden;
  display: flex; align-items: center; padding: 5.2rem 2rem 1.2rem;
}
.is-pinned .section-inner { width: 100%; }
.is-pinned .eng-header {
  grid-template-columns: 1fr 1fr; align-items: end; gap: 2rem; margin-bottom: 1.4rem;
}
.is-pinned .eng-header .section-title { margin-bottom: 0; }
.is-pinned .eng-header .section-lead { justify-self: end; max-width: 30rem; }
.is-pinned .proc-rail { display: block; position: relative; height: 92px; margin-bottom: 1.1rem; }
.proc-rail svg { position: absolute; left: 0; top: 0; width: 100%; height: 48px; overflow: visible; }
.proc-line { fill: none; stroke: rgba(var(--slate-light-rgb),0.2); stroke-width: 1.5; }
.proc-line--fill { stroke: var(--accent); stroke-width: 2.2; stroke-dashoffset: 1; filter: drop-shadow(0 0 5px rgba(var(--accent-rgb),0.8)); }
.proc-head {
  position: absolute; left: -7px; top: -7px; width: 14px; height: 14px; border-radius: 50%; z-index: 2;
  background: #fff4e6; box-shadow: 0 0 0 4px rgba(234,122,42,0.3), 0 0 20px 4px rgba(234,122,42,0.8);
  will-change: transform;
}
.proc-node {
  position: absolute; left: var(--x); top: 0; width: 17%; transform: translateX(-50%);
  background: none; border: 0; color: var(--text-muted); text-align: center;
  display: flex; flex-direction: column; align-items: center;
}
.proc-node-dot {
  width: 12px; height: 12px; margin-top: 18px; border-radius: 50%;
  background: var(--bg-base); border: 2px solid rgba(var(--slate-light-rgb),0.45);
  transition: border-color 240ms var(--ease-out), background 240ms var(--ease-out), transform 240ms var(--ease-out);
}
.proc-node-num { margin-top: 0.55rem; font-family: 'Roboto Mono', monospace; font-size: 0.56rem; letter-spacing: 0.14em; transition: color 240ms var(--ease-out); }
.proc-node-lab { font-family: 'Roboto Mono', monospace; font-size: 0.6rem; line-height: 1.3; transition: color 240ms var(--ease-out); }
.proc-node.is-done .proc-node-dot { background: var(--accent); border-color: var(--accent); }
.proc-node.is-active .proc-node-dot { background: var(--spark); border-color: var(--spark); transform: scale(1.35); }
.proc-node.is-active .proc-node-num { color: var(--spark); }
.proc-node.is-active .proc-node-lab { color: var(--text-primary); }
.proc-node:active .proc-node-dot { transform: scale(0.9); }
@media (hover: hover) and (pointer: fine) {
  .proc-node:hover .proc-node-lab { color: var(--text-primary); }
}
.is-pinned .proc-list { display: grid; padding-left: 0; gap: 0; }
.is-pinned .proc-list::before, .is-pinned .proc-list::after, .is-pinned .proc-item::before { display: none; }
.is-pinned .proc-item {
  grid-area: 1 / 1; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 2.8rem; align-items: center;
  opacity: 0; visibility: hidden; transform: translateY(14px);
  transition: opacity 340ms var(--ease-out), transform 340ms var(--ease-out), visibility 340ms;
}
.is-pinned .proc-item.is-active { opacity: 1; visibility: visible; transform: none; }
.is-pinned .proc-fig { aspect-ratio: auto; height: min(calc(100vh - 21.5rem), 26rem); min-height: 13rem; }
.is-pinned .proc-copy h3 { font-size: 1.35rem; }
.is-pinned .proc-foot { margin-top: 0.8rem; font-size: 0.72rem; }

/* ── Radiografía ──────────────────────────── */
#radiografia {
  background:
    radial-gradient(ellipse 50% 40% at 20% 100%, rgba(var(--accent-rgb),0.1), transparent 70%),
    radial-gradient(ellipse 40% 40% at 95% 10%, rgba(var(--spark-rgb),0.06), transparent 70%),
    var(--bg-elevated);
}
.rxs-header { margin-bottom: 3rem; }
.rxs-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 1.6rem; align-items: start; }
.rxs-dash, .rxs-case { min-width: 0; }
.rxs-case { max-width: none; margin: 0; padding: 2rem 1.7rem; border-radius: 10px; }
.cs-title { font-size: 1rem; line-height: 1.35; }
.cs-subtitle { font-size: 0.82rem; margin-bottom: 1.4rem; }
.cs-metrics { grid-template-columns: 1fr 1fr; margin-bottom: 1.5rem; border-radius: 6px; overflow: hidden; }
.cs-metric { padding: 1.05rem 0.6rem; }
.cs-metric-val { font-size: 1.5rem; font-variant-numeric: tabular-nums; }
.cs-metric-lbl { font-size: 0.52rem; letter-spacing: 0.08em; display: block; line-height: 1.4; }
.cs-do { list-style: none; display: grid; gap: 0.75rem; margin-bottom: 1.4rem; }
.cs-do-item { display: grid; grid-template-columns: 2.1rem 1fr; gap: 0.7rem; align-items: start; }
.cs-do-idx {
  display: grid; place-items: center; height: 2.1rem; border-radius: 6px;
  font-family: 'Roboto Mono', monospace; font-size: 0.52rem; color: var(--spark);
  border: 1px solid rgba(var(--spark-rgb),0.35); background: rgba(var(--spark-rgb),0.07);
}
.cs-do-item h4 { font-family: 'Roboto Mono', monospace; font-size: 0.72rem; font-weight: 500; }
.cs-do-item p { font-size: 0.76rem; color: var(--text-muted); line-height: 1.55; }
.cs-quote { font-size: 0.8rem; margin-bottom: 1.4rem; }
.rxs-case .btn { width: 100%; justify-content: center; }
@media (max-width: 1024px) { .rxs-grid { grid-template-columns: minmax(0, 1fr); } }

@media (prefers-reduced-motion: reduce) {
  .hero-fx, .hero-beam, .hero-net { display: none; }
  .hero-content, .logo-ring, .logo-arc, .logo-word, .hero-card-inner, .hero-card-inner::after,
  .ico-gear, .ico-bar, .ico-arrow, .proc-ov * { animation: none !important; }
  .proc-ov, .svc-ov, .feat-cell::before, .svc-media::after { display: none; }
  .svc-stage { animation: none !important; transform: scale(1.06); }
  .hero-card { transition: none; }
}

/* the case stays in view next to the taller dashboard */
#radiografia { overflow: clip; }
@media (min-width: 1025px) {
  .rxs-case { position: sticky; top: 6.2rem; }
}

/* dashboard: the period switch takes its own row on the narrowest phones */
@media (max-width: 440px) {
  .rx-controls { flex-wrap: wrap; width: 100%; min-width: 0; }
  .rx-periods { display: flex; flex: 1 1 100%; min-width: 0; }
  .rx-period { flex: 1 1 0; min-width: 0; padding-inline: 4px; }
}

/* ════════════════════════════════════════════
   DEEP BLUE THEME
   Saturated navy matched to the blacks of the Codex images, pure white
   ink and electric accents: same family as the images, none of the grey.
════════════════════════════════════════════ */
::selection { background: rgba(var(--accent-rgb),0.35); }
.grain { display: none; }
.section-title { font-weight: 500; }
.section-rule { height: 2px; width: 56px; }
.section-lead { font-weight: 400; }
.eyebrow { font-weight: 500; }
.btn-primary { background: linear-gradient(135deg, #0a5cc0, #1673dc); }

#hero .hero-plate { filter: brightness(1.18) saturate(1.22) contrast(1.05); }
#hero .btn-ghost { background: rgba(4,20,44,0.6); }
#nav.scrolled {
  background: rgba(4,20,44,0.9); border-bottom-color: rgba(var(--accent-rgb),0.28);
  backdrop-filter: blur(16px) saturate(1.6); -webkit-backdrop-filter: blur(16px) saturate(1.6);
}

/* section bands */
#engagement.proc {
  background:
    radial-gradient(ellipse 55% 45% at 10% 12%, rgba(30,144,255,0.2), transparent 70%),
    var(--bg-elevated);
}
#framework {
  background:
    radial-gradient(ellipse 60% 48% at 50% 0%, rgba(30,144,255,0.2), transparent 70%),
    var(--bg-base);
}
#radiografia {
  background:
    radial-gradient(ellipse 50% 42% at 12% 100%, rgba(30,144,255,0.22), transparent 70%),
    radial-gradient(ellipse 36% 36% at 96% 6%, rgba(var(--spark-rgb),0.12), transparent 70%),
    var(--bg-elevated);
}
#alliances {
  background:
    radial-gradient(ellipse 50% 50% at 50% 100%, rgba(30,144,255,0.16), transparent 70%),
    var(--bg-base);
}
#about {
  background:
    radial-gradient(ellipse 50% 45% at 92% 8%, rgba(30,144,255,0.2), transparent 70%),
    var(--bg-elevated);
}
#contact {
  background:
    radial-gradient(ellipse 45% 50% at 4% 92%, rgba(30,144,255,0.18), transparent 70%),
    var(--bg-base);
}
#footer { background: linear-gradient(160deg, #06244a, #020d1d 62%); }

/* cards: crisp blue rim, lit from above */
.forge-card, .cs-card, .allia-card, .pillar-card, .founder-card {
  background: linear-gradient(165deg, #0d3264, var(--bg-card) 62%);
  box-shadow: inset 0 1px 0 rgba(143,208,255,0.16), 0 20px 44px -24px rgba(1,8,20,0.9);
}
.cs-metric { background: var(--bg-card); }
.forge-letter { opacity: 0.12; }
.forge-card:hover .forge-letter { opacity: 0.32; }

/* Metodología: the card lifts out of the row. .reveal.in sets transform:none
   with more weight, so these selectors have to outrank it */
.js .forge-card.reveal.in, .js .allia-card.reveal.in { transition-delay: 0s !important; }
.forge-card { transition: transform 280ms var(--ease-out), box-shadow 280ms var(--ease-out), border-top-color 200ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
  .js .forge-card.reveal.in:hover {
    z-index: 5; transform: translateY(-16px) scale(1.07);
    border-top-color: var(--spark);
    box-shadow: inset 0 1px 0 rgba(143,208,255,0.3), 0 0 0 1px var(--accent), 0 34px 60px -14px rgba(1,8,20,0.95), 0 0 46px rgba(30,144,255,0.4);
  }
  .js .allia-card.reveal.in:hover {
    transform: translateY(-6px);
    box-shadow: inset 0 1px 0 rgba(143,208,255,0.3), 0 0 0 1px var(--accent), 0 28px 50px -18px rgba(1,8,20,0.95);
  }
}
@media (hover: hover) and (pointer: fine) and (max-width: 1024px) {
  .js .forge-card.reveal.in:hover { transform: scale(1.03); }
}
.js .forge-card.reveal.in:active { transform: scale(0.99); }

.proc-fig { border-color: rgba(var(--accent-rgb),0.4); box-shadow: 0 30px 60px -24px rgba(1,8,20,0.95), 0 0 42px rgba(30,144,255,0.2); }
.form-input, .form-select, .form-textarea { background: #0b2b55; border-color: rgba(143,208,255,0.42); }
.form-input::placeholder, .form-textarea::placeholder { opacity: 0.75; }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--accent); }
.form-status.is-err { color: #ff9c8e; }
.form-status.is-ok { color: #4be38a; }
.footer-copy { color: rgba(var(--slate-light-rgb), 0.7); }
