:root {
  color-scheme: dark;
  --bg: #02060b;
  --bg-soft: #050c14;
  --panel: rgba(4, 10, 18, 0.52);
  --panel-strong: rgba(4, 10, 18, 0.72);
  --panel-border: rgba(98, 152, 205, 0.28);
  --text: #eaf1fb;
  --muted: #94a7bc;
  --blue: #6ea7ff;
  --cyan: #12d4ff;
  --teal: #25e3b4;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
  --radius: 18px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: rgba(18, 212, 255, 0.9) rgba(4, 11, 18, 0.88);
}

body {
  font-family: "Space Grotesk", sans-serif;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  overflow-x: hidden;
}

body::-webkit-scrollbar {
  width: 12px;
}

body::-webkit-scrollbar-track {
  background: rgba(4, 11, 18, 0.88);
}

body::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(18, 212, 255, 0.92), rgba(37, 227, 180, 0.88));
  border-radius: 999px;
  border: 2px solid rgba(4, 11, 18, 0.88);
}

body::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(37, 227, 180, 0.96), rgba(18, 212, 255, 0.95));
}

a {
  color: inherit;
}

#mesh-canvas {
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
}

.bg-overlay {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 34%, rgba(13, 23, 36, 0.12), transparent 58%),
    linear-gradient(
      180deg,
      rgba(2, 6, 11, 0.95) 0%,
      rgba(2, 6, 11, 0.58) 34%,
      rgba(2, 6, 11, 0.3) 58%,
      rgba(2, 6, 11, 0.9) 100%
    );
}

.bg-overlay::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.012) 0,
      rgba(255, 255, 255, 0.012) 1px,
      transparent 1px,
      transparent 6px
    ),
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.01) 0,
      rgba(255, 255, 255, 0.01) 1px,
      transparent 1px,
      transparent 7px
    );
  mix-blend-mode: soft-light;
  opacity: 0.25;
}

.container {
  width: min(1160px, calc(100% - 2.2rem));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(14px);
  background: linear-gradient(
    180deg,
    rgba(2, 7, 12, 0.88) 0%,
    rgba(2, 7, 12, 0.62) 100%
  );
  border-bottom: 1px solid rgba(160, 191, 224, 0.15);
}

.site-header .container {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-decoration: none;
  color: var(--text);
}

.brand-mark {
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: linear-gradient(140deg, var(--cyan), var(--teal));
  box-shadow: 0 0 10px rgba(18, 212, 255, 0.8);
}

.brand span {
  font-size: 0.95rem;
}

.brand strong {
  color: var(--cyan);
}

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

.nav-links a {
  color: #a6bdd3;
  text-decoration: none;
  font-size: 0.93rem;
  font-weight: 500;
  transition: color 0.25s ease, opacity 0.25s ease;
}

.nav-links a:hover {
  color: var(--text);
  opacity: 0.96;
}

