:root {
  --bg: #ffffff;
  --bg-alt: #f6f7f9;
  --text: #14171a;
  --text-muted: #5b6472;
  --accent: #2b5fff;
  --accent-contrast: #ffffff;
  --border: #e5e7eb;
  --card-bg: #ffffff;
  --shadow: 0 1px 3px rgba(20, 23, 26, 0.06), 0 1px 2px rgba(20, 23, 26, 0.04);
  --max-width: 780px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1115;
    --bg-alt: #171a20;
    --text: #eef0f3;
    --text-muted: #9aa3af;
    --accent: #6d8bff;
    --accent-contrast: #0f1115;
    --border: #262b33;
    --card-bg: #171a20;
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.4), 0 1px 2px rgba(0, 0, 0, 0.3);
  }
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

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

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

#app.loading {
  opacity: 0;
}

#app {
  opacity: 1;
  transition: opacity 0.25s ease;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.brand {
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.02em;
}

.nav-links {
  display: flex;
  gap: 24px;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.15s ease;
}

.nav-links a:hover {
  color: var(--accent);
}

.hero {
  padding: 96px 24px 64px;
}

.eyebrow {
  color: var(--accent);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 8px;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  margin: 0 0 8px;
  letter-spacing: -0.02em;
}

.hero-title {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin: 0 0 20px;
  font-weight: 500;
}

.hero-bio {
  max-width: 560px;
  color: var(--text-muted);
  margin: 0 0 24px;
}

.hero-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-links a {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.hero-links a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.section {
  padding: 56px 24px;
  border-top: 1px solid var(--border);
}

.section h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 24px;
  letter-spacing: -0.01em;
}

.resume-block {
  margin-bottom: 36px;
}

.resume-block h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 16px;
}

.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.timeline-item {
  padding: 16px 20px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.timeline-item-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.timeline-item-title {
  font-weight: 600;
  font-size: 1rem;
}

.timeline-item-subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.timeline-item-dates {
  color: var(--text-muted);
  font-size: 0.82rem;
  white-space: nowrap;
}

.timeline-item-desc {
  margin: 8px 0 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.skills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skills li {
  padding: 6px 14px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.85rem;
  color: var(--text);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

.project-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--text);
  display: flex;
  flex-direction: column;
}

.project-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.project-card-body {
  padding: 16px;
}

.project-card-title {
  font-weight: 600;
  margin: 0 0 6px;
}

.project-card-desc {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0;
}

.site-footer {
  padding: 32px 24px;
  color: var(--text-muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--border);
}

.empty-hint {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-style: italic;
}

@media (max-width: 480px) {
  .nav-links {
    gap: 14px;
  }
  .hero {
    padding: 72px 20px 48px;
  }
}
