html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

html {
  background: #000000;
}

:root {
  --bg: #000000;
  --card: #111216;
}

body {
  background: #000000;
}

#services .services-launch,
#services .services-launch__scroll,
#services .services-launch__sticky,
#services .services-launch__scene {
  overflow: visible !important;
}

#services .services-launch {
  z-index: 8;
  pointer-events: none !important;
}

#services #servicesLaunchSvg {
  overflow: visible !important;
}

#services .ai-curve-wrap {
  z-index: 12;
}

#services .curve-overlay {
  pointer-events: auto !important;
}

#services .curve-card.is-visible {
  opacity: 1 !important;
  pointer-events: auto !important;
}

#services .curve-card__face.is-visible {
  display: flex !important;
}

.hero.intro,
.section-ai,
#contact,
.footer {
  background: #000000 !important;
}

.nav {
  background: var(--bg) !important;
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  backdrop-filter: blur(14px) saturate(150%);
}

.theme-light {
  --bg: #ffffff;
  --card: #ffffff;
  background: #ffffff;
}

.theme-light body {
  background: #ffffff;
}

.theme-light .nav {
  background: var(--bg) !important;
}

.brand {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.logo-pair {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.logo-secondary {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  object-fit: contain;
  object-position: center;
}

.logo {
  flex: 0 1 auto;
  width: auto;
  height: 30px;
  max-width: 154px;
  object-fit: contain;
  object-position: left center;
}

.theme-light .logo,
.theme-light .logo-secondary {
  filter: drop-shadow(0 1px 1px rgba(255, 255, 255, .72));
}

.theme-light .hero.intro,
.theme-light .section-ai,
.theme-light #contact,
.theme-light .footer {
  background: #ffffff !important;
}

.theme-light .hero.intro {
  isolation: isolate;
}

.theme-light .hero.intro:before {
  content: none;
}

.theme-light .intro-svg,
.theme-light .hero-copy,
.theme-light .hero-title-mobile {
  z-index: 2;
}

.balanced-cpu-mode #starfield,
.balanced-cpu-mode #pricing-canvas {
  transform: translateZ(0);
}

.balanced-cpu-mode .nav,
.balanced-cpu-mode .pricing-pass__body,
.balanced-cpu-mode .pricing-pass__stub {
  -webkit-backdrop-filter: blur(6px) !important;
  backdrop-filter: blur(6px) !important;
}

.balanced-cpu-mode #home:not(.is-motion-visible) *,
.balanced-cpu-mode #agents:not(.is-motion-visible) * {
  animation-play-state: paused !important;
}

.balanced-cpu-mode .section-ai:before {
  inset: -48px !important;
  will-change: transform;
}

.hero.intro {
  height: calc(100svh - var(--nav-h));
  min-height: 620px;
  flex-direction: column;
  gap: clamp(16px, 2.2vw, 24px);
  padding: clamp(48px, 8vw, 88px) clamp(18px, 5vw, 48px);
  text-align: center;
}

.intro-svg {
  --hero-title-fill: #ffffff;
  --hero-title-stroke: rgba(126, 224, 255, 0.16);
  --hero-title-shadow: rgba(126, 224, 255, 0.2);
  width: min(88vw, 1100px);
  max-height: 250px;
  overflow: visible;
  transform-origin: center;
  animation: hero-title-float 5.8s ease-in-out infinite;
  filter:
    drop-shadow(0 14px 20px rgba(0, 0, 0, 0.34))
    drop-shadow(0 0 7px var(--hero-title-shadow));
}

.theme-light .intro-svg {
  --hero-title-fill: #101319;
  --hero-title-stroke: rgba(255, 255, 255, 0.72);
  --hero-title-shadow: rgba(15, 23, 42, 0.13);
  filter:
    drop-shadow(0 16px 20px rgba(15, 23, 42, 0.13))
    drop-shadow(0 0 5px var(--hero-title-shadow));
}

.hero-flow-ready .intro-svg-text {
  font-size: var(--hero-flow-size, 120px) !important;
  will-change: font-size;
}

.intro-svg-text {
  fill: var(--hero-title-fill);
  stroke: var(--hero-title-stroke);
  stroke-linejoin: round;
  stroke-width: 1px;
  paint-order: stroke fill;
}

@keyframes hero-title-float {
  0%,
  100% {
    transform: translate3d(0, -10px, 0) scale(1.006);
  }

  50% {
    transform: translate3d(0, 11px, 0) scale(0.994);
  }
}