.nav-links a[aria-current="page"] {
  color: var(--text);
  text-shadow: 0 0 16px rgba(18, 212, 255, 0.25);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #12d4ff;
  border-radius: 11px;
  padding: 0.78rem 1.25rem;
  text-decoration: none;
  font-weight: 600;
  color: #03161d;
  background: #12d4ff;
  box-shadow: 0 0 0 1px rgba(18, 212, 255, 0.44), 0 12px 30px rgba(18, 212, 255, 0.24);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.btn:hover {
  transform: translateY(-2px);
  background: #12d4ff;
}

.btn:active {
  background: #12d4ff;
}

.btn.primary {
  color: #03161d;
  background: #12d4ff;
  border-color: #12d4ff;
  box-shadow: 0 0 0 1px rgba(18, 212, 255, 0.44), 0 12px 30px rgba(18, 212, 255, 0.24);
}

.btn.primary:hover {
  background: #12d4ff;
}

.btn.primary:active {
  background: #12d4ff;
}

.btn.ghost {
  color: #12d4ff;
  background: transparent;
  border-color: #12d4ff;
  box-shadow: none;
}

.btn.ghost:hover {
  color: #12d4ff;
  background: transparent;
  box-shadow: 0 0 0 1px rgba(18, 212, 255, 0.34);
}

.btn.ghost:active {
  color: #12d4ff;
  background: transparent;
}

.btn.small {
  padding: 0.56rem 0.96rem;
  font-size: 0.88rem;
}

.hero {
  min-height: 86svh;
  display: flex;
  align-items: center;
}

.hero-panel {
  width: min(900px, 100%);
  margin: 6.2rem auto 4rem;
  text-align: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border-radius: 999px;
  border: 1px solid rgba(18, 212, 255, 0.42);
  background: rgba(3, 17, 25, 0.58);
  padding: 0.45rem 0.82rem;
  font-family: "JetBrains Mono", monospace;
  letter-spacing: 0.09em;
  font-size: 0.74rem;
  color: var(--cyan);
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 0 8px rgba(18, 212, 255, 0.8);
}

.hero h1 {
  margin-top: 1.35rem;
  font-size: clamp(2.3rem, 7vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
}

.hero .accent {
  background: linear-gradient(115deg, var(--cyan), var(--teal));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero .lede {
  margin: 1.4rem auto 0;
  color: var(--muted);
  font-size: 1.15rem;
  line-height: 1.65;
  max-width: 65ch;
}

.hero-actions {
  margin-top: 1.85rem;
  display: flex;
  justify-content: center;
  gap: 0.9rem;
  flex-wrap: wrap;
}

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

.quick-point {
  border: 1px solid rgba(120, 168, 214, 0.22);
  background: rgba(3, 11, 18, 0.5);
  border-radius: 12px;
  padding: 0.95rem 0.8rem;
}

.quick-point strong {
  display: block;
  font-family: "JetBrains Mono", monospace;
  color: var(--teal);
  font-size: 0.9rem;
}

.quick-point span {
  margin-top: 0.25rem;
  display: block;
  color: var(--muted);
  font-size: 0.88rem;
}

.page-main {
  min-height: calc(100vh - 76px);
}

.page-hero {
  min-height: 68svh;
}

.page-hero-compact {
  min-height: 56svh;
}

body.home-page .page-main > section:first-child {
  min-height: calc(100vh - var(--header-h, 76px));
  min-height: calc(100dvh - var(--header-h, 76px));
  display: flex;
  align-items: center;
}

body.home-page .page-main > section:first-child .hero-panel {
  margin-top: clamp(1.2rem, 3.2vh, 2.8rem);
  margin-bottom: clamp(1.1rem, 3vh, 2.2rem);
}

.hero-panel-left {
  margin: 5.2rem 0 2.2rem;
  text-align: left;
}

.hero-panel-left .lede {
  margin-left: 0;
}

.hero-panel-left .quick-points {
  margin-top: 1.45rem;
}

.home-gallery-cta {
  justify-content: flex-start;
  margin-top: 1.25rem;
}

.hero-bullets {
  list-style: none;
  margin: 1.65rem auto 0;
  max-width: 760px;
  text-align: left;
  display: grid;
  gap: 0.2rem;
}

.hero-bullets li {
  color: var(--muted);
  line-height: 1.6;
  padding: 0.62rem 0 0.72rem;
  border-bottom: 1px solid rgba(106, 156, 208, 0.22);
}

.hero-bullets strong {
  font-family: "JetBrains Mono", monospace;
  color: var(--teal);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

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

.story-block {
  padding: 0.35rem 0 0.65rem;
}

.story-block h3 {
  font-size: 1.32rem;
}

.story-block p {
  margin-top: 0.55rem;
  color: var(--muted);
  line-height: 1.66;
}

.story-block + .story-block {
  border-left: 1px solid rgba(106, 156, 208, 0.2);
  padding-left: 1.4rem;
}

.capability-list {
  margin-top: 0.4rem;
}

.capability-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.2rem;
  align-items: start;
  padding: 1rem 0;
  border-top: 1px solid rgba(106, 156, 208, 0.22);
}

.capability-item:last-child {
  border-bottom: 1px solid rgba(106, 156, 208, 0.22);
}

.capability-item h3 {
  font-size: 1.2rem;
}

.capability-item p {
  margin-top: 0.45rem;
  color: var(--muted);
  line-height: 1.62;
}

.capability-item .cap-meta {
  margin-top: 0.12rem;
  white-space: nowrap;
}

.project-strips {
  margin-top: 0.35rem;
}

.project-strip {
  display: block;
  text-decoration: none;
  padding: 1rem 0.2rem;
  border-top: 1px solid rgba(106, 156, 208, 0.24);
  transition: transform 0.22s ease;
}

.project-strip:last-child {
  border-bottom: 1px solid rgba(106, 156, 208, 0.24);
}

.project-strip:hover {
  transform: translateX(8px);
}

.project-strip-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.project-strip h3 {
  font-size: 1.24rem;
}

.project-strip p {
  margin-top: 0.45rem;
  color: var(--muted);
  line-height: 1.62;
}

.process-surface {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
  gap: 1.3rem;
  align-items: stretch;
}

.process-column {
  padding-right: 0.35rem;
}

.process-column .timeline {
  margin-top: 0.2rem;
}

.terminal-card-flat {
  border: 1px solid rgba(98, 152, 205, 0.28);
  border-radius: var(--radius);
  background: rgba(4, 10, 18, 0.46);
  padding: 1.3rem;
  box-shadow: var(--shadow);
}

.contact-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.9fr);
  gap: 2rem;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(106, 156, 208, 0.22);
}

.contact-intro p {
  color: var(--muted);
  line-height: 1.7;
  max-width: 62ch;
}

.contact-actions-inline {
  justify-content: flex-start;
  margin-top: 1.15rem;
}

.email-copy-line {
  margin-top: 0.82rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.52rem;
  color: var(--muted);
  line-height: 1.5;
}

.email-inline {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.82rem;
}

.copy-email-btn.btn.small {
  padding: 0.4rem 0.72rem;
}

.copy-status {
  min-height: 1em;
  font-size: 0.82rem;
  color: #8ef2d7;
}

.contact-copy-line {
  margin-top: 0;
  padding: 0.35rem 0 0.55rem;
  border-bottom: 1px dashed rgba(106, 156, 208, 0.28);
}

.contact-links-plain {
  display: grid;
  align-content: start;
  gap: 0.52rem;
}

.contact-links-plain a {
  display: inline-flex;
  align-items: center;
  gap: 0.52rem;
  color: var(--text);
  text-decoration: none;
  padding: 0.35rem 0;
  border-bottom: 1px dashed rgba(106, 156, 208, 0.28);
  transition: color 0.22s ease;
}

.contact-link-icon {
  width: 1.5rem;
  text-align: center;
  font-family: "JetBrains Mono", monospace;
  color: var(--cyan);
  font-size: 0.8rem;
}

.contact-links-plain a:hover {
  color: #d8ecff;
}

body.editorial .quick-points {
  grid-template-columns: 1fr;
  gap: 0;
}

body.editorial .quick-point {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0.7rem 0;
  border-bottom: 1px solid rgba(106, 156, 208, 0.22);
}

body.editorial .quick-point strong {
  font-size: 0.82rem;
}

body.editorial .glass-card {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  padding: 0.85rem 0;
}

body.editorial .glass-card::after {
  display: none;
}

body.editorial .glass-card.is-hovered {
  border-color: transparent;
}

body.editorial .cards-3,
body.editorial .glass-grid,
body.editorial .kpi-grid {
  gap: 0.45rem;
}

body.editorial .cards-3 .glass-card,
body.editorial .glass-grid .glass-card,
body.editorial .kpi-grid .glass-card,
body.editorial .detail-spaced.glass-card {
  border-top: 1px solid rgba(106, 156, 208, 0.24);
}

body.editorial .cards-3 .glass-card:last-child,
body.editorial .glass-grid .glass-card:last-child,
body.editorial .kpi-grid .glass-card:last-child {
  border-bottom: 1px solid rgba(106, 156, 208, 0.24);
}

body.editorial .cap-card,
body.editorial .project-card,
body.editorial .kpi-card {
  min-height: auto;
}

section {
  padding: 4.65rem 0;
  position: relative;
}

.section-head {
  margin-bottom: 1.8rem;
  max-width: 740px;
}

.process-head {
  max-width: 920px;
}

.section-kicker {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cyan);
}

