:root {
  color-scheme: light;
  --bg: #f3f1ea;
  --bg-elevated: rgba(255, 255, 255, 0.76);
  --surface: rgba(255, 255, 255, 0.82);
  --surface-strong: rgba(255, 255, 255, 0.95);
  --surface-border: rgba(35, 39, 47, 0.08);
  --text: #171b23;
  --text-muted: #5b6474;
  --heading: #0e1320;
  --accent: #0f6d67;
  --accent-strong: #0b4c48;
  --accent-soft: rgba(15, 109, 103, 0.12);
  --shadow: 0 24px 80px rgba(23, 27, 35, 0.08);
  --shadow-soft: 0 18px 42px rgba(23, 27, 35, 0.08);
  --radius-xl: 20px;
  --radius-lg: 14px;
  --radius-md: 10px;
  --radius-sm: 10px;
  --container: min(1180px, calc(100vw - 40px));
  --section-gap: clamp(4.5rem, 8vw, 7rem);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b1018;
  --bg-elevated: rgba(14, 20, 29, 0.76);
  --surface: rgba(14, 20, 29, 0.72);
  --surface-strong: rgba(18, 25, 36, 0.92);
  --surface-border: rgba(214, 225, 245, 0.08);
  --text: #edf2ff;
  --text-muted: #9aa6bc;
  --heading: #f7fbff;
  --accent: #74e7d9;
  --accent-strong: #a4fff3;
  --accent-soft: rgba(116, 231, 217, 0.12);
  --shadow: 0 28px 100px rgba(0, 0, 0, 0.36);
  --shadow-soft: 0 22px 48px rgba(0, 0, 0, 0.28);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(15, 109, 103, 0.16), transparent 32%),
    radial-gradient(circle at 85% 18%, rgba(255, 193, 113, 0.16), transparent 24%),
    linear-gradient(180deg, var(--bg), color-mix(in srgb, var(--bg) 86%, #ffffff 14%));
  transition:
    background-color 200ms ease,
    color 200ms ease,
    background 300ms ease;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    linear-gradient(transparent 0, rgba(255, 255, 255, 0.015) 100%),
    repeating-linear-gradient(
      90deg,
      transparent 0,
      transparent 54px,
      rgba(255, 255, 255, 0.025) 55px,
      transparent 56px
    );
  pointer-events: none;
  opacity: 0.6;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

img {
  max-width: 100%;
  display: block;
}

.site-shell {
  width: var(--container);
  margin: 0 auto;
  padding-bottom: 3rem;
}

.topbar {
  position: sticky;
  top: 18px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(100%, 1120px);
  margin: 24px auto 0;
  padding: 14px 18px;
  backdrop-filter: blur(22px);
  background: var(--bg-elevated);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-soft);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 68%, white 32%));
  color: #f9fffe;
  font-family: "Sora", sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.brand-text {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--heading);
}

.nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.nav a {
  padding: 0.8rem 1rem;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 600;
  transition:
    background-color 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.nav a:hover,
.nav a:focus-visible {
  background: var(--accent-soft);
  color: var(--heading);
  transform: translateY(-1px);
}

.theme-toggle {
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
}

.theme-toggle__track {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 6px;
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  border: 1px solid var(--surface-border);
}

.theme-toggle__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  padding: 0.65rem 0.8rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  transition:
    background-color 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

html[data-theme="light"] .theme-toggle__icon--sun,
html:not([data-theme]) .theme-toggle__icon--sun,
html[data-theme="dark"] .theme-toggle__icon--moon {
  background: var(--surface-strong);
  color: var(--heading);
  box-shadow: inset 0 0 0 1px var(--surface-border);
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.9fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
  padding: clamp(3rem, 7vw, 6rem) 0 clamp(2rem, 5vw, 4rem);
}

.hero::after {
  content: "";
  position: absolute;
  right: 4%;
  top: 8%;
  width: clamp(180px, 25vw, 280px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(15, 109, 103, 0.22), transparent 70%);
  filter: blur(6px);
  animation: float 8s ease-in-out infinite;
  z-index: -1;
}

.eyebrow {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero h1,
.section-heading h2,
.project-card h3,
.timeline-card h3,
.skill-card h3,
.education-card h3,
.hero-panel h2 {
  margin: 0;
  font-family: "Sora", sans-serif;
  color: var(--heading);
}

.hero h1 {
  font-size: clamp(3rem, 7vw, 5.7rem);
  line-height: 0.95;
  letter-spacing: -0.05em;
  max-width: 10ch;
}

.hero-title {
  margin: 1.5rem 0 1rem;
  max-width: 18ch;
  font-size: clamp(1.2rem, 2.35vw, 1.75rem);
  line-height: 1.3;
  color: color-mix(in srgb, var(--heading) 90%, var(--text-muted) 10%);
  font-weight: 600;
}

.hero-summary,
.section-copy,
.project-summary,
.timeline-points,
.education-meta,
.footer {
  color: var(--text-muted);
}

.hero-summary {
  max-width: 64ch;
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0.95rem 1.3rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background-color 180ms ease,
    color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.button--primary {
  color: #f7fffd;
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  box-shadow: 0 18px 30px rgba(15, 109, 103, 0.2);
}

.button--secondary {
  color: var(--heading);
  background: var(--surface-strong);
  border: 1px solid var(--surface-border);
}

.contact-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, max-content));
  gap: 0.85rem 1.4rem;
  padding: 0;
  margin: 2rem 0 0;
  list-style: none;
}

