:root {
  --ink: #16243b;
  --muted: #617087;
  --navy: #163f73;
  --blue: #2563eb;
  --cyan: #4cc9c0;
  --mint: #e8faf6;
  --sky: #edf5ff;
  --paper: #fffdfa;
  --line: #dce5ee;
  --warm: #f6f2eb;
  --danger: #b42318;
  --shadow: 0 24px 60px rgba(22, 63, 115, .12);
  font-family: "Arial Hebrew", "Noto Sans Hebrew", Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); line-height: 1.65; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button, .button { cursor: pointer; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.site-header {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 2rem;
  min-height: 76px; padding: .8rem clamp(1rem, 4vw, 4rem);
  background: rgba(255, 253, 250, .94); border-bottom: 1px solid rgba(220, 229, 238, .8);
  backdrop-filter: blur(14px);
}
.brand { display: inline-flex; align-items: center; gap: .72rem; color: var(--navy); }
.brand-mark { display: block; flex: 0 0 42px; width: 42px; height: 42px; border-radius: 13px; object-fit: contain; }
.brand-lockup { display: grid; line-height: 1.05; }
.brand-lockup strong { font-size: 1.32rem; font-weight: 900; letter-spacing: -.04em; }
.brand-lockup small { margin-top: .28rem; color: var(--muted); font-size: .68rem; font-weight: 700; white-space: nowrap; }
.site-header nav { margin-inline-start: auto; display: flex; align-items: center; gap: .4rem; }
.language-picker { display: inline-flex; align-items: center; gap: .4rem; margin-inline-start: auto; color: var(--muted); font-size: .76rem; font-weight: 800; }
.language-picker select { width: auto; min-height: 40px; padding: .35rem 2rem .35rem .65rem; border-radius: 999px; background-color: white; }
.site-header .language-picker + .nav-toggle + nav { margin-inline-start: 0; }
.site-header nav a { padding: .55rem .85rem; border-radius: 999px; color: var(--muted); font-weight: 700; }
.site-header nav a:hover, .site-header nav a:focus-visible { background: var(--sky); color: var(--navy); }
.nav-account-actions { display: flex; align-items: center; gap: .4rem; }
.account-link { border: 1px solid var(--line); background: white; }
.register-link { border: 1px solid var(--navy); background: var(--navy); color: white !important; }
.register-link:hover, .register-link:focus-visible { background: #0f315c !important; color: white !important; }
.notification-link { position: relative; }
.notification-link span { display: grid; place-items: center; position: absolute; top: -.25rem; left: -.25rem; min-width: 20px; height: 20px; padding: 0 .3rem; border-radius: 999px; background: var(--danger); color: white; font-size: .68rem; }
.nav-toggle { display: none; margin-inline-start: auto; border: 0; background: transparent; color: var(--navy); font-weight: 800; }
.demo-data-banner { padding: .55rem 1rem; border-bottom: 1px solid #f3d28b; background: #fff4dc; color: #734b00; text-align: center; font-size: .86rem; font-weight: 800; }

.hero {
  min-height: 520px; padding: clamp(2.5rem, 5vw, 5rem) clamp(1.25rem, 7vw, 8rem);
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(360px, .75fr); gap: clamp(3rem, 7vw, 8rem); align-items: center;
  background: radial-gradient(circle at 15% 15%, rgba(76, 201, 192, .2), transparent 28%), linear-gradient(145deg, #fffdfa 35%, #edf5ff 100%);
  overflow: hidden;
}
.hero-copy { max-width: 760px; }
.eyebrow { display: inline-block; margin-bottom: .9rem; color: #087e79; font-size: .82rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 1.25rem; font-size: clamp(2.8rem, 6.4vw, 5.7rem); line-height: 1.02; letter-spacing: -.055em; color: var(--navy); }
h1 em { color: #138d86; font-style: normal; }
.hero p { max-width: 680px; color: var(--muted); font-size: clamp(1.08rem, 1.8vw, 1.3rem); }
.actions, .vote-actions, .editor-actions, .trust-row, .tag-row, .confidence-line { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; }
.button, button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .7rem 1.25rem;
  border: 1px solid var(--navy); border-radius: 10px 10px 10px 3px; background: var(--navy); color: white; font-weight: 800;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
}
.button:hover, button:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(22, 63, 115, .16); }
.button.ghost { background: white; color: var(--navy); border-color: var(--line); }
.trust-row { margin-top: 2rem; color: var(--muted); font-size: .9rem; }
.trust-row span::first-letter { color: #0c8e67; }

.consensus-demo {
  position: relative; max-width: 470px; padding: 2rem; border: 1px solid rgba(255,255,255,.9); border-radius: 26px 26px 26px 7px;
  background: rgba(255,255,255,.84); box-shadow: var(--shadow); backdrop-filter: blur(10px);
}
.consensus-demo::before { content: ""; position: absolute; inset: -18px 30px auto -18px; height: 100px; border-radius: 22px; background: var(--cyan); opacity: .14; z-index: -1; transform: rotate(-3deg); }
.demo-head { display: flex; align-items: center; gap: .55rem; margin-bottom: 1.2rem; color: var(--muted); font-size: .85rem; font-weight: 800; }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: #13a36e; box-shadow: 0 0 0 5px rgba(19,163,110,.12); }
.category-badge { display: inline-flex; width: fit-content; padding: .35rem .65rem; border-radius: 999px; background: var(--mint); color: #087e79; font-size: .78rem; font-weight: 900; }
.consensus-demo h2 { margin: .9rem 0 1.4rem; font-size: clamp(1.6rem, 3vw, 2.25rem); line-height: 1.2; color: var(--navy); }
.support-ring { display: flex; align-items: baseline; gap: .7rem; padding-bottom: 1.2rem; border-bottom: 1px solid var(--line); }
.support-ring strong { font-size: 3rem; color: #138d86; line-height: 1; }
.support-ring span { color: var(--muted); font-weight: 700; }
.demo-result { margin: 1.3rem 0; padding: 1rem; border-right: 4px solid var(--cyan); background: var(--mint); border-radius: 8px 0 0 8px; }
.demo-result span { color: #087e79; font-size: .75rem; font-weight: 900; }
.demo-result p { margin: .25rem 0 0; color: var(--ink); font-size: 1rem; font-weight: 700; }
.consensus-demo small { color: var(--muted); }

.section { max-width: 1240px; margin: 0 auto; padding: clamp(4rem, 7vw, 7rem) clamp(1.25rem, 4vw, 3rem); }
.intro { text-align: center; }
.intro > h2, .section-heading h2 { max-width: 740px; margin: 0 auto 3rem; color: var(--navy); font-size: clamp(2rem, 4vw, 3.4rem); line-height: 1.12; letter-spacing: -.04em; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; text-align: right; }
.steps article { padding: 1.6rem; border-top: 3px solid var(--cyan); background: white; box-shadow: 0 12px 36px rgba(22, 63, 115, .07); }
.steps b { color: #13958d; font-size: .82rem; letter-spacing: .08em; }
.steps h3 { margin: .55rem 0; color: var(--navy); font-size: 1.35rem; }
.steps p { color: var(--muted); margin: 0; }

.page-hero { padding: clamp(4rem, 7vw, 7rem) max(1.25rem, calc((100vw - 1180px) / 2)); background: linear-gradient(135deg, var(--warm), var(--sky)); }
.page-hero.compact { padding-block: clamp(3rem, 5vw, 5rem); }
.page-hero h1 { max-width: 900px; margin: .5rem 0 1rem; font-size: clamp(2.5rem, 5vw, 4.8rem); }
.page-hero p { max-width: 760px; margin: 0; color: var(--muted); font-size: 1.15rem; }
.catalog-summary { display: grid; grid-template-columns: repeat(3, 1fr); margin: -6rem 0 2rem; border: 1px solid var(--line); border-radius: 20px 20px 20px 6px; background: white; box-shadow: var(--shadow); overflow: hidden; position: relative; }
.catalog-summary div { display: grid; gap: .2rem; padding: 1.4rem 1.7rem; border-left: 1px solid var(--line); }
.catalog-summary div:last-child { border-left: 0; }
.catalog-summary strong { color: var(--navy); font-size: clamp(1.8rem, 3vw, 2.7rem); line-height: 1; }
.catalog-summary span { color: var(--muted); font-size: .86rem; font-weight: 800; }
.category-directory { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .75rem; margin-bottom: 2rem; }
.category-tile { display: flex; align-items: center; justify-content: flex-start; gap: .8rem; width: 100%; min-height: 82px; padding: .9rem 1rem; border: 1px solid var(--line); border-radius: 14px 14px 14px 4px; background: white; color: var(--ink); text-align: start; box-shadow: none; }
.category-tile:hover, .category-tile:focus-visible, .category-tile.selected { transform: none; border-color: #31aaa2; background: var(--mint); box-shadow: 0 0 0 3px rgba(76,201,192,.14); }
.category-tile .category-icon { display: grid; place-items: center; flex: 0 0 40px; width: 40px; height: 40px; border-radius: 12px; background: var(--sky); color: var(--navy); font-size: 1.15rem; font-weight: 900; }
.category-tile .category-copy { flex: 1 1 auto; min-width: 0; }
.category-tile strong, .category-tile small { display: block; }
.category-tile strong { color: var(--navy); font-size: .9rem; line-height: 1.25; }
.category-tile small { margin-top: .3rem; color: var(--muted); font-size: .72rem; }
.filter-bar { display: flex; align-items: center; gap: .8rem; margin-bottom: 2rem; padding: .75rem; border: 1px solid var(--line); background: white; box-shadow: 0 10px 30px rgba(22,63,115,.06); }
.filter-bar label { display: flex; align-items: center; flex: 1; }
.sort-control { display: flex; }
.sort-control > span { color: var(--muted); font-size: .8rem; font-weight: 800; }
.sort-help { margin: -1.25rem 0 1.5rem; color: var(--muted); font-size: .9rem; }
.results-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin: 2.3rem 0 1rem; scroll-margin-top: 100px; }
.results-heading h2 { margin: 0; color: var(--navy); font-size: 1.8rem; }
.results-heading span { color: var(--muted); font-weight: 800; }
input, textarea, select {
  width: 100%; min-height: 48px; padding: .7rem .85rem; border: 1px solid var(--line); border-radius: 8px; background: white; color: var(--ink);
}
textarea { min-height: 120px; resize: vertical; }
input:focus, textarea:focus, select:focus { outline: 3px solid rgba(76,201,192,.2); border-color: #31aaa2; }
.topic-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 1.2rem; }
.topic-card { display: flex; flex-direction: column; min-height: 340px; padding: 1.45rem; border: 1px solid var(--line); border-radius: 18px 18px 18px 5px; background: white; box-shadow: 0 12px 34px rgba(22,63,115,.07); transition: transform .18s ease, box-shadow .18s ease; }
.topic-card:hover { transform: translateY(-4px); box-shadow: 0 18px 44px rgba(22,63,115,.12); }
.card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; color: var(--muted); font-size: .78rem; }
.confidence { display: inline-flex; padding: .3rem .6rem; border-radius: 999px; background: var(--sky); color: var(--navy); font-size: .75rem; font-weight: 800; }
.confidence.high { background: #e9f9ee; color: #11733d; }
.confidence.low { background: #fff4dc; color: #8a5b00; }
.topic-card-copy { display: flex; flex: 1; flex-direction: column; }
.topic-card h2 { margin: 1.1rem 0 .7rem; color: var(--navy); font-size: 1.55rem; line-height: 1.25; }
.topic-card p { color: var(--muted); }
.topic-card .ranking-context { margin: auto 0 0; padding-top: .75rem; color: var(--blue); font-size: .9rem; font-weight: 800; }
.topic-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; align-items: start; padding: 1rem 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .8rem; }
.topic-stats > span { display: grid; grid-template-rows: 1.7rem auto; align-items: start; text-align: center; }
.topic-stats strong { display: block; color: var(--navy); font-size: 1.1rem; }
.text-link { color: #087e79; font-weight: 900; }

.topic-layout { display: grid; grid-template-columns: minmax(300px,.7fr) minmax(0,1.3fr); gap: 2rem; align-items: start; }
.result-card { position: sticky; top: 100px; padding: 1.6rem; border: 1px solid #bdebe4; background: var(--mint); border-radius: 20px 20px 20px 6px; }
.result-card h2 { color: var(--navy); font-size: 2rem; }
.result-summary { font-size: 1.12rem; font-weight: 700; }
.result-card h3 { margin: 1.6rem 0 .6rem; color: var(--navy); font-size: 1rem; }
.result-card ul { padding-right: 1.2rem; }
.result-card li { margin-bottom: .5rem; }
.consensus-metrics { display: grid; gap: .55rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.consensus-metrics span { color: var(--muted); font-size: .86rem; }
.consensus-metrics strong { color: var(--navy); font-size: 1rem; }
.results-locked { border-style: dashed; }
.results-locked h2 { margin-bottom: .65rem; }
.results-locked p { color: var(--muted); }
.questions .section-heading { text-align: right; }
.questions .section-heading h2 { margin: 0 0 1.2rem; font-size: 2.2rem; }
.question-card { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 1rem; margin-bottom: 1rem; padding: 1.4rem; border: 1px solid var(--line); background: white; }
#principle-question { scroll-margin-top: 96px; }
.question-number { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--navy); color: white; font-weight: 900; }
.dimension { color: #087e79; font-size: .74rem; font-weight: 900; }
.question-card h3 { margin: .3rem 0 1rem; font-size: 1.25rem; color: var(--navy); }
.vote-actions button { min-height: 40px; min-width: 72px; }
.vote-button {
  background: white;
  color: var(--navy);
  border-color: var(--line);
  box-shadow: none;
}
.vote-button:hover:not(:disabled), .vote-button:focus-visible:not(:disabled) {
  background: var(--sky);
  border-color: #9fb7d3;
}
.vote-button.selected {
  background: var(--navy);
  color: white;
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(22, 63, 115, .13);
}
.vote-button.no.selected {
  background: #8a3141;
  border-color: #8a3141;
}
.vote-button.undecided { color: var(--muted); border-style: dashed; }
.vote-button.undecided.selected {
  background: #596678;
  color: white;
  border-color: #596678;
  border-style: solid;
}
.vote-actions span { color: var(--muted); font-size: .82rem; }
.vote-bar { height: 7px; margin-top: 1rem; border-radius: 999px; background: #edf0f4; overflow: hidden; }
.vote-bar i { display: block; height: 100%; background: var(--cyan); }
.vote-results { display: block; margin-top: .45rem; color: var(--muted); }
.ballot-confirmation {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: .8rem 1.2rem;
  align-items: center;
  margin-top: 1.4rem;
  padding: 1.4rem;
  border: 1px solid #bdebe4;
  border-radius: 16px 16px 16px 5px;
  background: var(--mint);
}
.ballot-confirmation strong { color: var(--navy); font-size: 1.12rem; }
.ballot-confirmation p { margin: .25rem 0 0; color: var(--muted); }
.ballot-confirmation button:disabled {
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
  opacity: .48;
}
.ballot-confirmation #ballotMessage { grid-column: 1 / -1; }
.ballot-confirmation .notice { margin: 0; }
.notice.success { background: #e9f9ee; border-color: #11733d; color: #11733d; }
.translation-fallback { max-width: 760px; margin: 0 0 1rem; padding: .65rem .85rem; border: 1px solid #e4ad54; border-radius: 10px; background: #fff7e6; color: #704700; font-weight: 700; }

.question-geography { margin-top: 1.4rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
.question-geography-toggle { width: 100%; justify-content: space-between; border-color: var(--line); background: var(--sky); color: var(--navy); box-shadow: none; }
.question-geography-toggle::after { content: '⌄'; font-size: 1.1rem; transition: transform .16s ease; }
.question-geography-toggle[aria-expanded="true"]::after { transform: rotate(180deg); }
.question-geography-toggle:hover, .question-geography-toggle:focus-visible { background: var(--mint); box-shadow: 0 0 0 3px rgba(76,201,192,.14); }
.question-geography-panel { container-type: inline-size; margin-top: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: 14px; background: #fff; overflow: hidden; }
.question-geography-heading { margin-bottom: .75rem; }
.question-geography-heading h4 { margin: .25rem 0; color: var(--navy); font-size: 1rem; }
.question-geography-heading p { margin: 0; color: var(--muted); font-size: .84rem; }
.question-geography .geography-toolbar { margin-top: .75rem; }
.question-geography .geography-layout { grid-template-columns: minmax(180px,.48fr) minmax(410px,1.52fr); }
.question-geography .geography-map { width: min(100%, 210px); max-height: 390px; }
.question-geography .geography-region-list { grid-template-columns: repeat(2, minmax(0,1fr)); }
.question-geography .geography-region-card { padding: .75rem .85rem; }
.question-geography .geography-region-card dl { gap: .3rem; margin: .55rem 0; }

.geography-section { margin-top: 3rem; padding-top: 2.5rem; border-top: 1px solid var(--line); }
.geography-section .section-heading p { max-width: 720px; color: var(--muted); }
.geography-toolbar { display: flex; justify-content: space-between; align-items: end; gap: 1rem; margin: 1.25rem 0 .65rem; }
.geography-toolbar label { display: grid; gap: .35rem; min-width: 220px; color: var(--navy); font-size: .82rem; font-weight: 800; }
.view-switch { display: inline-flex; padding: .25rem; border: 1px solid var(--line); border-radius: 12px; background: var(--warm); }
.view-switch button { min-height: 40px; padding: .4rem .9rem; border: 0; border-radius: 8px; background: transparent; color: var(--muted); box-shadow: none; }
.view-switch button.active { background: white; color: var(--navy); box-shadow: 0 3px 10px rgba(22,63,115,.1); }
.geography-filter-note { margin-bottom: 1rem; color: var(--muted); font-size: .88rem; font-weight: 700; }
.geography-layout { display: grid; grid-template-columns: minmax(220px,.7fr) minmax(300px,1.3fr); gap: 1.2rem; align-items: start; }
.geography-map-panel { padding: 1.2rem; border: 1px solid var(--line); border-radius: 18px; background: linear-gradient(180deg, #f8fbff, #fff); text-align: center; }
.geography-map { display: block; width: min(100%, 260px); max-height: 500px; margin: 0 auto; overflow: visible; filter: drop-shadow(0 10px 18px rgba(22,63,115,.12)); }
.map-region { stroke: white; stroke-width: 4; cursor: pointer; transition: filter .16s ease, opacity .16s ease, transform .16s ease; transform-origin: center; }
.map-region:hover, .map-region:focus-visible, .map-region.active { filter: brightness(.93); outline: none; stroke: var(--navy); transform: scale(1.012); }
.map-region.result-yes { fill: #3fb8aa; }
.map-region.result-no { fill: #b65c6a; }
.map-region.result-undecided { fill: #8794a5; }
.map-region.result-balanced { fill: #e4ad54; }
.map-region.result-insufficient { fill: #dfe5eb; }
.map-disclaimer { margin: .7rem 0 0; color: var(--muted); font-size: .75rem; line-height: 1.45; }
.geography-region-list { display: grid; gap: .75rem; }
.geography-region-card { padding: 1rem 1.1rem; border: 1px solid var(--line); border-radius: 14px; background: white; transition: border-color .16s ease, box-shadow .16s ease; }
.geography-region-card.active { border-color: #31aaa2; box-shadow: 0 0 0 3px rgba(76,201,192,.14); }
.geography-region-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: .5rem; min-width: 0; }
.geography-region-card h3 { margin: 0; color: var(--navy); }
.geography-region-card dl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .45rem; margin: .8rem 0; }
.geography-region-card dl div { min-width: 0; padding: .55rem .35rem; border-radius: 8px; background: var(--sky); text-align: center; }
.geography-region-card dt { min-height: 2.1em; color: var(--muted); font-size: .72rem; line-height: 1.05; }
.geography-region-card dd { margin: .2rem 0 0; color: var(--navy); font-size: 1.05rem; font-weight: 900; }
.geography-region-card p { margin: 0; color: var(--muted); font-size: .78rem; }
.geography-region-card.insufficient { background: var(--warm); }
.region-leading { flex: 0 0 auto; max-width: 8.5rem; padding: .25rem .55rem; border-radius: 999px; background: var(--sky); color: var(--navy); font-size: .72rem; font-weight: 900; line-height: 1.25; text-align: center; }
.region-leading.yes { background: var(--mint); color: #087e79; }
.region-leading.no { background: #fff0ee; color: #8a3141; }
.region-leading.balanced { background: #fff7e6; color: #8a5b00; }
.geography-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; }
.geography-table-wrap table { width: 100%; border-collapse: collapse; background: white; }
.geography-table-wrap caption { padding: 1rem; color: var(--navy); font-weight: 900; text-align: right; }
.geography-table-wrap th, .geography-table-wrap td { padding: .8rem; border-top: 1px solid var(--line); text-align: right; white-space: nowrap; }
.geography-table-wrap thead th { background: var(--sky); color: var(--navy); }
.geography-collecting { padding: 1.4rem; border: 1px dashed #9fb7d3; border-radius: 14px; background: var(--sky); }
.geography-collecting h3 { margin-bottom: .4rem; color: var(--navy); }
.geography-collecting p { margin: 0; color: var(--muted); }
.inline-retry { min-height: 36px; margin-inline-start: .5rem; padding: .3rem .65rem; }

@container (max-width: 820px) {
  .question-geography .geography-layout { grid-template-columns: 1fr; }
  .question-geography .geography-map-panel { order: 0; }
  .question-geography .geography-region-list { grid-template-columns: repeat(2, minmax(0, 1fr)); order: 1; }
  .question-geography .geography-map { max-height: 320px; }
}

@container (max-width: 520px) {
  .question-geography-panel { padding: .75rem; }
  .question-geography .geography-region-list { grid-template-columns: 1fr; }
  .question-geography .geography-map { max-height: 280px; }
  .geography-filter-note { line-height: 1.5; }
}

.auth-shell { min-height: calc(100vh - 160px); display: grid; place-items: center; padding: 3rem 1.25rem; background: linear-gradient(135deg, var(--warm), var(--sky)); }
.auth-card, .editor-form { width: min(100%, 620px); padding: 2rem; border: 1px solid var(--line); border-radius: 22px 22px 22px 6px; background: white; box-shadow: var(--shadow); }
.profile-stack { display: grid; gap: 1.25rem; width: min(100%, 620px); }
.profile-stack .auth-card { width: 100%; }
.auth-card > p { color: var(--muted); }
.auth-card h1 { font-size: 2.7rem; }
.auth-card label, .editor-form label, .inline-editor label { display: grid; gap: .4rem; margin-bottom: 1rem; color: var(--navy); font-weight: 800; }
.field-help, .field-feedback { min-height: 1.25rem; color: var(--muted); font-size: .86rem; font-weight: 600; }
.field-help.error, .field-feedback.error { color: var(--danger); }
.field-feedback.success { color: #11733d; }
.auth-card button, .editor-form > button { width: 100%; margin-top: .5rem; }
.form-section { padding-top: 2rem; }
.editor-form { margin: 0 auto; width: min(100%, 800px); }
.form-note { margin: 1rem 0; padding: 1rem; background: var(--sky); color: var(--navy); font-size: .9rem; }
.notice { margin-top: 1rem; padding: .8rem; background: var(--sky); border-right: 4px solid var(--blue); }
.notice.error { background: #fff0ee; border-color: var(--danger); color: var(--danger); }
.success-screen { min-height: 70vh; display: grid; place-content: center; justify-items: center; text-align: center; padding: 2rem; }
.success-screen > span { display: grid; place-items: center; width: 70px; height: 70px; border-radius: 50%; background: var(--mint); color: #087e79; font-size: 2rem; }
.success-screen h1 { margin: 1rem 0; font-size: 3rem; }

.queue { display: grid; gap: 1.2rem; }
.queue-card { padding: 1.5rem; border: 1px solid var(--line); background: white; box-shadow: 0 12px 34px rgba(22,63,115,.07); }
.queue-card h2 { margin: .8rem 0 .4rem; color: var(--navy); }
.status { padding: .25rem .55rem; border-radius: 999px; background: var(--sky); color: var(--navy); font-weight: 800; }
.status.approved { background: #e9f9ee; color: #11733d; }
.status.in_review, .status.clarification_received, .status.ready_to_publish { background: #e9f9ee; color: #11733d; }
.status.clarification_requested { background: #fff7e6; color: #8a5b00; }
.status.duplicate, .status.rejected { background: #fff0ee; color: var(--danger); }
.ownership { margin-inline-start: auto; padding: .25rem .55rem; border-radius: 999px; background: var(--warm); color: var(--muted); font-weight: 800; }
.ownership.mine { background: var(--mint); color: #087e79; }
.duplicate-indicator { margin: 1rem 0; padding: .7rem; background: #e9f9ee; color: #11733d; }
.duplicate-indicator.warn { background: #fff7e6; color: #8a5b00; }
.duplicate-indicator.block { background: #fff0ee; color: var(--danger); }
.inline-editor { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: .8rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.inline-editor label { margin: 0; font-size: .84rem; }
.inline-editor .wide, .editor-actions { grid-column: 1 / -1; }
.inline-editor .check { display: flex; align-items: center; grid-column: span 2; }
.inline-editor .check input { width: 20px; min-height: 20px; }
.inline-editor.read-only { opacity: .72; }
.translation-review-form { margin-block: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: 16px; background: var(--cream); }
.translation-review-locale { display: grid; gap: .75rem; margin-block: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: 12px; }
.translation-review-locale label { display: grid; gap: .4rem; font-weight: 800; }
.translation-review-locale textarea { min-height: 7rem; }
.workflow-actions { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 1rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.workflow-actions form { padding: 1rem; border: 1px solid var(--line); border-radius: 12px; background: var(--warm); }
.workflow-actions label, .response-form label { display: grid; gap: .35rem; margin-bottom: .7rem; color: var(--navy); font-size: .84rem; font-weight: 800; }
.activity-log { margin-top: 1rem; padding: .8rem 1rem; border: 1px solid var(--line); background: white; }
.activity-log summary { cursor: pointer; color: var(--navy); font-weight: 900; }
.activity-log p { margin: .7rem 0 0; color: var(--muted); font-size: .82rem; }
.published-wording, .message-thread { margin: 1rem 0; padding: 1rem; border-right: 4px solid var(--cyan); background: var(--mint); }
.published-wording h3 { margin: .35rem 0; color: var(--navy); }
.message-thread p { margin: .4rem 0; }
.response-form { margin-top: 1rem; padding: 1rem; border: 1px solid var(--line); background: var(--sky); }
.notification-card.unread { border-right: 5px solid var(--cyan); background: #f7fffd; }
.publish { background: #0b806f; border-color: #0b806f; }
.danger-button { background: white; border-color: #efc4bf; color: var(--danger); }
.empty-state { grid-column: 1 / -1; padding: 3rem; text-align: center; background: var(--warm); }
.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin-top: 2rem; }
.pagination button { min-width: 42px; min-height: 42px; padding: .5rem; border-color: var(--line); background: white; color: var(--navy); box-shadow: none; }
.pagination button.active { background: var(--navy); color: white; border-color: var(--navy); }
.detailed { grid-template-columns: repeat(2, 1fr); }
.detailed article { min-height: 210px; }

.identity-verification, .demographics {
  display: grid; gap: .85rem; margin: .35rem 0 .25rem; padding: 1.1rem;
  border: 1px solid #b9d9d5; border-radius: 15px 15px 15px 5px; background: #f2fbfa;
}
.identity-verification legend, .demographics legend { padding: 0 .45rem; color: var(--navy); font-weight: 900; }
.identity-verification p, .identity-verification small, .demographics p, .demographics small { margin: 0; color: var(--muted); line-height: 1.55; }
.identity-verification small, .demographics small { font-size: .78rem; }
.verification-options { display: grid; gap: .65rem; margin-block: 1rem; }
.verification-options label { display: flex; align-items: center; gap: .65rem; margin: 0; padding: .75rem; border: 1px solid var(--line); border-radius: 10px; background: white; }
.verification-options input { width: 20px; min-height: 20px; margin: 0; }
.identity-verification input[type="file"] { padding: .65rem; background: white; }
.demographics { border-color: #d9d2ef; background: #f8f6fd; }
.privacy-notice { display: grid; gap: .6rem; padding: 1rem; border: 1px solid var(--line); border-radius: 15px 15px 15px 5px; background: var(--warm); }
.privacy-notice h2, .privacy-notice p { margin: 0; }
.privacy-notice h2 { color: var(--navy); font-size: 1rem; }
.privacy-notice p { color: var(--muted); font-size: .86rem; line-height: 1.55; }
.legal-consent { display: grid !important; grid-template-columns: 22px 1fr; gap: .65rem; align-items: start; margin: .25rem 0 0 !important; color: var(--ink) !important; font-weight: 750 !important; }
.legal-consent input { width: 20px; min-height: 20px; margin-top: .12rem; }
.legal-shell { max-width: 960px; margin: 0 auto; padding: 3rem 1.25rem 5rem; }
.legal-document { padding: clamp(1.25rem, 4vw, 3.5rem); border: 1px solid var(--line); border-radius: 22px 22px 22px 7px; background: white; box-shadow: var(--shadow); }
.legal-document h1 { color: var(--navy); font-size: clamp(2rem, 5vw, 3.2rem); margin: 0 0 1.5rem; }
.legal-document h2 { color: var(--navy); font-size: 1.45rem; margin: 2.4rem 0 .7rem; }
.legal-document h3 { color: var(--navy); font-size: 1.1rem; margin: 1.5rem 0 .5rem; }
.legal-document p, .legal-document li { line-height: 1.8; }
.legal-document blockquote { margin: 1.5rem 0; padding: 1rem 1.25rem; border-right: 4px solid var(--teal); background: #f2fbfa; color: var(--muted); }
.legal-document a { color: var(--blue); font-weight: 750; }
.legal-document code { direction: ltr; unicode-bidi: embed; background: var(--sky); padding: .12rem .35rem; border-radius: 5px; }
.legal-checkbox { padding: 1rem; background: #f8f6fd; border-radius: 12px; }
.legal-table { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--warm); }
.legal-table pre { margin: 0; padding: 1rem; direction: rtl; font: inherit; line-height: 1.7; white-space: pre; }
.auth-card button:disabled { opacity: .65; cursor: wait; }
.social-auth { display: grid; justify-items: center; gap: .75rem; margin: 1rem 0; }
.social-auth > * { width: min(100%, 360px); }
.apple-sign-in { min-height: 44px; border-radius: 6px; border: 1px solid #000; background: #000; color: #fff; font: 700 1rem/1.2 system-ui, sans-serif; }
.apple-sign-in:hover { background: #222; }
.auth-divider { display: flex; align-items: center; gap: .75rem; margin: 1.25rem 0; color: var(--muted); font-weight: 700; font-size: .9rem; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }

.admin-section { max-width: 1380px; }
.admin-summary {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  margin-top: -5.5rem; margin-bottom: 2rem; border: 1px solid var(--line);
  border-radius: 20px 20px 20px 6px; background: var(--line);
  box-shadow: var(--shadow); overflow: hidden; position: relative;
}
.admin-summary div { display: grid; gap: .25rem; padding: 1.35rem 1.5rem; background: white; }
.admin-summary strong { color: var(--navy); font-size: 2.2rem; line-height: 1; }
.admin-summary span { color: var(--muted); font-size: .82rem; font-weight: 800; }
.admin-filters label:first-child { flex: 2; }
.users-list { display: grid; gap: 1rem; }
.user-card {
  display: grid; grid-template-columns: minmax(260px, .8fr) minmax(520px, 1.4fr);
  gap: 1.5rem; align-items: center; padding: 1.25rem;
  border: 1px solid var(--line); border-radius: 16px 16px 16px 5px;
  background: white; box-shadow: 0 10px 30px rgba(22,63,115,.06);
}
.user-identity { display: flex; gap: 1rem; align-items: center; min-width: 0; }
.user-avatar {
  display: grid; place-items: center; flex: 0 0 48px; width: 48px; height: 48px;
  border-radius: 14px; background: var(--sky); color: var(--navy); font-weight: 900;
}
.user-identity h2 { margin: 0; color: var(--navy); font-size: 1.15rem; }
.user-identity a { color: var(--muted); overflow-wrap: anywhere; }
.user-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; margin-top: .45rem; color: var(--muted); font-size: .76rem; }
.status.disabled { background: #fff0ee; color: var(--danger); }
.self-badge { padding: .2rem .5rem; border-radius: 999px; background: var(--mint); color: #087e79; font-weight: 900; }
.user-permissions { display: grid; grid-template-columns: repeat(3, minmax(120px, 1fr)) auto; gap: .75rem; align-items: end; }
.user-permissions label { display: grid; gap: .3rem; color: var(--navy); font-size: .78rem; font-weight: 800; }
.user-permissions select { min-height: 44px; }
.user-permissions button { min-height: 44px; white-space: nowrap; }
.user-permissions select:disabled { background: var(--warm); color: var(--muted); cursor: not-allowed; }

footer { display: flex; justify-content: space-between; gap: 1rem; padding: 2rem clamp(1rem, 4vw, 4rem); border-top: 1px solid var(--line); color: var(--muted); }
footer strong { color: var(--navy); }

.audit-section { padding-top: 2rem; }
.audit-filters { align-items: end; margin-bottom: 1.5rem; }
.audit-filters label { display: grid; gap: .35rem; color: var(--muted); font-size: .9rem; }
.audit-critical-toggle { display: flex !important; align-items: center; min-height: 44px; }
.audit-critical-toggle input { width: auto; }
.audit-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.audit-table { width: 100%; border-collapse: collapse; min-width: 780px; }
.audit-table th, .audit-table td { padding: .9rem 1rem; text-align: right; border-bottom: 1px solid var(--line); }
.audit-table th { color: var(--muted); font-size: .85rem; background: var(--cream); }
.audit-table tbody tr { cursor: pointer; }
.audit-table tbody tr:hover, .audit-table tbody tr:focus { background: #f5f8fc; outline: 2px solid transparent; }
.severity, .audit-result { display: inline-flex; padding: .25rem .55rem; border-radius: 999px; font-size: .82rem; font-weight: 700; }
.severity.info { background: #e8f1fb; color: #184b7d; }
.severity.change { background: #e9f6ef; color: #17643c; }
.severity.sensitive { background: #fff2d8; color: #7a4b00; }
.severity.critical { background: #fde8e7; color: #982b25; }
.audit-result.success { color: #17643c; background: #e9f6ef; }
.audit-result.blocked, .audit-result.failure { color: #982b25; background: #fde8e7; }
.audit-dialog { width: min(720px, calc(100% - 2rem)); max-height: 85dvh; overflow: auto; border: 0; border-radius: 22px; padding: 1.5rem; color: var(--ink); }
.audit-dialog::backdrop { background: rgba(9, 27, 48, .55); }
.dialog-close { float: left; min-width: 40px; min-height: 40px; padding: .25rem; }
.audit-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
.audit-detail-grid div { padding: .75rem; border-radius: 12px; background: var(--cream); }
.audit-detail-grid dt, .audit-change small { color: var(--muted); font-size: .8rem; }
.audit-detail-grid dd { margin: .2rem 0 0; overflow-wrap: anywhere; }
.audit-change-list { display: grid; gap: .65rem; }
.audit-change { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: .75rem; padding: .75rem; border: 1px solid var(--line); border-radius: 12px; }
.audit-change span { display: grid; gap: .15rem; overflow-wrap: anywhere; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .consensus-demo { width: 100%; max-width: 620px; }
  .topic-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .category-directory { grid-template-columns: repeat(3, minmax(0,1fr)); }
  .topic-layout { grid-template-columns: 1fr; }
  .result-card { position: static; }
  .inline-editor { grid-template-columns: 1fr 1fr; }
  .workflow-actions { grid-template-columns: 1fr; }
  .admin-summary { grid-template-columns: repeat(2, 1fr); }
  .user-card { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .site-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    min-height: 64px;
    padding: .65rem 1rem;
    gap: .5rem;
  }
  .brand { min-width: 0; justify-self: start; }
  .language-picker { margin: 0; justify-self: center; }
  .language-picker > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
  .language-picker select { min-height: 42px; max-width: 104px; padding-inline: .55rem 1.6rem; }
  .brand-mark { width: 38px; height: 38px; flex-basis: 38px; }
  .brand-lockup small { display: none; }
  .nav-toggle { display: block; justify-self: end; margin: 0; white-space: nowrap; }
  .site-header nav {
    display: none;
    position: fixed;
    inset-block-start: 64px;
    inset-block-end: 0;
    inset-inline: 0;
    height: calc(100dvh - 64px);
    overflow-y: auto;
    overscroll-behavior: contain;
    flex-direction: column;
    align-items: stretch;
    gap: .35rem;
    margin: 0;
    padding: .75rem 1rem 1rem;
    border-bottom: 1px solid var(--line);
    background: var(--paper);
    box-shadow: var(--shadow);
  }
  .site-header nav.open { display: flex; }
  .site-header nav a { min-height: 48px; display: flex; align-items: center; padding: .7rem 1rem; border-radius: 10px; }
  .nav-account-actions {
    position: sticky;
    bottom: 0;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .65rem;
    margin-block-start: auto;
    padding-block-start: .85rem;
    border-top: 1px solid var(--line);
    background: var(--paper);
  }
  .nav-account-actions a { justify-content: center; text-align: center; }
  body.nav-open { overflow: hidden; }
  .hero { min-height: auto; padding: 3.25rem 1rem 4rem; grid-template-columns: minmax(0,1fr); gap: 2.5rem; }
  .hero h1 { font-size: clamp(2.55rem, 13vw, 4rem); }
  .hero p { font-size: 1.05rem; }
  .consensus-demo { padding: 1.35rem; border-radius: 20px 20px 20px 6px; }
  .section { padding: 3.5rem 1rem; }
  .page-hero, .page-hero.compact { padding: 3rem 1rem; }
  .page-hero h1 { font-size: clamp(2.25rem, 11vw, 3.4rem); line-height: 1.08; }
  .page-hero p { font-size: 1rem; }
  .steps, .topic-grid, .detailed { grid-template-columns: 1fr; }
  .steps { gap: .9rem; }
  .catalog-summary { grid-template-columns: 1fr; margin-top: -4.5rem; }
  .catalog-summary div { border-left: 0; border-bottom: 1px solid var(--line); }
  .catalog-summary div:last-child { border-bottom: 0; }
  .category-directory { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .filter-bar { flex-direction: column; }
  .results-heading { align-items: start; flex-direction: column; }
  .topic-card { min-height: auto; padding: 1.2rem; }
  .topic-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .65rem; }
  .topic-stats span { min-width: 0; overflow-wrap: anywhere; }
  .inline-editor { grid-template-columns: 1fr; }
  .inline-editor .check, .inline-editor .wide, .editor-actions { grid-column: 1; }
  .ownership { margin-inline-start: 0; }
  .topic-layout { gap: 1.25rem; padding-top: 2rem; }
  .result-card { padding: 1.25rem; }
  .questions .section-heading h2 { font-size: 1.9rem; }
  .question-card { grid-template-columns: 1fr; padding: 1.15rem; }
  .question-number { width: 34px; height: 34px; }
  #principle-question { scroll-margin-top: 76px; }
  .vote-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .vote-actions button { width: 100%; min-width: 0; }
  .vote-actions .undecided { grid-column: 1 / -1; }
  .vote-actions .choice-status { grid-column: 1 / -1; }
  .ballot-confirmation { grid-template-columns: 1fr; }
  .ballot-confirmation button { width: 100%; }
  .geography-toolbar { align-items: stretch; flex-direction: column; }
  .geography-toolbar label, .view-switch { width: 100%; }
  .view-switch button { flex: 1; }
  .geography-layout { grid-template-columns: 1fr; }
  .geography-map-panel { order: 0; }
  .geography-region-list { order: 1; }
  .question-geography .geography-layout { grid-template-columns: 1fr; }
  .question-geography .geography-region-list { grid-template-columns: 1fr; }
  .geography-region-card dl { grid-template-columns: repeat(3, minmax(0,1fr)); }
  .auth-shell { min-height: calc(100dvh - 64px); padding: 2rem 1rem; align-items: start; }
  .auth-card, .editor-form { padding: 1.25rem; border-radius: 18px 18px 18px 5px; }
  .auth-card h1 { font-size: clamp(2.1rem, 11vw, 2.7rem); }
  .legal-shell { padding: 2rem 1rem 3rem; }
  .legal-document { padding: 1.15rem; }
  .legal-table { max-width: 100%; }
  .legal-table pre { font-size: .82rem; }
  .admin-summary { grid-template-columns: 1fr 1fr; }
  .user-permissions { grid-template-columns: 1fr; }
  .user-permissions button { width: 100%; }
  .user-identity { align-items: flex-start; }
  .audit-detail-grid, .audit-change { grid-template-columns: 1fr; }
  footer { flex-direction: column; padding: 1.5rem 1rem; }
  footer nav { display: flex; flex-wrap: wrap; gap: .4rem 1rem; }
  footer nav a { min-height: 44px; display: inline-flex; align-items: center; }
}

@media (max-width: 440px) {
  .brand-lockup strong { font-size: 1.18rem; }
  .nav-toggle { min-height: 44px; padding-inline: .85rem; }
  .actions { display: grid; grid-template-columns: 1fr; }
  .actions .button, .actions button { width: 100%; }
  .trust-row { display: grid; gap: .45rem; }
  .category-directory { grid-template-columns: 1fr; }
  .category-tile { min-height: 72px; }
  .category-tile .category-icon { align-self: center; }
  .catalog-summary { margin-top: -3.5rem; }
  .topic-stats { grid-template-columns: 1fr 1fr; }
  .topic-stats span:last-child { grid-column: 1 / -1; }
  .question-geography-panel { margin-inline: -.35rem; }
  .geography-region-card { padding: .85rem; }
  .geography-region-card dt { min-height: auto; white-space: nowrap; }
  .card-meta, .tag-row, .confidence-line { align-items: flex-start; }
  .support-ring strong { font-size: 2.5rem; }
  .admin-summary { grid-template-columns: 1fr; margin-top: -3.5rem; }
  .user-card { padding: 1rem; }
  .user-avatar { flex-basis: 42px; width: 42px; height: 42px; }
  .editor-actions { display: grid; grid-template-columns: 1fr; }
  .editor-actions button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

/* Task-focused, bidirectional layouts: keep reading order identical to DOM order. */
[hidden] { display: none !important; }
#app:focus { outline: none; }
.skip-link { position: fixed; inset-block-start: -100px; inset-inline-start: 1rem; z-index: 1000; padding: .75rem 1rem; background: white; color: var(--navy); }
.skip-link:focus { inset-block-start: .5rem; outline: 3px solid var(--navy); }
#nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: .35em; }
button:disabled { cursor: wait; opacity: .65; transform: none; box-shadow: none; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid #087e79; outline-offset: 3px; }
.route-loading { max-width: 1100px; padding: 3rem 1.25rem; margin: auto; min-height: 45vh; }
.skeleton { height: 100px; border-radius: 12px; background: #edf1f7; margin-block: 1rem; }
.page-hero { padding-block: 2.5rem; }
.page-hero h1 { font-size: clamp(2rem, 4vw, 3.3rem); line-height: 1.2; letter-spacing: normal; }
.page-hero + .section { padding-top: 2rem; }
.category-disclosure { margin-block: 1rem 2rem; border: 1px solid var(--line); border-radius: 12px; padding: .8rem; background: white; }
.category-disclosure > summary { cursor: pointer; font-weight: 700; min-height: 44px; padding: .5rem; }
.category-directory { margin-block: 1rem; }
.category-tile { display: grid; grid-template-columns: 44px minmax(0, 1fr); align-items: center; justify-content: stretch; text-align: start; gap: .75rem; width: 100%; }
.category-icon { width: 44px; height: 44px; display: grid; place-items: center; margin: 0; font-size: 1.4rem; line-height: 1; }
.category-copy { min-width: 0; text-align: start; }
.category-copy strong { overflow-wrap: anywhere; }
.catalog-summary { gap: .75rem; }
.synthetic-label, .sample-notice { display: block; background: #fff4dc; color: #684500; padding: .65rem .8rem; border-radius: 8px; font-size: .9rem; }
.sample-notice a { display: block; text-decoration: underline; }
.category-badge { align-items: center; gap: .4rem; }
.category-badge svg { width: 18px; height: 18px; flex-shrink: 0; }
.method-limits { margin-block-start: 2rem; padding: 1.5rem; background: white; border: 1px solid var(--line); border-radius: 12px; }
.method-limits li { margin-block: .8rem; line-height: 1.7; }
.ballot-meter { position: sticky; top: 88px; z-index: 5; padding: .8rem 1rem; border: 1px solid var(--line); background: #fff; border-radius: 8px; font-weight: 700; }
.results-locked { position: static; padding: 1rem; }
.vote-button.selected, .vote-button.no.selected, .vote-button.undecided.selected { background: var(--navy); color: white; border-color: var(--navy); }
.vote-actions { align-items: stretch; }
.vote-button { min-height: 48px; }
.question-card { scroll-margin-top: 160px; }
.registration-actions { display: flex; gap: .75rem; }
.registration-actions > button { flex: 1; }
button.ghost { background: white; color: var(--navy); }
.registration-steps { font-weight: 700; color: var(--navy); padding-block: .6rem; border-bottom: 1px solid var(--line); }
.password-toggle { min-height: 44px; padding: .25rem .5rem; background: transparent; color: var(--navy); border: 0; font-size: .85rem; justify-self: end; }
input[dir="ltr"] { text-align: left; }
.steps, .topic-card, .auth-card, .legal-document { text-align: start; }
.legal-table { overflow: auto; }
.legal-table table { border-collapse: collapse; width: 100%; }
.legal-table th, .legal-table td { padding: .7rem; border: 1px solid var(--line); text-align: start; vertical-align: top; }
.legal-table th { background: var(--sky); }
.field-feedback.error, .field-help.error { color: #a52030; }
@media (max-width: 680px) {
  .hero { min-height: 0; padding-block: 2rem; gap: 2rem; }
  .hero h1 { font-size: 2.4rem; line-height: 1.18; }
  .page-hero { padding: 1.5rem 1rem; }
  .section { padding: 2rem 1rem; }
  .catalog-summary { display: flex; justify-content: space-around; margin: 0; padding: .8rem .4rem; }
  .catalog-summary > div { padding: .2rem; min-width: 0; flex: 1; }
  .catalog-summary strong { font-size: 1.4rem; }
  .catalog-summary span { font-size: .8rem; }
  .category-directory { grid-template-columns: 1fr; }
  .category-tile { min-height: 82px; padding: .75rem; }
  .filter-bar { gap: .65rem; }
  .topic-stats { gap: .5rem; font-size: .85rem; }
  .topic-layout { display: flex; flex-direction: column; }
  .topic-layout > * { width: 100%; min-width: 0; }
  .topic-layout .result-card:not(.results-locked) { order: 2; position: static; }
  .ballot-meter { top: 84px; }
  .auth-shell { padding: 1.5rem .75rem; }
  .auth-card { padding: 1.25rem; }
  .vote-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .vote-button, .vote-button.undecided { grid-column: auto; padding: .65rem .3rem; width: 100%; }
  .choice-status { grid-column: 1 / -1; }
  .geography-region-list { grid-template-columns: 1fr; }
  .geography-region-card dt { white-space: normal; }
  .confidence-line { gap: .5rem; }
  .confidence { white-space: normal; }
}
