/* Gnom-Hub product site — local multi-agent desk */
@import url("https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=IBM+Plex+Mono:wght@400;500;600&display=swap");

:root {
  --bg: #0f1410;
  --bg2: #151c16;
  --panel: #1a231c;
  --panel2: #222c24;
  --line: #2e3a30;
  --line2: #3d4d40;
  --fg: #e8efe6;
  --muted: #8fa392;
  --dim: #5c6b5e;
  --leaf: #6dcf7a;
  --leaf-dim: #2d6a38;
  --moss: #a8c97a;
  --warn: #e8b84a;
  --bad: #e85d5d;
  --sky: #7eb8c9;
  --font: "DM Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --max: 1040px;
  --radius: 12px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--fg);
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 70% 45% at 20% -10%, rgba(109, 207, 122, 0.1), transparent 55%),
    radial-gradient(ellipse 50% 35% at 100% 60%, rgba(168, 201, 122, 0.05), transparent 50%);
}
a { color: var(--leaf); text-decoration: underline; text-underline-offset: 0.18em; }
a:hover { color: #9ae8a4; }
code {
  font-family: var(--mono);
  font-size: 0.88em;
  background: rgba(109, 207, 122, 0.08);
  border: 1px solid var(--leaf-dim);
  padding: 0.08rem 0.35rem;
  border-radius: 4px;
  color: var(--moss);
}

.shell {
  position: relative;
  z-index: 1;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.2rem;
}

/* Nav */
.top {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(12px);
  background: rgba(15, 20, 16, 0.9);
  border-bottom: 1px solid var(--line);
}
.top-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.75rem 1.2rem;
  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.02em;
  color: var(--fg);
  text-decoration: none;
  font-size: 1.05rem;
}
.brand:hover { color: var(--leaf); text-decoration: none; }
.brand svg { display: block; }
.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem;
  align-items: center;
  justify-content: flex-end;
}
.nav a {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  padding: 0.4rem 0.65rem;
  border-radius: 8px;
}
.nav a:hover { color: var(--fg); background: var(--panel); }
.nav a.cta {
  background: var(--leaf);
  color: #0a100c;
  margin-left: 0.25rem;
}
.nav a.cta:hover { background: #9ae8a4; color: #0a100c; }
.nav a.lang {
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.75rem;
  padding: 0.28rem 0.55rem;
}

/* Hero */
.hero {
  padding: 3.5rem 0 2rem;
  text-align: center;
}
.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--moss);
  border: 1px solid var(--leaf-dim);
  background: rgba(109, 207, 122, 0.08);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  margin-bottom: 1.15rem;
}
.kicker .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--leaf);
  box-shadow: 0 0 8px var(--leaf);
}
.hero h1 {
  font-size: clamp(1.9rem, 5vw, 2.85rem);
  line-height: 1.12;
  letter-spacing: -0.03em;
  margin: 0 0 1rem;
  font-weight: 700;
  max-width: 18ch;
  margin-left: auto;
  margin-right: auto;
}
.hero h1 em {
  font-style: normal;
  color: var(--leaf);
}
.lead {
  font-size: clamp(1.05rem, 2.2vw, 1.2rem);
  color: var(--muted);
  max-width: 34rem;
  margin: 0 auto 1.5rem;
}
.lead strong { color: var(--fg); font-weight: 600; }
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  justify-content: center;
  margin-bottom: 1.25rem;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font: inherit;
  font-weight: 700;
  font-size: 0.92rem;
  padding: 0.7rem 1.15rem;
  border-radius: 10px;
  border: 1px solid var(--line2);
  background: transparent;
  color: var(--fg);
  text-decoration: none;
  cursor: pointer;
  transition: 0.12s ease;
}
.btn:hover { border-color: var(--leaf); color: var(--leaf); text-decoration: none; }
.btn.primary {
  background: var(--leaf);
  border-color: var(--leaf);
  color: #0a100c;
}
.btn.primary:hover { background: #9ae8a4; color: #0a100c; border-color: #9ae8a4; }
.btn.sm { font-size: 0.8rem; padding: 0.45rem 0.75rem; }
.btn.copied { background: var(--leaf) !important; color: #0a100c !important; }

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  justify-content: center;
  list-style: none;
  margin: 0;
  padding: 0;
}
.tags li {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
}

/* Rule strip */
.rule {
  max-width: 36rem;
  margin: 0 auto 2.5rem;
  padding: 1rem 1.25rem;
  border-left: 3px solid var(--leaf);
  background: var(--panel);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.4;
  text-align: left;
}
.rule cite {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.85rem;
  font-weight: 500;
  font-style: normal;
  color: var(--muted);
}

/* Sections */
.sec {
  padding: 2.75rem 0;
  border-top: 1px solid var(--line);
}
.sec-label {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim);
  margin: 0 0 0.5rem;
}
.sec h2 {
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  margin: 0 0 0.55rem;
  letter-spacing: -0.02em;
}
.sec-lead {
  color: var(--muted);
  max-width: 36rem;
  margin: 0 0 1.5rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}
