:root {
  --bg: #f7f8fb;
  --surface: #ffffff;
  --surface-2: #eef1f7;
  --text: #141a26;
  --muted: #5a6478;
  --line: #dde2ec;
  --accent: #2456d6;
  --accent-soft: #e6edfd;
  --accent-text: #ffffff;
  --hero-bg: #0f1a33;
  --hero-text: #f2f5fb;
  --hero-muted: #a9b5cf;
  --radius: 14px;
  --max: 1080px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c111c;
    --surface: #131a28;
    --surface-2: #1a2334;
    --text: #e8ecf4;
    --muted: #9aa5ba;
    --line: #253047;
    --accent: #6d97ff;
    --accent-soft: #1b2a4d;
    --accent-text: #0c111c;
    --hero-bg: #080c15;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0c111c;
  --surface: #131a28;
  --surface-2: #1a2334;
  --text: #e8ecf4;
  --muted: #9aa5ba;
  --line: #253047;
  --accent: #6d97ff;
  --accent-soft: #1b2a4d;
  --accent-text: #0c111c;
  --hero-bg: #080c15;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--hero-bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.nav .wrap { display: flex; align-items: center; gap: 24px; height: 60px; }
.brand { color: var(--hero-text); font-weight: 700; letter-spacing: -.01em; }
.brand:hover { text-decoration: none; }
.nav ul { list-style: none; margin: 0 auto 0 0; padding: 0; display: flex; gap: 20px; }
.nav ul a { color: var(--hero-muted); font-size: 14px; }
.nav ul a:hover { color: var(--hero-text); text-decoration: none; }
.lang {
  display: flex; padding: 3px; gap: 2px;
  border: 1px solid rgba(255,255,255,.2); border-radius: 999px;
}
.lang a {
  color: var(--hero-muted); font-size: 13px; font-weight: 600;
  padding: 3px 11px; border-radius: 999px;
}
.lang a:hover { color: var(--hero-text); background: rgba(255,255,255,.08); text-decoration: none; }
.lang a[aria-current] { background: #4f7dff; color: #fff; cursor: default; }

/* Hero */
.hero { background: var(--hero-bg); color: var(--hero-text); padding: 88px 0 96px; }
.hero .wrap { display: grid; grid-template-columns: 1fr auto; gap: 48px; align-items: center; }
.eyebrow { color: var(--hero-muted); font-size: 14px; letter-spacing: .08em; text-transform: uppercase; margin: 0 0 12px; }
.hero h1 { font-size: clamp(36px, 6vw, 60px); line-height: 1.05; letter-spacing: -.03em; margin: 0 0 16px; }
.hero .role { font-size: clamp(19px, 2.4vw, 24px); color: #c9d4ec; margin: 0 0 20px; font-weight: 500; }
.hero .role strong { color: #fff; }
.hero p.lead { color: var(--hero-muted); max-width: 640px; margin: 0 0 32px; font-size: 17px; }
.monogram {
  width: 168px; height: 168px; border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, #2456d6, #7a2a8f);
  font-size: 56px; font-weight: 800; letter-spacing: -.04em; color: #fff;
  box-shadow: 0 0 0 8px rgba(255,255,255,.05);
}
.facts { display: flex; flex-wrap: wrap; gap: 10px 28px; margin: 0 0 32px; padding: 0; list-style: none; color: #c9d4ec; font-size: 15px; }
.facts b { color: #fff; font-size: 20px; margin-right: 6px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 20px; border-radius: 10px; font-weight: 600; font-size: 15px;
  border: 1px solid transparent;
}
.btn:hover { text-decoration: none; filter: brightness(1.08); }
.btn-primary { background: #4f7dff; color: #fff; }
.btn-ghost { color: var(--hero-text); border-color: rgba(255,255,255,.25); }
.btn-ghost:hover { background: rgba(255,255,255,.08); }
.btn svg { width: 18px; height: 18px; }

/* Sections */
section.block { padding: 80px 0; border-bottom: 1px solid var(--line); }
section.block:last-of-type { border-bottom: 0; }
.sec-head { margin-bottom: 36px; max-width: 720px; }
.sec-head .num { color: var(--accent); font-weight: 700; font-size: 13px; letter-spacing: .1em; }
.sec-head h2 { font-size: clamp(26px, 3.4vw, 34px); letter-spacing: -.02em; line-height: 1.15; margin: 6px 0 10px; }
.sec-head p { color: var(--muted); margin: 0; }

.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px;
}
.card h3 { margin: 0 0 6px; font-size: 18px; letter-spacing: -.01em; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
.card .meta { color: var(--muted); font-size: 13px; margin-bottom: 10px; }
.card .result {
  margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line);
  font-size: 14px; color: var(--text);
}
.card .result b { color: var(--accent); }
.integ .card .via { margin-top: 10px; font-size: 13px; color: var(--muted); }
.integ .card .via b { color: var(--text); font-weight: 600; }

.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; padding: 0; list-style: none; }
.tags li {
  font-size: 12.5px; font-weight: 500; padding: 3px 10px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent);
}

/* Experience timeline */
.timeline { list-style: none; margin: 40px 0 0; padding: 0; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 28px 28px; }
.timeline li::before {
  content: ""; position: absolute; left: -7px; top: 7px; width: 12px; height: 12px;
  border-radius: 50%; background: var(--surface); border: 2px solid var(--accent);
}
.timeline li:first-child::before { background: var(--accent); }
.timeline .when { font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.timeline h3 { margin: 2px 0 4px; font-size: 17px; }
.timeline h3 span { color: var(--muted); font-weight: 500; }
.timeline p { margin: 0; color: var(--muted); font-size: 15px; max-width: 760px; }

/* Featured projects */
.feature {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 32px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 32px;
}
.feature + .feature { margin-top: 20px; }
.feature .kicker { font-size: 13px; font-weight: 600; color: var(--accent); }
.feature h3 { font-size: 26px; letter-spacing: -.02em; margin: 4px 0 10px; }
.feature p { color: var(--muted); margin: 0 0 12px; }
.feature ul.points { margin: 0; padding-left: 18px; color: var(--muted); font-size: 15px; }
.feature ul.points li { margin-bottom: 6px; }
.feature .side { background: var(--surface-2); border-radius: 12px; padding: 22px; font-size: 14px; }
.feature .side h4 { margin: 0 0 8px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.feature .side dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; }
.feature .side dt { color: var(--muted); }
.feature .side dd { margin: 0; font-weight: 500; }
.feature .links { margin-top: 16px; display: flex; gap: 16px; font-weight: 600; font-size: 14px; }

/* Integrations */
.integ .card { display: flex; flex-direction: column; }
.integ .logo {
  width: 44px; height: 44px; border-radius: 10px; margin-bottom: 14px;
  display: grid; place-items: center; font-weight: 800; font-size: 15px;
  background: var(--accent-soft); color: var(--accent);
}

/* Education */
.edu { display: grid; grid-template-columns: 1.4fr 1fr; gap: 18px; }
.badge-card { display: flex; gap: 20px; align-items: center; }
.badge-card img { width: 110px; height: 110px; flex: none; }
.certs { columns: 2; column-gap: 32px; padding-left: 18px; margin: 0; color: var(--muted); font-size: 15px; }
.certs li { margin-bottom: 6px; break-inside: avoid; }
.certs li b { color: var(--text); font-weight: 600; }

/* CV + Contact */
.cta {
  background: var(--hero-bg); color: var(--hero-text); border-radius: 20px; padding: 44px;
  display: grid; grid-template-columns: 1fr auto; gap: 32px; align-items: center;
}
.cta h2 { margin: 0 0 8px; font-size: 28px; letter-spacing: -.02em; }
.cta p { margin: 0; color: var(--hero-muted); }
.contact { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 18px; }
.contact a.card { display: flex; gap: 14px; align-items: center; color: var(--text); }
.contact a.card:hover { border-color: var(--accent); text-decoration: none; }
.contact svg { width: 26px; height: 26px; flex: none; color: var(--accent); }
.contact small { display: block; color: var(--muted); font-size: 13px; }
.contact span { font-weight: 600; word-break: break-word; }

footer { padding: 32px 0 48px; color: var(--muted); font-size: 14px; text-align: center; }

@media (max-width: 860px) {
  .nav ul { display: none; }
  .nav .wrap { justify-content: space-between; }
  .hero { padding: 56px 0 64px; }
  .hero .wrap { grid-template-columns: 1fr; }
  .monogram { display: none; }
  .g3, .g2, .feature, .edu, .contact, .cta { grid-template-columns: 1fr; }
  .feature, .cta { padding: 24px; }
  .certs { columns: 1; }
  section.block { padding: 56px 0; }
}
@media (max-width: 480px) {
  .wrap { padding: 0 16px; }
  .badge-card { flex-direction: column; align-items: flex-start; }
  .actions .btn { flex: 1 1 100%; justify-content: center; }
}
