:root {
  --ink: #1d2a24;
  --paper: #f6f1e7;
  --card: #fffdf8;
  --line: #ddd5c4;
  --muted: #6b6a5f;
  --accent: #2f6b4f;
  --accent-ink: #ffffff;
  --warn: #b3261e;
  --warn-bg: #fbe9e7;
  --ok-bg: #e6f2ea;
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --ink: #ece7dc;
    --paper: #151b18;
    --card: #1e2622;
    --line: #34403a;
    --muted: #a2a294;
    --accent: #6fbf95;
    --accent-ink: #10201a;
    --warn: #ff8a80;
    --warn-bg: #3a1f1d;
    --ok-bg: #1f3329;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
}
main { max-width: 560px; margin: 0 auto; padding: 16px 16px 96px; }
h1 { font-size: 1.35rem; margin: 8px 0 4px; }
h2 { font-size: 1.05rem; margin: 20px 0 8px; }
p { margin: 6px 0; }
.muted { color: var(--muted); font-size: 0.92rem; }
.top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.pill { font-size: 0.8rem; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line); white-space: nowrap; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; margin: 12px 0; }
.card.warn { background: var(--warn-bg); border-color: var(--warn); }
.card.ok { background: var(--ok-bg); }
button, .btn {
  font: inherit; border-radius: var(--radius); border: 1px solid var(--line);
  background: var(--card); color: var(--ink); padding: 12px 14px; min-height: 48px; cursor: pointer;
}
button.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 600; }
button.big { width: 100%; font-size: 1.1rem; min-height: 60px; margin: 8px 0; }
button.danger { color: var(--warn); }
button:disabled { opacity: 0.45; cursor: default; }
.row { display: flex; gap: 8px; flex-wrap: wrap; }
.row > * { flex: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { min-height: 44px; padding: 8px 14px; border-radius: 999px; }
.chip.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tile {
  position: relative; aspect-ratio: 1; border-radius: var(--radius); border: 2px dashed var(--line);
  background: var(--card); display: flex; flex-direction: column; justify-content: flex-end;
  overflow: hidden; padding: 0; text-align: left;
}
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tile .label { position: relative; padding: 8px 10px; background: color-mix(in srgb, var(--card) 85%, transparent); font-weight: 600; }
.tile.done { border-style: solid; border-color: var(--accent); }
.tile.skip { border-style: solid; border-color: var(--warn); }
.tile .reach { position: absolute; top: 6px; right: 6px; min-height: 32px; padding: 4px 10px; font-size: 0.8rem; border-radius: 999px; }
.list { list-style: none; padding: 0; margin: 0; }
.list li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.bar { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; margin-top: 4px; }
.bar > span { display: block; height: 100%; background: var(--accent); }
input[type=text], textarea {
  font: inherit; width: 100%; padding: 12px; border-radius: var(--radius);
  border: 1px solid var(--line); background: var(--card); color: var(--ink);
}
textarea { min-height: 90px; }
.footer { position: fixed; left: 0; right: 0; bottom: 0; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--paper); border-top: 1px solid var(--line); }
.footer .inner { max-width: 560px; margin: 0 auto; display: flex; gap: 8px; }
.footer .inner > * { flex: 1; }
.steps { counter-reset: s; padding: 0; list-style: none; }
.steps li { counter-increment: s; padding: 8px 0 8px 40px; position: relative; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: 6px; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; font-weight: 700; font-size: 0.9rem; }
.shapes { display: grid; gap: 10px; margin: 12px 0; }
.shape { display: flex; gap: 12px; align-items: center; text-align: left; width: 100%; padding: 10px 12px; }
.shape svg { flex: 0 0 56px; color: var(--accent); }
.shape > span { display: flex; flex-direction: column; gap: 2px; }
.shape .pill { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); margin-left: 6px; }
.shape.suggested { border: 2px solid var(--accent); background: var(--ok-bg); }
.shape:not(.suggested) .pill { display: none; }
