:root {
  color-scheme: dark;
  --bg: #0e1411;
  --surface: #161e19;
  --text: #f4f6ed;
  --muted: #b8c5b9;
  --lime: #bfef76;
  --line: #344037;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); line-height: 1.65; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid var(--lime); outline-offset: 5px; }
img { display: block; max-width: 100%; }
p, h1, h2, h3 { margin: 0; }
p { color: var(--muted); }
h1, h2, h3 { line-height: 1.04; letter-spacing: -.055em; }
h2 { font-size: clamp(2.2rem, 4.1vw, 3.65rem); }
section[id] { scroll-margin-top: 1.5rem; }
.shell { width: min(calc(100% - 72px), 1280px); margin-inline: auto; }
.skip { position: fixed; left: 1rem; top: 1rem; z-index: 5; transform: translateY(-200%); background: var(--lime); color: var(--bg); padding: .5rem 1rem; }
.skip:focus { transform: none; }

.site-header {
  min-height: 82px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1.5rem;
  align-items: center;
}
.brand { display: inline-flex; align-items: center; gap: .65rem; width: fit-content; font-size: 1.35rem; font-weight: 850; letter-spacing: -.06em; }
.accent { color: var(--lime); }
nav { display: flex; justify-content: center; gap: clamp(1rem, 3.5vw, 2.75rem); }
nav a, .network-link { color: var(--muted); font-size: .93rem; font-weight: 650; }
nav a:hover, .network-link:hover { color: var(--lime); }
.network-link { justify-self: end; padding: .48rem .84rem; border: 1px solid var(--line); border-radius: .4rem; }

.hero {
  isolation: isolate;
  position: relative;
  min-height: 540px;
  overflow: hidden;
  display: grid;
  align-items: center;
  padding: 4.75rem clamp(2rem, 6vw, 6rem) 5.5rem;
  border: 1px solid #34443b;
  border-radius: 1.15rem;
  background: linear-gradient(90deg, #111b16 0%, #15271f 64%, #203229 100%);
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: linear-gradient(90deg, #101814 2%, #101814f7 22%, #101814a6 52%, #10181414 82%), linear-gradient(0deg, #101814d6, transparent 40%), url("antenna.webp");
  background-position: center, center, right center;
  background-repeat: no-repeat;
  background-size: cover, cover, max(79%, 850px) auto;
}
.hero-content { max-width: 850px; }
.label { display: flex; align-items: center; gap: .6rem; color: var(--lime); font: 650 .875rem/1.4 var(--mono); letter-spacing: .09em; text-transform: uppercase; }
.label span { width: 1.55rem; height: 1px; background-color: var(--lime); }
h1 { margin: 1.45rem 0; font-size: clamp(3rem, 6.3vw, 6.1rem); line-height: .98; }
h1 em { font-style: normal; color: var(--lime); }
.intro { max-width: 510px; font-size: clamp(1rem, 1.4vw, 1.18rem); }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.9rem; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .65rem 1.15rem; border: 1px solid transparent; border-radius: .45rem; font-weight: 750; }
.primary { background: var(--lime); border-color: var(--lime); color: #142012; }
.primary:hover { background: #daf7af; }
.secondary { background: #101814ba; border-color: #5d7162; }
.secondary:hover { border-color: var(--lime); }
.hero-note { position: absolute; right: clamp(1.5rem, 3vw, 2.75rem); bottom: 1.4rem; color: #d0dfd2; font: .875rem/1.5 var(--mono); }

.section { padding-block: clamp(3.5rem, 7vw, 6.5rem); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem 2rem; margin-bottom: 1.75rem; }
.section-heading p { max-width: 365px; }
.projects { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.project { display: grid; grid-template-rows: auto 1fr; border: 1px solid var(--line); border-radius: .95rem; overflow: hidden; background: var(--surface); }
.alert { --project-accent: #ff8e95; --project-tint: #172733; }
.meshis { --project-accent: #cab1ff; --project-tint: #27223c; }
.project-image { display: grid; justify-items: center; overflow: hidden; aspect-ratio: 2.1; background: radial-gradient(ellipse at center, var(--project-tint), #11171b 78%); }
.project-image img { width: auto; height: 100%; max-width: 100%; min-height: 0; object-fit: contain; }
.project-info { padding: clamp(1.3rem, 3vw, 2.35rem); display: flex; flex-direction: column; align-items: start; border-top: 1px solid var(--line); }
.project-type { color: var(--project-accent); font: 650 .875rem/1.4 var(--mono); }
.project h3 { font-size: clamp(2rem, 3.4vw, 3rem); margin: .55rem 0 .85rem; }
.project-link { color: var(--project-accent); font-weight: 750; padding-top: 1.15rem; margin-top: auto; text-decoration: underline; text-underline-offset: 5px; }
.project-link:hover { color: var(--text); }

.mesh-section { background: var(--surface); border-block: 1px solid var(--line); }
.network { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: clamp(2rem, 7vw, 7rem); padding-block: clamp(3rem, 7vw, 6rem); }
.network h2 { margin: .9rem 0 1rem; }
.roles { padding: clamp(1.2rem, 3.5vw, 2.1rem); border: 1px solid var(--line); border-radius: .75rem; background: var(--bg); }
.roles ol { list-style: none; margin: 0; padding: 0; }
.roles li { position: relative; padding: .45rem 0 .45rem 1.5rem; display: flex; justify-content: space-between; align-items: center; gap: .75rem 1rem; }
.roles li::before { position: absolute; content: ""; left: 0; width: .55rem; height: .55rem; background: var(--lime); border-radius: 50%; z-index: 1; }
.roles li:not(:last-child)::after { position: absolute; content: ""; left: .24rem; top: 50%; height: 100%; width: 1px; background: #687d56; }
.roles li span { color: var(--muted); font-size: .9rem; }
.roles p { font-size: .875rem; border-top: 1px solid var(--line); margin-top: .85rem; padding-top: .85rem; }
.join { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem 3rem; padding-block: clamp(3rem, 7vw, 5.5rem); }
.join p { max-width: 650px; margin-top: .9rem; }
.join .button { flex-shrink: 0; }

.site-footer { border-top: 1px solid var(--line); }
.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem 1.5rem; color: var(--muted); padding-block: 1.5rem; font-size: .9rem; }
.footer-inner .brand { color: var(--text); }

@media (max-width: 750px) {
  .shell { width: calc(100% - 32px); }
  .site-header { grid-template-columns: 1fr 1fr; gap: 0 .5rem; padding-top: .6rem; }
  .site-header nav { grid-row: 2; grid-column: 1 / -1; justify-content: start; gap: 1.6rem; padding-block: .8rem; flex-wrap: wrap; }
  .network-link { grid-column: 2; grid-row: 1; }
  .hero { min-height: 485px; padding: 2.9rem 1.25rem 4.65rem; }
  .hero::after {
    background-image: linear-gradient(90deg, #101814f7, #10181470), linear-gradient(0deg, #101814, transparent 58%), url("antenna.webp");
    background-position: center, center, 67% center;
    background-size: cover;
  }
  .hero-note { right: auto; left: 1.25rem; bottom: 1.05rem; }
  .section-heading, .join { flex-direction: column; align-items: start; }
  .projects, .network { grid-template-columns: minmax(0, 1fr); }
}

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

.bot-intro { display: grid; grid-template-columns: 1.25fr 1fr; gap: 3rem; align-items: center; padding-bottom: clamp(3.5rem, 7vw, 6.5rem); }
.bot-intro h2 { margin: .8rem 0 1rem; }
.bot-intro p:not(.label) { max-width: 580px; }
.bot-intro .button { margin-top: 1.4rem; }
.bot-teaser { display: grid; gap: 1rem; padding: clamp(1.5rem, 4vw, 3rem); border: 1px solid var(--line); border-radius: .95rem; background: var(--surface); }
.bot-teaser span { color: var(--muted); }
.bot-teaser span:first-child { font: 1rem var(--mono); color: var(--lime); }
.bot-teaser code { font: 600 clamp(2.4rem, 5vw, 4.2rem) var(--mono); }
.bot-teaser:hover { border-color: var(--lime); }
@media (max-width: 950px) {
  .site-header { grid-template-columns: 1fr 1fr; gap: 0 .5rem; padding-top: .6rem; }
  .site-header nav { grid-row: 2; grid-column: 1 / -1; justify-content: start; gap: .6rem 1.6rem; padding-block: .8rem; flex-wrap: wrap; }
  .network-link { grid-column: 2; grid-row: 1; }
}
@media (max-width: 750px) { .bot-intro { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; } }
