:root {
  color-scheme: light;
  --bg: #efe7d6;
  --ink: #1c1914;
  --muted: #5c5346;
  --card: #fffaf1;
  --line: #ddc8a4;
  --deep: #14352c;
  --lime: #d6f25c;
  --warn: #8a3d12;
  --bad: #7c1e32;
  --ok: #1f6b45;
  --shadow: 0 1px 0 rgba(28, 25, 20, 0.06);
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(1200px 400px at 10% -10%, #f7f1e4 0%, transparent 50%),
    var(--bg);
}
.wrap { max-width: 40rem; margin: 0 auto; padding: 1.1rem 1.1rem 3rem; }
.top, footer { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.wordmark {
  color: var(--deep);
  font-weight: 760;
  letter-spacing: -0.03em;
  text-decoration: none;
  font-size: 1.05rem;
}
.wordmark::before {
  content: "";
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  margin-right: 0.4rem;
  border-radius: 99px;
  background: var(--lime);
  box-shadow: 0 0 0 4px var(--deep);
  vertical-align: 0.05rem;
}
.langs a, footer a, .lang { color: var(--muted); margin-left: 0.6rem; }
h1 {
  font-family: Georgia, "Iowan Old Style", Palatino, serif;
  font-size: clamp(2rem, 8vw, 3.1rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  font-weight: 650;
  margin: 1.2rem 0 0.7rem;
}
.sub, .trust, .prose, .about p { font-size: 1.02rem; line-height: 1.45; }
.sub { margin-top: 0; }
.trust { color: var(--muted); margin-top: 0.8rem; }
label { display: block; font-weight: 650; margin-bottom: 0.35rem; }
input[type="text"], input[type="file"] {
  width: 100%;
  font: inherit;
  font-size: 1rem;
  padding: 0.85rem 0.9rem;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink);
}
button, .filebtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-top: 0.7rem;
  min-height: 3.1rem;
  border: 0;
  border-radius: 14px;
  background: var(--deep);
  color: #f6f3ea;
  font: inherit;
  font-weight: 680;
  cursor: pointer;
}
button.secondary, .filebtn {
  background: transparent;
  color: var(--deep);
  border: 1px solid var(--deep);
}
button:disabled { opacity: 0.6; }
.about, .card, .summary, details, .note, .rssbox {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.about { margin-top: 1.6rem; padding: 1rem 1.05rem; }
.about h2, .prose h1, .prose h2 { font-family: Georgia, Palatino, serif; }
.summary { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 1rem; }
.summary div { padding: 0.85rem 0.4rem; text-align: center; }
.summary strong {
  display: block;
  font-variant-numeric: tabular-nums;
  font-size: 1.6rem;
}
.summary span { color: var(--muted); font-size: 0.82rem; }
.card, details, .note, .rssbox { margin-top: 0.75rem; padding: 0.85rem 1rem; }
.card h2 { margin: 0 0 0.3rem; font-size: 1.05rem; }
.meta { color: var(--muted); margin: 0.2rem 0; }
.tag { display: inline-block; padding: 0.12rem 0.45rem; border-radius: 999px; background: #efe4cf; font-size: 0.78rem; }
.tag.bad { background: #f3d0d6; color: var(--bad); }
.tag.warn { background: #f6e0c8; color: var(--warn); }
.tag.ok { background: #d9efe3; color: var(--ok); }
details summary { cursor: pointer; font-weight: 680; min-height: 2.4rem; display: flex; align-items: center; }
details ul { margin: 0.4rem 0 0; padding-left: 1.1rem; }
details a { color: var(--deep); }
blockquote { margin: 0.4rem 0; color: var(--ink); }
.progress {
  margin-top: 0.8rem;
  height: auto;
  background: transparent;
  color: var(--muted);
  font-size: 0.92rem;
}
.progress::before {
  content: "";
  display: block;
  height: 0.45rem;
  border-radius: 99px;
  margin-bottom: 0.35rem;
  background: linear-gradient(to right, var(--deep) var(--w, 0%), #e4d3b4 var(--w, 0%));
}
.progress[hidden] { display: none; }
.note.error { border-color: #e4b4bc; }
.actions { display: grid; gap: 0.2rem; }
footer { margin-top: 1.4rem; }
.prose { padding-bottom: 2rem; }
.prose h1 { margin-top: 0.4rem; }
.fine { color: var(--muted); }
:focus-visible { outline: 3px solid var(--deep); outline-offset: 2px; }
@media (max-width: 380px) {
  .summary { grid-template-columns: 1fr; }
  .summary div { text-align: left; padding-left: 0.9rem; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto; }
}
