:root {
  color-scheme: dark;
  --ink: #090d14;
  --ink-2: #0f1620;
  --panel: #141d29;
  --paper: #f2efe7;
  --muted: #a9b2bd;
  --line: rgba(242, 239, 231, 0.14);
  --line-strong: rgba(242, 239, 231, 0.28);
  --acid: #b8ff6a;
  --cyan: #60d8ff;
  --coral: #ff8b6b;
  --max: 1180px;
  --sans: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 85% 5%, rgba(96, 216, 255, 0.08), transparent 32rem),
    var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.skip-link {
  position: fixed;
  left: 1rem;
  top: -5rem;
  z-index: 100;
  background: var(--acid);
  color: var(--ink);
  padding: 0.7rem 1rem;
  font-weight: 700;
}

.skip-link:focus { top: 1rem; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  max-width: calc(var(--max) + 3rem);
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(9, 13, 20, 0.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--paper);
  text-decoration: none;
  font-weight: 720;
  letter-spacing: -0.02em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.25rem;
  aspect-ratio: 1;
  border: 1px solid var(--acid);
  color: var(--acid);
  font: 700 0.72rem/1 var(--mono);
}

nav { display: flex; align-items: center; gap: 1.75rem; }
nav a { color: var(--muted); text-decoration: none; font-size: 0.9rem; }
nav a:hover, nav a:focus-visible { color: var(--paper); }
.nav-cta { color: var(--acid); }

.hero,
.section,
.statement,
.proof-strip,
.contact,
.site-footer {
  width: min(var(--max), calc(100% - 3rem));
  margin-inline: auto;
}

.hero {
  min-height: calc(100vh - 75px);
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: center;
  padding: clamp(4rem, 9vw, 8rem) 0;
}

