/* Shared by every page: fonts, colour tokens (light, dark, and the visitor's switch), the bar, cards and the footer. */
@font-face { font-family: "Inter"; font-weight: 400; src: url(/fonts/Inter-400.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Inter"; font-weight: 500; src: url(/fonts/Inter-500.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url(/fonts/JetBrainsMono-400.woff2) format("woff2"); font-display: swap; }

/* Clay style: a grey page, soft rounded cards, one neo-grotesk in two tones (grey setup, black payoff),
   a single blue for action, and the name set huge at the foot of the page. Dark mode is the night version of the same system. */
:root {
  --page: #F0F0F0; --card: #F7F8FA; --raised: #FFFFFF;
  --ink: #0A0A0A; --mute: #A3A3A6; --soft: #56565B; --line: rgb(0 0 0 / 0.08);
  --blue: #0A63F5; --blue-hi: #3A95FF; --blue-ink: #FFFFFF; --blue-soft: rgb(10 99 245 / 0.12); --glow: rgb(10 99 245 / 0.6);
  --tile: linear-gradient(160deg, #3A3A3D, #0B0B0C 70%);
  --shadow: 0 1px 2px rgb(0 0 0 / 0.04), 0 8px 24px -12px rgb(0 0 0 / 0.12);
  --word: linear-gradient(180deg, #3A95FF 0%, #0A63F5 62%, rgb(10 99 245 / 0) 100%);
  --sweep: rgb(255 255 255 / 0.6);
  --sans: "Inter", -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --gutter: clamp(16px, 3.6vw, 56px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --page: #050505; --card: #0D0D0F; --raised: #151517;
    --ink: #F4F4F5; --mute: #707075; --soft: #A6A6AB; --line: rgb(255 255 255 / 0.09);
    --blue: #FFFFFF; --blue-hi: #FFFFFF; --blue-ink: #0A0A0A; --blue-soft: rgb(255 255 255 / 0.1); --glow: rgb(255 255 255 / 0.12);
    --tile: linear-gradient(160deg, #F4F4F5, #BDBDC2);
    --shadow: 0 0 0 1px rgb(255 255 255 / 0.06), 0 20px 40px -20px rgb(0 0 0 / 0.8);
    --word: linear-gradient(180deg, rgb(255 255 255 / 0.16) 0%, rgb(255 255 255 / 0.03) 80%, rgb(255 255 255 / 0) 100%);
    --sweep: rgb(150 196 255 / 0.55);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --page: #050505; --card: #0D0D0F; --raised: #151517;
  --ink: #F4F4F5; --mute: #707075; --soft: #A6A6AB; --line: rgb(255 255 255 / 0.09);
  --blue: #FFFFFF; --blue-hi: #FFFFFF; --blue-ink: #0A0A0A; --blue-soft: rgb(255 255 255 / 0.1); --glow: rgb(255 255 255 / 0.12);
  --tile: linear-gradient(160deg, #F4F4F5, #BDBDC2);
  --shadow: 0 0 0 1px rgb(255 255 255 / 0.06), 0 20px 40px -20px rgb(0 0 0 / 0.8);
  --word: linear-gradient(180deg, rgb(255 255 255 / 0.16) 0%, rgb(255 255 255 / 0.03) 80%, rgb(255 255 255 / 0) 100%);
  --sweep: rgb(150 196 255 / 0.55);
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { background: var(--page); color: var(--ink); font: 400 17px/1.6 var(--sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-x: clip; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 6px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
h1, h2, h3 { font-weight: 500; letter-spacing: -0.045em; text-wrap: balance; }
h1 { font-size: clamp(42px, 6.2vw, 84px); line-height: 1.02; }
h2 { font-size: clamp(34px, 4.4vw, 60px); line-height: 1.04; }
.m { color: var(--mute); }
p { text-wrap: pretty; }
.lede { margin-top: 24px; color: var(--soft); max-width: 34rem; }
.lede strong { color: var(--ink); font-weight: 500; }

/* bar */
.bar { display: flex; align-items: center; gap: clamp(16px, 4vw, 64px); padding: 20px var(--gutter); }
.mark { display: inline-flex; align-items: center; gap: 10px; font: 500 26px/1 var(--sans); letter-spacing: -0.04em; text-decoration: none; }
.glyph { width: 30px; height: 30px; flex: none; }
.bar nav { display: flex; gap: 24px; flex: 1; }
.bar nav a { text-decoration: none; color: var(--soft); font-size: 16px; }
@media (hover: hover) { .bar nav a:hover { color: var(--ink); } }
.pill { font: 500 16px/1 var(--sans); padding: 13px 22px; border-radius: 12px; background: var(--raised); color: var(--ink); text-decoration: none; box-shadow: var(--shadow); white-space: nowrap; }
.right { display: flex; align-items: center; gap: 8px; }
.theme { width: 44px; height: 44px; display: grid; place-items: center; border: 0; border-radius: 12px; background: var(--raised); color: var(--ink); box-shadow: var(--shadow); cursor: pointer; transition: scale 0.2s ease-out; }
.theme:active { scale: 0.95; }
.theme svg { width: 20px; height: 20px; grid-area: 1 / 1; transition: opacity 0.25s ease, transform 0.35s cubic-bezier(.16,1,.3,1); }
.theme .sun { opacity: 0; transform: rotate(-60deg) scale(0.5); }
:root[data-theme="dark"] .theme .sun { opacity: 1; transform: none; }
:root[data-theme="dark"] .theme .moon { opacity: 0; transform: rotate(60deg) scale(0.5); }
.switching, .switching *:not(.theme svg) { transition: none !important; }
@media (max-width: 760px) { .bar nav { display: none; } .bar { justify-content: space-between; } }

/* cards */
main { display: grid; gap: 16px; padding: 0 var(--gutter); }
.card { position: relative; background: var(--card); border-radius: 36px; padding: clamp(32px, 6vw, 96px) clamp(24px, 6vw, 96px); overflow: hidden; isolation: isolate; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
.split.flip > :first-child { order: 2; }
.stack > .demo { margin-top: clamp(32px, 5vw, 56px); }
.stack .head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 80px); align-items: end; }
.stack .head .lede { margin-top: 0; }
@media (max-width: 900px) {
  .split, .stack .head { grid-template-columns: minmax(0, 1fr); }
  .split.flip > :first-child { order: 0; }
  .card { border-radius: 28px; }
}

/* footer: links, then the name, huge, bleeding off the bottom */
footer { padding: clamp(64px, 9vw, 120px) var(--gutter) 0; overflow: hidden; }
.foot { display: grid; grid-template-columns: minmax(0, 1.2fr) repeat(3, minmax(0, 0.6fr)); gap: 40px; padding: 0 clamp(0px, 3vw, 40px); }
.foot .belief { margin-top: 20px; color: var(--soft); max-width: 22rem; font-size: 16px; }
.foot h3 { font-size: 17px; letter-spacing: -0.02em; }
.foot ul { list-style: none; margin-top: 16px; display: grid; gap: 14px; }
.foot ul a { text-decoration: none; color: var(--soft); font-size: 16px; }
@media (hover: hover) { .foot ul a:hover { color: var(--ink); } }
.copy-line { text-align: center; margin-top: clamp(48px, 6vw, 80px); font-size: 15px; letter-spacing: -0.02em; color: var(--soft); }
.word { display: block; font: 500 clamp(56px, 21vw, 400px)/0.78 var(--sans); letter-spacing: -0.065em; text-align: center; margin: clamp(16px, 3vw, 40px) 0 0;
  background: var(--word); -webkit-background-clip: text; background-clip: text; color: transparent; user-select: none; white-space: nowrap; transform: translateY(14%); }
/* Sweep (owner's pick, 31 Oct): one soft band of light crosses the name every 8 s, then it rests. Still for Reduce Motion. */
@media (prefers-reduced-motion: no-preference) {
  .word { background-image: linear-gradient(100deg, transparent 40%, var(--sweep) 50%, transparent 60%), var(--word);
    background-size: 300% 100%, 100% 100%; background-repeat: no-repeat; background-position: 100% 0, 0 0; animation: sweep 8s cubic-bezier(.45,0,.25,1) infinite; }
}
@keyframes sweep { 0% { background-position: 100% 0, 0 0; } 55%, 100% { background-position: 0% 0, 0 0; } }
@media (max-width: 760px) { .foot { grid-template-columns: 1fr 1fr; } .foot > :first-child { grid-column: 1 / -1; } }
