/* ---------- tokens ---------- */
:root {
  --bg: #fbfbfd;
  --fg: #1d1d1f;
  --muted: #86868b;
  --hairline: #d2d2d7;
  --surface: #ffffff;
  --surface-2: #f5f5f7;
  --accent: #0066ff;
  --accent-ink: #ffffff;
  --max: 1200px;
  --gutter: clamp(20px, 5vw, 64px);
  --section-y: clamp(96px, 14vw, 180px);
  --radius: 18px;
  --font-sans: "Geist", -apple-system, BlinkMacSystemFont, "SF Pro Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(.22,.61,.36,1);
}

[data-theme="dark"] {
  --bg: #000000;
  --fg: #f5f5f7;
  --muted: #86868b;
  --hairline: #2a2a2c;
  --surface: #111113;
  --surface-2: #1a1a1c;
  --accent-ink: #ffffff;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  font-weight: 400;
  background: var(--bg);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "ss01", "ss02", "cv11";
  letter-spacing: -0.011em;
  line-height: 1.5;
  transition: background .4s var(--ease), color .4s var(--ease);
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

/* ---------- layout ---------- */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

section {
  padding: var(--section-y) 0;
  position: relative;
}

.hairline {
  border: 0;
  border-top: 1px solid var(--hairline);
  margin: 0;
}

/* ---------- nav ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: 52px;
  display: flex;
  align-items: center;
  z-index: 100;
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  background: color-mix(in oklab, var(--bg) 72%, transparent);
  border-bottom: 1px solid color-mix(in oklab, var(--hairline) 60%, transparent);
  transition: background .3s var(--ease);
}
.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.nav-mark {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.nav-mark .dot {
  display: inline-block;
  width: 7px; height: 7px;
  background: var(--accent);
  border-radius: 50%;
  margin-right: 10px;
  vertical-align: 1px;
}
.nav-links {
  display: flex;
  gap: 28px;
  font-size: 12.5px;
  color: var(--muted);
}
.nav-links a { transition: color .2s var(--ease); }
.nav-links a:hover { color: var(--fg); }

.nav-cta-group {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  padding: 7px 12px;
  border-radius: 980px;
  color: var(--fg);
  border: 1px solid var(--hairline);
  transition: background .2s var(--ease), border-color .2s var(--ease);
}
.nav-ghost:hover {
  background: var(--surface-2);
  border-color: color-mix(in oklab, var(--fg) 18%, var(--hairline));
}
.nav-ghost svg { opacity: 0.85; }
.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  padding: 7px 13px;
  border-radius: 980px;
  background: var(--fg);
  color: var(--bg);
  font-weight: 500;
  transition: transform .2s var(--ease), opacity .2s var(--ease);
}
.nav-cta:hover { transform: scale(1.03); }
.nav-cta svg { stroke: var(--bg); }

@media (max-width: 820px) {
  .nav-links { display: none; }
  .nav-ghost span { display: none; }
  .nav-ghost { padding: 7px 9px; }
}

/* ---------- hero ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 140px 0 80px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: clamp(48px, 8vw, 120px);
  align-items: center;
}
.hero-text { min-width: 0; }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 56px; }
}

.hero-portrait {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
  justify-self: end;
  width: 100%;
  max-width: 380px;
  margin-right: clamp(-32px, -3vw, 0px);
  transform: translateX(clamp(0px, 2vw, 32px));
}
@media (max-width: 900px) {
  .hero-portrait { justify-self: start; max-width: 320px; margin-right: 0; transform: none; }
}
.portrait-frame {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 22px;
  background: var(--surface-2);
  box-shadow:
    0 1px 0 0 color-mix(in oklab, var(--fg) 8%, transparent) inset,
    0 30px 60px -30px color-mix(in oklab, var(--fg) 25%, transparent),
    0 2px 8px -2px color-mix(in oklab, var(--fg) 10%, transparent);
}
.portrait-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 1.2s var(--ease);
}
.portrait-frame:hover img { transform: scale(1.03); }

/* subtle gradient veil at bottom for legibility of caption underneath */
.portrait-frame::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 30%;
  background: linear-gradient(to top, color-mix(in oklab, var(--fg) 18%, transparent), transparent);
  pointer-events: none;
}

.portrait-caption {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.portrait-caption .dot {
  width: 5px; height: 5px;
  background: var(--muted);
  border-radius: 50%;
}
.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.live-dot {
  width: 7px; height: 7px;
  background: #34c759;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(52, 199, 89, 0.5);
  animation: pulse 2s var(--ease) infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(52, 199, 89, 0.5); }
  50% { box-shadow: 0 0 0 6px rgba(52, 199, 89, 0); }
}

