/* Layout: one poster-like column. The poll card is the only object with a hard ink border and offset shadow;
   the picket sign is the brand mark. Hate = sign red, Love = orange, Don't care = grey. */
:root {
  --paper: #F3F3F1;
  --surface: #FFFFFF;
  --ink: #141414;
  --muted: #5C5C57;
  --line: #DADAD4;
  --love: #F7931E;
  --on-love: #141414;
  --love-soft: #FFE7CC;
  --hate: #D62828;
  --on-hate: #FFFFFF;
  --hate-soft: #FBE2E2;
  --meh: #9E9E97;
  --meh-soft: #E6E6E1;
  --focus: #1F6FEB;
  --brand: #D62828;
  --font-logo: "Anton", Impact, "Arial Narrow", sans-serif;
  --font-display: "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;
  --font-body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #111111; --surface: #1B1B1A; --ink: #F2F2EE; --muted: #A8A8A1; --line: #2F2F2C;
    --love: #FFA43D; --on-love: #141414; --love-soft: #3D2811;
    --hate: #FF5A52; --on-hate: #141414; --hate-soft: #3B1515;
    --meh: #7C7C76; --meh-soft: #282826; --focus: #79A8FF; --brand: #FF5A52;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #111111; --surface: #1B1B1A; --ink: #F2F2EE; --muted: #A8A8A1; --line: #2F2F2C;
  --love: #FFA43D; --on-love: #141414; --love-soft: #3D2811;
  --hate: #FF5A52; --on-hate: #141414; --hate-soft: #3B1515;
  --meh: #7C7C76; --meh-soft: #282826; --focus: #79A8FF; --brand: #FF5A52;
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
}
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.muted { color: var(--muted); font-weight: 500; }

