:root {
  color-scheme: dark;
  --bg: #070a12;
  --bg-2: #0d111c;
  --card: rgba(17, 24, 39, 0.78);
  --card-strong: rgba(21, 27, 45, 0.92);
  --text: #f8fafc;
  --text-2: #cbd5e1;
  --muted: #94a3b8;
  --border: #263244;
  --purple: #8b5cf6;
  --orange: #f97316;
  --amber: #f59e0b;
  --green: #22c55e;
  --gradient: linear-gradient(135deg, #8b5cf6 0%, #f97316 52%, #f59e0b 100%);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  --max: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(circle at 10% 0%, rgba(139, 92, 246, 0.22), transparent 28rem),
    radial-gradient(circle at 82% 8%, rgba(249, 115, 22, 0.16), transparent 24rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  margin: 0;
  overflow-x: hidden;
}

body.menu-open {
  overflow: hidden;
}

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

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

::selection {
  background: rgba(249, 115, 22, 0.34);
}

.cursor-glow {
  background: radial-gradient(circle, rgba(249, 115, 22, 0.16), transparent 62%);
  border-radius: 999px;
  height: 28rem;
  left: var(--cursor-x, 50vw);
  opacity: 0.8;
  pointer-events: none;
  position: fixed;
  top: var(--cursor-y, 40vh);
  transform: translate(-50%, -50%);
  width: 28rem;
  z-index: -1;
}

.site-header {
  align-items: center;
  background: rgba(7, 10, 18, 0.72);
  border-bottom: 1px solid rgba(38, 50, 68, 0.58);
  backdrop-filter: blur(18px);
  display: flex;
  height: 76px;
  justify-content: space-between;
  left: 0;
  padding: 0 max(24px, calc((100vw - var(--max)) / 2));
  position: fixed;
  right: 0;
  top: 0;
  transition: background 180ms ease, border-color 180ms ease;
  z-index: 20;
}

.site-header.is-scrolled {
  background: rgba(7, 10, 18, 0.9);
  border-color: rgba(148, 163, 184, 0.2);
}

.brand,
.nav,
.hero-actions,
.contact-actions,
.ticker,
.card-top,
.cred-line {
  align-items: center;
  display: flex;
}

.brand {
  font-family: "Space Grotesk", Inter, sans-serif;
  font-weight: 700;
  gap: 0.8rem;
  letter-spacing: 0;
}

.brand-mark {
  align-items: center;
  background:
    linear-gradient(var(--bg), var(--bg)) padding-box,
    var(--gradient) border-box;
  border: 1px solid transparent;
  border-radius: 12px;
  color: var(--text);
  display: inline-flex;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.86rem;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.nav {
  gap: 1.25rem;
}

.nav a {
  color: var(--text-2);
  font-size: 0.9rem;
  font-weight: 700;
  transition: color 180ms ease;
}

.nav a:hover {
  color: var(--orange);
}

.menu-toggle {
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 12px;
  display: none;
  height: 42px;
  padding: 0 0.7rem;
  width: 46px;
}

.menu-toggle span {
  background: var(--text);
  display: block;
  height: 2px;
  margin: 5px 0;
  width: 100%;
}

.section-shell {
  margin: 0 auto;
  max-width: var(--max);
  padding: 96px 24px;
  position: relative;
}

.hero {
  align-items: center;
  display: grid;
  min-height: 100vh;
  overflow: hidden;
  padding-top: 132px;
}

.page-hero {
  min-height: 620px;
  padding-top: 150px;
}

.hero-bg {
  animation: glowShift 14s ease-in-out infinite alternate;
  background:
    radial-gradient(circle at 30% 20%, rgba(139, 92, 246, 0.35), transparent 35%),
    radial-gradient(circle at 70% 10%, rgba(249, 115, 22, 0.26), transparent 30%),
    radial-gradient(circle at 50% 80%, rgba(245, 158, 11, 0.18), transparent 35%);
  inset: 0;
  position: absolute;
  z-index: -3;
}

.signal-field {
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  position: absolute;
  z-index: -2;
}

.signal-field span {
  animation: signalDrift 9s ease-in-out infinite alternate;
  background: linear-gradient(90deg, transparent, rgba(139, 92, 246, 0.24), rgba(249, 115, 22, 0.32), transparent);
  height: 1px;
  left: -12%;
  position: absolute;
  transform: rotate(-8deg);
  width: 124%;
}

.signal-field span:nth-child(1) {
  top: 28%;
}

.signal-field span:nth-child(2) {
  animation-delay: -2s;
  top: 48%;
}

.signal-field span:nth-child(3) {
  animation-delay: -5s;
  top: 68%;
}

.hero::after {
  background:
    linear-gradient(90deg, rgba(7, 10, 18, 0.96) 0%, rgba(7, 10, 18, 0.78) 42%, rgba(7, 10, 18, 0.2) 100%),
    linear-gradient(0deg, var(--bg) 0%, rgba(7, 10, 18, 0) 28%);
  content: "";
  inset: 0;
  position: absolute;
  z-index: -1;
}

.hero-visual {
  border-radius: 28px;
  filter: saturate(1.18) contrast(1.06);
  height: min(68vh, 720px);
  object-fit: cover;
  object-position: center;
  opacity: 0.82;
  position: absolute;
  right: max(-140px, calc((100vw - var(--max)) / -2));
  top: 18%;
  width: min(820px, 68vw);
  z-index: -2;
}

.hero-content {
  max-width: 880px;
}

.badge,
.tag,
.section-kicker,
.cred-line,
.ticker,
.writing-card span {
  font-family: "JetBrains Mono", monospace;
}

.badge {
  background: rgba(249, 115, 22, 0.1);
  border: 1px solid rgba(249, 115, 22, 0.28);
  border-radius: 999px;
  color: #fed7aa;
  display: inline-flex;
  font-size: 0.82rem;
  margin: 0 0 1.35rem;
  padding: 0.55rem 0.8rem;
}

.eyebrow,
.section-kicker {
  color: var(--amber);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0;
  margin: 0 0 0.85rem;
  text-transform: uppercase;
}

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

h1,
h2,
h3 {
  font-family: "Space Grotesk", Inter, sans-serif;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(2.45rem, 4.4vw, 4.2rem);
  line-height: 0.98;
  margin-bottom: 1.1rem;
  max-width: 680px;
}

h2 {
  font-size: clamp(1.75rem, 3vw, 3rem);
  line-height: 1.08;
  margin-bottom: 0;
}

h3 {
  font-size: 1.32rem;
  line-height: 1.15;
  margin-bottom: 0.9rem;
}

.hero-copy {
  color: var(--text-2);
  font-size: clamp(0.98rem, 1.35vw, 1.08rem);
  max-width: 680px;
}

.hero-subhead {
  color: var(--text);
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: clamp(1.08rem, 1.6vw, 1.4rem);
  line-height: 1.1;
  margin-bottom: 1.1rem;
  max-width: 680px;
}

.hero-actions,
.contact-actions {
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2rem;
}

.button {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 999px;
  display: inline-flex;
  font-weight: 800;
  justify-content: center;
  min-height: 50px;
  padding: 0.85rem 1.2rem;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, color 180ms ease;
}

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

.button.primary {
  background: var(--gradient);
  box-shadow: 0 0 32px rgba(249, 115, 22, 0.24);
  color: #04111a;
}

.button.primary:hover {
  box-shadow: 0 0 44px rgba(139, 92, 246, 0.28);
}

.button.secondary {
  background: rgba(248, 250, 252, 0.03);
  border-color: rgba(203, 213, 225, 0.22);
  color: var(--text);
}

.button.secondary:hover {
  border-color: rgba(249, 115, 22, 0.76);
  color: #ffedd5;
}

.cred-line {
  color: var(--muted);
  flex-wrap: wrap;
  font-size: 0.86rem;
  gap: 0.55rem;
  margin: 1.5rem 0 0;
}

.cred-line a {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  color: var(--text-2);
  padding: 0.46rem 0.68rem;
  transition: border-color 180ms ease, color 180ms ease, background 180ms ease;
}

.cred-line a:hover {
  background: rgba(249, 115, 22, 0.1);
  border-color: rgba(249, 115, 22, 0.62);
  color: #ffedd5;
}

.cred-strip {
  border-block: 1px solid rgba(38, 50, 68, 0.7);
  overflow: hidden;
}

.ticker {
  color: var(--text-2);
  gap: clamp(1rem, 4vw, 3rem);
  justify-content: center;
  min-height: 72px;
  padding: 0 24px;
  text-transform: uppercase;
}

.ticker span {
  font-size: 0.78rem;
  white-space: nowrap;
}

.split {
  display: grid;
  gap: clamp(2rem, 6vw, 5rem);
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 1.08fr);
}

.narrative {
  color: var(--text-2);
  font-size: 1.04rem;
}

.signal-text {
  background: linear-gradient(90deg, var(--text), #fed7aa);
  -webkit-background-clip: text;
  color: transparent;
  font-weight: 800;
}

.section-heading {
  max-width: 780px;
}

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

.project-card,
.now-build-card,
.artifact-card,
.philosophy-grid article,
.writing-card,
.now-card,
.personal-card,
.talks-panel,
.contact-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015)) padding-box,
    linear-gradient(145deg, rgba(139, 92, 246, 0.48), rgba(249, 115, 22, 0.26), rgba(245, 158, 11, 0.18)) border-box;
  border: 1px solid transparent;
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.project-card,
.now-build-card,
.artifact-card,
.philosophy-grid article,
.now-card,
.personal-card {
  padding: clamp(1.35rem, 3vw, 2rem);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.project-card:hover,
.now-build-card:hover,
.artifact-card:hover,
.philosophy-grid article:hover,
.writing-card:hover {
  transform: translateY(-5px);
}

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

.now-build-card {
  min-height: 270px;
}

.now-build-card.primary-build {
  grid-column: span 2;
}

.now-build-card h3 {
  margin-top: 1.4rem;
}

.now-build-card strong {
  color: #fed7aa;
  display: inline-flex;
  margin-top: 1rem;
}

.timeline {
  padding-top: 40px;
}

.timeline-track {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 2.4rem;
  position: relative;
}

.timeline-track::before {
  background: linear-gradient(90deg, var(--amber), var(--orange), var(--purple));
  content: "";
  height: 1px;
  left: 8%;
  opacity: 0.42;
  position: absolute;
  right: 8%;
  top: 28px;
}

.timeline-track a {
  background: rgba(17, 24, 39, 0.46);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 22px;
  min-height: 210px;
  padding: 1.25rem;
  position: relative;
  transition: transform 180ms ease, border-color 180ms ease;
}

.timeline-track a:hover {
  border-color: rgba(249, 115, 22, 0.58);
  transform: translateY(-4px);
}

.timeline-track span {
  align-items: center;
  background: var(--bg);
  border: 1px solid rgba(249, 115, 22, 0.52);
  border-radius: 999px;
  color: #fed7aa;
  display: inline-flex;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.72rem;
  height: 42px;
  justify-content: center;
  margin-bottom: 1.4rem;
  width: 42px;
}

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

.card-top {
  justify-content: space-between;
  margin-bottom: 2rem;
}

.tag {
  background: rgba(148, 163, 184, 0.08);
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  color: var(--text-2);
  font-size: 0.72rem;
  padding: 0.46rem 0.7rem;
}

.orb {
  border-radius: 999px;
  box-shadow: 0 0 28px currentColor;
  height: 12px;
  width: 12px;
}

.orb.orange {
  color: var(--orange);
}

.orb.purple {
  color: var(--purple);
}

.orb.amber {
  color: var(--amber);
}

.orb.green {
  color: var(--green);
}

.project-card p,
.now-build-card p,
.artifact-card p,
.philosophy-grid p,
.writing-card p,
.talks-panel p,
.now-card p,
.personal-card p,
.contact-panel p {
  color: var(--text-2);
}

.project-flow {
  display: grid;
  gap: 0.75rem;
}

.project-flow p {
  margin-bottom: 0;
}

.project-flow strong {
  color: var(--text);
}

.project-card ul,
.interest-list {
  color: var(--muted);
  margin: 1.2rem 0 0;
  padding-left: 1.05rem;
}

.project-card li,
.interest-list li {
  margin-bottom: 0.45rem;
}

.project-card a {
  color: #fed7aa;
  display: inline-flex;
  font-weight: 800;
  margin-top: 1.2rem;
}

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

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

.artifact-card {
  min-height: 340px;
  overflow: hidden;
  position: relative;
}

.artifact-top {
  color: var(--muted);
  display: flex;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.72rem;
  justify-content: space-between;
  margin-bottom: 2rem;
  text-transform: uppercase;
}

.terminal-lines {
  background: rgba(7, 10, 18, 0.62);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 16px;
  padding: 1rem;
}

.terminal-lines p {
  color: var(--text-2);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.78rem;
  margin-bottom: 0.7rem;
}

.terminal-lines p:last-child {
  margin-bottom: 0;
}

.terminal-lines span {
  color: var(--orange);
  margin-right: 0.45rem;
}

.node-map {
  display: grid;
  gap: 0.8rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  position: relative;
}

.node-map::before {
  background:
    linear-gradient(90deg, transparent 0 49%, rgba(249, 115, 22, 0.26) 49% 51%, transparent 51%),
    linear-gradient(0deg, transparent 0 49%, rgba(139, 92, 246, 0.26) 49% 51%, transparent 51%);
  content: "";
  inset: 12%;
  position: absolute;
}

.node-map span {
  background: rgba(7, 10, 18, 0.78);
  border: 1px solid rgba(249, 115, 22, 0.32);
  border-radius: 999px;
  color: var(--text-2);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.75rem;
  padding: 0.75rem;
  position: relative;
  text-align: center;
}

.seismic-lines {
  display: grid;
  gap: 0.65rem;
  margin: 2.6rem 0 2rem;
}

.seismic-lines span {
  background: linear-gradient(90deg, transparent, var(--purple), var(--orange), var(--amber), transparent);
  clip-path: polygon(0 55%, 8% 50%, 14% 62%, 20% 18%, 26% 80%, 33% 45%, 44% 55%, 56% 22%, 68% 76%, 78% 42%, 88% 50%, 100% 48%);
  display: block;
  height: 22px;
  opacity: 0.86;
}

.seismic-lines span:nth-child(2),
.seismic-lines span:nth-child(4) {
  opacity: 0.44;
  transform: scaleX(0.86);
  transform-origin: left;
}

.thinking {
  border-block: 1px solid rgba(38, 50, 68, 0.58);
}

.writing-list {
  display: grid;
  gap: 0.85rem;
  margin-top: 2.2rem;
}

.writing-card {
  align-items: start;
  display: grid;
  gap: 1rem;
  grid-template-columns: 56px 1fr;
  padding: 1.25rem;
  transition: transform 180ms ease;
}

.writing-card span {
  color: var(--orange);
  font-size: 0.9rem;
}

.writing-card h3 {
  margin-bottom: 0.35rem;
}

.writing-card p {
  margin-bottom: 0;
}

.talks-panel {
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.78fr);
  overflow: hidden;
  padding: clamp(1.5rem, 4vw, 3rem);
  position: relative;
}

.talks-panel::before {
  background: var(--gradient);
  content: "";
  filter: blur(74px);
  height: 160px;
  opacity: 0.28;
  position: absolute;
  right: -30px;
  top: -60px;
  width: 260px;
}

.topic-cloud {
  align-content: start;
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  position: relative;
}

.topic-cloud span {
  background: rgba(248, 250, 252, 0.06);
  border: 1px solid rgba(203, 213, 225, 0.14);
  border-radius: 999px;
  color: var(--text-2);
  padding: 0.62rem 0.82rem;
}

.topic-cloud span:hover {
  border-color: rgba(249, 115, 22, 0.64);
  color: var(--text);
}

.human-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin: 1.4rem 0;
}

