/* ---------- Tokens ---------- */
:root {
  --bg: #fafafa;
  --bg-alt: #f2f3f5;
  --surface: #ffffff;
  --text: #16181d;
  --muted: #5d6370;
  --border: #e3e5ea;
  --accent: #2f5bea;
  --accent-soft: rgba(47, 91, 234, 0.1);
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 8px 24px rgba(16, 24, 40, 0.06);
  --radius: 16px;
  --maxw: 1080px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1013;
    --bg-alt: #14171c;
    --surface: #181b21;
    --text: #eceef2;
    --muted: #9aa1ad;
    --border: #262a32;
    --accent: #6d8dff;
    --accent-soft: rgba(109, 141, 255, 0.14);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.25);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #0e1013;
  --bg-alt: #14171c;
  --surface: #181b21;
  --text: #eceef2;
  --muted: #9aa1ad;
  --border: #262a32;
  --accent: #6d8dff;
  --accent-soft: rgba(109, 141, 255, 0.14);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.25);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.3s, color 0.3s;
}

a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; line-height: 1.15; letter-spacing: -0.02em; }
p { margin: 0; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}
.nav.is-scrolled { border-bottom-color: var(--border); }

.nav__inner {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 68px;
}

.nav__logo { font-weight: 700; font-size: 20px; letter-spacing: -0.03em; }
.nav__logo span { color: var(--accent); }

.nav__links { display: flex; gap: 28px; margin-left: auto; font-size: 15px; }
.nav__links a { color: var(--muted); transition: color 0.2s; }
.nav__links a:hover { color: var(--text); }

.theme-toggle {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.2s;
}
.theme-toggle:hover { border-color: var(--accent); }
.theme-toggle svg { width: 18px; height: 18px; }
.icon-moon { display: none; }
:root[data-theme="dark"] .icon-sun { display: none; }
:root[data-theme="dark"] .icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .icon-sun { display: none; }
  :root:not([data-theme="light"]) .icon-moon { display: block; }
}

/* ---------- Hero ---------- */
.hero { padding: 140px 0 120px; position: relative; overflow: hidden; }
.hero::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto auto;
  width: 640px;
  height: 640px;
  background: radial-gradient(circle, var(--accent-soft), transparent 65%);
  pointer-events: none;
}

.eyebrow {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 24px;
}

.hero__title {
  font-size: clamp(44px, 8vw, 88px);
  font-weight: 700;
  letter-spacing: -0.04em;
}

.hero__lead {
  max-width: 620px;
  margin-top: 24px;
  font-size: clamp(18px, 2.2vw, 21px);
  color: var(--muted);
}

.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 40px; }

.btn {
  display: inline-flex;
  align-items: center;
  height: 48px;
  padding: 0 22px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  transition: transform 0.2s, background-color 0.2s, border-color 0.2s;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: color-mix(in srgb, var(--accent) 88%, #000); }
.btn--ghost { border: 1px solid var(--border); background: var(--surface); }
.btn--ghost:hover { border-color: var(--accent); }

/* ---------- Sections ---------- */
.section { padding: 110px 0; }
.section--alt { background: var(--bg-alt); }
.section__title { font-size: clamp(30px, 4vw, 40px); font-weight: 700; margin-bottom: 40px; }

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 48px;
}
.grid-2 .section__title { margin-bottom: 0; }

.prose { display: grid; gap: 20px; font-size: 19px; color: var(--muted); }

/* ---------- Cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 20px;
}

.card {
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.card h3 { font-size: 18px; margin: 20px 0 8px; }
.card p { font-size: 15px; color: var(--muted); }

.card__icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent);
}

/* ---------- Timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--border); }
.timeline__item { position: relative; padding: 0 0 44px 32px; }
.timeline__item:last-child { padding-bottom: 0; }
.timeline__item::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 6px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--accent);
}
.timeline__item:first-child::before { background: var(--accent); }
.timeline__date { font-size: 14px; font-weight: 500; color: var(--accent); }
.timeline__item h3 { font-size: 20px; margin-top: 6px; }
.timeline__company { font-weight: 500; color: var(--muted); margin: 2px 0 10px; }
.timeline__item p:last-child { color: var(--muted); font-size: 16px; }

/* ---------- Contact ---------- */
.contact { text-align: center; max-width: 680px; }
.contact .section__title { margin-bottom: 16px; }
.contact__lead { color: var(--muted); font-size: 18px; }
.contact__email {
  display: inline-block;
  margin-top: 32px;
  font-size: clamp(24px, 4vw, 36px);
  font-weight: 700;
  letter-spacing: -0.02em;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-size: 0 2px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size 0.3s, color 0.2s;
  overflow-wrap: anywhere;
}
.contact__email:hover { background-size: 100% 2px; color: var(--accent); }

.socials { display: flex; justify-content: center; gap: 12px; margin-top: 32px; }
.socials a {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  transition: color 0.2s, border-color 0.2s, transform 0.2s;
}
.socials a:hover { color: var(--accent); border-color: var(--accent); transform: translateY(-2px); }

/* ---------- Footer ---------- */
.footer { padding: 32px 0; border-top: 1px solid var(--border); font-size: 14px; color: var(--muted); }

/* ---------- Reveal animation ---------- */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .nav__links { display: none; }
  .theme-toggle { margin-left: auto; }
  .hero { padding: 96px 0 80px; }
  .section { padding: 80px 0; }
  .grid-2 { grid-template-columns: 1fr; gap: 28px; }
  .prose { font-size: 17px; }
}