.hero-title {
  font-size: clamp(48px, 9vw, 120px);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 0.92;
  margin: 0;
}
.hero-title .accent { color: var(--accent); }

.hero-sub {
  margin-top: 32px;
  max-width: 720px;
  font-size: clamp(20px, 2.2vw, 28px);
  font-weight: 400;
  color: var(--fg);
  line-height: 1.32;
  letter-spacing: -0.018em;
}
.hero-sub .muted { color: var(--muted); }

.hero-meta {
  margin-top: 56px;
  display: flex;
  flex-wrap: wrap;
  gap: 40px 56px;
  font-size: 13px;
  color: var(--muted);
}
.hero-meta b {
  display: block;
  color: var(--fg);
  font-weight: 500;
  margin-top: 6px;
  font-size: 15px;
  letter-spacing: -0.01em;
}

.scroll-cue {
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-transform: uppercase;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
}
.scroll-cue .line {
  width: 1px; height: 36px;
  background: linear-gradient(to bottom, transparent, var(--hairline));
  animation: drop 2.4s var(--ease) infinite;
}
@keyframes drop {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* ---------- pitch ---------- */
.pitch {
  text-align: left;
}
.pitch-text {
  font-size: clamp(32px, 5.2vw, 68px);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.08;
  max-width: 1000px;
}
.pitch-text .dim { color: var(--muted); }

/* ---------- section heads ---------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 18px; height: 1px;
  background: var(--muted);
}
.section-title {
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1;
  margin: 0 0 24px;
}
.section-lede {
  font-size: clamp(17px, 1.6vw, 21px);
  color: var(--muted);
  max-width: 640px;
  line-height: 1.5;
}

/* ---------- metrics ---------- */
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: 80px;
  background: var(--hairline);
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}
.metric {
  background: var(--bg);
  padding: 56px 28px 48px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: background .3s var(--ease);
}
.metric:hover { background: var(--surface-2); }
.metric-num {
  font-size: clamp(56px, 7vw, 96px);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 0.95;
  font-feature-settings: "tnum" 1, "ss01" 1;
}
.metric-num .unit {
  font-size: 0.5em;
  color: var(--muted);
  font-weight: 500;
  margin-left: 2px;
}
.metric-label {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.45;
  letter-spacing: -0.005em;
  max-width: 220px;
}
.metric-tag {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  margin-top: auto;
}
@media (max-width: 900px) {
  .metrics { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
  .metrics { grid-template-columns: 1fr; }
  .metric { padding: 40px 24px; }
}

/* ---------- experience ---------- */
.role {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 64px;
  padding: 64px 0;
  border-top: 1px solid var(--hairline);
}
.role:last-child { border-bottom: 1px solid var(--hairline); }
.role-side {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 6px;
}
.role-side .when { letter-spacing: 0.02em; }
.role-side .where { color: var(--fg); }
.role-co {
  font-size: clamp(28px, 3.2vw, 40px);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.05;
  margin: 0 0 6px;
}
.role-title {
  font-size: 16px;
  color: var(--muted);
  margin: 0 0 32px;
  letter-spacing: -0.005em;
}
.role-group {
  margin-top: 36px;
}
.role-group:first-of-type { margin-top: 0; }
.role-group-h {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 16px;
}
.role-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.role-list li {
  font-size: 16px;
  line-height: 1.55;
  color: var(--fg);
  letter-spacing: -0.005em;
  padding-left: 22px;
  position: relative;
}
.role-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 11px;
  width: 10px; height: 1px;
  background: var(--muted);
}
.role-list li b {
  font-weight: 600;
  color: var(--fg);
}
.role-list li .chip {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11.5px;
  padding: 2px 8px;
  background: var(--surface-2);
  border: 1px solid var(--hairline);
  border-radius: 6px;
  color: var(--fg);
  letter-spacing: -0.005em;
  margin: 0 2px;
}

@media (max-width: 820px) {
  .role { grid-template-columns: 1fr; gap: 24px; }
}

