:root {
  --ink: #0d1117;
  --cream: #f5f0e8;
  --gold: #c9a84c;
  --gold-light: #e8c97a;
  --muted: #6b7280;
  --line: rgba(201,168,76,0.3);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--ink);
  color: var(--cream);
  font-family: 'Barlow', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
}

/* noise */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 999;
  opacity: 0.4;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 4rem;
  background: linear-gradient(to bottom, rgba(13,17,23,0.97) 0%, transparent 100%);
}
.nav-logo {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
}
.nav-links {
  display: flex;
  gap: 2.5rem;
  list-style: none;
}
.nav-links a {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--cream);
  text-decoration: none;
  opacity: 0.7;
  transition: opacity 0.2s, color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { opacity: 1; color: var(--gold); }

/* hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 24px;
  height: 1px;
  background: var(--cream);
  transition: all 0.3s;
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(4px, 4px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(4px, -4px); }

.mobile-menu {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(13,17,23,0.98);
  z-index: 99;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3rem;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.5rem;
  color: var(--cream);
  text-decoration: none;
  font-style: italic;
  transition: color 0.2s;
}
.mobile-menu a:hover { color: var(--gold); }

/* ── HERO ── */
#hero {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
  overflow: hidden;
}

.hero-left {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 8rem 4rem 6rem;
  position: relative;
  z-index: 2;
}

.hero-tag {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeUp 0.8s 0.3s forwards;
}

.hero-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(4rem, 7vw, 8rem);
  font-weight: 300;
  line-height: 0.95;
  letter-spacing: -0.02em;
  margin-bottom: 2rem;
  opacity: 0;
  animation: fadeUp 0.8s 0.5s forwards;
}
.hero-name em { font-style: italic; color: var(--gold-light); }

.hero-subtitle {
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  color: var(--muted);
  line-height: 1.9;
  max-width: 340px;
  opacity: 0;
  animation: fadeUp 0.8s 0.7s forwards;
}

.hero-stats {
  display: flex;
  gap: 3rem;
  margin-top: 3rem;
  opacity: 0;
  animation: fadeUp 0.8s 0.9s forwards;
}
.stat-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2.2rem;
  font-weight: 300;
  color: var(--gold);
  line-height: 1;
}
.stat-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.58rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 0.2rem;
}

/* ── HERO RIGHT: photo ── */
.hero-right {
  position: relative;
  overflow: hidden;
}

.hero-divider {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--gold) 30%, var(--gold) 70%, transparent);
  opacity: 0.25;
  z-index: 3;
}

.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  opacity: 0;
  animation: photoReveal 1.2s 0.4s forwards;
}

.hero-right::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right, rgba(13,17,23,0.15) 0%, transparent 30%),
    linear-gradient(to top, rgba(13,17,23,0.5) 0%, transparent 40%),
    linear-gradient(to bottom, rgba(13,17,23,0.4) 0%, transparent 20%);
  z-index: 2;
  pointer-events: none;
}

@keyframes photoReveal {
  from { opacity: 0; transform: scale(1.04); }
  to   { opacity: 1; transform: scale(1); }
}

/* ── PAGE HEADER (for sub-pages) ── */
.page-header {
  padding: 12rem 4rem 4rem;
  max-width: 1400px;
  margin: 0 auto;
  border-bottom: 1px solid var(--line);
}
.page-header .page-eyebrow {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.5rem;
}
.page-header .page-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3rem, 6vw, 6rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.02em;
}
.page-header .page-title em { font-style: italic; color: var(--gold-light); }

/* ── SECTION BASE ── */
section {
  padding: 8rem 4rem;
  max-width: 1400px;
  margin: 0 auto;
}

.section-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  margin-bottom: 5rem;
}
.section-num {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.3em;
  color: var(--gold);
}
.section-line-h {
  flex: 1;
  height: 1px;
  background: var(--line);
}
.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.2rem, 4vw, 4.5rem);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.section-title em { font-style: italic; color: var(--gold-light); }

/* ── ABOUT ── */
#about { border-top: 1px solid var(--line); }

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 6rem;
  align-items: start;
}

.about-body p {
  font-size: 1rem;
  line-height: 1.9;
  color: rgba(245,240,232,0.8);
  margin-bottom: 1.5rem;
}

