:root {
  --bg: #071018;
  --bg-2: #0b1620;
  --bg-3: #101f2c;
  --surface: rgba(11, 22, 32, 0.72);
  --surface-2: rgba(15, 28, 39, 0.82);
  --surface-3: rgba(255, 255, 255, 0.04);
  --text: #edf5ff;
  --muted: #98adbf;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.16);
  --cyan: #88e8ff;
  --amber: #ff9c5b;
  --lime: #b8ff7b;
  --shadow-xl: 0 35px 120px rgba(0, 0, 0, 0.34);
  --shadow-lg: 0 18px 56px rgba(0, 0, 0, 0.24);
  --radius-xl: 34px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --content-width: min(1240px, calc(100% - 28px));
  --sans: "Avenir Next", "Segoe UI Variable", "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  --mono: ui-monospace, "SFMono-Regular", "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: var(--sans);
  background:
    radial-gradient(circle at 18% 16%, rgba(136, 232, 255, 0.12), transparent 24%),
    radial-gradient(circle at 82% 22%, rgba(255, 156, 91, 0.14), transparent 22%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 45%, #060d14 100%);
  min-height: 100vh;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at center, #000 0%, rgba(0, 0, 0, 0.5) 56%, transparent 88%);
  opacity: 0.38;
}

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

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

button {
  font: inherit;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -64px;
  z-index: 20;
  padding: 12px 16px;
  border-radius: 12px;
  background: #ffffff;
  color: #071018;
}

.skip-link:focus {
  top: 16px;
}

.page-spotlight {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(
      circle 240px at var(--spotlight-x, 70%) var(--spotlight-y, 20%),
      rgba(136, 232, 255, 0.12),
      transparent 70%
    );
  z-index: 0;
}

.system-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.85;
  z-index: 0;
}

.topbar,
main,
.footer {
  position: relative;
  z-index: 1;
  width: var(--content-width);
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 0;
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  font-family: var(--mono);
  font-weight: 600;
  color: #081018;
  background: linear-gradient(135deg, var(--cyan), #baf2ff);
  box-shadow: 0 0 0 8px rgba(136, 232, 255, 0.09), var(--shadow-lg);
}

.brand-copy {
  display: grid;
  gap: 4px;
}

.brand-copy strong {
  font-size: 1rem;
}

.brand-copy small {
  color: var(--muted);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.topnav {
  display: inline-flex;
  gap: 16px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(7, 16, 24, 0.6);
  box-shadow: var(--shadow-lg);
}

.topnav a {
  color: var(--muted);
  font-size: 0.92rem;
}

main {
  display: grid;
  gap: 28px;
  padding: 10px 0 54px;
}

.hero,
.systems,
.work,
.trajectory,
.manifesto,
.contact {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(9, 18, 26, 0.84), rgba(7, 14, 21, 0.86));
  box-shadow: var(--shadow-xl);
}

.systems,
.work,
.trajectory,
.manifesto,
.contact {
  content-visibility: auto;
  contain-intrinsic-size: 900px;
}

.hero {
  min-height: calc(100vh - 108px);
  padding: 34px;
}

.hero::before,
.systems::before,
.work::before,
.trajectory::before,
.manifesto::before,
.contact::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at top left, rgba(136, 232, 255, 0.09), transparent 26%),
    radial-gradient(circle at bottom right, rgba(255, 156, 91, 0.09), transparent 24%);
}

.hero-shell,
.systems-layout,
.trajectory-layout,
.contact {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
  gap: 28px;
}

.eyebrow {
  margin: 0;
  color: var(--amber);
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.eyebrow-tight {
  margin-bottom: 10px;
}

.hero-copy {
  display: grid;
  align-content: center;
}

.hero h1,
.section-heading h2,
.manifesto-copy h2,
.contact-panel h2 {
  margin: 0;
  letter-spacing: -0.06em;
  line-height: 0.9;
}

.hero h1 {
  max-width: 10ch;
  margin-top: 18px;
  font-size: clamp(4rem, 10vw, 8.3rem);
  font-weight: 800;
}

.hero-break {
  display: block;
  font-family: var(--serif);
  font-style: italic;
  color: var(--cyan);
}

.hero-text,
.section-heading p,
.rail-card p,
.terminal-output,
.metric-card p,
.capability-card p,
.project-card p,
.timeline-card p,
.credential-list li,
.manifesto-grid p,
.contact-panel p {
  color: var(--muted);
  line-height: 1.75;
}

.hero-text {
  max-width: 62ch;
  margin: 24px 0 0;
  font-size: 1.02rem;
}

.hero-actions,
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 168px;
  padding: 15px 21px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 700;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

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

.button-primary {
  color: #041018;
  background: linear-gradient(135deg, var(--cyan), #d4f7ff);
  box-shadow: 0 18px 36px rgba(136, 232, 255, 0.2);
}

.button-secondary {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--line-strong);
}

.hero-rail {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 30px;
}

.rail-card,
.stage-card,
.systems-panel,
.capability-card,
.project-card,
.timeline-card,
.credential-column,
.manifesto-step {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(14px);
}

.rail-card {
  padding: 18px;
}

.rail-card strong {
  display: block;
  margin-top: 8px;
  font-size: 1rem;
}

.rail-kicker,
.metric-tag,
.timeline-year,
.capability-index {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--amber);
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-stage {
  position: relative;
  padding: 20px;
  border-radius: calc(var(--radius-xl) - 4px);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02)),
    var(--surface-2);
  border: 1px solid var(--line-strong);
  will-change: transform;
}

