:root {
  --background: #020817;
  --background-soft: #050b17;
  --card: #07101f;
  --card-elevated: #0b1423;
  --border: #1f2a3a;
  --border-subtle: #111b2a;
  --foreground: #dfe6ee;
  --foreground-strong: #f8fafc;
  --foreground-muted: #a8b2c1;
  --foreground-soft: #778397;
  --accent: #f8fafc;
  --accent-foreground: #020817;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --shadow-soft: 0 20px 50px rgba(0, 0, 0, 0.35);
  --max-width: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }
body {
  min-height: 100vh;
  background: var(--background);
  color: var(--foreground);
  font-family: "Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: none; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem; }
.section { padding: 5rem 0; border-top: 1px solid var(--border-subtle); }
.section-alt { background: var(--background-soft); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(2, 8, 23, 0.9);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
}
.nav-container { height: 64px; display: flex; align-items: center; justify-content: space-between; }
.logo {
  width: 42px; height: 42px; border: 1px solid #364152; border-radius: 999px;
  display: grid; place-items: center; background: var(--card-elevated); box-shadow: var(--shadow-soft);
}
.logo-text { font-weight: 600; letter-spacing: .12em; transform: translateX(1px); }
.nav { display: flex; gap: .15rem; font-size: .92rem; }
.nav a { color: var(--foreground-soft); padding: .35rem .6rem; border-radius: 999px; }
.nav a:hover { color: var(--foreground-strong); background: var(--card-elevated); }

.hero { padding: 6rem 0 5rem; }
.hero-content { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(300px, .9fr); gap: 3.2rem; align-items: start; }
.hero-text { max-width: 720px; }
.eyebrow, .hero-kicker {
  margin: 0 0 .75rem; font-size: .78rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .16em; color: var(--foreground-soft);
}
.hero h1 { margin: 0 0 1.15rem; font-size: clamp(2.45rem, 5vw, 4.6rem); line-height: 1.02; letter-spacing: -.04em; font-weight: 600; color: var(--foreground-strong); }
.hero-subtitle { margin: 0 0 1.6rem; max-width: 680px; font-size: 1.08rem; color: var(--foreground-muted); }
.hero-tags, .project-points { display: flex; flex-wrap: wrap; gap: .5rem; }
.hero-tags { margin-bottom: 1.8rem; }
.hero-tags span, .project-points span {
  display: inline-flex; align-items: center; border: 1px solid var(--border); background: var(--card-elevated);
  color: var(--foreground-muted); border-radius: 999px; padding: .28rem .62rem; font-size: .84rem;
}
.hero-actions, .contact-actions, .project-links { display: flex; flex-wrap: wrap; gap: .7rem; }
.btn, .project-links a {
  display: inline-flex; align-items: center; justify-content: center; min-height: 40px;
  padding: .55rem 1rem; border-radius: 999px; font-size: .9rem; font-weight: 500;
  border: 1px solid var(--border); transition: .16s ease;
}
.btn.primary, .project-links a { background: var(--accent); color: var(--accent-foreground); border-color: var(--accent); }
.btn.ghost { background: transparent; color: var(--foreground-muted); }
.btn:hover, .project-links a:hover { transform: translateY(-1px); }
.btn.ghost:hover { color: var(--foreground-strong); background: var(--card-elevated); }
.project-links a:hover { background: transparent; color: var(--foreground-strong); border-color: #475569; }

.hero-side { display: grid; gap: 1rem; }
.hero-card {
  padding: 1.25rem 1.35rem; border: 1px solid var(--border); border-radius: var(--radius-lg);
  background: var(--card); box-shadow: var(--shadow-soft);
}
.hero-card h2 { margin: 0 0 .65rem; font-size: 1.2rem; color: var(--foreground-strong); }
.hero-card p { margin: 0 0 .8rem; color: var(--foreground-muted); }
.hero-card ul { margin: 0; padding-left: 1.1rem; color: var(--foreground-muted); }
.hero-card li + li { margin-top: .35rem; }
.compact-list { list-style: none; padding-left: 0 !important; }

.section-header { margin-bottom: 2rem; }
.section-header h2, .education-wrap h2, .contact-panel h2 {
  margin: 0; font-size: clamp(1.75rem, 3vw, 2.35rem); line-height: 1.15; letter-spacing: -.025em;
  color: var(--foreground-strong); font-weight: 600;
}
.section-header > p:last-child { margin: .55rem 0 0; color: var(--foreground-soft); max-width: 720px; }
.wide-header { display: flex; justify-content: space-between; gap: 2rem; align-items: end; }
.wide-header > p { max-width: 500px; text-align: right; }

.featured-projects { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.project-card {
  border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--card);
  padding: 1.45rem; box-shadow: var(--shadow-soft);
}
.project-card.featured { min-height: 100%; display: flex; flex-direction: column; }
.project-topline { display: flex; align-items: center; justify-content: space-between; gap: .8rem; margin-bottom: 1.2rem; }
.project-number { color: var(--foreground-soft); font-size: .82rem; letter-spacing: .12em; }
.status-badge { border: 1px solid #4b5563; border-radius: 999px; padding: .22rem .55rem; color: var(--foreground); font-size: .76rem; }
.status-badge.subtle { color: var(--foreground-soft); border-color: var(--border); }
.project-card h3, .supporting-project h3, .timeline-item h3, .focus-card h3, .skill-card h3, .education-detail h3 {
  margin: 0 0 .55rem; color: var(--foreground-strong); font-size: 1.12rem; font-weight: 600;
}
.project-tagline { margin: 0 0 .9rem; color: var(--foreground-soft); font-size: .86rem; }
.project-card > p:not(.project-tagline):not(.project-note) { color: var(--foreground-muted); }
.project-points { margin: .9rem 0 1.2rem; }
.project-links { margin-top: auto; padding-top: .4rem; }
.project-note { margin: auto 0 0; padding-top: 1rem; font-size: .84rem; color: var(--foreground-soft); }
.muted-project { background: linear-gradient(180deg, rgba(11, 20, 35, .95), rgba(7, 16, 31, .95)); }
.supporting-project {
  margin-top: 1.25rem; display: flex; justify-content: space-between; align-items: center; gap: 2rem;
  border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: 1.2rem 1.35rem; background: var(--background-soft);
}
.supporting-project p { margin: .25rem 0 0; color: var(--foreground-muted); }

.about-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3rem; }
.about-grid p { margin-top: 0; color: var(--foreground-muted); font-size: 1rem; }

.focus-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.focus-card, .skill-card {
  border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--card); padding: 1.15rem;
}
.focus-card p, .skill-card p { margin: 0; color: var(--foreground-muted); }

.timeline { display: grid; gap: 1px; border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; background: var(--border); }
.timeline-item { display: grid; grid-template-columns: 220px 1fr; gap: 2rem; padding: 1.5rem; background: var(--card); }
.timeline-meta { display: flex; flex-direction: column; gap: .3rem; color: var(--foreground-soft); font-size: .88rem; }
.timeline-item p { margin: 0 0 .65rem; color: var(--foreground-muted); }
.timeline-item ul { margin: 0; padding-left: 1.15rem; color: var(--foreground-muted); }
.timeline-item li + li { margin-top: .35rem; }

.skills-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.skill-card { min-height: 118px; }

.education-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: end; }
.education-detail p { margin: 0; color: var(--foreground-muted); }

