*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #faf9f7;
  --bg-warm: #f4f1ec;
  --bg-dark: #1a1a1a;
  --text: #2c2c2c;
  --text-muted: #6b6b6b;
  --text-light: #e8e6e2;
  --text-light-muted: #a3a09b;
  --accent: #c96442;
  --accent-hover: #a84e30;
  --border: #e4e0da;
  --card: #ffffff;
  --serif: 'DM Serif Display', Georgia, serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --radius: 16px;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* ── Nav ── */

nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(250, 249, 247, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 100;
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: var(--serif);
  font-size: 1.15rem;
  text-decoration: none;
  color: var(--text);
}

.nav-links {
  display: flex;
  gap: 2.25rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: color 0.2s;
}

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

/* ── Hero ── */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 7rem 2rem 5rem;
  overflow: hidden;
}

.hero-content {
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  position: relative;
  z-index: 2;
}

.hero h1 {
  font-family: var(--serif);
  font-size: clamp(3rem, 7vw, 5.5rem);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -1px;
  margin-bottom: 1.5rem;
}

.hero-sub {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 480px;
  line-height: 1.7;
  margin-bottom: 2.5rem;
}

.hero-accent {
  position: absolute;
  top: -10%;
  right: -5%;
  width: 55%;
  height: 120%;
  background: linear-gradient(135deg, #f0e0d4 0%, #e6d5c3 50%, #dcc7b0 100%);
  border-radius: 0 0 0 40%;
  opacity: 0.4;
  z-index: 1;
}

/* ── Buttons ── */

.btn {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 100px;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  transition: all 0.25s;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201, 100, 66, 0.25);
}

/* ── Section basics ── */

.section {
  padding: 6rem 2rem;
}

.section-dark {
  background: var(--bg-dark);
  color: var(--text-light);
}

.section-warm {
  background: var(--bg-warm);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
}

.label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.label-light {
  color: var(--accent);
}

h2 {
  font-family: var(--serif);
  font-size: 2.5rem;
  font-weight: 400;
  letter-spacing: -0.5px;
  margin-bottom: 2.5rem;
  line-height: 1.2;
}

.section-heading-light {
  color: var(--text-light);
}

.section-note {
  font-size: 0.95rem;
  color: var(--text-muted);
  font-style: italic;
}

.section-note-bottom {
  margin-top: 2rem;
  text-align: center;
}

/* ── Projects ── */

.projects-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.project-card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s, box-shadow 0.3s;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  border-radius: 20px 20px 0 0;
}

.project-card:first-child::before {
  background: linear-gradient(90deg, var(--accent), #e8956e);
}

.project-card:last-child::before {
  background: linear-gradient(90deg, #4a6fa5, #7b9fd4);
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.08);
}

.project-card-emoji {
  font-size: 2.5rem;
  margin-bottom: 1.25rem;
  line-height: 1;
}

.project-badge {
  display: inline-block;
  width: fit-content;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: #fdf0ea;
  padding: 0.35rem 0.85rem;
  border-radius: 100px;
  margin-bottom: 1.25rem;
}

.badge-new {
  color: #4a6fa5;
  background: #eaf0f7;
}

.project-card h3 {
  font-family: var(--serif);
  font-size: 1.6rem;
  font-weight: 400;
  margin-bottom: 0.6rem;
}

.project-tagline {
  font-family: var(--serif);
  font-size: 1.05rem;
  color: var(--text);
  font-weight: 400;
  margin-bottom: 1.25rem;
  line-height: 1.45;
  font-style: italic;
}

.project-card > p:last-of-type {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.project-links .btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  padding: 0.6rem 1.3rem;
}

.project-links .btn-secondary {
  border: 1px solid var(--border);
  color: var(--text-muted);
}

.project-links .btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: #fdf0ea;
}

/* ── Publication strip ── */

.section-pub {
  padding: 3rem 2rem;
  border-top: 1px solid var(--border);
}

.pub-card {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-top: 0.5rem;
}

.pub-venue {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: #fdf0ea;
  padding: 0.3rem 0.7rem;
  border-radius: 6px;
  flex-shrink: 0;
}

.pub-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ── About ── */

.about-grid {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 4rem;
  align-items: start;
}

.about-text p {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  max-width: 600px;
  line-height: 1.75;
}

.about-text strong {
  color: var(--text);
  font-weight: 600;
}

.about-details {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.detail-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: center;
}

.detail-number {
  display: block;
  font-family: var(--serif);
  font-size: 2rem;
  color: var(--accent);
  margin-bottom: 0.25rem;
}

.detail-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* ── Experience ── */

.experience-list {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin-bottom: 4rem;
}

.exp-card {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 2.5rem;
  padding: 2rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.exp-card:first-child {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.exp-when {
  font-size: 0.85rem;
  color: var(--text-light-muted);
  font-weight: 500;
  padding-top: 0.2rem;
  font-variant-numeric: tabular-nums;
}

.exp-body h3 {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--text-light);
  margin-bottom: 0.2rem;
}

.exp-company {
  font-size: 0.9rem;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.exp-body p:last-child {
  font-size: 0.95rem;
  color: var(--text-light-muted);
  line-height: 1.7;
  max-width: 520px;
}

/* ── Tech strip ── */

.tech-strip {
  padding-top: 2rem;
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.5rem;
}

.tech-tags span {
  padding: 0.45rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 100px;
  font-size: 0.82rem;
  color: var(--text-light-muted);
  font-weight: 500;
  transition: all 0.2s;
}

.tech-tags span:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ── Beyond Code ── */

.passions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.passion-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem;
  transition: transform 0.3s, box-shadow 0.3s;
}

.passion-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.06);
}

.passion-emoji {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  line-height: 1;
}

.passions-three {
  grid-template-columns: repeat(3, 1fr);
}

.passion-card h3 {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 400;
  margin-bottom: 0.75rem;
}

.passion-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.75;
}

.passion-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 1rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
}

.passion-link:hover {
  opacity: 0.75;
}

.inline-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}

.inline-link:hover {
  border-bottom-color: var(--accent);
}

/* ── Education ── */

.edu-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2.5rem;
}

.edu-top {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.edu-emoji {
  font-size: 2.5rem;
  line-height: 1;
}

.edu-degree {
  font-family: var(--serif);
  font-size: 1.35rem;
  margin-bottom: 0.2rem;
}

.edu-dates {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.edu-description {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

/* ── Contact ── */

.contact-wrap {
  text-align: center;
  max-width: 540px;
  margin: 0 auto;
}

.contact-blurb {
  font-size: 1.1rem;
  color: var(--text-light-muted);
  margin-bottom: 2.5rem;
  line-height: 1.7;
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.contact-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 100px;
  text-decoration: none;
  color: var(--text-light);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.25s;
}

.contact-pill:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

.contact-pill svg {
  flex-shrink: 0;
}

/* ── Footer ── */

footer {
  text-align: center;
  padding: 2.5rem 2rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
}

/* ── Responsive ── */

@media (max-width: 900px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .about-details {
    flex-direction: row;
  }

  .detail-card {
    flex: 1;
  }

  .edu-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }

  .hero h1 {
    font-size: 2.75rem;
  }

  .hero-accent {
    width: 80%;
    opacity: 0.25;
  }

  .exp-card {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .projects-grid,
  .passions-grid,
  .passions-three {
    grid-template-columns: 1fr;
  }

  .about-details {
    flex-direction: column;
  }

  .contact-links {
    flex-direction: column;
    align-items: center;
  }

  h2 {
    font-size: 2rem;
  }
}