.stage-grid {
  display: grid;
  gap: 18px;
}

.stage-card {
  padding: 20px;
}

.stage-card-primary {
  position: relative;
  overflow: hidden;
}

.avatar-lockup {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 16px;
}

.profile-avatar {
  width: 90px;
  height: 90px;
  object-fit: cover;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

.avatar-lockup h2 {
  margin: 0 0 8px;
  font-size: 1.5rem;
  letter-spacing: -0.03em;
}

.radar {
  position: relative;
  height: 320px;
  margin-top: 18px;
  border-radius: 28px;
  background:
    radial-gradient(circle at center, rgba(136, 232, 255, 0.08), transparent 54%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent);
  overflow: hidden;
}

.radar-ring,
.radar-core,
.radar-node {
  position: absolute;
}

.radar-ring {
  top: 50%;
  left: 50%;
  border: 1px solid rgba(136, 232, 255, 0.2);
  border-radius: 999px;
  transform: translate(-50%, -50%);
}

.radar-ring-1 {
  width: 100px;
  height: 100px;
}

.radar-ring-2 {
  width: 180px;
  height: 180px;
}

.radar-ring-3 {
  width: 260px;
  height: 260px;
}

.radar-core {
  top: 50%;
  left: 50%;
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  border-radius: 999px;
  color: #071018;
  font-family: var(--mono);
  font-weight: 600;
  background: linear-gradient(145deg, var(--cyan), #d9f8ff);
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 12px rgba(136, 232, 255, 0.08);
}

.radar-node {
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  font-family: var(--mono);
  font-size: 0.78rem;
}

.radar-node-a { top: 18%; left: 52%; }
.radar-node-b { top: 35%; right: 6%; }
.radar-node-c { bottom: 22%; right: 16%; }
.radar-node-d { bottom: 10%; left: 48%; }
.radar-node-e { bottom: 28%; left: 4%; }
.radar-node-f { top: 38%; left: 10%; }

.terminal-card {
  background: linear-gradient(180deg, rgba(7, 16, 24, 0.96), rgba(12, 22, 31, 0.9));
}

.terminal-top {
  display: flex;
  gap: 8px;
}

.terminal-top span {
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.36);
}

.terminal-body {
  margin-top: 18px;
  font-family: var(--mono);
}

.terminal-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  color: var(--cyan);
}

.terminal-prompt {
  color: var(--lime);
}

.terminal-output {
  min-height: 4.8rem;
  margin: 16px 0 0;
}

.metrics-wall {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.metric-card {
  padding: 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.metric-card strong {
  display: block;
  margin-top: 10px;
  font-size: 1.5rem;
  letter-spacing: -0.05em;
}

.hero-marquee {
  margin-top: 24px;
  overflow: hidden;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}

.hero-marquee-track {
  display: flex;
  gap: 20px;
  width: max-content;
  padding: 16px 0;
  font-family: var(--mono);
  color: #dbeef6;
  animation: marquee 34s linear infinite;
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding-left: 18px;
  white-space: nowrap;
}

.ticker-item::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--amber);
  box-shadow: 0 0 0 7px rgba(255, 156, 91, 0.12);
}

.systems,
.work,
.trajectory,
.manifesto,
.contact {
  padding: 34px;
}

.section-heading {
  display: grid;
  gap: 14px;
  max-width: 760px;
  margin-bottom: 24px;
}

.section-heading h2,
.manifesto-copy h2,
.contact-panel h2 {
  font-size: clamp(2.2rem, 4.3vw, 4.1rem);
}