.contact-list a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0;
  color: var(--text-muted);
  font-weight: 600;
  transition: color 160ms ease;
}

.contact-list a:hover,
.contact-list a:focus-visible {
  color: var(--heading);
}

.surface {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, var(--surface), color-mix(in srgb, var(--surface) 88%, transparent));
  border: 1px solid var(--surface-border);
  box-shadow: var(--shadow);
}

.surface::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.18), transparent 45%);
  pointer-events: none;
}

.hero-panel__card {
  padding: clamp(1.5rem, 4vw, 2rem);
  border-radius: var(--radius-xl);
}

.panel-label,
.project-kicker,
.timeline-date {
  margin: 0;
  color: var(--text-muted);
  font-weight: 700;
}

.hero-panel h2 {
  margin-top: 0.75rem;
  font-size: clamp(1.3rem, 2.2vw, 2rem);
  line-height: 1.25;
}

.hero-panel h2 span {
  color: var(--accent);
}

.signal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.signal-grid article {
  padding: 1rem;
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--surface-strong) 82%, transparent);
  border: 1px solid var(--surface-border);
}

.signal-value {
  display: block;
  font-family: "Sora", sans-serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--heading);
}

.signal-label {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.section {
  padding-top: var(--section-gap);
}

.section--projects {
  position: relative;
}

.section--projects::before {
  content: "";
  position: absolute;
  inset: 12% 0 auto;
  height: 60%;
  background:
    radial-gradient(circle at 18% 20%, rgba(15, 109, 103, 0.16), transparent 32%),
    radial-gradient(circle at 82% 45%, rgba(255, 193, 113, 0.12), transparent 24%);
  z-index: -1;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 2rem;
  margin-bottom: 2rem;
}

.section-heading h2 {
  max-width: 12ch;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

.section-copy {
  max-width: 34ch;
  margin: 0 0 0 auto;
  line-height: 1.7;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1.25rem;
}

.project-card,
.timeline-card,
.skill-card,
.education-card {
  border-radius: var(--radius-xl);
}

.project-card {
  grid-column: span 4;
  padding: 1.5rem;
  min-height: 100%;
  transition:
    transform 220ms ease,
    box-shadow 220ms ease,
    border-color 220ms ease;
}

.project-card--featured {
  grid-column: span 8;
  padding: clamp(1.65rem, 3vw, 2rem);
}

.project-card:hover,
.timeline-card:hover,
.skill-card:hover,
.education-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 80px rgba(15, 109, 103, 0.12);
  border-color: color-mix(in srgb, var(--accent) 30%, var(--surface-border));
}

.project-card__header,
.timeline-card__top {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: start;
}

.project-kicker {
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.project-card h3 {
  margin-top: 0.65rem;
  font-size: 1.4rem;
  line-height: 1.22;
}

.project-card--featured h3 {
  font-size: clamp(1.6rem, 2.8vw, 2.5rem);
  max-width: 18ch;
}

.project-metric {
  margin: 0;
  padding: 0.75rem 0.95rem;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--heading);
  font-weight: 800;
  font-size: 0.85rem;
  text-align: right;
}

.project-summary {
  margin: 1rem 0 0;
  line-height: 1.7;
}

.project-points,
.timeline-points {
  margin: 1.15rem 0 0;
  padding-left: 1.15rem;
  line-height: 1.7;
}

.project-points li + li,
.timeline-points li + li {
  margin-top: 0.5rem;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.3rem;
}

.tag-row span,
.timeline-badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0.5rem 0.8rem;
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--surface-strong) 86%, transparent);
  border: 1px solid var(--surface-border);
  color: var(--heading);
  font-size: 0.84rem;
  font-weight: 700;
}

