/* ====== TOKENS ====== */
:root {
  --bg: #FAF7FE;
  --bg-2: #F4EEFB;
  --surface: #FFFFFF;
  --soft: #E8DEF5;
  --soft-2: #D9CDF0;
  --primary: #A78BD9;
  --primary-2: #8B6FC4;
  --deep: #3D2B5C;
  --ink: #1F1733;
  --muted: #6E6483;
  --line: rgba(61, 43, 92, 0.10);
  --line-2: rgba(61, 43, 92, 0.06);
  --accent: #C9B8E8;

  --serif: 'Instrument Serif', 'Cormorant Garamond', Georgia, serif;
  --sans: 'Geist', 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', 'IBM Plex Mono', ui-monospace, monospace;

  --radius-sm: 6px;
  --radius: 14px;
  --radius-lg: 24px;

  --shadow-sm: 0 1px 2px rgba(61, 43, 92, 0.04), 0 0 0 1px var(--line);
  --shadow: 0 24px 48px -24px rgba(61, 43, 92, 0.18), 0 0 0 1px var(--line);
  --shadow-lg: 0 40px 80px -32px rgba(61, 43, 92, 0.25);
}

[data-theme="dark"] {
  --bg: #14101F;
  --bg-2: #1A1428;
  --surface: #1F1830;
  --soft: #2A1F42;
  --soft-2: #3A2D5C;
  --primary: #C9B8E8;
  --primary-2: #A78BD9;
  --deep: #E8DEF5;
  --ink: #F4EEFB;
  --muted: #9989B5;
  --line: rgba(232, 222, 245, 0.10);
  --line-2: rgba(232, 222, 245, 0.05);
  --accent: #9B7FD4;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  line-height: 1.5;
  font-feature-settings: "ss01", "cv11";
}

img, svg { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
a { color: inherit; text-decoration: none; }

/* ====== TYPE UTILITIES ====== */
.serif { font-family: var(--serif); font-weight: 400; letter-spacing: -0.01em; }
.mono { font-family: var(--mono); font-feature-settings: "ss01"; }
.eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.eyebrow::before {
  content: '';
  width: 18px;
  height: 1px;
  background: var(--primary);
}

/* ====== LAYOUT ====== */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 32px;
}

section {
  position: relative;
  padding: 140px 0;
}

@media (max-width: 768px) {
  section { padding: 80px 0; }
  .container { padding: 0 20px; }
}

/* ====== NAV ====== */
.nav {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 8px 8px 20px;
  background: rgba(250, 247, 254, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-radius: 100px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.3s;
}
[data-theme="dark"] .nav {
  background: rgba(20, 16, 31, 0.72);
}
.nav-brand {
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 8px;
  padding-right: 16px;
  border-right: 1px solid var(--line);
  white-space: nowrap;
  flex-shrink: 0;
}
.nav-cta { white-space: nowrap; flex-shrink: 0; }
.nav-brand .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 0 4px rgba(167, 139, 217, 0.18);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(167, 139, 217, 0.18); }
  50% { box-shadow: 0 0 0 8px rgba(167, 139, 217, 0.05); }
}
.nav-links {
  display: flex;
  gap: 4px;
}
.nav-link {
  padding: 8px 14px;
  font-size: 13px;
  border-radius: 100px;
  color: var(--muted);
  transition: color 0.2s, background 0.2s;
}
.nav-link:hover { color: var(--ink); background: var(--bg-2); }
.nav-cta {
  padding: 10px 18px;
  font-size: 13px;
  background: var(--ink);
  color: var(--bg);
  border-radius: 100px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: transform 0.2s, background 0.2s;
}
.nav-cta:hover { transform: translateY(-1px); }
.nav-cta svg { width: 12px; height: 12px; }

@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav { padding: 7px 14px 7px 18px; }
}
/* desktop: only the name renders; sep + role are hidden */
.nav-brand-text { display: contents; }
.nav-brand-sep, .nav-brand-role { display: none; }

/* mobile: minimal pill, name | role inline at 20px */
@media (max-width: 600px) {
  .nav { padding: 11px 22px; gap: 0; top: 24px; }
  .nav-cta { display: none; }
  .nav-brand {
    padding-right: 0;
    border-right: none;
    gap: 14px;
  }
  .nav-brand-text {
    display: inline-flex;
    align-items: baseline;
    gap: 10px;
    line-height: 1;
  }
  .nav-brand-name { font-size: 20px; line-height: 1; }
  .nav-brand-sep {
    display: inline;
    font-size: 20px;
    color: rgba(61, 43, 92, 0.22);
    font-weight: 300;
    line-height: 1;
  }
  .nav-brand-role {
    display: inline;
    font-family: var(--serif);
    font-style: italic;
    font-size: 20px;
    letter-spacing: -0.005em;
    color: var(--muted);
    line-height: 1;
  }
}

/* very small screens: stack name and role on two lines, hide separator */
@media (max-width: 520px) {
  .nav-brand-text {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  .nav-brand-sep { display: none; }
}

/* ====== MOBILE FLOATING CTA ====== */
.mobile-cta { display: none; }
@media (max-width: 600px) {
  .mobile-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    position: fixed;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 99;
    padding: 13px 20px;
    background: var(--ink);
    color: var(--bg);
    border-radius: 100px;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: -0.005em;
    white-space: nowrap;
    box-shadow: 0 12px 32px -8px rgba(31, 23, 51, 0.35), 0 0 0 1px rgba(31, 23, 51, 0.1);
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.25s;
  }
  .mobile-cta:active { transform: translateX(-50%) translateY(1px); }
  .mobile-cta-arrow {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.14);
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .mobile-cta-arrow svg { width: 11px; height: 11px; }
}

/* ====== BUTTONS ====== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.005em;
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), background 0.25s, color 0.25s;
  position: relative;
  overflow: hidden;
}
.btn-primary {
  background: var(--ink);
  color: var(--bg);
}
.btn-primary:hover { transform: translateY(-2px); }
.btn-secondary {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.btn-secondary:hover { background: var(--bg-2); transform: translateY(-2px); }

.btn-arrow {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.btn:hover .btn-arrow { transform: translate(2px, -2px) rotate(-45deg); }
.btn-secondary .btn-arrow { background: var(--bg-2); }

/* ====== SCROLL REVEAL ====== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.9s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}
.reveal.delay-1 { transition-delay: 0.08s; }
.reveal.delay-2 { transition-delay: 0.16s; }
.reveal.delay-3 { transition-delay: 0.24s; }
.reveal.delay-4 { transition-delay: 0.32s; }

/* word reveal */
.word-reveal .word {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  padding: 0.15em 0.05em 0.25em;
  margin: -0.15em -0.05em -0.25em;
  line-height: inherit;
}
.word-reveal .word > span {
  display: inline-block;
  transform: translateY(140%);
  transition: transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1);
  line-height: inherit;
}
.word-reveal.in .word > span { transform: translateY(0); }