.systems-panel {
  padding: 22px;
}

.core-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  min-height: 360px;
}

.core-node {
  position: relative;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.core-node-main {
  grid-column: 2;
  grid-row: 2;
  display: grid;
  place-items: center;
  min-height: 140px;
  text-align: center;
  background: linear-gradient(145deg, rgba(136, 232, 255, 0.16), rgba(255, 156, 91, 0.14));
  box-shadow: 0 0 0 14px rgba(136, 232, 255, 0.05);
}

.core-node-main span {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.06em;
}

.core-node-main small,
.core-node-small small {
  color: var(--muted);
}

.core-node-small:nth-of-type(2) { grid-column: 2; grid-row: 1; }
.core-node-small:nth-of-type(3) { grid-column: 3; grid-row: 2; }
.core-node-small:nth-of-type(4) { grid-column: 3; grid-row: 3; }
.core-node-small:nth-of-type(5) { grid-column: 2; grid-row: 4; }
.core-node-small:nth-of-type(6) { grid-column: 1; grid-row: 3; }
.core-node-small:nth-of-type(7) { grid-column: 1; grid-row: 2; }

.capability-stack,
.manifesto-grid {
  display: grid;
  gap: 16px;
}

.capability-card,
.manifesto-step {
  padding: 22px;
}

.capability-card h3,
.project-card h3,
.timeline-card h3,
.credential-head h3,
.manifesto-step h3 {
  margin: 10px 0 12px;
  font-size: 1.5rem;
  letter-spacing: -0.04em;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.project-card {
  display: grid;
  gap: 18px;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent),
    var(--surface);
  will-change: transform;
}

.project-visual {
  min-height: 200px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(120deg, rgba(136, 232, 255, 0.12), transparent 42%),
    radial-gradient(circle at bottom right, rgba(255, 156, 91, 0.18), transparent 34%),
    rgba(255, 255, 255, 0.03);
}

.project-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.project-head a {
  color: var(--cyan);
  font-size: 0.92rem;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.project-tags span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 156, 91, 0.11);
  color: #ffc29b;
  font-size: 0.84rem;
}

.project-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.92rem;
}

.timeline {
  display: grid;
  gap: 16px;
}

.timeline-card {
  padding: 24px;
}

.credential-column {
  align-self: start;
  padding: 24px;
}

.credential-list {
  display: grid;
  gap: 14px;
  padding-left: 18px;
  margin: 20px 0 0;
}

.manifesto {
  display: grid;
  gap: 24px;
}

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

.contact {
  align-items: center;
}

.footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 0 0 36px;
  color: var(--muted);
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 520ms ease, transform 520ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.low-power .system-canvas,
.low-power .page-spotlight {
  display: none;
}

.low-power .hero-marquee-track {
  width: auto;
  flex-wrap: wrap;
  animation: none;
}

.low-power .tilt-card,
.low-power .project-card,
.low-power .hero-stage {
  transform: none !important;
}

.low-power .rail-card,
.low-power .stage-card,
.low-power .systems-panel,
.low-power .capability-card,
.low-power .project-card,
.low-power .timeline-card,
.low-power .credential-column,
.low-power .manifesto-step {
  backdrop-filter: none;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2);
}

@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@media (max-width: 1120px) {
  .hero-shell,
  .systems-layout,
  .trajectory-layout,
  .contact {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

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

@media (max-width: 860px) {
  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .topnav {
    flex-wrap: wrap;
  }

  .hero,
  .systems,
  .work,
  .trajectory,
  .manifesto,
  .contact {
    padding: 24px;
  }

  .hero-rail,
  .project-grid,
  .metrics-wall {
    grid-template-columns: 1fr;
  }

  .avatar-lockup {
    grid-template-columns: 1fr;
  }

  .core-grid {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .core-node-main,
  .core-node-small:nth-of-type(2),
  .core-node-small:nth-of-type(3),
  .core-node-small:nth-of-type(4),
  .core-node-small:nth-of-type(5),
  .core-node-small:nth-of-type(6),
  .core-node-small:nth-of-type(7) {
    grid-column: auto;
    grid-row: auto;
  }

  .footer {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 560px) {
  :root {
    --content-width: min(100% - 18px, 1240px);
  }

  .hero h1 {
    font-size: clamp(3.3rem, 14vw, 5.2rem);
  }

  .button {
    width: 100%;
  }

  .hero-actions,
  .contact-actions {
    flex-direction: column;
  }

  .hero-marquee-track {
    animation-duration: 24s;
  }
}

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

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