.timeline {
  position: relative;
  display: grid;
  gap: 1.1rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 20px;
  top: 12px;
  bottom: 12px;
  width: 1px;
  background: color-mix(in srgb, var(--accent) 22%, var(--surface-border));
}

.timeline-card {
  position: relative;
  margin-left: 2.75rem;
  padding: 1.4rem 1.45rem;
}

.timeline-card::before {
  content: "";
  position: absolute;
  top: 28px;
  left: -2.05rem;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 62%, white 38%));
  box-shadow: 0 0 0 7px color-mix(in srgb, var(--bg) 82%, transparent);
}

.timeline-card h3 {
  font-size: 1.25rem;
}

.timeline-date {
  margin-top: 0.4rem;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1rem;
}

.skill-card {
  grid-column: span 2;
  padding: 1.35rem;
}

.skill-card h3 {
  font-size: 1.05rem;
}

.skill-card .tag-row {
  margin-top: 1rem;
}

.education-card {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 2rem;
  padding: clamp(1.5rem, 4vw, 2rem);
}

.education-degree {
  margin: 0.7rem 0 0;
  color: var(--text-muted);
  font-weight: 600;
}

.education-meta {
  display: grid;
  gap: 0.5rem;
  line-height: 1.7;
}

.education-meta p {
  margin: 0;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 2rem 0 0;
  margin-top: var(--section-gap);
  border-top: 1px solid var(--surface-border);
  font-size: 0.95rem;
}

.footer a {
  color: var(--heading);
  font-weight: 700;
}

.js-ready .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 650ms ease,
    transform 650ms ease;
}

.js-ready .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes float {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }
  50% {
    transform: translate3d(0, -12px, 0);
  }
}

@media (max-width: 1040px) {
  .hero,
  .education-card,
  .section-heading {
    grid-template-columns: 1fr;
  }

  .section-heading {
    display: grid;
  }

  .section-copy {
    margin-left: 0;
  }

  .project-card--featured,
  .project-card {
    grid-column: span 6;
  }

  .skills-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .skill-card {
    grid-column: span 1;
  }
}

@media (max-width: 760px) {
  .site-shell {
    width: min(100vw - 24px, 100%);
  }

  .topbar {
    top: 12px;
    padding: 14px;
    border-radius: 14px;
    flex-wrap: wrap;
  }

  .brand {
    width: 100%;
    justify-content: space-between;
  }

  .nav {
    order: 3;
    width: 100%;
    justify-content: space-between;
  }

  .nav a {
    padding: 0.75rem 0.7rem;
    font-size: 0.88rem;
  }

  .hero h1 {
    max-width: 100%;
  }

  .hero-title,
  .hero-summary {
    max-width: 100%;
  }

  .contact-list {
    grid-template-columns: 1fr;
  }

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

  .project-card--featured,
  .project-card {
    grid-column: auto;
  }

  .project-card__header,
  .timeline-card__top,
  .footer {
    flex-direction: column;
    align-items: start;
  }

  .project-metric {
    text-align: left;
  }

  .timeline-card {
    margin-left: 2rem;
  }

  .timeline::before {
    left: 14px;
  }

  .timeline-card::before {
    left: -1.48rem;
  }

  .skills-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}



.project-card {
  display: flex;
  flex-direction: column;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: auto;
  padding-top: 1.35rem;
}

.link-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0.7rem 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--surface-border);
  background: color-mix(in srgb, var(--surface-strong) 88%, transparent);
  color: var(--heading);
  font-size: 0.88rem;
  font-weight: 700;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease;
}

.link-chip:hover,
.link-chip:focus-visible {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 34%, var(--surface-border));
}

.link-chip--primary {
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: #f7fffd;
  border-color: transparent;
}

.archive-grid {
  margin-top: 1.25rem;
}

.archive-card {
  padding: 1.5rem;
  border-radius: var(--radius-xl);
}

.archive-card h3 {
  margin-top: 0.65rem;
  font-size: 1.35rem;
}

.archive-card p {
  margin: 1rem 0 0;
  line-height: 1.7;
  color: var(--text-muted);
}

.project-page {
  padding-top: clamp(2.5rem, 6vw, 4.5rem);
}

.breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  color: var(--text-muted);
  font-weight: 700;
}

.breadcrumb:hover,
.breadcrumb:focus-visible {
  color: var(--heading);
}

.page-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: clamp(1.25rem, 4vw, 2.5rem);
  align-items: start;
}

