:root {
  --bg: #f5f7f4;
  --bg-soft: #edf1eb;
  --panel: rgba(255, 255, 255, 0.9);
  --panel-strong: #ffffff;
  --panel-muted: #eef2ed;
  --line: rgba(12, 16, 13, 0.1);
  --line-strong: rgba(12, 16, 13, 0.22);
  --text: #090c0a;
  --text-soft: #1a211c;
  --muted: #5f6a62;
  --brand: #0f8f4d;
  --brand-deep: #0a5a31;
  --brand-soft: rgba(15, 143, 77, 0.1);
  --warning: #5d7b25;
  --shadow: 0 26px 70px rgba(8, 12, 10, 0.09);
  --shadow-soft: 0 14px 32px rgba(8, 12, 10, 0.05);
  --radius: 0;
  --radius-soft: 0;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  background:
    linear-gradient(135deg, rgba(15, 143, 77, 0.06), transparent 28%),
    linear-gradient(180deg, #f7faf6 0%, #f1f4ef 40%, #e8ede8 100%);
  font-family: "Suisse Intl", "Neue Haas Grotesk Text Pro", "Avenir Next", "SF Pro Text", sans-serif;
  font-size: 15px;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(rgba(8, 12, 10, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(8, 12, 10, 0.03) 1px, transparent 1px);
  background-size: 88px 88px;
  mask-image: linear-gradient(180deg, black, transparent 78%);
  opacity: 0.4;
}

button, input, textarea, select { font: inherit; }
a { color: inherit; text-decoration: none; transition: color 180ms ease, border-color 180ms ease, background-color 180ms ease, transform 180ms ease, box-shadow 180ms ease; }
.container { width: min(1180px, calc(100vw - 64px)); margin: 0 auto; }
.page-shell { position: relative; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(245, 247, 244, 0.88);
  backdrop-filter: blur(18px) saturate(110%);
  border-bottom: 1px solid rgba(8, 12, 10, 0.08);
}
.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 78px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: #09100b;
  border: 1px solid rgba(15, 143, 77, 0.45);
  color: #f4fff8;
  font-size: 0.82rem;
  font-weight: 800;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.06);
}
.brand strong {
  display: block;
  font-size: 0.94rem;
  letter-spacing: -0.025em;
}
.brand small {
  display: block;
  color: var(--muted);
  margin-top: 2px;
  font-size: 0.74rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.main-nav, .header-actions, .button-row, .stat-row {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.main-nav a, .lang-switch {
  color: var(--muted);
  padding: 8px 0;
  border-bottom: 1px solid transparent;
  font-size: 0.83rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.main-nav a:hover, .main-nav a.active, .lang-switch:hover {
  color: var(--text);
  border-color: rgba(8, 12, 10, 0.32);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(15, 143, 77, 0.4);
  background: linear-gradient(180deg, #128f50, #0c713f);
  color: #f5fff8;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(15, 143, 77, 0.12);
}
.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 34px rgba(15, 143, 77, 0.18);
}
.button-secondary,
.button-ghost {
  background: rgba(255, 255, 255, 0.6);
  color: var(--text);
  border: 1px solid rgba(8, 12, 10, 0.14);
  box-shadow: none;
}
.button-secondary:hover,
.button-ghost:hover {
  background: #fff;
  box-shadow: var(--shadow-soft);
}
.button-ghost {
  background: transparent;
}

.hero, .page-hero { padding: 104px 0 44px; }
.page-hero { padding: 82px 0 34px; }
.page-hero.compact { padding-bottom: 22px; }
.hero-grid, .split-grid, .docs-header, .docs-shell, .footer-grid { display: grid; gap: 28px; }
.hero-grid { grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr); align-items: stretch; }
.hero h1, .page-hero h1 {
  margin: 0 0 20px;
  max-width: 10ch;
  color: #090c0a;
  font-family: "Canela", "Ivar Display", "Iowan Old Style", Georgia, serif;
  font-size: clamp(3.4rem, 7vw, 6.4rem);
  line-height: 0.9;
  letter-spacing: -0.075em;
}
.page-hero h1 {
  max-width: 18ch;
  font-size: clamp(2.1rem, 3.5vw, 3rem);
  line-height: 0.95;
}
.hero-copy, .page-hero p, .muted, .footer-grid p {
  color: var(--muted);
  line-height: 1.72;
  font-size: 0.96rem;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 6px 10px;
  margin: 0 0 18px;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--brand-deep);
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(15, 143, 77, 0.18);
}

.home-hero {
  position: relative;
  overflow: hidden;
}
.home-hero::after {
  content: '';
  position: absolute;
  inset: auto 0 0 0;
  height: 160px;
  background: linear-gradient(180deg, transparent, rgba(8, 12, 10, 0.04));
  pointer-events: none;
}
.hero-main {
  padding-right: 20px;
}
.hero-actions {
  margin-top: 28px;
}
.command-panel {
  display: grid;
  gap: 14px;
}
.signal-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.signal-strip div,
.stat-row div {
  min-width: 140px;
  padding: 16px 16px 14px;
  background: rgba(255,255,255,0.72);
  border: 1px solid rgba(8, 12, 10, 0.08);
}
.signal-strip strong,
.stat-row strong {
  display: block;
  margin-bottom: 6px;
  font-size: 0.92rem;
  letter-spacing: -0.02em;
}
.signal-strip span,
.stat-row span {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.terminal-card, .feature-card, .comparison-card, .plan-card, .log-card, .auth-card, .cta-banner, .doc-section, .docs-nav, .docs-cta-box {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}
.terminal-card, .feature-card, .comparison-card, .plan-card, .log-card, .doc-section, .docs-cta-box { padding: 24px; }
.terminal-card {
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.96), rgba(239,243,239,0.94));
  border-color: rgba(8, 12, 10, 0.12);
  box-shadow: 0 28px 68px rgba(8, 12, 10, 0.1);
}
.terminal-card::after, .comparison-card::after, .cta-banner::after, .feature-card::after, .plan-card.selected::after {
  content: '';
  position: absolute;
  inset: 0 auto auto 0;
  width: 44%;
  height: 2px;
  background: linear-gradient(90deg, rgba(15, 143, 77, 0.62), transparent);
}
.terminal-header { display: flex; gap: 7px; margin-bottom: 13px; }
.terminal-header span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(8, 12, 10, 0.16);
}
pre {
  margin: 0;
  overflow: auto;
  padding: 24px;
  background: #09100b;
  color: #dbf8e8;
  border: 1px solid rgba(255,255,255,0.06);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
  font-size: 0.86rem;
  line-height: 1.78;
}

