/* ==========================================================================
   Sovralta — hoja de estilos única
   Una compañía de ENT Intelligence
   ========================================================================== */

:root {
  --bg:      #0A0B0E;
  --bg-2:    #0C0E12;
  --card:    #101318;
  --card-h:  #141820;
  --line:    #232832;
  --line-2:  #343B46;
  --ink:     #EEEBE5;
  --mut:     #9199A5;
  --mut-2:   #5A6372;
  --mut-3:   #6B7280;
  --mut-4:   #4B5563;
  --gold:    #D6A550;
  --gold-s:  #E8BE6E;
  --rust:    #B05A3C;

  --wrap:    1160px;
  --gut:     48px;
  --ease:    cubic-bezier(.16, .84, .44, 1);
  --d:       'Space Grotesk', system-ui, -apple-system, sans-serif;
  --b:       'Inter', system-ui, -apple-system, sans-serif;

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--b);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { max-width: 100%; height: auto; display: block; }

a { color: var(--gold); }
a:hover { color: var(--ink); }

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

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 99;
  background: var(--gold); color: var(--bg); padding: 12px 20px;
  font-family: var(--d); font-size: 15px; text-decoration: none;
}
.skip:focus { left: 8px; top: 8px; color: var(--bg); }

/* --------------------------------------------------------------- Estructura */

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }

.d  { font-family: var(--d); font-weight: 500; letter-spacing: -0.025em; }
.mut { color: var(--mut); }

.eyebrow {
  font-family: var(--d); font-size: 12px; font-weight: 500;
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold);
}
.eyebrow--mut { color: var(--mut); }

.h1 { margin: 0; font-family: var(--d); font-weight: 700; letter-spacing: -0.03em;
      font-size: clamp(38px, 6.4vw, 72px); line-height: 1.02; }
.h2 { margin: 0; font-family: var(--d); font-weight: 700; letter-spacing: -0.03em;
      font-size: clamp(30px, 4.4vw, 50px); line-height: 1.06; }
.h3 { margin: 0; font-family: var(--d); font-weight: 500; letter-spacing: -0.02em;
      font-size: clamp(19px, 1.8vw, 24px); line-height: 1.3; }

.lead { font-size: clamp(17px, 1.6vw, 20px); line-height: 1.55; }
.fine { font-size: 14px; color: var(--mut-2); }

.band-dark  { background: var(--bg-2); border-block: 1px solid var(--line); }
.band-gold  { background: var(--gold); color: var(--bg); }
.band-gold a { color: var(--bg); }

.sec { padding-block: clamp(64px, 9vw, 104px); }
.sec--tight { padding-block: clamp(56px, 7vw, 88px); }

.cols { display: flex; flex-wrap: wrap; gap: clamp(32px, 5vw, 64px); }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; }
.span-2 { grid-column: span 2; }

/* ------------------------------------------------------------------ Botones */

.btn, .btn-2 {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 54px; padding: 0 30px; border-radius: 2px;
  font-family: var(--d); font-size: 16px; font-weight: 500;
  text-decoration: none; cursor: pointer;
  transition: transform 300ms var(--ease), box-shadow 300ms ease, border-color 300ms ease;
}
.btn   { background: var(--gold); color: var(--bg); border: 0; }
.btn:hover   { color: var(--bg); transform: translateY(-3px); box-shadow: 0 12px 32px rgba(214,165,80,.28); }
.btn-2 { background: transparent; color: var(--ink); border: 1px solid var(--line-2); }
.btn-2:hover { color: var(--ink); border-color: var(--gold); transform: translateY(-3px); }

.btn--dark   { background: var(--bg); color: var(--gold); }
.btn--dark:hover { color: var(--gold); box-shadow: 0 12px 32px rgba(10,11,14,.3); }
.btn-2--dark { border-color: var(--bg); color: var(--bg); }
.btn-2--dark:hover { color: var(--bg); border-color: var(--bg); }
.btn--full { width: 100%; }

.btns { display: flex; flex-wrap: wrap; gap: 14px; }
.btns--mid { justify-content: center; }

/* ------------------------------------------------------------- Encabezado */

.top { position: sticky; top: 0; z-index: 40;
  border-bottom: 1px solid var(--line);
  background: rgba(10, 11, 14, .88);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.band-gold + .top { background: rgba(10, 11, 14, .88); }

.bar { display: flex; flex-wrap: wrap; align-items: center; gap: 24px;
       min-height: 84px; padding-block: 16px; }

.logo { display: flex; align-items: center; gap: 10px; margin-right: auto;
        text-decoration: none; color: var(--ink); }
.logo:hover { color: var(--ink); }
.logo span { font-family: var(--d); font-weight: 500; font-size: 21px; letter-spacing: 0.02em; }

.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 28px; }
.nav a { font-family: var(--d); font-size: 15px; text-decoration: none;
         color: var(--mut); transition: color 220ms ease; white-space: nowrap; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); }

