:root {
  --bg: #fbf8f4;
  --bg-alt: #f3ede5;
  --ink: #1f1b2e;
  --muted: #5d5770;
  --accent: #6b4eff;
  --accent-2: #ff7a59;
  --card: #ffffff;
  --line: #e6dfd5;
  --radius: 18px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14121c;
    --bg-alt: #1b1826;
    --ink: #f3f0fa;
    --muted: #aaa3bd;
    --accent: #9d88ff;
    --accent-2: #ff9a80;
    --card: #221e30;
    --line: #2f2a40;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.65 Inter, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3 { font-family: Fraunces, Georgia, serif; line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: clamp(2.3rem, 6vw, 4.2rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h3 { font-size: 1.2rem; }
a { color: inherit; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

.eyebrow {
  text-transform: uppercase; letter-spacing: .14em;
  font-size: .78rem; font-weight: 600; color: var(--accent); margin: 0 0 .8em;
}
.accent {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lede { font-size: 1.15rem; color: var(--muted); max-width: 640px; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo {
  font-family: Fraunces, serif; font-weight: 700; font-size: 1.3rem; text-decoration: none;
  width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px;
  background: var(--ink); color: var(--bg);
}
.links { display: flex; gap: 28px; align-items: center; }
.links a { text-decoration: none; font-weight: 500; color: var(--muted); transition: color .2s; }
.links a:hover { color: var(--ink); }
.links .pill { color: var(--bg); background: var(--ink); padding: 8px 18px; border-radius: 999px; }
.links .pill:hover { color: var(--bg); opacity: .85; }
.menu-btn { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.menu-btn span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 5px 0; transition: transform .25s; }

/* Buttons */
.cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
.btn {
  display: inline-block; padding: 14px 26px; border-radius: 999px; font-weight: 600;
  text-decoration: none; transition: transform .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn.primary { background: var(--accent); color: #fff; box-shadow: 0 8px 24px -8px var(--accent); }
.btn.ghost { border: 1.5px solid var(--line); }

/* Hero */
.hero { position: relative; padding: 120px 0 110px; overflow: hidden; }
.hero-inner { position: relative; z-index: 1; }
.blob {
  position: absolute; width: 560px; height: 560px; right: -160px; top: -120px;
  background: radial-gradient(circle at 30% 30%, var(--accent-2), var(--accent) 60%, transparent 70%);
  filter: blur(70px); opacity: .35; animation: float 14s ease-in-out infinite;
}
@keyframes float { 50% { transform: translate(-40px, 40px) scale(1.08); } }

/* Sections */
.section { padding: 96px 0; }
.section.alt { background: var(--bg-alt); }
.two-col { display: grid; grid-template-columns: 1fr 1.4fr; gap: 48px; }
.prose p { margin: 0 0 1.1em; color: var(--muted); }
.stats { list-style: none; padding: 0; margin: 32px 0 0; display: flex; gap: 40px; flex-wrap: wrap; }
.stats strong { display: block; font-family: Fraunces, serif; font-size: 2.4rem; color: var(--accent); }
.stats span { font-size: .9rem; color: var(--muted); }

/* Timeline */
.timeline { list-style: none; padding: 0; margin: 40px 0 0; border-left: 2px solid var(--line); }
.timeline > li { display: grid; grid-template-columns: 200px 1fr; gap: 24px; padding: 0 0 40px 28px; position: relative; }
.timeline > li::before {
  content: ""; position: absolute; left: -8px; top: 6px; width: 14px; height: 14px;
  border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--bg-alt);
}
.when { font-weight: 600; color: var(--muted); font-size: .95rem; }
.what p { margin: 0; color: var(--muted); }
.roles { list-style: none; padding: 0; margin: 0 0 14px; border-left: 2px dotted var(--line); }
.roles li { padding: 2px 0 8px 14px; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.roles strong { font-weight: 600; }
.roles span { font-size: .8rem; color: var(--accent); font-weight: 600; }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 40px; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 16px 40px -20px rgba(0,0,0,.25); }
.card p { margin: 0; color: var(--muted); font-size: .95rem; }
.badge {
  display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 14px;
  font-weight: 700; font-size: .85rem; color: #fff; margin-bottom: 18px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}
.tags { list-style: none; padding: 0; margin: 36px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.tags li { padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px; font-size: .9rem; color: var(--muted); }

/* Contact & footer */
.contact { text-align: center; }
.contact .lede { margin: 0 auto; }
.contact .cta { justify-content: center; }
.footer { padding: 32px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; text-align: center; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .blob { animation: none; }
  html { scroll-behavior: auto; }
}

/* Mobile */
@media (max-width: 760px) {
  .menu-btn { display: block; }
  .links {
    position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    max-height: 0; overflow: hidden; transition: max-height .3s ease;
  }
  .links a { padding: 14px 20px; width: 100%; }
  .links .pill { background: none; color: var(--accent); }
  .nav.open .links { max-height: 360px; }
  .nav.open .menu-btn span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .nav.open .menu-btn span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
  .hero { padding: 80px 0 72px; }
  .section { padding: 72px 0; }
  .two-col { grid-template-columns: 1fr; gap: 16px; }
  .timeline > li { grid-template-columns: 1fr; gap: 4px; }
  .blob { width: 360px; height: 360px; right: -140px; }
}