.section { padding: 54px 0 92px; }
.section-alt {
  background: linear-gradient(180deg, rgba(255,255,255,0.32), rgba(255,255,255,0.12));
  border-top: 1px solid rgba(8, 12, 10, 0.05);
  border-bottom: 1px solid rgba(8, 12, 10, 0.05);
}
.section-heading {
  max-width: 700px;
  margin-bottom: 28px;
}
.section-heading h2, .comparison-card h2, .doc-section h2, .log-card h2, .auth-card h1 {
  margin: 0 0 12px;
  color: #090c0a;
  font-family: "Canela", "Ivar Display", "Iowan Old Style", Georgia, serif;
  font-size: clamp(1.9rem, 3.3vw, 3rem);
  line-height: 0.98;
  letter-spacing: -0.06em;
}

.section-proof .proof-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.66fr) minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}
.sticky-heading {
  position: sticky;
  top: 108px;
}
.feature-grid, .plan-grid, .comparison-grid, .log-list { display: grid; gap: 18px; }
.feature-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.plan-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.plan-grid-home { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.comparison-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.log-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.proof-cards { align-content: start; }

.feature-card h3, .plan-card h3 {
  margin: 0 0 10px;
  font-size: 1.06rem;
  line-height: 1.16;
  letter-spacing: -0.035em;
}
.feature-card p, .plan-card p, .log-card p, .doc-section p, .comparison-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.91rem;
  line-height: 1.64;
}
.feature-card,
.plan-card,
.log-card,
.doc-section,
.docs-cta-box,
.comparison-card {
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,0.94), rgba(241,244,240,0.88));
}
.feature-card:hover,
.plan-card:hover,
.log-card:hover,
.doc-section:hover,
.docs-cta-box:hover,
.comparison-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}
.card-index {
  display: inline-block;
  margin-bottom: 18px;
  color: var(--brand);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
}

