/* ==========================================================================
   Clínica Hispana Tu Vida · Recorrido virtual
   1. Tokens  2. Base  3. Utilidades  4. Componentes  5. Secciones
   6. Keyframes  7. Reduced motion
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
@property --angle { syntax: '<angle>'; initial-value: 0deg; inherits: false; }

:root {
  --primary: #1b4fa8;
  --secondary: #38a3dc;
  --accent: #f6b21b;
  --bg: #f6f4ef;
  --surface: #ffffff;
  --surface-dark: #0a1730;
  --text: #101a2e;
  --muted: #5b667a;

  --on-dark: #f3f6fb;
  --on-dark-muted: color-mix(in srgb, var(--on-dark) 68%, transparent);
  --line-dark: color-mix(in srgb, #fff 14%, transparent);

  --font-display: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --ease-smooth: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-bouncy: cubic-bezier(0.68, -0.55, 0.26, 1.55);
  --dur-fast: 300ms;
  --dur-slow: 800ms;

  --radius: 28px;
  --pad: clamp(20px, 4vw, 64px);
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--font-display); font-weight: 800; letter-spacing: -0.03em; line-height: 1.05; margin: 0; text-wrap: balance; }
h2 { font-size: clamp(2rem, 5vw, 3.5rem); }
p { margin: 0; }
img, video, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* ---------- 3. Utilidades ---------- */
.wrap { width: min(1240px, 100% - var(--pad) * 2); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.muted { color: var(--muted); }
.skip { position: fixed; left: 12px; top: -80px; z-index: 100; background: var(--accent); color: #1a1300; padding: 10px 16px; border-radius: 999px; font-weight: 500; text-decoration: none; }
.skip:focus { top: 12px; }

.eyebrow {
  font-family: var(--font-display); font-weight: 600; font-size: .8125rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent); display: flex; align-items: center; gap: 12px;
}
.eyebrow::before { content: ''; width: 28px; height: 2px; background: currentColor; border-radius: 2px; }
.eyebrow--dark { color: var(--primary); }

.reveal { opacity: 0; translate: 0 40px; transition: opacity var(--dur-slow) var(--ease-smooth), translate var(--dur-slow) var(--ease-smooth); transition-delay: calc(var(--d, 0) * 100ms); }
.reveal.is-in, .no-js .reveal { opacity: 1; translate: 0 0; }

/* Capa de medios: gradiente (fallback) < póster < video */
.media {
  background:
    var(--poster, linear-gradient(transparent, transparent)) center / cover no-repeat,
    radial-gradient(120% 90% at 15% 10%, color-mix(in srgb, var(--secondary) 55%, transparent), transparent 60%),
    radial-gradient(90% 80% at 90% 90%, color-mix(in srgb, var(--accent) 30%, transparent), transparent 60%),
    linear-gradient(140deg, #12306b, var(--surface-dark));
}
.media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 600ms ease; }
.media video.is-ready { opacity: 1; }

/* Blobs estáticos (gradiente radial: sin filter ni animación) */
.blob { position: absolute; border-radius: 50%; pointer-events: none; }
.blob--a { width: 620px; height: 620px; left: -180px; top: 8%; background: radial-gradient(closest-side, color-mix(in srgb, var(--secondary) 34%, transparent), transparent); }
.blob--b { width: 520px; height: 520px; right: -140px; bottom: 4%; background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 30%, transparent), transparent); }
.blob--c { width: 700px; height: 700px; left: -220px; bottom: -280px; background: radial-gradient(closest-side, color-mix(in srgb, var(--primary) 70%, transparent), transparent); }
.blob--d { width: 520px; height: 520px; right: -160px; top: -200px; background: radial-gradient(closest-side, color-mix(in srgb, var(--secondary) 34%, transparent), transparent); }