.page-hero h1,
.detail-section__heading h2,
.split-callout h2,
.doc-panel h3,
.media-card h3,
.archive-card h3 {
  margin: 0;
  font-family: "Sora", sans-serif;
  color: var(--heading);
}

.page-hero h1 {
  font-size: clamp(2.5rem, 5vw, 4.6rem);
  line-height: 0.98;
  letter-spacing: -0.05em;
  max-width: 12ch;
}

.page-lead {
  margin: 1.35rem 0 1rem;
  max-width: 20ch;
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  line-height: 1.35;
  color: color-mix(in srgb, var(--heading) 90%, var(--text-muted) 10%);
  font-weight: 600;
}

.page-summary {
  margin: 0;
  max-width: 64ch;
  color: var(--text-muted);
  line-height: 1.8;
}

.page-panel {
  padding: 1.35rem;
  border-radius: var(--radius-xl);
}

.page-panel .detail-image {
  margin-top: 0;
}

.stat-list {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

.stat-list > div {
  padding: 1rem;
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--surface-strong) 82%, transparent);
  border: 1px solid var(--surface-border);
}

.screen-boot {
  padding: clamp(0.95rem, 2vw, 1.15rem);
  border-radius: var(--radius-xl);
  cursor: pointer;
}

.screen-boot:focus-visible {
  outline: 1px solid color-mix(in srgb, var(--accent) 44%, var(--surface-border));
  outline-offset: 3px;
}

.screen-boot--card {
  margin: 1.15rem 0 0.2rem;
  padding: 0.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid color-mix(in srgb, var(--accent) 14%, var(--surface-border));
  background: linear-gradient(180deg, color-mix(in srgb, var(--surface-strong) 90%, #101419 10%), color-mix(in srgb, var(--surface) 86%, #07090c 14%));
}

.screen-boot--card .screen-boot__frame {
  height: 13rem;
  aspect-ratio: auto;
  border-radius: var(--radius-md);
}

.project-card--featured .screen-boot--card .screen-boot__frame {
  height: 14rem;
}

.screen-boot--card .screen-boot__hud {
  padding: 0.8rem 0.85rem;
  font-size: 0.64rem;
}

.screen-boot__frame {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: calc(var(--radius-xl) - 4px);
  border: 1px solid color-mix(in srgb, var(--accent) 14%, var(--surface-border));
  background: linear-gradient(180deg, rgba(4, 6, 9, 0.96), rgba(9, 12, 17, 0.98));
  isolation: isolate;
}

.screen-boot__image,
.screen-boot__blank,
.screen-boot__static,
.screen-boot__scanlines,
.screen-boot__vignette,
.screen-boot__hud {
  position: absolute;
  inset: 0;
}

.screen-boot__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transform: scale(1.035);
  transition:
    opacity 280ms ease,
    transform 520ms ease;
}

.screen-boot__blank {
  background:
    radial-gradient(circle at center, rgba(148, 158, 170, 0.08), transparent 38%),
    linear-gradient(180deg, rgba(7, 10, 14, 0.94), rgba(2, 3, 5, 0.98));
  transition: opacity 180ms ease;
}

.screen-boot__static {
  opacity: 0;
  background:
    radial-gradient(circle at 20% 22%, rgba(255, 255, 255, 0.18), transparent 24%),
    radial-gradient(circle at 78% 64%, rgba(255, 255, 255, 0.14), transparent 20%),
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.1) 0,
      rgba(255, 255, 255, 0.1) 2px,
      transparent 2px,
      transparent 5px
    ),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.05) 0,
      rgba(255, 255, 255, 0.05) 2px,
      transparent 2px,
      transparent 6px
    );
  mix-blend-mode: screen;
  filter: contrast(1.2);
  transition: opacity 120ms ease;
}

.screen-boot__scanlines {
  background:
    linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.16)),
    repeating-linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.08) 0,
      rgba(255, 255, 255, 0.08) 1px,
      transparent 1px,
      transparent 4px
    );
  opacity: 0.22;
  pointer-events: none;
}

.screen-boot__vignette {
  background: radial-gradient(circle at center, transparent 54%, rgba(0, 0, 0, 0.48) 100%);
  pointer-events: none;
}

