:root {
  --bg: #0c0c0e;
  --bg-soft: #141417;
  --ink: #f7f4ef;
  --muted: rgba(247, 244, 239, 0.58);
  --faint: rgba(247, 244, 239, 0.28);
  --line: rgba(247, 244, 239, 0.1);
  --accent: #ffffff;
  --accent-soft: rgba(255, 255, 255, 0.72);
  --display: "Instrument Serif", Georgia, serif;
  --sans: "Outfit", system-ui, sans-serif;
  --pad-x: clamp(1.5rem, 5vw, 5rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

.noise {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 80;
  opacity: 0.045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.glow {
  pointer-events: none;
  position: fixed;
  z-index: 0;
  border-radius: 50%;
  filter: blur(100px);
  will-change: transform;
}

.glow-1 {
  width: 55vw;
  height: 55vw;
  max-width: 720px;
  max-height: 720px;
  top: -18%;
  right: -12%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.16), transparent 70%);
}

.glow-2 {
  width: 40vw;
  height: 40vw;
  max-width: 480px;
  max-height: 480px;
  bottom: 10%;
  left: -14%;
  background: radial-gradient(circle, rgba(80, 100, 130, 0.22), transparent 70%);
}

.glow-3 {
  width: 30vw;
  height: 30vw;
  max-width: 360px;
  max-height: 360px;
  top: 45%;
  left: 40%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.08), transparent 70%);
}

/* —— Header —— */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem var(--pad-x);
  background: linear-gradient(180deg, rgba(12, 12, 14, 0.92), rgba(12, 12, 14, 0));
  backdrop-filter: blur(0px);
  transition: background 0.4s var(--ease), backdrop-filter 0.4s var(--ease);
}

.header.is-scrolled {
  background: rgba(12, 12, 14, 0.82);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.header-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--sans);
  font-weight: 700;
  letter-spacing: 0.14em;
  font-size: 0.95rem;
}

.header-brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--line);
}

.header-nav {
  display: flex;
  gap: clamp(1.25rem, 3vw, 2.5rem);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.header-nav a:hover {
  color: var(--accent);
}

.header-cta {
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.header-cta:hover {
  background: var(--accent);
  color: #16130f;
}

/* —— Hero —— */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100svh;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 7rem var(--pad-x) 5rem;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-grid {
  position: absolute;
  inset: 0;
  opacity: 0.22;
  background-image:
    linear-gradient(rgba(247, 244, 239, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(247, 244, 239, 0.05) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 20%, transparent 75%);
}

.hero-stage {
  position: relative;
  z-index: 2;
  width: min(100%, 56rem);
  text-align: center;
}

.hero-eyebrow {
  margin: 0 0 1.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero-title {
  margin: 0;
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(5.5rem, 18vw, 12rem);
  line-height: 0.85;
  letter-spacing: -0.04em;
}

.hero-title-line {
  display: inline-block;
  color: var(--accent);
}

.hero-lede {
  margin: 1.75rem auto 0;
  max-width: 34rem;
  font-family: var(--sans);
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-weight: 300;
  font-style: normal;
  line-height: 1.45;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
  margin-top: 2.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.4rem;
  padding: 0 1.75rem;
  border-radius: 999px;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), background 0.35s var(--ease),
    border-color 0.35s var(--ease), color 0.35s var(--ease);
}

.btn:hover {
  transform: translateY(-3px);
}

.btn-fill {
  background: var(--accent);
  color: #0c0c0e;
  box-shadow: 0 18px 50px rgba(255, 255, 255, 0.16);
}

.btn-line {
  border: 1px solid var(--line);
  background: rgba(247, 244, 239, 0.03);
  color: var(--ink);
}

.btn-line:hover {
  border-color: rgba(255, 255, 255, 0.5);
  color: var(--accent);
}

.hero-mark {
  position: absolute;
  z-index: 1;
  right: max(2%, calc(50% - 42rem));
  bottom: 8%;
  width: min(42vw, 420px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  pointer-events: none;
  opacity: 0.9;
}

.mark-logo {
  width: 58%;
  height: 58%;
  object-fit: cover;
  border-radius: 24%;
  border: 1px solid var(--line);
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55);
  z-index: 2;
}

.mark-orbit {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.mark-orbit-a {
  inset: 0;
}

.mark-orbit-b {
  inset: 10%;
  border-color: rgba(247, 244, 239, 0.08);
}

.hero-scroll {
  position: absolute;
  left: 50%;
  bottom: 1.75rem;
  z-index: 3;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.68rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--faint);
}

.hero-scroll-line {
  width: 1px;
  height: 3rem;
  background: linear-gradient(180deg, var(--accent), transparent);
  transform-origin: top center;
}

/* —— Panels —— */
.panel {
  position: relative;
  z-index: 1;
  padding: clamp(5rem, 14vh, 9rem) var(--pad-x);
}

.panel-inner {
  max-width: 72rem;
  margin: 0 auto;
}

.panel-kicker {
  margin: 0 0 1.25rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--accent);
}

.panel-title {
  margin: 0;
  max-width: 16ch;
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.panel-title em {
  font-style: italic;
  color: var(--accent);
}

.panel-title-sm {
  max-width: none;
  font-size: clamp(2.4rem, 5.5vw, 4rem);
}

.panel-copy {
  margin: 1.75rem 0 0;
  max-width: 38rem;
  font-family: var(--sans);
  font-size: clamp(1.05rem, 1.8vw, 1.2rem);
  font-weight: 300;
  line-height: 1.55;
  color: var(--muted);
}

.about {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(20, 20, 23, 0.65), transparent 55%);
}

.caps {
  padding-top: clamp(2rem, 6vh, 4rem);
}

.cap-rail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  margin-top: 3.5rem;
  border-top: 1px solid var(--line);
}

.cap {
  padding: 2.25rem 1.5rem 2.25rem 0;
  border-bottom: 1px solid var(--line);
}

.cap:nth-child(odd) {
  padding-right: 2rem;
  border-right: 1px solid var(--line);
}

.cap:nth-child(even) {
  padding-left: 2rem;
}

.cap-num {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--faint);
}

