:root {
  color-scheme: light;
  --bg: #f6f1fb;
  --surface: rgba(255, 255, 255, 0.82);
  --surface-strong: #ffffff;
  --text: #241336;
  --text-muted: #5b4a6f;
  --accent: #6d3fa8;
  --accent-strong: #4f2a82;
  --border: rgba(109, 63, 168, 0.16);
  --shadow: 0 20px 45px rgba(80, 44, 129, 0.14);
}

:root[data-theme='dark'] {
  color-scheme: dark;
  --bg: #140d1f;
  --surface: rgba(33, 22, 48, 0.88);
  --surface-strong: #1e1530;
  --text: #f6eefc;
  --text-muted: #c8b7d8;
  --accent: #b491e8;
  --accent-strong: #d6bfff;
  --border: rgba(180, 145, 232, 0.2);
  --shadow: 0 24px 50px rgba(8, 4, 14, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background:
    radial-gradient(circle at top left, rgba(109, 63, 168, 0.18), transparent 31%),
    var(--bg);
  color: var(--text);
  min-height: 100vh;
  transition: background 0.3s ease, color 0.3s ease;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 40%);
}

.site-shell {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 24px 56px;
}

.hero {
  padding: 24px 0 36px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
}

.brand {
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  color: var(--text);
  text-decoration: none;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav-links a,
.theme-toggle {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.nav-links a:hover,
.theme-toggle:hover {
  color: var(--accent);
}

.theme-toggle {
  border: 1px solid var(--border);
  background: var(--surface-strong);
  border-radius: 999px;
  padding: 8px 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.hero__content {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 24px;
  align-items: center;
  padding: 56px 0 24px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.24em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 12px;
}

.hero h1 {
  font-size: clamp(2.2rem, 4vw, 3.7rem);
  line-height: 1.08;
  margin: 0 0 16px;
}

.hero__summary,
.card p,
.contact-card p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-muted);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button--primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 12px 24px rgba(109, 63, 168, 0.22);
}

.button--secondary {
  background: var(--surface-strong);
  color: var(--text);
  border: 1px solid var(--border);
}

.hero__card,
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  border-radius: 24px;
  padding: 24px;
  backdrop-filter: blur(16px);
}

.card-chip {
  display: inline-block;
  margin-bottom: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(109, 63, 168, 0.14);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
}

.hero__card h2,
.section-heading h2 {
  margin: 0 0 10px;
}

.hero__card ul {
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--text-muted);
  line-height: 1.8;
}

.bullet-list {
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--text-muted);
  line-height: 1.8;
}

.section {
  padding: 28px 0;
}

.section-heading {
  margin-bottom: 18px;
}

.about-grid,
.skills-grid {
  display: grid;
  gap: 18px;
}

.about-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.skills-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.skill-card h3,
.card h3 {
  margin-top: 0;
}

.contact-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.contact-links a {
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 900px) {
  .hero__content {
    grid-template-columns: 1fr;
  }

  .skills-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .site-shell {
    padding: 16px 16px 40px;
  }

  .topbar {
    border-radius: 20px;
    padding: 14px 16px;
    flex-wrap: wrap;
    gap: 10px;
  }

  .nav-links {
    width: 100%;
    justify-content: space-between;
  }

  .about-grid,
  .skills-grid {
    grid-template-columns: 1fr;
  }
}
