/* ============ LocalGov Suite — applied8 ============ */
:root {
  --bg: #04070f;
  --bg2: #070d1a;
  --panel: rgba(10, 18, 34, 0.72);
  --panel-solid: #0a1222;
  --line: rgba(64, 100, 150, 0.22);
  --line-strong: rgba(94, 140, 196, 0.38);
  --ink: #e8eef7;
  --ink-dim: #93a5bd;
  --ink-faint: #5c6f8a;
  --mint: #00e6a8;
  --mint-soft: rgba(0, 230, 168, 0.14);
  --gold: #f5c96b;
  --gold-soft: rgba(245, 201, 107, 0.12);
  --serif: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --sans: 'Inter', system-ui, -apple-system, sans-serif;
  --mono: 'Space Grotesk', ui-monospace, monospace;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
::selection { background: var(--mint); color: #03120c; }

/* ---- 3D canvas + grid overlay ---- */
#hero3d {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  z-index: 0;
  display: block;
}
.grid-overlay {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(70,110,160,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(70,110,160,0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 30%, transparent 75%);
}

/* content above canvas */
header, main, footer { position: relative; z-index: 1; }

/* veils so text always reads over the scene */
main { background: transparent; }
.section, .cta-band, footer {
  background: linear-gradient(180deg, rgba(4,7,15,0.88), rgba(4,7,15,0.94));
  backdrop-filter: blur(6px);
}
.hero { background: transparent; }

/* ---- header ---- */
#site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px clamp(20px, 5vw, 64px);
  transition: background .35s ease, border-color .35s ease, padding .35s ease;
  border-bottom: 1px solid transparent;
}
#site-header.scrolled {
  background: rgba(4, 7, 15, 0.8);
  backdrop-filter: blur(14px) saturate(1.4);
  border-bottom-color: var(--line);
  padding-top: 12px; padding-bottom: 12px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-glyph { width: 30px; height: 30px; }
.bg-line { stroke: var(--mint); stroke-width: 4.5; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.bg-bar { fill: #2b4a6f; }
.bg-bar.gold { fill: var(--gold); }
.brand-name {
  font-family: var(--serif); font-weight: 700; font-size: 19px;
  color: var(--ink); letter-spacing: .01em;
}
.brand-sub { color: var(--mint); font-weight: 500; font-size: 14px; margin-left: 2px; }
#site-header nav { display: flex; align-items: center; gap: clamp(14px, 2.6vw, 34px); }
#site-header nav a {
  color: var(--ink-dim); text-decoration: none; font-size: 14.5px; font-weight: 500;
  transition: color .2s;
}
#site-header nav a:hover { color: var(--ink); }
#site-header nav a.nav-cta {
  color: #03120c; background: var(--mint);
  padding: 8px 18px; border-radius: 8px; font-weight: 600;
  box-shadow: 0 0 0 rgba(0,230,168,0); transition: box-shadow .25s, transform .2s, background .2s;
}
#site-header nav a.nav-cta:hover { background: #2cf0bb; box-shadow: 0 6px 28px rgba(0,230,168,0.35); transform: translateY(-1px); }

/* ---- hero ---- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 120px clamp(20px, 6vw, 80px) 80px;
  max-width: 1200px;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 12.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--mint); margin-bottom: 26px;
  background: rgba(0,230,168,0.06); border: 1px solid rgba(0,230,168,0.25);
  padding: 7px 14px; border-radius: 999px; width: fit-content;
}
.pulse-dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--mint); flex: none;
  animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,230,168,.5); opacity: 1; }
  50% { box-shadow: 0 0 0 7px rgba(0,230,168,0); opacity: .65; }
}
.hero h1 {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(2.6rem, 6.4vw, 5.2rem);
  line-height: 1.04; letter-spacing: -0.02em;
  text-wrap: balance;
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(92deg, var(--mint) 10%, #6fe8ff 55%, var(--gold) 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.hero-lede {
  margin-top: 26px; max-width: 640px;
  font-size: clamp(1.02rem, 1.6vw, 1.18rem); color: var(--ink-dim);
}
.hero-actions { display: flex; gap: 14px; margin-top: 36px; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--sans); font-weight: 600; font-size: 15.5px;
  padding: 13px 26px; border-radius: 10px; text-decoration: none;
  transition: transform .18s ease, box-shadow .25s ease, background .2s, border-color .2s;
}
.btn-primary { background: var(--mint); color: #03120c; box-shadow: 0 8px 32px rgba(0,230,168,.22); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 44px rgba(0,230,168,.4); background: #2cf0bb; }
.btn-ghost { border: 1px solid var(--line-strong); color: var(--ink); background: rgba(10,18,34,.4); backdrop-filter: blur(4px); }
.btn-ghost:hover { border-color: var(--mint); color: var(--mint); transform: translateY(-2px); }
.trust-strip {
  list-style: none; display: flex; flex-wrap: wrap; gap: 8px 20px;
  margin-top: 56px; padding-top: 26px; border-top: 1px solid var(--line);
}
.trust-strip li {
  font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-dim);
  background: rgba(6, 12, 24, 0.55);
  border: 1px solid var(--line);
  padding: 5px 12px; border-radius: 999px;
  display: flex; align-items: center; gap: 8px;
  backdrop-filter: blur(4px);
}
.trust-strip li::before { content: '✓'; color: var(--mint); font-size: 11px; }
/* readability veils over the 3D scene */
.hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(100deg, rgba(4,7,15,.78) 0%, rgba(4,7,15,.42) 46%, transparent 72%);
}
.scroll-hint {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  color: var(--ink-faint); font-size: 13px; animation: bob 2.4s ease-in-out infinite;
}
@keyframes bob { 0%,100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 8px); } }

