:root {
  --bg: #0b0d10;
  --bg-2: #12151a;
  --card: #161a20;
  --line: #262b33;
  --text: #eef1f4;
  --muted: #9aa3ae;
  --accent: #c6ff3d;
  --accent-ink: #0b0d10;
  --radius: 18px;
  --max: 1180px;
  --display: "Space Grotesk", system-ui, sans-serif;
  --body: "Inter", system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
::selection { background: var(--accent); color: var(--accent-ink); }

/* NAV */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px clamp(16px, 4vw, 48px);
  background: rgba(11, 13, 16, .72);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.nav.scrolled { border-color: var(--line); }
.logo { font-family: var(--display); font-weight: 700; font-size: 24px; letter-spacing: -.02em; }
.logo span { color: var(--accent); }
.links { display: flex; gap: 30px; align-items: center; font-size: 15px; }
.links a { color: var(--muted); transition: color .2s; }
.links a:hover { color: var(--text); }
.links .nav-cta { color: var(--accent-ink); background: var(--accent); padding: 8px 16px; border-radius: 999px; font-weight: 600; }
.links .nav-cta:hover { color: var(--accent-ink); }
.menu-btn { display: none; background: none; border: 0; width: 36px; height: 36px; cursor: pointer; position: relative; }
.menu-btn span { position: absolute; left: 6px; right: 6px; height: 2px; background: var(--text); transition: transform .3s, top .3s; }
.menu-btn span:first-child { top: 13px; }
.menu-btn span:last-child { top: 21px; }
.menu-btn[aria-expanded="true"] span:first-child { top: 17px; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] span:last-child { top: 17px; transform: rotate(-45deg); }

/* SHARED */
main > section { padding-left: clamp(16px, 4vw, 48px); padding-right: clamp(16px, 4vw, 48px); }
.section { max-width: var(--max); margin: 0 auto; padding-top: 120px; padding-bottom: 40px; }
.section-head { display: flex; align-items: baseline; gap: 18px; margin-bottom: 48px; border-bottom: 1px solid var(--line); padding-bottom: 20px; }
.section-head .num { font-family: var(--display); color: var(--accent); font-size: 18px; }
.section-head h2 { font-family: var(--display); font-size: clamp(40px, 7vw, 84px); line-height: 1; letter-spacing: -.035em; }
.section-intro { color: var(--muted); max-width: 560px; margin: -24px 0 36px; }
.eyebrow { font-size: 14px; text-transform: uppercase; letter-spacing: .14em; color: var(--accent); font-weight: 600; }

.btn { display: inline-flex; align-items: center; justify-content: center; padding: 14px 26px; border-radius: 999px; font-weight: 600; font-size: 16px; transition: transform .2s, background .2s, color .2s; }
.btn:hover { transform: translateY(-2px); }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.ghost { border: 1px solid var(--line); color: var(--text); }
.btn.ghost:hover { border-color: var(--text); }

/* HERO: full-bleed image, big centered name */
.hero {
  min-height: 100vh; min-height: 100svh;
  position: relative; display: flex; align-items: center; justify-content: center;
  text-align: center; overflow: hidden;
  padding-top: 100px; padding-bottom: 80px;
}
.hero-bg {
  position: absolute; inset: 0; z-index: -2;
  background: url("https://images.unsplash.com/photo-1619951007086-ab6ef9affbf1?auto=format&fit=crop&w=2000&q=70") center / cover no-repeat;
  filter: grayscale(1) contrast(1.05) brightness(.55);
  transform: scale(1.04);
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(11,13,16,.35) 0%, rgba(11,13,16,.55) 60%, var(--bg) 100%);
}
.hero-inner { max-width: var(--max); width: 100%; }
.hero h1 {
  font-family: var(--display);
  font-size: clamp(40px, 11vw, 150px);
  line-height: .9; letter-spacing: -.05em; margin: 0 0 26px;
}
.hero h1 .dot { color: var(--accent); }
.hero-role { font-size: clamp(13px, 1.6vw, 17px); text-transform: uppercase; letter-spacing: .22em; font-weight: 600; color: #e3e7ec; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 40px; justify-content: center; }
.hero .btn.ghost { border-color: rgba(255,255,255,.35); background: rgba(11,13,16,.35); }
.scroll-cue { position: absolute; bottom: 28px; left: 50%; transform: translateX(-50%); font-size: 26px; color: #cfd5dc; animation: bob 2s ease-in-out infinite; }
@keyframes bob { 50% { transform: translate(-50%, 8px); } }

/* ABOUT */
.about-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 56px; }
.about-text p { color: var(--muted); margin-bottom: 18px; }
.about-text .lead { font-family: var(--display); font-size: clamp(26px, 3vw, 36px); line-height: 1.2; color: var(--text); letter-spacing: -.02em; margin-bottom: 26px; }
.creds { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-content: start; }
.creds .cred { grid-column: 1 / -1; }
.stat-card { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.stat-card strong { display: block; font-family: var(--display); font-size: clamp(32px, 3.4vw, 44px); line-height: 1; letter-spacing: -.04em; color: var(--accent); }
.stat-card span { display: block; color: var(--muted); font-size: 14px; margin-top: 8px; line-height: 1.4; }
.about-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.cred { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.cred span { display: block; font-size: 13px; text-transform: uppercase; letter-spacing: .12em; color: var(--accent); margin-bottom: 6px; }
.cred strong { font-family: var(--display); font-size: 20px; display: block; }
.cred small { color: var(--muted); font-size: 14px; }

.skills { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 64px; }
.skill-group h3 { font-family: var(--display); font-size: 18px; margin-bottom: 14px; }
.skill-group ul { display: flex; flex-wrap: wrap; gap: 8px; }
.skill-group li { font-size: 14px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); }

/* TIMELINE */
.timeline { list-style: none; }
.job { display: grid; grid-template-columns: 180px 1fr; gap: 32px; padding: 34px 0; border-bottom: 1px solid var(--line); }
.job:last-child { border-bottom: 0; }
.job-when { font-family: var(--display); font-size: 20px; color: var(--accent); }
.job h3 { font-family: var(--display); font-size: clamp(22px, 2.4vw, 28px); line-height: 1.2; letter-spacing: -.02em; }
.company { color: var(--text); font-weight: 600; margin: 6px 0 14px; opacity: .8; }
.job-body > p:not(.company) { color: var(--muted); }
.job ul li { color: var(--muted); padding-left: 22px; position: relative; margin-bottom: 8px; }
.job ul li::before { content: ""; position: absolute; left: 0; top: .72em; width: 10px; height: 2px; background: var(--accent); }

/* CASE STUDIES */
.case { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 20px; overflow: hidden; }
.case-summary { padding: clamp(22px, 3vw, 36px); }
.case-meta { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.years { color: var(--muted); font-size: 14px; }
.case h3 { font-family: var(--display); font-size: clamp(26px, 3.2vw, 40px); line-height: 1.1; letter-spacing: -.03em; margin-bottom: 24px; }
.case-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.case-metrics div { background: var(--bg-2); padding: 18px; }
.case-metrics strong { display: block; font-family: var(--display); font-size: clamp(28px, 3.4vw, 44px); line-height: 1; letter-spacing: -.04em; }
.case-metrics span { display: block; color: var(--muted); font-size: 14px; margin-top: 8px; line-height: 1.4; }
.case details { border-top: 1px solid var(--line); }
.case summary { cursor: pointer; list-style: none; padding: 18px clamp(22px, 3vw, 36px); font-weight: 600; color: var(--accent); display: flex; justify-content: space-between; align-items: center; }
.case summary::-webkit-details-marker { display: none; }
.case summary::after { content: "+"; font-size: 24px; line-height: 1; transition: transform .25s; }
.case details[open] summary::after { transform: rotate(45deg); }
.case summary:hover { background: var(--bg-2); }
.case-body { padding: 4px clamp(22px, 3vw, 36px) 32px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px 40px; }
.case-block h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .14em; color: var(--accent); margin-bottom: 8px; }
.case-block p, .case-block li { color: var(--muted); font-size: 16px; }
.case-block ul li { padding-left: 20px; position: relative; margin-bottom: 8px; }
.case-block ul li::before { content: ""; position: absolute; left: 0; top: .72em; width: 10px; height: 2px; background: var(--accent); }
.case-block.lesson { grid-column: 1 / -1; border-left: 3px solid var(--accent); padding-left: 18px; }
.case-block.lesson p { color: var(--text); font-family: var(--display); font-size: 22px; line-height: 1.3; }
.sub-head { font-family: var(--display); font-size: 26px; margin: 56px 0 20px; letter-spacing: -.02em; }

/* PROJECTS */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.chip { font: inherit; font-size: 15px; background: transparent; color: var(--muted); border: 1px solid var(--line); padding: 9px 18px; border-radius: 999px; cursor: pointer; transition: all .2s; }
.chip:hover { color: var(--text); border-color: var(--text); }
.chip.active { background: var(--text); color: var(--bg); border-color: var(--text); }

.projects { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.project {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; display: flex; flex-direction: column;
  transition: transform .25s, border-color .25s;
}
.project:hover { transform: translateY(-4px); border-color: #3a414c; }
.project.hide { display: none; }
.project.featured { background: linear-gradient(160deg, #1d2410, var(--card) 60%); border-color: #3b4a17; }
.p-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 18px; gap: 12px; }
.tag { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--accent); border: 1px solid #3b4a17; padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.big { font-family: var(--display); font-size: 40px; line-height: 1; letter-spacing: -.04em; }
.project h4 { font-family: var(--display); font-size: 20px; line-height: 1.2; margin: 14px 0 8px; }
.project h3 { font-family: var(--display); font-size: 22px; line-height: 1.2; margin-bottom: 12px; letter-spacing: -.01em; }
.project p { color: var(--muted); font-size: 15px; }
.project .tag { align-self: flex-start; }
.p-facts { margin-top: auto; display: flex; flex-wrap: wrap; gap: 6px; }
.p-facts li { font-size: 13px; background: var(--bg-2); border: 1px solid var(--line); padding: 5px 10px; border-radius: 8px; }

/* ACTIVITIES */
.activities { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.activity { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 3 / 4; background: var(--card); }
.activity img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; filter: saturate(.9); }
.activity:hover img { transform: scale(1.06); }
.activity figcaption {
  position: absolute; inset: auto 0 0 0; padding: 26px;
  background: linear-gradient(transparent, rgba(0,0,0,.85));
}
.act-num { font-family: var(--display); color: var(--accent); font-size: 15px; }
.activity h3 { font-family: var(--display); font-size: clamp(32px, 3.4vw, 44px); line-height: 1; letter-spacing: -.03em; margin: 4px 0 6px; }
.activity p { color: #d4d9df; font-size: 15px; }

/* CONTACT */
.contact { max-width: var(--max); margin: 120px auto 0; text-align: center; padding-top: 90px; padding-bottom: 90px; border-top: 1px solid var(--line); }
.contact h2 { font-family: var(--display); font-size: clamp(40px, 7vw, 96px); line-height: .95; letter-spacing: -.045em; margin: 18px auto 22px; max-width: 900px; }
.contact p { color: var(--muted); max-width: 560px; margin: 0 auto; }
.contact-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 36px; }

.footer { border-top: 1px solid var(--line); padding: 28px clamp(16px, 4vw, 48px); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; color: var(--muted); font-size: 14px; }

/* REVEAL */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* RESPONSIVE */
@media (max-width: 1000px) {
  .projects { grid-template-columns: repeat(2, 1fr); }
  .skills { grid-template-columns: repeat(2, 1fr); }
  .about-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .menu-btn { display: block; }
  .links {
    position: fixed; inset: 68px 0 auto 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px 16px 20px; transform: translateY(-120%); transition: transform .35s ease;
  }
  .links.open { transform: none; }
  .links a { padding: 14px 0; width: 100%; font-size: 18px; border-bottom: 1px solid var(--line); }
  .links .nav-cta { margin-top: 16px; text-align: center; border: 0; }
  .about-grid { grid-template-columns: 1fr; gap: 32px; }
  .case-body { grid-template-columns: 1fr; }
  .case-metrics { grid-template-columns: 1fr; }
  .skills { grid-template-columns: 1fr; gap: 28px; }
  .job { grid-template-columns: 1fr; gap: 8px; }
  .projects { grid-template-columns: 1fr; }
  .activities { grid-template-columns: 1fr; }
  .activity { aspect-ratio: 4 / 3; }
  .section { padding-top: 90px; }
  .stat { padding: 24px 18px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
