/* ══════════════════════════════════════════════════════
   NAGARIK — India Political Directory
   Design: Modern · Minimal · Indian · Premium
   ══════════════════════════════════════════════════════ */

/* ── DESIGN TOKENS ──
   Palette: "Civic paper + Chakra blue".
   The primary accent is drawn from the Ashoka Chakra navy — the most
   politically neutral color in Indian civic identity (saffron and green
   both read as party colors). Keep accents tokenized; never hard-code. */
:root {
  color-scheme: light;
  --bg:        #F6F7FB;
  --surf:      #FFFFFF;
  --surf2:     #EEF0F6;
  --surf3:     #E2E5EF;
  --bdr:       rgba(20,24,43,0.07);
  --bdr2:      rgba(20,24,43,0.14);
  --txt:       #14182B;
  /* WCAG: --mut must hold ≥4.5:1 on --bg — it labels meaningful small text
     (section heads, legal, constituency names), not just decoration. */
  --mut:       rgba(20,24,43,0.60);
  --mut2:      rgba(20,24,43,0.72);
  --acc:       #3B4FD8;
  --acc-rgb:   59 79 216;
  --on-acc:    #FFFFFF;
  --acc2:      #15803D;
  --acc2-rgb:  21 128 61;
  --acc-dim:   rgba(59,79,216,0.08);
  --r-sm:      10px;
  --r:         16px;
  --r-lg:      24px;
  --r-xl:      32px;
  --ease:      cubic-bezier(.32,.72,.24,1);
  --shadow-xs: 0 1px 2px rgba(18,24,58,0.05);
  --shadow-sm: 0 1px 3px rgba(18,24,58,0.05), 0 3px 10px rgba(18,24,58,0.06);
  --shadow:    0 2px 8px rgba(18,24,58,0.07), 0 8px 28px rgba(18,24,58,0.07);
  --shadow-lg: 0 4px 20px rgba(18,24,58,0.10), 0 20px 56px rgba(18,24,58,0.10);
}
[data-theme="dark"] {
  /* Native selects, scrollbars, and form controls render dark too. */
  color-scheme: dark;
  --bg:        #0C0E16;
  /* Surfaces sit a touch higher and borders a touch brighter than the
     light theme's ratios — shadow-based elevation barely reads on dark,
     so separation must come from surface + border contrast. */
  --surf:      #151A2B;
  --surf2:     #1E2438;
  --surf3:     #293049;
  --bdr:       rgba(228,233,255,0.13);
  --bdr2:      rgba(228,233,255,0.24);
  --txt:       #E9ECF8;
  --mut:       rgba(233,236,248,0.62);
  --mut2:      rgba(233,236,248,0.80);
  --acc:       #93A5FF;
  --acc-rgb:   147 165 255;
  --on-acc:    #0C0E16;
  --acc2:      #5BD992;
  --acc2-rgb:  91 217 146;
  --acc-dim:   rgba(147,165,255,0.13);
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.42);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.42), 0 8px 22px rgba(0,0,0,0.28);
  --shadow:    0 2px 10px rgba(0,0,0,0.45), 0 16px 44px rgba(0,0,0,0.34);
  --shadow-lg: 0 6px 24px rgba(0,0,0,0.52), 0 28px 70px rgba(0,0,0,0.42);
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
*:focus-visible { outline: 2.5px solid var(--acc); outline-offset: 3px; border-radius: 6px; }
/* Views receive programmatic focus on navigation — no ring needed there. */
.view:focus { outline: none; }
.skip-link {
  position:fixed; top:-48px; left:16px; z-index:300;
  padding:10px 18px; border-radius:0 0 12px 12px;
  background:var(--acc); color:var(--on-acc);
  font-size:13px; font-weight:700; text-decoration:none;
  transition:top .15s ease;
}
.skip-link:focus { top:0; }
::selection { background: rgb(var(--acc-rgb) / .18); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}

/* ── INTERACTION STATES ── */
:where(button, select, a, [role="button"]) {
  -webkit-tap-highlight-color: transparent;
}
:where(button, select, .wiki-btn, .btn-primary, .btn-secondary, .vm-btn, .dl-btn, .party-pill, .nav-btn, .icon-btn, .lang-toggle, .back, .bt, .my-state-select) {
  min-height: 36px;
}
:where(button, .wiki-btn, .btn-primary, .btn-secondary, .vm-btn, .dl-btn, .party-pill, .nav-btn, .icon-btn, .lang-toggle, .back, .bt, .economy-source, .proj-src, .elec-src, .change-state-link, [role="button"]) {
  touch-action: manipulation;
}
:where(button, .wiki-btn, .btn-primary, .btn-secondary, .vm-btn, .dl-btn, .party-pill, .nav-btn, .icon-btn, .lang-toggle, .back, .bt, .economy-source, .proj-src, .elec-src, .change-state-link):active {
  transform: translateY(1px);
}
:where(.lcard, .cm-card, .pm-card, .minister-card, .sr-card, .search-state-shortcut, .state-list-card, .past-leader-row):active {
  transform: translateY(0);
  box-shadow: var(--shadow-xs);
}
:where(button, .wiki-btn, .btn-primary, .btn-secondary, .vm-btn, .dl-btn, .party-pill, .nav-btn, .icon-btn, .lang-toggle, .back, .bt, .my-state-select, .economy-source, .proj-src, .elec-src, .change-state-link, .lcard, .cm-card, .pm-card, .minister-card, .sr-card, .search-state-shortcut, .state-list-card, .past-leader-row):focus-visible {
  outline: 2.5px solid var(--acc);
  outline-offset: 3px;
  box-shadow: 0 0 0 4px var(--acc-dim);
}
:where(button, .btn-primary, .btn-secondary, .vm-btn, .dl-btn, .party-pill, .nav-btn, .icon-btn, .lang-toggle, .back, .bt):disabled,
:where(button, .btn-primary, .btn-secondary, .vm-btn, .dl-btn, .party-pill, .nav-btn, .icon-btn, .lang-toggle, .back, .bt)[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: .48;
  transform: none;
  box-shadow: none;
}

/* ── BASE ── */
body {
  background: var(--bg); color: var(--txt);
  font-family: 'Plus Jakarta Sans', sans-serif; font-size: 15px; line-height: 1.6;
  min-height: 100vh; overflow-x: hidden;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}

/* ══════════════════════════════════════════════════════
   HEADER
   ══════════════════════════════════════════════════════ */
/* Frosted strip behind the floating header: blurs + fades page content
   at the very top so it never scrolls past the capsule un-blurred. */