.human-chips span {
  background: rgba(248, 250, 252, 0.06);
  border: 1px solid rgba(203, 213, 225, 0.14);
  border-radius: 999px;
  color: var(--text-2);
  padding: 0.58rem 0.76rem;
}

.text-link {
  color: #fed7aa;
  display: inline-flex;
  font-weight: 800;
  margin-top: 1rem;
}

.now-personal {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1.08fr 0.92fr;
}

.now-page-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding-top: 24px;
}

.contact {
  padding-bottom: 72px;
}

.contact-panel {
  overflow: hidden;
  padding: clamp(2rem, 5vw, 4rem);
  position: relative;
}

.contact-panel::after {
  background:
    linear-gradient(90deg, transparent 0 46%, rgba(249, 115, 22, 0.18) 46% 47%, transparent 47%),
    linear-gradient(0deg, transparent 0 46%, rgba(139, 92, 246, 0.18) 46% 47%, transparent 47%);
  content: "";
  inset: 0;
  opacity: 0.28;
  pointer-events: none;
  position: absolute;
}

.contact-panel > * {
  position: relative;
  z-index: 1;
}

.contact-panel h2 {
  max-width: 720px;
}

.contact-panel p {
  max-width: 680px;
}

.site-footer {
  align-items: center;
  border-top: 1px solid rgba(38, 50, 68, 0.72);
  color: var(--muted);
  display: flex;
  font-size: 0.92rem;
  gap: 1rem;
  justify-content: space-between;
  margin: 0 auto;
  max-width: var(--max);
  min-height: 86px;
  padding: 0 24px;
}

