:root {
  --bg: #081019;
  --bg-deep: #04080f;
  --panel: rgba(10, 21, 33, 0.68);
  --panel-border: rgba(127, 170, 219, 0.16);
  --text: #f4f8fb;
  --muted: rgba(224, 236, 245, 0.74);
  --muted-strong: rgba(233, 242, 248, 0.92);
  --cyan: #84dbff;
  --mint: #7cf5cf;
  --amber: #ffd36f;
  --shadow: 0 32px 90px rgba(0, 0, 0, 0.32);
  --radius-xl: 34px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 999px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: "Instrument Sans", system-ui, sans-serif;
  background:
    radial-gradient(circle at 20% 20%, rgba(124, 245, 207, 0.16), transparent 26%),
    radial-gradient(circle at 80% 12%, rgba(132, 219, 255, 0.15), transparent 22%),
    radial-gradient(circle at 52% 78%, rgba(255, 211, 111, 0.11), transparent 24%),
    linear-gradient(180deg, #0c1623 0%, var(--bg) 44%, var(--bg-deep) 100%);
}

main {
  display: block;
}

a {
  color: inherit;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.14;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 160px 160px;
  mask-image: radial-gradient(circle at center, black 44%, transparent 88%);
}

.page-shell {
  position: relative;
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 36px;
}

.topbar,
.hero,
.capabilities,
.foot {
  position: relative;
  z-index: 1;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.03)),
    rgba(255, 255, 255, 0.02);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.mark svg {
  width: 20px;
  height: 20px;
}

.brand span {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 4px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
}

.lang-button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--muted);
  min-height: 32px;
  min-width: 44px;
  padding: 0 14px;
  border-radius: var(--radius-sm);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease;
}

.lang-button:hover {
  color: var(--muted-strong);
}

.lang-button.is-active {
  color: #071017;
  background: rgba(247, 251, 255, 0.96);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
}

.topbar-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 15px;
  border-radius: var(--radius-sm);
  color: #09111b;
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
  background: linear-gradient(135deg, #f7fbff 0%, #bee9ff 100%);
  box-shadow: 0 10px 28px rgba(91, 176, 230, 0.18);
}

.hero {
  padding: 48px 0 40px;
}

.hero-centered {
  min-height: 76vh;
  display: grid;
  place-items: center;
}

.bubble-stage {
  position: absolute;
  inset: 0;
  border-radius: calc(var(--radius-xl) + 8px);
  overflow: hidden;
  pointer-events: none;
}

.bubble-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 24% 28%, rgba(124, 245, 207, 0.14), transparent 24%),
    radial-gradient(circle at 74% 20%, rgba(132, 219, 255, 0.12), transparent 24%),
    radial-gradient(circle at 62% 76%, rgba(255, 211, 111, 0.11), transparent 26%);
}

.bubble-layer {
  position: absolute;
  inset: 0;
}

.hero-stack {
  position: relative;
  z-index: 1;
  isolation: isolate;
  max-width: 850px;
  text-align: center;
  padding: 44px 24px;
}

.hero-stack::before {
  content: "";
  position: absolute;
  inset: -36px -28px;
  z-index: -1;
  border-radius: 44px;
  background:
    radial-gradient(circle at center, rgba(7, 15, 24, 0.78) 0%, rgba(7, 15, 24, 0.64) 44%, rgba(7, 15, 24, 0.18) 74%, transparent 100%);
  filter: blur(8px);
}

.eyebrow,
.section-label {
  margin: 0 0 16px;
  color: var(--mint);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  letter-spacing: -0.05em;
}

h1 {
  font-family: "Space Grotesk", sans-serif;
  font-size: clamp(3.5rem, 9vw, 7.2rem);
  line-height: 0.94;
  max-width: 10ch;
  margin-inline: auto;
}

.lede {
  margin: 24px auto 0;
  max-width: 34ch;
  color: var(--muted-strong);
  font-size: clamp(1.1rem, 1.8vw, 1.28rem);
  line-height: 1.74;
}

.hero-actions {
  display: flex;
  justify-content: center;
  margin-top: 30px;
}

.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0 24px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-size: 1rem;
  font-weight: 700;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.cta:hover {
  transform: translateY(-1px);
}

