:root {
  color-scheme: dark;

  --space-0: #050814;
  --space-1: #091124;
  --space-2: #101b34;
  --panel: rgba(16, 28, 54, 0.78);
  --panel-strong: rgba(20, 34, 63, 0.94);

  --paper-0: #f5f8fc;
  --paper-1: #e9eef6;
  --ink: #131a29;
  --ink-soft: #4d586d;

  --white: #f7fbff;
  --mist: #c8d4e8;
  --muted: #8e9bb4;
  --line-dark: rgba(190, 211, 244, 0.18);
  --line-light: rgba(20, 35, 62, 0.16);

  --cyan: #7bdff2;
  --blue: #83a9ff;
  --violet: #b9a2ff;
  --gold: #ffd37a;
  --orange: #ff9b64;
  --alert: #ff6577;

  --max-width: 82rem;
  --copy-width: 47rem;
  --display: "Arial Narrow", "Aptos Display", "Segoe UI", Helvetica, Arial, sans-serif;
  --body: "Aptos", "Segoe UI", Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 100%;
  scroll-behavior: smooth;
  background: var(--space-0);
}

body {
  margin: 0;
  min-width: 20rem;
  overflow-x: hidden;
  background: var(--space-0);
  color: var(--white);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.68;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--gold);
  color: var(--space-0);
}

a {
  color: inherit;
  text-decoration-color: currentColor;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.22em;
}

a:hover,
a:focus-visible {
  color: var(--cyan);
}

.skip-link {
  position: fixed;
  top: 0.8rem;
  left: 0.8rem;
  z-index: 50;
  padding: 0.65rem 0.9rem;
  border: 1px solid var(--cyan);
  background: var(--space-0);
  color: var(--white);
  font-weight: 700;
  transform: translateY(-180%);
  transition: transform 160ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-shell {
  width: min(calc(100% - 3rem), var(--max-width));
  margin: 0 auto;
}

.intro,
.section,
.site-footer {
  position: relative;
}

.intro,
.section {
  isolation: isolate;
}

.intro::before,
.section::before,
.site-footer::before {
  content: "";
  position: absolute;
  z-index: -2;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
}

.intro {
  min-height: min(49rem, 92vh);
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 69rem;
  padding: clamp(6rem, 13vw, 11rem) 0 clamp(7rem, 14vw, 12rem);
}

.intro::before {
  background:
    radial-gradient(circle at 12% 18%, rgba(255,255,255,0.92) 0 1px, transparent 1.7px),
    radial-gradient(circle at 72% 14%, rgba(123,223,242,0.76) 0 1px, transparent 1.8px),
    radial-gradient(circle at 86% 39%, rgba(255,211,122,0.72) 0 1px, transparent 1.8px),
    radial-gradient(circle at 35% 48%, rgba(255,255,255,0.6) 0 1px, transparent 1.7px),
    radial-gradient(circle at 63% 68%, rgba(185,162,255,0.7) 0 1px, transparent 1.8px),
    radial-gradient(circle at 18% 76%, rgba(255,255,255,0.64) 0 1px, transparent 1.8px),
    radial-gradient(ellipse at 70% 20%, rgba(80, 116, 211, 0.23), transparent 42%),
    radial-gradient(ellipse at 14% 68%, rgba(42, 191, 217, 0.14), transparent 35%),
    linear-gradient(152deg, #050814 0%, #0b1530 48%, #151838 72%, #2d2040 100%);
  background-size:
    17rem 13rem,
    22rem 17rem,
    27rem 21rem,
    31rem 24rem,
    37rem 29rem,
    43rem 33rem,
    auto,
    auto,
    auto;
}

.intro::after {
  content: "";
  position: absolute;
  z-index: -1;
  left: 0;
  right: 0;
  bottom: clamp(3.5rem, 7vw, 6rem);
  height: 0.55rem;
  background:
    linear-gradient(
      90deg,
      var(--cyan) 0 12%,
      transparent 12% 13%,
      var(--blue) 13% 38%,
      transparent 38% 39%,
      var(--violet) 39% 63%,
      transparent 63% 64%,
      var(--gold) 64% 78%,
      transparent 78% 79%,
      var(--orange) 79% 91%,
      transparent 91% 92%,
      var(--alert) 92% 100%
    );
  border-radius: 999px 0 0 999px;
  box-shadow: 0 0 2.2rem rgba(123, 223, 242, 0.16);
}

.eyebrow,
.section-label,
.project-kind,
.subproject-kicker,
.subproject-status {
  font-family: var(--display);
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin: 0 0 1.65rem;
  color: var(--cyan);
}

.eyebrow::before {
  content: "";
  flex: 0 0 4.25rem;
  height: 0.7rem;
  border-radius: 999px 0 0 999px;
  background: linear-gradient(90deg, var(--violet), var(--cyan));
}

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

h1,
h2,
h3,
h4 {
  font-family: var(--display);
}

h1 {
  max-width: 13ch;
  margin-bottom: 2rem;
  color: var(--white);
  font-size: clamp(2.8rem, 7vw, 5.6rem);
  font-weight: 300;
  letter-spacing: 0.055em;
  line-height: 0.88;
  text-transform: uppercase;
  text-shadow: 0 0 2.4rem rgba(124, 177, 255, 0.14);
}

.lede {
  max-width: 45rem;
  margin-bottom: 0;
  color: #d8e2f5;
  font-size: clamp(1.35rem, 2.7vw, 2.05rem);
  font-weight: 350;
  letter-spacing: 0.01em;
  line-height: 1.4;
}

.section {
  display: grid;
  grid-template-columns: minmax(4rem, 9rem) minmax(0, 1fr);
  gap: clamp(1.5rem, 5vw, 5.5rem);
  padding: clamp(5.5rem, 10vw, 9rem) 0;
}

.section-label {
  align-self: start;
  width: fit-content;
  min-width: 3.25rem;
  padding: 0.28rem 0.8rem 0.32rem;
  border-radius: 999px 0 0 999px;
  text-align: center;
}

.section-body {
  max-width: var(--copy-width);
}

h2 {
  position: relative;
  margin-bottom: clamp(2.4rem, 5vw, 4rem);
  font-size: clamp(2.3rem, 5vw, 4.5rem);
  font-weight: 400;
  letter-spacing: 0.045em;
  line-height: 0.98;
  text-transform: uppercase;
}

h2::after {
  content: "";
  display: block;
  width: min(15rem, 48vw);
  height: 0.38rem;
  margin-top: 1rem;
  border-radius: 999px 0 0 999px;
}

/* The personal account begins in a bright, optimistic register. */
.prose {
  color: var(--ink);
}

.prose::before {
  background:
    linear-gradient(180deg, var(--paper-0) 0%, #f0f4fa 47%, var(--paper-1) 100%);
}

.prose::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  background:
    linear-gradient(90deg, transparent 0 8%, rgba(73, 112, 178, 0.045) 8% 8.1%, transparent 8.1% 100%),
    linear-gradient(180deg, transparent 0 72%, rgba(255, 101, 119, 0.035) 100%);
  pointer-events: none;
}

.prose .section-label {
  background: var(--space-2);
  color: var(--cyan);
}

.prose h2 {
  color: var(--space-1);
}

.prose h2::after {
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--violet));
}