.hero-title-mobile {
  display: none;
}

.hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  width: min(720px, 92vw);
  margin-top: clamp(-18px, -1.4vw, -8px);
  opacity: var(--hero-copy-opacity, 1);
  transform: translate3d(0, var(--hero-copy-y, 0px), 0) scale(var(--hero-copy-scale, 1));
  transform-origin: center top;
  will-change: transform, opacity;
}

.hero-copy p {
  position: relative;
  margin: 0;
  color: color-mix(in oklab, var(--fg) 76%, transparent);
  font-size: clamp(17px, 1.55vw, 21px);
  line-height: 1.5;
  text-wrap: balance;
  text-shadow:
    0 12px 22px rgba(0, 0, 0, 0.34),
    0 0 10px rgba(126, 224, 255, 0.12);
  animation: hero-caption-float 5.4s ease-in-out infinite;
  will-change: transform;
}

.hero-copy p:after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -14px;
  width: min(360px, 72%);
  height: 1px;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(126, 224, 255, 0.48), transparent);
  opacity: 0.62;
  transform: translateX(-50%);
}

.theme-light .hero-copy p {
  color: color-mix(in oklab, var(--fg) 72%, transparent);
  text-shadow:
    0 12px 22px rgba(15, 23, 42, 0.12),
    0 0 1px rgba(255, 255, 255, 0.9);
}

.theme-light .hero-copy p:after {
  background: linear-gradient(90deg, transparent, rgba(18, 27, 46, 0.28), transparent);
  opacity: 0.5;
}