.contact-panel {
  display: grid; grid-template-columns: minmax(0, 1.5fr) auto; gap: 2rem; align-items: center;
  border: 1px solid var(--border); background: var(--card); border-radius: var(--radius-lg); padding: 1.6rem;
}
.contact-panel > div:first-child > p:last-child { margin: .65rem 0 0; color: var(--foreground-muted); }
.contact-actions { justify-content: flex-end; }

.site-footer { border-top: 1px solid var(--border-subtle); }
.footer-inner { min-height: 72px; display: flex; align-items: center; justify-content: center; color: var(--foreground-soft); font-size: .88rem; text-align: center; }

@media (max-width: 960px) {
  .hero-content, .featured-projects, .about-grid, .education-wrap { grid-template-columns: 1fr; }
  .focus-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wide-header { display: block; }
  .wide-header > p { text-align: left; }
  .timeline-item { grid-template-columns: 160px 1fr; }
  .contact-panel { grid-template-columns: 1fr; }
  .contact-actions { justify-content: flex-start; }
}

@media (max-width: 760px) {
  .nav { display: none; }
  .hero { padding: 4.25rem 0 3.75rem; }
  .section { padding: 4rem 0; }
  .hero h1 { font-size: clamp(2.35rem, 11vw, 3.25rem); }
  .focus-grid, .skills-grid { grid-template-columns: 1fr; }
  .timeline-item { grid-template-columns: 1fr; gap: .8rem; }
  .supporting-project { display: block; }
  .supporting-project .project-links { margin-top: 1rem; }
}

@media (max-width: 480px) {
  .container { padding: 0 1rem; }
  .hero-actions, .contact-actions { flex-direction: column; align-items: stretch; }
  .btn { width: 100%; }
  .project-links a { width: 100%; }
  .project-links { flex-direction: column; }
}
