*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy:   #0f1020;
  --navy2:  #161828;
  --navy3:  #1e2038;
  --card:   #1a1c30;
  --border: rgba(255,255,255,0.07);
  --gold:   #d4a537;
  --gold2:  #e8b84b;
  --teal:   #2e8b8b;
  --teal2:  #3aa8a8;
  --white:  #f4f0e8;
  --gray1:  #b8b4aa;
  --gray2:  #7a7670;
  --green:  #2ecc71;
  --red:    #e74c3c;
}

html { scroll-behavior: smooth; }

/* fix font consistency — body text everywhere should be system-ui */
body {
  font-family: system-ui, -apple-system, sans-serif;
  background: var(--navy);
  color: var(--white);
  line-height: 1.7;
  font-size: 17px;
}

/* Georgia only for hero h1, blockquotes, and .serif class */
h1, blockquote, .serif { font-family: 'Georgia', 'Times New Roman', serif; }

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold2); }

/* text balance for headings */
h1, h2, .section-title, .hero h1 { text-wrap: balance; }

/* ── Nav ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(15,16,32,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem;
  height: 56px;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo {
  font-family: 'Georgia', serif;
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--gold);
  letter-spacing: 0.04em;
}
.nav-logo span { color: var(--gray1); font-size: 0.75rem; font-weight: normal; margin-left: 8px; letter-spacing: 0; font-family: system-ui, sans-serif; }
.nav-links { display: flex; gap: 1.75rem; font-family: system-ui, sans-serif; font-size: 0.875rem; color: var(--gray1); }
.nav-links a { color: var(--gray1); transition: color 0.2s; }
.nav-links a:hover { color: var(--white); }
/* active nav link */
.nav-links a[aria-current="page"] { color: var(--white); }
.nav-cta {
  font-family: system-ui, sans-serif;
  font-size: 0.875rem;
  background: var(--gold);
  color: #1a1200;
  padding: 7px 18px;
  border-radius: 4px;
  font-weight: 600;
  transition: background 0.2s;
}
.nav-cta:hover { background: var(--gold2); color: #1a1200; }

/* mobile hamburger nav */
.nav-toggle { display: none; }
.nav-mobile-menu {
  display: none;
  position: fixed; top: 56px; left: 0; right: 0;
  background: rgba(15,16,32,0.98);
  border-bottom: 1px solid var(--border);
  padding: 1rem 2rem;
  flex-direction: column; gap: 0;
  z-index: 99;
}
.nav-mobile-menu a {
  font-family: system-ui, sans-serif;
  font-size: 0.95rem;
  color: var(--gray1);
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
  display: block;
}
.nav-mobile-menu a:last-child { border-bottom: none; }
#nav-check { display: none; }
#nav-check:checked ~ .nav-mobile-menu { display: flex; }

/* ── Hero ── */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 6rem 2rem 4rem;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(46,139,139,0.12) 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 80% 80%, rgba(212,165,55,0.07) 0%, transparent 60%);
  pointer-events: none;
}
.hero-eyebrow {
  font-family: system-ui, sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal2);
  margin-bottom: 1.2rem;
}
.hero h1 {
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  font-weight: bold;
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin-bottom: 0.4rem;
  color: var(--gold);
}
.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: var(--gray1);
  margin-bottom: 1rem;
  font-style: italic;
}
.hero-desc {
  max-width: 640px;
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  color: var(--white);
  opacity: 0.85;
  margin-bottom: 2.5rem;
  line-height: 1.75;
}
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }
.btn-primary {
  font-family: system-ui, sans-serif;
  font-size: 1rem; font-weight: 600;
  background: var(--gold); color: #150f00;
  padding: 14px 32px; border-radius: 5px;
  transition: background 0.2s, transform 0.15s;
}
.btn-primary:hover { background: var(--gold2); color: #150f00; transform: translateY(-1px); }
.btn-secondary {
  font-family: system-ui, sans-serif;
  font-size: 1rem; font-weight: 500;
  border: 1px solid var(--border);
  color: var(--gray1);
  padding: 14px 32px; border-radius: 5px;
  background: rgba(255,255,255,0.04);
  transition: border-color 0.2s, color 0.2s;
}
.btn-secondary:hover { border-color: var(--gold); color: var(--gold); }

.hero-note {
  margin-top: 2.5rem;
  font-family: system-ui, sans-serif;
  font-size: 0.8rem;
  color: var(--gray2);
}

/* ── page hero (smaller than home hero, for inner pages) ── */
.page-hero {
  padding: 7rem 2rem 3rem;
  text-align: left;
  max-width: 1100px;
  margin: 0 auto;
}
.page-hero .section-label { margin-bottom: 0.5rem; }
.page-hero h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: bold;
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 0.75rem;
  font-family: system-ui, sans-serif;
}
.page-hero p {
  font-size: 1.1rem;
  color: var(--gray1);
  max-width: 600px;
  line-height: 1.75;
}