@keyframes hero-caption-float {
  0%,
  100% {
    transform: translate3d(0, 7px, 0);
  }

  50% {
    transform: translate3d(0, -7px, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-flow-ready .intro-svg-text {
    font-size: 120px !important;
  }

  .intro-svg,
  .hero-title-mobile {
    animation: none !important;
  }

  .hero-copy {
    opacity: 1 !important;
    transform: none !important;
  }

  .hero-copy p {
    animation: none !important;
    transform: none !important;
  }
}

@media (max-width: 700px) {
  :root {
    --nav-h: 96px;
  }

  .nav {
    height: var(--nav-h);
  }

  .nav-inner {
    position: relative;
    flex-wrap: wrap;
    align-content: center;
    gap: 6px 10px;
    padding: 8px 12px;
  }

  .brand,
  .actions {
    flex: 0 0 auto;
  }

  .actions {
    display: none;
  }

  .brand {
    max-width: calc(100% - 96px);
    overflow: hidden;
  }

  .logo-pair {
    max-width: 100%;
    overflow: hidden;
  }

  .logo,
  .logo-secondary {
    height: 22px;
  }

  .theme-toggle {
    --toggle-h: 26px;
    --toggle-w: 70px;
    --icon-size: 14px;
    --icon-shift: 9px;
  }

  .emoji {
    font-size: 18px;
  }

  .menu {
    order: 3;
    flex: 0 0 100%;
    justify-content: flex-start;
    gap: 14px;
    margin-top: 32px;
    padding: 0 2px 4px;
    overflow-x: auto;
  }

  .menu a {
    font-size: 13px;
    padding: 4px 0 6px;
    border-radius: 0;
  }

  .menu a:after {
    left: 0;
    right: 0;
    bottom: 1px;
  }

  .hero.intro {
    min-height: 600px;
    justify-content: center;
    gap: 18px;
    padding: 36px 18px 44px;
  }

  .intro-svg {
    display: none;
  }

  .hero-title-mobile {
    position: relative;
    z-index: 1;
    display: block;
    width: min(92vw, 520px);
    margin: 0;
    color: var(--fg);
    font-weight: 800;
    font-size: clamp(34px, 9.5vw, 44px);
    line-height: 0.96;
    letter-spacing: 0;
    text-align: center;
  }

  .hero-copy {
    width: 100%;
    max-width: calc(100vw - 36px);
    margin-top: 0;
    box-sizing: border-box;
  }

  .hero-copy p {
    max-width: 30ch;
    font-size: 16px;
    line-height: 1.48;
    overflow-wrap: break-word;
  }

  .hero.intro:after {
    content: none;
  }
}

@media (max-width: 420px) {
  .logo-secondary {
    display: none;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.theme-button {
  --button-size: 38px;
  --icon-size: 18px;
  --theme-button-gradient: var(--gradient);
  position: relative;
  display: inline-grid;
  place-items: center;
  width: var(--button-size);
  height: var(--button-size);
  padding: 0;
  appearance: none;
  border: 1px solid transparent;
  border-radius: 50%;
  color: #f4f7fb;
  background:
    linear-gradient(
      180deg,
      color-mix(in oklab, var(--card) 86%, #ffffff 10%),
      color-mix(in oklab, var(--card) 92%, #020617 8%)
    ) padding-box,
    var(--theme-button-gradient) border-box;
  box-shadow:
    0 10px 22px rgba(2, 8, 23, .24),
    0 0 18px rgba(255, 110, 196, .16),
    inset 0 1px 0 rgba(255, 255, 255, .14);
  cursor: pointer;
  isolation: isolate;
  transition:
    border-color .2s ease,
    box-shadow .2s ease,
    color .2s ease,
    transform .2s ease,
    background .2s ease;
}

.theme-button:before {
  content: "";
  position: absolute;
  inset: -5px;
  z-index: -1;
  border-radius: inherit;
  background: var(--theme-button-gradient);
  opacity: .2;
  filter: blur(8px);
  transition: opacity .2s ease, filter .2s ease;
}

.theme-button:hover {
  color: #ffffff;
  box-shadow:
    0 12px 26px rgba(2, 8, 23, .3),
    0 0 24px rgba(120, 115, 245, .22),
    inset 0 1px 0 rgba(255, 255, 255, .18);
  transform: translateY(-1px);
}

.theme-button:hover:before {
  opacity: .36;
  filter: blur(9px);
}

.theme-button:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px color-mix(in oklab, var(--bg) 76%, transparent),
    0 0 0 5px color-mix(in oklab, #7873f5 62%, transparent),
    0 12px 26px rgba(2, 8, 23, .24);
}

.theme-button__icon {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: currentColor;
}

.theme-button__icon:before {
  content: "";
  display: block;
  width: var(--icon-size);
  height: var(--icon-size);
  background: currentColor;
  mask: var(--theme-icon-mask) center / contain no-repeat;
  -webkit-mask: var(--theme-icon-mask) center / contain no-repeat;
}

.theme-button {
  --theme-icon-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.15' stroke-linecap='round' stroke-linejoin='round'><path d='M21 12.8A8.7 8.7 0 1 1 11.2 3a6.8 6.8 0 0 0 9.8 9.8z'/></svg>");
}

.theme-button.is-light {
  --theme-button-gradient: var(--gradient);
  --theme-icon-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.05' stroke-linecap='round' stroke-linejoin='round'><circle cx='12' cy='12' r='4'/><path d='M12 2v2.2M12 19.8V22M4.93 4.93l1.56 1.56M17.51 17.51l1.56 1.56M2 12h2.2M19.8 12H22M4.93 19.07l1.56-1.56M17.51 6.49l1.56-1.56'/></svg>");
  color: #1d4ed8;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .96), rgba(248, 250, 252, .86)) padding-box,
    var(--theme-button-gradient) border-box;
  box-shadow:
    0 10px 20px rgba(58, 123, 213, .16),
    0 0 18px color-mix(in oklab, var(--grad-glow) 46%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, .92);
}

.theme-button.is-light .theme-button__icon:before {
  background: var(--theme-button-gradient);
}

.theme-light .theme-button:hover {
  box-shadow:
    0 12px 24px rgba(58, 123, 213, .2),
    0 0 24px rgba(52, 199, 89, .16),
    inset 0 1px 0 rgba(255, 255, 255, .96);
}

.theme-light .theme-button:focus-visible {
  box-shadow:
    0 0 0 3px color-mix(in oklab, var(--bg) 76%, transparent),
    0 0 0 5px color-mix(in oklab, #007aff 52%, transparent),
    0 12px 24px rgba(58, 123, 213, .2);
}

.theme-light .theme-button:before {
  opacity: .14;
  filter: blur(7px);
}

.theme-light .theme-button:hover:before {
  opacity: .26;
}

@media (max-width: 1080px) {
  .theme-button {
    --button-size: 36px;
    --icon-size: 17px;
  }
}

@media (max-width: 820px) {
  .theme-button {
    --button-size: 34px;
    --icon-size: 16px;
  }
}

/* All page sections share the same pure light/dark background. */
main > section, .footer { background-color:var(--bg) !important; }

/* Services: omit the decorative multicolour progress rule. */
#services .services-launch__progress{display:none}

/* Let the next section follow the final Services content without a viewport-sized tail. */
#services.services-transition {min-height:0;}
#services .services-inner {padding-bottom:32px;}