.screen-boot__hud {
  display: flex;
  align-items: end;
  justify-content: space-between;
  padding: 1rem 1.05rem;
  pointer-events: none;
  color: rgba(244, 247, 251, 0.8);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.screen-boot__prompt,
.screen-boot__status {
  position: relative;
  z-index: 1;
}

.screen-boot__status {
  display: inline-grid;
}

.screen-boot__status-idle,
.screen-boot__status-arming,
.screen-boot__status-live {
  grid-area: 1 / 1;
  transition:
    opacity 140ms ease,
    transform 140ms ease;
}

.screen-boot__status-arming,
.screen-boot__status-live {
  opacity: 0;
  transform: translateY(4px);
}

.screen-boot.is-arming .screen-boot__static {
  opacity: 0.92;
  animation: screen-static 180ms steps(3) infinite;
}

.screen-boot.is-arming .screen-boot__blank {
  opacity: 0.18;
}

.screen-boot.is-arming .screen-boot__status-idle,
.screen-boot.is-revealed .screen-boot__status-idle,
.screen-boot.is-revealed .screen-boot__status-arming {
  opacity: 0;
  transform: translateY(-4px);
}

.screen-boot.is-arming .screen-boot__status-arming,
.screen-boot.is-revealed .screen-boot__status-live {
  opacity: 1;
  transform: translateY(0);
}

.screen-boot.is-revealed .screen-boot__image {
  opacity: 1;
  transform: scale(1);
}

.screen-boot.is-revealed .screen-boot__blank,
.screen-boot.is-revealed .screen-boot__static {
  opacity: 0;
}

@keyframes screen-static {
  0% {
    transform: translate3d(0, 0, 0);
  }
  33% {
    transform: translate3d(0.75%, -0.5%, 0);
  }
  66% {
    transform: translate3d(-0.75%, 0.6%, 0);
  }
  100% {
    transform: translate3d(0, 0, 0);
  }
}

.detail-section {
  padding-top: clamp(3rem, 6vw, 4.5rem);
}

.detail-section__heading {
  display: grid;
  gap: 0.9rem;
  margin-bottom: 1.5rem;
}

.detail-section__heading h2,
.split-callout h2 {
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1.06;
  letter-spacing: -0.04em;
  max-width: 16ch;
}

.detail-section__heading p:last-child,
.split-callout p,
.doc-panel p,
.media-card p,
.detail-card p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.75;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1rem;
}

.detail-card,
.media-card {
  padding: 1.35rem;
  border-radius: var(--radius-xl);
}

.detail-card {
  grid-column: span 4;
}

.detail-card h3,
.media-card h3 {
  margin: 0 0 0.75rem;
  font-size: 1.15rem;
}

.split-callout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(1.2rem, 3vw, 2rem);
  align-items: center;
  padding: clamp(1.35rem, 4vw, 2rem);
  border-radius: var(--radius-xl);
}

.doc-panel {
  display: grid;
  gap: 0.85rem;
  padding: 1.2rem;
  border-radius: var(--radius-lg);
  background: color-mix(in srgb, var(--surface-strong) 84%, transparent);
  border: 1px solid var(--surface-border);
}

.surface-plain {
  box-shadow: none;
}

.detail-image,
.gallery-grid img,
.media-card video {
  display: block;
  width: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid var(--surface-border);
  background: #020508;
  box-shadow: var(--shadow-soft);
}

.media-grid,
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.media-card video {
  aspect-ratio: 16 / 10;
  object-fit: cover;
  margin-bottom: 1rem;
}

code {
  font-family: "Manrope", sans-serif;
  font-size: 0.92em;
  padding: 0.12rem 0.4rem;
  border-radius: 0.5rem;
  background: color-mix(in srgb, var(--surface-strong) 90%, transparent);
  border: 1px solid var(--surface-border);
}

@media (max-width: 1040px) {
  .page-hero,
  .split-callout {
    grid-template-columns: 1fr;
  }

  .detail-card {
    grid-column: span 6;
  }
}

@media (max-width: 760px) {
  .page-hero h1 {
    max-width: 100%;
  }

  .page-lead,
  .page-summary,
  .detail-section__heading h2,
  .split-callout h2 {
    max-width: 100%;
  }

  .detail-grid,
  .media-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .detail-card {
    grid-column: auto;
  }
}

:root {
  --parallax-x: 0;
  --parallax-y: 0;
  --parallax-scroll: 0;
  --grain-opacity: 0.2;
}

:root,
html[data-theme="light"] {
  --bg: #d8dbe0;
  --bg-elevated: rgba(227, 231, 236, 0.68);
  --surface: rgba(244, 247, 250, 0.78);
  --surface-strong: rgba(251, 253, 255, 0.92);
  --surface-border: rgba(70, 79, 91, 0.14);
  --text: #171c24;
  --text-muted: #5d6775;
  --heading: #0d1218;
  --accent: #9ea7b0;
  --accent-strong: #737c86;
  --accent-soft: rgba(158, 167, 176, 0.14);
  --shadow: 0 32px 90px rgba(18, 22, 28, 0.16);
  --shadow-soft: 0 20px 46px rgba(18, 22, 28, 0.12);
}

