:root {
  --bg: #090909;
  --panel: rgba(255, 255, 255, 0.04);
  --panel-strong: rgba(255, 255, 255, 0.07);
  --text: #f4f2eb;
  --muted: #b6b0a2;
  --line: rgba(255, 255, 255, 0.1);
  --accent: #b7ff5e;
  --accent-2: #7af0ff;
  --max: 1240px;
  --hero-size: clamp(2.5rem, 5.5vw, 4.9rem);
  --section-title-size: clamp(2rem, 4vw, 3.6rem);
  --body-size: 1.02rem;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(122, 240, 255, 0.1), transparent 25%),
    radial-gradient(circle at top right, rgba(183, 255, 94, 0.08), transparent 20%),
    var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.4), transparent 80%);
  pointer-events: none;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.12;
  background-image: radial-gradient(rgba(255,255,255,0.35) 0.6px, transparent 0.6px);
  background-size: 12px 12px;
  mix-blend-mode: soft-light;
}

img {
  max-width: 100%;
}

.site-header,
.section,
.footer {
  width: min(calc(100% - 32px), var(--max));
  margin-inline: auto;
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 26px 0;
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(14px);
}

.brand,
.eyebrow,
.tag,
nav a {
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.brand {
  font-weight: 800;
  font-size: 0.95rem;
}

nav {
  display: flex;
  gap: 20px;
}

nav a,
.section-head a,
.contact-links a {
  color: var(--text);
  text-decoration: none;
}

nav a,
.section-head p,
.hero-copy,
.card p,
.about-copy,
.contact-panel p,
.metric-grid p,
.contact-links a {
  color: var(--muted);
}

.section {
  padding: 32px 0 48px;
}

.hero {
  padding-top: 40px;
  min-height: 82vh;
  display: grid;
  align-content: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 28px;
  align-items: center;
}

.hero-copy-wrap {
  position: relative;
  z-index: 1;
}

.eyebrow,
.tag {
  display: inline-flex;
  font-size: 0.72rem;
  color: var(--accent);
}

.hero h1,
.contact-panel h2 {
  font-size: var(--hero-size);
  line-height: 1.02;
  margin: 14px 0 18px;
  max-width: 13ch;
  letter-spacing: -0.05em;
}

.hero-title {
  display: flex;
  flex-direction: column;
}

.hero-title span {
  display: block;
  transform: translateY(36px);
  opacity: 0;
  filter: blur(8px);
}

body.loaded .hero-title span {
  animation: riseIn 900ms cubic-bezier(.2, .8, .2, 1) forwards;
}

body.loaded .hero-title span:nth-child(2) { animation-delay: 90ms; }
body.loaded .hero-title span:nth-child(3) { animation-delay: 180ms; }
body.loaded .hero-title span:nth-child(4) { animation-delay: 270ms; }

.hero-copy {
  max-width: 640px;
  font-size: var(--body-size);
  line-height: 1.75;
}

.split-line {
  transform: translateY(24px);
  opacity: 0;
  filter: blur(6px);
}

body.loaded .split-line {
  animation: riseIn 850ms cubic-bezier(.2, .8, .2, 1) forwards;
}

body.loaded .hero-copy.split-line { animation-delay: 320ms; }
body.loaded .hero-actions.split-line { animation-delay: 420ms; }
body.loaded .eyebrow.split-line { animation-delay: 40ms; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 22px;
}

.hero-orbital {
  position: relative;
  min-height: 620px;
  display: grid;
  place-items: center;
  --mx: 0px;
  --my: 0px;
}

.orbital-ring,
.orbital-core,
.float-card {
  will-change: transform;
}

.orbital-ring {
  position: absolute;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 50%;
  transform: translate3d(calc(var(--mx) * 0.12), calc(var(--my) * 0.12), 0);
}

.ring-1 {
  width: 480px;
  height: 480px;
  animation: rotateRing 20s linear infinite;
}

.ring-2 {
  width: 360px;
  height: 360px;
  border-style: dashed;
  animation: rotateRingReverse 16s linear infinite;
}

.ring-3 {
  width: 220px;
  height: 220px;
  border-color: rgba(183,255,94,0.22);
  animation: pulseRing 4s ease-in-out infinite;
}

.orbital-core {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(183,255,94,0.32), rgba(122,240,255,0.16) 42%, rgba(255,255,255,0.04) 70%);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 0 60px rgba(122,240,255,0.16);
  display: grid;
  place-items: center;
  backdrop-filter: blur(12px);
  transform: translate3d(calc(var(--mx) * -0.2), calc(var(--my) * -0.2), 0);
}

.core-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--text);
  text-align: center;
  max-width: 9ch;
}

.float-card {
  position: absolute;
  min-width: 170px;
  padding: 16px 18px;
  border-radius: 20px;
  background: rgba(10, 10, 10, 0.64);
  border: 1px solid rgba(255,255,255,0.12);
  backdrop-filter: blur(12px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.22);
}

.float-card strong {
  display: block;
  margin-top: 8px;
  font-size: 1.2rem;
}

.float-kicker {
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.68rem;
}

.float-card-a {
  top: 10%;
  right: 10%;
  animation: bobA 6s ease-in-out infinite;
  transform: translate3d(calc(var(--mx) * 0.5), calc(var(--my) * 0.5), 0);
}

.float-card-b {
  bottom: 18%;
  left: 8%;
  animation: bobB 7s ease-in-out infinite;
  transform: translate3d(calc(var(--mx) * -0.45), calc(var(--my) * -0.45), 0);
}