.eyebrow {
  margin: 0 0 1.2rem;
  color: var(--acid);
  font: 700 0.74rem/1.2 var(--mono);
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.status-dot {
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  margin-right: 0.5rem;
  border-radius: 50%;
  background: var(--acid);
  box-shadow: 0 0 1rem rgba(184, 255, 106, 0.75);
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  margin-bottom: 1.8rem;
  font-size: clamp(3.5rem, 7.4vw, 6.9rem);
  line-height: 0.9;
  letter-spacing: -0.075em;
  font-weight: 760;
}

h1 em {
  color: var(--acid);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
}

.hero-lede {
  max-width: 42rem;
  color: #c7ced5;
  font-size: clamp(1.08rem, 1.8vw, 1.35rem);
  line-height: 1.55;
}

.hero-actions,
.project-links,
.contact-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.hero-actions { margin: 2rem 0 2.5rem; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  min-height: 3rem;
  padding: 0.76rem 1.05rem;
  border: 1px solid var(--line-strong);
  text-decoration: none;
  font-weight: 700;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.button:hover,
.button:focus-visible { transform: translateY(-2px); border-color: var(--acid); }
.button-primary { background: var(--acid); color: var(--ink); border-color: var(--acid); }
.button-quiet { color: var(--paper); }
.button-light { background: var(--paper); color: var(--ink); border-color: var(--paper); }

.signal-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.signal-list li {
  padding: 0.42rem 0.65rem;
  color: var(--muted);
  border: 1px solid var(--line);
  font: 0.68rem/1 var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.hero-system {
  position: relative;
  overflow: hidden;
  background: linear-gradient(150deg, rgba(20, 29, 41, 0.96), rgba(10, 15, 22, 0.96));
  border: 1px solid var(--line-strong);
  box-shadow: 0 2rem 6rem rgba(0, 0, 0, 0.36);
}

.hero-system::after {
  content: "";
  position: absolute;
  inset: auto -10% -25% 25%;
  height: 45%;
  background: var(--cyan);
  filter: blur(100px);
  opacity: 0.08;
  pointer-events: none;
}

.system-topline {
  display: flex;
  justify-content: space-between;
  padding: 1rem 1.1rem;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font: 0.66rem/1 var(--mono);
  letter-spacing: 0.09em;
}

.live-label { color: var(--acid); }
.network-map { display: block; width: 100%; height: auto; }
.map-grid path { stroke: rgba(255, 255, 255, 0.045); stroke-width: 1; }
.map-lines path { fill: none; stroke: url(#path-gradient); stroke-width: 1.5; opacity: 0.62; }
.node circle { fill: var(--ink-2); stroke: var(--cyan); stroke-width: 1.5; }
.node text { fill: var(--paper); font: 700 9px var(--mono); letter-spacing: 0.05em; }
.node-b circle, .node-a circle { stroke: var(--acid); }
.node .pulse { fill: none; opacity: 0.26; animation: pulse-ring 2.8s ease-out infinite; }
.packet { fill: var(--acid); filter: drop-shadow(0 0 6px var(--acid)); }

@keyframes pulse-ring {
  0% { transform: scale(0.78); opacity: 0.45; }
  80%, 100% { transform: scale(1.22); opacity: 0; }
}

.system-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.system-steps li { padding: 1rem; border-right: 1px solid var(--line); }
.system-steps li:last-child { border-right: 0; }
.system-steps span, .system-steps small { display: block; color: var(--muted); font: 0.62rem/1.4 var(--mono); }
.system-steps strong { display: block; margin: 0.22rem 0; font-size: 0.88rem; }

.proof-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: -1px;
  padding: 0;
  border: 1px solid var(--line-strong);
  background: var(--ink-2);
}

.proof-strip div { min-height: 10rem; padding: 1.5rem; border-right: 1px solid var(--line); }
.proof-strip div:last-child { border-right: 0; }
.proof-strip dt { color: var(--acid); font: 700 clamp(2rem, 4vw, 3.6rem)/1 var(--mono); letter-spacing: -0.08em; }
.proof-strip dd { max-width: 12rem; margin: 1rem 0 0; color: var(--muted); font-size: 0.86rem; line-height: 1.4; }

.statement {
  padding: clamp(3rem, 6vw, 5rem) 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.statement p {
  max-width: 58rem;
  margin: 0;
  font-size: clamp(1.65rem, 3.5vw, 3.2rem);
  line-height: 1.2;
  letter-spacing: -0.045em;
}

.statement strong { color: var(--acid); font-family: Georgia, "Times New Roman", serif; font-weight: 400; }

.section { padding: clamp(5rem, 10vw, 9rem) 0; }
.section + .section { border-top: 1px solid var(--line); }

.section-heading { max-width: 48rem; margin-bottom: 3rem; }
.section-heading h2, .research-main h2, .contact h2 {
  margin-bottom: 1.25rem;
  font-size: clamp(2.3rem, 5vw, 4.7rem);
  line-height: 0.98;
  letter-spacing: -0.065em;
}
.section-heading > p:last-child, .split-heading > p { color: var(--muted); font-size: 1.08rem; }

.split-heading {
  max-width: none;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: end;
}
.split-heading > p { max-width: 32rem; margin-bottom: 0.4rem; }

.expertise-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.expertise-card {
  min-height: 20rem;
  padding: clamp(1.5rem, 4vw, 3rem);
  background: var(--ink);
  transition: background 180ms ease;
}
.expertise-card:hover { background: var(--ink-2); }
.expertise-card.featured { background: var(--paper); color: var(--ink); }
.expertise-card h3 { max-width: 20rem; margin: 2.5rem 0 1rem; font-size: clamp(1.5rem, 2.5vw, 2.4rem); line-height: 1.05; letter-spacing: -0.045em; }
.expertise-card p { max-width: 32rem; color: var(--muted); }
.expertise-card.featured p { color: #39434d; }
.card-number { color: var(--cyan); font: 0.72rem/1 var(--mono); }
.featured .card-number { color: #49661f; }
.expertise-card ul { margin: 1.6rem 0 0; padding: 0; list-style: none; }
.expertise-card li { padding: 0.38rem 0; border-top: 1px solid rgba(9, 13, 20, 0.14); font: 0.72rem/1.4 var(--mono); text-transform: uppercase; }

.research {
  display: grid;
  grid-template-columns: 0.32fr 1fr;
  gap: clamp(2rem, 8vw, 8rem);
}
.research-label { display: flex; flex-direction: column; justify-content: space-between; }
.research-index { color: var(--line-strong); font: clamp(2.5rem, 6vw, 6rem)/1 var(--mono); }
.research-main { max-width: 50rem; }
.research-lede { max-width: 46rem; color: var(--muted); font-size: clamp(1.25rem, 2.4vw, 1.8rem); line-height: 1.45; }
.research-topics { margin-top: 3rem; }
.research-topics article { display: grid; grid-template-columns: 0.55fr 1fr; gap: 2rem; padding: 1.3rem 0; border-top: 1px solid var(--line); }
.research-topics h3 { font-size: 1rem; }
.research-topics p { margin: 0; color: var(--muted); }

.career-timeline { border-top: 1px solid var(--line-strong); }
.career-timeline article {
  display: grid;
  grid-template-columns: 0.26fr 0.8fr 1.2fr;
  gap: clamp(1.5rem, 4vw, 4rem);
  padding: 2rem 0;
  border-bottom: 1px solid var(--line);
}
.career-period { margin: 0; color: var(--acid); font: 0.7rem/1.5 var(--mono); letter-spacing: 0.05em; }
.career-role p { margin-bottom: 0.4rem; color: var(--cyan); font: 0.68rem/1.4 var(--mono); text-transform: uppercase; letter-spacing: 0.05em; }
.career-role h3 { margin: 0; font-size: clamp(1.15rem, 2vw, 1.55rem); line-height: 1.15; letter-spacing: -0.025em; }
.career-impact { max-width: 42rem; margin: 0; color: var(--muted); font-size: 0.95rem; }
.credential-bar { display: grid; grid-template-columns: 0.42fr 1fr; gap: 2rem; padding: 2rem 0; border-bottom: 1px solid var(--line); }
.credential-bar .eyebrow { margin: 0; }
.credential-bar ul { display: flex; flex-wrap: wrap; gap: 0.55rem; margin: 0; padding: 0; list-style: none; }
.credential-bar li { padding: 0.45rem 0.65rem; border: 1px solid var(--line); color: var(--muted); font: 0.67rem/1.3 var(--mono); text-transform: uppercase; }
.resume-note { margin: 2rem 0 0; color: var(--muted); }
.resume-note a { color: var(--acid); text-decoration: none; }

.personal-work { padding-block: clamp(3.5rem, 7vw, 6rem); }
.personal-project {
  display: grid;
  grid-template-columns: 0.55fr 1.25fr auto;
  gap: clamp(1.5rem, 5vw, 5rem);
  align-items: center;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  border: 1px solid var(--line-strong);
  background: var(--ink-2);
}
.personal-project-label .eyebrow { margin-bottom: 0.65rem; }
.personal-project-label span { color: var(--muted); font: 0.66rem/1.4 var(--mono); }
.personal-project-copy h2 { margin-bottom: 0.65rem; font-size: clamp(1.7rem, 3vw, 2.8rem); letter-spacing: -0.05em; }
.personal-project-copy p { max-width: 44rem; margin-bottom: 0; color: var(--muted); }
.project-arrow { display: grid; place-items: center; width: 3.5rem; aspect-ratio: 1; border: 1px solid var(--acid); color: var(--acid); text-decoration: none; font-size: 1.4rem; transition: background 180ms ease, color 180ms ease, transform 180ms ease; }
.project-arrow:hover, .project-arrow:focus-visible { background: var(--acid); color: var(--ink); transform: translateY(-2px); }

.contact {
  padding: clamp(4rem, 9vw, 8rem);
  background: var(--coral);
  color: var(--ink);
}
.contact .eyebrow { color: var(--ink); }
.contact h2 { max-width: 58rem; }
.contact-actions { margin-top: 3rem; }
.contact-actions > a:not(.button) { font-weight: 700; text-underline-offset: 0.3em; }

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 2rem 0;
  color: var(--muted);
  font: 0.68rem/1.5 var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.site-footer a { color: var(--paper); }

:focus-visible { outline: 2px solid var(--cyan); outline-offset: 4px; }

@media (max-width: 900px) {
  nav a:not(.nav-cta) { display: none; }
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-system { max-width: 40rem; }
  .research { grid-template-columns: 1fr; }
  .research-label { flex-direction: row; }
  .proof-strip { grid-template-columns: repeat(2, 1fr); }
  .proof-strip div:nth-child(2) { border-right: 0; }
  .proof-strip div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .career-timeline article { grid-template-columns: 0.3fr 1fr; }
  .career-impact { grid-column: 2; }
}

@media (max-width: 640px) {
  .site-header { padding-inline: 1rem; }
  .hero, .section, .statement, .proof-strip, .contact, .site-footer { width: min(100% - 2rem, var(--max)); }
  .hero { padding-top: 3.5rem; }
  h1 { font-size: clamp(3.25rem, 16vw, 5.2rem); }
  .system-steps { grid-template-columns: 1fr; }
  .system-steps li { border-right: 0; border-bottom: 1px solid var(--line); }
  .system-steps li:last-child { border-bottom: 0; }
  .split-heading { grid-template-columns: 1fr; gap: 1rem; }
  .expertise-grid { grid-template-columns: 1fr; }
  .expertise-card { min-height: auto; }
  .research-topics article { grid-template-columns: 1fr; gap: 0.25rem; }
  .personal-project { grid-template-columns: 1fr auto; }
  .personal-project-label { grid-column: 1 / -1; }
  .proof-strip { grid-template-columns: 1fr 1fr; }
  .proof-strip div { min-height: 8.5rem; padding: 1.2rem; }
  .proof-strip dd { font-size: 0.78rem; }
  .career-timeline article { grid-template-columns: 1fr; gap: 0.8rem; }
  .career-impact { grid-column: 1; }
  .credential-bar { grid-template-columns: 1fr; }
  .contact { padding-inline: 1.5rem; }
  .contact-actions { align-items: stretch; flex-direction: column; }
  .site-footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