.section-head h2 {
  margin-top: 0.8rem;
  font-size: clamp(1.9rem, 4vw, 3.2rem);
  line-height: 1.1;
}

.section-head p {
  margin-top: 0.9rem;
  color: var(--muted);
  line-height: 1.7;
}

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

.glass-card {
  border: 1px solid var(--panel-border);
  background: var(--panel);
  border-radius: var(--radius);
  padding: 1.3rem;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  position: relative;
  transform-style: preserve-3d;
  transition:
    transform 0.26s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.26s ease,
    background 0.26s ease;
  will-change: transform;
}

.glass-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(
    280px circle at var(--mx, 50%) var(--my, 50%),
    rgba(18, 212, 255, 0.18),
    rgba(37, 227, 180, 0.06) 44%,
    transparent 72%
  );
  opacity: var(--hover-alpha, 0);
  transition: opacity 0.2s ease;
}

.glass-card.is-hovered {
  border-color: rgba(18, 212, 255, 0.4);
}

.glass-card > * {
  position: relative;
  z-index: 1;
}

.glass-card h3 {
  font-size: 1.22rem;
  margin-bottom: 0.55rem;
}

.glass-card p {
  color: var(--muted);
  line-height: 1.65;
}

.token-row {
  margin-top: 0.95rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.proof-bar {
  justify-content: center;
}

.token {
  border-radius: 10px;
  border: 1px solid rgba(90, 144, 201, 0.34);
  background: rgba(3, 14, 24, 0.58);
  padding: 0.33rem 0.62rem;
  font-size: 0.78rem;
  font-family: "JetBrains Mono", monospace;
  color: #c0d8ef;
}

code {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.88em;
  color: #cde9ff;
  background: rgba(3, 14, 24, 0.62);
  border: 1px solid rgba(90, 146, 204, 0.28);
  border-radius: 7px;
  padding: 0.12rem 0.35rem;
}

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

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

.cap-card {
  min-height: 210px;
}

.cap-meta {
  margin-top: 1rem;
  font-size: 0.82rem;
  color: var(--cyan);
  font-family: "JetBrains Mono", monospace;
}

.project-card {
  min-height: 225px;
  position: relative;
  overflow: hidden;
}

a.project-card {
  text-decoration: none;
}

.project-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(140deg, rgba(18, 212, 255, 0.11), transparent 58%);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.project-card:hover::before {
  opacity: 1;
}

.project-top {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.75rem;
}

.status {
  border-radius: 999px;
  font-size: 0.72rem;
  font-family: "JetBrains Mono", monospace;
  padding: 0.24rem 0.58rem;
  border: 1px solid rgba(90, 146, 204, 0.4);
  color: #b8d4ef;
  background: rgba(3, 14, 24, 0.64);
}

.status.live {
  border-color: rgba(37, 227, 180, 0.45);
  color: #8af1d4;
}

.project-foot {
  margin-top: 1rem;
  color: var(--cyan);
  font-size: 0.85rem;
  font-family: "JetBrains Mono", monospace;
}

.gallery-meta {
  margin-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.projects-showcase {
  display: grid;
  gap: 0.95rem;
}

.project-hero {
  display: block;
  text-decoration: none;
  padding: 1.35rem 1.35rem 1.3rem;
  border-radius: 18px;
  border: 1px solid rgba(18, 212, 255, 0.35);
  background:
    radial-gradient(circle at 82% 12%, rgba(18, 212, 255, 0.12), transparent 56%),
    linear-gradient(112deg, rgba(4, 14, 24, 0.84), rgba(3, 9, 16, 0.7));
  transition: border-color 0.24s ease, box-shadow 0.24s ease, transform 0.24s ease;
}

.project-hero:hover {
  transform: translateY(-2px);
  border-color: rgba(18, 212, 255, 0.58);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.35);
}

.project-hero-kicker {
  font-family: "JetBrains Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  color: #9ed1ff;
}

.project-hero h3 {
  margin-top: 0.52rem;
  font-size: clamp(1.6rem, 3.2vw, 2.05rem);
  line-height: 1.08;
}

.project-hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(340px, 0.92fr);
  gap: 1.1rem;
  align-items: stretch;
}