.prose p,
.connect p,
.project > p,
.subproject p {
  font-size: clamp(1.05rem, 1.6vw, 1.18rem);
}

.prose p {
  --signal: var(--cyan);
  position: relative;
  margin-bottom: 1.65rem;
  padding-left: 1.45rem;
}

.prose p::before {
  content: "";
  position: absolute;
  top: 0.42em;
  bottom: 0.4em;
  left: 0;
  width: 0.24rem;
  border-radius: 999px;
  background: var(--signal);
  opacity: 0.78;
}

.prose p:nth-of-type(2) { --signal: var(--blue); }
.prose p:nth-of-type(3) { --signal: var(--violet); }
.prose p:nth-of-type(4) { --signal: var(--gold); }
.prose p:nth-of-type(5) { --signal: var(--orange); }
.prose p:nth-of-type(6) { --signal: var(--alert); }
.prose p:nth-of-type(7) { --signal: var(--gold); }

.prose .closing-line {
  margin-top: 3.25rem;
  margin-bottom: 0;
  padding: 1.2rem 1.4rem 1.15rem 1.55rem;
  border-left: 0.5rem solid var(--alert);
  background: var(--space-1);
  color: var(--white);
  font-family: var(--display);
  font-size: clamp(1.5rem, 3vw, 2.3rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.2;
  text-transform: uppercase;
}

.prose .closing-line::before {
  display: none;
}

cite {
  font-style: italic;
}

/* Work moves into an operations-like register: less utopia, more responsibility. */
.work {
  color: var(--white);
}

.work::before {
  background:
    radial-gradient(ellipse at 82% 8%, rgba(255, 101, 119, 0.13), transparent 32%),
    radial-gradient(ellipse at 8% 92%, rgba(123, 223, 242, 0.08), transparent 34%),
    linear-gradient(145deg, #070b18 0%, #0b1327 55%, #151123 100%);
}

.work .section-label {
  background: var(--gold);
  color: var(--space-0);
}

.work h2::after {
  background: linear-gradient(90deg, var(--gold), var(--orange), var(--alert));
}

.project {
  position: relative;
  overflow: hidden;
  padding: clamp(1.8rem, 4vw, 3rem);
  border: 1px solid rgba(139, 169, 225, 0.25);
  background:
    linear-gradient(135deg, rgba(17, 30, 58, 0.96), rgba(10, 18, 36, 0.96));
  clip-path: polygon(1.2rem 0, 100% 0, 100% calc(100% - 1.2rem), calc(100% - 1.2rem) 100%, 0 100%, 0 1.2rem);
  box-shadow: 0 1.4rem 4rem rgba(0, 0, 0, 0.2);
}

.project::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 0.55rem;
  background:
    linear-gradient(
      90deg,
      var(--cyan) 0 17%,
      transparent 17% 18%,
      var(--blue) 18% 40%,
      transparent 40% 41%,
      var(--gold) 41% 66%,
      transparent 66% 67%,
      var(--orange) 67% 82%,
      transparent 82% 83%,
      var(--alert) 83% 100%
    );
}

.project-heading-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.35rem;
}

