:root {
  --bg: #07080a;
  --bg-2: #0d0f13;
  --ink: #eef0ec;
  --ink-dim: #b2b8b3;
  --ink-faint: #979e98;
  --line: rgba(238, 240, 236, 0.09);
  --glass: rgba(255, 255, 255, 0.035);
  --glass-edge: rgba(255, 255, 255, 0.12);
  --accent: #d9b27c;
  --accent-2: #7fb8a4;
  --serif: "Newsreader", Georgia, serif;
  --sans: "IBM Plex Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --gutter: clamp(20px, 4vw, 56px);
  --max: 980px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--accent); color: #111; }
a { color: inherit; }
h1, h2, h3, p, ul, ol { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img, svg { display: block; max-width: 100%; }

/* Top bar */
.topbar {
  position: fixed; top: 16px; left: 50%; transform: translateX(-50%);
  z-index: 10;
  width: min(calc(100% - 32px), 720px);
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 8px 8px 16px;
  border-radius: 999px;
  background: rgba(16, 18, 22, 0.55);
  border: 1px solid var(--glass-edge);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 12px 40px rgba(0, 0, 0, 0.35);
  animation: slideDown 900ms var(--ease-out) both;
}
.mark { font-family: var(--serif); font-size: 18px; font-style: italic; text-decoration: none; color: var(--accent); }
.topbar nav { display: flex; gap: 4px; }
.topbar nav a {
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em;
  text-decoration: none; color: var(--ink-dim);
  padding: 8px 12px; border-radius: 999px;
  transition: color 300ms var(--ease-out), background 300ms var(--ease-out);
}
@keyframes slideDown { from { opacity: 0; transform: translate(-50%, -14px); } to { opacity: 1; transform: translate(-50%, 0); } }

main, .footer { width: min(var(--max), calc(100% - var(--gutter) * 2)); margin: 0 auto; }

/* Hero */
.hero {
  min-height: min(78svh, 760px);
  display: flex; flex-direction: column; justify-content: center;
  padding: 112px 0 56px;
}
.eyebrow, .tag, .index, .scroll-cue span, .year, .footer {
  font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-faint);
}
.display {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(52px, 8vw, 98px);
  line-height: 0.96;
  letter-spacing: -0.03em;
  margin: 22px 0 24px;
}
.display em { font-style: normal; color: var(--accent); font-weight: 300; }
.tagline { font-family: var(--serif); font-size: clamp(19px, 2.1vw, 24px); font-style: italic; color: var(--ink-dim); max-width: 34ch; }
.scroll-cue { margin-top: 42px; display: inline-flex; align-items: center; gap: 14px; text-decoration: none; width: max-content; }
.scroll-cue i {
  position: relative; width: 1px; height: 44px; background: var(--line); overflow: hidden;
}
.scroll-cue i::after {
  content: ""; position: absolute; left: 0; top: -40%; width: 1px; height: 40%; background: var(--accent);
  animation: cue 2.2s var(--ease-out) infinite;
}
@keyframes cue { to { top: 110%; } }

/* Sections */
.section { padding: clamp(72px, 9vw, 104px) 0 0; }
.section-head { display: flex; align-items: baseline; gap: 18px; margin-bottom: clamp(26px, 4vw, 42px); }
.section-head h2 {
  font-family: var(--serif); font-weight: 300; font-size: clamp(33px, 4vw, 46px); letter-spacing: -0.025em; line-height: 1;
}
.about-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
.lede {
  font-family: var(--serif); font-size: clamp(22px, 2.5vw, 29px); line-height: 1.35; font-weight: 300; letter-spacing: -0.01em;
}
.about-body { display: grid; gap: 18px; color: var(--ink-dim); font-size: 16px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: clamp(40px, 6vw, 72px); }
.chips li {
  font-family: var(--mono); font-size: 12px; color: var(--ink-dim);
  padding: 9px 14px; border-radius: 999px;
  background: var(--glass); border: 1px solid var(--line);
  transition: transform 150ms var(--ease-out), border-color 150ms var(--ease-out), color 150ms var(--ease-out);
}