.project-hero-content {
  display: flex;
  flex-direction: column;
}

.project-hero-code {
  border: 1px solid rgba(107, 158, 210, 0.33);
  border-radius: 14px;
  background: rgba(2, 10, 18, 0.78);
  padding: 0.8rem 0.9rem 0.88rem;
  min-height: 320px;
  pointer-events: none;
}

.project-hero-code-title {
  font-family: "JetBrains Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.71rem;
  color: #9dcdf7;
}

.project-hero-snippet {
  margin-top: 0.48rem;
  border-radius: 10px;
  border: 1px solid rgba(92, 148, 204, 0.34);
  background: rgba(3, 12, 20, 0.75);
  padding: 0.72rem 0.74rem;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.77rem;
  line-height: 1.56;
  color: #d8edff;
  overflow: auto;
  max-height: 290px;
}

.project-hero-snippet code {
  background: transparent;
  border: 0;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

.projects-list {
  display: grid;
  gap: 0.65rem;
}

.project-list-item {
  display: block;
  text-decoration: none;
  padding: 1rem 1.1rem 1.06rem;
  border-left: 2px solid rgba(95, 148, 202, 0.42);
  border-radius: 10px;
  background: rgba(3, 11, 19, 0.48);
  transition: border-color 0.22s ease, background 0.22s ease, transform 0.22s ease;
}

.project-list-item:hover {
  border-left-color: rgba(18, 212, 255, 0.85);
  background: rgba(4, 14, 24, 0.62);
  transform: translateX(2px);
}

.project-list-item h3 {
  margin-top: 0.2rem;
  font-size: clamp(1.1rem, 2.4vw, 1.36rem);
  line-height: 1.2;
}

.project-summary {
  margin-top: 0.4rem;
}

.project-summary-casual {
  margin-top: 0.4rem;
  color: #b7cae0;
  line-height: 1.66;
}

.project-rail {
  margin-top: 0.78rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.project-hero .project-foot,
.project-list-item .project-foot {
  margin-top: 0.76rem;
}

/* Projects page: reduce stacked-card look and use cleaner rail rows */
.projects-page .projects-showcase {
  gap: 1.35rem;
}

.projects-page .project-hero {
  padding: 1.1rem 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  border-top: 1px solid rgba(99, 151, 204, 0.34);
  border-bottom: 1px solid rgba(99, 151, 204, 0.34);
}

.projects-page .project-hero:hover {
  transform: none;
  border-color: rgba(18, 212, 255, 0.58);
  box-shadow: none;
}

.projects-page .project-hero-layout {
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 0.9fr);
  gap: 1.35rem;
}

.projects-page .project-hero-content {
  padding: 0.44rem 0.28rem 0.42rem 0.18rem;
}

.projects-page .project-hero-code {
  min-height: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.projects-page .project-hero-snippet {
  margin-top: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  max-height: none;
  overflow: visible;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  word-break: break-word;
}

.projects-page .projects-list {
  margin-top: 0.3rem;
  gap: 0;
  position: static;
}

.projects-page .projects-list::before {
  display: none;
}

.projects-page .project-list-item {
  padding: 1.14rem 0.2rem 1.2rem 0;
  border-left: 0;
  border-radius: 0;
  background: transparent;
  border-bottom: 1px solid rgba(99, 151, 204, 0.32);
}

.projects-page .project-list-item:first-child {
  border-top: 1px solid rgba(99, 151, 204, 0.32);
}

.projects-page .project-list-item::before,
.projects-page .project-list-item::after {
  content: none;
  display: none;
}

.projects-page .project-list-item:hover {
  transform: translateX(4px);
  border-left-color: transparent;
  background: transparent;
  border-bottom-color: rgba(18, 212, 255, 0.56);
}

.projects-page .project-list-item h3 {
  margin-top: 0.24rem;
  font-size: clamp(1.2rem, 2.4vw, 1.48rem);
}

.projects-page .project-summary,
.projects-page .project-summary-casual {
  max-width: 78ch;
}

.projects-page .project-summary-casual {
  color: #a2bcd4;
}

.projects-page .project-foot {
  margin-top: 0.6rem;
}

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

.review-flow::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0.95rem;
  height: 1px;
  background: linear-gradient(90deg, rgba(18, 212, 255, 0.2), rgba(18, 212, 255, 0.65), rgba(18, 212, 255, 0.2));
}

.review-step {
  position: relative;
  padding-top: 1.45rem;
  padding-right: 0.4rem;
}

.review-step::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62rem;
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 0 0 3px rgba(4, 11, 18, 0.95), 0 0 14px rgba(18, 212, 255, 0.4);
}