.project h3 {
  margin-bottom: 0;
  font-size: clamp(2.2rem, 4.8vw, 3.8rem);
  font-weight: 420;
  letter-spacing: 0.035em;
  line-height: 1;
  text-transform: uppercase;
}

.project h3 a {
  color: var(--white);
  text-decoration: none;
}

.project h3 a:hover,
.project h3 a:focus-visible {
  color: var(--cyan);
}

.project h3 a::after {
  content: " ↗";
  display: inline-block;
  margin-left: 0.14em;
  color: var(--cyan);
  font-family: var(--body);
  font-size: 0.42em;
  font-weight: 700;
  vertical-align: top;
}

.project-kind {
  flex: 0 0 auto;
  padding: 0.34rem 0.85rem 0.38rem;
  border-radius: 999px 0 0 999px;
  background: var(--gold);
  color: var(--space-0);
}

.project > p {
  max-width: 40rem;
  margin-bottom: 2.6rem;
  color: #cbd8ed;
}

.subproject {
  position: relative;
  margin-top: 2.6rem;
  padding: 1.65rem 1.6rem 1.45rem 2rem;
  border-left: 0.65rem solid var(--violet);
  background: linear-gradient(90deg, rgba(185, 162, 255, 0.12), rgba(123, 223, 242, 0.035));
}

.subproject::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 7rem;
  height: 0.36rem;
  background: linear-gradient(90deg, var(--violet), var(--cyan));
}

.subproject-kicker {
  margin-bottom: 0.72rem;
  color: var(--violet);
}

.subproject h4 {
  margin-bottom: 0.9rem;
  color: var(--white);
  font-size: clamp(1.65rem, 3vw, 2.35rem);
  font-weight: 450;
  letter-spacing: 0.035em;
  line-height: 1.05;
  text-transform: uppercase;
}

.subproject h4 a {
  color: var(--white);
  text-decoration: none;
}

.subproject h4 a:hover,
.subproject h4 a:focus-visible {
  color: var(--cyan);
}

.subproject h4 a::after {
  content: " ↗";
  display: inline-block;
  margin-left: 0.14em;
  color: var(--cyan);
  font-family: var(--body);
  font-size: 0.42em;
  font-weight: 700;
  vertical-align: top;
}

.subproject p {
  margin-bottom: 1rem;
  color: #cbd8ed;
}

.subproject-status {
  margin-bottom: 0;
  color: var(--muted) !important;
}

/* The page ends not in alarm, but in an invitation to coordinate. */
.connect {
  color: var(--white);
}