body::before {
  content:''; position:fixed; top:0; left:0; right:0; height:92px;
  z-index:199; pointer-events:none;
  backdrop-filter:blur(14px) saturate(1.4);
  -webkit-backdrop-filter:blur(14px) saturate(1.4);
  background:linear-gradient(to bottom, rgb(246 247 251 / .92) 30%, rgb(246 247 251 / 0));
  mask-image:linear-gradient(to bottom, #000 55%, transparent);
  -webkit-mask-image:linear-gradient(to bottom, #000 55%, transparent);
}
[data-theme="dark"] body::before {
  background:linear-gradient(to bottom, rgb(12 14 22 / .92) 30%, rgb(12 14 22 / 0));
}

/* Floating pill header — detached capsule below the top edge
   (reference: Sarvam-style header the user shared). */
header {
  position: fixed; top: 12px; left: 50%; transform: translateX(-50%);
  z-index: 200;
  width: calc(100% - 32px); max-width: 1280px;
  height: 62px;
  display: flex; align-items: center; justify-content: space-between;
  /* Equal inset on both ends so the logo (left) and the theme/language
     controls (right) sit symmetrically, nudged slightly inward. */
  padding: 0 24px;
  /* Glassmorphism: low-opacity fill + heavy blur/saturation, a bright
     top-edge highlight, and a soft drop shadow so content glows through. */
  background: linear-gradient(rgba(255,255,255,0.55), rgba(255,255,255,0.42));
  backdrop-filter: blur(28px) saturate(2);
  -webkit-backdrop-filter: blur(28px) saturate(2);
  border: 1px solid rgba(255,255,255,0.65);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255,255,255,0.75);
  border-radius: 999px;
}
[data-theme="dark"] header {
  background: linear-gradient(rgba(26,30,48,0.55), rgba(16,19,32,0.48));
  border-color: rgba(228,233,255,0.14);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(228,233,255,0.08);
}

.logo { display: flex; align-items: center; gap: 11px; cursor: pointer; text-decoration: none; }
.logo-mark { width: 30px; height: 30px; flex-shrink: 0; display: block; }
/* Latin "Nagarik" renders in Fraunces; Devanagari "नागरिक" falls through to Tiro */
.logo-n { font-family:'Fraunces','Tiro Devanagari Hindi',serif; font-optical-sizing:auto; font-weight:600; letter-spacing:-0.01em; font-size:19px; line-height:1.2; color:var(--txt); }
.logo-s { font-size:9px; color:var(--mut); letter-spacing:.2em; text-transform:uppercase; margin-top:-1px; }

.header-nav { display:flex; gap:2px; }
.nav-btn {
  padding:9px 16px; background:none; border:none; border-radius:999px;
  font-size:11.5px; font-weight:600; color:var(--mut2); cursor:pointer;
  font-family:'Plus Jakarta Sans',sans-serif; transition:all .16s;
  letter-spacing:.08em; text-transform:uppercase;
}
.nav-btn:hover { color:var(--txt); background:var(--surf2); }
.nav-btn.active,
.nav-btn[aria-current="page"] { color:var(--acc); background:var(--acc-dim); box-shadow:inset 0 0 0 1px rgb(var(--acc-rgb) / .22); }
.nav-btn.active:hover,
.nav-btn[aria-current="page"]:hover { color:var(--acc); background:rgb(var(--acc-rgb) / .16); }

.header-actions { display:flex; align-items:center; gap:8px; }
.icon-btn {
  width:36px; height:36px; background:none; border:1px solid var(--bdr2);
  border-radius:10px; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
  transition:all .16s; color:var(--mut2);
}
.icon-btn svg { pointer-events:none; flex-shrink:0; }
.icon-btn:hover { border-color:var(--acc); background:var(--acc-dim); }
.icon-btn:active { border-color:var(--acc); background:rgb(var(--acc-rgb) / .18); }
.lang-toggle {
  height:36px; background:none; border:1px solid var(--bdr2);
  border-radius:10px; cursor:pointer; transition:border-color .16s;
  padding:0; overflow:visible; display:flex; align-items:stretch;
}
.lt-en, .lt-hi {
  display:flex; align-items:center; justify-content:center;
  padding:0 11px; font-size:11px; font-weight:600;
  color:var(--mut2); line-height:1; transition:background .16s, color .16s;
  white-space:nowrap;
}
.lt-en { border-radius:9px 0 0 9px; border-right:1px solid var(--bdr); }
.lt-hi { border-radius:0 9px 9px 0; font-family:'Tiro Devanagari Hindi',serif; font-size:14px; }
.lang-toggle[data-lang="en"] .lt-en {
  background:var(--acc-dim); color:var(--acc);
  box-shadow:inset 0 0 0 1px rgb(var(--acc-rgb) / .22);
}
.lang-toggle[data-lang="hi"] .lt-hi {
  background:var(--acc-dim); color:var(--acc); font-weight:700;
  box-shadow:inset 0 0 0 1px rgb(var(--acc-rgb) / .22);
}
.lang-toggle:hover { border-color:var(--acc); }
.lang-toggle:active { background:var(--acc-dim); }

/* ══════════════════════════════════════════════════════
   VIEWS
   ══════════════════════════════════════════════════════ */
.main { padding-top:88px; }
.view { display:none; }
.view.active { display:block; }

/* ══════════════════════════════════════════════════════
   HOME — HERO
   ══════════════════════════════════════════════════════ */
.home-hero {
  position:relative; overflow:hidden;
  /* Pull up behind the floating header so the hero background reaches the
     very top of the page — no bare strip above the tinted gradient. */
  margin-top:-88px;
  padding: calc(96px + 88px) 24px 72px;
  text-align: center;
  background: linear-gradient(165deg,
    rgb(var(--acc-rgb) / 0.06) 0%,
    transparent 40%,
    rgb(var(--acc-rgb) / 0.04) 100%
  ), var(--bg);
  border-bottom:1px solid var(--bdr);
}
/* Decorative civic-leadership motif — a minimal Parliament colonnade
   (dome + columns) as stroke-only line art, mirrored on BOTH bottom
   corners so the hero feels balanced. Keep it quiet: low opacity,
   cropped by overflow:hidden, never competing with headline/search. */
.home-hero::before,
.home-hero::after {
  content:''; pointer-events:none; position:absolute;
  width:380px; height:222px;
  bottom:-36px;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 70'%3E%3Cg stroke='%233B4FD8' stroke-width='1' stroke-linecap='round' fill='none'%3E%3Cpath d='M24 26 A 38 38 0 0 1 96 26'/%3E%3Cpath d='M52 12 A 9 9 0 0 1 68 12'/%3E%3Cline x1='12' y1='30' x2='108' y2='30'/%3E%3Cline x1='18' y1='36' x2='18' y2='60'/%3E%3Cline x1='30' y1='36' x2='30' y2='60'/%3E%3Cline x1='42' y1='36' x2='42' y2='60'/%3E%3Cline x1='54' y1='36' x2='54' y2='60'/%3E%3Cline x1='66' y1='36' x2='66' y2='60'/%3E%3Cline x1='78' y1='36' x2='78' y2='60'/%3E%3Cline x1='90' y1='36' x2='90' y2='60'/%3E%3Cline x1='102' y1='36' x2='102' y2='60'/%3E%3Cline x1='8' y1='64' x2='112' y2='64'/%3E%3C/g%3E%3C/svg%3E");
  background-size:contain; background-repeat:no-repeat;
  opacity:.055;
}
.home-hero::before { left:-60px; }
.home-hero::after  { right:-60px; }
[data-theme="dark"] .home-hero::before,
[data-theme="dark"] .home-hero::after { opacity:.09; filter:invert(1) hue-rotate(180deg); }

.home-hero-inner { position:relative; z-index:1; max-width:1120px; margin:0 auto; }

.home-title {
  font-family:'Fraunces',serif;
  font-optical-sizing: auto;
  font-size: clamp(40px, 6.4vw, 80px);
  font-weight: 550;
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin-bottom: 16px;
  color: var(--txt);
  /* Simple centered text — no flex, no reserved slot that causes overflow */
  text-align: center;
  white-space: nowrap;
}
.home-title .title-ticker {
  color: var(--acc); font-style:normal;
  display: inline-block;
  font-family:'Tiro Devanagari Hindi',serif;
  vertical-align: baseline;
  white-space: nowrap;
  /* Pure opacity crossfade — no translate, no reserved slot needed */
  transition: opacity .3s ease;
  will-change: opacity;
}
.home-title .title-ticker.ticker-out { opacity:0; }
.home-title .title-ticker.ticker-in  { opacity:1; }

.home-sub {
  font-size:16px; color:var(--mut2); line-height:1.65;
  margin:0 auto 36px; max-width:640px; white-space:nowrap;
}

/* Search */
.search-wrap.home-search {
  position:relative; max-width:560px; margin:0 auto 24px; padding:0;
}
.home-search .search-input {
  width:100%; padding:16px 24px 16px 52px;
  font-size:16px; font-family:'Plus Jakarta Sans',sans-serif;
  border-radius:100px; /* full pill */
  background:var(--surf); border:1.5px solid var(--bdr2);
  color:var(--txt); outline:none;
  transition:border-color .2s, box-shadow .2s;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}
.home-search .search-input:focus {
  border-color:var(--acc);
  box-shadow: 0 0 0 4px var(--acc-dim), 0 4px 24px rgba(0,0,0,0.08);
}
[data-theme="dark"] .home-search .search-input {
  box-shadow:0 10px 32px rgba(0,0,0,0.34);
}
[data-theme="dark"] .home-search .search-input:focus {
  box-shadow:0 0 0 4px rgb(var(--acc-rgb) / .18), 0 12px 36px rgba(0,0,0,0.38);
}
.home-search .search-input::placeholder { color:var(--mut); }
.home-search .search-icon { position:absolute; left:20px; top:50%; transform:translateY(-50%); width:18px; height:18px; color:var(--mut); pointer-events:none; }
.home-search .search-results {
  position:absolute; top:calc(100% + 10px); left:0; right:0; z-index:400;
  background:var(--surf); border:1px solid var(--bdr2);
  border-radius:20px; box-shadow:var(--shadow-lg);
  max-height:480px; overflow-y:auto; padding:8px;
}
.home-search .search-results.hidden { display:none; }

/* Stats */
.home-stats {
  display:flex; align-items:center; justify-content:center;
  flex-wrap:wrap; gap:10px 14px; max-width:1080px;
  margin:0 auto; font-size:14px; color:var(--mut2);
}
.home-stats strong { color:var(--txt); font-family:'Spline Sans Mono',monospace; font-weight:700; font-size:16px; }
.home-stat-pill {
  min-height:42px; display:inline-flex; align-items:center; justify-content:center;
  gap:6px; padding:8px 18px; border:1px solid var(--bdr);
  border-radius:100px; background:var(--surf);
  box-shadow:var(--shadow-xs); white-space:nowrap;
}
.home-stat-wide {
  width:max-content; max-width:100%;
}

/* ══════════════════════════════════════════════════════
   MAP SECTION
   ══════════════════════════════════════════════════════ */
.home-map-zone { background:var(--bg); border-top:1px solid var(--bdr); }
/* Map header row, aligned to the 1040px content column. Generous spacing —
   chip + hint live left, the Map/List toggle anchors the right. */
.map-zone-header {
  width:min(1040px, calc(100% - 32px)); margin:0 auto; padding:30px 0 16px;
  /* Equal 1fr side columns keep the centre column (the hint) screen-centered
     regardless of how wide the chip / toggle are. */
  display:grid; grid-template-columns:1fr auto 1fr; align-items:center;
  gap:14px 20px;
}
.map-zone-left { display:flex; align-items:center; gap:12px 22px; flex-wrap:wrap; min-width:0; justify-self:start; }
.map-zone-header > .map-hint { justify-self:center; }
.map-zone-header > .browse-toggle { justify-self:end; }
/* Single action cue for the map zone — quiet plain text, the animated
   arrow carries the "look down" gesture. */
.map-hint {
  display:inline-flex; align-items:center; gap:8px;
  font-size:12.5px; font-weight:600; color:var(--mut2); text-align:center;
}
.map-hint svg { width:13px; height:13px; flex:0 0 auto; color:var(--acc); animation:hintBob 2.4s var(--ease) infinite; }
@keyframes hintBob { 0%,100% { transform:translateY(-1.5px); } 50% { transform:translateY(1.5px); } }
@media (prefers-reduced-motion: reduce) { .map-hint svg { animation:none; } }
.map-wrap {
  width:100%; max-width:none; margin:0 auto;
  padding:4px clamp(12px,3vw,32px) 56px;
  position:relative; overflow:visible;
}
.map-viewport {
  position:relative; overflow:hidden;
  width:100%; max-width:1440px;
  height:clamp(620px, calc(100vh - 112px), 940px);
  margin:0 auto;
  border-radius:14px;
  touch-action:pan-y;
}
@media(min-width:700px) {
  .map-wrap {
    min-height:calc(clamp(620px, calc(100vh - 112px), 940px) + 28vh);
  }
  .map-viewport {
    position:sticky;
    top:88px;
    z-index:20;
  }
}
/* pan-y: vertical swipes must scroll the page (no scroll trap on phones);
   the JS pan/zoom handlers only consume horizontal drags and ctrl+wheel. */
#india-map { width:100%; height:100%; cursor:pointer; display:block; touch-action:pan-y; overflow:hidden; }
#india-map.map-zoomed { cursor:grab; }
#india-map.map-panning { cursor:grabbing; }
.map-controls {
  position:absolute; bottom:20px; z-index:5;
  /* Right edge tracks the centered 1040px content column (economy box). */
  right:max(16px, calc((100% - 1040px) / 2));
  width:max-content; max-width:calc(100% - 36px); margin:0;
  display:flex; align-items:center; gap:5px;
  padding:4px; border:1px solid var(--bdr); border-radius:999px;
  background:color-mix(in srgb, var(--surf) 92%, transparent);
  box-shadow:var(--shadow-sm); backdrop-filter:blur(12px);
}
[data-theme="dark"] .map-controls {
  background:color-mix(in srgb, var(--surf) 88%, transparent);
  border-color:var(--bdr2);
}
/* −/+ are equal boxed circles (SVG icons, dead-centre) flanking a
   fixed-width % readout; FIT sits apart behind a hairline divider. */
.map-control-btn {
  /* min-height overrides the global 36px button floor — these must be
     perfect circles (width = height), not ovals. */
  width:28px; min-width:28px; height:28px; min-height:28px; padding:0;
  border:1px solid var(--bdr); border-radius:999px;
  display:inline-flex; align-items:center; justify-content:center;
  background:var(--surf2); color:var(--txt);
  cursor:pointer; transition:background .15s ease, border-color .15s ease, color .15s ease, transform .12s ease;
}
.map-control-btn svg { width:12px; height:12px; display:block; }
.map-control-reset {
  width:auto; min-width:42px; padding:0 12px;
  font-family:'Plus Jakarta Sans',sans-serif; line-height:1;
  font-size:10px; letter-spacing:.05em; text-transform:uppercase; font-weight:700;
  margin-left:9px; position:relative;
}
.map-control-reset::before {
  content:''; position:absolute; left:-7px; top:6px; bottom:6px;
  width:1px; background:var(--bdr2);
}
.map-zoom-level {
  min-width:40px; text-align:center; color:var(--mut2);
  font-family:'Spline Sans Mono',monospace; font-size:10.5px; font-weight:700; line-height:1;
}
.map-control-btn:hover { background:var(--surf2); border-color:var(--bdr2); color:var(--acc); }
.map-control-btn:active { transform:translateY(1px); background:var(--acc-dim); border-color:var(--acc); }
.map-control-btn:focus-visible { outline:2px solid var(--acc); outline-offset:2px; }

/* Economy context */
.economy-panel {
  max-width:1040px; margin:0 auto 72px; padding:28px;
  display:grid; grid-template-columns:minmax(250px,320px) minmax(0,1fr); gap:28px;
  align-items:start;
  border:1px solid var(--bdr); border-radius:var(--r-lg);
  background:var(--surf);
  box-shadow:var(--shadow-xs);
}
.economy-copy { align-self:start; position:static; }
.economy-kicker {
  font-size:10px; letter-spacing:.16em; text-transform:uppercase;
  color:var(--acc); font-weight:700; margin-bottom:10px;
}
.economy-copy h2 {
  font-family:'Fraunces',serif; font-optical-sizing:auto;
  font-size:clamp(24px,3.2vw,36px); line-height:1.08;
  font-weight:550; letter-spacing:-0.01em; color:var(--txt); margin-bottom:10px;
}
.economy-copy p {
  font-size:14px; color:var(--mut2); line-height:1.65;
  margin-bottom:16px; max-width:30rem;
}
.economy-live-badge {
  display:inline-flex; align-items:center; gap:7px;
  font-size:10px; font-family:'Spline Sans Mono',monospace; font-weight:700;
  border-radius:100px;
  padding:5px 11px; margin-bottom:14px;
}
.economy-live-ok {
  color:var(--acc2); background:rgb(var(--acc2-rgb) / .10);
  border:1px solid rgb(var(--acc2-rgb) / .30);
}
.economy-live-loading {
  color:var(--mut2); background:var(--surf2);
  border:1px solid var(--bdr);
}
.economy-live-fallback {
  color:var(--acc); background:var(--acc-dim);
  border:1px solid rgb(var(--acc-rgb) / .34);
}
.economy-live-snapshot {
  color:var(--acc2); background:rgb(var(--acc2-rgb) / .08);
  border:1px solid rgb(var(--acc2-rgb) / .22);
}
.economy-live-dot {
  width:6px; height:6px; border-radius:50%;
  background:currentColor; animation:blink 2s infinite;
}
.economy-source {
  display:inline-flex; align-items:center; flex-shrink:0;
  font-size:11px; font-family:'Spline Sans Mono',monospace; color:var(--acc);
  text-decoration:none; border:1px solid var(--bdr2);
  border-radius:100px; padding:6px 12px; font-weight:600;
  transition:border-color .16s, background .16s, color .16s;
}
.economy-source:hover { border-color:var(--acc); background:var(--acc-dim); color:var(--acc); }
/* Card footer: status note on the left, IMF source pill on the right —
   both INSIDE the card, below the chart. */
.economy-footer {
  grid-column:1 / -1;
  display:flex; align-items:center; justify-content:space-between;
  gap:14px; flex-wrap:wrap;
  margin-top:4px; padding-top:16px;
  border-top:1px solid var(--bdr);
}
.economy-status {
  font-size:12px; color:var(--mut2);
  line-height:1.55; min-width:0;
  position:relative; z-index:1;
}
.economy-status-fallback { color:var(--acc); }
.economy-status-snapshot { color:var(--mut2); }
.economy-chart {
  display:flex; flex-direction:column; gap:8px;
  min-width:0; text-align:left;
}
.economy-loading {
  min-height:280px; padding:36px 16px;
  display:flex; align-items:center; justify-content:center; flex-direction:column;
  border:1px dashed var(--bdr2); border-radius:var(--r);
  background:var(--surf);
}
.economy-row {
  display:grid; grid-template-columns:34px minmax(148px,210px) minmax(140px,1fr) 84px;
  align-items:center; gap:12px; min-height:44px;
  padding:8px 10px; border:1px solid transparent; border-radius:12px;
  transition:background .16s, border-color .16s, transform .16s;
  color:var(--mut2);
}
.economy-row:hover {
  background:var(--surf);
  border-color:var(--bdr);
  transform:translateY(-1px);
}
.eco-rank {
  width:30px; height:30px; display:flex; align-items:center; justify-content:center;
  border:1px solid var(--bdr); border-radius:8px;
  font-family:'Spline Sans Mono',monospace; font-size:11px; font-weight:700;
  color:var(--mut2); background:var(--surf);
}
.eco-country {
  font-size:13px; font-weight:700; color:var(--txt);
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis; text-align:left;
}
.eco-country em {
  font-family:'Tiro Devanagari Hindi',serif; font-style:normal;
  color:var(--mut); font-weight:400; margin-left:4px;
}
.eco-bar {
  height:12px; border-radius:100px; background:var(--surf2);
  overflow:hidden; border:1px solid var(--bdr); min-width:120px;
}
.eco-bar i {
  display:block; width:var(--gdp); min-width:18px; height:100%;
  border-radius:inherit; background:linear-gradient(90deg,rgb(var(--acc-rgb) / .55),var(--acc));
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.18);
}
.eco-value {
  font-family:'Spline Sans Mono',monospace; font-size:12px;
  color:var(--mut2); text-align:right; font-weight:700;
}
.economy-row-india {
  background:var(--acc-dim); border-color:rgb(var(--acc-rgb) / .30);
  box-shadow:inset 3px 0 0 var(--acc);
}
.economy-row-india .eco-rank {
  border-color:rgb(var(--acc-rgb) / .38); color:var(--acc); background:var(--surf);
}
.economy-row-india .eco-country,
.economy-row-india .eco-value { color:var(--acc); }

