:root {
  --color-bg: #ffffff;
  --color-bg-alt: #f6f7f9;
  --color-surface: #ffffff;
  --color-border: #e4e6ea;
  --color-text: #16181d;
  --color-text-muted: #565c66;
  --color-accent: #2f5bea;
  --color-accent-dark: #1f3fb0;
  --color-accent-contrast: #ffffff;
  --shadow-sm: 0 1px 2px rgba(16, 20, 30, 0.06);
  --shadow-md: 0 8px 24px rgba(16, 20, 30, 0.08);
  --radius-md: 10px;
  --radius-lg: 16px;
  --max-width: 1080px;
  --header-height: 68px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-bg: #0f1115;
    --color-bg-alt: #15181f;
    --color-surface: #181b23;
    --color-border: #262a34;
    --color-text: #eef0f4;
    --color-text-muted: #9aa1ad;
    --color-accent: #6d8bff;
    --color-accent-dark: #8ba0ff;
    --color-accent-contrast: #0f1115;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  }
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: "Segoe UI", Inter, system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-accent);
  color: var(--color-accent-contrast);
  padding: 10px 16px;
  border-radius: 0 0 8px 0;
  z-index: 100;
}
.skip-link:focus {
  left: 0;
}

a {
  color: var(--color-accent);
  text-decoration: none;
}
a:hover {
  color: var(--color-accent-dark);
}

img {
  max-width: 100%;
  display: block;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--color-bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--color-border);
}

.header-inner {
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
  color: var(--color-text);
}
.logo:hover {
  color: var(--color-accent);
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 32px;
  margin: 0;
  padding: 0;
}

.main-nav a {
  color: var(--color-text-muted);
  font-weight: 600;
  font-size: 0.95rem;
}
.main-nav a:hover {
  color: var(--color-text);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 22px;
  background: var(--color-text);
  margin: 0 auto;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  display: none;
  max-height: 0;
  overflow: hidden;
  border-bottom: 1px solid var(--color-border);
  transition: max-height 0.25s ease;
}
.mobile-nav.open {
  max-height: 240px;
}
.mobile-nav ul {
  list-style: none;
  margin: 0;
  padding: 8px 24px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mobile-nav a {
  display: block;
  padding: 10px 4px;
  color: var(--color-text);
  font-weight: 600;
  border-bottom: 1px solid var(--color-border);
}

/* Hero */
.hero {
  padding: 96px 0 72px;
  background:
    radial-gradient(1200px 480px at 15% -10%, color-mix(in srgb, var(--color-accent) 14%, transparent), transparent 60%),
    var(--color-bg);
}

.eyebrow {
  display: inline-block;
  color: var(--color-accent-dark);
  background: color-mix(in srgb, var(--color-accent) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--color-accent) 30%, transparent);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  margin: 0 0 20px;
}

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  line-height: 1.08;
  margin: 0 0 12px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.hero-role {
  font-size: clamp(1.1rem, 2.4vw, 1.4rem);
  color: var(--color-text-muted);
  margin: 0 0 32px;
  font-weight: 500;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-accent-contrast);
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: var(--color-accent-dark);
  color: var(--color-accent-contrast);
  box-shadow: var(--shadow-md);
}

.btn-ghost {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-border);
}
.btn-ghost:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/* Sections */
.section {
  padding: 72px 0;
  scroll-margin-top: var(--header-height);
}

.section-alt {
  background: var(--color-bg-alt);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.section-title {
  font-size: clamp(1.5rem, 3vw, 1.9rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  margin: 0 0 32px;
}

.section-title-spaced {
  margin-top: 56px;
}

/* Profile */
.profile-grid {
  display: grid;
  grid-template-columns: minmax(260px, 380px) 1fr;
  gap: 40px;
  align-items: start;
}

.profile-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 8px 24px;
  box-shadow: var(--shadow-sm);
  margin: 0;
}

.profile-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--color-border);
}
.profile-row:last-child {
  border-bottom: none;
}

.profile-row dt {
  color: var(--color-text-muted);
  font-weight: 600;
  font-size: 0.9rem;
}

.profile-row dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

.profile-summary p {
  color: var(--color-text-muted);
  font-size: 1.05rem;
  margin: 0 0 18px;
}
.profile-summary p:last-child {
  margin-bottom: 0;
}

/* Timeline */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  position: relative;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--color-border);
}

.timeline-item {
  position: relative;
  padding: 0 0 40px 40px;
}
.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-marker {
  position: absolute;
  left: 0;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--color-surface);
  border: 3px solid var(--color-accent);
}

.timeline-content {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  box-shadow: var(--shadow-sm);
}

.timeline-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 16px;
  margin-bottom: 4px;
}

.timeline-head h3 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.timeline-date {
  color: var(--color-text-muted);
  font-size: 0.88rem;
  font-weight: 600;
  white-space: nowrap;
}

.timeline-org {
  color: var(--color-accent-dark);
  font-weight: 700;
  margin: 0 0 12px;
  font-size: 0.98rem;
}

.timeline-content p {
  color: var(--color-text-muted);
  margin: 0 0 12px;
}
.timeline-content p:last-child,
.timeline-content ul:last-child {
  margin-bottom: 0;
}

.timeline-content ul {
  margin: 0;
  padding-left: 20px;
  color: var(--color-text-muted);
}
.timeline-content li {
  margin-bottom: 6px;
}
.timeline-content li:last-child {
  margin-bottom: 0;
}

/* Contact */
.contact-intro {
  color: var(--color-text-muted);
  font-size: 1.05rem;
  margin: -16px 0 32px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.contact-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

a.contact-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-accent);
}

.contact-label {
  color: var(--color-text-muted);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.contact-value {
  color: var(--color-text);
  font-size: 1.1rem;
  font-weight: 700;
  word-break: break-word;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 28px 0;
}

.footer-inner {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  text-align: center;
}

/* Responsive */
@media (max-width: 860px) {
  .profile-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .main-nav {
    display: none;
  }
  .nav-toggle {
    display: flex;
  }
  .mobile-nav {
    display: block;
  }
  .hero {
    padding: 64px 0 48px;
  }
  .section {
    padding: 56px 0;
  }
  .timeline-item {
    padding-left: 30px;
  }
  .timeline::before {
    left: 5px;
  }
  .timeline-marker {
    width: 12px;
    height: 12px;
  }
  .timeline-content {
    padding: 20px;
  }
  .profile-row {
    flex-direction: column;
    gap: 4px;
  }
  .profile-row dd {
    text-align: left;
  }
}

@media (max-width: 420px) {
  .container {
    padding: 0 16px;
  }
  .hero-actions {
    flex-direction: column;
  }
  .btn {
    width: 100%;
  }
}