.cta.primary {
  color: #071017;
  background: linear-gradient(135deg, #fdfefe 0%, #a7e6ff 72%, #7cf5cf 100%);
  box-shadow: 0 18px 34px rgba(74, 165, 210, 0.22);
}

.proof-strip {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  margin: 26px 0 0;
  list-style: none;
}

.proof-strip li {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: var(--muted-strong);
  font-size: 0.92rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
}

.bubble {
  position: absolute;
  max-width: 220px;
  padding: 14px 16px;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(19, 34, 48, 0.86), rgba(9, 17, 26, 0.92)),
    rgba(10, 21, 33, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.09);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.18);
  color: var(--muted-strong);
  opacity: 0;
  transform: translate3d(0, 18px, 0) scale(0.96);
  animation: bubbleFade 7.6s ease-in-out forwards;
}

.bubble.is-static {
  max-width: clamp(148px, 14vw, 188px);
  padding: 12px 14px;
  opacity: 1;
  transform: translate3d(0, 0, 0);
  animation: none;
}

.bubble::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.03);
  pointer-events: none;
}

.bubble-title {
  display: block;
  color: var(--text);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.bubble-body {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.48;
}

.bubble.is-static .bubble-title {
  font-size: 0.88rem;
}

.bubble.is-static .bubble-body {
  margin-top: 6px;
  font-size: 0.8rem;
  line-height: 1.38;
}

.bubble-tone-cyan {
  box-shadow: 0 20px 40px rgba(81, 165, 220, 0.14);
}

.bubble-tone-mint {
  box-shadow: 0 20px 40px rgba(110, 219, 190, 0.14);
}

.bubble-tone-amber {
  box-shadow: 0 20px 40px rgba(226, 187, 91, 0.14);
}

.mobile-story {
  display: none;
}

.simple-section {
  padding: 18px 0 22px;
}

.centered-head {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

h2 {
  font-family: "Space Grotesk", sans-serif;
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1;
  max-width: 11ch;
  margin-inline: auto;
}

.section-head p:last-child {
  margin: 18px auto 0;
  max-width: 46ch;
  color: var(--muted);
  font-size: 1.04rem;
  line-height: 1.72;
}

.simple-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 30px;
}

.capability-grid {
  display: grid;
  gap: 16px;
}

.capability-card {
  min-height: 210px;
  padding: 22px;
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(18, 30, 44, 0.86), rgba(8, 15, 24, 0.92)),
    var(--panel);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.16);
}

.card-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: rgba(132, 219, 255, 0.12);
  color: var(--cyan);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.capability-card h3 {
  margin-top: 18px;
  font-size: 1.24rem;
  line-height: 1.06;
}

.capability-card p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.66;
}

.story-stream {
  position: relative;
}

.story-sentinel {
  width: 100%;
  height: 28px;
}

.story-bubble {
  position: relative;
  display: block;
  max-width: min(86%, 390px);
  padding: 18px 18px 16px;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(19, 34, 48, 0.9), rgba(9, 17, 26, 0.94)),
    rgba(10, 21, 33, 0.76);
  box-shadow: 0 22px 52px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: translate3d(0, 28px, 0) scale(0.97);
  transition:
    opacity 420ms ease,
    transform 640ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.story-bubble.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

.story-bubble.align-start {
  justify-self: start;
  border-bottom-left-radius: 12px;
}

.story-bubble.align-end {
  justify-self: end;
  border-bottom-right-radius: 12px;
}

.story-bubble::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.03);
  pointer-events: none;
}

.foot {
  display: flex;
  justify-content: center;
  padding-top: 24px;
  color: rgba(233, 242, 248, 0.45);
  font-size: 0.84rem;
}

@keyframes bubbleFade {
  0% {
    opacity: 0;
    transform: translate3d(0, 18px, 0) scale(0.96);
  }

  12% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }

  76% {
    opacity: 1;
    transform: translate3d(0, -8px, 0) scale(1);
  }

  100% {
    opacity: 0;
    transform: translate3d(0, -20px, 0) scale(0.98);
  }
}

@media (max-width: 1180px) {
  .page-shell {
    width: min(100% - 32px, 1100px);
  }

  .simple-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 901px) {
  html,
  body {
    height: 100%;
    overflow: hidden;
  }

  body {
    min-height: 100vh;
  }

  .page-shell {
    min-height: 100vh;
    display: grid;
    grid-template-rows: auto 1fr auto;
    padding-bottom: 18px;
  }

  main {
    min-height: 0;
  }

  .hero {
    padding: 22px 0 8px;
  }

  .hero-centered {
    min-height: 0;
    height: 100%;
  }

  .hero-stack {
    max-width: 760px;
    padding: 22px 24px 18px;
  }

  h1 {
    font-size: clamp(3.9rem, 8vw, 6.3rem);
    max-width: 9.4ch;
  }

  .lede {
    max-width: 31ch;
    font-size: clamp(1.04rem, 1.5vw, 1.18rem);
  }

  .proof-strip {
    margin-top: 22px;
  }

  .simple-section {
    display: none;
  }

  .foot {
    padding-top: 0;
  }
}