/* ---------- project spotlight ---------- */
.spotlight {
  background: var(--fg);
  color: var(--bg);
  border-radius: 28px;
  padding: clamp(48px, 6vw, 96px);
  margin-top: 64px;
  position: relative;
  overflow: hidden;
}
[data-theme="dark"] .spotlight {
  background: var(--surface);
  color: var(--fg);
  border: 1px solid var(--hairline);
}
.spotlight-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 80px;
  align-items: start;
}
.spot-eyebrow {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: color-mix(in oklab, var(--bg) 60%, transparent);
  margin-bottom: 24px;
  display: flex;
  gap: 14px;
  align-items: center;
}
[data-theme="dark"] .spot-eyebrow { color: var(--muted); }
.spot-eyebrow .live {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #34c759;
  animation: pulse 2s var(--ease) infinite;
}
.spot-title {
  font-size: clamp(40px, 5.5vw, 72px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1;
  margin: 0 0 24px;
}
.spot-lede {
  font-size: clamp(18px, 1.7vw, 22px);
  line-height: 1.45;
  color: color-mix(in oklab, var(--bg) 75%, transparent);
  letter-spacing: -0.015em;
}
[data-theme="dark"] .spot-lede { color: var(--muted); }

.spot-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 32px;
  font-size: 15px;
  color: var(--accent);
  font-weight: 500;
  transition: gap .2s var(--ease);
}
.spot-link:hover { gap: 14px; }
.spot-link .arr {
  display: inline-block;
  transition: transform .2s var(--ease);
}

.spot-stack {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.spot-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 24px;
  padding: 20px 0;
  border-top: 1px solid color-mix(in oklab, var(--bg) 18%, transparent);
  font-size: 14.5px;
  line-height: 1.5;
}
[data-theme="dark"] .spot-row { border-color: var(--hairline); }
.spot-row:last-child { border-bottom: 1px solid color-mix(in oklab, var(--bg) 18%, transparent); }
[data-theme="dark"] .spot-row:last-child { border-color: var(--hairline); }
.spot-row .k {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: color-mix(in oklab, var(--bg) 55%, transparent);
  padding-top: 3px;
}
[data-theme="dark"] .spot-row .k { color: var(--muted); }

@media (max-width: 880px) {
  .spotlight-grid { grid-template-columns: 1fr; gap: 48px; }
}

/* ---------- skills ---------- */
.skills {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  margin-top: 72px;
}
.skill-col h4 {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
}
.skill-col ul {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.skill-col li {
  font-size: 16px;
  letter-spacing: -0.005em;
  color: var(--fg);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
.skill-col li .lvl {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.04em;
}
@media (max-width: 820px) {
  .skills { grid-template-columns: 1fr; gap: 32px; }
}

/* ---------- education ---------- */
.edu {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--hairline);
  margin-top: 72px;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
}
.edu-card {
  background: var(--bg);
  padding: 56px 40px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.edu-card .when {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.02em;
}
.edu-card .deg {
  font-size: clamp(22px, 2.2vw, 28px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0;
}
.edu-card .school {
  font-size: 15px;
  color: var(--muted);
  margin: -8px 0 0;
}
.edu-card .school-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: -8px;
}
.edu-card .school-row .school {
  margin: 0;
}
.edu-card .edu-logo {
  height:50px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.um-logo {
  height:50px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}
.edu-card .gpa {
  margin-top: auto;
  padding-top: 18px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--fg);
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--hairline);
}
.edu-card .gpa span { color: var(--muted); }
@media (max-width: 760px) {
  .edu { grid-template-columns: 1fr; }
}

/* ---------- contact / footer ---------- */
.contact {
  text-align: center;
  padding: clamp(120px, 18vw, 220px) 0;
}
.contact h2 {
  font-size: clamp(48px, 9vw, 132px);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 0.95;
  margin: 0;
}
.contact .mail {
  color: var(--accent);
  text-decoration: none;
  position: relative;
  display: inline-block;
}
.contact .mail::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0.04em;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .4s var(--ease);
}
.contact .mail:hover::after { transform: scaleX(1); }
.contact-sub {
  margin-top: 36px;
  font-size: clamp(16px, 1.6vw, 19px);
  color: var(--muted);
  max-width: 580px;
  margin-left: auto;
  margin-right: auto;
}
.contact-links {
  margin-top: 56px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}
.contact-links a {
  font-size: 14px;
  padding: 12px 22px;
  border: 1px solid var(--hairline);
  border-radius: 980px;
  transition: background .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease);
}
.contact-links a:hover {
  background: var(--fg);
  color: var(--bg);
  border-color: var(--fg);
}

footer {
  border-top: 1px solid var(--hairline);
  padding: 32px 0;
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--muted);
  letter-spacing: 0.02em;
}
footer .wrap {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- reveal (immediate; iframe-safe) ---------- */
.reveal { opacity: 1; transform: none; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- selection ---------- */
::selection {
  background: var(--accent);
  color: var(--accent-ink);
}