.connect::before {
  background:
    linear-gradient(112deg, rgba(74, 107, 184, 0.14), transparent 38%),
    linear-gradient(180deg, #111a31 0%, #080c18 100%);
}

.connect .section-label {
  background: var(--cyan);
  color: var(--space-0);
}

.connect h2::after {
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.connect p {
  max-width: 40rem;
  color: #cbd6e9;
}

.contact-line {
  width: fit-content;
  max-width: 100%;
  margin-top: 2.4rem;
  margin-bottom: 0;
  padding: 0.8rem 1.2rem 0.85rem 1.35rem;
  border-left: 0.55rem solid var(--cyan);
  background: rgba(123, 223, 242, 0.09);
  font-family: var(--display);
  font-size: clamp(1.25rem, 3vw, 1.9rem) !important;
  letter-spacing: 0.025em;
}

.contact-line a {
  color: var(--white);
  overflow-wrap: anywhere;
  text-decoration: none;
}

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

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  padding: 2.2rem 0 3.2rem;
  color: var(--muted);
  font-size: 0.8rem;
}

.site-footer::before {
  background: #050814;
  border-top: 1px solid var(--line-dark);
}

.site-footer p {
  margin-bottom: 0;
}

@media (max-width: 48rem) {
  .site-shell {
    width: min(calc(100% - 2rem), var(--max-width));
  }

  .intro {
    min-height: auto;
    padding-top: 6.5rem;
  }

  .intro::after {
    bottom: 3.3rem;
  }

  h1 {
    font-size: clamp(2.6rem, 12vw, 4.2rem);
    letter-spacing: 0.025em;
  }

  .section {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .section-label {
    min-width: 3rem;
  }

  .prose p {
    padding-left: 1.1rem;
  }

  .project-heading-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.8rem;
  }

  .project {
    padding: 1.8rem 1.35rem;
  }

  .subproject {
    padding-right: 1.15rem;
    padding-left: 1.35rem;
  }

  .site-footer {
    flex-direction: column;
    gap: 0.55rem;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Minimal additions for the two-page personal hub. */
.site-nav {
  position: absolute;
  top: 2rem;
  right: 0;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--display);
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.site-nav a {
  padding: 0.45rem 0.7rem 0.5rem;
  border-bottom: 0.22rem solid transparent;
  color: var(--muted);
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--cyan);
}

.site-nav a[aria-current="page"] {
  border-bottom-color: var(--cyan);
  color: var(--white);
}

.intro-compact {
  min-height: min(36rem, 72vh);
  padding-top: clamp(7rem, 12vw, 9rem);
  padding-bottom: clamp(6rem, 10vw, 8rem);
}

.read-more {
  margin-top: 2.75rem;
  margin-bottom: 0 !important;
  padding-left: 0 !important;
}

.read-more::before {
  display: none;
}

.read-more a {
  display: inline-block;
  padding: 0.72rem 1rem 0.78rem 1.2rem;
  border-left: 0.48rem solid var(--violet);
  background: var(--space-1);
  color: var(--white);
  font-family: var(--display);
  font-size: 0.9rem;
  font-weight: 750;
  letter-spacing: 0.11em;
  text-decoration: none;
  text-transform: uppercase;
}

.read-more a:hover,
.read-more a:focus-visible {
  border-left-color: var(--cyan);
  color: var(--cyan);
}

.dilemma {
  color: var(--white);
}

.dilemma::before {
  background:
    radial-gradient(ellipse at 83% 12%, rgba(185, 162, 255, 0.12), transparent 34%),
    radial-gradient(ellipse at 9% 88%, rgba(255, 211, 122, 0.07), transparent 32%),
    linear-gradient(145deg, #080d1b 0%, #101832 55%, #171326 100%);
}

.dilemma .section-label {
  background: var(--violet);
  color: var(--space-0);
}

.dilemma h2::after {
  background: linear-gradient(90deg, var(--violet), var(--blue), var(--gold));
}

.dilemma p {
  max-width: var(--copy-width);
  margin-bottom: 1.65rem;
  color: #d2dcef;
  font-size: clamp(1.05rem, 1.6vw, 1.18rem);
}

@media (max-width: 48rem) {
  .site-nav {
    top: 1.35rem;
    right: auto;
    left: 0;
  }

  .intro-compact {
    min-height: auto;
    padding-top: 7.5rem;
  }
}

.site-footer p:last-child {
  text-align: right;
}

@media (max-width: 48rem) {
  .site-footer p:last-child {
    text-align: left;
  }
}

/* Meaning-led hero revision. The domain anchors the site; page titles carry the thesis. */
.site-nav {
  left: 0;
  right: 0;
  justify-content: space-between;
  width: 100%;
}

.site-nav-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.site-nav .site-identity {
  padding-left: 0;
  border-bottom-color: transparent;
  color: var(--cyan);
  letter-spacing: 0.2em;
}

.site-nav .site-identity:hover,
.site-nav .site-identity:focus-visible {
  color: var(--white);
}

.site-nav .site-identity[aria-current="page"] {
  border-bottom-color: transparent;
  color: var(--cyan);
}

.hero-statement h1 {
  max-width: 20ch;
  font-size: clamp(2.65rem, 6vw, 5.25rem);
  letter-spacing: 0.025em;
  line-height: 0.96;
}

.about-page .hero-statement h1 {
  max-width: 15ch;
  font-size: clamp(3rem, 7vw, 5.8rem);
}

.hero-statement .lede {
  max-width: 42rem;
  font-size: clamp(1.15rem, 2.2vw, 1.65rem);
}

@media (max-width: 48rem) {
  .site-nav {
    right: 0;
    left: 0;
    width: 100%;
  }

  .site-nav .site-identity {
    max-width: 48vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .hero-statement h1,
  .about-page .hero-statement h1 {
    max-width: none;
    font-size: clamp(2.35rem, 10.5vw, 4rem);
    letter-spacing: 0.015em;
    line-height: 0.98;
  }
}
