@font-face {
  font-family: 'Poppins';
  src: url('/assets/fonts/poppins-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Poppins';
  src: url('/assets/fonts/poppins-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Inter Variable';
  src: url('/assets/fonts/inter-variable.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'JetBrains Mono';
  src: url('/assets/fonts/jetbrains-mono-variable.woff2') format('woff2');
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Sora';
  src: url('/assets/fonts/sora-700.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --deep-space: #020511;
  --ink: #f4f7ff;
  --muted: #8b9ecf;
  --blue: #2d70ff;
  --gold: #ffbe23;
  --violet: #7c5cff;
  font-family: 'Inter Variable', Inter, system-ui, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

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

html {
  min-width: 320px;
  height: 100%;
  min-height: 100%;
  overflow: hidden;
  background: var(--deep-space);
}

body {
  min-width: 320px;
  height: 100%;
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  overflow: hidden;
  background: var(--deep-space);
  color: var(--ink);
}

.site-loader {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 44%, rgb(28 74 181 / 0.19), transparent 31%),
    radial-gradient(circle at 20% 78%, rgb(112 62 210 / 0.09), transparent 32%),
    #020511;
  opacity: 1;
  visibility: visible;
  transition:
    opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 0s;
}

.site-loader::before {
  position: absolute;
  inset: -28%;
  content: '';
  background: conic-gradient(
    from 120deg at 50% 50%,
    transparent 0 31%,
    rgb(45 112 255 / 0.08) 39%,
    transparent 49% 77%,
    rgb(124 92 255 / 0.055) 84%,
    transparent 92%
  );
  filter: blur(42px);
  animation: loader-atmosphere 12s linear infinite;
}

.site-loader.is-complete {
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 0.85s;
}

.site-loader-lockup {
  position: relative;
  display: grid;
  justify-items: center;
  width: min(82vw, 24rem);
  transform: translateY(-1.5vh);
}

.site-loader-logo {
  display: block;
  width: clamp(14rem, 24vw, 20rem);
  height: auto;
  filter:
    drop-shadow(0 0 2rem rgb(45 112 255 / 0.3))
    drop-shadow(0 0.7rem 1.8rem rgb(0 0 0 / 0.35));
  animation: loader-logo-breathe 2.8s ease-in-out infinite;
}

.site-loader-meter {
  position: relative;
  width: min(15rem, 62vw);
  height: 2px;
  margin-top: 2rem;
  overflow: hidden;
  border-radius: 999px;
  background: rgb(126 159 225 / 0.13);
  box-shadow: 0 0 1.4rem rgb(45 112 255 / 0.08);
}

.site-loader-progress {
  --loader-progress: 0;
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #2d70ff, #77a7ff 58%, #ffbe23 118%);
  box-shadow: 0 0 0.85rem rgb(45 112 255 / 0.75);
  transform: scaleX(var(--loader-progress));
  transform-origin: left center;
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.space-scene,
.space-fallback,
#space-canvas,
.space-vignette,
.space-grid,
.ambient-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.space-scene {
  z-index: 0;
  overflow: hidden;
  background: var(--deep-space);
}

.space-fallback {
  background:
    radial-gradient(circle at 76% 24%, rgb(45 112 255 / 0.24), transparent 25%),
    radial-gradient(circle at 18% 66%, rgb(124 92 255 / 0.11), transparent 32%),
    linear-gradient(145deg, #020511 0%, #040a1c 48%, #020715 100%);
}

#space-canvas {
  width: 100%;
  height: 100%;
}

.ambient-glow {
  border-radius: 999px;
  filter: blur(80px);
  opacity: 0.18;
  will-change: transform;
}

.ambient-glow--blue {
  width: 42vw;
  height: 42vw;
  min-width: 22rem;
  min-height: 22rem;
  inset: auto -14vw -24vw auto;
  background: rgb(45 112 255 / 0.5);
  animation: blue-drift 18s ease-in-out infinite alternate;
}

.ambient-glow--violet {
  width: 32vw;
  height: 32vw;
  min-width: 18rem;
  min-height: 18rem;
  inset: -18vw auto auto -14vw;
  background: rgb(124 92 255 / 0.35);
  animation: violet-drift 22s ease-in-out infinite alternate;
}

.space-grid {
  top: auto;
  left: -20vw;
  bottom: -42vh;
  width: 140vw;
  height: 88vh;
  opacity: 0.2;
  background-image:
    linear-gradient(rgb(45 112 255 / 0.17) 1px, transparent 1px),
    linear-gradient(90deg, rgb(45 112 255 / 0.17) 1px, transparent 1px);
  background-size: clamp(46px, 5vw, 76px) clamp(46px, 5vw, 76px);
  transform: perspective(520px) rotateX(64deg);
  transform-origin: center top;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 38%, #000 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 38%, #000 100%);
}

.space-vignette {
  background:
    radial-gradient(circle at 50% 47%, transparent 18%, rgb(2 5 17 / 0.2) 62%, rgb(2 5 17 / 0.78) 112%),
    linear-gradient(to bottom, rgb(2 5 17 / 0.4), transparent 22%, transparent 73%, rgb(2 5 17 / 0.52));
}

.earth-stage {
  position: fixed;
  z-index: 0;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.earth-stage.is-ready {
  opacity: 0.96;
}

#earth-canvas {
  position: absolute;
  z-index: 1;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  filter: saturate(1.12) contrast(1.08);
}

.page-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100vh;
  min-height: 100svh;
  padding:
    max(1.5rem, env(safe-area-inset-top))
    clamp(1.25rem, 4vw, 4.5rem)
    max(1.35rem, env(safe-area-inset-bottom));
  opacity: 0;
  transition: opacity 0.72s 0.08s cubic-bezier(0.22, 1, 0.36, 1);
}

body.scene-ready .page-shell {
  opacity: 1;
}

body:not(.scene-ready) .site-header,
body:not(.scene-ready) .headline-launch,
body:not(.scene-ready) .headline-word,
body:not(.scene-ready) .headline-orbit,
body:not(.scene-ready) h1 em,
body:not(.scene-ready) .intro,
body:not(.scene-ready) .site-footer {
  animation-play-state: paused;
}

.site-header {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 7rem;
  padding-top: clamp(1.4rem, 4vh, 3.2rem);
  animation: reveal-down 0.9s 0.05s both cubic-bezier(0.22, 1, 0.36, 1);
}

.language-switcher {
  position: relative;
  z-index: 5;
  margin-right: 0.35rem;
}

.language-trigger {
  display: inline-flex;
  width: 2.25rem;
  height: 1.85rem;
  align-items: center;
  justify-content: center;
  gap: 0.18rem;
  padding: 0;
  border: 1px solid rgb(91 139 241 / 0.24);
  border-radius: 0.58rem;
  background: rgb(7 15 38 / 0.68);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.06),
    0 0.65rem 1.8rem rgb(0 0 0 / 0.2);
  color: #dce8ff;
  cursor: pointer;
  backdrop-filter: blur(14px);
  transition: border-color 180ms ease, background 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.language-trigger:hover,
.language-trigger[aria-expanded='true'] {
  border-color: rgb(91 139 241 / 0.58);
  background: rgb(12 27 64 / 0.82);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.08),
    0 0 1.25rem rgb(45 112 255 / 0.18);
}

.language-trigger.is-switching {
  pointer-events: none;
}

.language-trigger:focus-visible,
.language-option:focus-visible {
  outline: 2px solid rgb(92 143 255 / 0.72);
  outline-offset: 3px;
}

.language-flag,
.language-option-flag {
  display: block;
  flex: none;
  height: auto;
  box-shadow: 0 0 0 1px rgb(255 255 255 / 0.12);
}

.language-flag {
  width: 1.12rem;
  max-height: 0.78rem;
  border-radius: 0.12rem;
}

.language-caret {
  width: 0;
  height: 0;
  border-top: 0.2rem solid currentColor;
  border-right: 0.16rem solid transparent;
  border-left: 0.16rem solid transparent;
  opacity: 0.58;
  transition: transform 180ms ease;
}

.language-trigger[aria-expanded='true'] .language-caret {
  transform: rotate(180deg);
}

.language-menu {
  position: absolute;
  bottom: calc(100% + 0.6rem);
  left: 50%;
  display: grid;
  width: 9.2rem;
  gap: 0.25rem;
  padding: 0.38rem;
  border: 1px solid rgb(91 139 241 / 0.26);
  border-radius: 0.9rem;
  background: rgb(4 10 27 / 0.94);
  box-shadow:
    inset 0 1px 0 rgb(255 255 255 / 0.055),
    0 1rem 3rem rgb(0 0 0 / 0.42),
    0 0 2rem rgb(45 112 255 / 0.08);
  transform: translateX(-50%);
  backdrop-filter: blur(20px);
}

.language-menu[hidden] {
  display: none;
}

.language-option {
  display: flex;
  align-items: center;
  gap: 0.62rem;
  width: 100%;
  padding: 0.62rem 0.68rem;
  border: 0;
  border-radius: 0.62rem;
  background: transparent;
  color: #aebfe5;
  font: 500 0.82rem/1 'Inter Variable', Inter, system-ui, sans-serif;
  text-align: left;
  cursor: pointer;
  transition: color 160ms ease, background 160ms ease;
}

.language-option:hover,
.language-option.is-active {
  background: rgb(45 112 255 / 0.13);
  color: #f5f8ff;
}

.language-option-flag {
  width: 1.38rem;
  max-height: 0.94rem;
  border-radius: 0.13rem;
}

.brand-wordmark {
  display: block;
  width: clamp(14rem, 20vw, 19rem);
  height: auto;
  filter:
    drop-shadow(0 0 1.8rem rgb(45 112 255 / 0.2))
    drop-shadow(0 0.65rem 1.6rem rgb(0 0 0 / 0.3));
}

.hero {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  padding: clamp(3.5rem, 8vh, 7rem) 0;
  isolation: isolate;
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  width: min(100%, 78rem);
  flex-direction: column;
  align-items: center;
  text-align: center;
}

h1 {
  margin: 0;
  font-family: 'Poppins', 'Inter Variable', sans-serif;
  font-weight: 700;
  text-wrap: balance;
  text-shadow: 0 1.2rem 4.5rem rgb(0 0 0 / 0.42);
  perspective: 800px;
}

.headline-line {
  display: block;
}

.headline-launch {
  position: relative;
  padding: 0.04em 0.08em 0.14em;
  margin: -0.04em -0.08em -0.14em;
  overflow: visible;
  font-size: clamp(2.65rem, 5.4vw, 5.35rem);
  letter-spacing: -0.064em;
  line-height: 1.12;
  opacity: 0;
  filter: blur(9px);
  transform: translateY(0.3em) scale(0.975);
  animation: launch-line-arrival 0.9s 0.18s both cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, filter, transform;
}

.headline-word {
  display: inline-block;
  padding-bottom: 0.1em;
  margin-bottom: -0.1em;
  overflow: visible;
  opacity: 1;
  color: #eef4ff;
  vertical-align: bottom;
}

.headline-soft-accent {
  color: #abc5f8;
  text-shadow: 0 0 1.35rem rgb(80 137 255 / 0.16);
}

.headline-orbit {
  margin-top: 0.04em;
  opacity: 0;
  font-family: 'Sora', 'Inter Variable', sans-serif;
  font-size: clamp(3.25rem, 7vw, 7rem);
  font-weight: 700;
  letter-spacing: -0.073em;
  line-height: 0.96;
  color: #eef4ff;
  filter: blur(14px);
  transform: translateY(0.42em) scale(0.91);
  animation: orbit-line-arrival 1.05s 0.75s both cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, filter, transform;
}

h1 em {
  position: relative;
  color: transparent;
  font-style: normal;
  background: linear-gradient(112deg, #edf4ff 0%, #70a5ff 18%, #1761ff 42%, #9c7cff 62%, #ffca46 79%, #4e8bff 100%);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  filter: drop-shadow(0 0 2.35rem rgb(45 112 255 / 0.3));
  animation: orbit-color-drift 3.8s 1.2s ease-in-out infinite alternate;
}

.intro {
  max-width: 42rem;
  margin: clamp(1.7rem, 4vh, 2.65rem) 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  font-weight: 520;
  letter-spacing: -0.015em;
  line-height: 1.7;
  text-wrap: balance;
  animation: reveal-up 0.95s 1.02s both cubic-bezier(0.22, 1, 0.36, 1);
}

.intro-line {
  display: block;
}

.intro-line + .intro-line {
  margin-top: 0.08em;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.28em;
  color: rgb(154 177 225 / 0.82);
  font-family: 'Inter Variable', Inter, system-ui, sans-serif;
  font-size: clamp(0.8rem, 0.92vw, 0.9rem);
  font-weight: 500;
  letter-spacing: 0.015em;
  line-height: 1;
  animation: reveal-up 0.9s 1.16s both cubic-bezier(0.22, 1, 0.36, 1);
}

.footer-brand {
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
}

.footer-brand-gg {
  color: rgb(45 112 255);
  text-shadow:
    0 0 10px rgb(45 112 255 / 0.52),
    0 0 24px rgb(45 112 255 / 0.24);
}

.footer-brand-space {
  color: rgb(248 250 255);
  text-shadow: 0 0 10px rgb(248 250 255 / 0.18);
}

@keyframes reveal-up {
  from { opacity: 0; transform: translateY(1.4rem); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes loader-atmosphere {
  to { transform: rotate(1turn) scale(1.04); }
}

@keyframes loader-logo-breathe {
  0%, 100% { opacity: 0.82; transform: scale(0.992); }
  50% { opacity: 1; transform: scale(1); }
}

@keyframes launch-line-arrival {
  64% {
    opacity: 1;
    filter: blur(0);
    transform: translateY(-0.025em) scale(1.006);
  }
  100% {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0) scale(1);
  }
}

@keyframes reveal-down {
  from { opacity: 0; transform: translateY(-1rem); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes orbit-line-arrival {
  62% {
    opacity: 1;
    filter: blur(0);
    transform: translateY(-0.025em) scale(1.008);
  }
  100% {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0) scale(1);
  }
}

@keyframes orbit-color-drift {
  from { background-position: 0% 50%; }
  to { background-position: 100% 50%; }
}

@keyframes blue-drift {
  to { transform: translate(-5vw, -5vh) scale(1.1); }
}

@keyframes violet-drift {
  to { transform: translate(6vw, 4vh) scale(1.12); }
}

@media (max-width: 720px) {
  .page-shell {
    padding-right: 1.25rem;
    padding-left: 1.25rem;
  }

  .site-header {
    justify-content: center;
    min-height: 5.5rem;
    padding-top: 1.1rem;
  }

  .brand-wordmark {
    width: 13.25rem;
  }

  .earth-stage.is-ready {
    opacity: 0.84;
  }

  #earth-canvas {
    filter: saturate(1.2) contrast(1.06) brightness(1.12);
  }

  .hero {
    padding: 3.2rem 0 4.25rem;
  }

  .headline-launch {
    font-size: clamp(2.15rem, 10vw, 2.75rem);
    line-height: 1.14;
  }

  html[lang='es'] .headline-launch {
    font-size: clamp(2rem, 9vw, 2.5rem);
  }

  .headline-orbit {
    margin-top: 0.14em;
    font-size: clamp(2.75rem, 12.5vw, 3.5rem);
    line-height: 0.98;
  }

  html[lang='es'] .headline-orbit {
    font-size: clamp(2.35rem, 11vw, 3.05rem);
  }

  .intro {
    max-width: 31rem;
    line-height: 1.62;
  }

}

@media (max-height: 760px) and (min-width: 721px) {
  .page-shell {
    padding-top: 1rem;
    padding-bottom: 1rem;
  }

  .hero {
    padding-top: 2.5rem;
    padding-bottom: 3rem;
  }

  .intro {
    margin-top: 1.35rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }

  .headline-word,
  .headline-orbit {
    opacity: 1 !important;
    filter: none !important;
    transform: none !important;
    animation-delay: 0ms !important;
  }

  .earth-stage {
    transition: none;
  }
}