/* ── Sections ── */
section { padding: 5rem 2rem; }
.container { max-width: 1100px; margin: 0 auto; }
.section-label {
  font-family: system-ui, sans-serif;
  font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--teal2);
  margin-bottom: 0.75rem;
}
.section-title {
  font-size: clamp(1.7rem, 3.5vw, 2.4rem);
  font-weight: bold;
  color: var(--white);
  line-height: 1.2;
  margin-bottom: 1rem;
  font-family: system-ui, sans-serif;
}
.section-title em { font-style: normal; color: var(--gold); }
.section-body {
  font-size: 1.05rem;
  color: var(--gray1);
  max-width: 640px;
  line-height: 1.8;
}

/* ── Divider ── */
.divider { width: 48px; height: 2px; background: var(--gold); margin: 1.5rem 0; }

/* ── Stat strip ── */
.stat-strip {
  background: var(--navy3);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 2.5rem 2rem;
}
.stat-strip .container {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 3rem;
}
.stat { text-align: center; }
.stat-number {
  font-size: 2.2rem; font-weight: bold;
  color: var(--gold); display: block;
  font-family: system-ui, sans-serif;
}
.stat-label {
  font-family: system-ui, sans-serif;
  font-size: 0.8rem; color: var(--gray2);
  text-transform: uppercase; letter-spacing: 0.08em;
}

/* ── Feature grid ── */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 3rem;
}
.feature-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.75rem;
  transition: border-color 0.2s, transform 0.2s;
}
.feature-card:hover { border-color: rgba(212,165,55,0.3); transform: translateY(-2px); }
.feature-icon {
  font-size: 1.6rem;
  margin-bottom: 0.75rem;
  display: block;
  color: var(--gold);
}
.feature-card h3 {
  font-size: 1.05rem; font-weight: bold;
  color: var(--white);
  margin-bottom: 0.5rem;
  font-family: system-ui, sans-serif;
}
.feature-card p {
  font-size: 0.92rem;
  color: var(--gray1);
  line-height: 1.65;
  font-family: system-ui, sans-serif;
}

/* ── Community section ── */
.community-section {
  background: var(--navy2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.community-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
  margin-top: 3rem;
}
.community-list { list-style: none; }
.community-list li {
  font-family: system-ui, sans-serif;
  font-size: 0.97rem;
  color: var(--gray1);
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: flex-start; gap: 0.75rem;
  line-height: 1.5;
}
.community-list li:last-child { border-bottom: none; }
.community-list li strong { color: var(--white); font-weight: 600; display: block; margin-bottom: 1px; }
.check { color: var(--teal2); font-size: 1rem; flex-shrink: 0; margin-top: 2px; }

.community-callout {
  background: var(--navy3);
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  border-radius: 8px;
  padding: 2rem;
}
.community-callout blockquote {
  font-size: 1.1rem;
  color: var(--white);
  line-height: 1.75;
  font-style: italic;
  margin-bottom: 1rem;
}
.community-callout cite {
  font-family: system-ui, sans-serif;
  font-size: 0.82rem;
  color: var(--gray2);
  font-style: normal;
}

/* ── Permission tiers ── */
.tier-list {
  margin-top: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1px;
  border-radius: 8px;
  overflow: hidden;
}
.tier {
  display: flex; align-items: flex-start; gap: 1.25rem;
  background: var(--card);
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--border);
}
.tier:first-child { border-radius: 8px 8px 0 0; }
.tier:last-child { border-radius: 0 0 8px 8px; }
.tier-badge {
  font-family: system-ui, sans-serif;
  font-size: 0.78rem; font-weight: 700;
  padding: 3px 10px; border-radius: 3px;
  white-space: nowrap; flex-shrink: 0;
  margin-top: 3px;
}
.tier-body { flex: 1; }
.tier-body strong {
  font-family: system-ui, sans-serif;
  font-size: 0.95rem; color: var(--white);
  display: block; margin-bottom: 2px;
}
.tier-body p {
  font-family: system-ui, sans-serif;
  font-size: 0.85rem; color: var(--gray1); line-height: 1.5;
}

