:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #0f172a;
  --muted: #64748b;
  --border: #e2e8f0;
  --accent: #2563eb;
  --accent-text: #ffffff;
  --ok: #15803d;
  --warn: #b91c1c;
  --warn-bg: #fef2f2;
  --radius: 12px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1120;
    --surface: #111827;
    --text: #e5e7eb;
    --muted: #94a3b8;
    --border: #1f2937;
    --accent: #3b82f6;
    --ok: #4ade80;
    --warn: #f87171;
    --warn-bg: #2a1215;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
}
.wrap { max-width: 860px; margin: 0 auto; padding: 0 16px; }

.site-header { border-bottom: 1px solid var(--border); background: var(--surface); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 56px; }
.brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 1.1rem; color: var(--text); text-decoration: none; }
.logo { width: 26px; height: 26px; background: url(/favicon.svg) center / contain no-repeat; }
.tag { font-size: .8rem; color: var(--ok); font-weight: 600; }

.hero { padding: 32px 0 8px; }
.hero h1 { font-size: clamp(1.5rem, 4vw, 2.1rem); line-height: 1.2; margin: 0 0 12px; text-wrap: balance; }
.hero p { color: var(--muted); margin: 0; max-width: 62ch; }

.ad-slot {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  margin: 24px 0;
  min-height: 90px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.ad-bottom { min-height: 250px; }
.ad-label {
  position: absolute; top: 4px; left: 8px;
  font-size: .7rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em;
}
.ad-slot ins { width: 100%; }

.drop {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 40px 16px;
  background: var(--surface);
  border: 2px dashed var(--accent);
  border-radius: var(--radius);
  text-align: center;
  cursor: pointer;
  transition: background .15s, transform .15s;
}
.drop svg { color: var(--accent); }
.drop:hover, .drop.over { background: color-mix(in srgb, var(--accent) 8%, var(--surface)); }
.drop.over { transform: scale(1.01); }
.drop:focus-within { outline: 3px solid color-mix(in srgb, var(--accent) 40%, transparent); outline-offset: 2px; }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop-main { font-weight: 600; font-size: 1.05rem; }
.drop-main u { color: var(--accent); }
.drop-sub { color: var(--muted); font-size: .875rem; }

.results-head { display: flex; justify-content: flex-end; margin-top: 16px; }
.results { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 12px; }
.card {
  display: flex; gap: 16px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.card.error { flex-direction: column; gap: 4px; }
.thumb { width: 96px; height: 96px; object-fit: cover; border-radius: 8px; flex: none; background: var(--border); }
.card-body { min-width: 0; flex: 1; }
.card-title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.status { margin: 2px 0 8px; font-size: .9rem; }
.status.ok, .status.clean { color: var(--ok); }
.status.err { color: var(--warn); }
.meta { display: grid; grid-template-columns: max-content 1fr; gap: 2px 12px; margin: 0 0 12px; font-size: .875rem; }
.meta dt { color: var(--muted); }
.meta dd { margin: 0; overflow-wrap: anywhere; text-decoration: line-through; text-decoration-color: var(--muted); }
.meta dd.sensitive { color: var(--warn); }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font: inherit; font-weight: 600; font-size: .9rem;
  text-decoration: none;
  cursor: pointer;
}
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn.subtle { border-color: transparent; color: var(--muted); }
.btn:hover { filter: brightness(1.05); }

.info { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; margin: 40px 0 0; }
.info h2 { font-size: 1.05rem; margin: 0 0 8px; }
.info ul { margin: 0; padding-left: 20px; color: var(--muted); }

.site-footer { border-top: 1px solid var(--border); margin-top: 40px; padding: 20px 0; font-size: .875rem; color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; }
.site-footer a { color: var(--muted); }

.prose { padding: 32px 0; max-width: 68ch; }
.prose h1 { margin-top: 0; }

@media (max-width: 480px) {
  .card { flex-direction: column; }
  .thumb { width: 100%; height: 180px; }
}

/* Navigation */
.nav { display: flex; gap: 16px; font-size: .9rem; }
.nav a, .site-footer nav a { color: var(--muted); text-decoration: none; }
.nav a:hover, .site-footer nav a:hover { color: var(--text); text-decoration: underline; }
.site-footer nav { display: flex; gap: 16px; }

/* Article pages */
.prose h2 { font-size: 1.25rem; margin: 2em 0 .5em; }
.prose h3 { font-size: 1.05rem; margin: 1.5em 0 .4em; }
.prose p, .prose li { color: var(--text); }
.prose a { color: var(--accent); }
.prose .lede { font-size: 1.1rem; color: var(--muted); }
.prose ol, .prose ul { padding-left: 22px; }
.prose li { margin: .3em 0; }
.cta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
  margin: 24px 0; padding: 16px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  color: var(--muted); font-size: .9rem;
}
.cta .btn { color: var(--accent-text); }
.table-wrap { overflow-x: auto; margin: 16px 0; }
.prose table { border-collapse: collapse; width: 100%; font-size: .9rem; }
.prose th, .prose td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.prose th { color: var(--muted); font-weight: 600; }
.yes { color: var(--ok); font-weight: 600; }
.no { color: var(--warn); font-weight: 600; }
.guide-list { list-style: none; padding: 0 !important; display: grid; gap: 12px; }
.guide-list a { display: block; padding: 14px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; }
.guide-list a:hover { border-color: var(--accent); }
.guide-list strong { display: block; color: var(--text); }
.guide-list span { color: var(--muted); font-size: .9rem; }
.updated { color: var(--muted); font-size: .85rem; }
.guides-home { padding: 0; max-width: none; margin-top: 40px; }
.guides-home h2 { margin-top: 0; }
.nav .tag { align-self: center; }
.perks { display: flex; flex-wrap: wrap; gap: 6px 0; list-style: none; margin: 14px 0 0; padding: 0; font-size: .875rem; font-weight: 600; color: var(--ok); }
.perks li + li::before { content: "·"; margin: 0 10px; color: var(--muted); font-weight: 400; }

/* Removal options */
.options { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin: 0 0 12px; padding: 0; border: 0; }
.options legend { float: left; margin-right: 4px; font-weight: 600; font-size: .9rem; color: var(--muted); }
.options label { display: inline-flex; align-items: center; gap: 6px; font-size: .95rem; cursor: pointer; }
.options input { width: 18px; height: 18px; accent-color: var(--accent); margin: 0; }
.options small { color: var(--muted); }
.opt-hint { margin: -4px 0 12px; color: var(--warn); font-size: .875rem; }
.drop.disabled { opacity: .5; pointer-events: none; }
.results-head { gap: 8px; }
.meta dd.kept { text-decoration: none; }
.meta dd .kept-tag { margin-left: 6px; font-size: .75rem; color: var(--ok); font-weight: 600; }
