/* Orbitrei // a quiet page around one moving thing: the planet. Graphite of the editor UI; violet only where the icons have it. */

@font-face { font-family: "Inter"; src: url(../assets/fonts/Inter-Regular.woff) format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url(../assets/fonts/Inter-Medium.woff) format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter Display"; src: url(../assets/fonts/InterDisplay-Bold.woff) format("woff"); font-weight: 700; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url(../assets/fonts/JetBrainsMono-Regular.woff) format("woff"); font-weight: 400; font-display: swap; }

:root {
  /* the editor's surfaces (editor/src/theme.cpp) */
  --gutter: #0a0c0e;
  --panel: #111417;
  --raised: #181c20;
  --hover: #232a30;
  --line: rgba(255, 255, 255, .06);
  --text: #e3e7e4;
  --dim: #9ca4aa;
  /* the icon gradient */
  --violet: #641aff;
  --violet-mid: #9b6bff;
  --lilac: #dfc8ff;
  --icon-grad: linear-gradient(135deg, #dfc8ff, #641aff);

  --margin: clamp(20px, 7vw, 120px);
  --sans: "Inter", system-ui, sans-serif;
  --display: "Inter Display", "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scrollbar-color: #3a444c transparent; scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  margin: 0;
  background: var(--gutter);
  color: var(--text);
  font: 400 18px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, p, figure, pre, ul { margin: 0; }
ul { padding: 0; list-style: none; }
img, video, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
::selection { background: rgba(155, 107, 255, .35); }
:focus-visible { outline: 2px solid var(--violet-mid); outline-offset: 3px; border-radius: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

#gl { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; }
main, .foot { position: relative; z-index: 1; }

/* ---------------------------------------------------------------- buttons */
.button {
  display: inline-flex; align-items: center; justify-content: center; height: 48px; padding: 0 22px; border-radius: 12px; flex: none;
  background: var(--text); color: var(--gutter); font-weight: 500; font-size: 15.5px;
  transition: background .2s, transform .2s;
}
.button:hover { background: #fff; }
.button:active { transform: translateY(1px); }
.button-sm { height: 38px; padding: 0 16px; border-radius: 10px; font-size: 14.5px; }
.button-quiet { background: var(--raised); color: var(--text); }
.button-quiet:hover { background: var(--hover); }

/* ---------------------------------------------------------------- top bar */
.bar { position: fixed; z-index: 20; top: 14px; left: 0; right: 0; display: flex; justify-content: center; padding: 0 14px; pointer-events: none; }
.bar-in {
  pointer-events: auto; width: min(1120px, 100%); height: 58px;
  display: flex; align-items: center; gap: 8px; padding: 0 10px 0 16px;
  background: rgba(17, 20, 23, .72); backdrop-filter: blur(18px) saturate(1.3); -webkit-backdrop-filter: blur(18px) saturate(1.3);
  border: 1px solid var(--line); border-radius: 16px;
}
.mark { display: flex; align-items: center; gap: 10px; font-weight: 500; font-size: 16px; letter-spacing: -.01em; }
.mark img { width: 24px; height: 24px; }
.links { display: flex; gap: 2px; margin: 0 auto; }
.links a { padding: 8px 13px; border-radius: 9px; font-size: 14.5px; color: var(--dim); transition: color .2s, background .2s; }
.links a:hover { color: var(--text); background: var(--raised); }
.links a.on { color: var(--text); background: var(--raised); }

/* ---------------------------------------------------------------- type */
h2 {
  font: 700 clamp(38px, 5vw, 64px)/1.04 var(--display);
  letter-spacing: -.032em;
  text-wrap: balance;
}
.col { max-width: 600px; margin-left: var(--margin); padding-right: 20px; }
.col > p { margin-top: 22px; color: var(--dim); font-size: 19px; max-width: 34em; }

/* ---------------------------------------------------------------- hero */
.hero { height: 230vh; }
.hero-stage { position: sticky; top: 0; height: 100vh; }
.hero-foot {
  position: absolute; left: var(--margin); right: var(--margin); bottom: clamp(32px, 8vh, 72px);
  display: flex; align-items: flex-end; justify-content: space-between; gap: 32px;
}
.hero-foot p { max-width: 25em; color: var(--dim); font-size: 18px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.scroll-cue { position: absolute; left: 50%; bottom: 20px; width: 1px; height: 36px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.scroll-cue span { position: absolute; left: 0; top: -12px; width: 1px; height: 12px; background: var(--lilac); animation: cue 2.2s cubic-bezier(.25, 1, .5, 1) infinite; }
@keyframes cue { to { top: 36px; } }
.hero-fallback { display: none; }
.no-gl .hero-fallback {
  display: grid; place-items: center; height: 100%;
  font: 700 clamp(72px, 15vw, 220px)/1 var(--display); letter-spacing: -.05em;
  background: var(--icon-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------------------------------------------------------------- section heads */
.head { margin: 0 var(--margin); max-width: 720px; }
.head.center { margin: 0 auto; text-align: center; padding: 0 20px; }
.head > p { margin-top: 18px; color: var(--dim); font-size: 19px; }
.head.center > p { margin-left: auto; margin-right: auto; max-width: 32em; }

/* ---------------------------------------------------------------- product */
.product { padding: 16vh 0 14vh; }
.screen-wrap { margin: 48px auto 0; width: min(1240px, calc(100% - 2 * var(--margin) + 40px)); perspective: 1600px; }
.screen {
  position: relative; aspect-ratio: 16 / 10; border-radius: 16px; overflow: hidden;
  background: var(--panel); border: 1px solid rgba(255, 255, 255, .09);
  box-shadow: 0 50px 140px rgba(0, 0, 0, .7), 0 0 0 8px rgba(17, 20, 23, .6);
  transform-origin: 50% 100%; will-change: transform;
}
.screen img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .5s; }
.screen img.on { opacity: 1; }

/* ---------------------------------------------------------------- screening room */
.reel { height: 520vh; }
.reel-stage { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 22px; padding: 96px var(--margin) 28px; }
.reel-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; }
.reel-head h2 { font-size: clamp(32px, 3.8vw, 52px); }
.reel-head p { color: var(--dim); font-size: 16px; max-width: 24em; text-align: right; }
.screen-room { position: relative; flex: 1; min-height: 0; border-radius: 20px; overflow: hidden; background: #000; border: 1px solid var(--line); }
.layer { position: absolute; inset: 0; will-change: clip-path, transform, filter, opacity; }
.layer video { width: 100%; height: 100%; object-fit: cover; }
.room-shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(0deg, rgba(0, 0, 0, .72), rgba(0, 0, 0, 0) 42%); }
.room-title { position: absolute; left: 32px; bottom: 44px; max-width: 30em; transition: opacity .3s, transform .45s cubic-bezier(.25, 1, .5, 1); }
.room-title.swap { opacity: 0; transform: translateY(10px); }
.room-title h3 { font: 700 clamp(30px, 4vw, 56px)/1 var(--display); letter-spacing: -.03em; }
.room-title p { margin-top: 12px; color: #d4d8d5; font-size: 16.5px; }
.room-cut { position: absolute; top: 20px; right: 22px; padding: 7px 12px; border-radius: 9px; font-size: 13.5px; color: var(--text);
  background: rgba(10, 12, 14, .6); backdrop-filter: blur(10px); opacity: 0; transition: opacity .3s; }
.room-cut.on { opacity: 1; }
.room-track { position: absolute; left: 32px; right: 32px; bottom: 22px; display: flex; gap: 6px; }
.room-track span { flex: 1; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, .18); overflow: hidden; position: relative; }
.room-track span::after { content: ""; position: absolute; inset: 0; background: var(--icon-grad); transform-origin: left; transform: scaleX(var(--f, 0)); }

/* ---------------------------------------------------------------- kinetic list */
.kin { padding: 14vh 0 10vh; }
.kin-grid { margin: 40px var(--margin) 0; display: grid; grid-template-columns: 1fr 1.05fr; gap: 56px; }
.kin-list { padding: 18vh 0 30vh; }
.kin-list li { padding: 14px 0; cursor: default; }
.kin-list h3 { font: 700 clamp(44px, 6.4vw, 96px)/1 var(--display); letter-spacing: -.045em; color: #20262b; transition: color .4s; }
.kin-list p { max-width: 26em; color: var(--dim); font-size: 17px; max-height: 0; opacity: 0; overflow: hidden;
  transition: max-height .5s cubic-bezier(.25, 1, .5, 1), opacity .4s, margin .5s; }
.kin-list li.on h3 { background: linear-gradient(100deg, #f1ecff, #b18cff 70%, #7b3dff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.kin-list li.on p { max-height: 6em; opacity: 1; margin-top: 14px; }
.kin-media { position: relative; }
.kin-frame { position: sticky; top: calc(50vh - min(19vw, 230px)); aspect-ratio: 16 / 10; border-radius: 20px; overflow: hidden;
  background: #000; border: 1px solid var(--line); box-shadow: 0 40px 120px rgba(0, 0, 0, .6); }
.kin-frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.06);
  transition: opacity .6s, transform 1.2s cubic-bezier(.25, 1, .5, 1); }
.kin-frame video.on { opacity: 1; transform: none; }


/* ---------------------------------------------------------------- footer */
.foot { padding: 0 14px 0; margin-top: 6vh; overflow: hidden; }
.foot-card {
  width: min(1120px, 100%); margin: 0 auto; padding: 40px 40px 44px;
  display: grid; grid-template-columns: 1.1fr 2fr; gap: 40px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 20px;
}
.foot-brand .mark { font-size: 18px; }
.foot-brand .mark img { width: 28px; height: 28px; }
.foot-brand p { margin-top: 14px; color: var(--dim); font-size: 15px; max-width: 22em; }
.foot-brand .button { margin-top: 24px; }
.foot-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.foot-cols h3 { font-size: 13.5px; font-weight: 500; color: var(--dim); margin-bottom: 12px; }
.foot-cols a, .foot-cols span { display: block; font-size: 15px; line-height: 2.1; color: var(--text); }
.foot-cols span { color: #c3c9cc; }
.foot-cols a:hover { color: var(--lilac); }
.foot-base {
  width: min(1120px, 100%); margin: 0 auto; padding: 20px 8px;
  display: flex; justify-content: space-between; font-size: 14px; color: var(--dim);
}
.foot-base a:hover { color: var(--text); }
.foot-word {
  margin: 0 auto -0.2em; text-align: center; user-select: none;
  font: 700 clamp(110px, 23vw, 380px)/.9 var(--display); letter-spacing: -.06em;
  background: linear-gradient(180deg, rgba(155, 107, 255, .26), rgba(100, 26, 255, .06) 55%, rgba(10, 12, 14, 0) 85%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------------------------------------------------------------- smaller screens */
@media (max-width: 1100px) {
  .foot-card { grid-template-columns: 1fr; }
  .kin-grid { grid-template-columns: 1fr; }
  .kin-media { display: none; }
  .kin-list { padding: 0; }
  .kin-list p { max-height: none; opacity: 1; margin-top: 10px; }
  .kin-list h3 { color: var(--text); }
}
@media (max-width: 760px) {
  body { font-size: 17px; }
  .links { display: none; }
  .bar-in .button { margin-left: auto; }
  .hero-foot { flex-direction: column; align-items: flex-start; gap: 22px; }
  .scroll-cue { display: none; }
  .reel { height: 460vh; }
  .reel-stage { padding: 84px 14px 18px; }
  .reel-head { flex-direction: column; align-items: flex-start; gap: 8px; }
  .reel-head p { text-align: left; }
  .room-title { left: 18px; right: 18px; bottom: 36px; }
  .room-track { left: 18px; right: 18px; }
  .foot-card { padding: 28px 24px; }
  .foot-cols { grid-template-columns: 1fr 1fr; }
}

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

/* Moonlight Cats is 1:1: shown whole, pillarboxed on black, never cropped */
video.square { object-fit: contain; background: #000; }

/* the AI item: an agent driving Orbitrei over MCP, typed line by line when it lights up */
.kin-term { position: absolute; inset: 0; padding: 22px 26px; background: var(--panel); font: 14.5px/1.75 var(--mono);
  color: var(--dim); opacity: 0; transition: opacity .6s; overflow: hidden; }
.kin-term.on { opacity: 1; }
.kin-term p { opacity: 0; transform: translateY(6px); white-space: nowrap; }
.kin-term.on p { animation: term-in .35s cubic-bezier(.25, 1, .5, 1) forwards; }
.kin-term i { font-style: normal; color: var(--lilac); display: inline-block; min-width: 15ch; }
.kin-term .t-head { display: flex; align-items: center; gap: 7px; margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.kin-term .t-head span { width: 11px; height: 11px; border-radius: 50%; background: var(--hover); }
.kin-term .t-head b { margin-left: 10px; font-weight: 400; font-size: 13px; }
.kin-term .t-ask { color: var(--text); margin-bottom: 8px; }
.kin-term .t-done { margin-top: 8px; color: var(--text); }
.kin-term.on p:nth-child(2) { animation-delay: .25s; } .kin-term.on p:nth-child(3) { animation-delay: .9s; }
.kin-term.on p:nth-child(4) { animation-delay: 1.3s; } .kin-term.on p:nth-child(5) { animation-delay: 1.7s; }
.kin-term.on p:nth-child(6) { animation-delay: 2.1s; } .kin-term.on p:nth-child(7) { animation-delay: 2.5s; }
.kin-term.on p:nth-child(8) { animation-delay: 2.9s; } .kin-term.on p:nth-child(9) { animation-delay: 3.6s; }
@keyframes term-in { to { opacity: 1; transform: none; } }