.top .btn { min-height: 46px; padding: 0 22px; font-size: 15px; }

/* -------------------------------------------------------------- Revelado */

.js [data-reveal] { opacity: 0; transform: translateY(22px); }
.js [data-reveal].is-in {
  opacity: 1; transform: none;
  transition: opacity 820ms var(--ease), transform 820ms var(--ease);
}

/* --------------------------------------------------------------- Tarjetas */

.card {
  position: relative; overflow: hidden;
  border: 1px solid var(--line); border-radius: 2px;
  background: var(--card); padding: clamp(24px, 3vw, 34px);
  transition: transform 380ms var(--ease), border-color 380ms ease, background 380ms ease;
}
.card::after {
  content: ''; position: absolute; left: 0; top: 0; width: 2px; height: 0;
  background: var(--gold); transition: height 420ms var(--ease);
}
.card:hover { transform: translateY(-6px); border-color: var(--line-2); background: var(--card-h); }
.card:hover::after { height: 100%; }
.card__n { margin: 0 0 16px; font-family: var(--d); font-size: 14px; color: var(--gold); }
.card p:last-child { margin-bottom: 0; }

.panel { border: 1px solid var(--line); border-radius: 2px;
         background: var(--card); padding: clamp(26px, 3.4vw, 40px); }

.box { border: 1px solid rgba(10,11,14,.35); border-radius: 2px; padding: clamp(28px, 3.4vw, 40px); }
.box--hard { border: 2px solid var(--bg); }

.rule { border-top: 1px solid var(--line); padding-top: 22px; }
.rule-hard { border-top: 2px solid var(--bg); padding-top: 32px; }

/* ------------------------------------------------------------------ Cinta */

@keyframes sv-run { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.marquee { overflow: hidden; border-block: 1px solid var(--line);
           background: var(--bg-2); padding-block: 22px; }
.marquee__t { display: flex; width: max-content; animation: sv-run 34s linear infinite; }
.marquee__i { font-family: var(--d); font-size: 15px; letter-spacing: 0.08em;
              text-transform: uppercase; color: var(--mut-2);
              padding-inline: 26px; white-space: nowrap; }

@keyframes sv-pulse { 0%, 100% { opacity: 1; transform: scale(1); }
                      50% { opacity: .35; transform: scale(.7); } }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%;
       background: currentColor; animation: sv-pulse 2s ease-in-out infinite; }

/* ------------------------------------------------------- Hero: resplandor */

.hero { position: relative; overflow: hidden; background: var(--bg); }
.hero__glow { position: absolute; inset: 0; pointer-events: none;
              background: radial-gradient(620px circle at 62% 30%,
                rgba(214,165,80,.13), rgba(214,165,80,0) 62%); }
.hero__in { position: relative; padding-block: clamp(64px, 9vw, 120px) clamp(56px, 8vw, 104px); }

/* ---------------------------------------------------- Hero: constelación */

.sky { position: relative; width: 100%; aspect-ratio: 13 / 10; }
.sky__s { position: absolute; border-radius: 50%; background: var(--gold); pointer-events: none; }
.sky__l { position: absolute; height: 1px; transform-origin: 0 50%;
          background: var(--gold); pointer-events: none; }

/* ----------------------------------------------------------- Mapa / grafo */

.graph { position: relative; width: 100%; max-width: 1040px; margin-inline: auto;
         aspect-ratio: 2 / 1; container-type: inline-size; }