/* ---- sections ---- */
.section { padding: clamp(80px, 11vh, 140px) clamp(20px, 6vw, 80px); }
.section.alt { background: linear-gradient(180deg, rgba(7,13,26,.92), rgba(4,7,15,.95)); }
.section-head { max-width: 760px; margin-bottom: 56px; }
.kicker {
  font-family: var(--mono); font-size: 12.5px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 14px;
}
.section h2, .cta-band h2 {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(1.9rem, 4vw, 3rem); line-height: 1.1; letter-spacing: -0.015em;
  text-wrap: balance;
}
.section-lede { margin-top: 18px; color: var(--ink-dim); font-size: 1.06rem; max-width: 620px; }

/* ---- cards ---- */
.cards {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  max-width: 1280px;
}
.card {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 30px 28px 26px;
  overflow: hidden;
  transition: transform .28s cubic-bezier(.2,.7,.3,1), border-color .28s, box-shadow .28s;
}
.card::before { /* top hairline that lights up */
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--mint), transparent);
  opacity: 0; transition: opacity .3s;
}
.card:hover { transform: translateY(-5px); border-color: var(--line-strong); box-shadow: 0 24px 60px rgba(2, 8, 20, .6), 0 0 0 1px rgba(0,230,168,.08); }
.card:hover::before { opacity: .9; }
.card-icon { width: 44px; height: 44px; margin-bottom: 18px; }
.card-icon svg {
  width: 100%; height: 100%; stroke: var(--mint); fill: none;
  stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.card-icon svg .dim { stroke: var(--ink-faint); }
.card h3 { font-family: var(--serif); font-size: 1.34rem; font-weight: 700; letter-spacing: -0.01em; }
.card-domain {
  font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold); margin: 6px 0 14px;
}
.card p:not(.card-domain) { color: var(--ink-dim); font-size: .955rem; }
.card-link {
  display: inline-flex; align-items: center; gap: 7px;
  margin-top: 22px; padding-top: 16px; width: 100%;
  border-top: 1px solid var(--line);
  color: var(--mint); text-decoration: none; font-weight: 600; font-size: 14.5px;
  transition: gap .2s;
}
.card-link span { transition: transform .2s; }
.card-link:hover span { transform: translateX(4px); }

