/* Stolen Bike Registry — modern, self-contained stylesheet (no build step). */
:root {
  --bg: #f7f8fa;
  --surface: #ffffff;
  --ink: #14181f;
  --muted: #677084;
  --line: #e4e7ec;
  --brand: #1d4ed8;
  --brand-ink: #ffffff;
  --danger: #dc2626;
  --ok: #16a34a;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .06), 0 8px 24px rgba(16, 24, 40, .06);
  --maxw: 1120px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.5;
}
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255,255,255,.9);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; }
.brand { display: flex; align-items: center; gap: 9px; font-size: 1.1rem; color: var(--ink); white-space: nowrap; }
.brand:hover { text-decoration: none; }
.brand-mark { font-size: 1.35rem; }
.brand-text strong { color: var(--brand); }

.site-nav { display: flex; align-items: center; gap: 2px; }
.site-nav a { color: var(--muted); font-weight: 500; font-size: .95rem; padding: 8px 12px; border-radius: 8px; white-space: nowrap; }
.site-nav a:hover { color: var(--ink); background: #f0f2f5; text-decoration: none; }
.site-nav a.nav-cta { color: var(--brand-ink); margin-left: 6px; }
.site-nav a.nav-cta:hover { background: #1742b8; color: #fff; }

/* Hamburger (hidden on desktop) */
.nav-toggle { display: none; flex-direction: column; justify-content: center; gap: 5px; width: 42px; height: 38px; padding: 0 9px; background: none; border: 1px solid var(--line); border-radius: 9px; cursor: pointer; }
.nav-toggle-bar { display: block; height: 2px; width: 100%; background: var(--ink); border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
.nav-toggle.is-open .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle.is-open .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .site-nav {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--surface); border-bottom: 1px solid var(--line);
    padding: 10px 16px 16px; box-shadow: var(--shadow);
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 12px; font-size: 1rem; }
  .site-nav a.nav-cta { margin: 8px 0 0; text-align: center; }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 16px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--surface);
  color: var(--ink); font: inherit; font-weight: 600; cursor: pointer;
}
.btn:hover { text-decoration: none; border-color: #cfd4dc; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { background: #1742b8; }
.btn.disabled { opacity: .45; pointer-events: none; }

/* Hero + search */
.hero { padding: 40px 0 24px; }
.hero h1 { margin: 0 0 18px; font-size: clamp(1.6rem, 3vw, 2.3rem); letter-spacing: -.02em; }
.search { display: flex; gap: 10px; flex-wrap: wrap; }
.search input[type=search], .search select {
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px;
  font: inherit; background: var(--surface); color: var(--ink);
}
.search input[type=search] { flex: 1 1 320px; }
.search select { flex: 0 0 auto; }

/* Map */
.map { height: 380px; width: 100%; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: #e9eef3; }
.map-detail { height: 260px; border: 1px solid var(--line); border-radius: var(--radius); }

/* Results */
.results { padding: 26px 20px 60px; }
.result-count { color: var(--muted); margin: 0 0 16px; font-size: .95rem; }
.card-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  transition: transform .12s ease, box-shadow .12s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(16,24,40,.12); }
.card-link { color: inherit; display: block; }
.card-link:hover { text-decoration: none; }
.card-media { position: relative; aspect-ratio: 4 / 3; background: #eef1f5; }
.card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-media-placeholder { display: grid; place-items: center; height: 100%; font-size: 2.4rem; opacity: .35; }
.card-body { padding: 14px 16px 16px; }
.card-title { margin: 0 0 6px; font-size: 1.02rem; letter-spacing: -.01em; }
.card-meta { margin: 0 0 4px; color: var(--muted); font-size: .88rem; display: flex; gap: 8px; flex-wrap: wrap; }
.card-meta span:not(:last-child)::after { content: "·"; margin-left: 8px; color: var(--line); }
.card-loc { margin: 0; font-size: .9rem; }

/* Badge */
.badge {
  position: absolute; top: 10px; left: 10px;
  padding: 4px 10px; border-radius: 999px; font-size: .72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .04em; color: #fff; background: var(--muted);
}
.badge-recovered { background: var(--ok); }

/* Pager */
.pager { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 34px; }
.pager-pos { color: var(--muted); font-size: .9rem; }
.empty { color: var(--muted); padding: 40px 0; text-align: center; }

/* Report detail */
.report { padding: 28px 20px 64px; }
.crumbs { margin-bottom: 14px; font-size: .9rem; }
.report-head { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.report-head h1 { margin: 0; font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -.02em; }
.report-head .badge { position: static; }
.report-grid { display: grid; grid-template-columns: 1.7fr 1fr; gap: 32px; align-items: start; }
.report-photo { margin: 0 0 22px; }
.report-photo img { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); }
.report-section { margin: 0 0 26px; }
.report-section h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0 0 10px; }
.prose { margin: 0; white-space: pre-wrap; }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; margin: 0; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.report-side .contact { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 18px; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 28px 0; margin-top: 20px; color: var(--muted); font-size: .9rem; }
.site-footer p { margin: 2px 0; }

/* Forms (submit / moderation) */
.form-page { padding: 28px 20px 64px; max-width: 760px; }
.form-page h1 { font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -.02em; margin: 6px 0 6px; }
.form-intro { margin: 0 0 22px; }
.req { color: var(--danger); }
.report-form fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 18px 6px; margin: 0 0 20px; background: var(--surface); }
.report-form legend { padding: 0 8px; font-weight: 700; font-size: .9rem; }
.field { margin-bottom: 16px; display: flex; flex-direction: column; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; }
.field label { font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.field input, .field select, .field textarea {
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px;
  font: inherit; background: var(--surface); color: var(--ink); width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--brand); outline-offset: 1px; border-color: var(--brand);
}
.field-error { color: var(--danger); font-size: .85rem; margin-top: 5px; }
.report-form input:invalid:not(:placeholder-shown) { border-color: var(--danger); }
.small { font-size: .85rem; }
.form-actions { display: flex; gap: 12px; align-items: center; margin-top: 8px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.locpicker { height: 300px; border: 1px solid var(--line); border-radius: 10px; margin: 8px 0 6px; background: #e9eef3; }
.locpicker-tools { display: flex; align-items: center; gap: 12px; margin-bottom: 4px; }
.alert { padding: 12px 16px; border-radius: 10px; margin-bottom: 20px; }
.alert-error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.alert-ok { background: #ecfdf3; color: #166534; border: 1px solid #bbf7d0; }

/* Owner self-service (correction / recovery via emailed magic link) */
.container.narrow { max-width: 640px; }
.update-page { padding-top: 32px; padding-bottom: 48px; }
.update-page h1 { margin-top: 0; }
.owner-update { margin-top: 28px; padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface, #f8fafc); }
.owner-update h2 { margin-top: 0; }
.update-page label.radio, .report-form label.radio { display: flex; align-items: center; gap: 8px; font-weight: 400; margin: 6px 0; }
.update-page label.radio input, .report-form label.radio input { width: auto; }

/* Settings: per-field label + help editor */
.set-field { padding: 12px 0; border-top: 1px solid var(--line); }
.set-field + .set-field { margin-top: 0; }
.set-field-name { font-weight: 600; margin-bottom: 6px; }
.set-sub { font-size: .78rem; color: var(--muted); margin-bottom: 2px; }

/* Form field helper text + tooltips */
.field-hint { display: block; margin-top: 4px; color: var(--muted); font-size: .82rem; }
.tip { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; border-radius: 50%; background: #e2e8f0; color: var(--muted); font-size: .66rem; font-weight: 700; font-style: italic; cursor: help; vertical-align: middle; }
.tip:hover, .tip:focus { background: var(--brand); color: #fff; outline: none; }

/* Moderation */
.mod-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.mod-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; margin: 18px 0; }
.mod-card { display: flex; flex-direction: column; gap: 4px; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); color: inherit; }
a.mod-card:hover { text-decoration: none; border-color: var(--brand); }
.mod-card-num { font-size: 2rem; font-weight: 700; letter-spacing: -.02em; }
.mod-card-label { color: var(--muted); font-size: .9rem; }

/* Stats caveats / annotations */
.note { border-radius: var(--radius); padding: 12px 14px; font-size: .9rem; }
.note-caveat { background: #f1f5f9; border: 1px solid var(--line); color: var(--ink); margin: 14px 0; }
.note-inline { margin: 8px 0 4px; }

/* Seasonality month bars */
.months { display: flex; align-items: flex-end; gap: 6px; height: 140px; margin: 12px 0 4px; }
.month-col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 4px; }
.month-bar { width: 100%; max-width: 34px; background: var(--brand); border-radius: 5px 5px 0 0; min-height: 2px; }
.month-lbl { font-size: .72rem; color: var(--muted); }

/* Lock-effectiveness matrix */
.lm-table { border-collapse: collapse; width: 100%; font-size: .9rem; }
.lm-table th, .lm-table td { border: 1px solid var(--line); padding: 8px 10px; text-align: center; }
.lm-table thead th { background: #f7f8fa; font-size: .8rem; font-weight: 600; vertical-align: bottom; }
.lm-rowhead { text-align: left !important; white-space: nowrap; font-weight: 600; background: #f7f8fa; }
.lm-cell { font-weight: 600; }
.lm-n, .lm-raw { color: var(--muted); }
.lm-panel { display: none; }
#lm-pct:checked ~ .lm-panel-pct, #lm-raw:checked ~ .lm-panel-raw { display: block; }
#lm-pct:checked ~ .lp-tabs .lm-tab-pct, #lm-raw:checked ~ .lp-tabs .lm-tab-raw { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }

/* Recovery comparison */
.rec-compare { display: flex; flex-direction: column; gap: 6px; margin: 12px 0; }
.rec-row { display: grid; grid-template-columns: 150px 1fr; align-items: center; gap: 12px; }
.rec-lbl { font-size: .9rem; font-weight: 600; text-align: right; }
.rec-bars { display: flex; align-items: center; gap: 8px; }
.rec-bar { display: inline-block; color: #fff; font-size: .78rem; font-weight: 700; padding: 2px 8px; border-radius: 5px; min-width: 30px; text-align: right; }
.rec-bar-a { background: var(--ok); }
.rec-bar-b { background: var(--muted); }
.rec-vs { color: var(--muted); font-size: .8rem; }

/* Time-of-day heatmap */
.heat-wrap { overflow-x: auto; margin: 12px 0 4px; }
.heat { border-collapse: collapse; }
.heat-day { text-align: right; padding-right: 8px; font-size: .78rem; color: var(--muted); font-weight: 600; }
.heat-cell { width: 15px; height: 15px; border: 1px solid #fff; border-radius: 2px; }
.heat-hr { font-size: .7rem; color: var(--muted); text-align: left; padding-top: 4px; }

/* Locked-to pie chart */
.pie-wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 26px; margin: 14px 0 6px; }
.pie { width: 200px; height: 200px; border-radius: 50%; flex-shrink: 0; box-shadow: var(--shadow); }
.pie-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; min-width: 240px; }
.pie-legend li { display: flex; align-items: center; gap: 8px; font-size: .92rem; }
.pie-key { width: 14px; height: 14px; border-radius: 3px; flex-shrink: 0; }
.pie-cat { flex: 1; }

/* Landmark proximity (CSS-only locked/unlocked tabs) */
.lp-radio { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.lp-tabs { display: inline-flex; gap: 4px; padding: 4px; background: #eef1f5; border-radius: 999px; margin: 6px 0 4px; }
.lp-tab { cursor: pointer; padding: 7px 18px; border-radius: 999px; font-weight: 600; font-size: .92rem; color: var(--muted); }
#lp-locked:checked ~ .lp-tabs .lp-tab-locked,
#lp-unlocked:checked ~ .lp-tabs .lp-tab-unlocked,
#lp-cbdin:checked ~ .lp-tabs .lp-tab-cbdin,
#lp-cbdout:checked ~ .lp-tabs .lp-tab-cbdout { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.lp-panel { display: none; }
#lp-locked:checked ~ .lp-panel-locked,
#lp-unlocked:checked ~ .lp-panel-unlocked,
#lp-cbdin:checked ~ .lp-panel-cbdin,
#lp-cbdout:checked ~ .lp-panel-cbdout { display: block; }
.lp-radio:focus-visible ~ .lp-tabs { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 999px; }
.prox-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin: 14px 0; }
.prox-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; text-align: center; }
.prox-icon { font-size: 1.8rem; }
.prox-big { font-size: 2.6rem; font-weight: 700; letter-spacing: -.02em; color: var(--brand); line-height: 1.1; }
.prox-label { font-weight: 600; margin-top: 2px; }
.prox-sub { color: var(--muted); font-size: .85rem; margin-top: 6px; }

/* Compare reports */
.cmp-form { display: flex; gap: 10px; align-items: flex-start; margin: 16px 0 20px; }
.cmp-form textarea { flex: 1; font: inherit; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; resize: vertical; }
.cmp-warn { color: #92400e; background: #fef3c7; border: 1px solid #fde68a; padding: 8px 12px; border-radius: 8px; }
.cmp-wrap { overflow-x: auto; }
.cmp-table { border-collapse: collapse; width: 100%; font-size: .92rem; }
.cmp-table th, .cmp-table td { border: 1px solid var(--line); padding: 9px 12px; text-align: left; vertical-align: top; }
.cmp-rowhead { background: #f7f8fa; font-weight: 600; white-space: nowrap; width: 130px; }
.cmp-col { background: #f7f8fa; text-align: center; min-width: 150px; }
.cmp-thumb { display: block; width: 100%; max-width: 150px; height: 90px; object-fit: cover; border-radius: 8px; margin: 0 auto 6px; }
.cmp-match td { background: #ecfdf3; }
.cmp-match .cmp-rowhead { background: #d1fadf; }
.cmp-diff td { background: #fff7ed; }
.cmp-empty { color: var(--muted); }
.cmp-flag { display: inline-block; background: var(--ok); color: #fff; font-size: .68rem; font-weight: 700; padding: 1px 7px; border-radius: 999px; margin-left: 4px; vertical-align: middle; }

/* Historical revision banner */
.rev-banner { display: flex; flex-wrap: wrap; gap: 8px 16px; justify-content: space-between; align-items: center; padding: 10px 14px; margin: 0 0 18px; background: #fffbeb; border: 1px solid #fde68a; border-radius: var(--radius); font-size: .9rem; }
.rev-banner-links { white-space: nowrap; }
.cmp-legend { margin-top: 12px; font-size: .85rem; }
.cmp-key { display: inline-block; width: 14px; height: 14px; border-radius: 3px; vertical-align: middle; margin-right: 3px; border: 1px solid var(--line); }
.cmp-key-match { background: #ecfdf3; }
.cmp-key-diff { background: #fff7ed; }

/* Moderator banner (secondary nav, shown to signed-in moderators) */
.mod-banner { background: #1f2937; color: #e5e7eb; position: sticky; top: 64px; z-index: 999; }
.mod-banner-inner { display: flex; align-items: center; gap: 14px; min-height: 44px; }
.mod-banner-tag { font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #93c5fd; background: rgba(59,130,246,.15); padding: 3px 9px; border-radius: 6px; white-space: nowrap; }
.mod-banner-nav { display: flex; gap: 2px; flex-wrap: wrap; }
.mod-banner-nav a { color: #e5e7eb; font-size: .9rem; font-weight: 500; padding: 6px 12px; border-radius: 7px; }
.mod-banner-nav a:hover { background: rgba(255,255,255,.1); text-decoration: none; }
.mod-badge { display: inline-block; min-width: 18px; text-align: center; background: var(--brand); color: #fff; font-size: .72rem; font-weight: 700; padding: 1px 6px; border-radius: 999px; }
.mod-banner-spacer { flex: 1; }
.mod-banner-user { color: #9ca3af; font-size: .85rem; white-space: nowrap; }
.mod-banner-out { background: none; border: 1px solid rgba(255,255,255,.25); color: #e5e7eb; font-size: .85rem; padding: 5px 12px; border-radius: 7px; cursor: pointer; }
.mod-banner-out:hover { background: rgba(255,255,255,.1); }
@media (max-width: 640px) {
  .mod-banner-inner { flex-wrap: wrap; gap: 8px; padding-top: 8px; padding-bottom: 8px; }
  .mod-banner-spacer { display: none; }
  .mod-banner-user { margin-left: auto; }
}

/* Activity timeline / history */
.hist-filter { display: flex; gap: 6px; margin: 20px 0 14px; }
.hist-tab { padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); font-size: .9rem; }
.hist-tab:hover { text-decoration: none; border-color: #cfd4dc; }
.hist-tab.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.timeline { list-style: none; margin: 0; padding: 0; }
.tl-item { display: flex; gap: 14px; padding: 0 0 18px; position: relative; }
.tl-item:not(:last-child)::before { content: ""; position: absolute; left: 6px; top: 16px; bottom: 0; width: 2px; background: var(--line); }
.tl-dot { width: 14px; height: 14px; border-radius: 50%; background: var(--brand); margin-top: 3px; flex-shrink: 0; box-shadow: 0 0 0 3px var(--bg); }
.tl-view .tl-dot { background: var(--muted); }
.tl-line { font-size: .95rem; }
.tl-rev { color: var(--muted); font-size: .8rem; margin-left: 6px; }
.tl-note { color: var(--ink); background: #f7f8fa; border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; margin: 5px 0; font-size: .9rem; }
.tl-time { color: var(--muted); font-size: .82rem; margin-top: 3px; }

/* Moderator toolbar on a report */
.mod-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; margin: 0 0 22px; background: #f7faff; border: 1px solid #cfe0ff; border-radius: var(--radius); }
.mod-toolbar .tb-form { display: contents; }
.btn.tb-delete { color: #991b1b; border-color: #fecaca; }
.btn.tb-delete:hover { background: #fef2f2; }
.tb-recover { position: relative; }
.tb-recover > summary { cursor: pointer; list-style: none; }
.tb-recover > summary::-webkit-details-marker { display: none; }
.tb-recover-form { position: absolute; top: 100%; left: 0; z-index: 20; margin-top: 6px; width: 290px; display: flex; flex-direction: column; gap: 8px; padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); }
.tb-recover-form textarea { font: inherit; padding: 8px; border: 1px solid var(--line); border-radius: 8px; resize: vertical; }
.recovered-flag { color: var(--ok); font-weight: 600; font-size: .9rem; }

/* PII redaction controls (edit form + report badges) */
.check.redact { display: inline-flex; align-items: center; gap: 5px; margin-top: 5px; font-size: .82rem; color: #92400e; font-weight: 500; }
.check.redact input { margin: 0; }
.redact-badge { display: inline-block; font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: #92400e; background: #fef3c7; border: 1px solid #fde68a; padding: 1px 6px; border-radius: 999px; vertical-align: middle; }
.pending-flag { color: #92400e; background: #fef3c7; border: 1px solid #fde68a; padding: 3px 10px; border-radius: 999px; font-size: .8rem; font-weight: 600; }

/* Success notice on moderator forms */
.form-notice { background: #ecfdf5; border: 1px solid #a7f3d0; color: #065f46; padding: 10px 14px; border-radius: var(--radius); margin: 0 0 16px; }

/* Moderator admin tables (content pages, etc.) */
.admin-table { width: 100%; border-collapse: collapse; margin-top: 12px; }
.admin-table th, .admin-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.admin-table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
.admin-table-actions { text-align: right; white-space: nowrap; }

/* Monospace editor textarea (Markdown/HTML source) */
textarea.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .9rem; line-height: 1.5; tab-size: 2; }

/* Contact-details reveal (public: gated behind a button, JS-injected) */
.contact-reveal { margin: 4px 0 10px; }
.contact-reveal-btn { width: 100%; }
.contact-target[hidden] { display: none; }
.contact-note { margin: 6px 0 0; }

/* Statistics dashboard */
.stat-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin: 18px 0 8px; }
.stat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; display: flex; flex-direction: column; gap: 4px; }
.stat-num { font-size: 2.2rem; font-weight: 700; letter-spacing: -.02em; color: var(--brand); }
.stat-label { color: var(--muted); font-size: .9rem; }
.stat-h2 { font-size: 1.15rem; margin: 30px 0 12px; }
.bars { display: flex; flex-direction: column; gap: 8px; }
.bar-row { display: grid; grid-template-columns: 140px 1fr 56px; align-items: center; gap: 12px; }
.bar-key { color: var(--muted); font-size: .9rem; text-align: right; }
.bar-key-link { color: var(--brand); }
.bar-track { background: #eef1f5; border-radius: 6px; height: 16px; overflow: hidden; }
.bar-fill { display: block; height: 100%; background: var(--brand); border-radius: 6px; min-width: 2px; }
.bar-key-active { font-weight: 700; color: var(--ink); }
.bar-fill-active { background: var(--ok); }
.bar-val { font-weight: 600; font-size: .9rem; }
@media (max-width: 560px) { .bar-row { grid-template-columns: 96px 1fr 44px; } .bar-key { font-size: .82rem; } }

/* Calendar */
.cal-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 6px 0 10px; }
.cal-month { font-size: 1.2rem; }
.calendar { width: 100%; border-collapse: collapse; table-layout: fixed; }
.calendar th { text-align: center; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: 6px 0; }
.cal-cell { height: 76px; border: 1px solid var(--line); vertical-align: top; padding: 0; }
.cal-empty { background: #fafbfc; border-color: #f0f1f3; }
.cal-cell .cal-day { display: block; padding: 5px 7px; font-size: .8rem; color: var(--muted); }
.cal-cell.has-thefts { background: var(--surface); }
.cal-cell.has-thefts a { display: flex; flex-direction: column; height: 100%; color: inherit; }
.cal-cell.has-thefts a:hover { text-decoration: none; background: #eef4ff; }
.cal-cell .cal-count { margin: auto auto 8px; font-size: 1.3rem; font-weight: 700; color: var(--brand); }

/* Static content pages */
.content-page { max-width: 760px; padding: 28px 20px 64px; }
.content-page h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); letter-spacing: -.02em; margin: 6px 0 18px; }
.prose-content { line-height: 1.7; }
.prose-content p { margin: 0 0 1em; }
.prose-content h2 { margin: 1.4em 0 .5em; font-size: 1.3rem; }
.prose-content h3 { margin: 1.2em 0 .4em; font-size: 1.1rem; }
.prose-content ul, .prose-content ol { margin: 0 0 1em; padding-left: 1.4em; }
.prose-content li { margin: .3em 0; }
.prose-content img { max-width: 100%; height: auto; border-radius: var(--radius); margin: .5em 0; }
.prose-content img.page-photo { float: right; margin: 0 0 1em 1.5em; max-width: 300px; }
.prose-content a { text-decoration: underline; }

/* Moderation queue + edit */
.queue { list-style: none; margin: 18px 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.queue-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.queue-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 16px; }
.queue-info { min-width: 0; }
.queue-title { font-weight: 600; }
.queue-meta { margin: 4px 0 0; color: var(--muted); font-size: .85rem; }
.queue-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.queue-actions form { margin: 0; }
/* inline preview (CSS-only toggle) */
.qprev-check { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.qprev-toggle { cursor: pointer; user-select: none; display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border: 1px solid var(--line); border-radius: 8px; color: var(--muted); transition: transform .15s ease; }
.qprev-toggle:hover { background: #f0f2f5; color: var(--ink); }
.qprev-check:checked ~ .queue-row .qprev-toggle { transform: rotate(180deg); color: var(--ink); }
.qprev-body { display: none; gap: 16px; padding: 0 16px 16px; border-top: 1px solid var(--line); }
.qprev-check:checked ~ .qprev-body { display: flex; padding-top: 14px; }
.qprev-img { width: 120px; height: 90px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.qprev-main { min-width: 0; }
.qprev-facts { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; margin: 0; font-size: .88rem; }
.qprev-facts dt { color: var(--muted); }
.qprev-facts dd { margin: 0; }
.qprev-desc { margin: 8px 0 0; font-size: .9rem; white-space: pre-wrap; }
@media (max-width: 680px) { .qprev-body { flex-direction: column; } }
.mod-controls { background: #f7faff !important; border-color: #cfe0ff !important; }
.check { font-weight: 500 !important; display: flex; align-items: center; gap: 8px; }
.check input { width: auto !important; }
@media (max-width: 680px) { .queue-row { flex-direction: column; align-items: stretch; } }

/* Thank-you page */
.finish { padding: 60px 20px; max-width: 640px; }
.finish-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 40px; text-align: center; }
.finish-mark { width: 56px; height: 56px; margin: 0 auto 18px; border-radius: 50%; background: var(--ok); color: #fff; font-size: 1.8rem; display: grid; place-items: center; }
.finish-card h1 { font-size: 1.4rem; margin: 0 0 12px; }
.finish .form-actions { justify-content: center; }

@media (max-width: 820px) {
  .report-grid { grid-template-columns: 1fr; }
}