/* ── Matching section ── */
.matching-flow {
  display: flex;
  gap: 0;
  margin-top: 2.5rem;
  align-items: stretch;
}
.flow-step {
  flex: 1;
  background: var(--card);
  border: 1px solid var(--border);
  padding: 1.5rem;
  position: relative;
}
.flow-step:first-child { border-radius: 8px 0 0 8px; }
.flow-step:last-child { border-radius: 0 8px 8px 0; }
.flow-arrow {
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); font-size: 1.2rem;
  padding: 0 2px;
  background: var(--navy3);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.flow-step-num {
  font-family: system-ui, sans-serif;
  font-size: 0.7rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--teal2); margin-bottom: 0.4rem;
}
.flow-step h4 {
  font-family: system-ui, sans-serif;
  font-size: 0.95rem; font-weight: 600;
  color: var(--white); margin-bottom: 0.5rem;
}
.flow-step p {
  font-family: system-ui, sans-serif;
  font-size: 0.83rem; color: var(--gray1); line-height: 1.55;
}

/* ── CTA section ── */
.cta-section {
  text-align: center;
  background: var(--navy2);
  border-top: 1px solid var(--border);
}
.cta-section .section-title { margin: 0 auto 1rem; }
.cta-section .section-body { margin: 0 auto 2rem; text-align: center; }

/* ── Footer ── */
footer {
  background: var(--navy);
  border-top: 1px solid var(--border);
  padding: 2.5rem 2rem;
  font-family: system-ui, sans-serif;
  font-size: 0.82rem;
  color: var(--gray2);
}

/* ── About / two-col ── */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
  margin-top: 3rem;
}
.about-values {
  display: flex; flex-direction: column; gap: 1.25rem;
  margin-top: 2rem;
}
.value-row {
  display: flex; gap: 1rem; align-items: flex-start;
}
.value-icon {
  font-size: 1.1rem; flex-shrink: 0; margin-top: 2px;
  color: var(--gold);
}
.value-row h4 {
  font-family: system-ui, sans-serif;
  font-size: 0.95rem; font-weight: 600;
  color: var(--white); margin-bottom: 2px;
}
.value-row p {
  font-family: system-ui, sans-serif;
  font-size: 0.87rem; color: var(--gray1); line-height: 1.55;
}
.about-story {
  font-size: 1rem; color: var(--gray1); line-height: 1.85;
}
.about-story p { margin-bottom: 1.1rem; }
.about-story p:last-child { margin-bottom: 0; }

/* ── Conservation ── */
.conservation-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 3rem;
}
.conservation-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
}
.conservation-card h3 {
  font-family: system-ui, sans-serif;
  font-size: 0.95rem; font-weight: 600;
  color: var(--white); margin-bottom: 0.5rem;
  display: flex; align-items: center; gap: 0.5rem;
}
.conservation-card p {
  font-family: system-ui, sans-serif;
  font-size: 0.87rem; color: var(--gray1); line-height: 1.6;
}
.conservation-pledge {
  margin-top: 2.5rem;
  background: var(--navy3);
  border: 1px solid var(--border);
  border-left: 3px solid var(--teal2);
  border-radius: 8px;
  padding: 1.75rem 2rem;
  display: flex; gap: 1.5rem; align-items: flex-start;
}
.conservation-pledge-icon { font-size: 1.5rem; flex-shrink: 0; }
.conservation-pledge p {
  font-family: system-ui, sans-serif;
  font-size: 0.95rem; color: var(--gray1); line-height: 1.75;
}
.conservation-pledge strong { color: var(--white); }