/* ── ABOUT EXTRA: alternating image rows ── */
.about-extra { border-top: 1px solid var(--line); }

.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
  margin-bottom: 7rem;
}
.feature-row:last-child { margin-bottom: 0; }
.feature-row.image-left .feature-text { order: 2; }
.feature-row.image-left .feature-media { order: 1; }

.feature-media {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid var(--line);
}
.feature-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.8s ease;
}
.feature-media:hover img { transform: scale(1.03); }
.feature-media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(13,17,23,0.15) 0%, transparent 40%, rgba(201,168,76,0.05) 100%);
  pointer-events: none;
}

.feature-eyebrow {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.25rem;
}
.feature-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.8rem, 2.6vw, 2.6rem);
  font-weight: 300;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin-bottom: 1.5rem;
}
.feature-title em { font-style: italic; color: var(--gold-light); }
.feature-text p {
  font-size: 1rem;
  line-height: 1.9;
  color: rgba(245,240,232,0.8);
  margin-bottom: 1.25rem;
}

/* ── HOME SECTIONS (lede, inline cta, contributions) ── */
#home-about,
#home-education,
#home-awards,
#home-contributions { border-top: 1px solid var(--line); }

.section-lede {
  font-size: 1rem;
  line-height: 1.9;
  color: rgba(245,240,232,0.8);
  max-width: 760px;
  margin-bottom: 4rem;
}

.inline-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 1rem;
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.35rem;
  transition: color 0.2s, border-color 0.2s, gap 0.2s;
}
.inline-cta:hover { color: var(--gold-light); border-color: var(--gold); gap: 0.9rem; }

.contrib-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-top: 1px solid var(--line);
}
.contrib-item {
  display: grid;
  grid-template-columns: 160px 1fr;
  align-items: start;
  gap: 3rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.2s;
}
.contrib-item:hover { background: rgba(201,168,76,0.03); }

.contrib-marker {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.7rem;
  font-weight: 300;
  color: var(--gold);
  letter-spacing: -0.01em;
  line-height: 1.1;
  border-left: 1px solid var(--gold);
  padding-left: 1.25rem;
}
.contrib-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--cream);
  margin-bottom: 0.6rem;
}
.contrib-body p {
  font-size: 0.95rem;
  line-height: 1.85;
  color: rgba(245,240,232,0.78);
}

/* ── PORTFOLIO ── */
#portfolio {
  border-top: 1px solid var(--line);
  background: linear-gradient(to bottom, transparent, rgba(201,168,76,0.03) 50%, transparent);
}

.portfolio-center { text-align: center; margin-bottom: 5rem; }
.portfolio-big {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(5rem, 12vw, 14rem);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--gold);
  display: block;
}
.portfolio-sub {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 0.5rem;
}

.portfolio-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5px;
  background: var(--line);
  border: 1px solid var(--line);
}

.p-card {
  background: var(--ink);
  padding: 3rem 2.5rem;
  transition: background 0.3s;
  position: relative;
  overflow: hidden;
}
.p-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(201,168,76,0.05) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
}
.p-card:hover { background: rgba(201,168,76,0.04); }
.p-card:hover::before { opacity: 1; }

.p-card-icon { font-size: 1.5rem; margin-bottom: 1.5rem; }
.p-card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  font-weight: 400;
  margin-bottom: 0.75rem;
  color: var(--cream);
}
.p-card-body {
  font-size: 0.85rem;
  line-height: 1.8;
  color: var(--muted);
}

/* ── AWARDS ── */
#awards { border-top: 1px solid var(--line); }

.award-row {
  display: grid;
  grid-template-columns: 80px 1fr auto;
  align-items: center;
  gap: 3rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.2s;
  cursor: default;
}
.award-row:first-child { border-top: 1px solid var(--line); }
.award-row:hover { background: rgba(201,168,76,0.03); }

.award-year {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--gold);
}
.award-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  font-weight: 400;
}
.award-org {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: right;
  white-space: nowrap;
}

/* ── GLOBAL ── */
#global { border-top: 1px solid var(--line); }

.global-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8rem;
  align-items: center;
}

.global-text p {
  font-size: 1rem;
  line-height: 1.9;
  color: rgba(245,240,232,0.8);
  margin-bottom: 1.5rem;
}

.wef-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  border: 1px solid var(--gold);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 1.5rem;
}