@media (max-width: 900px) {
  .page-shell {
    padding-bottom: calc(118px + env(safe-area-inset-bottom));
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .topbar-meta {
    width: 100%;
    align-items: flex-start;
    justify-content: flex-start;
  }

  .lang-switch {
    width: min(100%, 176px);
  }

  .hero-centered {
    min-height: auto;
  }

  .bubble-stage {
    display: none;
  }

  .hero {
    padding: 34px 0 18px;
  }

  .hero-actions {
    position: fixed;
    left: 50%;
    bottom: calc(14px + env(safe-area-inset-bottom));
    z-index: 30;
    width: min(calc(100vw - 48px), 360px);
    margin-top: 0;
    transform: translateX(-50%);
  }

  .hero-actions .cta {
    width: 100%;
    min-height: 60px;
    box-shadow:
      0 22px 36px rgba(0, 0, 0, 0.24),
      0 12px 28px rgba(74, 165, 210, 0.18);
  }

  .hero-stack {
    max-width: 640px;
    padding: 26px 0 110px;
  }

  .hero-stack::before {
    inset: -22px -14px;
    background:
      radial-gradient(circle at center, rgba(7, 15, 24, 0.9) 0%, rgba(7, 15, 24, 0.78) 54%, rgba(7, 15, 24, 0.26) 84%, transparent 100%);
  }

  h1 {
    max-width: 9ch;
  }

  .mobile-story {
    display: block;
    padding: 6px 0 8px;
  }

  .centered-head {
    max-width: 640px;
    text-align: left;
  }

  h2 {
    margin-inline: 0;
    max-width: 11ch;
  }

  .section-head p:last-child {
    margin-left: 0;
    margin-right: 0;
    max-width: 34ch;
  }

  .story-stream {
    display: grid;
    gap: 18px;
    margin-top: 28px;
    padding: 6px 0 10px;
  }

  .simple-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .foot {
    padding-top: 12px;
  }
}

@media (max-width: 680px) {
  .page-shell {
    width: calc(100% - 22px);
    padding-top: 16px;
    padding-bottom: calc(114px + env(safe-area-inset-bottom));
  }

  .topbar {
    gap: 14px;
  }

  .topbar-meta {
    width: 100%;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: nowrap;
  }

  .lang-switch {
    width: 144px;
    min-width: 144px;
  }

  .topbar-link {
    margin-left: auto;
    flex: 0 0 auto;
    width: fit-content;
    max-width: calc(100% - 154px);
    min-height: 38px;
    padding-inline: 14px;
    font-size: 0.82rem;
    white-space: nowrap;
  }

  .cta {
    width: 100%;
  }

  .lang-button {
    flex: 1;
    min-width: 0;
    padding-inline: 12px;
    font-size: 0.82rem;
  }

  .hero-centered {
    min-height: calc(100svh - 152px);
  }

  .hero {
    padding: 30px 0 14px;
  }

  .hero-stack {
    padding: 14px 0 112px;
  }

  .hero-stack::before {
    inset: -18px -8px;
    background:
      radial-gradient(circle at center, rgba(7, 15, 24, 0.9) 0%, rgba(7, 15, 24, 0.76) 48%, rgba(7, 15, 24, 0.34) 78%, transparent 100%);
  }

  h1 {
    max-width: 8ch;
    font-size: clamp(3.2rem, 13vw, 4.8rem);
  }

  .lede {
    max-width: 100%;
    font-size: 1.05rem;
  }

  .bubble {
    max-width: 168px;
    padding: 11px 13px;
  }

  .bubble-title {
    font-size: 0.9rem;
  }

  .bubble-body {
    font-size: 0.84rem;
  }

  .mobile-story {
    padding-top: 8px;
  }

  .section-head p:last-child {
    max-width: 100%;
  }

  .story-stream {
    gap: 14px;
    margin-top: 22px;
  }

  .story-bubble {
    max-width: min(92%, 340px);
    padding: 16px 16px 14px;
  }

  .hero-actions {
    width: min(calc(100vw - 56px), 300px);
    bottom: calc(10px + env(safe-area-inset-bottom));
  }

  .hero-actions .cta {
    min-height: 56px;
  }

  html[lang="es"] .hero-stack {
    padding-bottom: 132px;
  }

  html[lang="es"] h1 {
    max-width: 8.8ch;
  }

  .simple-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