.app {
  max-width: 720px;
  margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: 20px 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Header */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-icon { width: 52px; height: 52px; flex: none; }
.brand-text { display: flex; flex-direction: column; gap: 3px; }
.brand .word { font-family: var(--font-logo); font-size: 32px; color: var(--brand); text-transform: uppercase; letter-spacing: 0.02em; line-height: 1; }
.brand .tagline { font-size: 13px; font-weight: 600; color: var(--muted); line-height: 1.1; }
.crowd { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.crowd-label { text-transform: uppercase; letter-spacing: 0.08em; font-weight: 600; font-size: 11px; }
.seg { display: inline-flex; border: 1.5px solid var(--ink); border-radius: 999px; overflow: hidden; }
.seg button {
  font: 600 13px var(--font-body); padding: 5px 12px; border: 0; background: transparent; color: var(--ink); cursor: pointer;
}
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.chip { display: inline-flex; gap: 6px; align-items: baseline; border: 1.5px solid var(--line); border-radius: 999px; padding: 4px 12px; background: var(--surface); color: var(--ink); font-weight: 600; }

.tabs { display: flex; gap: 2px; border-bottom: 2px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tabs a {
  text-decoration: none; font-weight: 600; padding: 8px 14px; color: var(--muted); white-space: nowrap;
  border-bottom: 3px solid transparent; margin-bottom: -2px;
}
.tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--brand); }

/* Public-votes notice */
.notice {
  position: relative; display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  padding: 16px 20px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 6px;
}
.notice p { margin: 0; max-width: 60ch; }
.notice .sign { width: 120px; height: 160px; flex: none; }
.notice-body { flex: 1 1 260px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }

/* Poll card */
.card {
  background: var(--surface);
  border: 2.5px solid var(--ink);
  box-shadow: 6px 6px 0 var(--ink);
  border-radius: 6px;
  padding: 20px;
  display: flex; flex-direction: column; gap: 16px;
  scroll-margin-top: 16px;
}
.card-meta { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.cat { text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700; font-size: 12px; color: var(--ink); }
.count { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.poll-title {
  font-family: var(--font-display); font-weight: 900; text-transform: uppercase;
  font-size: clamp(48px, 13vw, 104px); line-height: 0.9; letter-spacing: 0.005em;
  margin: 0; text-wrap: balance; overflow-wrap: anywhere;
}
.wiki { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 15px; width: fit-content; }
.w { font-family: Georgia, "Times New Roman", serif; font-weight: 700; border: 1.5px solid currentColor; border-radius: 3px; padding: 0 4px; font-size: 13px; line-height: 1.3; }
.by { font-size: 13px; color: var(--muted); }

.choices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.vote {
  font-family: var(--font-display); font-weight: 900; text-transform: uppercase; font-size: 26px; line-height: 1;
  padding: 18px 8px; border-radius: 6px; cursor: pointer; border: 2.5px solid var(--ink);
  transition: transform 0.08s ease;
}
.vote:active { transform: translateY(2px); }
.vote.love { background: var(--love); color: var(--on-love); }
.vote.meh { background: var(--surface); color: var(--ink); }
.vote.hate { background: var(--hate); color: var(--on-hate); }
.vote.hate:hover { background: color-mix(in srgb, var(--hate) 88%, var(--on-hate)); }
.vote small { display: block; font-family: var(--font-mono); font-size: 11px; font-weight: 500; margin-top: 6px; opacity: 0.75; text-transform: none; }
.card-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.linkbtn { background: none; border: 0; padding: 0; font: 600 14px var(--font-body); color: var(--muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.linkbtn:hover { color: var(--ink); }
.linkbtn.strong { color: var(--ink); text-decoration: none; font-size: 16px; font-weight: 700; text-align: left; }
.linkbtn.strong:hover { text-decoration: underline; }
.keys { font-family: var(--font-mono); font-size: 12px; color: var(--muted); }

/* Results */
.verdict { display: flex; flex-direction: column; gap: 6px; }
.verdict-line { font-size: 22px; font-weight: 700; line-height: 1.25; margin: 0; text-wrap: balance; }
.verdict-line b { font-family: var(--font-mono); font-weight: 600; }
.badge-pill {
  display: inline-block; width: fit-content; font: 700 12px var(--font-body); text-transform: uppercase; letter-spacing: 0.1em;
  padding: 4px 10px; border-radius: 999px; border: 1.5px solid var(--ink);
}
.badge-pill.hot { background: var(--hate); color: var(--on-hate); }
.badge-pill.main { background: var(--meh-soft); color: var(--ink); }
.badge-pill.split { background: var(--love-soft); color: var(--ink); }
.badge-pill.first { background: var(--ink); color: var(--paper); }
.bars { display: flex; flex-direction: column; gap: 10px; }
.row { display: grid; grid-template-columns: 116px 1fr 52px; gap: 10px; align-items: center; }
.row .lbl { font-weight: 600; font-size: 15px; display: flex; gap: 6px; align-items: center; }
.row .you { font: 700 10px var(--font-body); letter-spacing: 0.1em; text-transform: uppercase; background: var(--ink); color: var(--paper); padding: 2px 6px; border-radius: 3px; }
.track { height: 28px; background: var(--meh-soft); border-radius: 4px; overflow: hidden; }
.fill { display: block; height: 100%; width: var(--w); border-radius: 4px; }
.row.love .fill { background: var(--love); }
.row.meh .fill { background: var(--meh); }
.row.hate .fill { background: var(--hate); }
.row.mine .track { box-shadow: inset 0 0 0 2px var(--ink); }
.pct { font-family: var(--font-mono); font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.fresh .fill { animation: grow 0.7s cubic-bezier(.2,.8,.2,1); }
@keyframes grow { from { width: 0; } }
.source { font-size: 13px; color: var(--muted); }
#copy-fallback input { font-size: 14px; }

/* Takes */
.takes { border-top: 1.5px solid var(--line); padding-top: 16px; display: flex; flex-direction: column; gap: 12px; }
.take-form { display: flex; flex-direction: column; gap: 6px; }
.take-form label { margin-top: 0; }
.take-row { display: flex; gap: 8px; }
.take-row input { flex: 1; min-width: 0; }
.take-meta { display: flex; justify-content: space-between; gap: 12px; font: 500 12px var(--font-mono); color: var(--muted); }
.takes-title { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); display: flex; gap: 8px; }
.takes-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.take { padding: 12px; border: 1.5px solid var(--line); border-radius: 6px; background: var(--surface); display: flex; flex-direction: column; gap: 6px; }
.take p { margin: 0; overflow-wrap: anywhere; }
.take-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.take-actions { display: flex; gap: 14px; }
.quote { margin: 0; padding: 8px 12px; border-left: 4px solid var(--meh); background: var(--paper); border-radius: 0 4px 4px 0; font-size: 14px; color: var(--muted); overflow-wrap: anywhere; }
.quote strong { color: var(--ink); }
.quoting { display: flex; flex-direction: column; gap: 6px; }

/* People */
.person { display: inline-flex; align-items: center; gap: 10px; background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-align: left; min-width: 0; }
span.person { cursor: default; }
button.person:hover strong { text-decoration: underline; }
.av { width: 28px; height: 28px; border-radius: 50%; background: var(--meh-soft); flex: none; object-fit: cover; display: inline-block; }
.av.mid { width: 40px; height: 40px; }
.av.big { width: 64px; height: 64px; border: 2px solid var(--ink); }
.people { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.person-row { display: flex; align-items: center; gap: 12px; padding: 12px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 6px; flex-wrap: wrap; }
.person-row .person { flex: 1 1 220px; }
.person-row .l { display: flex; flex-direction: column; min-width: 0; }
.person-row .l small { color: var(--muted); font-size: 13px; }
.btn.small { padding: 6px 12px; font-size: 13px; }
.btn[aria-pressed="true"] { background: var(--surface); color: var(--ink); }
.prof-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.prof-name { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.prof-name .page-title { overflow-wrap: anywhere; }
.compat { display: flex; align-items: center; gap: 16px; padding: 16px 20px; background: var(--love-soft); border-radius: 6px; border: 1.5px solid var(--love); flex-wrap: wrap; }
.compat .score { font-size: 64px; }
.back { align-self: flex-start; }

.btn {
  font: 700 15px var(--font-body); padding: 11px 18px; border-radius: 6px; cursor: pointer;
  border: 2px solid var(--ink); background: var(--surface); color: var(--ink); text-decoration: none; display: inline-block;
}
.btn.primary { background: var(--ink); color: var(--paper); }
.btn:disabled { opacity: 0.55; cursor: progress; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

/* Poll list and filters */
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-top: 12px; }
.section-head h2, h2.sh { font-family: var(--font-display); font-weight: 900; text-transform: uppercase; font-size: 30px; line-height: 1; margin: 0; }
.section-head span { font-family: var(--font-mono); font-size: 13px; color: var(--muted); }
.filters { display: flex; flex-wrap: wrap; gap: 6px; }
.filters button {
  font: 600 14px var(--font-body); padding: 5px 12px; border-radius: 999px; border: 1.5px solid var(--line);
  background: var(--surface); color: var(--ink); cursor: pointer;
}
.filters button:hover { border-color: var(--ink); }
.filters button[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.poll-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; }
.poll-list button {
  width: 100%; text-align: left; display: flex; justify-content: space-between; align-items: center; gap: 8px;
  padding: 10px 12px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 6px; cursor: pointer;
  font: 600 15px var(--font-body); color: var(--ink);
}
.poll-list button:hover { border-color: var(--ink); }
.poll-list button[aria-current="true"] { border-color: var(--ink); box-shadow: inset 4px 0 0 var(--brand); }
.poll-list .t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tag { flex: none; font: 700 11px var(--font-body); text-transform: uppercase; letter-spacing: 0.06em; padding: 3px 7px; border-radius: 3px; }
.tag.love { background: var(--love); color: var(--on-love); }
.tag.hate { background: var(--hate); color: var(--on-hate); }
.tag.meh { background: var(--meh-soft); color: var(--ink); }
.tag.skip, .tag.none { color: var(--muted); border: 1px dashed var(--line); }

/* Profile */
.page-title { font-family: var(--font-display); font-weight: 900; text-transform: uppercase; font-size: clamp(40px, 10vw, 64px); line-height: 0.95; margin: 0; }
.lede { color: var(--muted); max-width: 60ch; margin: 0; }
.meter { display: flex; flex-direction: column; gap: 10px; padding: 20px; background: var(--surface); border-radius: 6px; border: 1.5px solid var(--line); }
.meter-top { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.score { font-family: var(--font-display); font-weight: 900; font-size: 88px; line-height: 0.85; font-variant-numeric: tabular-nums; }
.tier { font-size: 20px; font-weight: 700; }
.gauge { position: relative; height: 14px; border-radius: 7px; background: linear-gradient(90deg, var(--meh-soft), var(--meh) 40%, var(--love) 75%, var(--hate)); }
.gauge .needle { position: absolute; top: -6px; width: 6px; height: 26px; margin-left: -3px; background: var(--ink); border-radius: 3px; left: var(--x); }
.gauge-labels { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 600; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.stat { padding: 12px; border-radius: 6px; background: var(--surface); border: 1.5px solid var(--line); display: flex; flex-direction: column; gap: 2px; }
.stat b { font-family: var(--font-mono); font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.1; }
.stat span { font-size: 12px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips .c { padding: 5px 10px; border-radius: 999px; font-weight: 600; font-size: 14px; }
.chips .c.hate { background: var(--hate-soft); border: 1.5px solid var(--hate); }
.chips .c.love { background: var(--love-soft); border: 1.5px solid var(--love); }
.chips .c.meh { background: var(--meh-soft); border: 1.5px solid var(--meh); }
.block { display: flex; flex-direction: column; gap: 10px; }
.block h3 { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); }
.list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 12px; background: var(--surface); border: 1.5px solid var(--line); border-radius: 6px; }
.list .l { min-width: 0; display: flex; flex-direction: column; }
.list .l strong { overflow-wrap: anywhere; }
.list .l small { color: var(--muted); font-size: 13px; }
.match { font-family: var(--font-mono); font-weight: 600; font-size: 20px; font-variant-numeric: tabular-nums; flex: none; }
.empty { padding: 16px; border: 1.5px dashed var(--line); border-radius: 6px; color: var(--muted); }
.empty p { margin: 0 0 10px; }
.empty p:last-child { margin: 0; }

/* Create */
.create { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
form { display: flex; flex-direction: column; gap: 6px; }
label { font-weight: 700; font-size: 14px; margin-top: 10px; }
input, select {
  font: 500 16px var(--font-body); padding: 11px 12px; border-radius: 6px; border: 1.5px solid var(--line);
  background: var(--surface); color: var(--ink); width: 100%;
}
select {
  -webkit-appearance: none; appearance: none; padding-right: 40px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%;
  background-size: 6px 6px; background-repeat: no-repeat;
}
input:focus, select:focus { border-color: var(--ink); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 35%, transparent); }
textarea {
  font: 500 16px var(--font-body); padding: 11px 12px; border-radius: 6px; border: 1.5px solid var(--line);
  background: var(--surface); color: var(--ink); width: 100%; resize: vertical;
}
textarea:focus { border-color: var(--ink); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 35%, transparent); }

/* Profiles */
.av-init { display: inline-grid; place-items: center; color: #FFFFFF; font: 700 11px var(--font-body); letter-spacing: 0.02em; }
.av-init.mid { font-size: 15px; }
.av-init.big { font-size: 24px; }
.handle { color: var(--muted); font-weight: 600; font-size: 14px; }
.here { display: flex; flex-wrap: wrap; gap: 6px; }
.here span { font: 600 12px var(--font-body); padding: 3px 9px; border-radius: 999px; background: var(--meh-soft); color: var(--ink); }
.bio { margin: 0; max-width: 60ch; overflow-wrap: anywhere; }
.prof-meta { display: flex; flex-direction: column; gap: 10px; }
.pf-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.pf-preview { display: flex; gap: 14px; align-items: center; padding: 14px; border: 1.5px dashed var(--line); border-radius: 6px; margin-bottom: 4px; }
.pf-pname { font-weight: 700; font-size: 18px; overflow-wrap: anywhere; }
.handle-row { display: flex; align-items: center; border: 1.5px solid var(--line); border-radius: 6px; background: var(--surface); }
.handle-row > span { padding-left: 12px; color: var(--muted); font-weight: 700; }
.handle-row input { border: 0; padding-left: 4px; background: transparent; }
.handle-row input:focus { box-shadow: none; }
.handle-row:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 35%, transparent); }
fieldset { border: 0; padding: 0; margin: 12px 0 0; min-width: 0; }
legend { font-weight: 700; font-size: 14px; padding: 0; margin-bottom: 8px; }
.opt-row { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { position: relative; margin: 0; font-weight: 600; }
.opt input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; padding: 0; opacity: 0; cursor: pointer; }
.opt span { display: inline-block; padding: 7px 14px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface); font-size: 14px; }
.opt input:checked + span { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.opt input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.opt.swatch span { width: 36px; height: 36px; padding: 0; border: 3px solid var(--surface); box-shadow: 0 0 0 1.5px var(--line); }
.opt.swatch input:checked + span { box-shadow: 0 0 0 3px var(--ink); }
.check { display: flex; gap: 10px; align-items: center; margin-top: 16px; font-weight: 600; font-size: 15px; }
.check input { width: 20px; height: 20px; padding: 0; margin: 0; accent-color: var(--brand); }
.hint { font-size: 13px; color: var(--muted); margin: 0; }
.side-card { padding: 16px; border-radius: 6px; border: 1.5px solid var(--line); background: var(--surface); display: flex; flex-direction: column; gap: 8px; }
.side-card h2 { margin: 0; font-size: 16px; }
.side-card p { margin: 0; color: var(--muted); font-size: 14px; }
.danger-btn { border-color: var(--brand); color: var(--brand); }
.danger-btn.solid { background: var(--brand); color: #FFFFFF; }
.prompt { display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 16px 20px; border-radius: 6px; background: var(--surface); border: 2px solid var(--ink); }
.prompt p { margin: 0; max-width: 52ch; }
.people-tools { display: flex; flex-direction: column; gap: 10px; }
.err { color: var(--brand); font-weight: 600; margin: 6px 0 0; min-height: 1.5em; }
.lookup { margin-top: 12px; padding: 14px; border-radius: 6px; border: 1.5px solid var(--line); background: var(--surface); display: flex; flex-direction: column; gap: 8px; }
.lookup[data-state="found"] { border-color: var(--ink); }
.eyebrow { font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); font-weight: 700; }
.lookup .article { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-weight: 700; font-size: 18px; }
.lookup .article a { font-size: 14px; font-weight: 600; }
.lookup p { margin: 0; font-size: 14px; color: var(--muted); }
.alts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 14px; color: var(--muted); }
.alts button { font: 600 14px var(--font-body); padding: 4px 10px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; }
.alts button:hover { border-color: var(--ink); }
.mini-preview { margin-top: 12px; padding: 14px; border: 1.5px dashed var(--line); border-radius: 6px; }
.mini-preview .poll-title { font-size: clamp(32px, 8vw, 48px); }
.rules { padding: 16px; background: var(--hate-soft); border-radius: 6px; border: 1.5px solid var(--hate); }
.rules h2 { margin: 0 0 8px; font-family: var(--font-display); font-weight: 900; text-transform: uppercase; font-size: 24px; }
.rules ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 15px; }

.foot { font-size: 13px; color: var(--muted); border-top: 1.5px solid var(--line); padding-top: 14px; }

#toast {
  position: fixed; left: 50%; transform: translateX(-50%) translateY(20px);
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 6px; font-weight: 600;
  opacity: 0; pointer-events: none; transition: opacity 0.2s, transform 0.2s; max-width: calc(100% - 32px);
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (max-width: 560px) {
  .pf-layout { grid-template-columns: 1fr; }
  .brand .word { font-size: 24px; }
  .brand-icon { width: 44px; height: 44px; }
  .notice .sign { width: 90px; height: 120px; }
  .tabs a { padding: 8px 10px; }
  .vote { font-size: 20px; padding: 16px 4px; }
  .row { grid-template-columns: 92px 1fr 44px; gap: 8px; }
  .row .lbl { font-size: 13px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .create { grid-template-columns: 1fr; }
  .keys { display: none; }
  .compat .score { font-size: 52px; }
}
@media (prefers-reduced-motion: reduce) {
  .fresh .fill { animation: none; }
  .vote, #toast { transition: none; }
}

/* ---- Public site additions ---- */
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; }
.demo-bar { background: var(--ink); color: var(--paper); font-size: 13px; font-weight: 600; text-align: center;
  padding-block: 8px; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.account { display: flex; align-items: center; gap: 8px; }
.account a.person { text-decoration: none; }
.chips button.c { font: 600 14px var(--font-body); color: var(--ink); cursor: pointer; }
.chips button.c:hover { text-decoration: underline; }
.signin { max-width: 420px; display: flex; flex-direction: column; gap: 12px; }
.sso { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 48px;
  font: 600 16px var(--font-body); padding: 12px 16px; border-radius: 6px; cursor: pointer; border: 1.5px solid var(--line); }
.sso svg { width: 20px; height: 20px; flex: none; }
.sso.apple { background: #000000; color: #FFFFFF; border-color: #000000; }
.sso.google { background: #FFFFFF; color: #1F1F1F; border-color: #747775; }
.sso.facebook { background: #1877F2; color: #FFFFFF; border-color: #1877F2; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.wiki-results { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.wiki-results label { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; margin: 0; border: 1.5px solid var(--line);
  border-radius: 6px; background: var(--paper); cursor: pointer; font-weight: 500; font-size: 15px; }
.wiki-results label:has(input:checked) { border-color: var(--ink); background: var(--surface); }
.wiki-results input { width: auto; margin: 3px 0 0; padding: 0; accent-color: var(--brand); }
.wiki-results strong { display: block; }
.wiki-results small { display: block; color: var(--muted); font-size: 13px; }
.wiki-results a { font-size: 13px; font-weight: 600; }
.foot a { color: inherit; }
