/* Intel 61 — live Israeli election results (Intel Global). White page, blue ink. */
@font-face { font-family: 'Sora'; font-weight: 300 800; font-display: swap; src: url(fonts/Sora-latin-a3354b.woff2) format('woff2'); }
@font-face { font-family: 'Plex'; font-weight: 300 700; font-display: swap; src: url(fonts/IBMPlexSans-latin-f66677.woff2) format('woff2'); }

:root {
  --blue: #0038b8;          /* Israeli-flag blue */
  --blue-2: #1d4fd1;
  --ink: #0b1f4d;
  --muted: #5b6b8c;
  --line: #e3e9f6;
  --soft: #f3f6fd;
  --paper: #ffffff;
  --gold: #c99a06;
  --red: #c62828;
  --green: #12804a;
  --radius: 16px;
  --display: 'Sora', system-ui, -apple-system, 'Segoe UI', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji';
  --text: 'Plex', system-ui, -apple-system, 'Segoe UI', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji';
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--text); font-size: 16px; line-height: 1.45; overflow-x: hidden; }
button { font: inherit; color: inherit; cursor: pointer; }
img { display: block; }
.num { font-family: var(--display); font-variant-numeric: tabular-nums; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.hide { display: none !important; }

/* ── welcome ─────────────────────────────────────────────────────────── */
#welcome { position: fixed; inset: 0; z-index: 50; background: var(--paper); display: flex; padding: 24px 16px; overflow-y: auto; }
#welcome .card { width: 100%; max-width: 520px; text-align: center; margin: auto; }
.brand-big { font-family: var(--display); font-weight: 800; font-size: clamp(56px, 16vw, 104px); letter-spacing: -0.04em; color: var(--blue); line-height: .95; margin: 14px 0 6px; }
.brand-big span { display: inline-block; }
.tagline { font-family: var(--display); font-size: 18px; color: var(--muted); margin: 0 0 22px; }
.stripe { height: 10px; background: linear-gradient(var(--blue) 0 35%, transparent 35% 65%, var(--blue) 65%); margin: 0 auto 22px; width: 120px; border-radius: 2px; }
.how { text-align: left; background: var(--soft); border-radius: var(--radius); padding: 16px 18px; margin: 0 0 22px; }
.how h2 { font-family: var(--display); font-size: 15px; letter-spacing: .08em; text-transform: uppercase; color: var(--blue); margin: 0 0 10px; }
.how ol { margin: 0; padding-left: 20px; }
.how li { margin: 6px 0; }
.how b { color: var(--blue); }
.enter { display: inline-flex; align-items: center; gap: 10px; background: var(--blue); color: #fff; border: 0; border-radius: 999px; padding: 16px 30px; font-family: var(--display); font-weight: 700; font-size: 18px; box-shadow: 0 10px 30px rgba(0,56,184,.28); transition: transform .15s; }
.enter:active { transform: scale(.97); }
.enter .dot { width: 10px; height: 10px; border-radius: 50%; background: #fff; animation: pulse 1.4s infinite; }
.small-note { color: var(--muted); font-size: 13px; margin-top: 12px; }
.by { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; }
.by img { width: 26px; height: 26px; border-radius: 50%; }
@keyframes pulse { 0%,100% { opacity: 1; transform: scale(1);} 50% { opacity: .35; transform: scale(.7);} }

/* ── top bar ─────────────────────────────────────────────────────────── */
header.top { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
header.top .wrap { display: flex; align-items: center; gap: 10px; height: 58px; }
.logo { width: 32px; height: 32px; border-radius: 50%; flex: none; }
.brand { font-family: var(--display); font-weight: 800; font-size: 22px; color: var(--blue); letter-spacing: -0.03em; white-space: nowrap; }
.brand small { font-weight: 500; font-size: 13px; color: var(--muted); letter-spacing: 0; margin-left: 6px; }
.top .sp { flex: 1; }
.live-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; letter-spacing: .06em; color: var(--red); text-transform: uppercase; }
.live-pill i { width: 8px; height: 8px; border-radius: 50%; background: var(--red); animation: pulse 1.4s infinite; }
.live-pill.final { color: var(--green); } .live-pill.final i { background: var(--green); animation: none; }
.follow { display: inline-flex; align-items: center; gap: 6px; background: var(--ink); color: #fff; text-decoration: none; font-size: 13px; font-weight: 600; padding: 7px 12px; border-radius: 999px; white-space: nowrap; }
.follow svg { width: 13px; height: 13px; fill: #fff; }
.iconbtn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: #fff; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.iconbtn svg { width: 18px; height: 18px; stroke: var(--blue); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
@media (max-width: 560px) { .brand small, .follow .t { display: none; } .follow { padding: 8px; } }

/* ── progress ────────────────────────────────────────────────────────── */
.progress { padding: 14px 0 4px; }
.progress .row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.progress .row b { color: var(--ink); font-family: var(--display); font-size: 18px; }
.bar { height: 6px; background: var(--soft); border-radius: 99px; overflow: hidden; margin-top: 8px; }
.bar i { display: block; height: 100%; width: 0; background: var(--blue); border-radius: 99px; transition: width 1.2s cubic-bezier(.2,.8,.2,1); }

/* ── section shell ───────────────────────────────────────────────────── */
section.blk { padding: 22px 0; border-bottom: 1px solid var(--line); }
.blk h2 { font-family: var(--display); font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--blue); margin: 0 0 14px; display: flex; align-items: center; gap: 10px; }
.blk h2 .hint { text-transform: none; letter-spacing: 0; font-family: var(--text); font-size: 13px; color: var(--muted); font-weight: 400; }
.seg { display: inline-flex; background: var(--soft); border-radius: 999px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600; color: var(--muted); }
.seg button.on { background: #fff; color: var(--blue); box-shadow: 0 1px 4px rgba(11,31,77,.12); }

/* ── race to 61 ──────────────────────────────────────────────────────── */
.race-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }
.side { display: flex; align-items: center; gap: 12px; min-width: 0; }
.side.r { flex-direction: row-reverse; text-align: right; }
.face { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; background: var(--soft); border: 3px solid #fff; box-shadow: 0 0 0 2px var(--c, var(--blue)); flex: none; }
.side .lbl { font-size: 13px; color: var(--muted); line-height: 1.2; }
.side .lbl b { display: block; color: var(--ink); font-size: 15px; }
.big { font-family: var(--display); font-weight: 800; font-size: clamp(54px, 13vw, 96px); line-height: .9; letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.race-bar { position: relative; height: 44px; margin: 16px 0 8px; border-radius: 12px; background: var(--soft); overflow: hidden; display: flex; }
.race-bar .s { height: 100%; transition: flex-basis 1.4s cubic-bezier(.2,.8,.2,1); flex: 0 0 0; position: relative; }
.race-bar .s span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-family: var(--display); font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; }
.race-bar .gap { flex: 1 1 auto; }
.race-61 { position: absolute; top: -6px; bottom: -6px; width: 2px; background: var(--ink); }
.race-61.l { left: calc(61 / 120 * 100%); } .race-61.r { right: calc(61 / 120 * 100%); }
.race-legend { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); flex-wrap: wrap; gap: 6px; }
.race-legend .k { display: inline-flex; align-items: center; gap: 6px; }
.race-legend .k i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.need { text-align: center; font-size: 15px; margin-top: 10px; }
.need b { font-family: var(--display); color: var(--blue); }
.ai-line { margin-top: 14px; background: var(--soft); border-left: 3px solid var(--blue); border-radius: 0 12px 12px 0; padding: 10px 14px; font-size: 15px; }
.ai-line small { display: block; color: var(--muted); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 2px; }

/* ── hemicycle ───────────────────────────────────────────────────────── */
.hemi-wrap { display: grid; grid-template-columns: 1fr; gap: 18px; align-items: center; }
@media (min-width: 900px) { .hemi-wrap { grid-template-columns: 1.2fr 1fr; } }
#hemi { width: 100%; max-width: 620px; margin: 0 auto; display: block; }
#hemi circle { transition: fill .8s ease; }
.hemi-key { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; }
.hemi-key span { display: inline-flex; align-items: center; gap: 6px; }
.hemi-key i { width: 10px; height: 10px; border-radius: 50%; }

/* ── party rows ──────────────────────────────────────────────────────── */
.parties { display: grid; grid-template-columns: 1fr; gap: 8px; }
@media (min-width: 900px) { .parties { grid-template-columns: 1fr 1fr; gap: 8px 22px; } }
.prow { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; padding: 10px 4px; border-bottom: 1px solid var(--line); transition: background .6s; }
.prow.flash { background: #eaf1ff; }
.pics { position: relative; width: 44px; height: 44px; }
.pics .ph { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.pics .lg { position: absolute; right: -6px; bottom: -4px; width: 22px; height: 22px; border-radius: 6px; background: #fff; object-fit: contain; box-shadow: 0 1px 4px rgba(0,0,0,.2); padding: 1px; }
.badge { display: flex; align-items: center; justify-content: center; border-radius: 50%; color: #fff; font-family: var(--display); font-weight: 700; }
.pname { min-width: 0; }
.pname b { display: block; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pname .ldr { color: var(--muted); font-size: 13px; }
.pname .mini { height: 5px; background: var(--soft); border-radius: 9px; margin-top: 6px; overflow: hidden; }
.pname .mini i { display: block; height: 100%; border-radius: 9px; transition: width 1.2s cubic-bezier(.2,.8,.2,1); }
.pname .stats { font-size: 12px; color: var(--muted); margin-top: 3px; font-variant-numeric: tabular-nums; }
.pseats { text-align: right; min-width: 52px; }
.pseats .n { font-family: var(--display); font-weight: 800; font-size: 30px; line-height: 1; }
.pseats .d { font-size: 12px; font-weight: 700; display: block; height: 15px; }
.d.up { color: var(--green); } .d.down { color: var(--red); }
.pseats .proj { font-size: 11px; color: var(--muted); }

/* ── threshold ───────────────────────────────────────────────────────── */
.th-list { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 700px) { .th-list { grid-template-columns: 1fr 1fr; } }
.th { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; }
.th .g { grid-column: 1 / -1; position: relative; height: 10px; background: var(--soft); border-radius: 9px; }
.th .g i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 9px; transition: width 1.2s; }
.th .g u { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--ink); left: calc(3.25 / 6 * 100%); }
.tag { font-size: 11px; font-weight: 800; letter-spacing: .08em; padding: 3px 8px; border-radius: 6px; }
.tag.in { background: #e3f5ea; color: var(--green); } .tag.out { background: #fde8e8; color: var(--red); }

/* ── exit polls ──────────────────────────────────────────────────────── */
.tabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 8px 14px; font-size: 14px; font-weight: 600; color: var(--muted); }
.tabs button.on { background: var(--blue); border-color: var(--blue); color: #fff; }
.tabs button .star { color: var(--gold); }
.ep-meta { font-size: 13px; color: var(--muted); margin: 8px 0 10px; }
.closest { display: inline-flex; align-items: center; gap: 6px; background: #fff7dc; color: #7a5b00; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.ep-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.ep-table td, .ep-table th { padding: 8px 6px; border-bottom: 1px solid var(--line); text-align: right; }
.ep-table th { font-size: 12px; color: var(--muted); font-weight: 600; }
.ep-table td:first-child, .ep-table th:first-child { text-align: left; }
.ep-table .dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 8px; }
.ep-blocs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.ep-blocs span { background: var(--soft); border-radius: 10px; padding: 6px 10px; font-size: 13px; }
.ep-blocs b { font-family: var(--display); }

/* ── coalition builder ───────────────────────────────────────────────── */
.meter { position: relative; height: 18px; background: var(--soft); border-radius: 99px; overflow: hidden; margin: 6px 0 4px; }
.meter i { display: block; height: 100%; width: 0; background: var(--blue); transition: width .5s cubic-bezier(.2,.8,.2,1), background .4s; border-radius: 99px; }
.meter.win i { background: linear-gradient(90deg, #e2b100, var(--gold)); }
.meter u { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--ink); left: calc(61 / 120 * 100%); }
.cb-total { display: flex; justify-content: space-between; align-items: baseline; }
.cb-total .big2 { font-family: var(--display); font-size: 40px; font-weight: 800; }
.cb-total .big2.win { color: var(--gold); }
.chips { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; margin-top: 12px; }
.chip { display: flex; align-items: center; gap: 8px; border: 1.5px solid var(--line); border-radius: 12px; padding: 8px; background: #fff; text-align: left; transition: border-color .2s, background .2s, transform .1s; }
.chip:active { transform: scale(.97); }
.chip.on { border-color: var(--blue); background: #eef3ff; }
.chip img, .chip .badge { width: 30px; height: 30px; border-radius: 8px; object-fit: contain; flex: none; }
.chip b { font-size: 13px; line-height: 1.15; display: block; }
.chip small { color: var(--muted); font-size: 12px; }
.warns { margin-top: 10px; display: grid; gap: 6px; }
.warn { background: #fff7e6; border: 1px solid #f6dfae; color: #6b4b00; font-size: 13px; padding: 8px 10px; border-radius: 10px; }
.cb-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.btn { border: 0; border-radius: 999px; padding: 10px 16px; font-weight: 700; font-size: 14px; background: var(--soft); color: var(--blue); }
.btn.primary { background: var(--blue); color: #fff; }
.btn:disabled { opacity: .45; cursor: default; }

/* ── map ─────────────────────────────────────────────────────────────── */
.map-box { position: relative; height: min(70vh, 620px); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--soft); }
#map { position: absolute; inset: 0; }
.map-search { position: absolute; z-index: 3; top: 10px; left: 10px; right: 10px; max-width: 340px; }
.map-search input { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font: inherit; font-size: 15px; background: #fff; box-shadow: 0 4px 16px rgba(11,31,77,.1); }
.map-sug { background: #fff; border-radius: 12px; margin-top: 4px; box-shadow: 0 8px 24px rgba(11,31,77,.14); overflow: hidden; }
.map-sug button { display: block; width: 100%; text-align: left; border: 0; background: #fff; padding: 9px 12px; font-size: 14px; border-bottom: 1px solid var(--line); }
.town-card { position: absolute; z-index: 3; left: 10px; right: 10px; bottom: 10px; max-width: 360px; background: #fff; border-radius: 14px; padding: 12px 14px; box-shadow: 0 8px 30px rgba(11,31,77,.18); }
.town-card h3 { margin: 0 0 6px; font-family: var(--display); font-size: 17px; display: flex; justify-content: space-between; }
.town-card h3 button { border: 0; background: none; color: var(--muted); font-size: 20px; line-height: 1; }
.town-card .tr { display: grid; grid-template-columns: 10px 1fr auto; gap: 8px; align-items: center; font-size: 14px; padding: 3px 0; }
.town-card .tr i { width: 10px; height: 10px; border-radius: 50%; }
.town-card small { color: var(--muted); }
.map-empty { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--muted); text-align: center; padding: 20px; z-index: 2; pointer-events: none; }
.maplibregl-popup-content { font-family: var(--text); }

/* ── news ────────────────────────────────────────────────────────────── */
.news { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 900px) { .news { grid-template-columns: 1fr 1fr; } }
.item { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; animation: slidein .6s ease both; }
.item.brk { border-color: var(--red); box-shadow: 0 0 0 1px var(--red) inset; }
.item .src { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.item .src b { color: var(--blue); }
.item p { margin: 0; font-size: 15px; white-space: pre-line; overflow-wrap: anywhere; }
.item .orig { margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); direction: rtl; text-align: right; color: var(--muted); font-size: 14px; white-space: pre-line; }
.item .acts { display: flex; gap: 12px; margin-top: 8px; font-size: 13px; }
.item .acts button, .item .acts a { border: 0; background: none; padding: 0; color: var(--blue); font-weight: 600; text-decoration: none; }
.brk-tag { color: #fff; background: var(--red); font-weight: 800; font-size: 10px; letter-spacing: .1em; padding: 2px 6px; border-radius: 4px; margin-right: 6px; }
@keyframes slidein { from { opacity: 0; transform: translateY(10px);} to { opacity: 1; transform: none; } }

/* ── footer ──────────────────────────────────────────────────────────── */
footer { padding: 26px 0 40px; color: var(--muted); font-size: 13px; }
footer a { color: var(--blue); }
footer .credits { margin-top: 10px; font-size: 11px; }
footer .credits summary { cursor: pointer; }

/* ── the flip ────────────────────────────────────────────────────────── */
#flip { position: fixed; inset: 0; z-index: 40; pointer-events: none; overflow: hidden; }
#flip .panel { position: absolute; inset: 0; background: var(--blue); transform: translateX(-105%); display: flex; align-items: center; justify-content: center; text-align: center; color: #fff; padding: 24px; }
#flip .panel.brk { background: #0b1f4d; }
#flip .panel::before, #flip .panel::after { content: ''; position: absolute; left: 0; right: 0; height: 7%; background: #fff; opacity: .95; }
#flip .panel::before { top: 9%; } #flip .panel::after { bottom: 9%; }
#flip .inner { max-width: 900px; max-height: 64%; opacity: 0; transform: scale(.92); position: relative; z-index: 1; }
#flip .kicker { font-family: var(--display); font-weight: 700; letter-spacing: .3em; font-size: clamp(13px, 2.4vw, 18px); opacity: .85; text-transform: uppercase; }
#flip .head { font-family: var(--display); font-weight: 800; font-size: clamp(34px, 8vw, 84px); line-height: 1.02; letter-spacing: -0.03em; margin: 14px 0; }
#flip .sub { font-size: clamp(16px, 3vw, 24px); opacity: .9; }
#flip .who { width: clamp(84px, 16vw, 140px); height: clamp(84px, 16vw, 140px); border-radius: 50%; object-fit: cover; margin: 0 auto 6px; border: 4px solid #fff; background: rgba(255,255,255,.15); }
#flip.go .panel { animation: wipe 5s cubic-bezier(.7,0,.2,1) forwards; }
#flip.go .inner { animation: inner 5s ease forwards; }
@keyframes wipe { 0% { transform: translateX(-105%);} 12% { transform: translateX(0);} 84% { transform: translateX(0);} 100% { transform: translateX(105%);} }
@keyframes inner { 0%,10% { opacity: 0; transform: scale(.92);} 18% { opacity: 1; transform: scale(1);} 66% { transform: scale(1.0);} 70% { transform: scale(1.06);} 74% { transform: scale(1);} 82% { opacity: 1;} 90%,100% { opacity: 0; transform: scale(1.02);} }
body.shake main { animation: shake .45s ease; }
@keyframes shake { 0%,100% { transform: none;} 25% { transform: translateY(-3px);} 50% { transform: translateY(2px);} 75% { transform: translateY(-1px);} }
@media (prefers-reduced-motion: reduce) { #flip.go .panel, #flip.go .inner { animation-duration: 2.5s; } }

.stale { background: #fff4e5; color: #8a5300; text-align: center; font-size: 13px; padding: 6px; }

/* ── 28 Oct: Ethan — "really minimalist and neat" on phones ─────────────── */
.blk h2 { flex-wrap: nowrap; white-space: nowrap; }
.blk h2 .seg { margin-left: auto; }
.sub-line { font-size: 13px; color: var(--muted); margin-top: 6px; }
.pname b .ldr2 { font-weight: 400; color: var(--muted); }
.more { display: block; margin: 14px auto 0; }
@media (max-width: 640px) {
  .blk h2 .hint, .side .lbl .parts { display: none; }
  section.blk { padding: 18px 0; }
  .face { width: 48px; height: 48px; border-width: 2px; }
  .side { gap: 8px; }
  .side .lbl b { font-size: 14px; }
  .big { font-size: 64px; }
  .race-bar { height: 34px; border-radius: 10px; margin: 12px 0 6px; }
  .need { font-size: 14px; }
  .prow { grid-template-columns: 38px 1fr auto; gap: 10px; padding: 9px 0; }
  .pics, .pics .ph { width: 38px; height: 38px; }
  .pics .lg { width: 18px; height: 18px; right: -5px; }
  .pname .ldr { display: none; }
  .pseats .n { font-size: 26px; }
  .pseats .proj { display: none; }
  .hemi-key { font-size: 12px; gap: 4px 10px; }
  .th { padding: 8px 0; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; }
  .ep-table { font-size: 13px; }
  .chips { grid-template-columns: 1fr 1fr; }
}

/* ── projected note ─────────────────────────────────────────────────── */
.proj-note { margin-top: 10px; font-size: 13px; color: var(--muted); text-align: center; }
.proj-note b { color: var(--ink); }
body.proj .pseats .proj { display: block !important; }

/* ── who will be PM ─────────────────────────────────────────────────── */
.pm { margin-top: 18px; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.pm-head { font-family: var(--display); font-weight: 700; font-size: 15px; }
.pm-head small { display: block; font-family: var(--text); font-weight: 400; font-size: 12px; color: var(--muted); }
.pm-scale { display: flex; align-items: center; gap: 10px; margin: 12px 0 8px; }
.pm-face { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; background: var(--soft); flex: none; }
.pm-track { position: relative; flex: 1; height: 10px; border-radius: 99px; background: linear-gradient(90deg, #1F5AA5, #e3e9f6 30% 70%, #3a8fd6); margin-bottom: 18px; }
.pm-track span { position: absolute; top: 16px; font-size: 11px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.pm-track span:nth-child(1) { left: 0; } .pm-track span:nth-child(2) { left: 50%; transform: translateX(-50%); } .pm-track span:nth-child(3) { right: 0; }
.pm-track i { position: absolute; top: -6px; width: 22px; height: 22px; margin-left: -11px; left: 50%; background: var(--ink); border: 3px solid #fff; border-radius: 50%; box-shadow: 0 1px 6px rgba(11,31,77,.3); transition: left 1.4s cubic-bezier(.2,.8,.2,1); }
.pm-text { font-size: 14px; }

/* ── party profile sheet ────────────────────────────────────────────── */
.prow, .hemi-key span { cursor: pointer; }
.sheet-bg { position: fixed; inset: 0; z-index: 30; background: rgba(11,31,77,.35); display: flex; align-items: flex-end; justify-content: center; animation: fadein .2s; }
.sheet { background: #fff; width: 100%; max-width: 560px; max-height: 88vh; overflow-y: auto; border-radius: 20px 20px 0 0; padding: 18px 18px 28px; animation: up .28s cubic-bezier(.2,.8,.2,1); }
@media (min-width: 700px) { .sheet-bg { align-items: center; } .sheet { border-radius: 20px; } }
@keyframes up { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.sh-top { display: flex; gap: 14px; align-items: center; }
.sh-top .ph { width: 76px; height: 76px; border-radius: 50%; object-fit: cover; flex: none; background: var(--soft); }
.sh-top h3 { margin: 0; font-family: var(--display); font-size: 22px; line-height: 1.1; }
.sh-top .who { color: var(--muted); font-size: 14px; }
.sh-top .lg { height: 30px; max-width: 90px; object-fit: contain; margin-top: 6px; }
.sh-x { margin-left: auto; align-self: flex-start; border: 0; background: var(--soft); width: 34px; height: 34px; border-radius: 50%; font-size: 18px; line-height: 1; color: var(--muted); }
.sh-blurb { margin: 14px 0 0; font-size: 15px; }
.sh-bio { margin: 8px 0 0; font-size: 13px; color: var(--muted); }
.sh-nums { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 14px; }
.sh-nums div { background: var(--soft); border-radius: 12px; padding: 8px; text-align: center; }
.sh-nums b { display: block; font-family: var(--display); font-size: 20px; }
.sh-nums span { font-size: 11px; color: var(--muted); }
.sh h4, .sheet h4 { margin: 16px 0 6px; font-family: var(--display); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); }
.sh-polls { display: flex; flex-wrap: wrap; gap: 6px; }
.sh-polls span { background: var(--soft); border-radius: 8px; padding: 4px 8px; font-size: 13px; }
.sh-town { display: flex; justify-content: space-between; font-size: 14px; padding: 5px 0; border-bottom: 1px solid var(--line); }

/* ── footer links + embed ───────────────────────────────────────────── */
.foot-links { display: flex; gap: 16px; margin-top: 12px; }
.linkbtn { border: 0; background: none; padding: 0; color: var(--blue); font-size: 13px; text-decoration: underline; }
.embed-box { margin-top: 10px; background: var(--soft); border-radius: 12px; padding: 12px; max-width: 640px; }
.embed-box p { margin: 0 0 8px; }
.embed-box textarea { width: 100%; font: 12px ui-monospace, monospace; border: 1px solid var(--line); border-radius: 8px; padding: 8px; resize: none; margin-bottom: 8px; }

/* ── TV mode (/tv) ──────────────────────────────────────────────────── */
.ticker { position: fixed; left: 0; right: 0; bottom: 0; z-index: 25; height: 54px; background: var(--blue); color: #fff; display: flex; align-items: center; overflow: hidden; }
.ticker b { flex: none; background: #fff; color: var(--blue); font-family: var(--display); font-size: 15px; letter-spacing: .15em; height: 100%; display: flex; align-items: center; padding: 0 18px; }
.ticker .tk { flex: 1; overflow: hidden; }
.tk-in { display: inline-block; white-space: nowrap; font-size: 20px; padding-left: 100%; animation: tick 120s linear infinite; }
.tk-in span { margin-right: 60px; } .tk-in i { font-style: normal; opacity: .7; margin-right: 8px; }
@keyframes tick { to { transform: translateX(-100%); } }
body.tv { font-size: clamp(16px, 1.05vw, 24px); overflow: hidden; }
body.tv main .wrap { max-width: none; display: grid; grid-template-columns: 1.05fr 1fr; gap: 0 3vw; padding: 0 3vw; height: calc(100vh - 58px - 54px - 70px); }
body.tv .progress { grid-column: 1 / -1; }
body.tv #race, body.tv #knesset { grid-column: 1; }
body.tv #race { padding-top: 6px; } body.tv #knesset { border: 0; padding-top: 4px; }
body.tv #hemi { max-width: 34vw; }
body.tv .rot { grid-column: 2; grid-row: 2 / span 2; display: none; border: 0; overflow: hidden; }
body.tv .rot.on { display: block; animation: fadein .6s; }
body.tv #builderBlk, body.tv #newsBlk, body.tv footer, body.tv .hint, body.tv #modeSeg, body.tv .follow .t { display: none !important; }
body.tv .map-box { height: calc(100vh - 300px); }
body.tv .parties { grid-template-columns: 1fr 1fr; gap: 0 24px; }
body.tv .prow { padding: 6px 0; }
body.tv .big { font-size: clamp(64px, 6.5vw, 150px); }
body.tv .face { width: clamp(60px, 5vw, 110px); height: clamp(60px, 5vw, 110px); }
body.tv .race-bar { height: clamp(40px, 4vh, 64px); }
body.tv .pm { margin-top: 12px; }
body.tv header.top .wrap { max-width: none; padding: 0 3vw; }

/* quick welcome flip (2 s) */
#flip.go.quick .panel, #flip.go.quick .inner { animation-duration: 2.06s; }
/* "As things stand, with 41% counted" — big, at the top */
.stand { font-family: var(--display); font-weight: 800; font-size: clamp(24px, 5.4vw, 40px); letter-spacing: -0.02em; line-height: 1.1; color: var(--ink); margin: 0; }
.stand .pc { color: var(--blue); }
.stand small { display: block; font-family: var(--text); font-weight: 400; font-size: 13px; letter-spacing: 0; color: var(--muted); margin-top: 4px; }

/* soldiers' votes note (28 Oct) */
.soldiers { margin-top: 10px; background: #fff7e6; border: 1px solid #f6dfae; color: #5c4300; border-radius: 12px; padding: 10px 12px; font-size: 14px; line-height: 1.4; }
.soldiers.in { background: #e9f7ef; border-color: #bfe5cf; color: #1d5a39; }

/* final result mode (28 Oct, idea 2) */
.final-banner { margin-top: 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: linear-gradient(135deg, #fff6d6, #ffe9a3); border: 1px solid #e8c45a; border-radius: 14px; padding: 12px 14px; }
.final-banner b { display: block; font-family: var(--display); font-size: 20px; letter-spacing: .06em; color: #7a5600; }
.final-banner span { font-size: 13px; color: #6b5413; }
#flip .panel.gold { background: linear-gradient(135deg, #b8860b, #e0b425); }