/* Cards */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.card:first-child { grid-column: span 2; }
.card, .panel {
  position: relative;
  border-radius: 24px;
  padding: clamp(24px, 3vw, 36px);
  background: linear-gradient(160deg, rgba(255,255,255,0.06), rgba(255,255,255,0.015) 60%);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  overflow: hidden;
  transition: transform 180ms var(--ease-out), border-color 180ms var(--ease-out);
}
.spotlight::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), rgba(217, 178, 124, 0.14), transparent 60%);
  opacity: 0; transition: opacity 180ms var(--ease-out);
}
.card h3, .panel h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(22px, 2.4vw, 28px); line-height: 1.2; margin: 14px 0 10px; letter-spacing: -0.01em; }
.card p, .panel p { color: var(--ink-dim); font-size: 15px; max-width: 58ch; }

.explore-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }

/* Timeline */
.timeline { position: relative; display: grid; gap: 0; }
.timeline li {
  display: grid; grid-template-columns: 120px 1fr; gap: 24px;
  padding: 28px 0; border-top: 1px solid var(--line);
}
.timeline li:last-child { border-bottom: 1px solid var(--line); }
.timeline h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -0.01em; }
.timeline p { color: var(--ink-dim); font-size: 15px; margin-top: 4px; }
.timeline .year { padding-top: 10px; }

/* Contact */
.contact .lede { max-width: 26ch; }
.links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 40px; }
.pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 20px 12px 16px;
  border-radius: 999px;
  text-decoration: none; font-size: 14px; font-weight: 400;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-edge);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 10px 30px rgba(0, 0, 0, 0.25);
  transition: transform 150ms var(--ease-out), background 150ms var(--ease-out), border-color 150ms var(--ease-out);
  will-change: transform;
}
.pill svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.pill svg.solid { fill: currentColor; stroke: none; }
.pill:active { transform: scale(0.97) !important; }
.pill:focus-visible, .topbar a:focus-visible, .scroll-cue:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

.footer {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 64px 0 40px; margin-top: 92px; border-top: 1px solid var(--line);
}
.nivora-link {
  align-self: center;
  padding: 5px 10px;
  border: 1px solid rgba(238, 240, 236, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--ink-dim);
  font: 500 10px/1 var(--mono);
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
  transition: transform 150ms var(--ease-out), background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}
.nivora-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.nivora-link:active { transform: scale(.96); }

/* The swarm supplies the one authored entrance; reading content stays still. */
.reveal { opacity: 1; translate: none; filter: none; }

@media (hover: hover) and (pointer: fine) {
  .topbar nav a:hover { color: var(--ink); background: rgba(255, 255, 255, 0.06); }
  .chips li:hover { transform: translateY(-2px); border-color: rgba(217, 178, 124, 0.5); color: var(--ink); }
  .spotlight:hover::before { opacity: 1; }
  .card:hover, .panel:hover { border-color: rgba(255, 255, 255, 0.18); transform: translateY(-2px); }
  .pill:hover { background: rgba(217, 178, 124, 0.12); border-color: rgba(217, 178, 124, 0.55); }
  .nivora-link:hover { color: var(--ink); background: rgba(217, 178, 124, 0.10); border-color: rgba(217, 178, 124, 0.42); transform: translateY(-1px); }
}

/* Responsive */
@media (max-width: 900px) {
  .about-grid, .explore-grid { grid-template-columns: 1fr; }
  .cards { grid-template-columns: 1fr; }
  .card:first-child { grid-column: auto; }
}
@media (max-width: 600px) {
  .topbar nav a:not(:last-child) { display: none; }
  .timeline li { grid-template-columns: 1fr; gap: 6px; }
  .hero { padding-top: 110px; }
  .card, .panel { border-radius: 20px; }
  .card:hover, .panel:hover { transform: none; }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; translate: none; filter: none; }
}
