:root {
  --bg: #f4f2ee; --card: #fff; --ink: #1d2433; --muted: #667085; --line: #e2ded6;
  --accent: #1f4fd8; --pro: #17794a; --con: #b3372f; --mid: #a86a00;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
main { max-width: 880px; margin: 0 auto; padding: 48px 20px 80px; }
h1 { margin: 0 0 6px; font-size: 1.9rem; letter-spacing: -0.02em; }
h2 { margin: 0 0 14px; font-size: 1.05rem; }
.lead { margin: 0 0 28px; color: var(--muted); }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 12px;
  padding: 22px; margin-bottom: 18px;
}
label, .label {
  display: block; margin-bottom: 8px; font-size: .78rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .06em; color: var(--muted);
}
.label:not(:first-child) { margin-top: 18px; }
.row { display: flex; gap: 10px; }
input {
  flex: 1; min-width: 0; padding: 11px 13px; font: inherit; color: inherit;
  border: 1px solid #c9c4ba; border-radius: 8px; background: #fff;
}
input:focus-visible, button:focus-visible, a:focus-visible { outline: 3px solid #9db4f5; outline-offset: 1px; }
button {
  padding: 11px 20px; font: inherit; font-weight: 600; color: #fff; cursor: pointer;
  background: var(--accent); border: 0; border-radius: 8px;
}
button:hover { filter: brightness(1.1); }
.error { margin: 12px 0 0; color: var(--con); }
.hint { margin: 16px 0 0; font-size: .9rem; color: var(--muted); }
a { color: var(--accent); }
.break { overflow-wrap: anywhere; }

.wait-head { display: flex; align-items: center; gap: 12px; }
.spinner {
  width: 22px; height: 22px; flex: none; border-radius: 50%;
  border: 3px solid var(--line); border-top-color: var(--accent);
  animation: spin .9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 4s; } }
#wait-log { margin: 16px 0 0; padding: 0; list-style: none; color: var(--muted); font-size: .93rem; }
#wait-log li { padding: 3px 0; overflow-wrap: anywhere; }
#wait-log li::before { content: "✓ "; color: var(--pro); }

blockquote {
  margin: 0; padding-left: 14px; border-left: 3px solid var(--accent);
  font-size: 1.2rem; line-height: 1.4;
}
.verdict-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.verdict-row strong { font-size: 1.5rem; text-transform: capitalize; }
.score { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.bar { height: 8px; margin: 10px 0 4px; border-radius: 4px; background: var(--line); overflow: hidden; }
.bar > div { height: 100%; border-radius: 4px; background: var(--tone, var(--accent)); }
.verdict { --tone: var(--mid); border-left: 5px solid var(--tone); }
.verdict.prawdopodobna { --tone: var(--pro); }
.verdict.nieprawdopodobna { --tone: var(--con); }
.verdict strong { color: var(--tone); }
#res-justification { margin: 12px 0 0; }

.columns { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.pro { --tone: var(--pro); } .con { --tone: var(--con); }
.columns h2 { color: var(--tone); }
.sources { margin: 0; padding: 0; list-style: none; }
.sources li { padding: 14px 0; border-top: 1px solid var(--line); }
.sources li:first-child { border-top: 0; padding-top: 0; }
.src-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.src-head a { font-weight: 600; overflow-wrap: anywhere; }
.src-domain { font-size: .82rem; color: var(--muted); overflow-wrap: anywhere; }
.sources p { margin: 6px 0 0; font-size: .93rem; }
.unverified { font-size: .78rem; color: var(--mid); }
.empty { color: var(--muted); }

@media (max-width: 640px) {
  .columns { grid-template-columns: 1fr; gap: 0; }
  .row { flex-direction: column; }
}