.review-step-index {
  font-family: "JetBrains Mono", monospace;
  letter-spacing: 0.12em;
  font-size: 0.73rem;
  color: #86a9cd;
}

.review-step h3 {
  margin-top: 0.38rem;
  font-size: 1.05rem;
}

.review-step > p:not(.review-step-index) {
  margin-top: 0.42rem;
  color: var(--muted);
  line-height: 1.66;
}

.review-flow-note {
  margin-top: 0.82rem;
  color: #a8c0d7;
  font-size: 0.9rem;
}

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

.kpi-card {
  min-height: 150px;
}

.detail-spaced {
  margin-top: 1rem;
}

.path-note {
  margin-top: 0.95rem;
  color: var(--muted);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.84rem;
}

.tech-peek {
  margin-top: 0.25rem;
}

.code-peek {
  margin: 0;
  padding: 1rem 1.05rem;
  border-radius: 12px;
  border: 1px solid rgba(107, 158, 210, 0.34);
  background: rgba(4, 12, 20, 0.78);
  color: #d9eeff;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.82rem;
  line-height: 1.58;
  overflow-x: auto;
}

.code-peek code {
  background: transparent;
  border: 0;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

.peek-why {
  margin-top: 0.72rem;
  color: var(--muted);
  line-height: 1.66;
}

.peek-why strong {
  color: #bfe3ff;
}

.peek-actions {
  margin-top: 0.62rem;
  justify-content: flex-start;
}

.code-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: stretch;
  justify-content: center;
  padding: 0.6rem;
}

.code-modal::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(1, 6, 11, 0.88);
  backdrop-filter: blur(6px);
}

.code-modal.is-open {
  display: flex;
}

.code-modal-shell {
  position: relative;
  width: calc(100vw - 1.2rem);
  max-width: 1600px;
  max-height: calc(100svh - 1.2rem);
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  border: 1px solid rgba(108, 160, 212, 0.34);
  border-radius: 14px;
  background: rgba(4, 11, 19, 0.96);
  box-shadow: 0 28px 68px rgba(0, 0, 0, 0.48);
  overflow: hidden;
}