.graph__e { position: absolute; height: 1px; transform-origin: 0 50%; pointer-events: none; }
.graph__n {
  position: absolute; margin: 0; white-space: nowrap; cursor: pointer;
  padding: clamp(6px, .7cqw, 11px) clamp(10px, 1.1cqw, 17px);
  background: var(--card); border: 1px solid var(--line-2); border-radius: 2px;
  font-family: var(--d); font-weight: 500; font-size: clamp(9px, 1.25cqw, 14px);
  color: #C3C7CE;
  transition: border-color 220ms ease, color 220ms ease, background 220ms ease;
}
.graph__n:hover, .graph__n:focus-visible { background: #161A20; }
.graph__h {
  position: absolute; white-space: nowrap; pointer-events: none;
  padding: clamp(9px, 1cqw, 16px) clamp(16px, 1.7cqw, 26px);
  background: var(--gold); color: var(--bg); border-radius: 2px;
  font-family: var(--d); font-weight: 500; font-size: clamp(12px, 1.8cqw, 22px);
}
.graph__fb { margin: 0; color: var(--mut); }
.js .graph__fb { display: none; }

.toggle { display: inline-flex; gap: 4px; padding: 4px;
          background: var(--card); border: 1px solid var(--line); border-radius: 2px; }
.toggle button {
  min-height: 46px; padding: 0 22px; border: 0; border-radius: 2px;
  background: transparent; color: var(--mut); cursor: pointer;
  font-family: var(--d); font-size: 15px; font-weight: 500;
  transition: background 280ms ease, color 280ms ease;
}
.toggle button:hover { color: var(--ink); }
.toggle button[aria-pressed="true"] { background: var(--gold); color: var(--bg); }

/* ------------------------------------------------------------------ Pasos */

.step {
  position: relative; border: 0; border-top: 1px solid var(--line);
  background: transparent; text-align: left; padding: 24px 0 0;
  font-family: inherit; color: inherit; cursor: pointer;
}
.step__bar { position: absolute; left: 0; top: -1px; height: 2px; width: 0;
             background: var(--gold); transition: width 520ms var(--ease); }
.step__t { display: block; margin-bottom: 10px; font-family: var(--d);
           font-weight: 500; font-size: 20px; color: var(--mut-3);
           transition: color 420ms ease; }
.step__b { display: block; font-size: 16px; line-height: 1.6; color: var(--mut-4);
           transition: color 420ms ease; }
.step[aria-pressed="true"] .step__bar { width: 100%; }
.step[aria-pressed="true"] .step__t { color: var(--ink); }
.step[aria-pressed="true"] .step__b { color: var(--mut); }

/* -------------------------------------------------------- Frentes (lista) */

.pick {
  position: relative; display: block; width: 100%; text-align: left;
  background: transparent; border: 0; border-top: 1px solid var(--line);
  padding: 26px 0 26px 22px; font-family: inherit; color: inherit; cursor: pointer;
}
.pick__bar { position: absolute; left: 0; top: 0; bottom: 0; width: 2px;
             background: var(--gold); transform: scaleY(0); transform-origin: top;
             transition: transform 460ms var(--ease); }
.pick__n { display: block; margin-bottom: 6px; font-family: var(--d);
           font-size: 13px; color: var(--gold); }
.pick__t { display: block; font-family: var(--d); font-weight: 500;
           font-size: clamp(21px, 2.2vw, 26px); letter-spacing: -0.02em;
           color: var(--mut-3); transition: color 420ms ease; }
.pick[aria-pressed="true"] .pick__bar { transform: scaleY(1); }
.pick[aria-pressed="true"] .pick__t { color: var(--ink); }

@keyframes sv-fade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.fade { animation: sv-fade 520ms var(--ease) both; }

/* ------------------------------------------------------------- AI Board */

.orbit { position: relative; width: 100%; max-width: 420px; aspect-ratio: 1 / 1; margin-inline: auto; }
.orbit__r { position: absolute; inset: 0; border: 1px solid var(--line); border-radius: 50%; }
.orbit__r:nth-of-type(2) { inset: 16%; }
.orbit__r:nth-of-type(3) { inset: 32%; }
.orbit__s { position: absolute; width: 10px; height: 10px; border-radius: 50%; background: var(--gold); }
.orbit__c { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
            padding: 16px 24px; background: var(--gold); color: var(--bg); border-radius: 2px;
            font-family: var(--d); font-weight: 500; font-size: 20px; white-space: nowrap; }

/* ------------------------------------------------------- Rieles (5 días) */

.rail { position: relative; height: 2px; background: var(--line); margin-top: clamp(38px, 5vw, 54px); }
.rail__f { position: absolute; left: 0; top: 0; height: 2px; width: 0;
           background: var(--gold); transition: width 620ms var(--ease); }
.rail__m { position: absolute; top: 50%; width: 14px; height: 14px; border-radius: 50%;
           border: 2px solid var(--line); background: var(--bg);
           transform: translate(-50%, -50%);
           transition: border-color 420ms ease, background 420ms ease, box-shadow 420ms ease; }
.rail__m.is-on { border-color: var(--gold); background: var(--gold);
                 box-shadow: 0 0 0 7px rgba(214,165,80,.14); }

.day { background: transparent; border: 0; text-align: left; padding: 0;
       font-family: inherit; color: inherit; cursor: pointer; }
.day__t { display: block; margin-bottom: 10px; font-family: var(--d); font-weight: 500;
          font-size: clamp(20px, 2.2vw, 26px); letter-spacing: -0.02em;
          color: var(--mut-3); transition: color 420ms ease; }
.day__b { display: block; font-size: 17px; line-height: 1.6; color: var(--mut-4);
          transition: color 420ms ease; }
.day.is-past .day__t { color: var(--ink); }
.day.is-past .day__b { color: var(--mut); }
.day[aria-pressed="true"] .day__t { color: var(--gold); }
.day[aria-pressed="true"] .day__b { color: var(--ink); }

/* -------------------------------------------------------- Filas de casos */

.row { position: relative; display: flex; flex-wrap: wrap; gap: clamp(24px, 4vw, 48px);
       align-items: flex-start; padding-block: clamp(32px, 4.4vw, 48px);
       border-top: 1px solid var(--line); transition: background 420ms ease; }
.row::before { content: ''; position: absolute; left: 0; top: 0; width: 0; height: 2px;
               background: var(--gold); transition: width 560ms var(--ease); }
.row:hover { background: var(--bg-2); }
.row:hover::before { width: 100%; }
.row:last-of-type { border-bottom: 1px solid var(--line); }
.row__k { flex: 0 0 240px; }
.row__v { flex: 1 1 440px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.row__h { margin: 0 0 8px; font-family: var(--d); font-weight: 700;
          font-size: clamp(28px, 3.4vw, 38px); letter-spacing: -0.03em; }
.row__u { margin: 0 0 20px; font-size: 15px; color: var(--mut-2); }
.row--soon .row__h, .row--soon .row__v p { color: var(--mut-3); }

.tag { display: inline-block; margin: 0; padding: 6px 12px;
       border: 1px solid var(--line-2); border-radius: 2px;
       font-family: var(--d); font-size: 12px; letter-spacing: 0.1em;
       text-transform: uppercase; color: var(--gold); }
.tag--off { color: var(--mut-3); border-color: var(--line); }

@keyframes sv-breathe { 0%, 100% { transform: scaleY(.35); opacity: .4; }
                        50% { transform: scaleY(1); opacity: 1; } }
.bars { display: flex; align-items: flex-end; gap: 5px; height: 42px; }
.bars span { width: 4px; height: 100%; background: var(--gold);
             transform-origin: bottom; animation: sv-breathe 2.6s ease-in-out infinite; }
.bars span:nth-child(1) { animation-delay: 0ms; }
.bars span:nth-child(2) { animation-delay: 180ms; }
.bars span:nth-child(3) { animation-delay: 360ms; }
.bars span:nth-child(4) { animation-delay: 120ms; }
.bars span:nth-child(5) { animation-delay: 540ms; }
.bars span:nth-child(6) { animation-delay: 300ms; }
.bars span:nth-child(7) { animation-delay: 660ms; }
.bars span:nth-child(8) { animation-delay: 240ms; }
.bars span:nth-child(9) { animation-delay: 420ms; }

/* ------------------------------------------------------------------- Pie */

.foot { background: var(--bg-2); border-top: 1px solid var(--line); color: var(--mut); }
.foot--plain { background: var(--bg); }
.foot__in { padding-block: clamp(36px, 5vw, 56px); display: flex; flex-wrap: wrap;
            gap: 32px; align-items: flex-start; }
.foot__in--row { align-items: center; gap: 24px; padding-block: 44px; }
.foot h2 { margin: 0 0 12px; font-family: var(--d); font-weight: 500; font-size: 13px;
           letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink); }
.foot__links { margin: 0; font-size: 15px; line-height: 2; }
.foot__links a { color: var(--mut); text-decoration: none; }
.foot__links a:hover { color: var(--ink); }
.foot__legal { margin: 0; font-size: 13px; color: var(--mut-2); }

/* -------------------------------------------------------------- Contacto */

.ct { display: flex; flex-direction: column; gap: 10px; }
.ct a { font-family: var(--d); font-size: clamp(18px, 2vw, 22px);
        text-decoration: none; letter-spacing: -0.01em; }

/* ------------------------------------------------------------- Adaptable */

@media (max-width: 900px) {
  :root { --gut: 18px; }
  .bar { gap: 14px; min-height: 68px; }
  .nav { order: 3; flex: 1 0 100%; gap: 20px; overflow-x: auto;
         padding-bottom: 2px; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .hide-s { display: none !important; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .graph { aspect-ratio: 1 / 1.1; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: minmax(0, 1fr); }
  .span-2 { grid-column: span 1; }
  .row__k { flex: 1 1 100%; }
  .btn, .btn-2 { width: 100%; }
  .top .btn { width: auto; min-height: 42px; padding: 0 16px; font-size: 14px; }
  .btns { gap: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important; animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
  .bars span { transform: scaleY(.6); }
}
