:root {
  color-scheme: light;
  --bg: #f7f4ee;
  --ink: #20231f;
  --muted: #66706a;
  --line: rgba(32, 35, 31, 0.14);
  --panel: rgba(255, 255, 255, 0.72);
  --panel-strong: #fffaf0;
  --green: #2f8f6b;
  --green-dark: #176047;
  --blue: #286f9c;
  --amber: #c97a1a;
  --red: #b84a3d;
  --shadow: 0 24px 80px rgba(44, 38, 29, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), transparent 440px),
    radial-gradient(circle at 14% 12%, rgba(47, 143, 107, 0.16), transparent 34%),
    radial-gradient(circle at 86% 4%, rgba(201, 122, 26, 0.16), transparent 28%),
    var(--bg);
  color: var(--ink);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

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

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 5vw, 72px);
  border-bottom: 1px solid rgba(32, 35, 31, 0.08);
  background: rgba(247, 244, 238, 0.86);
  backdrop-filter: blur(18px);
}

.brand,
.nav,
.hero-actions,
.project-meta,
.contact,
.footer {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
}

.brand-mark {
  width: 28px;
  height: 28px;
  border: 8px solid var(--ink);
  border-right-color: var(--green);
  border-bottom-color: var(--amber);
  transform: rotate(45deg);
}

.nav {
  gap: clamp(14px, 3vw, 34px);
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 600;
}

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

.hero {
  min-height: calc(100svh - 72px);
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(320px, 0.98fr);
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
  padding: clamp(36px, 6vw, 86px) clamp(20px, 5vw, 72px) clamp(30px, 5vw, 72px);
}

.hero-copy {
  max-width: 660px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--green-dark);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: clamp(4.8rem, 17vw, 13rem);
  line-height: 0.78;
  font-weight: 800;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: clamp(2rem, 4.2vw, 4.9rem);
  line-height: 0.98;
  letter-spacing: 0;
}

h3 {
  margin: 0;
  font-size: 1.14rem;
  letter-spacing: 0;
}

.hero-lede {
  max-width: 560px;
  margin: 30px 0 0;
  color: #414942;
  font-size: clamp(1.05rem, 1.8vw, 1.34rem);
}

.hero-actions {
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-weight: 800;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

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

.button.primary {
  border-color: var(--ink);
  background: var(--ink);
  color: #fffaf0;
}

.button.secondary {
  background: rgba(255, 255, 255, 0.58);
}

.hero-visual {
  position: relative;
  min-height: 520px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background:
    linear-gradient(120deg, rgba(255, 250, 240, 0.9), rgba(255, 255, 255, 0.34)),
    repeating-linear-gradient(90deg, rgba(32, 35, 31, 0.04) 0 1px, transparent 1px 72px),
    repeating-linear-gradient(0deg, rgba(32, 35, 31, 0.04) 0 1px, transparent 1px 72px);
  box-shadow: var(--shadow);
}

#signalCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.probe {
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 3px solid #fffaf0;
  box-shadow: 0 0 0 1px rgba(32, 35, 31, 0.18), 0 12px 30px rgba(32, 35, 31, 0.18);
}

.probe-a {
  left: 18%;
  top: 22%;
  background: var(--green);
}

.probe-b {
  right: 20%;
  top: 35%;
  background: var(--amber);
}

.probe-c {
  left: 45%;
  bottom: 20%;
  background: var(--blue);
}

.section {
  padding: clamp(58px, 9vw, 120px) clamp(20px, 5vw, 72px);
}

.band {
  background: rgba(255, 250, 240, 0.58);
  border-block: 1px solid rgba(32, 35, 31, 0.08);
}

.section-head {
  max-width: 870px;
  margin-bottom: clamp(24px, 5vw, 48px);
}

.section-head p:not(.eyebrow) {
  max-width: 520px;
  color: var(--muted);
}

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

.project-card,
.note,
.terminal,
.metric-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 18px 50px rgba(44, 38, 29, 0.08);
}

.project-card {
  min-height: 310px;
  padding: 22px;
}

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

.project-meta {
  gap: 8px;
  margin-bottom: 48px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}

.status-dot.live,
.timeline .ok {
  background: var(--green);
}

.status-dot.planned,
.timeline .warn {
  background: var(--amber);
}

.status-dot.quiet {
  background: var(--blue);
}

.project-card p,
.note p {
  color: var(--muted);
}

dl {
  display: grid;
  gap: 12px;
  margin: 28px 0 0;
}

dl div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid rgba(32, 35, 31, 0.1);
  padding-top: 12px;
}

dt {
  color: var(--muted);
  font-weight: 700;
}

dd {
  margin: 0;
  text-align: right;
  font-weight: 800;
}

.split {
  display: grid;
  grid-template-columns: minmax(240px, 0.72fr) minmax(0, 1.28fr);
  gap: clamp(26px, 5vw, 76px);
}

.sticky-head {
  position: sticky;
  top: 108px;
  align-self: start;
}

.note-list {
  display: grid;
  gap: 14px;
}

.note {
  padding: 24px;
}

.note time {
  display: block;
  margin-bottom: 14px;
  color: var(--green-dark);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.78rem;
  font-weight: 600;
}

.status-section {
  background: #eef2e9;
  border-block: 1px solid rgba(32, 35, 31, 0.08);
}

.status-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  gap: 16px;
}

.terminal {
  overflow: hidden;
  background: #20231f;
  color: #eef2e9;
}

.terminal-bar {
  display: flex;
  gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.terminal-bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d6d0c3;
}

.terminal-bar span:nth-child(2) {
  background: var(--amber);
}

.terminal-bar span:nth-child(3) {
  background: var(--green);
}

pre {
  margin: 0;
  padding: clamp(20px, 3vw, 34px);
  overflow-x: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: clamp(0.82rem, 1.7vw, 1rem);
  line-height: 1.75;
}

.metric-panel {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 22px;
}

.metric {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(32, 35, 31, 0.1);
}

.metric span {
  color: var(--muted);
  font-weight: 700;
}

.metric strong {
  font-size: 1.45rem;
}

.timeline {
  display: grid;
  grid-template-columns: repeat(21, 1fr);
  gap: 5px;
  padding-top: 12px;
}

.timeline span {
  min-height: 42px;
  border-radius: 4px;
}

.contact {
  justify-content: space-between;
  gap: 24px;
}

.contact h2 {
  max-width: 900px;
}

.footer {
  justify-content: space-between;
  gap: 20px;
  padding: 26px clamp(20px, 5vw, 72px);
  border-top: 1px solid rgba(32, 35, 31, 0.1);
  color: var(--muted);
  font-weight: 700;
}

@media (max-width: 980px) {
  .hero,
  .split,
  .status-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .hero-visual {
    min-height: 420px;
    order: -1;
  }

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

  .sticky-head {
    position: static;
  }
}

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

  .nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  h1 {
    font-size: clamp(4rem, 23vw, 7.4rem);
  }

  .hero-visual {
    min-height: 320px;
  }

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

  .button {
    width: 100%;
  }

  dl div,
  .metric {
    align-items: flex-start;
    flex-direction: column;
  }

  dd {
    text-align: left;
  }
}