.code-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.72rem 0.92rem;
  border-bottom: 1px solid rgba(107, 159, 211, 0.22);
}

.code-modal-head h2 {
  font-size: 1rem;
  letter-spacing: 0.01em;
}

.code-modal-hint {
  padding: 0.44rem 0.92rem;
  color: var(--muted);
  font-size: 0.8rem;
  border-bottom: 1px solid rgba(107, 159, 211, 0.16);
}

.code-modal-body {
  overflow: auto;
  padding: 0.55rem;
}

.code-peek-full {
  width: 100%;
  min-height: calc(100svh - 210px);
  user-select: none;
  -webkit-user-select: none;
  caret-color: transparent;
}

body.code-modal-open {
  overflow: hidden;
}

.proof-list {
  list-style: none;
  display: grid;
  gap: 0.45rem;
  margin-top: 0.75rem;
}

.proof-list li {
  color: var(--muted);
  line-height: 1.58;
}

.proof-list li::before {
  content: "•";
  margin-right: 0.55rem;
  color: var(--teal);
}

.contact-actions-left {
  justify-content: flex-start;
}

.timeline {
  position: relative;
  margin-top: 1.3rem;
  display: grid;
  gap: 1rem;
  --line-x: 1.2rem;
  --focus-base: 24px;
  --focus-y: 24px;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--line-x);
  width: 2px;
  transform: translateX(-50%);
  background: linear-gradient(
    180deg,
    rgba(18, 212, 255, 0.3),
    rgba(37, 227, 180, 0.2),
    rgba(110, 167, 255, 0.1)
  );
  opacity: 0.9;
  z-index: 0;
}

.timeline-focus {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.timeline-focus::before {
  content: "";
  position: absolute;
  left: var(--line-x);
  top: var(--focus-base);
  width: 2px;
  height: max(1px, calc(var(--focus-y) - var(--focus-base)));
  transform: translateX(-50%);
  border-radius: 999px;
  background: linear-gradient(
    180deg,
    rgba(232, 251, 255, 1),
    rgba(18, 212, 255, 0.86),
    rgba(37, 227, 180, 0.26)
  );
  box-shadow: 0 0 10px rgba(18, 212, 255, 0.42), 0 0 22px rgba(37, 227, 180, 0.2);
  transition: height 760ms cubic-bezier(0.22, 1, 0.36, 1);
}

.timeline-focus::after {
  content: "";
  position: absolute;
  left: var(--line-x);
  top: var(--focus-y);
  width: 14px;
  height: 14px;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  background: radial-gradient(
    circle,
    rgba(238, 252, 255, 1) 0 28%,
    rgba(18, 212, 255, 0.95) 35% 64%,
    rgba(37, 227, 180, 0.25) 72%,
    transparent 74%
  );
  box-shadow: 0 0 14px rgba(18, 212, 255, 0.95), 0 0 28px rgba(37, 227, 180, 0.42);
  animation: timelinePulse 1.5s ease-in-out infinite;
  transition: top 760ms cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes timelinePulse {
  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
  }
  50% {
    transform: translate(-50%, -50%) scale(1.08);
  }
}

.timeline-item {
  position: relative;
  z-index: 1;
  padding: 0.35rem 0 0.5rem 2.9rem;
  transition: opacity 0.48s ease, transform 0.48s ease;
}

.timeline-head {
  color: var(--text);
  font-weight: 600;
  font-size: 1.14rem;
  transition: color 0.42s ease;
}

.timeline-meta {
  margin-top: 0.2rem;
  font-family: "JetBrains Mono", monospace;
  color: var(--cyan);
  font-size: 0.78rem;
  transition: color 0.42s ease;
}

.timeline-copy {
  margin-top: 0.45rem;
  color: var(--muted);
  line-height: 1.6;
  transition: color 0.42s ease;
}

.timeline.has-active .timeline-item {
  opacity: 0.6;
}

.timeline.has-active .timeline-item.active {
  opacity: 1;
}

.timeline.has-active .timeline-item.active .timeline-head {
  color: #f3f9ff;
}

.timeline.has-active .timeline-item.active .timeline-meta {
  color: #86dcff;
}

.timeline.has-active .timeline-item.active .timeline-copy {
  color: #bacde0;
}

.process-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
  gap: 1rem;
  align-items: stretch;
}

.process-layout > .glass-card {
  height: 100%;
}

.terminal-card {
  background: var(--panel-strong);
}