.float-card-c {
  top: 58%;
  right: 4%;
  animation: bobC 8s ease-in-out infinite;
  transform: translate3d(calc(var(--mx) * 0.35), calc(var(--my) * 0.35), 0);
}

.button {
  padding: 13px 20px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.96rem;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

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

.button.primary {
  background: var(--text);
  color: #111;
}

.button.secondary {
  border: 1px solid var(--line);
  color: var(--text);
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
  margin-bottom: 18px;
}

.grid {
  display: grid;
  gap: 18px;
}

.projects {
  grid-template-columns: repeat(12, 1fr);
}

.card {
  background: linear-gradient(180deg, var(--panel-strong), var(--panel));
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 22px;
  position: relative;
  overflow: hidden;
  transition: transform 280ms ease, border-color 280ms ease, box-shadow 280ms ease;
}

.card:hover {
  transform: translateY(-8px);
  border-color: rgba(183,255,94,0.24);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.25);
}

.card::after {
  content: '';
  position: absolute;
  inset: auto -20% -40% auto;
  width: 180px;
  height: 180px;
  background: radial-gradient(circle, rgba(122, 240, 255, 0.18), transparent 65%);
  pointer-events: none;
}

.feature h2,
.service-card h3,
.about-card h3 {
  margin: 14px 0 10px;
  line-height: 1.14;
}

.feature h2 {
  font-size: clamp(1.35rem, 2.2vw, 2rem);
  max-width: 18ch;
}

.feature p,
.service-card p,
.about-card li,
.contact-panel p,
.metric-grid p {
  line-height: 1.75;
  font-size: 0.98rem;
}

.tall {
  grid-column: span 7;
  min-height: 360px;
}

.feature:not(.tall):not(.wide) {
  grid-column: span 5;
}

.wide {
  grid-column: span 12;
}

.service-grid {
  grid-template-columns: repeat(4, 1fr);
}

.service-card {
  min-height: 210px;
}

.metric-grid {
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 28px 0;
}

.metric {
  display: inline-block;
  font-size: clamp(1.45rem, 3vw, 2.3rem);
  font-weight: 800;
  margin-bottom: 10px;
}

.about-layout {
  display: grid;
  grid-template-columns: 1.35fr 0.9fr;
  gap: 20px;
  align-items: start;
}

.about-copy {
  font-size: clamp(1.05rem, 1.8vw, 1.45rem);
  line-height: 1.7;
  margin: 0;
  max-width: 34ch;
}

.about-card ul {
  padding-left: 18px;
  margin: 0;
}

.contact-panel {
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 24px;
  background: linear-gradient(160deg, rgba(183,255,94,0.08), rgba(122,240,255,0.04) 36%, rgba(255,255,255,0.03));
}

.contact-panel h2 {
  max-width: 14ch;
  font-size: var(--section-title-size);
}

.contact-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 20px;
}

.contact-links a,
.section-head a,
nav a {
  transition: color 180ms ease;
}

.contact-links a:hover,
.section-head a:hover,
nav a:hover {
  color: var(--text);
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 600ms ease, transform 600ms ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(32px);
    filter: blur(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

@keyframes rotateRing {
  from { transform: rotate(0deg) translate3d(calc(var(--mx) * 0.12), calc(var(--my) * 0.12), 0); }
  to { transform: rotate(360deg) translate3d(calc(var(--mx) * 0.12), calc(var(--my) * 0.12), 0); }
}

@keyframes rotateRingReverse {
  from { transform: rotate(360deg) translate3d(calc(var(--mx) * 0.12), calc(var(--my) * 0.12), 0); }
  to { transform: rotate(0deg) translate3d(calc(var(--mx) * 0.12), calc(var(--my) * 0.12), 0); }
}

@keyframes pulseRing {
  0%, 100% { transform: scale(1) translate3d(calc(var(--mx) * 0.12), calc(var(--my) * 0.12), 0); opacity: 0.8; }
  50% { transform: scale(1.05) translate3d(calc(var(--mx) * 0.12), calc(var(--my) * 0.12), 0); opacity: 1; }
}

@keyframes bobA {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -12px; }
}

@keyframes bobB {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 14px; }
}

@keyframes bobC {
  0%, 100% { translate: 0 0; }
  50% { translate: -4px -10px; }
}

@media (max-width: 960px) {
  .projects,
  .service-grid,
  .metric-grid,
  .about-layout {
    grid-template-columns: 1fr;
  }

  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-orbital {
    min-height: 420px;
  }

  .ring-1 { width: 320px; height: 320px; }
  .ring-2 { width: 250px; height: 250px; }
  .ring-3 { width: 160px; height: 160px; }

  .tall,
  .feature:not(.tall):not(.wide),
  .wide {
    grid-column: span 1;
    min-height: unset;
  }

  .site-header {
    flex-direction: column;
    gap: 14px;
    align-items: flex-start;
  }

  nav {
    flex-wrap: wrap;
  }
}

@media (max-width: 640px) {
  .site-header,
  .section {
    width: min(calc(100% - 24px), var(--max));
  }

  .hero {
    padding-top: 24px;
  }

  .hero h1,
  .contact-panel h2 {
    max-width: none;
  }

  .hero-orbital {
    min-height: 360px;
  }

  .float-card {
    min-width: 138px;
    padding: 14px;
  }

  .float-card-a { top: 4%; right: 0; }
  .float-card-b { left: 0; bottom: 8%; }
  .float-card-c { right: 0; top: 64%; }

  .button {
    width: 100%;
    text-align: center;
  }
}