.site-footer p {
  margin: 0;
}

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

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

@keyframes glowShift {
  from {
    filter: hue-rotate(0deg);
    transform: translate3d(0, 0, 0) scale(1);
  }

  to {
    filter: hue-rotate(16deg);
    transform: translate3d(1.5rem, -1rem, 0) scale(1.04);
  }
}

@keyframes signalDrift {
  from {
    opacity: 0.14;
    transform: translateX(-2rem) rotate(-8deg);
  }

  to {
    opacity: 0.42;
    transform: translateX(2rem) rotate(-8deg);
  }
}

@media (max-width: 900px) {
  .site-header {
    height: 68px;
    padding-inline: 18px;
  }

  .menu-toggle {
    display: block;
  }

  .nav {
    align-items: stretch;
    background: rgba(13, 17, 28, 0.98);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: var(--shadow);
    display: none;
    flex-direction: column;
    gap: 0;
    left: 18px;
    padding: 0.8rem;
    position: fixed;
    right: 18px;
    top: 80px;
  }

  body.menu-open .nav {
    display: flex;
  }

  .nav a {
    border-radius: 12px;
    padding: 0.9rem;
  }

  .nav a:hover {
    background: rgba(249, 115, 22, 0.1);
  }

  .section-shell {
    padding-block: 64px;
  }

  .hero {
    min-height: 920px;
    padding-top: 116px;
  }

  .hero-visual {
    height: 48vh;
    opacity: 0.56;
    right: -260px;
    top: 12%;
    width: min(840px, 150vw);
  }

  .split,
  .project-grid,
  .now-grid,
  .timeline-track,
  .artifact-grid,
  .philosophy-grid,
  .talks-panel,
  .now-personal,
  .now-page-grid {
    grid-template-columns: 1fr;
  }

  .project-card.featured,
  .now-build-card.primary-build {
    grid-column: span 1;
  }

  .timeline-track::before {
    bottom: 8%;
    height: auto;
    left: 21px;
    right: auto;
    top: 8%;
    width: 1px;
  }

  .ticker {
    justify-content: flex-start;
    overflow-x: auto;
  }
}

@media (max-width: 560px) {
  .brand span:last-child {
    display: none;
  }

  .hero {
    min-height: 860px;
    padding-top: 98px;
  }

  h1 {
    font-size: clamp(2.1rem, 9vw, 2.6rem);
  }

  .hero-subhead {
    font-size: 1.03rem;
  }

  .hero-copy {
    font-size: 0.94rem;
  }

  .hero-actions {
    margin-top: 1.35rem;
  }

  .badge {
    border-radius: 18px;
  }

  .button {
    width: 100%;
  }

  .card-top {
    align-items: flex-start;
    gap: 1rem;
  }

  .writing-card {
    grid-template-columns: 1fr;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
  }
}