.global-visual {
  position: relative;
  aspect-ratio: 1;
  max-width: 380px;
  justify-self: center;
}
.globe-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--line);
  animation: spin linear infinite;
}
.globe-ring:nth-child(1) { inset: 0; animation-duration: 20s; }
.globe-ring:nth-child(2) { inset: 15%; animation-duration: 15s; animation-direction: reverse; border-color: rgba(201,168,76,0.15); }
.globe-ring:nth-child(3) { inset: 30%; animation-duration: 10s; border-color: rgba(201,168,76,0.25); }
.globe-center {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 110px; height: 110px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, rgba(201,168,76,0.2), transparent 70%);
  border: 1px solid rgba(201,168,76,0.4);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.85rem;
  font-style: italic;
  color: var(--gold-light);
  text-align: center;
}
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--line);
  padding: 3rem 4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1400px;
  margin: 0 auto;
}
.footer-brand {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.2rem;
  font-style: italic;
  color: var(--gold-light);
}
.footer-note {
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  nav { padding: 1.25rem 1.5rem; }
  .nav-links { display: none; }
  .hamburger { display: flex; }

  #hero {
    grid-template-columns: 1fr;
    min-height: 100svh;
  }

  .hero-right {
    order: -1;
    height: 55vw;
    min-height: 260px;
    max-height: 380px;
  }
  .hero-right::after {
    background:
      linear-gradient(to bottom, rgba(13,17,23,0.3) 0%, transparent 30%),
      linear-gradient(to top, rgba(13,17,23,0.9) 0%, transparent 50%);
  }
  .hero-divider { display: none; }

  .hero-left {
    padding: 2rem 1.5rem 4rem;
    justify-content: flex-start;
  }
  .hero-tag { margin-bottom: 1rem; }
  .hero-name { font-size: clamp(3rem, 14vw, 5rem); margin-bottom: 1rem; }
  .hero-subtitle { max-width: 100%; font-size: 0.8rem; }
  .hero-stats { gap: 2rem; flex-wrap: wrap; margin-top: 2rem; }

  .page-header { padding: 7rem 1.5rem 3rem; }

  section { padding: 4rem 1.5rem; }
  .section-header { flex-wrap: wrap; gap: 1rem; margin-bottom: 3rem; }
  .section-line-h { display: none; }

  .about-grid { grid-template-columns: 1fr; gap: 2.5rem; }

  .feature-row { grid-template-columns: 1fr; gap: 2rem; margin-bottom: 4rem; }
  .feature-row.image-left .feature-text { order: 2; }
  .feature-row.image-left .feature-media { order: 1; }
  .feature-row .feature-media { order: 1; }
  .feature-row .feature-text { order: 2; }
  .feature-media { aspect-ratio: 16 / 11; }

  .portfolio-cards { grid-template-columns: repeat(2, 1fr); }
  .p-card { padding: 2rem 1.5rem; }

  .award-row {
    grid-template-columns: 55px 1fr;
    gap: 1rem;
    padding: 1.75rem 0;
  }
  .award-org { display: none; }
  .award-name { font-size: 1.15rem; }

  .global-split { grid-template-columns: 1fr; gap: 3rem; }
  .global-visual { max-width: 260px; margin: 0 auto; }

  .section-lede { margin-bottom: 2.5rem; font-size: 0.95rem; }
  .contrib-item {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 2rem 0;
  }
  .contrib-marker {
    font-size: 1.4rem;
    border-left: none;
    padding-left: 0;
    border-bottom: 1px solid var(--gold);
    padding-bottom: 0.4rem;
    display: inline-block;
  }
  .contrib-title { font-size: 1.15rem; }

  footer { flex-direction: column; gap: 0.75rem; text-align: center; padding: 2rem 1.5rem; }
}

@media (min-width: 769px) and (max-width: 1024px) {
  nav { padding: 1.5rem 2.5rem; }
  .hero-left { padding: 8rem 2.5rem 4rem; }
  section { padding: 6rem 2.5rem; }
  .page-header { padding: 10rem 2.5rem 3.5rem; }
  .about-grid { gap: 3rem; }
  .feature-row { gap: 3rem; }
  .global-split { gap: 4rem; }
  .award-row { gap: 1.5rem; }
  .portfolio-cards { grid-template-columns: repeat(4, 1fr); }
}