html[data-theme="dark"] {
  --bg: #07090c;
  --bg-elevated: rgba(13, 16, 20, 0.76);
  --surface: rgba(20, 24, 29, 0.76);
  --surface-strong: rgba(29, 34, 40, 0.92);
  --surface-border: rgba(177, 186, 196, 0.12);
  --text: #e5ebf2;
  --text-muted: #a2acb8;
  --heading: #f4f7fb;
  --accent: #aab2bb;
  --accent-strong: #848d97;
  --accent-soft: rgba(170, 178, 187, 0.14);
  --shadow: 0 36px 100px rgba(0, 0, 0, 0.52);
  --shadow-soft: 0 24px 56px rgba(0, 0, 0, 0.38);
  --grain-opacity: 0.15;
}

body {
  position: relative;
  isolation: isolate;
  overflow-x: hidden;
  background:
    radial-gradient(circle at calc(14% + (var(--parallax-x) * 1px)) calc(10% + (var(--parallax-y) * 1px)), rgba(163, 174, 188, 0.16), transparent 28%),
    radial-gradient(circle at calc(86% - (var(--parallax-x) * 0.8px)) calc(18% + (var(--parallax-y) * 0.4px)), rgba(108, 120, 136, 0.12), transparent 22%),
    linear-gradient(135deg, rgba(9, 11, 14, 0.96), rgba(27, 31, 37, 0.8) 38%, rgba(68, 76, 88, 0.24) 100%),
    linear-gradient(180deg, color-mix(in srgb, var(--bg) 92%, #020303 8%), color-mix(in srgb, var(--bg) 80%, #0a0d11 20%));
}

body::before {
  inset: -12% -6%;
  z-index: -2;
  opacity: 1;
  background:
    radial-gradient(circle at calc(22% + (var(--parallax-x) * 0.7px)) calc(12% + (var(--parallax-scroll) * -0.05px)), rgba(173, 182, 194, 0.12), transparent 0 24%),
    radial-gradient(circle at calc(76% - (var(--parallax-x) * 0.5px)) calc(30% + (var(--parallax-scroll) * -0.09px)), rgba(102, 113, 128, 0.12), transparent 0 18%),
    linear-gradient(transparent 0, rgba(255, 255, 255, 0.02) 100%),
    repeating-linear-gradient(
      120deg,
      transparent 0 38px,
      rgba(223, 229, 237, 0.02) 39px,
      transparent 40px 78px
    ),
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.012) 0,
      rgba(255, 255, 255, 0.012) 1px,
      transparent 1px,
      transparent 52px
    );
  transform:
    translate3d(calc(var(--parallax-x) * 0.45px), calc(var(--parallax-scroll) * -0.08px), 0)
    scale(1.06);
  filter: blur(0.5px);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: var(--grain-opacity);
  background:
    radial-gradient(circle at center, transparent 38%, rgba(0, 0, 0, 0.3) 100%),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.028) 0,
      rgba(255, 255, 255, 0.028) 1px,
      transparent 1px,
      transparent 3px
    ),
    repeating-linear-gradient(
      0deg,
      rgba(0, 0, 0, 0.032) 0,
      rgba(0, 0, 0, 0.032) 1px,
      transparent 1px,
      transparent 4px
    );
  mix-blend-mode: soft-light;
  transform: translate3d(calc(var(--parallax-x) * -0.25px), calc(var(--parallax-scroll) * -0.04px), 0);
}

.topbar {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--bg-elevated) 78%, #050608 22%), color-mix(in srgb, var(--surface) 82%, #0d1116 18%));
  border-color: color-mix(in srgb, var(--surface-border) 92%, rgba(255, 255, 255, 0.08) 8%);
  box-shadow:
    0 24px 54px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.brand-mark {
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--accent) 78%, #dfe5eb 22%), color-mix(in srgb, var(--accent-strong) 88%, #161b21 12%));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 10px 22px rgba(35, 41, 48, 0.24);
}

.nav a:hover,
.nav a:focus-visible,
.contact-list a:hover,
.contact-list a:focus-visible {
  color: var(--heading);
  background: color-mix(in srgb, var(--accent-soft) 80%, transparent);
}