.cap h3 {
  margin: 0 0 0.75rem;
  font-family: var(--display);
  font-size: clamp(1.45rem, 2.2vw, 1.9rem);
  font-weight: 500;
}

.cap p {
  margin: 0;
  max-width: 34rem;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.6;
  font-weight: 300;
}

/* —— API section —— */
.api {
  border-top: 1px solid var(--line);
  background:
    radial-gradient(80% 60% at 100% 0%, rgba(255, 255, 255, 0.05), transparent 55%),
    linear-gradient(180deg, rgba(20, 20, 23, 0.5), transparent 50%);
}

.api-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem 2rem;
  margin-top: 3rem;
}

.api-point {
  padding: 1.5rem 0;
  border-top: 1px solid var(--line);
}

.api-point h3 {
  margin: 0 0 0.65rem;
  font-family: var(--display);
  font-size: 1.55rem;
  font-weight: 500;
}

.api-point p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.6;
  font-weight: 300;
}

.api-point code,
.panel-copy code {
  font-family: ui-monospace, "Cascadia Code", "SFMono-Regular", Menlo, monospace;
  font-size: 0.86em;
  padding: 0.1em 0.35em;
  border-radius: 0.3em;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
}

.api-code {
  margin-top: 3rem;
  border-radius: 1.25rem;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.api-code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1.25rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
}

.api-code-tag {
  color: var(--accent-soft);
  letter-spacing: 0.08em;
}

.api-pre {
  margin: 0;
  padding: 1.35rem 1.35rem 1.1rem;
  overflow-x: auto;
  font-family: ui-monospace, "Cascadia Code", "SFMono-Regular", Menlo, monospace;
  font-size: 0.84rem;
  line-height: 1.55;
  color: rgba(247, 244, 239, 0.88);
}

.api-pre code {
  font-family: inherit;
  background: none;
  padding: 0;
}

.api-code-note {
  margin: 0;
  padding: 0 1.35rem 1.2rem;
  font-size: 0.82rem;
  color: var(--faint);
  font-weight: 300;
}

.strip {
  position: relative;
  z-index: 1;
  padding: clamp(4rem, 12vh, 7rem) var(--pad-x);
  border-block: 1px solid var(--line);
  background: var(--bg-soft);
  text-align: center;
}

.strip-line {
  margin: 0 auto;
  max-width: 18ch;
  font-family: var(--display);
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.strip-line span {
  display: block;
  font-style: italic;
  color: var(--accent);
}

.download {
  min-height: 85svh;
  display: flex;
  align-items: center;
}

.download-inner {
  width: 100%;
}

.dl-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 1rem;
  margin-top: 3rem;
}

.dl-card {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  min-height: 11rem;
  padding: 1.6rem 1.5rem;
  border-radius: 1.25rem;
  border: 1px solid var(--line);
  background: rgba(247, 244, 239, 0.02);
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease), background 0.4s var(--ease);
}

.dl-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.06);
}

.dl-card-pending,
.dl-card-unavailable {
  opacity: 0.55;
  pointer-events: none;
  cursor: default;
}

.dl-card-pending:hover,
.dl-card-unavailable:hover {
  transform: none;
  border-color: var(--line);
  background: rgba(247, 244, 239, 0.02);
}

.dl-card-primary {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.18), rgba(20, 20, 23, 0.4));
  border-color: rgba(255, 255, 255, 0.35);
}

.dl-label {
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--faint);
}

.dl-card strong {
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 500;
  margin-top: auto;
}

.dl-meta {
  color: var(--muted);
  font-size: 0.85rem;
}

.footer {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 2rem var(--pad-x) 2.5rem;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 0.8rem;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.footer-brand img {
  width: 28px;
  height: 28px;
  border-radius: 7px;
}

@media (max-width: 960px) {
  .header-nav {
    display: none;
  }

  .hero-mark {
    position: relative;
    right: auto;
    bottom: auto;
    width: min(70vw, 280px);
    margin: 3rem auto 0;
    opacity: 0.85;
  }

  .hero {
    padding-bottom: 3rem;
  }

  .cap-rail {
    grid-template-columns: 1fr;
  }

  .cap:nth-child(odd),
  .cap:nth-child(even) {
    padding-left: 0;
    padding-right: 0;
    border-right: none;
  }

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

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

@media (prefers-reduced-motion: reduce) {
  .btn:hover,
  .dl-card:hover {
    transform: none;
  }
}