.terminal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}

.terminal-hint {
  margin-top: 0.65rem;
  margin-bottom: 0.9rem;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.62;
}

.terminal-shell {
  border-radius: 13px;
  border: 1px solid rgba(96, 150, 206, 0.35);
  background: rgba(2, 9, 15, 0.82);
  overflow: hidden;
}

.terminal-top {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.4rem 0.65rem;
  border-bottom: 1px solid rgba(89, 141, 198, 0.22);
  background: rgba(6, 15, 25, 0.92);
}

.terminal-dots {
  display: inline-flex;
  align-items: center;
  gap: 0.32rem;
}

.terminal-dots span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(148, 168, 192, 0.5);
}

.terminal-dots span:nth-child(1) {
  background: rgba(18, 212, 255, 0.8);
}

.terminal-dots span:nth-child(2) {
  background: rgba(37, 227, 180, 0.7);
}

.terminal-name {
  color: #8fb6de;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-family: "JetBrains Mono", monospace;
}

.terminal-body {
  min-height: 248px;
  max-height: 248px;
  overflow: hidden;
  padding: 0.85rem 0.95rem 0.95rem;
  display: grid;
  align-content: start;
  gap: 0.34rem;
}

.term-line {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.85rem;
  line-height: 1.62;
  white-space: pre-wrap;
  word-break: break-word;
}

.term-line.cmd {
  color: #9ddaff;
}

.term-line.log {
  color: #9ab1c6;
}

.term-line.ok {
  color: #8ef2d7;
}

.term-line.meta {
  color: #79b8ff;
}

.term-line.is-typing::after {
  content: "";
  display: inline-block;
  width: 0.58ch;
  height: 1.08em;
  margin-left: 2px;
  vertical-align: -0.18em;
  background: rgba(18, 212, 255, 0.95);
  animation: termBlink 0.95s steps(2, start) infinite;
}

@keyframes termBlink {
  0%,
  49% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0;
  }
}

.contact-wrap {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1rem;
}

.contact-links {
  display: grid;
  gap: 0.6rem;
}

.contact-title {
  margin-top: 0.7rem;
}

.contact-copy {
  margin-top: 0.8rem;
  color: var(--muted);
  line-height: 1.7;
}

.contact-actions {
  justify-content: flex-start;
  margin-top: 1.1rem;
}

.contact-links-spaced {
  margin-top: 0.9rem;
}

.contact-links a {
  text-decoration: none;
  color: var(--text);
  border: 1px solid rgba(105, 155, 206, 0.3);
  border-radius: 10px;
  padding: 0.68rem 0.86rem;
  background: rgba(3, 14, 24, 0.56);
}

.site-footer {
  padding: 2.5rem 0 3.3rem;
  color: var(--muted);
  text-align: center;
  font-size: 0.88rem;
}

.scroll-top-btn {
  position: fixed;
  right: clamp(0.9rem, 2vw, 1.35rem);
  bottom: max(0.9rem, env(safe-area-inset-bottom));
  z-index: 55;
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  border-radius: 999px;
  border: 1px solid rgba(18, 212, 255, 0.4);
  background: rgba(3, 14, 24, 0.88);
  color: var(--cyan);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.74rem;
  letter-spacing: 0.03em;
  line-height: 1;
  padding: 0.5rem 0.74rem;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.22s ease, transform 0.22s ease, border-color 0.22s ease, color 0.22s ease;
}

.scroll-top-btn.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.scroll-top-btn:hover {
  border-color: rgba(18, 212, 255, 0.78);
  color: #d8f6ff;
}