.theme-toggle__track,
.signal-grid article,
.tag-row span,
.timeline-badge,
.link-chip,
code {
  background: linear-gradient(180deg, color-mix(in srgb, var(--surface-strong) 92%, #11151a 8%), color-mix(in srgb, var(--surface) 90%, #0a0d11 10%));
}

.surface {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--surface) 95%, #101419 5%), color-mix(in srgb, var(--surface) 82%, #06080b 18%));
  border-color: color-mix(in srgb, var(--surface-border) 94%, rgba(255, 255, 255, 0.05) 6%);
  box-shadow:
    0 28px 74px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(14px);
}

.surface::before {
  background:
    linear-gradient(145deg, rgba(232, 238, 245, 0.08), transparent 42%),
    linear-gradient(0deg, rgba(255, 255, 255, 0.015), transparent 100%);
}

.button--primary,
.link-chip--primary {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--accent) 78%, #e5eaef 22%), color-mix(in srgb, var(--accent-strong) 90%, #242a31 10%));
  box-shadow:
    0 18px 34px rgba(31, 38, 45, 0.26),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.button--secondary {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--surface-strong) 92%, #101419 8%), color-mix(in srgb, var(--surface) 88%, #07090c 12%));
}

.hero,
.page-hero {
  position: relative;
  isolation: isolate;
}

.hero::before,
.page-hero::before {
  content: "";
  position: absolute;
  inset: -4% -2% auto;
  height: 118%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at calc(26% + (var(--parallax-x) * 0.7px)) calc(18% + (var(--parallax-y) * 0.6px)), rgba(178, 187, 198, 0.12), transparent 0 20%),
    radial-gradient(circle at calc(74% - (var(--parallax-x) * 0.55px)) calc(22% + (var(--parallax-y) * 0.25px)), rgba(102, 113, 126, 0.12), transparent 0 18%),
    linear-gradient(90deg, rgba(232, 238, 245, 0.03), transparent 34%, rgba(110, 121, 135, 0.06) 100%);
  transform: translate3d(calc(var(--parallax-x) * 0.28px), calc(var(--parallax-scroll) * -0.1px), 0);
  filter: blur(8px);
}

.hero::after {
  right: 1%;
  top: 4%;
  width: clamp(240px, 34vw, 420px);
  background:
    radial-gradient(circle, rgba(180, 190, 201, 0.16), transparent 64%),
    radial-gradient(circle at 62% 38%, rgba(102, 112, 125, 0.12), transparent 46%);
  filter: blur(18px);
  transform: translate3d(calc(var(--parallax-x) * -0.35px), calc(var(--parallax-scroll) * -0.08px), 0);
}

.eyebrow,
.project-kicker {
  color: color-mix(in srgb, var(--accent) 92%, #eef3f8 8%);
  text-shadow: 0 0 24px rgba(152, 162, 173, 0.12);
}

.section--projects::before {
  background:
    radial-gradient(circle at 18% 24%, rgba(176, 186, 198, 0.14), transparent 32%),
    radial-gradient(circle at 82% 40%, rgba(102, 113, 126, 0.12), transparent 22%),
    linear-gradient(180deg, transparent, rgba(240, 245, 250, 0.03) 52%, transparent);
  transform: translate3d(0, calc(var(--parallax-scroll) * -0.06px), 0);
}

.project-card--featured,
.page-panel,
.hero-panel__card {
  border-color: color-mix(in srgb, var(--accent) 18%, var(--surface-border));
}

.project-card:hover,
.timeline-card:hover,
.skill-card:hover,
.education-card:hover,
.archive-card:hover,
.detail-card:hover,
.media-card:hover {
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.26),
    0 0 0 1px color-mix(in srgb, var(--accent) 18%, transparent);
}

.detail-image,
.gallery-grid img,
.media-card video {
  filter: saturate(0.84) contrast(1.02) brightness(0.92);
}

html[data-theme="light"] .detail-image,
html[data-theme="light"] .gallery-grid img,
html[data-theme="light"] .media-card video {
  filter: saturate(0.78) contrast(1.04) brightness(0.96) sepia(0.08);
}

@media (max-width: 760px) {
  body::before,
  body::after,
  .hero::before,
  .page-hero::before {
    transform: none;
  }
}

.site-shell {
  position: relative;
  z-index: 1;
}

.hero-panel {
  display: grid;
  gap: 1rem;
  align-content: start;
}

.glitch-link__wrapper {
  display: inline-block;
}

.noise-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 14;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0.18;
}

html[data-theme="light"] .noise-overlay {
  mix-blend-mode: multiply;
  opacity: 0.08;
}

.site-cursor {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 150;
  width: 0;
  height: 0;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(-100px, -100px, 0);
  transition: opacity 120ms ease;
}