/* Map states */
.sp { fill:#DCDFEA; stroke:#F6F7FB; stroke-width:1; vector-effect:non-scaling-stroke; transition:fill .14s, stroke .14s; }
.sp:hover,.sp:focus-visible,.sp.sel { fill:#C5CBE2; stroke:var(--acc); stroke-width:1.8; cursor:pointer; outline:none; }
.sp-ut { fill:#D7DAE7; stroke:#F6F7FB; stroke-width:1; }
.sp-inset-territory { fill:#D4D8E5; stroke:#F6F7FB; stroke-width:1; }
.sp-inset-territory:hover,
.sp-inset-territory:focus-visible { fill:#C0C7DF; stroke:var(--acc); stroke-width:1.8; }
[data-theme="dark"] .sp { fill:#272C44; stroke:#0C0E16; stroke-width:1; }
[data-theme="dark"] .sp:hover,[data-theme="dark"] .sp:focus-visible,[data-theme="dark"] .sp.sel { fill:#363D60; stroke:var(--acc); stroke-width:1.8; }
[data-theme="dark"] .sp-ut { fill:#2C3149; stroke:#0C0E16; }
[data-theme="dark"] .sp-inset-territory { fill:#2E3350; stroke:#0C0E16; }
.map-label {
  fill:rgba(22,26,46,0.78); stroke:#F6F7FB; stroke-width:2.4px;
  paint-order:stroke; stroke-linejoin:round; vector-effect:non-scaling-stroke;
  pointer-events:none; user-select:none; font-weight:800; text-transform:uppercase;
  text-rendering:geometricPrecision;
}
.map-label-ut { fill:rgba(22,26,46,0.78); font-weight:800; }
.map-label-inset { fill:rgba(22,26,46,0.72); stroke-width:2px; }
[data-theme="dark"] .map-label { fill:rgba(233,236,248,0.86); stroke:#0C0E16; }
[data-theme="dark"] .map-label-ut { fill:rgba(233,236,248,0.90); }
[data-theme="dark"] .map-label-inset { fill:rgba(233,236,248,0.76); }

/* Tooltip */
#tip {
  position:fixed; z-index:500; pointer-events:none; display:none;
  background:var(--surf); border:1px solid var(--bdr2);
  border-radius:16px; padding:12px 18px;
  box-shadow:var(--shadow-lg); min-width:150px;
}
.tip-n    { font-size:15px; font-weight:700; color:var(--txt); margin-bottom:6px; }
.tip-row  { display:flex; flex-direction:column; gap:3px; }
.tip-seats{ font-size:12px; color:var(--acc); font-weight:700; font-family:'Spline Sans Mono',monospace; }
.tip-cap  { font-size:12px; color:var(--mut2); }

/* Municipal / urban governance tab */
.municipal-wrap { display:flex; flex-direction:column; gap:18px; }
.municipal-summary {
  display:grid; grid-template-columns:minmax(260px,1fr) minmax(220px,320px);
  gap:16px; align-items:stretch;
}
.municipal-summary,
.municipal-stat,
.municipal-project {
  border:1px solid var(--bdr); border-radius:16px;
  background:var(--surf); box-shadow:var(--shadow-sm);
}
.municipal-summary { padding:18px; }
.municipal-kicker,
.municipal-project-facts span {
  font-size:10px; letter-spacing:.14em; text-transform:uppercase;
  color:var(--mut); font-weight:700; margin-bottom:8px;
}
.municipal-body-header { display:flex; align-items:center; gap:12px; margin-bottom:7px; }
.municipal-body-logo {
  width:40px; height:40px; border-radius:8px; object-fit:contain;
  background:var(--surf2); border:1px solid var(--bdr); padding:4px; flex-shrink:0;
}
.municipal-body-header h3 { margin:0; }
.municipal-summary h3 {
  font-size:24px; line-height:1.16; color:var(--txt);
  margin:0 0 7px;
}
.municipal-summary p {
  font-size:13px; line-height:1.55; color:var(--mut2);
  margin:0;
}
.municipal-summary-source {
  margin-top:16px; padding-top:12px; border-top:1px solid var(--bdr);
  display:flex; align-items:center; flex-wrap:wrap; gap:8px 12px;
  color:var(--mut); font-size:11px; line-height:1.45;
}
.municipal-summary-source span { color:var(--mut2); font-weight:650; }
.municipal-source-inline {
  color:var(--mut2); font-size:11px; font-weight:750; text-decoration:none;
}
.municipal-source-inline:hover { color:var(--acc); text-decoration:underline; }
.municipal-status-panel {
  min-width:0; padding:14px; border-radius:14px;
  background:var(--surf2); border:1px solid var(--bdr);
  display:flex; flex-direction:column; justify-content:center; gap:7px;
}
.municipal-status-panel strong {
  color:var(--txt); font-size:18px; line-height:1.2;
}
.municipal-status-panel small,
.municipal-status-panel em {
  color:var(--mut2); font-size:12px; line-height:1.4; font-style:normal;
}
.municipal-status-panel em { color:var(--mut); font-size:11px; }
.municipal-snapshot-status {
  display:inline-flex !important; width:max-content; max-width:100%;
  border-radius:100px; padding:4px 9px;
  font-family:'Spline Sans Mono',monospace; font-size:10px !important;
  text-transform:uppercase; letter-spacing:.08em;
}
.municipal-budget-link,
.municipal-source {
  color:var(--mut2); font-weight:700; text-decoration:none;
}
.municipal-budget-link:hover,
.municipal-source:hover { color:var(--acc); text-decoration:underline; }
.municipal-source {
  display:inline-flex; align-items:center;
  width:max-content; max-width:100%;
  margin-top:auto; padding-top:8px;
  border-top:1px solid var(--bdr);
  font-size:11px;
}
.municipal-stat-row {
  display:grid; grid-template-columns:repeat(4,minmax(0,1fr));
  gap:10px;
}
.municipal-stat { padding:12px 14px; }
.municipal-stat strong {
  display:block; font-family:'Spline Sans Mono',monospace;
  font-size:22px; line-height:1; color:var(--txt); margin-bottom:5px;
}
.municipal-stat span { font-size:11px; color:var(--mut2); font-weight:700; }
.municipal-projects {
  display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:12px;
}
.municipal-project { padding:14px; display:flex; flex-direction:column; }
.municipal-project-head {
  display:flex; align-items:flex-start; justify-content:space-between;
  gap:10px 12px; margin-bottom:12px;
}
.municipal-project h4 {
  font-size:15px; line-height:1.35; color:var(--txt); margin:0;
}
.municipal-status {
  flex:0 0 auto; border-radius:100px; padding:3px 8px;
  font-size:9px; font-family:'Spline Sans Mono',monospace;
  text-transform:uppercase; font-weight:700;
}
.municipal-status-ongoing { color:var(--acc); background:var(--acc-dim); border:1px solid rgb(var(--acc-rgb) / .30); }
.municipal-status-completed { color:var(--acc2); background:rgb(var(--acc2-rgb) / .10); border:1px solid rgb(var(--acc2-rgb) / .28); }
.municipal-status-proposed { color:var(--mut2); background:var(--surf2); border:1px solid var(--bdr); }
/* Same compact metric treatment as leader/state .proj-metrics:
   ONE soft panel with label+value rows — not a box per fact. */
.municipal-project-facts {
  display:flex; flex-direction:column;
  gap:6px; margin:0 0 10px; padding:12px 14px;
  background:var(--surf2); border-radius:10px;
}
.municipal-project-facts div {
  min-width:0; padding:0; border:0; background:none;
  font-size:11px; color:var(--mut2); line-height:1.6;
}
.municipal-project-facts span {
  display:inline-block; width:auto; min-width:52px; margin:0 10px 0 0;
  font-size:9px; vertical-align:middle;
}
.municipal-project-facts strong {
  display:inline; color:var(--txt); font-size:11.5px; line-height:1.5;
  font-weight:700; overflow-wrap:anywhere;
}
.municipal-project-note {
  margin:0 0 8px; padding:10px 11px; border-radius:10px;
  background:var(--surf2); border:1px solid var(--bdr);
  color:var(--mut2); font-size:12px; line-height:1.45;
}
/* Compact inline agency/vendor row — no boxed panel; sits in the card's
   footer line so it doesn't inflate card height. */
.vendor-row {
  display:flex; align-items:center; flex-wrap:wrap; gap:6px 10px;
  margin:0; padding:0; border:0; background:none;
  min-width:0;
}
.vendor-row-compact { margin:8px 0 0; }
.vendor-row-label {
  font-size:9px; letter-spacing:.12em; text-transform:uppercase;
  color:var(--mut); font-weight:800; white-space:nowrap;
}
.vendor-list { display:flex; flex-wrap:wrap; gap:7px; min-width:0; }
.proj-footer {
  display:flex; align-items:center; justify-content:space-between;
  gap:8px 14px; flex-wrap:wrap; margin-top:12px;
}
.proj-footer .proj-src { margin-top:0; flex-shrink:0; }
.proj-footer-right { display:inline-flex; align-items:center; gap:8px; flex-wrap:wrap; margin-left:auto; }
.proj-verified {
  display:inline-flex; align-items:center; gap:4px; font-size:10px; font-weight:700;
  font-family:'Spline Sans Mono',monospace; letter-spacing:.01em; text-decoration:none;
  color:var(--acc2); background:rgb(var(--acc2-rgb) / .10); border:1px solid rgb(var(--acc2-rgb) / .26);
  border-radius:100px; padding:3px 9px; cursor:help; transition:background .16s,border-color .16s;
}
a.proj-verified:hover { background:rgb(var(--acc2-rgb) / .18); border-color:var(--acc2); }
.proj-verified svg { flex:none; }
.proj-verified-no { color:var(--mut2); background:var(--surf2); border-color:var(--bdr); }
.municipal-project-foot { display:flex; align-items:center; gap:8px; flex-wrap:wrap; margin-top:10px; }
.municipal-project-foot .municipal-source { margin-top:0; }
.promise-foot { display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.vendor-chip {
  display:inline-flex; align-items:center; gap:7px;
  max-width:100%; padding:5px 8px;
  border:1px solid var(--bdr); border-radius:999px;
  background:var(--surf); color:var(--txt); text-decoration:none;
  box-shadow:var(--shadow-xs);
}
.vendor-chip:hover { border-color:var(--acc); color:var(--acc); }
.vendor-logo {
  width:18px; height:18px; border-radius:4px;
  object-fit:contain; flex:0 0 auto; background:#fff;
}
.vendor-logo-fallback {
  display:inline-flex; align-items:center; justify-content:center;
  background:var(--acc-dim); color:var(--acc);
  font-size:10px; font-weight:800; font-family:'Spline Sans Mono',monospace;
}
.vendor-text {
  min-width:0; display:flex; flex-direction:column;
  line-height:1.15;
}
.vendor-name {
  font-size:11px; font-weight:800;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
}
.vendor-role {
  font-size:9px; color:var(--mut2); font-weight:700;
  white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
}
.municipal-note {
  font-size:11px; line-height:1.65; color:var(--mut);
  margin:0;
}

/* ══════════════════════════════════════════════════════
   BACK BUTTON
   ══════════════════════════════════════════════════════ */
.back {
  display:inline-flex; align-items:center; gap:8px;
  padding:14px 28px; font-size:13px; font-weight:500;
  color:var(--mut2); cursor:pointer; background:none; border:none;
  border-radius:8px;
  transition:color .16s, background .16s, transform .16s, box-shadow .16s;
}
.back:hover { color:var(--txt); background:var(--surf2); }
.back svg { width:14px; height:14px; fill:none; stroke:currentColor; stroke-width:2; }
.view > .back {
  display:flex;
  position:relative; z-index:321;
  margin:0 max(18px,calc((100vw - 960px) / 2)) 24px;
  width:fit-content; max-width:calc(100% - 56px);
}
.view:not(#v-home) {
  padding-top:14px;
}
.view:not(#v-home) > .back + :is(.state-hdr,.det-wrap) {
  margin-top:10px;
}
/* Fixed left-rail back button, left-aligned with the header capsule's
   left edge (capsule: width calc(100% - 32px), max-width 1280px, centered).
   Labels must stay short enough for the ~160px gutter between the capsule
   edge and the 960px content column — keep them single-line. */
@media(min-width:1456px) {
  .view > .back {
    position:fixed;
    top:92px;
    left:max(16px, calc((100vw - 1280px) / 2));
    margin:0;
    max-width:170px;
    padding:10px 12px;
    white-space:nowrap;
  }
  .view:not(#v-home) > .back + :is(.state-hdr,.det-wrap) {
    margin-top:0;
  }
}

/* ══════════════════════════════════════════════════════
   STATE VIEW HEADER
   ══════════════════════════════════════════════════════ */
.state-hdr { max-width:960px; margin:0 auto; padding:8px 28px 22px; border-bottom:1px solid var(--bdr); }
.state-hdr-top { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; }
.state-nm  { font-family:'Fraunces',serif; font-optical-sizing:auto; font-size:clamp(28px,5vw,48px); font-weight:500; letter-spacing:-0.01em; margin-bottom:6px; color:var(--txt); }
.state-rg  { font-size:12px; color:var(--mut); margin-bottom:14px; }
.state-share-btn { display:inline-flex; align-items:center; gap:6px; margin-top:10px; padding:7px 14px; border:1px solid var(--bdr); border-radius:20px; background:var(--surf); color:var(--mut2); font-size:12px; cursor:pointer; transition:background .15s,color .15s,border-color .15s; white-space:nowrap; flex-shrink:0; }
.state-share-btn:hover { background:var(--surf2); color:var(--acc); border-color:var(--acc); }
.state-share-btn.share-copied { background:var(--acc); color:var(--on-acc); border-color:var(--acc); }
.pbar  { height:5px; border-radius:3px; overflow:hidden; display:flex; background:var(--surf2); margin-bottom:6px; }
.pseg  { height:100%; transition:width .6s cubic-bezier(.4,0,.2,1); }
.pleg  { display:flex; gap:14px; flex-wrap:wrap; }
.pleg-i{ display:flex; align-items:center; gap:5px; font-size:11px; color:var(--mut2); }
.pleg-d{ width:8px; height:8px; border-radius:50%; }

/* TABS */
.tabs {
  display:flex; gap:6px; border-bottom:1px solid var(--bdr);
  max-width:960px; margin:0 auto; padding:8px 28px 0;
  overflow-x:auto; overflow-y:hidden; scrollbar-width:none;
}
.tabs::-webkit-scrollbar { display:none; }
@media(max-width:600px) { .tabs { mask-image:linear-gradient(90deg,transparent,#000 8%,#000 88%,transparent); -webkit-mask-image:linear-gradient(90deg,transparent,#000 8%,#000 88%,transparent); } }
.tab[hidden] { display:none; }
.tab {
  min-height:40px; padding:9px 15px; font-size:13px; font-weight:700;
  color:var(--mut2); background:none; border:1px solid transparent;
  border-bottom:none; cursor:pointer; white-space:nowrap;
  font-family:'Plus Jakarta Sans',sans-serif; transition:color .16s,border-color .16s,background .16s,box-shadow .16s;
  margin-bottom:0; border-radius:12px 12px 0 0;
}
.tab.active,
.tab[aria-selected="true"] {
  color:var(--acc); border-color:rgb(var(--acc-rgb) / .24);
  background:var(--acc-dim);
  box-shadow:inset 0 -2px 0 var(--acc);
}
.tab:hover  { color:var(--txt); background:var(--surf2); }
.tab.active:hover,
.tab[aria-selected="true"]:hover { color:var(--acc); background:rgb(var(--acc-rgb) / .16); }

.content { max-width:960px; margin:0 auto; padding:28px 28px 80px; }

/* Section label */
.sec { font-size:10px; letter-spacing:.18em; text-transform:uppercase; color:var(--mut); font-weight:700; margin-bottom:20px; display:flex; align-items:center; gap:12px; }
.sec::after { content:''; flex:1; height:1px; background:var(--bdr); }

/* Data quality badges */
.quality-badges { display:flex; flex-wrap:wrap; gap:7px; align-items:center; margin:0 0 18px; }
.quality-badge {
  display:inline-flex; align-items:center; gap:5px; min-height:24px; padding:4px 10px;
  border-radius:100px; font-family:'Spline Sans Mono',monospace; font-size:10px;
  font-weight:700; line-height:1.2; letter-spacing:.01em; white-space:nowrap;
}
.quality-badge { cursor:help; }
.quality-badge.quality-muted { cursor:default; }
.quality-badge-ico { flex:none; }
.quality-ok { color:var(--acc2); background:rgb(var(--acc2-rgb) / .10); border:1px solid rgb(var(--acc2-rgb) / .26); }
.quality-source { color:var(--acc); background:var(--acc-dim); border:1px solid rgb(var(--acc-rgb) / .28); }
.quality-muted { color:var(--mut2); background:var(--surf2); border:1px solid var(--bdr); }
/* Canonical placement for quality badges: a footer row at the BOTTOM of
   the card/section they describe, separated by a hairline — never floated
   in headers. Use this wrapper everywhere badges are rendered. */
.quality-footer { margin-top:14px; padding-top:12px; border-top:1px solid var(--bdr); }
.quality-footer .quality-badges { margin:0; }
.leader-quality-footer { margin:-6px 0 24px; display:flex; align-items:center; gap:8px 14px; flex-wrap:wrap; }

/* State dashboard */
.state-dashboard {
  background:var(--surf); border:1px solid var(--bdr2); border-radius:22px;
  padding:18px; margin-bottom:24px; box-shadow:var(--shadow-sm);
}
.state-dashboard-head {
  display:flex; justify-content:space-between; gap:18px; align-items:flex-start;
  margin-bottom:14px; padding-bottom:14px; border-bottom:1px solid var(--bdr);
}
.dash-kicker {
  font-family:'Spline Sans Mono',monospace; font-size:10px; font-weight:700;
  letter-spacing:.18em; text-transform:uppercase; color:var(--acc); margin-bottom:5px;
}
.state-dashboard h3 { font-size:24px; line-height:1.1; margin:0 0 5px; color:var(--txt); }
.state-dashboard p { font-size:13px; color:var(--mut2); margin:0; line-height:1.5; }
.state-dash-brief { display:grid; grid-template-columns:1.2fr .9fr 1.1fr; gap:10px; margin-bottom:10px; }
.state-dash-card,
.state-dash-metric,
.state-dash-project {
  background:var(--surf2); border:1px solid var(--bdr); border-radius:12px; padding:11px 12px;
}
.state-dash-card { min-height:78px; display:flex; flex-direction:column; gap:6px; }
.dash-status-pills { display:flex; flex-wrap:wrap; gap:5px; }
.dash-pill {
  display:inline-flex; align-items:center; padding:3px 9px;
  border-radius:100px; font-family:'Spline Sans Mono',monospace;
  font-size:10px; font-weight:700; white-space:nowrap;
}
.dash-pill-ongoing   { color:var(--acc);  background:var(--acc-dim); border:1px solid rgb(var(--acc-rgb) / .25); }
.dash-pill-completed { color:var(--acc2); background:rgb(var(--acc2-rgb) / .10); border:1px solid rgb(var(--acc2-rgb) / .25); }
.dash-pill-proposed  { color:var(--mut2); background:var(--surf2); border:1px solid var(--bdr); }
.state-dash-card-link { cursor:pointer; transition:border-color .16s, box-shadow .16s; }
.state-dash-card-link:hover { border-color:rgb(var(--acc-rgb) / .35); box-shadow:var(--shadow-xs); }
.state-dash-card-link:hover .dash-card-jump { color:var(--acc); }
.dash-card-jump { color:var(--acc) !important; font-weight:600; opacity:.85; }
.state-dash-card-main { min-width:0; display:flex; flex-direction:column; gap:5px; }
.state-dash-card span,
.state-dash-metric span,
.state-dash-projects-head span {
  font-family:'Spline Sans Mono',monospace; font-size:10px; font-weight:700;
  letter-spacing:.14em; text-transform:uppercase; color:var(--mut);
}
.state-dash-card strong {
  min-width:0; font-size:17px; color:var(--txt); line-height:1.25;
  overflow-wrap:break-word; word-break:break-word;
}
.state-dash-card small,
.state-dash-metric small,
.state-dash-project small,
.state-dash-project em {
  color:var(--mut2); font-size:11.5px; line-height:1.5; font-style:normal;
}
.state-dash-metrics {
  display:grid; grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px; margin-bottom:12px;
}
.state-dash-metric {
  min-height:0; display:flex; align-items:center; justify-content:space-between;
  gap:10px;
}
.state-dash-metric div { min-width:0; display:flex; align-items:baseline; gap:5px; }
.state-dash-metric strong { color:var(--txt); font-size:15px; line-height:1.2; white-space:nowrap; }
.state-dash-metric small { white-space:nowrap; }
.state-dash-projects {
  margin-top:4px; display:grid; gap:7px;
}
.state-dash-projects-head {
  display:flex; align-items:center; justify-content:space-between;
  gap:10px; margin:0 0 2px;
}
.state-dash-projects-head small {
  color:var(--mut); font-size:11px; font-family:'Spline Sans Mono',monospace; font-weight:700;
}
.state-dash-project {
  display:grid; grid-template-columns:minmax(0,1fr) minmax(140px,auto); gap:8px 14px; align-items:center;
}
.state-dash-project strong { min-width:0; color:var(--txt); font-size:14px; line-height:1.3; }
.state-dash-project small {
  display:flex; flex-direction:column; align-items:flex-end; gap:2px;
  text-align:right;
}
.state-dash-project small b {
  color:var(--acc); font-size:11px; text-transform:uppercase; letter-spacing:.05em;
}
.state-dash-project small span { max-width:260px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.state-dash-project em { display:block; margin-top:2px; }
.dash-muted { color:var(--mut); font-size:12px; }

/* Leader detail jump navigation */
.leader-jump-nav {
  display:flex; flex-wrap:wrap; gap:8px; margin:18px 0 12px;
  padding:8px; background:var(--surf); border:1px solid var(--bdr);
  border-radius:14px; box-shadow:var(--shadow-xs);
}
.leader-jump-nav a {
  display:inline-flex; align-items:center; min-height:32px; padding:7px 12px;
  border-radius:100px; color:var(--mut2); text-decoration:none; font-size:12px;
  font-weight:700; transition:color .16s,background .16s,box-shadow .16s;
}
.leader-jump-nav a:hover { color:var(--acc); background:var(--acc-dim); box-shadow:inset 0 0 0 1px rgb(var(--acc-rgb) / .18); }
#d-ex,
#leader-election,
#leader-projects,
#leader-mplads,
#leader-news,
#leader-parliament { scroll-margin-top:134px; }

/* My State snapshot */
/* ══════════════════════════════════════════════════════
   LEADER CARDS
   ══════════════════════════════════════════════════════ */
.grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(152px,1fr)); gap:12px; }

.lcard {
  background:var(--surf); border:1px solid var(--bdr);
  border-radius:var(--r-lg); padding:18px 14px;
  text-align:center; cursor:pointer;
  transition:border-color .25s var(--ease), box-shadow .25s var(--ease), transform .25s var(--ease);
  box-shadow:var(--shadow-xs);
}
.lcard:hover { border-color:rgb(var(--acc-rgb) / .32); box-shadow:var(--shadow); transform:translateY(-3px); }

.lcard-img { width:68px; height:68px; border-radius:50%; overflow:hidden; margin:0 auto 12px; border:2px solid var(--bdr2); background:var(--surf2); }
.lcard-img img { width:100%; height:100%; object-fit:cover; display:block; }
.lcard-img-ph { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:22px; font-family:'Tiro Devanagari Hindi',serif; color:var(--mut); }
.lcard-nm    { font-size:12px; font-weight:700; margin-bottom:2px; line-height:1.35; color:var(--txt); }
.lcard-nm-hi { font-family:'Tiro Devanagari Hindi',serif; font-size:11px; color:var(--mut); margin-bottom:4px; }
.lcard-co    { font-size:10px; color:var(--mut); margin-bottom:8px; line-height:1.3; }

/* CM Card */
.cm-card {
  background:var(--surf); border:1px solid var(--bdr);
  border-radius:var(--r-xl); padding:22px;
  margin-bottom:32px; display:flex; gap:20px; align-items:center;
  cursor:pointer; transition:border-color .25s var(--ease), box-shadow .25s var(--ease), transform .25s var(--ease);
  box-shadow:var(--shadow-sm);
}
.cm-card:hover { border-color:rgb(var(--acc-rgb) / .36); box-shadow:var(--shadow-lg); transform:translateY(-3px); }
.cm-img { width:80px; height:80px; border-radius:50%; overflow:hidden; border:2px solid var(--bdr2); background:var(--surf2); flex-shrink:0; }
.cm-img img { width:100%; height:100%; object-fit:cover; display:block; }
.cm-img-ph  { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:28px; font-family:'Tiro Devanagari Hindi',serif; color:var(--mut); }
.cm-badge   { font-size:10px; letter-spacing:.14em; text-transform:uppercase; color:var(--acc); margin-bottom:4px; font-weight:700; }
.cm-name    { font-family:'Fraunces',serif; font-optical-sizing:auto; font-size:24px; font-weight:500; letter-spacing:-0.01em; margin-bottom:4px; color:var(--txt); }
.cm-name-hi { font-family:'Tiro Devanagari Hindi',serif; font-size:14px; color:var(--mut); margin-bottom:6px; }

/* Party Tag */
.ptag { display:inline-flex; align-items:center; gap:4px; font-size:10px; font-family:'Spline Sans Mono',monospace; padding:3px 9px; border-radius:100px; letter-spacing:.02em; font-weight:600; }
.ptag-logo-slot,
.ptag-logo-img {
  width:14px; height:14px; flex-shrink:0; display:inline-block;
  border-radius:3px; object-fit:contain; background:rgba(255,255,255,0.72);
}
.ptag-logo-slot {
  border:1px solid currentColor; opacity:.38;
}
.det-tag .ptag-logo-slot,
.det-tag .ptag-logo-img { width:16px; height:16px; }

/* Tenure Tag */
.tenure-tag { font-family:'Spline Sans Mono',monospace; font-size:10px; color:var(--mut2); background:var(--surf2); border:1px solid var(--bdr); border-radius:6px; padding:2px 8px; white-space:nowrap; font-weight:500; }

/* View-all button */
.vm { text-align:center; margin-top:24px; }
.vm-btn { padding:10px 28px; background:var(--acc-dim); border:1.5px solid var(--acc); border-radius:100px; font-size:13px; font-weight:600; color:var(--acc); cursor:pointer; font-family:'Plus Jakarta Sans',sans-serif; transition:all .2s; }
.vm-btn:hover { background:var(--acc); color:var(--on-acc); }
.vm-btn:active { background:var(--acc); color:var(--on-acc); }

/* ══════════════════════════════════════════════════════
   PARTY FILTER
   ══════════════════════════════════════════════════════ */
.party-filter-row { display:flex; gap:8px; flex-wrap:wrap; margin-bottom:24px; align-items:center; }
.party-filter-label { font-size:10px; letter-spacing:.14em; text-transform:uppercase; color:var(--mut); margin-right:4px; font-weight:700; }
.party-pill { min-height:36px; padding:7px 14px; border:1px solid var(--bdr2); border-radius:100px; font-size:11px; font-family:'Spline Sans Mono',monospace; color:var(--mut2); background:none; cursor:pointer; transition:all .16s; display:inline-flex; align-items:center; gap:5px; font-weight:500; }
.party-pill:hover  { border-color:var(--acc); color:var(--acc); }
.party-pill.active,
.party-pill[aria-pressed="true"] { background:var(--acc-dim); border-color:var(--acc); color:var(--acc); box-shadow:inset 0 0 0 1px rgb(var(--acc-rgb) / .22); }
.party-pill.active:hover,
.party-pill[aria-pressed="true"]:hover { background:rgb(var(--acc-rgb) / .16); }
.filter-count { font-size:11px; color:var(--mut); margin-left:auto; font-family:'Spline Sans Mono',monospace; }
.mp-const-search-row { display:flex; align-items:center; gap:10px; margin-bottom:20px; }
.mp-const-search { flex:1; max-width:340px; padding:9px 14px; border:1px solid var(--bdr2); border-radius:20px; font-size:13px; background:var(--surf); color:var(--txt); font-family:'Plus Jakarta Sans',sans-serif; outline:none; transition:border-color .15s; }
.mp-const-search:focus { border-color:var(--acc); }
.mp-const-search::placeholder { color:var(--mut); }

/* ══════════════════════════════════════════════════════
   SEARCH RESULTS (grouped)
   ══════════════════════════════════════════════════════ */
.search-count { font-size:10px; color:var(--mut); letter-spacing:.1em; text-transform:uppercase; padding:8px 6px 4px; font-weight:700; }
.search-empty { font-size:13px; color:var(--mut2); text-align:center; padding:24px; line-height:1.8; }
.search-group-label { font-size:9px; letter-spacing:.16em; text-transform:uppercase; color:var(--mut); font-weight:700; padding:10px 8px 4px; border-top:1px solid var(--bdr); margin-top:4px; }
.search-group-label:first-of-type { border-top:none; margin-top:0; }

.sr-card { display:flex; align-items:center; gap:12px; padding:8px 10px; border-radius:12px; cursor:pointer; transition:background .14s, box-shadow .14s; }
.sr-card:hover { background:var(--surf2); box-shadow:inset 0 0 0 1px var(--bdr); }
.sr-img { width:38px; height:38px; border-radius:50%; overflow:hidden; border:1.5px solid var(--bdr2); background:var(--surf2); flex-shrink:0; }
.sr-img img { width:100%; height:100%; object-fit:cover; display:block; }
.sr-img .lcard-img-ph { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:13px; font-family:'Tiro Devanagari Hindi',serif; color:var(--mut); }
.sr-body { flex:1; min-width:0; }
.sr-name { font-size:13px; font-weight:700; color:var(--txt); line-height:1.3; }
.sr-hi   { font-family:'Tiro Devanagari Hindi',serif; font-size:11px; color:var(--mut); margin-left:4px; }
.sr-sub  { font-size:11px; color:var(--mut2); margin:2px 0 4px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

.search-state-shortcut { display:flex; align-items:center; gap:14px; padding:14px 16px; background:var(--acc-dim); border:1.5px solid var(--acc); border-radius:16px; cursor:pointer; margin-bottom:10px; transition:background .16s, box-shadow .16s; }
.search-state-shortcut:hover { background:rgb(var(--acc-rgb) / .16); box-shadow:var(--shadow-xs); }
.sscut-icon { font-size:24px; }
.sscut-name { font-size:15px; font-weight:700; color:var(--acc); }
.sscut-sub  { font-size:11px; color:var(--mut2); margin-top:1px; }

/* ══════════════════════════════════════════════════════
   LEADER DETAIL
   ══════════════════════════════════════════════════════ */
.det-wrap { max-width:680px; margin:0 auto; padding:0 28px 80px; }
.det-hdr  { display:flex; gap:24px; align-items:flex-start; padding:24px 0 26px; border-bottom:1px solid var(--bdr); margin-bottom:32px; flex-wrap:wrap; }
.det-img  { width:104px; height:104px; border-radius:50%; overflow:hidden; border:2.5px solid var(--bdr2); background:var(--surf2); flex-shrink:0; }
.det-img img { width:100%; height:100%; object-fit:cover; display:block; }
.det-img-ph  { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:38px; font-family:'Tiro Devanagari Hindi',serif; color:var(--mut); }
.det-nm    { font-family:'Fraunces',serif; font-optical-sizing:auto; font-size:clamp(24px,4vw,36px); font-weight:500; letter-spacing:-0.01em; margin-bottom:5px; color:var(--txt); }
.det-nm-hi { font-family:'Tiro Devanagari Hindi',serif; font-size:clamp(14px,2.5vw,18px); color:var(--mut2); margin-bottom:10px; }
.det-role  { font-size:12px; color:var(--mut); margin-bottom:12px; }
.det-tags  { display:flex; flex-wrap:wrap; gap:8px; }
.det-tag   { padding:4px 12px; border-radius:100px; font-size:11px; border:1px solid var(--bdr2); color:var(--mut2); font-weight:500; }
.det-tag.hl{ border-color:var(--acc); color:var(--acc); background:var(--acc-dim); }

.leader-timeline { margin:0 0 14px; padding:10px 0; border-bottom:1px solid var(--bdr); }
.leader-timeline-label { font-size:9px; text-transform:uppercase; letter-spacing:.14em; color:var(--mut); font-weight:700; margin-bottom:8px; }
.leader-timeline-chips { display:flex; gap:6px; flex-wrap:wrap; }
.term-chip { padding:4px 12px; border-radius:100px; font-size:11px; border:1px solid var(--bdr2); color:var(--mut2); font-weight:500; font-family:'Spline Sans Mono',monospace; }
.term-chip-current { font-weight:700; }
.leader-timeline-note { font-size:12px; color:var(--mut2); line-height:1.5; }

.det-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(190px,1fr)); gap:1px; background:var(--bdr); border:1px solid var(--bdr); border-radius:20px; overflow:hidden; margin-bottom:32px; }
.det-cell { background:var(--surf); padding:18px; }
.det-cl   { font-size:9px; color:var(--mut); text-transform:uppercase; letter-spacing:.14em; margin-bottom:4px; font-weight:700; }
.det-cv   { font-size:14px; color:var(--txt); font-weight:600; }
/* Compact, flat fact cards — same card language as proj/src cards:
   plain surface + hairline border, no accent bars, content-hugging. */
.det-info-grid {
  display:grid; grid-template-columns:repeat(12,minmax(0,1fr));
  gap:7px; margin-bottom:18px; align-items:stretch;
  grid-auto-rows:minmax(54px,auto);
}
.det-info-card {
  grid-column:span 4; background:var(--surf);
  border:1px solid var(--bdr); border-radius:12px;
  padding:9px 13px; box-shadow:var(--shadow-xs);
  min-width:0; position:relative; overflow:hidden;
  align-self:stretch; min-height:54px;
  display:flex; flex-direction:column; justify-content:center; gap:3px;
}
.det-info-wide { grid-column:span 6; }
.det-info-bio {
  grid-column:1 / -1;
  padding:13px 16px;
  justify-content:flex-start;
}
.det-info-label {
  font-family:'Spline Sans Mono',monospace;
  font-size:9px; color:var(--mut); text-transform:uppercase;
  letter-spacing:.13em; margin-bottom:0; font-weight:700;
}
.det-info-value {
  font-size:13px; line-height:1.4; color:var(--txt);
  font-weight:650; overflow-wrap:anywhere;
}
.det-info-party .det-info-value { display:flex; align-items:center; }
.det-info-wide .det-info-value { font-size:12.5px; font-weight:600; line-height:1.45; color:var(--mut2); }
.det-info-bio .det-info-value {
  max-width:72ch; white-space:pre-line;
  font-size:13px; font-weight:500; line-height:1.6;
  color:var(--mut2); overflow-wrap:normal;
}
.det-bio  { font-size:14px; line-height:1.8; color:var(--mut2); background:var(--surf); border:1px solid var(--bdr); border-radius:var(--r-lg); padding:20px; margin-bottom:24px; }

.wiki-btn { display:inline-flex; align-items:center; gap:8px; padding:10px 20px; border:1.5px solid var(--acc); border-radius:100px; font-size:13px; font-weight:600; color:var(--acc); text-decoration:none; transition:all .18s; background:var(--acc-dim); }
.wiki-btn:hover { background:var(--acc); color:var(--on-acc); }
.wiki-btn:active { background:var(--acc); color:var(--on-acc); }

.no-dt { text-align:center; padding:56px 20px; }
.no-dt p { font-size:14px; color:var(--mut2); line-height:1.75; max-width:380px; margin:0 auto; }
.no-dt a { color:var(--acc); text-decoration:none; font-weight:600; }

/* ══════════════════════════════════════════════════════
   PROMISE TRACKER — manifesto commitments + sourced status.
   Status colours: delivered=green(acc2), progress=blue(acc),
   stalled=amber, dropped=red. Used on the state Promises tab
   and the National view. ══════════════════════════════════ */
.promise-tracker { margin-bottom:8px; }
/* Head is a simple stacked block (intro + government); the section already has
   an <h2> heading above it, so no in-panel kicker. */
.promise-tracker-head { margin-bottom:14px; }
.promise-intro { margin:0 0 12px; max-width:640px; font-size:13px; line-height:1.6; color:var(--mut2); }
.promise-govt { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.promise-govt-line { font-size:12px; color:var(--mut); font-weight:600; }
/* Calm summary on its own row: one thin proportional bar carries the colour
   story; the legend uses muted text with a small colour dot (no filled pills). */
.promise-summary {
  display:flex; align-items:center; gap:10px 18px; flex-wrap:wrap;
  margin:0 0 18px; padding:12px 16px; background:var(--surf2); border-radius:var(--r-lg);
}
.promise-bar { display:flex; width:180px; max-width:60vw; height:8px; border-radius:100px; overflow:hidden; gap:2px; }
.promise-bar-seg { display:block; min-width:4px; }
.promise-bar-delivered { background:var(--acc2); }
.promise-bar-progress  { background:var(--acc); }
.promise-bar-stalled   { background:#D97706; }
.promise-bar-dropped   { background:#DC2626; }
.promise-tallies { display:flex; gap:6px 16px; flex-wrap:wrap; align-items:center; justify-content:flex-start; }
.promise-tally {
  display:inline-flex; align-items:center; gap:6px; white-space:nowrap;
  font-family:'Spline Sans Mono',monospace; font-size:10.5px; font-weight:700; color:var(--mut2);
}
.promise-tally::before { content:""; width:7px; height:7px; border-radius:50%; background:var(--bdr); flex:none; }
.promise-tally-delivered::before { background:var(--acc2); }
.promise-tally-progress::before  { background:var(--acc); }
.promise-tally-stalled::before   { background:#D97706; }
.promise-tally-dropped::before   { background:#DC2626; }

.promise-list { display:grid; grid-template-columns:repeat(auto-fill,minmax(280px,1fr)); gap:14px; }
.promise-card {
  position:relative; display:flex; flex-direction:column; background:var(--surf); border:1px solid var(--bdr);
  border-radius:var(--r-lg); padding:18px 18px 16px; box-shadow:var(--shadow-sm);
  transition:border-color .16s, box-shadow .16s, transform .16s var(--ease);
}
.promise-card:hover { box-shadow:var(--shadow-md); transform:translateY(-1px); border-color:var(--bdr2); }
.promise-card-head { display:flex; align-items:center; gap:8px 12px; flex-wrap:wrap; margin-bottom:11px; }
/* One calm status chip per card: neutral pill, the colour lives in the dot
   and the label text only. */
.promise-status {
  display:inline-flex; align-items:center; gap:6px;
  font-family:'Spline Sans Mono',monospace; font-size:10px; font-weight:700;
  letter-spacing:.06em; text-transform:uppercase; padding:4px 10px; border-radius:100px;
  background:var(--surf2); border:1px solid var(--bdr); color:var(--mut2);
}
.promise-status::before { content:""; width:6px; height:6px; border-radius:50%; background:var(--mut); flex:none; }
.promise-status-delivered { color:var(--acc2); }
.promise-status-delivered::before { background:var(--acc2); }
.promise-status-progress  { color:var(--acc); }
.promise-status-progress::before  { background:var(--acc); }
.promise-status-stalled   { color:#B45309; }
.promise-status-stalled::before   { background:#D97706; }
.promise-status-dropped   { color:#B91C1C; }
.promise-status-dropped::before   { background:#DC2626; }
[data-theme="dark"] .promise-status-stalled { color:#FBBF77; }
[data-theme="dark"] .promise-status-dropped { color:#FCA5A5; }
.promise-since { font-family:'Spline Sans Mono',monospace; font-size:10px; font-weight:600; color:var(--mut); }
.promise-text { margin:0 0 7px; font-size:14.5px; font-weight:700; line-height:1.35; color:var(--txt); }
.promise-detail { margin:0 0 12px; font-size:12.5px; line-height:1.6; color:var(--mut2); }
.promise-foot { display:flex; align-items:center; gap:8px; flex-wrap:wrap; justify-content:flex-start; margin-top:auto; padding-top:12px; }
/* Keep the footer quiet: neutral source link + neutral verified chip so the
   only colour on a promise card is the single status chip. */
.promise-src {
  font-family:'Spline Sans Mono',monospace; font-size:10.5px; font-weight:600; color:var(--mut2);
  text-decoration:none; border:1px solid var(--bdr); border-radius:6px; padding:2px 9px;
  transition:background .16s, border-color .16s, color .16s;
}
.promise-src:hover { background:var(--surf2); border-color:var(--acc); color:var(--acc); }
.promise-foot .proj-verified { color:var(--mut2); background:transparent; border-color:var(--bdr); }
.promise-foot a.proj-verified:hover { background:var(--surf2); border-color:var(--bdr2); }
.promise-src-none { color:var(--mut); border-color:var(--bdr); cursor:default; }

/* Election result */
.elec-result { background:var(--surf); border:1px solid var(--bdr2); border-radius:var(--r-lg); padding:20px; margin-bottom:28px; box-shadow:var(--shadow-sm); }
.elec-label  { font-size:10px; letter-spacing:.14em; text-transform:uppercase; color:var(--mut); margin-bottom:14px; display:flex; align-items:center; gap:8px; font-weight:700; }
.elec-src    { font-family:'Spline Sans Mono',monospace; font-size:10px; color:var(--acc); text-decoration:none; border:1px solid var(--acc-dim); border-radius:5px; padding:1px 7px; font-weight:600; transition:background .16s,border-color .16s,color .16s; }
.elec-src:hover { background:var(--acc-dim); border-color:var(--acc); }
.elec-row    { display:flex; margin-bottom:14px; }
.elec-stat   { flex:1; text-align:center; padding:10px 6px; border-right:1px solid var(--bdr); }
.elec-stat:last-child { border-right:none; }
.elec-n      { font-family:'Spline Sans Mono',monospace; font-size:22px; font-weight:700; color:var(--acc); line-height:1; margin-bottom:4px; }
.elec-l      { font-size:9px; text-transform:uppercase; letter-spacing:.1em; color:var(--mut); font-weight:600; }
.elec-bar-wrap { height:4px; background:var(--surf2); border-radius:2px; overflow:hidden; margin-top:10px; }
.elec-bar    { height:100%; background:linear-gradient(90deg,rgb(var(--acc-rgb) / .55),var(--acc)); border-radius:2px; transition:width .8s ease; }
.elec-note   { font-size:11px; color:var(--acc); margin-top:8px; font-weight:500; }
.result-badge{ display:flex; gap:6px; align-items:center; margin:3px 0 6px; flex-wrap:wrap; }
.rb-share    { font-family:'Spline Sans Mono',monospace; font-size:11px; font-weight:700; color:var(--acc2); background:rgb(var(--acc2-rgb) / .12); border:1px solid rgb(var(--acc2-rgb) / .28); border-radius:100px; padding:1px 8px; }
.rb-margin   { font-family:'Spline Sans Mono',monospace; font-size:10px; color:var(--mut2); background:var(--surf2); border:1px solid var(--bdr); border-radius:100px; padding:1px 8px; }

/* MPLADS */
.mplads-block { margin-bottom:8px; }
.mplads-card  { background:var(--surf); border:1px solid var(--bdr2); border-left:3px solid var(--acc); border-radius:var(--r-lg); padding:18px; box-shadow:var(--shadow-sm); }
.mplads-amount{ font-family:'Spline Sans Mono',monospace; font-size:24px; font-weight:700; color:var(--acc); margin-bottom:8px; }
.mplads-desc  { font-size:13px; color:var(--mut2); line-height:1.7; }

/* Projects */
.proj-list { display:flex; flex-direction:column; gap:12px; margin-bottom:36px; }
.proj-card  { background:var(--surf); border:1px solid var(--bdr); border-radius:var(--r-lg); padding:18px; box-shadow:var(--shadow-sm); transition:border-color .16s; }
.proj-card:hover { border-color:var(--bdr2); }
.proj-header{ display:flex; justify-content:space-between; align-items:flex-start; gap:12px; margin-bottom:12px; }
.proj-name  { font-size:14px; font-weight:700; color:var(--txt); line-height:1.4; }
.proj-name-hi{ font-family:'Tiro Devanagari Hindi',serif; font-size:11px; color:var(--mut); margin-top:2px; }
.proj-chips { display:inline-flex; align-items:center; gap:6px; flex-shrink:0; flex-wrap:wrap; justify-content:flex-end; }
.proj-status { font-size:9px; letter-spacing:.12em; text-transform:uppercase; padding:3px 10px; border-radius:100px; font-family:'Spline Sans Mono',monospace; white-space:nowrap; flex-shrink:0; font-weight:700; }
.proj-status.ongoing   { background:rgb(var(--acc-rgb) / .10); color:var(--acc); border:1.5px solid rgb(var(--acc-rgb) / .25); }
.proj-status.completed { background:rgb(var(--acc2-rgb) / .10); color:var(--acc2); border:1.5px solid rgb(var(--acc2-rgb) / .25); }
.proj-status.proposed  { background:var(--surf2); color:var(--mut); border:1px solid var(--bdr); }
.proj-status.stopped   { background:rgba(180,83,9,0.08); color:#B45309; border:1.5px solid rgba(180,83,9,0.25); }
[data-theme="dark"] .proj-status.stopped { background:rgba(251,191,36,0.10); color:#FBBF24; border-color:rgba(251,191,36,0.28); }
.proj-metrics { display:flex; flex-direction:column; gap:6px; margin:12px 0; padding:12px 14px; background:var(--surf2); border-radius:10px; }
.proj-metric  { font-size:11px; color:var(--mut2); line-height:1.6; }
.proj-metric.is-muted { color:var(--mut); }
/* min-width keeps BUDGET/REACH columns aligned; width:auto lets longer
   labels (COMPLETED, TARGET) take their space instead of overlapping the
   value text that follows them. */
.pm-label     { display:inline-block; font-family:'Spline Sans Mono',monospace; font-size:9px; letter-spacing:.1em; text-transform:uppercase; color:var(--mut); width:auto; min-width:52px; margin-right:10px; vertical-align:middle; font-weight:700; }
.proj-meta    { font-size:12px; color:var(--mut2); line-height:1.7; }
.proj-year    { font-family:'Spline Sans Mono',monospace; font-size:10px; color:var(--mut); display:inline-block; margin-right:6px; font-weight:600; }
/* Inherited / carried-forward projects: a neutral "Inherited" badge in the
   header + a clear "Carried forward from <former CM>" provenance line. */
.proj-inherited {
  display:inline-flex; align-items:center; gap:4px; flex-shrink:0; white-space:nowrap;
  font-family:'Spline Sans Mono',monospace; font-size:9px; font-weight:700;
  letter-spacing:.1em; text-transform:uppercase; padding:3px 9px; border-radius:100px;
  color:var(--mut2); background:var(--surf2); border:1px dashed var(--bdr2);
}
.proj-inherited svg { flex:none; }
.proj-inherited-line {
  display:flex; align-items:center; gap:7px; margin-top:11px; padding-top:11px;
  border-top:1px dashed var(--bdr); font-size:12px; color:var(--mut2); line-height:1.5;
}
.proj-inherited-line svg { flex:none; color:var(--acc); }
.proj-inherited-line strong { color:var(--txt); font-weight:700; }
.proj-summary { font-size:10px; font-family:'Spline Sans Mono',monospace; color:var(--mut); background:var(--surf2); border:1px solid var(--bdr); border-radius:6px; padding:2px 8px; margin-left:8px; font-weight:600; }
.proj-src     { display:inline-flex; align-items:center; gap:4px; margin-top:10px; font-size:11px; font-family:'Spline Sans Mono',monospace; color:var(--acc); text-decoration:none; border:1px solid var(--bdr); border-radius:100px; padding:3px 10px; transition:border-color .16s,background .16s,color .16s; font-weight:600; }
.proj-src:hover { border-color:var(--acc); background:var(--acc-dim); }

/* Parliament */
.parl-stats-links { display:flex; gap:12px; flex-wrap:wrap; margin-bottom:8px; }

/* Share bar */
.share-bar { display:flex; gap:10px; flex-wrap:wrap; margin-top:28px; padding-top:20px; border-top:1px solid var(--bdr); }
.btn-primary,
.btn-secondary { padding:10px 20px; border-radius:100px; font-size:13px; font-weight:600; cursor:pointer; font-family:'Plus Jakarta Sans',sans-serif; transition:all .18s; display:inline-flex; align-items:center; justify-content:center; gap:8px; }
.btn-primary { background:var(--acc); border:1.5px solid var(--acc); color:var(--on-acc); box-shadow:var(--shadow-xs); }
.btn-primary:hover { background:var(--txt); border-color:var(--txt); color:var(--bg); box-shadow:var(--shadow-sm); }
.btn-primary:active { background:var(--txt); border-color:var(--txt); color:var(--bg); }
.btn-secondary { padding:10px 20px; background:var(--surf); border:1.5px solid var(--bdr2); color:var(--mut2); }
.btn-secondary:hover { border-color:var(--acc); color:var(--acc); background:var(--acc-dim); }
.btn-secondary:active { border-color:var(--acc); color:var(--acc); background:rgb(var(--acc-rgb) / .18); }

/* ══════════════════════════════════════════════════════
   NATIONAL LEADERS
   ══════════════════════════════════════════════════════ */
.pm-card {
  background:var(--surf); border:1px solid var(--bdr);
  border-radius:var(--r-xl); padding:24px;
  margin-bottom:16px; display:flex; gap:22px; align-items:center;
  cursor:pointer; transition:all .2s; box-shadow:var(--shadow-sm);
}
.pm-card:hover { border-color:rgb(var(--acc-rgb) / .32); box-shadow:var(--shadow-lg); transform:translateY(-3px); }
.pm-img { width:96px; height:96px; border-radius:50%; overflow:hidden; border:2.5px solid var(--bdr2); background:var(--surf2); flex-shrink:0; }
.pm-img img { width:100%; height:100%; object-fit:cover; display:block; }
.pm-img-ph  { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:32px; font-family:'Tiro Devanagari Hindi',serif; color:var(--mut); }
.pm-badge   { font-size:10px; letter-spacing:.14em; text-transform:uppercase; color:var(--acc); margin-bottom:5px; font-weight:700; }
.pm-name    { font-family:'Fraunces',serif; font-optical-sizing:auto; font-weight:500; letter-spacing:-0.01em; font-size:clamp(20px,3.5vw,30px); margin-bottom:5px; color:var(--txt); }
.pm-name-hi { font-family:'Tiro Devanagari Hindi',serif; font-size:14px; color:var(--mut); margin-bottom:6px; }
.pm-detail  { font-size:13px; color:var(--mut2); display:flex; align-items:center; gap:8px; flex-wrap:wrap; }

.minister-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(228px,1fr)); gap:12px; }
.minister-card { background:var(--surf); border:1px solid var(--bdr); border-radius:var(--r-lg); padding:16px 14px; cursor:pointer; display:flex; align-items:center; gap:14px; transition:all .18s; box-shadow:var(--shadow-xs); }
.minister-card:hover { border-color:rgb(var(--acc-rgb) / .28); box-shadow:var(--shadow); transform:translateY(-2px); }
.minister-img { width:48px; height:48px; border-radius:50%; overflow:hidden; border:1.5px solid var(--bdr2); background:var(--surf2); flex-shrink:0; }
.minister-img img { width:100%; height:100%; object-fit:cover; display:block; }
.minister-img-ph { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:16px; font-family:'Tiro Devanagari Hindi',serif; color:var(--mut); }
.minister-nm    { font-size:13px; font-weight:700; margin-bottom:2px; line-height:1.3; color:var(--txt); }
.minister-nm-hi { font-family:'Tiro Devanagari Hindi',serif; font-size:10px; color:var(--mut); margin-bottom:3px; }
.minister-role  { font-size:10px; color:var(--mut); line-height:1.4; margin-bottom:5px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-weight:500; }

/* ══════════════════════════════════════════════════════
   NEWS
   ══════════════════════════════════════════════════════ */
.news-live-dot { display:inline-block; width:6px; height:6px; border-radius:50%; background:var(--acc2); margin-left:4px; vertical-align:middle; animation:blink 2s infinite; }
@keyframes blink { 0%,100%{opacity:1}50%{opacity:.2} }
.news-list { display:flex; flex-direction:column; gap:10px; margin-bottom:32px; }
.news-item { display:flex; align-items:stretch; border:1px solid var(--bdr); border-radius:var(--r-lg); text-decoration:none; background:var(--surf); overflow:hidden; transition:border-color .18s,box-shadow .18s; box-shadow:var(--shadow-xs); }
.news-item:hover { border-color:rgb(var(--acc-rgb) / .28); box-shadow:var(--shadow); }
.news-item.news-item-img { flex-direction:row; }
.news-thumb { width:90px; min-height:88px; align-self:stretch; flex-shrink:0; background:var(--surf2); position:relative; display:flex; align-items:center; justify-content:center; border-right:1px solid var(--bdr); overflow:hidden; }
.news-thumb img { width:100%; height:100%; min-height:100%; object-fit:cover; object-position:center; display:block; }
.news-thumb-profile img { filter:saturate(.9); opacity:.95; }
.news-thumb span {
  display:none; font-family:'Spline Sans Mono',monospace; font-size:10px;
  letter-spacing:.12em; color:var(--mut); font-weight:700;
}
.news-thumb-missing span { display:block; }
.news-body  { flex:1; padding:14px 16px; }
.news-headline { font-size:13px; font-weight:700; color:var(--txt); line-height:1.45; margin-bottom:7px; }
.news-meta     { display:flex; align-items:center; justify-content:space-between; gap:8px; flex-wrap:wrap; }
.news-source   { font-size:11px; color:var(--acc); font-family:'Spline Sans Mono',monospace; font-weight:600; }
.news-time     { font-size:11px; color:var(--mut); font-family:'Spline Sans Mono',monospace; }
.news-empty    { font-size:13px; color:var(--mut2); padding:20px 0; text-align:center; line-height:1.8; }
.news-ext-link { color:var(--acc); text-decoration:none; font-weight:700; }

/* ══════════════════════════════════════════════════════
   HINDI / SCRIPT NAMES
   ══════════════════════════════════════════════════════ */
.lcard-nm-hi  { font-family:'Tiro Devanagari Hindi',serif; font-size:12px; color:var(--mut); margin-top:1px; margin-bottom:4px; }
.cm-name-hi   { font-family:'Tiro Devanagari Hindi',serif; font-size:15px; color:var(--mut); margin-bottom:6px; }
.det-nm-hi    { font-family:'Tiro Devanagari Hindi',serif; font-size:clamp(13px,2.2vw,18px); color:var(--mut2); margin-bottom:10px; }
.pl-name-hi   { font-family:'Tiro Devanagari Hindi',serif; font-size:11px; color:var(--mut); margin-left:4px; }

/* ══════════════════════════════════════════════════════
   PAST LEADERS
   ══════════════════════════════════════════════════════ */
.past-leaders-details { margin-top:32px; border:1px solid var(--bdr); border-radius:var(--r-lg); overflow:hidden; box-shadow:var(--shadow-xs); }
.past-leaders-summary { display:flex; align-items:center; justify-content:space-between; padding:16px 20px; cursor:pointer; font-size:13px; font-weight:700; color:var(--mut2); background:var(--surf); list-style:none; user-select:none; transition:background .16s,color .16s,box-shadow .16s; }
.past-leaders-summary::-webkit-details-marker { display:none; }
.past-leaders-summary::before { content:'▶'; font-size:10px; margin-right:8px; color:var(--mut); transition:transform .2s; }
details[open] .past-leaders-summary::before { transform:rotate(90deg); }
.past-leaders-summary:hover { background:var(--surf2); color:var(--txt); }
.past-leaders-summary:active { background:var(--surf3); }
.past-leaders-count { font-family:'Spline Sans Mono',monospace; font-size:10px; color:var(--mut); background:var(--surf2); border:1px solid var(--bdr); border-radius:6px; padding:2px 8px; font-weight:700; }
.past-leaders-list { border-top:1px solid var(--bdr); }
.past-leader-row { display:flex; gap:14px; align-items:flex-start; padding:16px 20px; border-bottom:1px solid var(--bdr); cursor:pointer; transition:background .14s,box-shadow .14s; }
.past-leader-row:last-child { border-bottom:none; }
.past-leader-row:hover { background:var(--surf2); box-shadow:inset 3px 0 0 var(--acc); }
.pl-img  { width:44px; height:44px; border-radius:50%; overflow:hidden; border:1.5px solid var(--bdr2); background:var(--surf2); flex-shrink:0; }
.pl-img img { width:100%; height:100%; object-fit:cover; display:block; }
.pl-img-ph  { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:14px; font-family:'Tiro Devanagari Hindi',serif; color:var(--mut); }
.pl-info   { flex:1; min-width:0; }
.pl-name   { font-size:13px; font-weight:700; margin-bottom:4px; line-height:1.3; color:var(--txt); }
.pl-meta   { display:flex; align-items:center; gap:8px; margin-bottom:6px; flex-wrap:wrap; }
.pl-tenure { font-family:'Spline Sans Mono',monospace; font-size:10px; color:var(--mut); font-weight:600; }
.pl-legacy { font-size:12px; color:var(--mut2); line-height:1.6; }
.project-handover-list { margin-top:10px; display:grid; gap:8px; }
.project-handover {
  padding:10px 12px 10px 14px;
  border:1px solid var(--bdr);
  border-left:3px solid var(--bdr2);
  border-radius:8px;
  background:var(--surf);
  box-shadow:var(--shadow-xs);
}
.project-handover-head { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:6px 12px; margin-bottom:7px; }
.project-handover-status {
  flex-shrink:0;
  border-radius:999px;
  padding:3px 8px;
  font-family:'Spline Sans Mono',monospace;
  font-size:9px;
  font-weight:700;
  text-transform:uppercase;
  color:var(--mut2);
  background:var(--surf2);
  border:1px solid var(--bdr);
}
.project-handover-line {
  margin-top:7px; display:flex; align-items:center; gap:6px;
  font-size:11px; font-weight:600; color:var(--mut2); line-height:1.4;
}
.project-handover-line svg { width:11px; height:11px; flex:0 0 auto; color:var(--mut); }
.project-handover-name { font-size:12px; font-weight:700; color:var(--txt); line-height:1.35; }
.project-handover-note { margin-top:4px; font-size:11px; color:var(--mut2); line-height:1.5; }
.project-handover-continued { border-left-color:var(--acc2); background:rgb(var(--acc2-rgb) / .06); }
.project-handover-continued .project-handover-status { color:var(--acc2); border-color:rgb(var(--acc2-rgb) / .32); background:rgb(var(--acc2-rgb) / .10); }
.project-handover-modified { border-left-color:var(--acc); background:var(--acc-dim); }
.project-handover-modified .project-handover-status { color:var(--acc); border-color:rgb(var(--acc-rgb) / .32); background:rgb(var(--acc-rgb) / .10); }
.project-handover-renamed { border-left-color:#7B68EE; background:rgba(123,104,238,0.05); }
.project-handover-renamed .project-handover-status { color:#6552d0; border-color:rgba(123,104,238,0.28); background:rgba(123,104,238,0.08); }
.project-handover-discontinued { border-left-color:var(--mut); background:var(--surf2); }
.project-handover-discontinued .project-handover-status { color:var(--mut2); background:var(--surf3); }

/* ══════════════════════════════════════════════════════
   COMING SOON
   ══════════════════════════════════════════════════════ */
/* ── MLA TAB ── */
.mla-composition { margin-bottom:28px; }
.mla-ruling-label { display:inline-block; font-size:12px; font-weight:700; color:var(--acc); background:var(--acc-dim); border:1px solid rgb(var(--acc-rgb) / .24); border-radius:100px; padding:4px 14px; margin-bottom:10px; }
.mla-comp-summary { font-size:12px; color:var(--mut); margin-bottom:8px; font-family:'Spline Sans Mono',monospace; font-weight:600; }

.mla-sources-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(240px,1fr)); gap:12px; margin-bottom:40px; }
.mla-source-card {
  display:flex; align-items:flex-start; gap:14px;
  padding:16px; background:var(--surf);
  border:1px solid var(--bdr); border-radius:var(--r-lg);
  text-decoration:none; transition:border-color .18s, box-shadow .18s;
  box-shadow:var(--shadow-xs);
}
.mla-source-card:hover { border-color:rgb(var(--acc-rgb) / .32); box-shadow:var(--shadow); }
.msc-icon  { font-size:22px; flex-shrink:0; margin-top:2px; }
.msc-title { font-size:13px; font-weight:700; color:var(--txt); margin-bottom:3px; }
.msc-url   { font-size:10px; color:var(--acc); font-family:'Spline Sans Mono',monospace; font-weight:600; margin-bottom:5px; }
.msc-desc  { font-size:11px; color:var(--mut2); line-height:1.5; }

.coming-soon-notice { text-align:center; padding:48px 24px; border:1px dashed var(--bdr2); border-radius:var(--r-xl); background:var(--surf); }
.csn-icon  { font-size:36px; margin-bottom:14px; }
.csn-title { font-size:17px; font-weight:700; color:var(--txt); margin-bottom:6px; }
.csn-sub   { font-size:13px; color:var(--mut2); line-height:1.6; max-width:320px; margin:0 auto 18px; }

/* ══════════════════════════════════════════════════════
   MY STATE CHIP (hero)
   One-tap shortcut to the saved state — replaces the old
   below-the-map "My Leaders" panel, which duplicated the map.
   ══════════════════════════════════════════════════════ */
.my-state-row { display:flex; justify-content:center; align-items:center; gap:8px 10px; flex-wrap:wrap; margin-top:14px; min-height:0; }
.my-state-row:empty { display:none; }
.my-state-chip {
  display:inline-flex; align-items:center; gap:7px;
  padding:8px 16px; border-radius:100px; cursor:pointer;
  background:var(--surf); border:1px solid var(--bdr2); color:var(--mut2);
  font-family:'Plus Jakarta Sans',sans-serif; font-size:12.5px; font-weight:600;
  box-shadow:var(--shadow-xs);
  transition:border-color .16s, color .16s, background .16s;
}
.my-state-chip:hover { border-color:var(--acc); color:var(--acc); background:var(--acc-dim); }
.my-state-chip svg { width:13px; height:13px; flex:0 0 auto; color:var(--acc); }
.my-state-chip strong { color:var(--txt); font-weight:700; }
/* Quiet circular edit affordance — replaces the underlined "Change state"
   text link that crowded the row. */
.my-state-chip-edit {
  width:30px; height:30px; min-height:30px; padding:0; border-radius:50%;
  border:1px solid var(--bdr); background:var(--surf); color:var(--mut2);
  display:inline-flex; align-items:center; justify-content:center; cursor:pointer;
  transition:color .16s, border-color .16s, background .16s;
}
.my-state-chip-edit svg { width:12px; height:12px; }
.my-state-chip-edit:hover { color:var(--acc); border-color:var(--acc); background:var(--acc-dim); }
/* "Set my state" picker — compact form group: small prompt above one tidy row
   of [select] [Save] [Cancel], all the same height. No oversized bar, no
   floating circle, no detached underline. */
.my-state-picker { display:inline-flex; flex-direction:column; align-items:center; gap:8px; max-width:100%; }
.msp-label {
  display:inline-flex; align-items:center; gap:6px; font-size:12px; font-weight:600; color:var(--mut2);
}
.msp-label svg { width:13px; height:13px; flex:none; color:var(--acc); }
.msp-row { display:flex; align-items:center; gap:8px; max-width:100%; }
.my-state-picker .my-state-select {
  flex:0 1 190px; width:190px; min-width:0; padding:9px 34px 9px 14px; font-size:13.5px; border-radius:10px;
  background-position:calc(100% - 16px) 50%,calc(100% - 11px) 50%;
}
.my-state-picker .msp-save { flex:none; padding:9px 18px; border-radius:10px; font-size:13px; }
.msp-cancel {
  flex:none; padding:9px 14px; border-radius:10px; cursor:pointer;
  background:transparent; border:1px solid var(--bdr); color:var(--mut2);
  font-family:'Plus Jakarta Sans',sans-serif; font-size:13px; font-weight:600;
  transition:border-color .16s, color .16s, background .16s;
}
.msp-cancel:hover { border-color:var(--acc); color:var(--acc); background:var(--surf2); }

/* ══════════════════════════════════════════════════════
   BROWSE TOGGLE
   ══════════════════════════════════════════════════════ */
/* Same pill language as .map-hint beside it (soft surface, 100px radius,
   hairline border, xs shadow) — segments are fully rounded chips inside,
   so the active state slides between them like a segmented control. */
.browse-toggle {
  display:inline-flex; align-items:center; gap:3px;
  padding:3px; border:1px solid var(--bdr); border-radius:100px;
  background:var(--surf); box-shadow:var(--shadow-xs);
}
.browse-toggle .bt {
  display:inline-flex; align-items:center; justify-content:center;
  padding:7px 16px; background:none; border:none; border-radius:100px;
  font-family:'Plus Jakarta Sans',sans-serif; font-size:12.5px; font-weight:600;
  color:var(--mut2); line-height:1; white-space:nowrap; cursor:pointer;
  transition:background .18s var(--ease), color .18s var(--ease), box-shadow .18s var(--ease);
}
.browse-toggle .bt:hover { background:var(--surf2); color:var(--txt); }
.browse-toggle .bt:active { transform:scale(.96); }
.browse-toggle .bt.active,
.browse-toggle .bt[aria-pressed="true"] {
  background:var(--acc-dim); color:var(--acc); font-weight:700;
  box-shadow:inset 0 0 0 1px rgb(var(--acc-rgb) / .25);
}
.browse-toggle .bt.active:hover,
.browse-toggle .bt[aria-pressed="true"]:hover {
  background:rgb(var(--acc-rgb) / .14); color:var(--acc);
}

/* State list — same centered 1040px column as the economy panel. */
#state-list-grid {
  display:none; grid-template-columns:repeat(auto-fill,minmax(162px,1fr));
  gap:10px; padding:16px 0;
  width:min(1040px, 100%); margin:0 auto;
}
/* List mode collapses the map's reserved sticky scroll space. */
.map-wrap.list-mode { min-height:0; height:auto; }
.state-list-card { background:var(--surf); border:1px solid var(--bdr); border-radius:var(--r-lg); padding:14px 16px; cursor:pointer; transition:border-color .18s,box-shadow .18s,transform .18s; display:flex; flex-direction:column; gap:4px; box-shadow:var(--shadow-xs); }
.state-list-card:hover { border-color:rgb(var(--acc-rgb) / .32); box-shadow:var(--shadow); transform:translateY(-2px); }
.sr-card.sr-active, .search-state-shortcut.sr-active { background:var(--surf2); box-shadow:inset 2.5px 0 0 var(--acc); }
.state-list-icon {
  width:30px; height:30px; border-radius:9px; flex:0 0 auto;
  display:inline-flex; align-items:center; justify-content:center;
  background:var(--acc-dim); color:var(--acc); margin-bottom:4px;
}
.state-list-icon svg { width:15px; height:15px; }
.state-list-name { font-size:13px; font-weight:700; color:var(--txt); }
.state-list-cm   { display:flex; align-items:center; gap:6px; font-size:11px; color:var(--mut2); }
.state-list-dot  { width:8px; height:8px; border-radius:50%; flex:0 0 auto; }

/* ══════════════════════════════════════════════════════
   LOADING
   ══════════════════════════════════════════════════════ */
.lw  { text-align:center; padding:56px 20px; color:var(--mut); }
.spin{ width:28px; height:28px; border:2.5px solid var(--bdr2); border-top-color:var(--acc); border-radius:50%; animation:spin .7s linear infinite; margin:0 auto 14px; }
@keyframes spin { to{transform:rotate(360deg)} }

/* ══════════════════════════════════════════════════════
   MY STATE SELECT
   ══════════════════════════════════════════════════════ */
.my-state-select { padding:11px 42px 11px 16px; background:var(--surf); border:1.5px solid var(--bdr2); border-radius:12px; color:var(--txt); font-size:14px; font-family:'Plus Jakarta Sans',sans-serif; outline:none; cursor:pointer; min-width:200px; transition:border-color .2s,box-shadow .2s,background .2s; appearance:none; font-weight:500; background-image:linear-gradient(45deg,transparent 50%,var(--mut2) 50%),linear-gradient(135deg,var(--mut2) 50%,transparent 50%); background-position:calc(100% - 18px) 50%,calc(100% - 12px) 50%; background-size:6px 6px,6px 6px; background-repeat:no-repeat; }
.my-state-select:hover { border-color:var(--acc); background-color:var(--surf2); }
.my-state-select:focus { border-color:var(--acc); box-shadow:0 0 0 4px var(--acc-dim); }

/* Source register */
.source-register-panel {
  max-width:1040px; margin:48px auto 0; padding:0 28px;
  background:transparent; border:0; border-radius:0; box-shadow:none;
}
.source-register-head {
  display:block; max-width:760px; margin-bottom:18px;
  padding-bottom:16px; border-bottom:1px solid var(--bdr);
}
.source-register-kicker {
  font-family:'Spline Sans Mono',monospace; font-size:10px; font-weight:700;
  letter-spacing:.18em; text-transform:uppercase; color:var(--acc); margin-bottom:6px;
}
.source-register-head h2 { margin:0 0 8px; font-family:'Fraunces',serif; font-optical-sizing:auto; font-weight:550; letter-spacing:-0.01em; font-size:28px; line-height:1.12; color:var(--txt); }
.source-register-head p { margin:0; color:var(--mut2); font-size:14px; line-height:1.6; max-width:680px; }
.source-register-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; }
/* "How we verify" — compact explainer of the ✓ Verified / unverified system,
   folded into the source register (no separate page). */
.verify-method { margin-top:16px; padding-top:18px; border-top:1px solid var(--bdr); }
.verify-method-title {
  margin:0 0 12px; font-family:'Spline Sans Mono',monospace; font-size:11px; font-weight:700;
  letter-spacing:.12em; text-transform:uppercase; color:var(--mut2);
}
.verify-method-list { list-style:none; margin:0; padding:0; display:grid; gap:9px; max-width:760px; }
.verify-method-list li { display:flex; align-items:flex-start; gap:10px; font-size:13px; line-height:1.55; color:var(--mut2); }
.verify-method-list strong { color:var(--txt); font-weight:700; }
.vm-dot { flex:none; width:9px; height:9px; border-radius:50%; margin-top:5px; }
.vm-dot-ok  { background:var(--acc2); }
.vm-dot-no  { background:var(--mut); }
.vm-dot-mut { background:#D97706; }
.source-register-card {
  background:var(--surf); border:1px solid var(--bdr); border-radius:var(--r-lg);
  padding:16px 18px; display:flex; flex-direction:column; gap:7px;
  box-shadow:var(--shadow-xs); transition:border-color .16s, box-shadow .16s;
}
.source-register-card:hover { border-color:rgb(var(--acc-rgb) / .35); box-shadow:var(--shadow-sm); }
.src-card-head { display:flex; align-items:center; gap:9px; margin-bottom:3px; }
.src-card-icon {
  width:28px; height:28px; border-radius:8px; flex:0 0 auto;
  display:inline-flex; align-items:center; justify-content:center;
  background:var(--acc-dim); color:var(--acc);
}
.src-card-icon svg { width:14px; height:14px; }
.src-card-kicker {
  font-family:'Spline Sans Mono',monospace; font-size:10px; font-weight:700;
  letter-spacing:.14em; text-transform:uppercase; color:var(--mut);
}
.source-register-card strong { color:var(--txt); font-size:15px; line-height:1.28; }
.source-register-card small { color:var(--mut2); font-size:12px; line-height:1.45; }

/* ══════════════════════════════════════════════════════
   TOAST
   ══════════════════════════════════════════════════════ */
#toast { position:fixed; bottom:28px; left:50%; transform:translateX(-50%); background:var(--txt); color:var(--bg); padding:11px 24px; border-radius:100px; font-size:13px; font-weight:600; box-shadow:var(--shadow-lg); z-index:1000; transition:opacity .3s; }
.toast-visible { opacity:1; }
.toast-hidden  { opacity:0; pointer-events:none; }

/* ══════════════════════════════════════════════════════
   FOOTER
   ══════════════════════════════════════════════════════ */
.site-footer {
  border-top:1px solid var(--bdr); background:var(--surf);
  padding:44px 28px 28px; margin-top:48px;
}
.footer-grid {
  max-width:1040px; margin:0 auto;
  display:grid; grid-template-columns:minmax(240px,1.4fr) repeat(3,minmax(140px,1fr));
  gap:32px;
}
.footer-logo { margin-bottom:12px; }
.footer-logo .logo-mark { width:26px; height:26px; }
.footer-logo .logo-n { font-size:17px; }
.footer-tagline {
  font-family:'Fraunces',serif; font-optical-sizing:auto; font-weight:550;
  font-size:17px; line-height:1.35; color:var(--txt); margin:0 0 10px;
  letter-spacing:-0.01em; max-width:24ch;
}
.footer-desc { font-size:12px; color:var(--mut2); line-height:1.7; margin:0; max-width:34ch; }
.footer-col h3 {
  font-size:10px; letter-spacing:.16em; text-transform:uppercase;
  color:var(--mut); font-weight:700; margin:0 0 12px;
}
.footer-col a {
  display:block; font-size:13px; color:var(--mut2); text-decoration:none;
  padding:4px 0; transition:color .16s; width:fit-content;
}
.footer-col a:hover { color:var(--acc); }
.footer-trust-note { font-size:12px; color:var(--mut2); line-height:1.65; margin:0 0 8px; }
.footer-bottom {
  max-width:1040px; margin:32px auto 0; padding-top:18px;
  border-top:1px solid var(--bdr);
}
.footer-bottom p { font-size:11px; color:var(--mut); line-height:1.8; margin:0; }
/* Meta bar — mono data line left, made-with credit right (hairline below). */
.footer-meta {
  display:flex; justify-content:space-between; align-items:center;
  gap:10px 28px; flex-wrap:wrap; padding-bottom:16px; margin-bottom:16px;
  border-bottom:1px solid var(--bdr);
  font-family:'Spline Sans Mono',monospace; font-size:10.5px; font-weight:600;
  letter-spacing:.1em; text-transform:uppercase; color:var(--mut);
}
.footer-meta-credit { display:inline-flex; align-items:center; gap:5px; flex-wrap:wrap; color:var(--mut2); }
.footer-claude { color:#C96442; font-weight:700; }
[data-theme="dark"] .footer-claude { color:#E8A491; }
.footer-x {
  color:var(--txt); font-weight:700; text-decoration:underline;
  text-decoration-color:var(--bdr2); text-underline-offset:3px;
}
.footer-x:hover { color:var(--acc); text-decoration-color:var(--acc); }
.site-footer a { transition:color .16s; }
.dl-btn { padding:9px 22px; background:none; border:1.5px solid var(--bdr2); border-radius:100px; font-size:12px; font-weight:600; color:var(--mut2); cursor:pointer; font-family:'Plus Jakarta Sans',sans-serif; transition:all .18s; }
.dl-btn:hover { border-color:var(--acc); color:var(--acc); background:var(--acc-dim); }
.dl-btn:active { border-color:var(--acc); color:var(--acc); background:rgb(var(--acc-rgb) / .18); }
.editorial-note { background:var(--surf2); border-radius:12px; padding:14px 20px; margin:16px 0; }
.editorial-note p { font-size:11px; color:var(--mut); line-height:1.8; margin:0; }

/* ══════════════════════════════════════════════════════
   ANIMATIONS
   ══════════════════════════════════════════════════════ */
.fade { animation:fadeUp .34s var(--ease); }
@keyframes fadeUp { from{opacity:0;transform:translateY(10px)} to{opacity:1;transform:none} }

/* ══════════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════════ */
@media(max-width:540px) {
  header { top:10px; width:calc(100% - 20px); padding:0 14px; gap:10px; }
  .main { padding-top:84px; }
  .logo { min-width:0; gap:10px; }
  .logo-s { max-width:112px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; letter-spacing:.14em; }
  .header-actions { gap:6px; flex-shrink:0; }
  .icon-btn { width:34px; height:34px; border-radius:9px; }
  .lang-toggle { height:34px; border-radius:9px; }
  .lang-toggle::before,
  .lang-toggle::after { padding:0 8px; }
  .header-nav { display:none; }

  .home-hero { margin-top:-84px; padding:calc(58px + 84px) 14px 44px; }
  .home-hero::before,
  .home-hero::after { width:200px; height:117px; bottom:-18px; }
  .home-hero::before { left:-46px; }
  .home-hero::after  { right:-46px; }
  .home-hero-inner { max-width:100%; }
  .home-title {
    font-size:clamp(22px, 6.2vw, 32px);
    max-width:100%;
    overflow:visible;
  }
  .home-sub { font-size:14px; max-width:320px; margin-bottom:24px; white-space:normal; }
  .search-wrap.home-search { max-width:100%; margin-bottom:20px; }
  .home-search .search-input { padding:14px 18px 14px 46px; font-size:14px; }
  .home-search .search-icon { left:17px; }
  .home-search .search-results { max-height:360px; border-radius:16px; }
  .home-stats { align-items:center; gap:8px; font-size:12px; max-width:360px; }
  .home-stat-pill {
    min-height:36px; padding:5px 11px;
  }
  .home-stats strong { font-size:14px; }

  .map-zone-header {
    padding:16px 14px 4px;
    grid-template-columns:1fr; justify-items:center; gap:12px;
  }
  .map-zone-left { justify-self:center; }
  .map-zone-header > .map-hint { justify-self:center; }
  .map-zone-header > .browse-toggle { justify-self:center; }
  .browse-toggle { width:100%; max-width:280px; }
  .browse-toggle .bt { flex:1; padding:8px 12px; }
  .map-wrap { padding:0 10px 36px; max-width:100%; min-height:0; }
  .map-viewport {
    position:relative; top:auto; z-index:auto;
    max-width:100%; border-radius:10px;
    height:clamp(540px, calc(100vh - 96px), 760px);
  }
  .map-wrap svg { max-height:none; }
  .map-controls {
    bottom:12px; right:22px;
    gap:4px; padding:4px;
    max-width:calc(100% - 44px);
  }
  .map-control-btn { width:26px; min-width:26px; height:26px; min-height:26px; padding:0; }
  .map-control-reset { width:auto; padding:0 10px; }
  .map-control-reset { font-size:10px; }
  .map-zoom-level { min-width:42px; font-size:10px; }
  #state-list-grid { grid-template-columns:1fr; }

  .economy-panel {
    grid-template-columns:1fr; gap:20px;
    padding:20px 14px; margin-bottom:44px;
    border-radius:20px;
  }
  .economy-copy { position:static; }
  .economy-copy h2 { font-size:21px; }
  .economy-copy p { font-size:13px; }
  .economy-source { width:100%; justify-content:center; }
  .economy-row {
    grid-template-columns:28px minmax(118px,160px) minmax(90px,1fr) auto;
    gap:8px; min-height:42px; padding:7px 8px;
  }
  .eco-bar { min-width:80px; }
  .eco-country { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
  .eco-value { font-size:11px; }
  .economy-row-india { padding:7px 8px; }

  .source-register-panel { margin:30px auto 0; padding:0 14px; }
  .source-register-head { max-width:none; margin-bottom:14px; padding-bottom:13px; }
  .source-register-head h2 { font-size:22px; }
  .source-register-head p { font-size:13px; }
  .source-register-grid { grid-template-columns:1fr; }

  .pm-card { flex-direction:column; text-align:center; }
  .pm-detail { justify-content:center; }
  .minister-grid { grid-template-columns:1fr; }
  .minister-role { white-space:normal; }

  .view > .back { margin:0 14px 16px; padding:12px 16px; max-width:calc(100% - 28px); }
  .state-hdr,.content { padding-left:14px; padding-right:14px; }
  .state-nm { font-size:clamp(25px,8vw,36px); }
  .tabs { padding:7px 12px 0; gap:5px; }
  .tab { min-height:38px; padding:8px 12px; flex:0 0 auto; }
  .grid { grid-template-columns:repeat(auto-fill,minmax(138px,1fr)); gap:10px; }
  .lcard { padding:16px 12px; border-radius:18px; }
  .cm-card { flex-direction:column; align-items:center; text-align:center; padding:18px; }
  .cm-card > div:last-child { width:100%; }
  .cm-card .ptag { justify-content:center; }
  .party-filter-row { gap:8px; }
  .party-filter-label { width:100%; margin-right:0; }
  .filter-count { width:100%; margin-left:0; }
  .party-pill { padding:6px 11px; min-height:34px; }
  .project-handover { padding:10px; }
  .project-handover-head { align-items:flex-start; flex-direction:column; gap:4px; }
  .project-handover-line { text-align:left; }

  .det-wrap { padding-left:14px; padding-right:14px; }
  .det-hdr { flex-direction:column; }
  .det-img { width:92px; height:92px; }
  .det-grid { grid-template-columns:1fr; }
  .det-info-grid { grid-template-columns:1fr; gap:8px; margin-bottom:24px; grid-auto-rows:auto; }
  .det-info-card,
  .det-info-wide,
  .det-info-bio { grid-column:auto; min-height:auto; padding:13px 14px; border-radius:11px; justify-content:flex-start; }
  .det-info-label { margin-bottom:5px; }
  .det-info-value { font-size:14px; }
  .det-info-bio .det-info-value { max-width:none; line-height:1.75; }
  .quality-badges { gap:6px; }
  .quality-badge { white-space:normal; }
  .state-dashboard { padding:14px; border-radius:18px; }
  .state-dashboard-head { flex-direction:column; gap:12px; }
  .state-dashboard h3 { font-size:23px; }
  .state-dash-brief { grid-template-columns:1fr; }
  .state-dash-metrics { grid-template-columns:1fr; }
  .state-dash-project { grid-template-columns:1fr; }
  .state-dash-project small { align-items:flex-start; text-align:left; }
  .state-dash-project small span { max-width:100%; white-space:normal; }
  .leader-jump-nav { flex-wrap:nowrap; overflow-x:auto; scrollbar-width:none; }
  .leader-jump-nav::-webkit-scrollbar { display:none; }
  .det-cell { padding:16px; }
  .det-bio,
  .elec-result,
  .mplads-card,
  .proj-card,
  .coming-soon-notice { padding:16px; border-radius:16px; }
  .elec-row { flex-wrap:wrap; }
  .elec-stat { border-right:none !important; border-bottom:1px solid var(--bdr); min-width:45%; }
  .elec-stat:last-child { border-bottom:none; }
  .elec-label { flex-wrap:wrap; }
  .proj-header { flex-direction:column; align-items:flex-start; gap:8px; }
  .proj-status { white-space:normal; }
  .proj-summary { display:inline-block; margin:6px 0 0; }
  .pm-label { min-width:46px; }
  .parl-stats-links,
  .share-bar { align-items:stretch; }
  .share-bar .btn-secondary,
  .parl-stats-links .wiki-btn,
  .mplads-card .wiki-btn,
  .coming-soon-notice .wiki-btn { width:100%; justify-content:center; text-align:center; }

  .news-item.news-item-img { flex-direction:column; }
  .news-thumb { width:100%; height:140px; min-height:140px; border-right:none; border-bottom:1px solid var(--bdr); }
  .past-leaders-summary { flex-direction:column; align-items:flex-start; gap:4px; }
  .past-leader-row { padding:14px 16px; }
  .pl-meta { gap:6px; }

  .my-state-picker { width:100%; }
  .msp-row { width:100%; }
  .my-state-picker .my-state-select { flex:1 1 auto; width:auto; min-width:0; }

  .site-footer { padding:32px 14px 24px; }
  .footer-grid { grid-template-columns:1fr 1fr; gap:24px; }
  .footer-brand { grid-column:1 / -1; }
}
@media(max-width:400px) {
  .home-title { font-size:clamp(20px, 5.8vw, 25px); }
  .logo-s { display:none; }
  .logo-mark { width:26px; height:26px; }
  .home-search .search-input { font-size:13px; }
  .grid { grid-template-columns:1fr; }
}

/* ══════════════════════════════════════════════════════
   MOBILE BOTTOM NAVIGATION
   ══════════════════════════════════════════════════════ */
.mobile-bottom-nav { display:none; }

@media(max-width:540px) {
  /* Push all content above the bottom nav */
  .main { padding-bottom:68px; }

  .mobile-bottom-nav {
    display:flex;
    position:fixed; bottom:0; left:0; right:0; z-index:300;
    background:rgba(246,247,251,0.96);
    backdrop-filter:blur(20px) saturate(1.6);
    -webkit-backdrop-filter:blur(20px) saturate(1.6);
    border-top:1px solid var(--bdr);
    padding:6px 0 max(6px, env(safe-area-inset-bottom));
    box-shadow:0 -4px 20px rgba(18,24,58,0.08);
  }
  [data-theme="dark"] .mobile-bottom-nav {
    background:rgba(12,14,22,0.96);
    box-shadow:0 -4px 20px rgba(0,0,0,0.35);
  }
  .mbn-btn {
    flex:1; display:flex; flex-direction:column;
    align-items:center; justify-content:center; gap:3px;
    padding:6px 8px; background:none; border:none; cursor:pointer;
    font-family:'Plus Jakarta Sans',sans-serif; font-size:10px; font-weight:700;
    letter-spacing:.04em; color:var(--mut2);
    text-transform:uppercase;
    transition:color .16s, background .16s;
    border-radius:12px; margin:0 4px;
  }
  .mbn-btn svg { width:22px; height:22px; stroke:currentColor; fill:none; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
  .mbn-btn.active,
  .mbn-btn[aria-current="page"] { color:var(--acc); background:var(--acc-dim); }
  .mbn-btn:hover { background:var(--surf2); }
  .mbn-btn:active { transform:scale(.94); }

  /* Economy on mobile: compact, clean */
  .economy-panel {
    border-radius:16px;
    padding:18px 12px;
    margin-bottom:32px;
  }
  .economy-live-badge { font-size:9px; }
  .economy-copy h2 { font-size:18px; }
  .economy-copy p { font-size:12px; }
  .economy-source { width:100%; justify-content:center; }
  /* Two clean lines per row:
     line 1 → rank + country name
     line 2 → bar with the $ value at its right end */
  .economy-row {
    grid-template-columns:24px minmax(0,1fr) 58px;
    grid-template-rows:auto auto;
    gap:6px 8px; min-height:48px; align-items:center;
  }
  .eco-rank { width:24px; height:24px; font-size:10px; border-radius:6px; grid-row:1; grid-column:1; }
  .eco-country { font-size:12px; grid-row:1; grid-column:2 / -1; }
  .eco-bar {
    display:block; grid-row:2; grid-column:1 / 3;
    height:7px; min-width:0;
  }
  .eco-value { font-size:11px; grid-row:2; grid-column:3; text-align:right; }
  .economy-row-india { padding:7px 8px; }

  .municipal-summary,
  .municipal-stat-row,
  .municipal-projects { grid-template-columns:1fr; }
  .municipal-project-facts { grid-template-columns:1fr; }
  .municipal-summary h3 { font-size:18px; }
  .municipal-status-panel { padding:12px; }
  .municipal-stat { padding:12px; }
  .municipal-stat strong { font-size:20px; }
  .municipal-project-head { flex-direction:column; align-items:flex-start; gap:8px; }

  /* News thumbnails on mobile */
  .news-item.news-item-img { flex-direction:row; }
  .news-thumb { width:70px; min-height:78px; height:auto; border-right:1px solid var(--bdr); border-bottom:none; }
}

/* ══════════════════════════════════════════════════════
   SCROLLBAR
   ══════════════════════════════════════════════════════ */
::-webkit-scrollbar { width:4px; height:4px; }
::-webkit-scrollbar-track { background:transparent; }
::-webkit-scrollbar-thumb { background:var(--bdr2); border-radius:2px; }
