:root { --ink: #1a1a1a; --muted: #5c5c5c; --line: #ddd; --accent: #0b57d0; --bg: #fff; --ok: #1a7f37; --bad: #b3261e; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
main { max-width: 44rem; margin: 0 auto; padding: 1.5rem 1rem 4rem; }
nav { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--line); padding-bottom: .75rem; margin-bottom: 1.5rem; }
h1 { font-size: 1.6rem; } h2 { font-size: 1.2rem; margin-top: 2rem; }
label { display: block; margin: .9rem 0; font-weight: 600; }
input, textarea, select { display: block; width: 100%; margin-top: .3rem; padding: .55rem .65rem; font: inherit; font-weight: 400; border: 1px solid var(--line); border-radius: 6px; }
button { font: inherit; padding: .55rem 1.1rem; border: 0; border-radius: 6px; background: var(--accent); color: #fff; cursor: pointer; margin-top: .5rem; }
button.link { background: none; color: var(--accent); text-decoration: underline; padding: 0; margin: 0; }
a.button { display: inline-block; padding: .55rem 1.1rem; border-radius: 6px; background: var(--accent); color: #fff; text-decoration: none; }
.err { color: var(--bad); font-weight: 400; font-size: .9rem; }
fieldset.row { border: 1px solid var(--line); border-radius: 8px; margin: .75rem 0; padding: .5rem .75rem; }
ol.stages { list-style: none; padding: 0; }
ol.stages li { padding: .4rem 0 .4rem 1.6rem; position: relative; color: var(--muted); }
ol.stages li::before { content: "○"; position: absolute; left: 0; }
ol.stages li.done { color: var(--ink); } ol.stages li.done::before { content: "●"; color: var(--ok); }
ol.stages li.current { color: var(--ink); font-weight: 600; } ol.stages li.current::before { content: "◉"; color: var(--accent); }
ul.timeline { list-style: none; padding: 0; } ul.timeline li { border-left: 2px solid var(--line); margin: 0; padding: .5rem 0 .5rem 1rem; }
time { color: var(--muted); font-size: .85rem; margin-left: .5rem; }
.scroll { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; margin: .75rem 0; }
th, td { text-align: left; border-bottom: 1px solid var(--line); padding: .45rem .6rem; white-space: nowrap; }
.shots img { max-width: 100%; border: 1px solid var(--line); border-radius: 8px; margin: .5rem 0; }
.summary { background: #f6f8fa; border-radius: 8px; padding: .75rem 1rem; }
.stepnav { display: flex; gap: .75rem; align-items: center; margin-top: 1.5rem; }
#savestate { color: var(--muted); font-size: .85rem; }
h3 { font-size: 1rem; margin: 1.25rem 0 0; }
.intake th, .intake td { white-space: normal; vertical-align: top; }
.intake tbody th { width: 11rem; font-weight: 600; }
.assets { display: flex; flex-wrap: wrap; gap: .5rem; margin: .75rem 0; }
.assets img { width: 8rem; height: 8rem; object-fit: cover; border: 1px solid var(--line); border-radius: 8px; }
.chip { display: inline-block; padding: .15rem .6rem; border: 1px solid var(--line); border-radius: 999px; font-size: .85rem; margin-right: .4rem; }
.chip.ongoing { opacity: .7; }
.amber { color: #9a6700; }
.red { color: var(--bad); }
.board-client { border-top: 1px solid var(--line); padding: .75rem 0; }
.tasklist { margin: .3rem 0 0 0; padding-left: 1.2rem; }
.tasklist form { display: inline; margin-left: .5rem; }
.tasklist form input[name="note"] { display: inline; width: auto; margin: 0 .3rem; padding: .2rem .4rem; }
.job-detail { border-top: 1px solid var(--line); padding: .75rem 0; }
ol.ladder { list-style: none; padding: 0; }
ol.ladder li { padding: .4rem 0 .4rem 1.6rem; position: relative; color: var(--muted); }
ol.ladder li::before { content: "○"; position: absolute; left: 0; }
ol.ladder li.done { color: var(--ink); } ol.ladder li.done::before { content: "●"; color: var(--ok); }
ol.ladder li.current { color: var(--ink); font-weight: 600; } ol.ladder li.current::before { content: "◉"; color: var(--accent); }

/* schema-driven intake: help text, section blurbs, choice groups, gating chips */
.blurb { color: var(--muted); margin: .25rem 0 1.25rem; max-width: 60ch; }
.help { color: var(--muted); font-weight: 400; font-size: .9rem; margin: .2rem 0 .1rem; max-width: 60ch; }
.safety { border: 1px solid var(--bad); border-radius: 8px; padding: .75rem 1rem; background: #fff6f5; }
.core { display: inline-block; margin-left: .4rem; padding: .1rem .5rem; border-radius: 999px;
  background: #eef3fd; color: var(--accent); font-size: .72rem; font-weight: 700;
  letter-spacing: .04em; text-transform: uppercase; vertical-align: 1px; }
fieldset.choices { border: 1px solid var(--line); border-radius: 8px; margin: .9rem 0; padding: .5rem 1rem 1rem; }
fieldset.choices legend { font-weight: 600; padding: 0 .35rem; }
label.choice { display: flex; align-items: flex-start; gap: .5rem; margin: .4rem 0; font-weight: 400; }
label.choice input { display: inline; width: auto; margin: .35rem 0 0; flex: none; }
.rows h3 { margin: 1.4rem 0 .2rem; font-size: 1rem; }
.meta { color: var(--muted); font-size: .9rem; }
/* Removing a row is destructive and secondary — it should not outrank "Add". */
fieldset.row button[data-remove] { background: none; color: var(--muted); border: 1px solid var(--line); }
fieldset.row button[data-remove]:hover { color: var(--bad); border-color: var(--bad); }