.site-cursor.is-visible {
  opacity: 1;
}

.site-cursor__orb,
.site-cursor__ring,
.site-cursor__beam {
  position: absolute;
  top: 0;
  left: 0;
  transform: translate(-50%, -50%);
}

.site-cursor__orb {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 78%, #eef3f8 22%);
  box-shadow:
    0 0 0 1px rgba(240, 245, 250, 0.16),
    0 0 24px rgba(142, 152, 164, 0.24);
}

.site-cursor__ring {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--accent) 42%, rgba(236, 241, 247, 0.24));
  background: rgba(240, 245, 250, 0.02);
  transition:
    transform 140ms ease,
    opacity 140ms ease,
    width 140ms ease,
    height 140ms ease;
}

.site-cursor__beam {
  width: 2px;
  height: 28px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(242, 246, 250, 0.92), rgba(148, 158, 170, 0.18));
  box-shadow: 0 0 16px rgba(148, 158, 170, 0.22);
  opacity: 0;
  transition:
    opacity 120ms ease,
    transform 120ms ease;
}

.site-cursor[data-mode="beam"] .site-cursor__ring,
.site-cursor[data-mode="beam"] .site-cursor__orb {
  opacity: 0;
}

.site-cursor[data-mode="beam"] .site-cursor__beam {
  opacity: 1;
}

.site-cursor[data-mode="pulse"] .site-cursor__ring {
  width: 42px;
  height: 42px;
}

.site-cursor.is-pressed .site-cursor__ring {
  width: 28px;
  height: 28px;
}

html.has-custom-cursor body,
html.has-custom-cursor a,
html.has-custom-cursor button,
html.has-custom-cursor [role="button"],
html.has-custom-cursor [role="link"] {
  cursor: none !important;
}

html.has-custom-cursor.show-native-cursor body,
html.has-custom-cursor.show-native-cursor a,
html.has-custom-cursor.show-native-cursor button,
html.has-custom-cursor.show-native-cursor [role="button"],
html.has-custom-cursor.show-native-cursor [role="link"] {
  cursor: auto !important;
}

.focus-hint {
  position: fixed;
  top: 18px;
  left: 18px;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.58rem;
  border-radius: var(--radius-lg);
  border: 1px solid color-mix(in srgb, var(--surface-border) 90%, rgba(255, 255, 255, 0.06) 10%);
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--bg-elevated) 84%, #0a0d11 16%), color-mix(in srgb, var(--surface) 78%, #0d1014 22%));
  box-shadow:
    0 18px 38px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  backdrop-filter: blur(18px);
}

.focus-hint__keys,
.focus-hint__escape {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.focus-hint__escape {
  display: none;
}

.focus-hint.is-active .focus-hint__escape {
  display: inline-flex;
}

.focus-hint.is-active .focus-hint__keys {
  display: none;
}

.focus-hint [data-key] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 28px;
  padding: 0 0.45rem;
  border-radius: var(--radius-sm);
  border: 1px solid color-mix(in srgb, var(--surface-border) 88%, rgba(255, 255, 255, 0.1) 12%);
  color: var(--heading);
  letter-spacing: 0.08em;
  transition:
    transform 100ms ease,
    background-color 100ms ease,
    border-color 100ms ease;
}

.focus-hint [data-key].is-pressed {
  transform: translateY(-1px);
  border-color: color-mix(in srgb, var(--accent) 42%, var(--surface-border));
  background: color-mix(in srgb, var(--accent-soft) 74%, transparent);
}

main > section {
  transition:
    opacity 320ms ease,
    filter 320ms ease;
}

main > section.focus-muted {
  opacity: 0.18;
  filter: blur(1.8px) saturate(0.82);
}

main > section.focus-active {
  opacity: 1;
  filter: none;
}

.observation-active {
  border-color: color-mix(in srgb, var(--accent) 26%, var(--surface-border));
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--accent) 14%, transparent),
    0 24px 56px rgba(0, 0, 0, 0.18);
}

::selection {
  background: color-mix(in srgb, var(--accent-soft) 86%, rgba(237, 242, 247, 0.08) 14%);
  color: var(--heading);
}

.js-ready .reveal {
  opacity: 0;
  transform: translateY(18px);
  filter: blur(10px);
  transition:
    opacity 720ms ease,
    transform 720ms ease,
    filter 720ms ease;
}

.js-ready .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

@media (max-width: 960px) {
  .focus-hint {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .noise-overlay,
  .site-cursor,
  .focus-hint {
    display: none !important;
  }
}
