:root{
  --bg: #fdfdfd;
  --fg:#0a0a0a;
  --muted:#5b6b85;
  --line:#d5ddee;
  --card:#ffffff;
  --cardLine:#d5ddee;
  --accent:#002F6C;          /* Eureka Blue */
  --accentHover:#003a84;     /* Slightly brighter version */
  --soft:#f4f6fb;           /* very light blue tint background for soft sections */
  --radius:16px;
--brightband: #0077c2; /* lighter rally blue */
  --gold: #d4af37; /* classic heraldic gold */
  --goldHover: #e1c45c;
}


}

/* Soft white-blue base for all sections to remove grey stripes */
.soft-section {
  background: var(--soft);
}

    *{box-sizing:border-box}
    html,body{margin:0; padding:0; background:var(--bg); color:var(--fg); font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji"}
    a{color:inherit; text-decoration:none}
    .container{max-width:1100px; margin:0 auto; padding:0 16px}
    .btn{display:inline-flex; align-items:center; gap:8px; padding:12px 16px; border-radius:16px; font-weight:600; border:1px solid var(--line); background:var(--card)}
    .btn:hover{background:#f3f4f6}
    .btn.primary{background:var(--accent); color:#fff; border-color:var(--accent)}
    .btn.primary:hover{background:var(--accentHover)}
    .chip{display:inline-flex; padding:2px 8px; border-radius:999px; background:#efefef; font-size:12px; color:#444}
    header.nav{position:sticky; top:0; z-index:30; backdrop-filter:saturate(180%) blur(6px); background:rgba(255,255,255,0.75); border-bottom:1px solid var(--line)}
    header .row{display:flex; align-items:center; justify-content:space-between; padding:12px 0}
    nav a{font-size:14px; margin-left:20px}
    section{padding:64px 0}
    h1{font-size:40px; line-height:1.15; margin:0}
    h2{font-size:28px; margin:0}
    h3{font-size:18px; margin:0}
    p{line-height:1.6; color:#202124}
    .muted{color:var(--muted)}
    .hero{background:linear-gradient(to bottom,#f7f7f7, #fff)}
    .grid{display:grid; gap:24px}
    .g-2{grid-template-columns: 1fr}
    .g-4{grid-template-columns: 1fr}
    @media (min-width: 900px){
      .g-2{grid-template-columns: 1.1fr 0.9fr}
      .g-4{grid-template-columns: repeat(4, 1fr)}
    }
    .card{background:var(--card); border:1px solid var(--cardLine); border-radius:24px; padding:20px; box-shadow:0 1px 2px rgba(0,0,0,0.03)}
    .soft{background:var(--soft); border:1px solid var(--line); border-radius:24px; padding:20px}
    .kbd{font-family:ui-monospace, Menlo, Consolas, monospace; font-size:12px; background:#111; color:#fff; padding:2px 6px; border-radius:6px}
    .list{padding-left:18px}
    .list li{margin:8px 0}
    .road{background:#fff}
    .phase{background:#fafafa; border:1px solid var(--line); border-radius:24px; padding:18px}
    .phase h3{display:flex; align-items:center; gap:8px}
    .progress{height:12px; width:100%; background:#e5e7eb; border-radius:999px; overflow:hidden}
    .bar{height:100%; background:#111; width:0%}
    .footer{border-top:1px solid var(--line); background:#fff}
    .small{font-size:12px}
    input,button,textarea{font:inherit}
    input[type="text"], input[type="email"]{
      width:100%; border:1px solid var(--line); background:#fff; padding:12px 14px; border-radius:14px
    }
    .row2{display:grid; grid-template-columns:1fr; gap:12px}
    @media (min-width: 760px){ .row2{grid-template-columns:1fr 1fr} }
    .pill{display:inline-flex; align-items:center; gap:6px; padding:8px 10px; border:1px solid var(--line); border-radius:12px; background:#fff; font-size:14px}
    .pill:hover{background:#f5f5f5}
    .ledger-cards{display:grid; gap:12px}
    @media (min-width: 800px){ .ledger-cards{grid-template-columns:repeat(3,1fr)} }
    .stat{background:#fff; border:1px solid var(--line); border-radius:18px; padding:16px}
    .stat .label{color:var(--muted); font-size:13px}
    .stat .value{font-weight:700; font-size:22px}
  
    /* === Branding Enhancements === */
    .hero{position:relative}
    .eureka-watermark{
      position:absolute; inset:0;
      pointer-events:none;
      background: radial-gradient(closest-side, rgba(17,17,17,0.06), transparent 70%) center/60% 60% no-repeat;
      mask: url('#'); /* fallback for older browsers */
    }
    /* Use an inline SVG background for the watermark */
    .eureka-watermark{
      background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><rect x='0' y='48' width='100' height='4' rx='1' fill='%23000' opacity='0.08'/><rect x='48' y='0' width='4' height='100' rx='1' fill='%23000' opacity='0.08'/><circle cx='50' cy='50' r='8' fill='%23000' opacity='0.08'/><circle cx='50' cy='10' r='5' fill='%23000' opacity='0.08'/><circle cx='50' cy='90' r='5' fill='%23000' opacity='0.08'/><circle cx='10' cy='50' r='5' fill='%23000' opacity='0.08'/><circle cx='90' cy='50' r='5' fill='%23000' opacity='0.08'/></svg>");
      background-size: 420px 420px;
      background-position: right -80px top -40px;
      opacity: 0.7;
    }

    /* Section divider with star motif */
    .divider{display:flex; justify-content:center; align-items:center; gap:10px; margin:24px 0}
    .divider:before, .divider:after{
      content:""; height:1px; background:var(--line); flex:1
    }
    .divider svg{width:18px; height:18px; opacity:0.45}

    /* Phase icons */
    .phase h3{display:flex; align-items:center; gap:8px}
    .phase h3 svg{width:18px; height:18px}

    /* Footer crest */
    .footer-crest{display:inline-flex; align-items:center; gap:8px}
    .footer-crest svg{width:16px; height:16px}


    .hero .card img{ mix-blend-mode:multiply; }
    .footer-crest img{ display:inline-block; vertical-align:middle; }

/* Global text & surfaces */
html, body { background: var(--bg); color: var(--fg); }
p { color: var(--fg); }
.muted { color: var(--muted); }

/* Sections: no grey stripes, just transparent over the deep field */
section { background: transparent; }

/* Cards and soft panels */
.card { background: var(--card); border:1px solid var(--cardLine); }
.soft  { background: var(--soft);  border:1px solid var(--line); }

/* Nav: solid banner strip (blur on dark looks muddy) */
header.nav{
  position:sticky; top:0; z-index:30;
  backdrop-filter:none;
  background: rgba(14,26,43,0.92); /* var(--bg), slightly translucent */
  border-bottom:1px solid var(--line);
}
header.nav {
  height: 120px;
  display: flex;
  align-items: center; /* vertically centers the contents */
}


header .row a { color: var(--fg); }
nav a { color: var(--fg); opacity:.9; }
nav a:hover { opacity:1; }

/* Buttons */
.btn{ background: var(--card); border:1px solid var(--line); color: var(--fg); }
.btn:hover{ background: #1a2a44; }
.btn.primary{ background: var(--accent); border-color: var(--accent); color:#fff; }
.btn.primary:hover{ background: var(--accentHover); }

/* Progress bar */
.progress{ background:#1b2741; }
.bar{ background: var(--accent); }

/* Small crest in nav (from earlier step) */
.nav-crest{
  position:absolute; left:0; top:50%; transform:translateY(-50%);
  height:40px; width:auto;
}

/* Optional: soften dividers for dark */
.divider:before, .divider:after{ background: var(--line); }

/* === Loading Overlay (Eureka veil) === */
#preload {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  background: rgba(0,0,0,0.35); /* safety tint while image loads */
  overflow: hidden;
}

#preload .preload-backdrop {
  position: absolute;
  inset: 0;
  background: center/cover no-repeat url("images/eureka_flag.png");
  filter: blur(10px) saturate(0.9) brightness(0.8);
  transform: scale(1.05); /* reduce edge bleed from blur */
}

#preload .preload-content {
  position: relative;
  max-width: 70ch;
  padding: 20px 24px;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
  text-align: center;
}

#preload .preload-line {
  margin: 0;
  color: #fff;
  font-size: clamp(14px, 2.2vw, 18px);
  line-height: 1.5;
}

/* Fade-in and fade-out choreography */
@keyframes preloadFadeIn {
  from { opacity: 0 } to { opacity: 1 }
}
@keyframes preloadFadeOut {
  from { opacity: 1 } to { opacity: 0 }
}
#preload { animation: preloadFadeIn 300ms ease-out; }
#preload.fade-out { animation: preloadFadeOut 420ms ease-in forwards; }

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  #preload, #preload.fade-out { animation: none; }
}

/* === DARK EUREKA — GLOBAL OVERRIDE (append at end of style.css) === */

/* Palette */
:root{
  --bg: #0d1b2a;         /* deep field */
  --fg: #e8eef5;         /* body text */
  --muted:#b8c7e0;       /* secondary text */
  --line:#223047;        /* dividers */
  --card:#132238;        /* cards/panels */
  --cardLine:#1b2a42;    /* card borders */
  --soft:#0b1728;        /* softer section bg if needed */
  --accent:#2a6fdb;      /* Eureka blue */
  --accentHover:#3a81f1; /* hover blue */
}

/* Base surfaces & text */
html, body { background: var(--bg) !important; color: var(--fg) !important; }
p, .small, .chip, .label, .value { color: var(--fg) !important; }
.muted { color: var(--muted) !important; }

/* Kill any light stripes/gradients */
section, .road, .footer, .soft-section { background: transparent !important; }
.hero { background: transparent !important; }

/* Cards / panels / stats */
.card, .soft, .stat { background: var(--card) !important; border:1px solid var(--cardLine) !important; }
.stat .label { color: var(--muted) !important; }

/* Nav banner — readable on dark */
header.nav{
  backdrop-filter: none !important;
  background: #162440 !important;             /* lighter than page for separation */
  border-bottom: 1px solid var(--line) !important;
  height: 80px;                                /* as requested */
  display: flex; align-items: center;
}
header.nav .row{ height:100%; display:flex; align-items:center; padding-top:0; padding-bottom:0; }
header .row a, nav a { color: #f4f8ff !important; opacity: .95; }
nav a:hover { opacity: 1; text-decoration: underline; }

/* Buttons */
.btn{ background: var(--card) !important; border:1px solid var(--line) !important; color: var(--fg) !important; }
.btn:hover{ background: #1a2a44 !important; }
.btn.primary{ background: var(--accent) !important; border-color: var(--accent) !important; color:#fff !important; }
.btn.primary:hover{ background: var(--accentHover) !important; }

/* Inputs / pills — no white blocks */
input[type="text"], input[type="email"]{
  background:#0f1e34 !important; color: var(--fg) !important;
  border:1px solid var(--line) !important;
}
.pill{ background:#16243a !important; border:1px solid var(--line) !important; color: var(--fg) !important; }
.pill:hover{ background:#1a2a44 !important; }

/* Phase cards (were pale) */
.phase{ background:#16243a !important; border:1px solid var(--line) !important; }

/* Footer bar */
.footer{ background: transparent !important; border-top:1px solid var(--line) !important; }

/* Progress */
.progress{ background:#142339 !important; }
.bar{ background: var(--accent) !important; }

/* Hero image blend stays gentle on dark */
.hero .card img{ mix-blend-mode: normal !important; opacity: .15 !important; }

/* Crest */
.nav-crest{ height:40px; width:auto; }

/* === EUREKA BANDS === */
:root{
  --band:#0e4e60; /* the deep blue you sent; adjust if needed */
}

/* Section band */
.band{
  background: var(--band) !important;   /* beats the global transparent rule */
  color:#eef4fb;                         /* readable ink on blue */
}

/* Typography inside band */
.band h1,.band h2,.band h3,
.band p,.band .small{ color:#eef4fb !important; }
.band .muted{ color:rgba(255,255,255,0.78) !important; }

/* Dividers on band */
.band .divider:before,
.band .divider:after{ background:rgba(255,255,255,0.25) !important; }

/* Cards/panels on band: translucent, not white tiles */
.band .card,.band .soft,.band .stat{
  background: rgba(0,0,0,0.18) !important;
  border:1px solid rgba(255,255,255,0.14) !important;
}
.band .stat .label{ color:rgba(255,255,255,0.8) !important; }

/* Buttons on band */
.band .btn{
  background: rgba(0,0,0,0.18) !important;
  border:1px solid rgba(255,255,255,0.18) !important;
  color:#fff !important;
}
.band .btn:hover{ background: rgba(0,0,0,0.28) !important; }
.band .btn.primary{
  background: var(--accent) !important;
  border-color: var(--accent) !important;
  color:#fff !important;
}
.band .btn.primary:hover{ background: var(--accentHover) !important; }

/* Progress bar on band */
.band .progress{ background: rgba(0,0,0,0.22) !important; }
.band .bar{ background: #ffffff !important; } /* white bar reads well on band */

/* === BRIGHT RALLY BAND === */
.bright-band{
  background: var(--brightband) !important;
  color:#ffffff !important;
}

/* Text fix */
.bright-band h1, .bright-band h2, .bright-band h3,
.bright-band p, .bright-band .small{ color:#ffffff !important; }

/* Divider contrast */
.bright-band .divider:before,
.bright-band .divider:after{ background:rgba(255,255,255,0.4) !important; }

/* Buttons in this band */
.bright-band .btn{
  background: rgba(255,255,255,0.15) !important;
  border:1px solid rgba(255,255,255,0.25) !important;
  color:#ffffff !important;
}
.bright-band .btn:hover{
  background: rgba(255,255,255,0.25) !important;
}

/* === EUREKA: Unified Dark + Bands (FINAL) === */

/* Core palette — one hue family */
:root{
  --bg: #0d1b2a;        /* deep field */
  --fg: #e8eef5;        /* body text on dark */
  --muted:#b8c7e0;      /* subdued text */
  --line:#223047;       /* dividers */

  --card:#132238;       /* panels */
  --cardLine:#1b2a42;

  --accent:#2a6fdb;     /* Eureka action blue (buttons/links), not as bg */
  --accentHover:#3a81f1;

  /* Bands (same hue family) */
  --band:#10384a;       /* deep banner blue */
  --brightband:#145b75; /* rally band (lighter tint of --band) */

  /* Nav (derived from band) */
  --navBg: rgba(16,56,74,0.92);
}

/* Global surfaces */
html, body { background: var(--bg) !important; color: var(--fg) !important; }
p, .small, .label, .value { color: var(--fg) !important; }
.muted { color: var(--muted) !important; }

/* Kill stray light backgrounds/gradients */
.hero, .road, .footer, section, .soft-section { background: transparent !important; }

/* Panels/cards/stats */
.card, .soft, .stat { background: var(--card) !important; border:1px solid var(--cardLine) !important; }
.stat .label { color: var(--muted) !important; }

/* Nav — readable, aligned to band hue */
header.nav{
  backdrop-filter:none !important;
  background: var(--navBg) !important;
  border-bottom:1px solid var(--line) !important;
  height:80px; display:flex; align-items:center;
}
header.nav .row{ height:100%; display:flex; align-items:center; padding-top:0; padding-bottom:0; }
header .row a, nav a { color:#f4f8ff !important; opacity:.95; }
nav a:hover { opacity:1; text-decoration: underline; }

/* Buttons */
.btn{ background: var(--card) !important; border:1px solid var(--line) !important; color: var(--fg) !important; }
.btn:hover{ background:#1a2a44 !important; }
.btn.primary{ background: var(--accent) !important; border-color: var(--accent) !important; color:#fff !important; }
.btn.primary:hover{ background: var(--accentHover) !important; }

/* Inputs / pills */
input[type="text"], input[type="email"]{
  background:#0f1e34 !important; color: var(--fg) !important; border:1px solid var(--line) !important;
}
.pill{ background:#16243a !important; border:1px solid var(--line) !important; color: var(--fg) !important; }
.pill:hover{ background:#1a2a44 !important; }

/* Phase tiles */
.phase{ background:#16243a !important; border:1px solid var(--line) !important; }

/* Progress */
.progress{ background:#142339 !important; }
.bar{ background: var(--accent) !important; }

/* Images in hero cards */
.hero .card img{ mix-blend-mode: normal !important; opacity:.15 !important; }

/* Bands */
.band{
  background: var(--band) !important; color:#eef4fb !important;
}
.band h1,.band h2,.band h3,.band p,.band .small{ color:#eef4fb !important; }
.band .muted{ color:rgba(255,255,255,0.78) !important; }
.band .divider:before, .band .divider:after{ background:rgba(255,255,255,0.25) !important; }
.band .card,.band .soft,.band .stat{
  background: rgba(0,0,0,0.18) !important; border:1px solid rgba(255,255,255,0.14) !important;
}
.band .btn{
  background: rgba(0,0,0,0.18) !important; border:1px solid rgba(255,255,255,0.18) !important; color:#fff !important;
}
.band .btn:hover{ background: rgba(0,0,0,0.28) !important; }
.band .btn.primary{ background: var(--accent) !important; border-color: var(--accent) !important; color:#fff !important; }
.band .btn.primary:hover{ background: var(--accentHover) !important; }
.band .progress{ background: rgba(0,0,0,0.22) !important; }
.band .bar{ background:#ffffff !important; }

/* Bright rally band (same family, lighter) */
.bright-band{
  background: var(--brightband) !important; color:#ffffff !important;
}
.bright-band h1,.bright-band h2,.bright-band h3,
.bright-band p,.bright-band .small{ color:#ffffff !important; }
.bright-band .divider:before, .bright-band .divider:after{ background:rgba(255,255,255,0.4) !important; }
.bright-band .card,.bright-band .soft,.bright-band .stat{
  background: rgba(0,0,0,0.16) !important; border:1px solid rgba(255,255,255,0.20) !important;
}
.bright-band .btn{
  background: rgba(255,255,255,0.14) !important; border:1px solid rgba(255,255,255,0.24) !important; color:#ffffff !important;
}
.bright-band .btn:hover{ background: rgba(255,255,255,0.24) !important; }

/* === PARCHMENT SECTION === */
.parchment {
  background: #ffffff !important;
  color: #111111 !important;
  border-top: 2px solid #e0e0e0;
  border-bottom: 2px solid #e0e0e0;
}

.parchment h1, 
.parchment h2, 
.parchment h3,
.parchment p, 
.parchment .small {
  color: #111111 !important;
}

.parchment .muted {
  color: #444 !important;
}

/* Panels inside parchment look like paper cards */
.parchment .card,
.parchment .soft,
.parchment .stat {
  background: #ffffff !important;
  border: 1px solid #dddddd !important;
  color: #111111 !important;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

/* Buttons inside parchment default back to dark civic style */
.parchment .btn {
  background: #f3f3f3 !important;
  color: #111 !important;
  border: 1px solid #cccccc !important;
}

.parchment .btn.primary {
  background: var(--accent) !important;
  color: #fff !important;
}

/* === MODERN CHARTER SECTION — Clean white, not aged === */
.charter-section {
  background: #f5f6f8 !important;       /* cool civic white */
  color: #111 !important;               /* strong ink tone */
  border-top: 2px solid #e3e6ea;
  border-bottom: 2px solid #e3e6ea;
  box-shadow: 0 -1px 6px rgba(0,0,0,0.15), 0 2px 6px rgba(0,0,0,0.15); /* modern floating panel feel */
}

.charter-section h1,
.charter-section h2,
.charter-section h3,
.charter-section p,
.charter-section .small {
  color: #111 !important;
}

.charter-section .muted {
  color: #555 !important;
}

/* Inside cards should appear as flat white panels, not dark */
.charter-section .card,
.charter-section .soft,
.charter-section .stat {
  background: #ffffff !important;
  border: 1px solid #dadee4 !important;
  color: #111 !important;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

/* Buttons inside modern charter revert back to dark civic style */
.charter-section .btn {
  background: #ffffff !important;
  color: #111 !important;
  border: 1px solid #cccccc !important;
}
.charter-section .btn:hover { background: #e8eaee !important; }

/* HERO layout that respects the container */
.hero-grid{
  display:grid;
  gap:24px;
  grid-template-columns: 1fr;            /* mobile: single column */
}
@media (min-width:900px){
  .hero-grid{
    grid-template-columns: 1.1fr 0.9fr;  /* desktop: two columns */
    align-items: center;
  }
  .hero-banner{ grid-column: 1 / -1; }   /* banner spans both columns on desktop */
}
.hero-banner img{
  display:block; width:100%; height:auto;
}

/* HERO — disciplined layout */
.hero-grid{
  display:grid;
  gap:24px;
  align-items:start;
  grid-template-columns: 1fr;
  grid-template-areas:
    "banner"
    "copy"
    "treasury";
}

/* Desktop: banner spans; copy left, treasury right */
@media (min-width: 900px){
  .hero-grid{
    grid-template-columns: 1.1fr 0.9fr;
    grid-template-areas:
      "banner   banner"
      "copy     treasury";
  }
}

/* Area hooks */
.hero-banner   { grid-area: banner; }
.hero-copy     { grid-area: copy; }
.hero-treasury { grid-area: treasury; }

/* Clean, consistent spacing */
.hero-banner img{ display:block; width:100%; height:auto; }

/* Tidy headings & paragraphs so they don't push things around */
.hero-copy h1{ margin:0; line-height:1.15; }
.hero-copy p{ margin:10px 0 0; }

/* Ensure the card sits at the top of its column */
.card.hero-treasury{ align-self:start; position:relative; overflow:hidden; }

/* Background image inside the card stays contained */
.card.hero-treasury > img{
  position:absolute; inset:0; width:100%; height:100%; object-fit:cover; opacity:0.10;
  pointer-events:none;
}

/* Combined hero + charter grid */
.hero-grid{
  display:grid;
  gap:24px;
  align-items:start;
  grid-template-columns: 1fr;
  grid-template-areas:
    "banner"
    "copy"
    "treasury"
    "charter";
}

.hero-banner   { grid-area: banner; }
.hero-copy     { grid-area: copy; }
.hero-treasury { grid-area: treasury; }
.charter-brief { grid-area: charter; }

/* Desktop layout */
@media (min-width: 900px){
  .hero-grid{
    grid-template-columns: 1.1fr 0.9fr;
    grid-template-areas:
      "banner   banner"
      "copy     treasury"
      "charter  charter";
  }
}

/* Optional: make the bright-band look like your old section while inline */
.charter-brief.bright-band{
  background: var(--bright-band, transparent);
  padding: 16px 0; /* use 0 if your .container already handles padding */
}

/* --- Parchment typography & framing --- */
.parchment {
  /* assume you already set a parchment bg; we ensure legibility */
  --ink: #2a2015;           /* deep brown "ink" instead of harsh black */
  --ink-muted: #5b4a34;     /* secondary text */
  --rule: rgba(43, 33, 21, .25);
  --accent: #8b6a3d;        /* gold-brown accent */
  color: var(--ink);
}

/* Subtle fiber overlay so text feels printed into the page */
.parchment .ink-layer {
  position: relative;
}
.parchment .ink-layer::after {
  content: "";
  position: absolute; inset: 0;
  pointer-events: none;
  background:
    radial-gradient(80% 60% at 50% 35%, transparent 0 60%, rgba(0,0,0,.04) 100%),
    linear-gradient(transparent 0, rgba(0,0,0,.03) 100%);
  mix-blend-mode: multiply;
}

/* Kicker (small line above the main title) */
.kicker {
  display: inline-block;
  font-size: .85rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-muted);
  background: linear-gradient(to right, var(--rule), transparent);
  -webkit-background-clip: text;
  background-clip: text;
}

/* Main title on parchment */
.parchment .section-title {
  margin: 6px 0 10px;
  font-size: clamp(1.6rem, 1.2rem + 1.8vw, 2.4rem);
  line-height: 1.15;
  letter-spacing: .01em;
  font-variation-settings: "wght" 650; /* if variable font; else ignore */
  color: var(--ink);
  text-shadow: 0 1px 0 rgba(255,255,255,.35);
}

/* Optional subtitle line */
.parchment .section-subtitle {
  margin: 6px 0 14px;
  color: var(--ink-muted);
  font-size: clamp(1rem, .95rem + .3vw, 1.15rem);
}

/* Decorative rules that suit parchment */
.rule {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--rule), transparent);
  margin: 12px 0;
}
.rule.thick {
  height: 2px;
  background: linear-gradient(to right, transparent, rgba(43,33,21,.45), transparent);
  margin: 8px 0 16px;
}

/* Drop cap for the first paragraph if desired */
.dropcap:first-letter {
  float: left;
  font-size: 3.2rem;
  line-height: .85;
  padding: .1rem .5rem 0 0;
  color: var(--accent);
  font-weight: 600;
}

/* List of phases styled like a charter */
.phases {
  margin-top: 14px;
  display: grid;
  gap: 14px;
}
@media (min-width: 840px){
  .phases { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
.phase {
  padding: 14px 16px;
  border: 1px solid rgba(43,33,21,.18);
  background: linear-gradient(180deg, rgba(255,255,255,.28), rgba(255,255,255,0));
  backdrop-filter: blur(.2px); /* gives ‘printed on paper’ feel */
}
.phase h4{
  margin: 0 0 6px;
  font-size: 1.05rem;
  color: var(--ink);
}
.phase p{
  margin: 0;
  color: var(--ink-muted);
  line-height: 1.5;
}
/* === HERO: add a dedicated full-width row for the quote === */
.hero-grid {
  grid-template-areas:
    "banner"
    "copy"
    "treasury"
    "quote" !important;
}

@media (min-width: 900px){
  .hero-grid {
    grid-template-columns: 1.1fr 0.9fr;
    grid-template-areas:
      "banner   banner"
      "copy     treasury"
      "quote    quote" !important;
  }
}

/* --- Proclamation Band Section --- */
.epigraph-band {
  display: flex;
  align-items: center;       /* Vertically centers content */
  justify-content: center;   /* Optional: keeps it centered horizontally */
  padding: 3rem 0;           /* Adjust height of band — tweak if needed */
  background: rgba(255, 248, 235, 0.8);
  border-top: 1px solid rgba(60,50,35,0.2);
  border-bottom: 1px solid rgba(60,50,35,0.2);
  background-blend-mode: multiply;
  backdrop-filter: blur(2px);
}


.epigraph-text {
  font-size: clamp(1.1rem, 1rem + 0.5vw, 1.4rem);
  font-style: italic;
  line-height: 1.5;
  max-width: 80ch;
  margin: 0 auto;
  color: rgba(60, 50, 35, 0.85);
  text-align: center;
  position: relative;
  padding-top: 0; /* remove this if it's currently 1rem+ */
}

.epigraph-text::before {
  content: none;
}

/* Let proclamation text float across full screen — no frame container */
#preload .preload-content {
  margin: 0;
  padding: 0;
  max-width: none !important;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh; /* centers vertically */
}

/* Full field proclamation text, larger, no bounds */
.preload-line {
  margin: clamp(1rem, 2vh, 2.4rem) 0;
  letter-spacing: .065em;
  text-transform: uppercase;
  text-wrap: balance;
  color: #fff;
  line-height: 1.2;
  font-weight: 600;
  width: 100%;
}
/* Make proclamation text ~120% larger */
.preload-1 { 
  font-size: clamp(3rem, 6vw, 6.5rem); /* Previously ~4.4rem max → now 6.5rem */
}

.preload-2 { 
  font-size: clamp(2.6rem, 5vw, 5rem); /* Previously ~3.6rem → now 5rem */
}


/* Slow ceremonial reveal still intact */
@keyframes preload-rise { 
  from { opacity:0; transform: translateY(10px); } 
  to { opacity:1; transform:none; } 
}
.preload-1 { opacity:0; animation: preload-rise 1s ease-out 400ms forwards; }
.preload-2 { opacity:0; animation: preload-rise 1.1s ease-out 1600ms forwards; }

/* Remove box completely on reduced motion too */
@media (prefers-reduced-motion: reduce) {
  .preload-1, .preload-2 { animation:none; opacity:1; transform:none; }
}

.preload-line {
  margin: clamp(2rem, 4vh, 4rem) 0; /* increase breathing space between lines */
}

/* === PRELOAD OATH — FINAL OVERRIDE (place at very end of style.css) === */

/* No frame. Center in full viewport. */
#preload .preload-content{
  margin: 0 !important;
  padding: 0 !important;
  max-width: none !important;
  width: 100% !important;
  min-height: 100vh !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;

  /* kill the old box */
  background: none !important;
  border: none !important;
  box-shadow: none !important;
}

/* Proclamation lines: bigger + spaced. */
.preload-line{
  margin: clamp(2rem, 4vh, 4rem) 0 !important; /* space between the two lines */
  letter-spacing: .065em;
  text-transform: uppercase;
  text-wrap: balance;
  color: #fff;
  line-height: 1.2;
  font-weight: 600;
  width: 100%;
}
/* Reduce proclamation size to ~80% of previous */

#preload .preload-1 { 
  font-size: clamp(2.4rem, 5vw, 5rem) !important; /* Was 6.5rem max — now 5rem */
}

#preload .preload-2 { 
  font-size: clamp(2rem, 5vw, 5rem) !important; /* Was 5rem max — now 4rem */
}


/* Slower, ceremonial reveal */
@keyframes preload-rise { from { opacity:0; transform: translateY(10px); } to { opacity:1; transform:none; } }
.preload-1{ opacity:0; animation: preload-rise 1s ease-out 400ms forwards; }
.preload-2{ opacity:0; animation: preload-rise 1.1s ease-out 1600ms forwards; }

/* No underline between them */
.preload-1 strong, .preload-2 strong{ box-shadow: none !important; }

/* Horizontal faded banner cloth — grain + shadow, not vertical */
.cloth-banner{
  grid-area: treasury;                 /* same grid slot the treasury used */
  position: relative;
  isolation: isolate;                  /* keep effects contained */
  aspect-ratio: 16 / 9;                /* horizontal banner shape */
  overflow: hidden;                    /* hide masks outside */
  border-radius: 10px;                 /* gentle rounding like cloth curl */
  box-shadow:
    0 10px 24px rgba(0,0,0,.28),       /* depth shadow */
    0 2px 0 rgba(0,0,0,.12) inset;     /* subtle inner weight */
}

/* Use <img> so browsers can lazy/decode efficiently; style it like bg */
.cloth-banner > img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  filter: saturate(.9) contrast(.95) brightness(.92);  /* faded print */
  opacity:.92;
  transform: translateZ(0);            /* crisper on some GPUs */
}

/* Soft edge fade (top & bottom) like worn cloth */
.cloth-banner::before{
  content:"";
  position:absolute; inset:0;
  background:
    linear-gradient(to bottom,
      rgba(0,0,0,.35), rgba(0,0,0,0) 18%, rgba(0,0,0,0) 82%, rgba(0,0,0,.35));
  mix-blend-mode:multiply;
  pointer-events:none;
}

/* Fine grain / canvas texture */
.cloth-banner::after{
  content:"";
  position:absolute; inset:0;
  pointer-events:none;
  background:
    /* dither-grain */
    repeating-linear-gradient(0deg, rgba(255,255,255,.02) 0 2px, rgba(0,0,0,.02) 2px 4px),
    /* subtle canvas weave */
    repeating-linear-gradient(90deg, rgba(0,0,0,.015) 0 1px, transparent 1px 3px);
  mix-blend-mode:multiply;
  opacity:.7;
}

/* Optional: faint stitched hems top and bottom (comment out if not wanted) */
.cloth-banner .hem{
  position:absolute; left:6%; right:6%;
  height:1px; background:rgba(0,0,0,.25);
  box-shadow: 0 1px 0 rgba(255,255,255,.2) inset;
}
.cloth-banner .hem.top{ top:10px; opacity:.6; }
.cloth-banner .hem.bot{ bottom:10px; opacity:.6; }

/* Hover (desktop): whisper of lift without being UI-ish */
@media (hover:hover){
  .cloth-banner:hover{ box-shadow:
    0 16px 32px rgba(0,0,0,.32),
    0 2px 0 rgba(0,0,0,.12) inset; }
}

/* Wrapper holds both the cloth media (clipped) and the caption (not clipped) */
.cloth-banner{
  grid-area: treasury;
  margin: 0;           /* figure default margins can be odd; normalize */
}

/* The clipped, textured banner box */
.cloth-media{
  position: relative;
  aspect-ratio: 16 / 9;          /* visible height */
  overflow: hidden;              /* clip only the image + overlays */
  border-radius: 10px;
  box-shadow:
    0 10px 24px rgba(0,0,0,.28),
    0 2px 0 rgba(0,0,0,.12) inset;
  isolation: isolate;
}

.cloth-media > img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  filter: saturate(.65) contrast(.95) brightness(.92);
  opacity:.92;
  transform: translateZ(0);
}

/* Optional grain / edge fade – if you added these before, target .cloth-media::before/::after */
.cloth-media::before{
  content:"";
  position:absolute; inset:0;
  background:
    linear-gradient(to bottom,
      rgba(0,0,0,.35), rgba(0,0,0,0) 18%, rgba(0,0,0,0) 82%, rgba(0,0,0,.35));
  mix-blend-mode:multiply;
  pointer-events:none;
}
.cloth-media::after{
  content:"";
  position:absolute; inset:0; pointer-events:none;
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,.02) 0 2px, rgba(0,0,0,.02) 2px 4px),
    repeating-linear-gradient(90deg, rgba(0,0,0,.015) 0 1px, transparent 1px 3px);
  mix-blend-mode:multiply;
  opacity:.7;
}

/* Caption now sits below the clipped box, so it will show */
.cloth-caption{
  margin-top: .8rem;
  text-align: center;
  font-size: .95rem;
  line-height: 1.4;
  opacity: .8;
  font-style: italic;
  color: currentColor;     /* inherits site text color; adjust if needed */
}

/* --- CLOTH BANNER: final overrides --- */

/* The wrapper holds visual + caption; DO NOT clip here */
.cloth-banner{
  grid-area: treasury;
  margin: 0;
  overflow: visible !important;
  aspect-ratio: auto !important;
}

/* Kill any old pseudo-layers that were attached to .cloth-banner itself */
.cloth-banner::before,
.cloth-banner::after{ content: none !important; }

/* The visual “cloth” box: this is where we clip, texture, shadow */
.cloth-media{
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 10px;
  isolation: isolate;
  box-shadow:
    0 10px 24px rgba(0,0,0,.28),
    0 2px 0 rgba(0,0,0,.12) inset;
}
.cloth-media > img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  filter: saturate(.7) contrast(.95) brightness(.92);
  transform: translateZ(0);
  opacity:.92;
}
/* Edge fade + grain live on the media box (not the wrapper) */
.cloth-media::before{
  content:"";
  position:absolute; inset:0;
  background:
    linear-gradient(to bottom,
      rgba(0,0,0,.35), rgba(0,0,0,0) 18%, rgba(0,0,0,0) 82%, rgba(0,0,0,.35));
  mix-blend-mode:multiply;
  pointer-events:none;
}
.cloth-media::after{
  content:"";
  position:absolute; inset:0;
  pointer-events:none;
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,.02) 0 2px, rgba(0,0,0,.02) 2px 4px),
    repeating-linear-gradient(90deg, rgba(0,0,0,.015) 0 1px, transparent 1px 3px);
  mix-blend-mode:multiply;
  opacity:.7;
}

/* Caption sits outside the clipped box, so it will show */
.cloth-caption {
  margin-top: .8rem;
  margin-bottom: 1rem; /* <-- this creates a full clear visual break */
  text-align: center;
  font-size: .95rem;
  line-height: 1.4;
  opacity: .8;
  font-style: italic;
  color: currentColor;
}

/* Structure */
.treasury-block { margin-top: 16px; }
.treasury-status { margin: 10px 0 14px; }
.center { text-align: center; }

/* Stats as a tidy 3-up grid */
.stats {
  display: grid; gap: 10px;
  grid-template-columns: repeat(3, minmax(0,1fr));
  margin: 0 0 10px; padding: 0;
}
.stats .stat { background: rgba(0,0,0,0.04); border-radius: 8px; padding: 10px; text-align: center; }
.stats dt { font-size: .8rem; opacity: .7; }
.stats dd { margin: 4px 0 0; font-weight: 600; font-size: 1.1rem; }

/* Progress */
.progress-wrap {
  height: 8px; background: rgba(0,0,0,0.15);
  border-radius: 4px; overflow: hidden; margin: 6px auto 6px; max-width: 600px;
}
.progress-bar { height: 100%; background: var(--accent,#8b6a3d); width: 0%; }

/* Actions */
.treasury-actions {
  display: flex; flex-wrap: wrap; gap: 12px;
  justify-content: center; margin: 12px 0 14px;
}

/* Pledge */
.pledge-card .pill-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.visually-hidden { position: absolute !important; height: 1px; width: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }

.rounded-frame {
  overflow: hidden; /* Ensures the image is clipped to the rounded shape */
  border-radius: 12px; /* Adjust this: 8px = subtle, 20px = softer, 30px = old-photo feel */
  border: 2px solid rgba(0,0,0,0.2); /* Optional soft frame edge */
  box-shadow: 0 4px 14px rgba(0,0,0,0.25); /* Subtle depth */
  display: inline-block; /* Keeps it sized to the image */
}

.rounded-frame img {
  display: block;
  width: 100%;
  height: auto;
}

.correspondence-form {
  display: grid;
  gap: 12px;
  max-width: 600px;
  margin-top: 14px;
}

.correspondence-form input,
.correspondence-form textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid rgba(0,0,0,0.2);
  background: rgba(255,255,255,0.7);
  font-family: inherit;
}

.correspondence-form button {
  margin-top: 6px;
}

/* === NAV: lock permanently to top (final override) === */
:root{ --header-h: 80px; } /* adjust to your real header height */

header.nav{
  position: fixed !important;
  top: 0; left: 0; right: 0;
  height: var(--header-h) !important;
  z-index: 9999 !important;
  background: var(--navBg, rgba(16,56,74,0.92)) !important; /* readable */
  border-bottom: 1px solid var(--line) !important;
  display: flex; align-items: center;
}

header.nav .row{
  height: 100%;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0; /* header height is controlled by --header-h */
}

/* Push the document down so it doesn't slide under the fixed header */
body{ padding-top: var(--header-h) !important; }

header.nav .row {
  display: flex;
  align-items: center;
}

/* === Header: push nav to the right (scoped overrides) === */
header.nav .container,
header.nav .row{
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important; /* brand left */
  text-align: initial !important;         /* kill inherited centering */
}

header.nav .brand{
  display: inline-flex;
  align-items: center;
}



/* === NAV: final, single source of truth (place last) === */
:root { --header-h: 80px; }

/* Keep header fixed and sized */
header.nav{
  position: fixed !important;
  top: 0; left: 0; right: 0;
  height: var(--header-h) !important;
  z-index: 9999 !important;
  background: var(--navBg, rgba(16,56,74,0.92)) !important;
  border-bottom: 1px solid var(--line) !important;
  display: flex !important;
  align-items: center !important;
}

/* Make the row a flex row and stop any inherited centering */
header.nav .container,
header.nav .row{
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;  /* push content to the right */
  text-align: initial !important;        /* kill any text-align:center */
  width: 100% !important;
  padding: 0 !important;
  margin: 0 auto !important;
}

/* If you have a logo/brand element, this pins it left and keeps nav right */
header.nav .brand{ 
  margin-right: auto !important; 
  display: inline-flex !important; 
  align-items: center !important; 
}

/* The nav block itself: a compact row, not full-width */
header.nav nav{
  margin-left: auto !important;          /* hard push to right */
  display: flex !important;
  gap: 18px !important;
  width: auto !important;
  text-align: right !important;
}

/* Ensure main content doesn't hide under fixed header */
body{ padding-top: var(--header-h) !important; }

/* Hide nav bar while preload is active */
#preload.active ~ header.nav,
#preload:not(.done) ~ header.nav {
  display: none !important;
}





/* --- Responsive nav toggle --- */
header.nav { position: sticky; top:0; z-index:30; }
header.nav .row { display:flex; align-items:center; justify-content:flex-end; gap:16px; }

/* Toggle button */
.nav-toggle{
  display:none; /* default hidden on wide screens */
  border:1px solid var(--line);
  background: var(--card);
  border-radius: 10px;
  padding: 8px 10px;
  cursor:pointer;
}
.nav-toggle .bar{
  display:block; width:22px; height:2px; background:#fff; margin:5px 0;
}

/* Collapsed state driven by a data-attribute on header */
header.nav[data-collapsed="true"] .nav-toggle{ display:inline-flex; }
header.nav[data-collapsed="true"] nav#primary-nav{
  position: absolute;
  top: 100%; right: 16px; left: 16px;
  background: var(--navBg, rgba(16,56,74,0.92));
  border:1px solid var(--line);
  border-radius: 12px;
  padding: 10px;
  display: none;               /* hidden until opened */
  flex-direction: column;
  gap: 8px;
}
header.nav[data-collapsed="true"] nav#primary-nav.open{ display:flex; }

header.nav[data-collapsed="true"] nav#primary-nav a{
  color:#f4f8ff; padding:8px 10px; border-radius:8px;
}
header.nav[data-collapsed="true"] nav#primary-nav a:hover{
  background: rgba(255,255,255,0.08);
}

/* On wide layouts, keep the inline row look */
@media (min-width: 780px){
  header.nav[data-collapsed="false"] nav#primary-nav a{ margin-left:20px; }
}




/* --- Hamburger toggle --- */
.nav-toggle{
  display:none; /* visible only when collapsed */
  border:1px solid var(--line);
  background: var(--card);
  border-radius: 10px;
  padding: 8px 10px;
  cursor:pointer;
}
.nav-toggle .bar{ display:block; width:22px; height:2px; background:#fff; margin:5px 0; }

/* Collapsed state toggled via data-attribute on header */
header.nav[data-collapsed="true"] .nav-toggle{ display:inline-flex; }
header.nav[data-collapsed="true"] nav#primary-nav{
  position: absolute;
  top: 100%;
  right: 16px; left: 16px;
  background: var(--navBg, rgba(16,56,74,0.92));
  border:1px solid var(--line);
  border-radius: 12px;
  padding: 10px;
  display: none;                 /* closed by default */
  flex-direction: column;
  gap: 8px;
}
header.nav[data-collapsed="true"] nav#primary-nav.open{ display:flex; }
header.nav[data-collapsed="true"] nav#primary-nav a{
  color:#f4f8ff; padding:8px 10px; border-radius:8px;
}
header.nav[data-collapsed="true"] nav#primary-nav a:hover{
  background: rgba(255,255,255,0.08);
}

/* Hide the top nav links on narrow screens */
@media (max-width: 1030px) {
  header.nav nav[aria-label="Primary"] {
    display: none !important;
  }
}


/* Force the Declaration download button to use the default primary styling */
#charter .btn.primary {
  background: var(--accent) !important;
  border-color: var(--accent) !important;
  color: #fff !important;
}



  @keyframes preloadShow {
    0%, 80%   { opacity: 1; visibility: visible; pointer-events: auto; }
    100%      { opacity: 0; visibility: hidden; pointer-events: none; }
  }
}

#preload { animation: preloadFadeIn 300ms ease-out; }
#preload.fade-out { animation: preloadFadeOut 420ms ease-in forwards; }


/* Hard anchor the Eureka flag to the far right of header */
.nav-flag-absolute {
  position: absolute;
  right: 20px;          /* adjust distance from edge */
  top: 50%;
  transform: translateY(-50%);
  height: 60px;         /* adjust size as needed */
  width: auto;
  opacity: 0.9;
  pointer-events: none; /* optional: make it decorative only */
}
.nav-flag-absolute:hover {
  opacity: 1;
}













/* Header row discipline: brand left, nav center/right, flag hard-right */
header.nav .row{
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 12px !important;
}

/* Brand pushes everything else to the right */
header.nav .brand{ margin-right: auto !important; }

/* Nav is allowed to shrink to avoid colliding with the flag */
header.nav #primary-nav{
  display: flex !important;
  gap: 18px !important;
  flex: 1 1 auto !important;   /* allow shrink */
  min-width: 0 !important;     /* enable ellipsis/wrap instead of overflow */
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
}

/* The flag occupies fixed space at the far right and cannot be overlapped */
.nav-flag-hardright{
  flex: 0 0 auto !important;
  height: 60px !important;
  width: auto !important;
  margin-left: 12px !important;
  margin-right: 50px !important;
  opacity: .95;
}

/* Optional: on tighter widths, let nav wrap to a second line before the flag */
@media (max-width: 1080px){
  header.nav #primary-nav{
    white-space: normal !important;   /* allow wrapping */
  }
}

/* If you use the collapsed/hamburger mode, keep the flag visible and separate */
header.nav[data-collapsed="true"] #primary-nav{ width: auto !important; }







/* Treasury split layout */
.pledge-card .pledge-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 900px){
  .pledge-card .pledge-grid{
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

/* Stretch list spacing */
.stretch-list{
  margin: 8px 0 0;
  padding-left: 18px;
}
.stretch-list li{ margin: 6px 0; }

/* Optional visual separation on dark */
.pledge-right{
  border-left: 1px solid var(--cardLine);
  padding-left: 16px;
}
@media (max-width: 899px){
  .pledge-right{
    border-left: none;
    padding-left: 0;
    border-top: 1px solid var(--cardLine);
    padding-top: 12px;
  }
}

/* Collapsed by default; opens on click. Style summary like a button */
#witnessRoll > summary.btn {
  list-style: none;
  cursor: pointer;
  user-select: none;
}
#witnessRoll > summary.btn::-webkit-details-marker { display: none; }

/* Ledger look */
.ledger-list { 
  margin: 8px 0 0; padding: 0; list-style: none; 
  border-top: 1px solid var(--line);
}
.ledger-list li {
  padding: 10px 0; 
  border-bottom: 1px solid var(--line);
}