/* ---------- 4. Componentes ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 14px 26px; border-radius: 999px;
  font-family: var(--font-display); font-weight: 600; font-size: 1rem; line-height: 1.2; text-decoration: none; white-space: nowrap;
  transition: background-color var(--dur-fast) var(--ease-smooth), color var(--dur-fast) var(--ease-smooth), scale var(--dur-fast) var(--ease-smooth), translate 500ms var(--ease-bouncy);
}
.btn svg { width: 20px; height: 20px; fill: currentColor; flex: none; }
.btn:hover { scale: 1.04; }
.btn:active { scale: .98; }
.btn--primary { background: var(--surface); color: var(--surface-dark); }
.btn--accent { background: var(--accent); color: #1a1300; }
.btn--accent:hover { background: color-mix(in srgb, var(--accent) 86%, #fff); }
.btn--ghost { color: var(--on-dark); border: 1px solid color-mix(in srgb, #fff 34%, transparent); background: color-mix(in srgb, #fff 8%, transparent); }
.btn--ghost:hover { background: color-mix(in srgb, #fff 16%, transparent); }
.btn--sm { min-height: 40px; padding: 8px 18px; font-size: .875rem; }

/* CTA con halo giratorio (único gradiente cónico animado del sitio) */
.glow { position: relative; display: inline-flex; border-radius: 999px; }
.glow::before {
  content: ''; position: absolute; inset: -3px; border-radius: inherit; z-index: 0;
  background: conic-gradient(from var(--angle), var(--accent), var(--secondary), #fff, var(--accent));
  animation: spin 4s linear infinite;
}
.glow .btn { position: relative; z-index: 1; }

/* Selector de idioma */
.lang { position: relative; display: grid; grid-template-columns: 1fr 1fr; padding: 3px; border-radius: 999px; background: color-mix(in srgb, #fff 12%, transparent); }
.lang__btn { position: relative; z-index: 1; min-width: 40px; height: 32px; padding: 0 10px; border-radius: 999px; font-family: var(--font-display); font-weight: 600; font-size: .75rem; letter-spacing: .06em; color: var(--on-dark-muted); transition: color var(--dur-fast) var(--ease-smooth); }
.lang__btn[aria-pressed="true"] { color: var(--surface-dark); }
.lang__thumb { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc(50% - 3px); border-radius: 999px; background: var(--surface); transition: translate var(--dur-fast) var(--ease-smooth); }
html[lang="en"] .lang__thumb { translate: 100% 0; }

/* Navbar isla (fondo sólido translúcido: va siempre encima de video) */
.nav {
  position: fixed; z-index: 50; top: 14px; left: 0; right: 0; margin-inline: auto;
  width: min(1120px, 100% - 24px);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 12px 12px 12px 20px; border-radius: 999px;
  color: var(--on-dark);
  background: color-mix(in srgb, var(--surface-dark) 62%, transparent);
  border: 1px solid var(--line-dark);
  transition: padding var(--dur-fast) var(--ease-smooth), background-color var(--dur-fast) var(--ease-smooth), box-shadow var(--dur-fast) var(--ease-smooth);
}
.nav.is-scrolled { padding-block: 7px; background: color-mix(in srgb, var(--surface-dark) 90%, transparent); box-shadow: 0 14px 40px -18px color-mix(in srgb, var(--surface-dark) 80%, transparent); }
.nav__brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-weight: 600; font-size: .9375rem; white-space: nowrap; }
.nav__brand b { font-weight: 800; color: var(--accent); }
.nav__logo { width: 34px; height: 34px; transition: scale var(--dur-fast) var(--ease-smooth); }
.nav.is-scrolled .nav__logo { scale: .88; }
.nav__links { display: flex; gap: 6px; }
.nav__links a { padding: 8px 14px; border-radius: 999px; font-size: .9375rem; font-weight: 500; text-decoration: none; white-space: nowrap; color: var(--on-dark-muted); transition: color var(--dur-fast), background-color var(--dur-fast); }
.nav__links a:hover { color: var(--on-dark); background: color-mix(in srgb, #fff 10%, transparent); }
.nav__tools { display: flex; align-items: center; gap: 10px; }
.nav__burger { display: none; width: 40px; height: 40px; border-radius: 50%; background: color-mix(in srgb, #fff 12%, transparent); position: relative; }
.nav__burger span { position: absolute; left: 12px; right: 12px; height: 2px; border-radius: 2px; background: currentColor; transition: translate var(--dur-fast) var(--ease-smooth), rotate var(--dur-fast) var(--ease-smooth); }
.nav__burger span:first-child { top: 15px; }
.nav__burger span:last-child { top: 23px; }
.nav__burger[aria-expanded="true"] span:first-child { translate: 0 4px; rotate: 45deg; }
.nav__burger[aria-expanded="true"] span:last-child { translate: 0 -4px; rotate: -45deg; }

@media (max-width: 900px) {
  .nav { padding-left: 14px; }
  .nav__cta { display: none; }
  .nav__burger { display: block; }
  .nav__links {
    position: fixed; inset: 0; z-index: -1;
    flex-direction: column; justify-content: center; align-items: center; gap: 8px;
    background: var(--surface-dark);
    opacity: 0; visibility: hidden; transition: opacity var(--dur-fast) var(--ease-smooth), visibility 0s linear var(--dur-fast);
  }
  .nav__links a { font-family: var(--font-display); font-size: 2rem; font-weight: 800; color: var(--on-dark); padding: 12px 24px; }
  .nav.is-open .nav__links { opacity: 1; visibility: visible; transition-delay: 0s; }
  .nav.is-open { background: transparent; border-color: transparent; box-shadow: none; }
}
@media (max-width: 420px) { .nav__name { font-size: .8125rem; } .nav__logo { width: 28px; height: 28px; } }

/* ---------- 5. Secciones ---------- */

/* Hero */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: grid; align-items: end; overflow: hidden; overflow: clip; color: var(--on-dark); background: var(--surface-dark); --p: 0; }
.hero__media { position: absolute; inset: 0; scale: calc(1 + var(--p) * 0.15); opacity: calc(1 - var(--p) * 0.6); transform-origin: 50% 60%; }
.hero__shade { position: absolute; inset: 0; background:
  linear-gradient(to top, color-mix(in srgb, var(--surface-dark) 96%, transparent) 0%, color-mix(in srgb, var(--surface-dark) 62%, transparent) 42%, color-mix(in srgb, var(--surface-dark) 30%, transparent) 72%, color-mix(in srgb, var(--surface-dark) 55%, transparent) 100%); }
.hero__content { position: relative; width: min(1240px, 100% - var(--pad) * 2); margin-inline: auto; padding-block: 140px clamp(96px, 14vh, 150px); translate: 0 calc(var(--p) * -70px); opacity: calc(1 - var(--p) * 1.5); }
.hero__title { font-size: clamp(3rem, 8vw, 5rem); margin-block: 18px 20px; max-width: 12ch; }
.grad { background: linear-gradient(100deg, var(--accent) 0%, #ffe39a 30%, var(--secondary) 55%, var(--accent) 100%); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shimmer 7s linear infinite; }
.hero__lead { max-width: 54ch; color: color-mix(in srgb, var(--on-dark) 86%, transparent); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px 16px; margin-top: 32px; }
.hero__card { position: absolute; right: var(--pad); bottom: clamp(96px, 14vh, 150px); display: flex; align-items: center; gap: 12px; padding: 14px 20px; border-radius: 20px; font-size: .9375rem; font-weight: 500; background: color-mix(in srgb, var(--surface-dark) 70%, transparent); border: 1px solid var(--line-dark); opacity: calc(1 - var(--p) * 2); }
.hero__card-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); animation: pulse 2s ease-in-out infinite; }
.hero__scroll { position: absolute; left: 50%; bottom: 22px; translate: -50% 0; display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: .6875rem; letter-spacing: .2em; text-transform: uppercase; text-decoration: none; color: var(--on-dark-muted); opacity: calc(1 - var(--p) * 3); }
.hero__scroll-line { width: 2px; height: 34px; border-radius: 2px; background: color-mix(in srgb, #fff 24%, transparent); position: relative; overflow: hidden; overflow: clip; }
.hero__scroll-line::after { content: ''; position: absolute; inset: 0; background: var(--accent); animation: drip 1.8s var(--ease-smooth) infinite; }
.hero.is-paused *, .hero.is-paused *::before, .hero.is-paused *::after { animation-play-state: paused !important; }
@media (max-width: 900px) { .hero__card { display: none; } }

/* Manifiesto */
.statement { position: relative; height: 190vh; background: var(--bg); }
.statement__sticky { position: sticky; top: 0; height: 100vh; height: 100dvh; display: flex; flex-direction: column; justify-content: center; gap: 28px; padding-inline: var(--pad); overflow: hidden; overflow: clip; }
.statement__sticky > .eyebrow, .statement__text { position: relative; width: min(1040px, 100%); margin-inline: auto; }
.statement__text { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.75rem, 4.6vw, 3.5rem); line-height: 1.16; letter-spacing: -0.03em; --p: 0; }
.statement__text em { font-style: normal; color: var(--primary); }
.statement__text .word { opacity: clamp(0.14, calc((var(--p) - var(--i)) * 9 + 0.14), 1); }
.no-js .statement { height: auto; padding-block: 120px; }
.no-js .statement__sticky { position: static; height: auto; }

/* Recorrido */
.tour { position: relative; height: calc(var(--n) * 130vh + 100vh); background: var(--surface-dark); color: var(--on-dark); }
.tour__stage { position: sticky; top: 0; height: 100vh; height: 100dvh; overflow: hidden; overflow: clip; }

.tour__amb { display: none; }
.tour__frame { position: absolute; inset: 0; overflow: hidden; overflow: clip; }
.tour__layer { position: absolute; inset: 0; visibility: hidden; --in: 0; --out: 0; clip-path: inset(calc((1 - var(--in)) * 100%) 0 0 0); }
.tour__layer.is-on { visibility: visible; }
.tour__layer video { scale: calc(1 + var(--out) * 0.06); }
.tour__shade { position: absolute; inset: 0; pointer-events: none; background:
  linear-gradient(to bottom, color-mix(in srgb, var(--surface-dark) 60%, transparent) 0, transparent 22%),
  linear-gradient(to top, color-mix(in srgb, var(--surface-dark) 96%, transparent) 0, color-mix(in srgb, var(--surface-dark) 72%, transparent) 26%, transparent 58%); }

.tour__toggle { position: absolute; right: 16px; top: 88px; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--surface-dark) 70%, transparent); border: 1px solid var(--line-dark); transition: scale var(--dur-fast) var(--ease-smooth), background-color var(--dur-fast); }
.tour__toggle:hover { scale: 1.08; background: var(--surface-dark); }
.tour__toggle svg { width: 20px; height: 20px; fill: var(--on-dark); }
.tour__toggle .i-play, .tour__toggle[aria-pressed="true"] .i-pause { display: none; }
.tour__toggle[aria-pressed="true"] .i-play { display: block; }

.tour__captions { position: absolute; inset: auto 0 0 0; padding: 0 var(--pad) calc(54px + env(safe-area-inset-bottom)); pointer-events: none; }
.cap { position: absolute; inset: auto var(--pad) calc(54px + env(safe-area-inset-bottom)) var(--pad); opacity: 0; translate: 0 26px; transition: opacity 450ms var(--ease-smooth), translate 600ms var(--ease-smooth); }
.cap.is-active { opacity: 1; translate: 0 0; transition-delay: 120ms; }
.cap__num { font-family: var(--font-display); font-weight: 800; font-size: 1rem; letter-spacing: .08em; color: var(--accent); }
.cap__num span { color: var(--on-dark-muted); font-weight: 600; }
.cap__title { font-size: clamp(1.875rem, 7vw, 3.25rem); margin-block: 6px 10px; }
.cap__text { font-size: 1rem; line-height: 1.55; color: color-mix(in srgb, var(--on-dark) 86%, transparent); max-width: 46ch; }
.cap__tags { display: none; }

.rail { position: absolute; inset: auto var(--pad) calc(22px + env(safe-area-inset-bottom)) var(--pad); display: flex; gap: 6px; }
.rail__btn { flex: 1; padding-block: 10px; text-align: left; }
.rail__btn i { display: block; height: 3px; border-radius: 3px; background: color-mix(in srgb, #fff 26%, transparent); position: relative; overflow: hidden; overflow: clip; --f: 0; }
.rail__btn i::after { content: ''; position: absolute; inset: 0; background: var(--accent); transform-origin: 0 50%; scale: var(--f) 1; }
.rail__btn span { display: none; }

/* Escritorio: video enmarcado + texto al lado (menos ampliación = imagen más nítida) */
@media (min-width: 1024px) and (min-aspect-ratio: 4/5) and (min-height: 600px) {
  .tour__stage { display: grid; grid-template-columns: minmax(300px, 30%) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto; column-gap: clamp(28px, 4vw, 64px); padding: 104px var(--pad) 26px; }
  .tour__amb { display: block; position: absolute; inset: 0; }
  .tour__amb span { position: absolute; inset: -6%; background: center / cover no-repeat; opacity: 0; transition: opacity 900ms ease; }
  .tour__amb span.is-active { opacity: .34; }
  .tour__amb::after { content: ''; position: absolute; inset: 0; background: radial-gradient(120% 100% at 70% 50%, transparent, var(--surface-dark) 85%); }

  .tour__frame { position: relative; inset: auto; grid-column: 2; grid-row: 1; align-self: center; justify-self: end; width: min(100%, calc((100dvh - 236px) * 16 / 9)); aspect-ratio: 16 / 9; border-radius: var(--radius); box-shadow: 0 40px 90px -40px color-mix(in srgb, #000 60%, var(--primary)); border: 1px solid var(--line-dark); }
  .tour__shade { display: none; }
  .tour__toggle { top: auto; bottom: 16px; }

  .tour__captions { position: relative; inset: auto; grid-column: 1; grid-row: 1; padding: 0; }
  .cap { inset: 0; display: flex; flex-direction: column; justify-content: center; }
  .cap__title { font-size: clamp(2.25rem, 3.6vw, 3.5rem); margin-block: 10px 16px; }
  .cap__text { font-size: 1.0625rem; line-height: 1.65; }
  .cap__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
  .chip { padding: 6px 14px; border-radius: 999px; font-size: .8125rem; font-weight: 500; line-height: 1.4; color: var(--on-dark); background: color-mix(in srgb, #fff 9%, transparent); border: 1px solid var(--line-dark); }

  .rail { position: relative; inset: auto; grid-column: 1 / -1; grid-row: 2; gap: 14px; margin-top: 22px; }
  .rail__btn { padding-block: 8px 0; }
  .rail__btn span { display: block; margin-top: 10px; font-size: .8125rem; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--on-dark-muted); transition: color var(--dur-fast); }
  .rail__btn:hover span, .rail__btn[aria-current="true"] span { color: var(--on-dark); }
}

/* Sin JS: lista simple de espacios */
.no-js .tour { height: auto; padding: 100px var(--pad); }
.no-js .tour__stage { position: static; height: auto; display: block; padding: 0; }
.no-js .tour__frame, .no-js .rail, .no-js .tour__amb { display: none; }
.no-js .tour__captions { position: static; padding: 0; display: grid; gap: 40px; }
.no-js .cap { position: static; opacity: 1; translate: none; }

/* Espacios (bento) */
.spaces { padding-block: clamp(90px, 12vw, 160px); content-visibility: auto; contain-intrinsic-size: auto 1400px; }
.spaces__head { display: grid; gap: 16px; margin-bottom: clamp(36px, 5vw, 64px); max-width: 720px; }
.bento { display: grid; grid-template-columns: repeat(6, 1fr); grid-auto-rows: clamp(200px, 21vw, 290px); gap: clamp(12px, 1.6vw, 22px); }
.bento__cell { grid-column: span 3; }
.bento__cell--xl { grid-row: span 2; }
.bento__cell--s { grid-column: span 2; }
.bento__cell--l { grid-column: span 4; }
.card { position: relative; width: 100%; height: 100%; display: block; text-align: left; border-radius: var(--radius); overflow: hidden; overflow: clip; color: var(--on-dark); background: var(--surface-dark); box-shadow: 0 24px 50px -30px color-mix(in srgb, var(--primary) 70%, transparent); transition: translate var(--dur-fast) var(--ease-smooth), box-shadow var(--dur-fast) var(--ease-smooth); --mx: 50%; --my: 50%; }
.card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: scale 900ms var(--ease-smooth); }
.card::before { content: ''; position: absolute; inset: 0; z-index: 1; background: linear-gradient(to top, color-mix(in srgb, var(--surface-dark) 94%, transparent) 0, color-mix(in srgb, var(--surface-dark) 40%, transparent) 46%, transparent 72%); }
.card::after { content: ''; position: absolute; inset: 0; z-index: 1; opacity: 0; transition: opacity var(--dur-fast); background: radial-gradient(340px circle at var(--mx) var(--my), color-mix(in srgb, #fff 20%, transparent), transparent 70%); }
.card__body { position: absolute; z-index: 2; inset: auto 0 0 0; padding: clamp(18px, 2vw, 28px); display: grid; gap: 4px; }
.card__num { font-family: var(--font-display); font-weight: 800; font-size: .875rem; letter-spacing: .1em; color: var(--accent); }
.card__title { font-family: var(--font-display); font-weight: 800; font-size: clamp(1.25rem, 2vw, 1.75rem); letter-spacing: -0.02em; line-height: 1.15; }
.card__more { font-size: .875rem; font-weight: 500; color: var(--on-dark-muted); display: inline-flex; gap: 8px; margin-top: 4px; }
.card__more b { font-weight: 500; transition: translate var(--dur-fast) var(--ease-smooth); }
@media (hover: hover) {
  .card:hover { translate: 0 -6px; box-shadow: 0 34px 60px -28px color-mix(in srgb, var(--primary) 85%, transparent); }
  .card:hover img { scale: 1.06; }
  .card:hover::after { opacity: 1; }
  .card:hover .card__more b { translate: 6px 0; }
}
@media (max-width: 800px) {
  .bento { grid-template-columns: 1fr 1fr; grid-auto-rows: clamp(170px, 46vw, 260px); }
  .bento__cell, .bento__cell--s, .bento__cell--l { grid-column: span 1; }
  .bento__cell--xl { grid-column: span 2; grid-row: span 1; }
  .card__more { display: none; }
}

/* Contacto */
.contact { position: relative; overflow: hidden; overflow: clip; background: var(--surface-dark); color: var(--on-dark); padding-block: clamp(100px, 13vw, 180px); }
.contact__inner { position: relative; display: grid; gap: clamp(32px, 5vw, 72px); grid-template-columns: 1.15fr .85fr; align-items: end; }
.contact h2 { margin-block: 18px 18px; }
.contact__lead { color: var(--on-dark-muted); max-width: 44ch; }
.contact__actions { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.contact__empty { font-size: .9375rem; padding: 14px 18px; border-radius: 16px; border: 1px dashed color-mix(in srgb, var(--accent) 60%, transparent); color: var(--accent); }
@media (max-width: 800px) { .contact__inner { grid-template-columns: 1fr; } .contact__actions .btn { width: 100%; } }

/* Footer */
.footer { background: #071127; color: var(--on-dark-muted); padding-block: 30px calc(30px + env(safe-area-inset-bottom)); font-size: .875rem; }
.footer__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 28px; }
.footer__brand { font-family: var(--font-display); font-weight: 600; color: var(--on-dark); }
.footer__brand b { color: var(--accent); font-weight: 800; }
.footer__top { text-decoration: none; }
.footer__top:hover { color: var(--on-dark); }

/* Fundido breve al cambiar de idioma (solo contenido, no botones) */
main, .footer, .nav__links { transition: opacity 180ms ease; }
.is-switching main, .is-switching .footer { opacity: 0; }

/* ---------- 6. Keyframes ---------- */
@keyframes spin { to { --angle: 360deg; } }
@keyframes shimmer { to { background-position: -220% 0; } }
@keyframes pulse { 50% { opacity: .35; } }
@keyframes drip { 0% { translate: 0 -100%; } 60%, 100% { translate: 0 100%; } }

/* ---------- 7. Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .glow::before, .grad, .hero__card-dot, .hero__scroll-line::after { animation: none; }
  .hero__media { scale: 1; }
  .hero__content { translate: none; }
  .reveal { opacity: 1; translate: none; transition: none; }
  .statement__text .word { opacity: 1; }
  .cap, .card, .card img, .btn { transition: opacity 200ms linear; }
  .tour__layer video { scale: 1; }
}

/* ---------- 8. Navegadores sin color-mix() (Safari < 16.2): fondos de respaldo ---------- */
@supports not (color: color-mix(in srgb, red, blue)) {
  :root { --on-dark-muted: rgba(243, 246, 251, .68); --line-dark: rgba(255, 255, 255, .14); }
  .nav { background: rgba(10, 23, 48, .82); }
  .nav.is-scrolled { background: rgba(10, 23, 48, .94); }
  .lang, .nav__burger { background: rgba(255, 255, 255, .12); }
  .btn--ghost { border-color: rgba(255, 255, 255, .34); background: rgba(255, 255, 255, .08); }
  .hero__shade { background: linear-gradient(to top, rgba(10, 23, 48, .96) 0%, rgba(10, 23, 48, .62) 42%, rgba(10, 23, 48, .3) 72%, rgba(10, 23, 48, .55) 100%); }
  .hero__lead, .cap__text { color: rgba(243, 246, 251, .86); }
  .hero__card, .tour__toggle { background: rgba(10, 23, 48, .7); }
  .tour__shade { background: linear-gradient(to bottom, rgba(10, 23, 48, .6) 0, transparent 22%), linear-gradient(to top, rgba(10, 23, 48, .96) 0, rgba(10, 23, 48, .72) 26%, transparent 58%); }
  .rail__btn i { background: rgba(255, 255, 255, .26); }
  .card::before { background: linear-gradient(to top, rgba(10, 23, 48, .94) 0, rgba(10, 23, 48, .4) 46%, transparent 72%); }
  .chip { background: rgba(255, 255, 255, .09); }
  .contact__empty { border-color: rgba(246, 178, 27, .6); }
}