.check-list, .request-list {
  list-style: none;
  padding: 0;
  margin: 18px 0 0;
  display: grid;
  gap: 11px;
}
.check-list li, .request-list li {
  position: relative;
  padding-left: 22px;
  color: var(--text-soft);
  line-height: 1.6;
}
.check-list li::before, .request-list li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--brand);
  font-size: 1.15rem;
  line-height: 1;
}

.plan-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 100%;
  background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(240,244,239,0.9));
}
.plan-card.selected {
  border-color: rgba(15, 143, 77, 0.34);
  box-shadow: 0 18px 42px rgba(15, 143, 77, 0.12);
}
.plan-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}
.plan-price {
  margin: 0;
  color: var(--text);
  font-size: 1.86rem;
  font-weight: 800;
  letter-spacing: -0.055em;
}
.plan-price span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.plan-cta-label {
  margin-top: 18px !important;
  font-weight: 700;
  color: var(--brand-deep) !important;
}
.dashboard-plan-form { display: block; }

.home-commercial .commercial-copy {
  max-width: 480px;
}
.cta-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 22px;
  padding: 30px;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(239,243,239,0.92));
}
.final-section .cta-banner p {
  max-width: 520px;
}
.stat-row {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.docs-shell {
  grid-template-columns: 240px minmax(0, 1fr);
  align-items: start;
}
.docs-nav {
  position: sticky;
  top: 92px;
  padding: 14px;
  background: rgba(255,255,255,0.8);
}
.docs-nav a {
  display: block;
  padding: 10px 9px;
  color: var(--muted);
  font-size: 0.83rem;
  letter-spacing: 0.02em;
}
.docs-nav a:hover {
  background: rgba(15, 143, 77, 0.05);
  color: var(--text);
}
.docs-content { display: grid; gap: 20px; }
.log-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  color: var(--brand-deep);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.auth-wrap {
  min-height: calc(100vh - 320px);
  display: flex;
  align-items: center;
}
.auth-card-wrap { display: grid; place-items: center; }
.auth-card {
  width: min(520px, 100%);
  padding: 30px;
  background: rgba(255,255,255,0.96);
  border: 1px solid rgba(8, 12, 10, 0.08);
  box-shadow: 0 20px 48px rgba(8, 12, 10, 0.08);
}
.auth-card label {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.87rem;
}
.auth-card input {
  width: 100%;
  border: 1px solid rgba(8, 12, 10, 0.12);
  background: #fff;
  color: var(--text);
  padding: 13px 14px;
  outline: none;
}
.auth-card input:focus {
  border-color: rgba(15, 143, 77, 0.44);
  box-shadow: 0 0 0 4px rgba(15, 143, 77, 0.08);
}
.auth-card .button {
  width: 100%;
  margin-top: 20px;
}
.notice {
  margin: 12px 0 16px;
  padding: 12px 14px;
  background: rgba(15, 143, 77, 0.065);
  border: 1px solid rgba(15, 143, 77, 0.12);
  color: var(--text-soft);
  font-size: 0.9rem;
}
.firebase-note { font-size: 0.88rem; }
.request-list li { display: grid; gap: 2px; }
.request-list strong, .request-list span { display: block; }
.request-list small { color: var(--muted); }

.site-footer {
  padding: 34px 0 38px;
  border-top: 1px solid rgba(8, 12, 10, 0.08);
}
.footer-grid {
  grid-template-columns: 1.2fr 0.7fr 0.7fr;
  padding-top: 12px;
}
.footer-grid h4 {
  margin: 0 0 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.74rem;
}
.footer-grid ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
  color: var(--muted);
}
.footer-bottom {
  padding-top: 24px;
  color: var(--muted);
  letter-spacing: 0.03em;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #050706;
    --bg-soft: #0d110e;
    --panel: rgba(12, 16, 13, 0.9);
    --panel-strong: #0d120e;
    --panel-muted: #111712;
    --line: rgba(234, 241, 236, 0.1);
    --line-strong: rgba(234, 241, 236, 0.2);
    --text: #f3f7f4;
    --text-soft: #d6e0d9;
    --muted: #9ba8a0;
    --brand: #18b261;
    --brand-deep: #73dc9d;
    --brand-soft: rgba(24, 178, 97, 0.16);
    --shadow: 0 26px 70px rgba(0, 0, 0, 0.34);
    --shadow-soft: 0 14px 32px rgba(0, 0, 0, 0.24);
  }

  body {
    background:
      radial-gradient(circle at top right, rgba(24, 178, 97, 0.14), transparent 24%),
      linear-gradient(180deg, #050706 0%, #090c0a 46%, #0d120e 100%);
  }
  body::before {
    background:
      linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
      linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
    opacity: 0.25;
  }
  .site-header {
    background: rgba(5, 7, 6, 0.82);
    border-bottom-color: rgba(255,255,255,0.08);
  }
  .brand-mark {
    background: #f0f6f2;
    color: #09100b;
    border-color: rgba(24, 178, 97, 0.5);
  }
  .button-secondary,
  .button-ghost {
    background: rgba(12, 16, 13, 0.64);
    color: var(--text);
    border-color: rgba(255,255,255,0.14);
  }
  .button-secondary:hover,
  .button-ghost:hover {
    background: rgba(18, 24, 19, 0.94);
  }
  .eyebrow,
  .signal-strip div,
  .stat-row div,
  .docs-nav,
  .auth-card,
  .notice {
    background: rgba(12, 16, 13, 0.76);
  }
  .terminal-card {
    background: linear-gradient(180deg, rgba(13,18,14,0.96), rgba(10,14,11,0.96));
  }
  pre {
    background: #020403;
    color: #d6fbe5;
  }
  .feature-card,
  .plan-card,
  .log-card,
  .doc-section,
  .docs-cta-box,
  .comparison-card,
  .cta-banner {
    background: linear-gradient(180deg, rgba(12,16,13,0.95), rgba(10,13,11,0.92));
  }
  .section-alt {
    background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
    border-top-color: rgba(255,255,255,0.06);
    border-bottom-color: rgba(255,255,255,0.06);
  }
}

@media (max-width: 1024px) {
  .hero-grid,
  .split-grid,
  .feature-grid,
  .plan-grid,
  .comparison-grid,
  .log-list,
  .footer-grid,
  .docs-shell,
  .section-proof .proof-grid,
  .signal-strip {
    grid-template-columns: 1fr;
  }
  .docs-nav,
  .sticky-heading { position: static; }
  .stat-row { grid-template-columns: 1fr; }
}

@media (max-width: 860px) {
  .header-row {
    flex-direction: column;
    align-items: stretch;
    padding: 12px 0;
  }
  .main-nav, .header-actions { justify-content: center; }
  .cta-banner {
    flex-direction: column;
    align-items: flex-start;
  }
  .container { width: min(1180px, calc(100vw - 24px)); }
  .hero, .page-hero { padding-top: 68px; }
  .hero h1, .page-hero h1 { max-width: none; }
  .hero-main { padding-right: 0; }
}
