/* Electric homes (case studies). Look follows Rewiring's current print pieces and the case studies
   layout studio: cream paper, black marker ink, yellow highlighter, green figures, dashed story cards. */
@font-face {
  font-family: 'RA Election Display';
  src: url('/election-assets/fonts/RA-Election-Display.woff2') format('woff2');
  font-display: swap;
}

:root {
  --paper: #fffaf0;
  --soft: #f7f1e1;
  --ink: #1f2727;
  --ink-2: #5c5a52;
  --line: #d3caae;
  --card: #ffffff;
  --yellow: #ffc436;
  --yellow-soft: #fff1c9;
  --yellow-deep: #e0a100;
  --mint: #e7efe8;
  --mint-2: #c2d0c4;
  --sage: #527570;
  --good: #2f8a12;
  --good-soft: #d9f2c9;
  --good-ink: #1e5c07;

  --display: 'RA Election Display', 'Londrina Solid', 'Arial Narrow', sans-serif;
  --body: 'Rubik', system-ui, sans-serif;

  --pad: clamp(16px, 3.2vw, 48px);
  --gap: clamp(14px, 1.6vw, 24px);
  --border: 3px;
  --shadow: 4px 4px 0 var(--ink);
  --squiggle: 255px 15px 225px 15px / 15px 225px 15px 255px;
  --tap: 44px;
  --nav-h: 70px; /* the standard Rewiring nav is fixed over the top of the page */
}

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); }
/* Everything below lives inside .cs so the standard Rewiring nav and footer keep their own styles. */
.cs { background: var(--paper); color: var(--ink); font-family: var(--body); font-size: clamp(15px, .3vw + 14px, 18px); line-height: 1.5; -webkit-font-smoothing: antialiased; }
.cs *, .cs *::before, .cs *::after { box-sizing: border-box; }
:where(.cs img) { max-width: 100%; display: block; }
:where(.cs a) { color: var(--ink); text-underline-offset: 3px; }
:where(.cs button) { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.wrap { max-width: 1520px; margin: 0 auto; padding: 0 var(--pad); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 99; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.display { font-family: var(--display); font-weight: 400; text-transform: uppercase; letter-spacing: .005em; line-height: .95; }

/* ---------- standard Rewiring hero (same treatment as the EV leaderboard and regional reports) ---------- */
.cs .hero { position: relative; overflow: hidden; margin: 0; padding: calc(var(--nav-h) + clamp(44px, 5.5vw, 84px)) var(--pad) clamp(60px, 7.5vw, 112px); background: linear-gradient(160deg, #2c5e5b 0%, #14302f 100%); color: #d1e0df; }
.cs .hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .05; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
.cs .hero-inner { position: relative; z-index: 1; max-width: 1424px; margin: 0 auto; }
.cs .hero-art { position: absolute; right: clamp(0px, 4vw, 90px); top: 50%; width: clamp(240px, 27vw, 400px); padding: clamp(14px, 1.6vw, 24px); background: #FFFCF0; border-radius: 46% 54% 50% 50% / 52% 46% 54% 48%; transform: translateY(-50%) rotate(3deg); box-shadow: 0 18px 40px rgba(0, 0, 0, .28); }
.cs .hero-art img { width: 100%; height: auto; }
.cs .hero .sub { max-width: min(46ch, 58%); }
.cs .hero-links { max-width: 62%; }
.cs .hero h1 { max-width: min(14ch, 58%); }
.cs .hero h1 { margin: 0 0 22px; max-width: 14ch; font-family: var(--body); font-weight: 700; font-size: clamp(42px, 6vw, 76px); line-height: 1.04; letter-spacing: -.01em; color: #FFFCF0; text-wrap: balance; }
.cs .hero .sub { margin: 0; max-width: 46ch; font-size: clamp(1.05rem, 1.4vw, 1.3rem); line-height: 1.55; opacity: .92; }
.cs .hero-links { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 26px; margin-top: clamp(26px, 3vw, 40px); }
.cs a.hero-btn { display: inline-flex; align-items: center; min-height: 48px; padding: 0 1.5em; background: #f5b731; color: #1a3c3c; font-weight: 700; text-decoration: none; border-radius: 999px; transition: transform .12s ease, background .12s ease; }
.cs a.hero-btn:hover { background: #ffc94f; transform: translateY(-1px); }
.cs a.hero-link { display: inline-flex; align-items: center; gap: .45em; min-height: 44px; color: #FFFCF0; font-weight: 600; text-decoration: underline; text-decoration-color: rgba(255, 252, 240, .45); text-underline-offset: 5px; }
.cs a.hero-link:hover { text-decoration-color: #f5b731; }
.cs .hero :focus-visible { outline-color: #f5b731; }

.cs .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: var(--tap); padding: 0 1.2em;
  font-family: var(--display); font-size: 1.15em; text-transform: uppercase; letter-spacing: .02em; text-decoration: none; line-height: 1;
  background: var(--yellow); color: var(--ink); border: var(--border) solid var(--ink); border-radius: 999px;
  box-shadow: 3px 3px 0 var(--ink); cursor: pointer; transition: transform .12s ease, box-shadow .12s ease;
}
.btn:hover { transform: translate(-1px, -1px); box-shadow: 5px 5px 0 var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.btn.is-plain { background: var(--card); }
.btn.is-small { min-height: 38px; font-size: 1em; padding: 0 1em; }

/* ---------- browse: scrolling list beside a sticky map ---------- */
.browse { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(340px, .85fr); gap: var(--pad); align-items: start; padding-top: clamp(40px, 5.5vw, 84px); padding-bottom: calc(var(--pad) * 2); }
.hl { background: var(--yellow); padding: .02em .16em .06em; margin: 0 -.06em; border-radius: .18em .5em .22em .42em / .5em .2em .46em .24em; -webkit-box-decoration-break: clone; box-decoration-break: clone; }

.tools { display: grid; gap: clamp(20px, 2.2vw, 30px); }
.tools-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.tools h2 { font-size: clamp(26px, 2.6vw, 40px); margin: 0; scroll-margin-top: calc(var(--nav-h) + 14px); }
.seg { display: flex; flex-wrap: wrap; gap: 0; width: fit-content; max-width: 100%; border: var(--border) solid var(--ink); border-radius: 12px; overflow: hidden; background: var(--card); box-shadow: 3px 3px 0 var(--ink); }
.seg-btn { display: inline-flex; align-items: center; gap: .5em; min-height: var(--tap); padding: 0 1.05em; border: 0; border-right: 2px solid var(--ink); background: transparent; font-weight: 700; cursor: pointer; white-space: nowrap; }
.seg-btn:last-child { border-right: 0; }
.seg-btn span { font-weight: 600; font-size: .86em; opacity: .7; font-variant-numeric: tabular-nums; }
.seg-btn:hover { background: var(--yellow-soft); }
.seg-btn[aria-pressed="true"] { background: var(--yellow); }
.seg-btn[aria-pressed="true"] span { opacity: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: .4em; min-height: 38px; padding: 0 .9em; cursor: pointer; white-space: nowrap;
  font-weight: 600; font-size: .9em; background: var(--card); border: 2px solid var(--ink); border-radius: 999px;
}
.chip svg { width: 1.15em; height: 1.15em; flex: none; }
.chip:hover { background: var(--yellow-soft); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.tools-ctl { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.filter { position: relative; font-size: .9em; }
.filter summary { display: inline-flex; align-items: center; gap: .5em; min-height: 38px; padding: 0 2em 0 .9em; list-style: none; cursor: pointer; font-weight: 600; border: 2px solid var(--ink); border-radius: 999px; background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%231f2727' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right .8em center / 11px; user-select: none; }
.filter summary::-webkit-details-marker { display: none; }
.filter summary:hover, .filter[open] summary { background-color: var(--yellow-soft); }
.filter-n { display: inline-grid; place-items: center; min-width: 1.5em; height: 1.5em; padding: 0 .35em; border-radius: 999px; background: var(--ink); color: var(--paper); font-size: .82em; font-variant-numeric: tabular-nums; }
.filter-panel { position: absolute; z-index: 30; left: 0; top: calc(100% + 8px); width: min(380px, calc(100vw - var(--pad) * 2)); display: grid; gap: 10px; padding: 16px; background: var(--card); border: var(--border) solid var(--ink); border-radius: 14px; box-shadow: var(--shadow); font-size: 1.1em; }
.filter-panel h3 { margin: 4px 0 0; font-size: .95em; font-weight: 700; }
.filter-panel h3:first-child { margin-top: 0; }
.filter-panel .btn { justify-self: start; margin-top: 4px; }
.sort { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: .9em; }
.sort select { font: inherit; font-weight: 600; min-height: 38px; padding: 0 2em 0 .8em; border: 2px solid var(--ink); border-radius: 999px; background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%231f2727' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right .8em center / 11px; color: var(--ink); appearance: none; cursor: pointer; }

.where { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 10px 14px; background: var(--mint); border: 2px solid var(--ink); border-radius: 12px; font-weight: 600; }
.where button { margin-left: auto; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: calc(var(--gap) * 1.1); margin-top: clamp(26px, 3vw, 42px); padding: 0; list-style: none; }
.card {
  position: relative; display: flex; flex-direction: column; height: 100%; background: var(--card); color: var(--ink); text-decoration: none;
  border: var(--border) solid var(--ink); border-radius: 14px; box-shadow: var(--shadow); overflow: hidden;
  transition: transform .14s ease, box-shadow .14s ease;
}
.card:hover, .card.is-hot { transform: translate(-2px, -2px); box-shadow: 7px 7px 0 var(--ink); }
.card.is-hot { background: var(--yellow-soft); }
.card-photo { position: relative; aspect-ratio: 4 / 3; background: var(--mint); border-bottom: var(--border) solid var(--ink); overflow: hidden; }
.card-photo img { width: 100%; height: 100%; object-fit: cover; }
.card-photo .play { position: absolute; right: 10px; top: 10px; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--yellow); color: var(--ink); border: 2.5px solid var(--ink); box-shadow: 2px 2px 0 var(--ink); }
.card-photo .play svg { width: 20px; height: 20px; margin-left: 2px; }
.card-photo.is-empty { display: grid; place-items: center; background: var(--yellow-soft); }
.card-photo.is-empty .tech-big { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; max-width: 70%; color: var(--ink); }
.card-photo.is-empty svg { width: 38px; height: 38px; }
.pill { display: inline-block; font-family: var(--display); text-transform: uppercase; font-size: 1.1em; line-height: 1; letter-spacing: .02em; padding: .34em .7em .3em; background: var(--yellow); border: 2.5px solid var(--ink); border-radius: 999px; white-space: nowrap; }
.card-photo .pill { position: absolute; left: 10px; bottom: 10px; box-shadow: 2px 2px 0 var(--ink); }
.card-body { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px 16px; flex: 1; }
.card h3 { font-family: var(--display); font-weight: 400; text-transform: uppercase; font-size: clamp(26px, 2vw, 34px); line-height: .95; margin: 0; overflow-wrap: anywhere; }
.place { display: flex; align-items: center; gap: 6px; margin: 0; font-weight: 600; font-size: .9em; color: var(--ink-2); }
.place svg { width: 1em; height: 1em; flex: none; }
.card-save { display: none; margin: 0; font-weight: 700; color: var(--good-ink); }
.card-quote { margin: 0; font-size: .95em; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.tech-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 6px; }
.tech-row span { display: grid; place-items: center; width: 32px; height: 32px; border: 2px solid var(--ink); border-radius: 50%; background: var(--paper); }
.tech-row svg { width: 17px; height: 17px; }
.empty { padding: 28px 20px; border: 2px dashed var(--yellow-deep); border-radius: 14px; background: var(--card); text-align: center; font-weight: 600; }
.status { margin: var(--gap) 0 0; font-weight: 600; color: var(--ink-2); }

/* ---------- map ---------- */
.map-col { position: sticky; top: calc(var(--nav-h) + 16px); }
.map-panel { position: relative; background: var(--mint); border: var(--border) solid var(--ink); border-radius: 26px; box-shadow: 6px 6px 0 var(--ink); overflow: hidden; height: min(calc(100vh - var(--nav-h) - 36px), 900px); min-height: 480px; }
.map-svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; filter: drop-shadow(3px 4px 0 var(--ink)); }
.map-svg .land { fill: var(--paper); stroke: var(--ink); stroke-width: 2.5; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.pins { position: absolute; inset: 0; pointer-events: none; transition: opacity .18s ease; }
.pins.is-moving { opacity: 0; }
.pin {
  position: absolute; transform: translate(-50%, -50%); pointer-events: auto; cursor: pointer; padding: 0;
  display: grid; place-items: center; min-width: 22px; height: 22px; border-radius: 999px;
  background: var(--yellow); border: 2.5px solid var(--ink); box-shadow: 2px 2px 0 var(--ink);
  font-weight: 700; font-size: 14px; line-height: 1; color: var(--ink);
  transition: transform .12s ease, background .12s ease;
}
.pin::before { content: ''; position: absolute; inset: -12px; border-radius: 50%; } /* 44px touch target */
.pin.is-many { min-width: 34px; height: 34px; padding: 0 6px; font-size: 16px; }
.pin:hover, .pin:focus-visible, .pin.is-hot { transform: translate(-50%, -50%) scale(1.18); z-index: 3; }
.pin.is-hot, .pin.is-on { background: var(--ink); color: var(--yellow); }
.pin-tip { position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%); padding: 5px 10px; background: var(--ink); color: var(--paper); border-radius: 8px; font-size: 13px; font-weight: 600; white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .12s ease; }
.pin:hover .pin-tip, .pin:focus-visible .pin-tip, .pin.is-hot .pin-tip { opacity: 1; }
.map-tools { position: absolute; right: 14px; bottom: 14px; display: flex; gap: 8px; align-items: center; }
.map-btn { display: grid; place-items: center; min-width: var(--tap); height: var(--tap); padding: 0 12px; background: var(--card); border: 2.5px solid var(--ink); border-radius: 999px; box-shadow: 2px 2px 0 var(--ink); font-weight: 700; cursor: pointer; }
.map-btn:hover { background: var(--yellow); }
.map-btn svg { width: 18px; height: 18px; }
.map-note { position: absolute; left: 18px; top: 16px; margin: 0; max-width: 15ch; font-family: var(--display); text-transform: uppercase; font-size: clamp(20px, 1.7vw, 28px); line-height: 1; transform: rotate(-3deg); }
.map-note svg { display: block; width: 46px; height: 34px; margin: 4px 0 0 30px; }

/* ---------- one home ---------- */
.home { padding-top: calc(var(--nav-h) + var(--pad) * .8); padding-bottom: calc(var(--pad) * 2); }
.back { display: inline-flex; align-items: center; gap: 8px; min-height: var(--tap); font-weight: 700; text-decoration: none; }
.back:hover { text-decoration: underline; }
.back svg { width: 18px; height: 18px; }
.home-head { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: var(--pad); align-items: center; padding: var(--gap) 0 calc(var(--pad) * 1.2); }
.home-head h1 { font-size: clamp(52px, 7.4vw, 124px); line-height: 1.12; margin: 0; overflow-wrap: anywhere; }
.home-head h1 .hl { padding: 0 .14em .04em; }
.home-meta { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 18px 0 0; font-weight: 600; color: var(--ink-2); }
.qmark { display: block; width: 58px; height: 37px; margin: 28px 0 10px; background: var(--yellow); -webkit-mask: url('../img/quote-marks.svg') center / contain no-repeat; mask: url('../img/quote-marks.svg') center / contain no-repeat; filter: drop-shadow(3px 3px 0 var(--ink)); }
.home-quote { margin: 0; max-width: 28ch; font-weight: 700; font-size: clamp(20px, 2vw, 30px); line-height: 1.25; letter-spacing: -.01em; text-wrap: balance; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 0; padding: 0; list-style: none; }
.tag { display: inline-flex; align-items: center; gap: .4em; font-family: var(--display); text-transform: uppercase; font-size: 1.05em; line-height: 1; padding: .42em .7em .36em; background: var(--yellow); border: 2.5px solid var(--ink); border-radius: 8px; box-shadow: 2px 2px 0 var(--ink); }
.tag svg { width: 1.05em; height: 1.05em; }
.home-quote.is-long { max-width: 44ch; font-weight: 600; font-size: clamp(17px, 1.35vw, 21px); line-height: 1.45; letter-spacing: 0; text-wrap: pretty; }
.frame { position: relative; justify-self: center; width: min(100%, 560px); transform: rotate(1.6deg); }
.frame-in { border: 7px solid var(--ink); border-radius: var(--squiggle); overflow: hidden; background: var(--mint); aspect-ratio: 5 / 4; }
.frame-in img { width: 100%; height: 100%; object-fit: cover; }
.frame .bolt { position: absolute; left: -34px; bottom: 26px; width: 64px; height: 84px; transform: rotate(-8deg); }
.frame.is-map { width: min(100%, 400px); transform: rotate(-1.4deg); }
.frame.is-map .frame-in { position: relative; aspect-ratio: 3 / 4; }
.frame.is-map svg.mini-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.frame.is-map .land { fill: var(--paper); stroke: var(--ink); stroke-width: 2; vector-effect: non-scaling-stroke; }
.frame.is-map .dot { fill: var(--yellow); stroke: var(--ink); stroke-width: 3; vector-effect: non-scaling-stroke; }

.band { border-top: 2px solid var(--ink); padding: calc(var(--pad) * 1.1) 0; }
.band > h2 { font-size: clamp(30px, 3.2vw, 52px); margin: 0 0 var(--gap); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin: 0; padding: 0; list-style: none; }
.stats li { padding: 4px 24px; border-left: 2px solid var(--line); }
.stats li:first-child { border-left: 0; padding-left: 0; }
.stats b { display: block; font-weight: 800; font-size: clamp(46px, 6vw, 96px); line-height: .95; letter-spacing: -.03em; color: var(--good); white-space: nowrap; }
.stats span { display: block; margin-top: 8px; font-weight: 700; }

.words-title { display: inline-block; font-weight: 700; font-size: clamp(30px, 3.4vw, 54px); letter-spacing: -.02em; line-height: 1.1; margin: 0 0 calc(var(--gap) * 1.4); padding-bottom: 14px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 12' preserveAspectRatio='none'%3E%3Cpath d='M2 7c14-7 22 5 36 0s22-6 36 0 22 5 36 0 22-6 36 0 22 5 36 0 12-3 16-2' fill='none' stroke='%23ffc436' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat left bottom / 82% 12px; }
.words { columns: 2; column-gap: var(--gap); }
.qa { break-inside: avoid; margin: 0 0 var(--gap); padding: 20px 22px; background: var(--card); border: 2.5px dashed var(--yellow-deep); border-radius: 14px; }
.qa h3 { margin: 0 0 8px; font-size: 1.2em; font-weight: 700; letter-spacing: -.01em; line-height: 1.25; }
.qa p { margin: 0 0 .7em; }
.qa p:last-child { margin-bottom: 0; }
/* free-form stories: one column of text, an optional video above it and a credit line below */
.tale .prose { max-width: 72ch; padding: clamp(20px, 2.4vw, 34px) clamp(20px, 2.6vw, 38px); background: var(--card); border: 2.5px dashed var(--yellow-deep); border-radius: 14px; font-size: 1.06em; line-height: 1.62; }
.prose > * { margin: 0 0 1em; }
.prose > *:last-child { margin-bottom: 0; }
.prose h3 { margin-top: 1.5em; font-size: 1.2em; font-weight: 700; letter-spacing: -.01em; line-height: 1.25; }
.prose h3:first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: 0 0 .4em; }
.prose blockquote { margin-left: 0; padding-left: 1em; border-left: 4px solid var(--yellow); }
.prose blockquote p { margin: 0; }
.cs .prose a, .cs .credit a { font-weight: 600; text-decoration-color: var(--yellow-deep); text-decoration-thickness: 2px; overflow-wrap: anywhere; }
.video { max-width: 860px; margin: 0 0 var(--gap); aspect-ratio: 16 / 9; border: 5px solid var(--ink); border-radius: 14px; overflow: hidden; background: var(--ink); box-shadow: var(--shadow); }
.video iframe { display: block; width: 100%; height: 100%; border: 0; }
.credit { max-width: 72ch; margin: 16px 0 0; font-size: .95em; color: var(--ink-2); }
.big-quote { break-inside: avoid; margin: 0 0 var(--gap); padding: 10px 4px 18px; }
.big-quote p { margin: 0; font-family: var(--display); text-transform: uppercase; font-size: clamp(30px, 3vw, 50px); line-height: 1.02; text-wrap: balance; }
.big-quote cite { display: block; margin-top: 12px; font-style: normal; font-weight: 600; color: var(--ink-2); }

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--gap); }
.fact { padding: 22px; background: var(--card); border: 2.5px dashed var(--yellow-deep); border-radius: 14px; }
.fact > h3 { display: inline-block; margin: 0 0 16px; font-family: var(--display); font-weight: 400; text-transform: uppercase; font-size: 1.3em; line-height: 1; padding: .4em .7em .34em; background: var(--yellow); border: 2.5px solid var(--ink); border-radius: 8px; box-shadow: 2px 2px 0 var(--ink); }
.bill + .bill { margin-top: 18px; }
.bill-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; font-weight: 700; }
.delta { font-size: .8em; font-weight: 700; padding: .25em .7em; border-radius: 999px; background: var(--good-soft); color: var(--good-ink); border: 1.5px solid var(--good-ink); white-space: nowrap; }
.bar-row { display: grid; grid-template-columns: 3.6em 1fr auto; align-items: center; gap: 10px; font-size: .85em; font-weight: 600; margin-top: 6px; }
.bar-row > span:first-child { color: var(--ink-2); }
.bar { height: 14px; }
.bar i { display: block; height: 100%; min-width: 14px; border: 2px solid var(--ink); border-radius: 999px; background: var(--line); }
.bar.is-after i { background: var(--good); }
.bill-remark { margin: 8px 0 0; font-size: .85em; color: var(--ink-2); }
.spec { margin: 0; }
.spec div { display: grid; grid-template-columns: 6em 1fr; gap: 12px; padding: 10px 0; border-top: 1.5px solid var(--line); }
.spec div:first-child { border-top: 0; padding-top: 0; }
.spec dt { font-weight: 700; color: var(--ink-2); font-size: .9em; }
.spec dd { margin: 0; }
.mini { position: relative; height: 300px; background: var(--mint); border: 2.5px solid var(--ink); border-radius: 12px; overflow: hidden; }
.mini svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.mini .land { fill: var(--paper); stroke: var(--ink); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.mini .dot { fill: var(--yellow); stroke: var(--ink); stroke-width: 2.5; vector-effect: non-scaling-stroke; }
.mini-cap { margin: 12px 0 0; font-weight: 600; }

.more .cards { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }

/* Server-rendered copy for crawlers and no-JS readers; the script replaces it. */
.js #ssr { display: none; }
#ssr { padding-top: var(--pad); padding-bottom: var(--pad); }
#ssr li { margin: .4em 0; }

/* ---------- share band + keep exploring ---------- */
.share-band { background: var(--yellow); border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); }
.share-band .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--gap); padding-top: calc(var(--pad) * 1.1); padding-bottom: calc(var(--pad) * 1.1); }
.share-band h2 { font-size: clamp(34px, 4.4vw, 72px); margin: 0; }
.share-band p { margin: 10px 0 0; max-width: 48ch; font-size: 1.1em; }
.cs .share-band a.btn { background: var(--ink); color: var(--paper); box-shadow: 3px 3px 0 var(--paper); font-size: 1.35em; min-height: 56px; padding: 0 1.4em; }
.explore .wrap { padding-top: calc(var(--pad) * 1.3); padding-bottom: calc(var(--pad) * 1.6); }
.explore h2 { font-size: clamp(30px, 3.2vw, 52px); margin: 0 0 var(--gap); }
.explore-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: calc(var(--gap) * 1.1); }
.cs a.explore-card { display: flex; flex-direction: column; gap: 8px; padding: 26px 28px; background: var(--card); text-decoration: none; border: var(--border) solid var(--ink); border-radius: 14px; box-shadow: var(--shadow); transition: transform .14s ease, box-shadow .14s ease, background .14s ease; }
.cs a.explore-card:hover { transform: translate(-2px, -2px); box-shadow: 7px 7px 0 var(--ink); background: var(--yellow-soft); }
.explore-card h3 { margin: 0; font-family: var(--display); font-weight: 400; text-transform: uppercase; font-size: clamp(28px, 2.4vw, 40px); line-height: .98; }
.explore-card p { margin: 0; max-width: 40ch; }
.explore-go { margin-top: 10px; font-weight: 700; }

/* ---------- smaller screens ---------- */
@media (max-width: 980px) {
  .browse { grid-template-columns: 1fr; }
  .map-col { position: static; order: 2; }
  .intro { display: contents; }
  .intro-list { order: 3; }
  .map-panel { height: min(74vh, 620px); min-height: 420px; }
  .home-head { grid-template-columns: 1fr; }
  .frame { order: -1; width: min(86%, 460px); }
  .words { columns: 1; }
}
@media (max-width: 620px) {
  :root { --border: 2.5px; --shadow: 3px 3px 0 var(--ink); }
  .seg { width: 100%; }
  .seg-btn { flex: 1 1 auto; justify-content: center; padding: 0 .7em; font-size: .95em; }
  .card-photo .play { right: 6px; top: 6px; width: 30px; height: 30px; }
  .card-photo .play svg { width: 15px; height: 15px; }
  .cs .hero-art { position: static; width: min(54vw, 230px); margin: 0 0 22px; transform: rotate(-3deg); }
  .cs .hero h1, .cs .hero .sub, .cs .hero-links { max-width: none; }
  .cs .hero-links { gap: 2px 22px; }
  .cs a.hero-btn { margin-bottom: 10px; }
  .cards, .more .cards { grid-template-columns: 1fr; gap: 12px; }
  .card { flex-direction: row; border-radius: 12px; }
  .card-photo { flex: none; width: 112px; aspect-ratio: auto; border-bottom: 0; border-right: var(--border) solid var(--ink); }
  .card-photo .pill, .card-quote { display: none; }
  .card-photo.is-empty .tech-big { max-width: 84%; gap: 6px; }
  .card-photo.is-empty svg { width: 26px; height: 26px; }
  .card-save { display: block; font-size: .92em; }
  .card-body { padding: 12px 14px; gap: 5px; }
  .card h3 { font-size: 26px; }
  .tech-row span { width: 26px; height: 26px; border-width: 1.5px; }
  .tech-row svg { width: 14px; height: 14px; }
  .stats li { border-left: 0; padding: 12px 0; border-top: 2px solid var(--line); }
  .stats li:first-child { border-top: 0; }
  .frame .bolt { left: -14px; width: 46px; height: 60px; }
  .map-note { font-size: 18px; }
  .facts { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