@media (max-width: 800px) { .grid-3 { grid-template-columns: 1fr; } }
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem;
}
.card h3 { margin: 0 0 0.4rem; font-size: 1.05rem; }
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; }
.card .num {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--leaf);
  letter-spacing: 0.08em;
  margin-bottom: 0.45rem;
}

/* Flow */
.flow {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr;
  gap: 0.5rem;
  align-items: stretch;
}
@media (max-width: 700px) {
  .flow { grid-template-columns: 1fr; }
  .flow .arr { display: none; }
}
.flow .box {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem;
  text-align: center;
}
.flow .box strong { display: block; margin-bottom: 0.25rem; }
.flow .box span { font-size: 0.85rem; color: var(--muted); }
.flow .arr {
  display: grid;
  place-items: center;
  color: var(--dim);
  font-size: 1.2rem;
}
.flow .box.hi {
  border-color: var(--leaf-dim);
  background: rgba(109, 207, 122, 0.08);
}

/* Shot */
.shot {
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
}
.shot img {
  display: block;
  width: 100%;
  height: auto;
}
.shot figcaption {
  padding: 0.75rem 1rem;
  font-size: 0.88rem;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.split {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 1.5rem;
  align-items: start;
}
@media (max-width: 800px) { .split { grid-template-columns: 1fr; } }

.term {
  background: #0a0e0b;
  border: 1px solid var(--line2);
  border-radius: var(--radius);
  overflow: hidden;
}
.term-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.85rem;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--dim);
  background: var(--panel);
}
.term pre {
  margin: 0;
  padding: 1rem;
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.6;
  overflow-x: auto;
  color: #c5d4c0;
  cursor: text;
  user-select: text;
}
.term .c { color: var(--dim); }
.term .g { color: var(--leaf); }
.term .s { color: var(--moss); }

.list-check {
  list-style: none;
  margin: 0;
  padding: 0;
}
.list-check li {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  display: grid;
  grid-template-columns: 1.2rem 1fr;
  gap: 0.5rem;
}
.list-check li:last-child { border-bottom: 0; }
.list-check li::before {
  content: "✓";
  color: var(--leaf);
  font-weight: 700;
}
.list-check strong { color: var(--fg); }

/* Compare */
table.cmp {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
table.cmp th, table.cmp td {
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--line);
}
table.cmp th {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--dim);
  background: var(--panel2);
}
table.cmp tr:last-child td { border-bottom: 0; }
table.cmp .yes { color: var(--leaf); font-weight: 700; }
table.cmp .no { color: var(--dim); }

/* Footer */
.foot {
  border-top: 1px solid var(--line);
  padding: 2rem 0 2.5rem;
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--muted);
}
.foot-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.25rem;
}
.foot strong { color: var(--fg); display: block; margin-bottom: 0.25rem; }
.foot-links { display: flex; flex-wrap: wrap; gap: 0.85rem; }
.foot-links a { color: var(--muted); text-decoration: none; }
.foot-links a:hover { color: var(--leaf); }

/* SEO helper: visually hidden but crawlable */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

.toast {
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  z-index: 200;
  background: var(--panel2);
  border: 1px solid var(--line2);
  color: var(--fg);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 0.65rem 1.1rem;
  border-radius: 999px;
  opacity: 0;
  transition: 0.25s ease;
  pointer-events: none;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.reveal {
  opacity: 0;
  transform: translateY(10px);
  transition: 0.45s ease;
}
.reveal.visible { opacity: 1; transform: none; }

.doc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 0.55rem;
}
.doc-link {
  display: block;
  padding: 0.9rem 1rem;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--fg);
  text-decoration: none;
}
.doc-link:hover { border-color: var(--leaf); text-decoration: none; }
.doc-link strong { display: block; color: var(--leaf); margin-bottom: 0.25rem; font-size: 0.9rem; }
.doc-link span { color: var(--muted); font-size: 0.88rem; }
.search-box {
  width: 100%;
  max-width: 28rem;
  margin: 1rem 0 0;
  padding: 0.7rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--fg);
  font: inherit;
}
.search-box:focus { outline: none; border-color: var(--leaf); }

.center-page {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 2rem;
}