/* ---- pillars ---- */
.pillars { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); max-width: 1280px; }
.pillar {
  border: 1px solid var(--line); border-radius: 16px;
  background: linear-gradient(160deg, rgba(12,22,40,.75), rgba(6,11,22,.9));
  padding: 34px 30px;
  transition: border-color .3s, transform .3s;
}
.pillar:hover { border-color: rgba(245,201,107,.4); transform: translateY(-4px); }
.pillar-num {
  font-family: var(--mono); font-size: 13px; letter-spacing: .2em; color: var(--gold);
  margin-bottom: 18px;
}
.pillar h3 { font-family: var(--serif); font-size: 1.22rem; margin-bottom: 12px; }
.pillar p { color: var(--ink-dim); font-size: .96rem; }

/* ---- method ---- */
.method-grid {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(36px, 6vw, 90px);
  align-items: center; max-width: 1280px;
}
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px,1fr)); gap: 14px; margin-top: 40px; }
.stat {
  border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px;
  background: var(--panel);
}
.stat b {
  display: block; font-family: var(--serif); font-size: 2rem; font-weight: 700; color: var(--mint);
  line-height: 1.1;
}
.stat span { font-size: .82rem; color: var(--ink-faint); letter-spacing: .04em; }
.pipeline {
  border: 1px solid var(--line-strong); border-radius: 16px; overflow: hidden;
  background: rgba(6, 11, 22, .85);
  box-shadow: 0 30px 80px rgba(2,6,16,.55);
  font-family: var(--mono);
}
.pipe-row {
  display: grid; grid-template-columns: 110px 1fr; gap: 14px; align-items: center;
  padding: 16px 22px; border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.pipe-row:last-child { border-bottom: none; }
.pipe-key { color: var(--mint); text-transform: uppercase; letter-spacing: .12em; font-size: 11.5px; }
.pipe-val { color: var(--ink-dim); font-family: var(--sans); font-size: 14px; }
.pipe-arrow { text-align: center; color: var(--ink-faint); font-size: 12px; line-height: 1; padding: 2px 0; }
.pipe-row.lit { background: var(--mint-soft); }
.pipe-row.lit .pipe-val { color: var(--ink); }

/* ---- CTA ---- */
.cta-band {
  background:
    radial-gradient(ellipse 60% 90% at 50% 110%, rgba(0,230,168,0.07), transparent 65%),
    linear-gradient(180deg, rgba(4,7,15,.9), rgba(4,7,15,.96));
  text-align: center;
  padding-bottom: clamp(110px, 14vh, 170px);
}
.cta-inner { max-width: 680px; margin: 0 auto; }
.cta-band p { color: var(--ink-dim); font-size: 1.08rem; margin-top: 16px; }
.cta-band .hero-actions { justify-content: center; }

/* ---- footer ---- */
footer { border-top: 1px solid var(--line); padding: 30px clamp(20px, 6vw, 80px); }
.foot-inner {
  display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap;
  max-width: 1280px; margin: 0 auto;
  font-size: 13.5px; color: var(--ink-faint);
}
.foot-inner nav { display: flex; gap: 22px; }
.foot-inner nav a { color: var(--ink-dim); text-decoration: none; transition: color .2s; }
.foot-inner nav a:hover { color: var(--mint); }

/* ---- reveal animation ---- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.3,1); }
.reveal.in { opacity: 1; transform: none; }
.card.reveal.in:nth-child(2) { transition-delay: .07s; }
.card.reveal.in:nth-child(3) { transition-delay: .14s; }
.card.reveal.in:nth-child(4) { transition-delay: .07s; }
.card.reveal.in:nth-child(5) { transition-delay: .14s; }
.card.reveal.in:nth-child(6) { transition-delay: .21s; }

/* ---- responsive ---- */
@media (max-width: 900px) {
  .method-grid { grid-template-columns: 1fr; }
  #site-header nav a:not(.nav-cta) { display: none; }
}
@media (max-width: 560px) {
  .trust-strip { gap: 6px 14px; }
  .hero { padding-top: 100px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .pulse-dot, .scroll-hint { animation: none; }
}