/* ── Changelog ── */
.changelog-list {
  margin-top: 2.5rem;
  display: flex; flex-direction: column; gap: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.changelog-entry {
  display: flex; gap: 1.5rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--card);
}
.changelog-entry:last-child { border-bottom: none; }
.changelog-entry:hover { background: var(--navy3); }
.changelog-date {
  font-family: system-ui, sans-serif;
  font-size: 0.78rem;
  color: var(--gray2);
  white-space: nowrap;
  flex-shrink: 0;
  padding-top: 3px;
  min-width: 90px;
}
.changelog-body { flex: 1; }
.changelog-body strong {
  font-family: system-ui, sans-serif;
  font-size: 0.95rem; font-weight: 600;
  color: var(--white); display: block; margin-bottom: 3px;
}
.changelog-body p {
  font-family: system-ui, sans-serif;
  font-size: 0.85rem; color: var(--gray1); line-height: 1.5;
}
.changelog-tags { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.changelog-tag {
  font-family: system-ui, sans-serif;
  font-size: 0.7rem; font-weight: 600;
  padding: 2px 7px; border-radius: 3px;
  letter-spacing: 0.04em;
}
.tag-new { background: rgba(46,139,139,0.18); color: var(--teal2); }
.tag-fix { background: rgba(212,165,55,0.15); color: var(--gold); }
.tag-improved { background: rgba(244,240,232,0.07); color: var(--gray1); }
.tag-security { background: rgba(231,76,60,0.15); color: #e74c3c; }
.tag-removed { background: rgba(122,118,112,0.15); color: var(--gray2); }

/* ── Blog cards ── */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.25rem;
  margin-top: 2.5rem;
}
.blog-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
  cursor: default;
}
.blog-meta {
  font-family: system-ui, sans-serif;
  font-size: 0.75rem; color: var(--gray2);
  margin-bottom: 0.6rem;
  display: flex; gap: 0.75rem; align-items: center;
}
.blog-category {
  font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--teal2);
}
.blog-card h3 {
  font-family: system-ui, sans-serif;
  font-size: 1rem; font-weight: 600;
  color: var(--white); margin-bottom: 0.5rem;
  line-height: 1.35;
}
.blog-card p {
  font-family: system-ui, sans-serif;
  font-size: 0.87rem; color: var(--gray1); line-height: 1.6;
}

/* ── Two-column feature grid (for features page) ── */
.two-col-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}
.mini-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1rem 1.25rem;
  font-family: system-ui, sans-serif;
  font-size: 0.88rem;
  color: var(--gray1);
  line-height: 1.5;
}

/* ── Query example blocks ── */
.query-block {
  background: var(--navy3);
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  border-radius: 6px;
  padding: 0.85rem 1.25rem;
  font-family: 'Georgia', serif;
  font-size: 1rem;
  color: var(--gold);
  margin-bottom: 0.75rem;
}

/* ── Export table ── */
.export-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 2rem;
  font-family: system-ui, sans-serif;
  font-size: 0.9rem;
}
.export-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal2);
  border-bottom: 1px solid var(--border);
}
.export-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--gray1);
}
.export-table td:first-child {
  color: var(--white);
  font-weight: 600;
}
.export-table tr:last-child td { border-bottom: none; }
.export-table tr:hover td { background: var(--navy3); }

/* ── Tier breakdown list ── */
.tier-breakdown {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 2rem;
}
.tier-breakdown-row {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1rem 1.25rem;
  display: flex;
  gap: 1rem;
  align-items: baseline;
}
.tier-breakdown-label {
  font-family: system-ui, sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--gold);
  white-space: nowrap;
  min-width: 80px;
}
.tier-breakdown-count {
  font-family: system-ui, sans-serif;
  font-size: 0.78rem;
  color: var(--teal2);
  font-weight: 700;
  white-space: nowrap;
  min-width: 60px;
}
.tier-breakdown-desc {
  font-family: system-ui, sans-serif;
  font-size: 0.88rem;
  color: var(--gray1);
  line-height: 1.5;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-toggle {
    display: flex; align-items: center; justify-content: center;
    width: 36px; height: 36px;
    cursor: pointer;
    color: var(--gray1);
    font-size: 1.2rem;
    background: none; border: 1px solid var(--border);
    border-radius: 4px;
  }
  .community-grid { grid-template-columns: 1fr; gap: 2rem; }
  .about-grid { grid-template-columns: 1fr; gap: 2rem; }
  .matching-flow { flex-direction: column; }
  .flow-step:first-child { border-radius: 8px 8px 0 0; }
  .flow-step:last-child { border-radius: 0 0 8px 8px; }
  .flow-arrow { display: none; }
  .page-hero { padding: 5rem 1.5rem 2rem; }
}