.scroll-top-btn:focus-visible {
  outline: 2px solid rgba(18, 212, 255, 0.92);
  outline-offset: 2px;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

@media (max-width: 1040px) {
  .story-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .story-block + .story-block {
    border-left: 0;
    border-top: 1px solid rgba(106, 156, 208, 0.2);
    padding-left: 0;
    padding-top: 1rem;
  }

  .capability-item {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }

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

  .project-hero {
    padding: 1.2rem 1.15rem 1.14rem;
  }

  .project-hero-layout {
    grid-template-columns: 1fr;
    gap: 0.82rem;
  }

  .project-hero-code {
    min-height: 0;
    padding: 0.72rem 0.8rem 0.78rem;
  }

  .project-list-item {
    padding: 0.95rem 0.95rem 1rem;
  }

  .projects-page .project-hero {
    padding: 1rem 0;
  }

  .projects-page .project-hero-layout {
    grid-template-columns: 1fr;
    gap: 0.9rem;
  }

  .projects-page .project-hero-content {
    padding: 0.2rem 0;
  }

  .projects-page .project-hero-code {
    min-height: 0;
  }

  .projects-page .project-list-item {
    padding-left: 0;
  }

  .review-flow {
    grid-template-columns: 1fr;
    gap: 0.86rem;
    padding-left: 1.45rem;
  }

  .review-flow::before {
    left: 0.24rem;
    right: auto;
    top: 0.2rem;
    bottom: 0.2rem;
    width: 1px;
    height: auto;
    background: linear-gradient(180deg, rgba(18, 212, 255, 0.18), rgba(18, 212, 255, 0.66), rgba(18, 212, 255, 0.18));
  }

  .review-step {
    padding-top: 0.05rem;
    padding-left: 0.95rem;
    padding-right: 0;
  }

  .review-step::before {
    left: -1.21rem;
    top: 0.48rem;
  }

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

  .process-surface {
    grid-template-columns: 1fr;
  }

  .contact-band {
    grid-template-columns: 1fr;
    gap: 1.3rem;
  }

  .process-layout {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .process-layout > .glass-card {
    height: auto;
  }

  .terminal-body {
    min-height: 216px;
    max-height: 216px;
  }

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

@media (max-width: 860px) {
  .bg-overlay {
    background:
      radial-gradient(circle at 50% 56%, rgba(8, 31, 42, 0.13), transparent 56%),
      linear-gradient(
        180deg,
        rgba(2, 6, 11, 0.97) 0%,
        rgba(2, 6, 11, 0.93) 20%,
        rgba(2, 6, 11, 0.68) 44%,
        rgba(2, 6, 11, 0.92) 100%
      );
  }

  .bg-overlay::after {
    opacity: 0.16;
  }

  .site-header .container {
    min-height: auto;
    padding: 0.7rem 0;
    flex-wrap: wrap;
    row-gap: 0.65rem;
  }

  .brand {
    order: 1;
  }

  .site-header .btn.small {
    display: none;
  }

  .nav-links {
    order: 3;
    width: 100%;
    overflow-x: auto;
    gap: 1rem;
    padding-bottom: 0.18rem;
  }

  .nav-links a {
    white-space: nowrap;
  }

  .hero {
    min-height: auto;
    padding-top: 0.4rem;
  }

  .hero-panel {
    margin-top: 5rem;
  }

  .hero-bullets {
    margin-top: 1.25rem;
  }

  .project-strip-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.45rem;
  }

  .capability-item .cap-meta {
    white-space: normal;
  }

  .glass-grid,
  .cards-3,
  .review-flow,
  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .project-hero h3 {
    font-size: 1.45rem;
  }

  .project-hero-snippet {
    font-size: 0.74rem;
    max-height: 245px;
  }

  .project-list-item h3 {
    font-size: 1.2rem;
  }
}

@media (max-width: 620px) {
  .container {
    width: min(1160px, calc(100% - 1.2rem));
  }

  .brand span {
    font-size: 0.88rem;
  }

  .nav-links {
    gap: 0.85rem;
  }

  .eyebrow {
    max-width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    text-align: center;
    white-space: normal;
    line-height: 1.35;
    font-size: 0.64rem;
    letter-spacing: 0.07em;
    padding: 0.42rem 0.7rem;
  }

  .hero-panel {
    margin-top: 4.2rem;
  }

  .hero h1 {
    font-size: clamp(1.9rem, 9vw, 2.4rem);
    line-height: 1.03;
  }

  .hero .lede {
    font-size: 0.98rem;
    line-height: 1.55;
    max-width: 34ch;
  }

  .token {
    font-size: 0.72rem;
    padding: 0.3rem 0.56rem;
  }

  section {
    padding: 3.85rem 0;
  }

  .quick-points,
  .cards-4 {
    grid-template-columns: 1fr;
  }

  .review-flow {
    padding-left: 1.18rem;
  }

  .review-flow::before {
    left: 0.16rem;
  }

  .project-hero,
  .project-list-item {
    padding: 0.9rem 0.88rem 0.96rem;
  }

  .projects-page .project-hero {
    padding: 0.86rem 0;
  }

  .projects-page .project-list-item {
    padding: 0.98rem 0 1rem 0;
  }

  .project-hero h3 {
    font-size: 1.3rem;
  }

  .project-hero-snippet {
    font-size: 0.72rem;
    line-height: 1.52;
    max-height: 215px;
  }

  .project-summary-casual {
    font-size: 0.95rem;
  }

  .hero .lede {
    font-size: 1rem;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 420px) {
  .brand span {
    font-size: 0.84rem;
  }

  .hero h1 {
    font-size: clamp(1.72rem, 8.8vw, 2.1rem);
  }
}

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

  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
