/* KKB visual system. Colors come from the Kochvai Boker logo: forest green and brass on paper.
   Lora (titles) + Source Sans 3 (everything else), both OFL, served from /fonts. */
@font-face { font-family: "Source Sans 3"; src: url(/fonts/source-sans-3.woff) format("woff"); font-weight: 200 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Source Sans 3"; src: url(/fonts/source-sans-3-italic.woff) format("woff"); font-weight: 200 900; font-style: italic; font-display: swap; }
@font-face { font-family: "Lora"; src: url(/fonts/lora.woff) format("woff"); font-weight: 400 700; font-style: normal; font-display: swap; }
:root {
  --forest: #1f3a2e; --forest-2: #2c5241; --brass: #b8925c; --brass-deep: #8c6a36; --paper: #f6f4ef;
  --ink: #1e2723; --muted: #5c6862; --faint: #85908a; --line: #dfe2dc; --bg: var(--paper); --card: #fff;
  --navy: var(--forest); --navy-2: var(--forest-2); --accent: var(--brass); --accent-bg: #f7eedc;
  --green: #2e7d55; --green-bg: #e5f2ea; --red: #a2412f; --red-bg: #f8e6e1; --blue-bg: #e8efeb; --gold-bg: #f5ead2;
  --radius: 8px; --shadow: none; --lift: 0 8px 28px rgba(20, 35, 28, .16);
  --serif: "Lora", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; font: 16px/1.5 var(--sans); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
td, .num, .amt, .t-val, .badge .count, .count { font-variant-numeric: tabular-nums; }
a { color: var(--forest-2); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { margin: 0; line-height: 1.25; font-family: var(--serif); font-weight: 600; color: var(--forest); }
h1 { font-size: 27px; letter-spacing: -.2px; } h2 { font-size: 18.5px; } h3 { font-size: 16px; }
button, input, select, textarea { font: inherit; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* Header */
.top { background: var(--forest); color: #fff; position: sticky; top: 0; z-index: 10; border-bottom: 3px solid var(--brass); }
.top-in { max-width: 1240px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; white-space: nowrap; font-family: var(--serif); font-weight: 600; font-size: 18px; }
.brand:hover { text-decoration: none; }
.brand img { width: 34px; height: 34px; border-radius: 50%; background: #f4f0e8; padding: 2px; }
.brand span { display: flex; flex-direction: column; line-height: 1.1; }
.brand small { font-family: var(--sans); font-weight: 500; font-size: 11.5px; color: #d9c7a6; letter-spacing: .3px; }
.nav { display: flex; gap: 2px; flex-wrap: wrap; flex: 1; }
.nav a { color: #dbe4de; padding: 6px 8px; border-radius: 6px; font-size: 14.5px; font-weight: 500; }
.nav a:hover { background: rgba(255,255,255,.10); color: #fff; text-decoration: none; }
.nav a.on { color: #fff; background: rgba(255,255,255,.12); box-shadow: inset 0 -2px 0 var(--brass); border-radius: 6px 6px 0 0; }
.who { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.who select { background: #fff; border: 0; border-radius: 6px; padding: 4px 6px; }
.demo-band { background: var(--accent-bg); color: #6b4f1f; font-size: 12.5px; text-align: center; padding: 4px 12px; border-bottom: 1px solid #efdcb3; }

main { max-width: 1180px; margin: 0 auto; padding: 24px 16px 80px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.page-head p { margin: 6px 0 0; color: var(--muted); max-width: 72ch; }
.cols { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 18px; align-items: start; }
@media (max-width: 860px) { .cols { grid-template-columns: 1fr; } }

/* Cards & lists */
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 16px; }
.panel > .ph { padding: 13px 16px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.panel > .pb { padding: 14px 16px; }
.panel .empty { color: var(--faint); padding: 14px; font-size: 14px; }
.group-title { font-size: 15px; font-family: var(--serif); color: var(--forest); font-weight: 600; margin: 20px 0 8px; display: flex; gap: 8px; align-items: center; }
.group-title .count { background: var(--line); color: var(--ink); border-radius: 10px; padding: 0 7px; font-size: 11px; }
.item { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 8px; box-shadow: var(--shadow); }
.item .row1 { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.item .name { font-weight: 650; font-size: 16.5px; }
.item .amt { font-weight: 650; white-space: nowrap; }
.item .why { color: var(--muted); font-size: 14.5px; margin-top: 3px; }
.item .meta { color: var(--faint); font-size: 12.5px; margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px 12px; }
.item .acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.events { margin: 8px 0 0; padding: 8px 10px; background: var(--bg); border-radius: 8px; font-size: 12.5px; color: var(--muted); }
.events div + div { margin-top: 3px; }

.badge { display: inline-block; font-size: 12.5px; font-weight: 600; padding: 1px 9px; border-radius: 999px; background: var(--line); color: var(--ink); white-space: nowrap; }
.b-due { background: var(--blue-bg); color: var(--forest-2); }
.b-overdue { background: var(--red-bg); color: var(--red); }
.b-upcoming { background: #eef0f3; color: var(--muted); }
.b-ok, .b-live, .b-sent, .b-answered, .b-done { background: var(--green-bg); color: var(--green); }
.b-warn, .b-pending, .b-queued, .b-setup, .b-partial, .b-awaiting_verification { background: var(--accent-bg); color: #7d5a1e; }
.b-failed, .b-removed { background: var(--red-bg); color: var(--red); }
.b-gold { background: var(--gold-bg); color: #7a5b12; }
.b-green { background: var(--green-bg); color: var(--green); }

/* Buttons & forms */
.btn { border: 1px solid #cfd5cd; background: #fff; color: var(--ink); padding: 7px 14px; border-radius: 6px; cursor: pointer; font-size: 14.5px; font-weight: 600; }
.btn:hover { border-color: #aab4ab; background: #fbfaf7; }
.btn.primary { background: var(--forest); border-color: var(--forest); color: #fff; }
.btn.primary:hover { background: var(--forest-2); border-color: var(--forest-2); }
.btn.small { padding: 3px 10px; font-size: 13.5px; }
.btn.ghost { border-color: transparent; background: transparent; color: var(--forest-2); }
.btn.ghost:hover { background: rgba(31,58,46,.06); }
.btn:disabled { opacity: .5; cursor: default; }
label { display: block; font-size: 13.5px; color: var(--muted); font-weight: 600; margin: 10px 0 4px; }
input[type=text], input[type=password], input[type=email], input[type=number], input[type=date], input[type=month], input[type=datetime-local], select, textarea {
  width: 100%; border: 1px solid #cfd5cd; border-radius: 6px; padding: 8px 10px; background: #fff; color: var(--ink); }
textarea { min-height: 80px; resize: vertical; }
.inline { display: flex; gap: 8px; align-items: end; flex-wrap: wrap; }
.inline > * { flex: 1; min-width: 120px; }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg button { border: 1px solid #cfd5cd; background: #fff; border-radius: 18px; padding: 5px 12px; cursor: pointer; font-size: 13.5px; }
.seg button.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 4px; }
.chips button { border: 1px solid var(--line); background: #fff; border-radius: 16px; padding: 4px 12px; cursor: pointer; font-size: 13px; }
.chips button.on { background: var(--forest); color: #fff; border-color: var(--forest); }

/* Tables */
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
th { text-align: left; font-size: 13px; font-weight: 600; color: var(--muted); padding: 9px 12px; border-bottom: 1px solid var(--line); background: #faf9f5; }
td { padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
tbody tr:hover td, table tr:hover td { background: #fbfaf6; }
tr:last-child td { border-bottom: 0; }
.num { text-align: right; white-space: nowrap; }
.tablewrap { overflow-x: auto; }

/* Phone frame for RYZO's dashboard */
.phone { max-width: 560px; margin: 0 auto; }
.phone .hero { background: var(--navy); color: #fff; border-radius: 14px; padding: 16px; margin-bottom: 14px; }
.phone .hero p { margin: 4px 0 0; color: #cfdbea; font-size: 14px; }
.phone .hero .big { font-size: 30px; font-weight: 750; line-height: 1; }
.tabs { display: flex; gap: 4px; background: #ebe8df; border-radius: 10px; padding: 3px; margin-bottom: 8px; }
.tabs button { flex: 1; border: 0; background: transparent; padding: 8px 4px; border-radius: 8px; font-size: 14px; font-weight: 600; color: var(--muted); cursor: pointer; }
.tabs button.on { background: #fff; color: var(--forest); box-shadow: 0 1px 2px rgba(20,35,28,.12); }

/* SMS */
.sms { max-width: 420px; background: #fff; border: 1px solid var(--line); border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); }
.sms .bar { background: #f3f4f6; padding: 10px 14px; text-align: center; font-size: 13px; border-bottom: 1px solid var(--line); }
.sms .thread { height: 520px; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; background: #fff; }
.bubble { max-width: 82%; padding: 8px 12px; border-radius: 16px; font-size: 14px; white-space: pre-wrap; }
.bubble.in { align-self: flex-end; background: #2b7cf6; color: #fff; border-bottom-right-radius: 4px; }
.bubble.out { align-self: flex-start; background: #e9e9eb; color: #111; border-bottom-left-radius: 4px; }
.bubble.failed { background: var(--red-bg); color: var(--red); }
.bubble-meta { font-size: 11px; color: var(--faint); margin-top: -4px; }
.bubble-meta.in { align-self: flex-end; } .bubble-meta.out { align-self: flex-start; }
.sms form { display: flex; gap: 6px; padding: 10px; border-top: 1px solid var(--line); }
.sms form input { border-radius: 18px; }

/* Modal & toast */
.modal-bg { position: fixed; inset: 0; background: rgba(16, 28, 22, .45); display: flex; align-items: flex-start; justify-content: center; padding: 40px 12px; z-index: 50; overflow-y: auto; }
.modal { background: #fff; border-radius: 10px; width: 100%; max-width: 500px; padding: 20px 22px; box-shadow: var(--lift); border-top: 3px solid var(--brass); }
.modal h2 { margin-bottom: 4px; } .modal .sub { color: var(--muted); font-size: 13.5px; margin-bottom: 6px; }
.modal .foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: var(--forest); color: #fff; padding: 10px 16px; border-radius: 9px; font-size: 14px; z-index: 60; max-width: 90vw; box-shadow: 0 6px 20px rgba(0,0,0,.2); }
.toast.err { background: var(--red); }
.note { background: var(--accent-bg); border: 1px solid #ead7b1; border-radius: 8px; padding: 10px 13px; font-size: 14.5px; color: #6b4f1f; margin-bottom: 12px; }
.note.info { background: var(--blue-bg); border-color: #cbdad1; color: var(--forest); }
.kv { display: grid; grid-template-columns: 120px 1fr; gap: 4px 10px; font-size: 14px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; }
.muted { color: var(--muted); } .faint { color: var(--faint); font-size: 13.5px; }
.flow-steps { counter-reset: s; list-style: none; padding: 0; margin: 0; }
.flow-steps li { counter-increment: s; position: relative; padding: 0 0 12px 34px; font-size: 14px; }
.flow-steps li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--forest); color: #fff; font-size: 12px; font-weight: 700; display: grid; place-items: center; }
.owner { font-size: 13.5px; font-weight: 700; color: var(--brass-deep); }
.linkrow { display: flex; gap: 8px; flex-wrap: wrap; }
.linkrow a { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; font-weight: 600; font-size: 14px; }
@media (max-width: 600px) {
  .top-in { gap: 6px 12px; padding: 8px 12px; }
  .nav { order: 3; flex: 0 0 100%; flex-wrap: nowrap; overflow-x: auto; }
  .nav a { white-space: nowrap; }
  .who { margin-left: auto; } .who select { max-width: 150px; }
  main { padding: 14px 10px 50px; }
}

.page-head .inline > select { min-width: 160px; flex: 0 0 auto; width: auto; }
.page-head .inline > .btn { flex: 0 0 auto; min-width: 0; }

/* Donors list and profile (laid out like the Individual Donor Report) */
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px 14px; }
.form-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.form-grid label.check { flex-direction: row; align-items: center; gap: 8px; color: var(--ink); }
.form-grid input:not([type=checkbox]) { padding: 7px 9px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); }
.linkbtn { background: none; border: 0; padding: 0; color: var(--navy-2); cursor: pointer; font-size: 13px; }
.linkbtn.danger, .btn.danger { color: var(--red); }
.donor-table td { vertical-align: top; }
.donor-table td:nth-child(2), .donor-table td:nth-child(4) { white-space: nowrap; }
.report { --kkb: #203a2e; --kkb-gold: #b8935a; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 22px 14px; }
.rep-band { display: flex; align-items: center; gap: 16px; background: var(--kkb); color: #fff; border-radius: 8px; padding: 8px 12px; }
.rep-band img { width: 54px; height: 54px; border-radius: 4px; background: #f3efe6; }
.rep-title { font-family: var(--serif); font-weight: 600; font-size: 24px; letter-spacing: .3px; }
.rep-sub { font-size: 13px; opacity: .9; }
.rep-name { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin: 14px 0 4px; flex-wrap: wrap; }
.rep-name h1 { font-size: 32px; color: var(--kkb); }
.rep-id { font-size: 13px; color: var(--muted); font-weight: 600; } .rep-id span { font-weight: 400; }
.rep-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 10px; }
.rep-two { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.rep-line { font-size: 14px; margin: 2px 0; }
.rep-h { font-size: 15px; font-weight: 800; letter-spacing: .4px; color: var(--kkb); margin: 14px 0 2px; }
.rep-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.t-label { font-size: 13px; color: var(--muted); } .t-val { font-size: 21px; color: var(--kkb); } .t-sub { font-size: 11.5px; color: var(--muted); }
.rep-box { border-bottom: 1px solid #cfd4cf; padding: 6px 0 8px; font-size: 13.5px; min-height: 30px; }
.rep-input { width: 100%; border: 0; border-bottom: 1px solid #cfd4cf; padding: 6px 0; font-size: 14px; background: transparent; resize: vertical; }
.rep-input:focus { outline: none; border-bottom-color: var(--kkb-gold); }
.rep-follow { display: grid; grid-template-columns: 3fr 1.3fr 1fr; gap: 24px; align-items: start; }
.note-form { display: flex; flex-direction: column; gap: 6px; margin: 6px 0 8px; padding: 8px; background: #f7f5ef; border-radius: 8px; }
.note-form input[type=date], .note-form select { width: auto; }
.note-form input, .note-form select, .note-form textarea { padding: 6px 8px; border: 1px solid var(--line); border-radius: 6px; }
.note-row { padding: 7px 0; border-bottom: 1px solid #e6e8e4; font-size: 14px; }
.note-text { white-space: pre-wrap; }
.rep-table { width: 100%; border-collapse: collapse; margin-top: 4px; font-size: 13.5px; }
.rep-table th { background: var(--kkb); color: #fff; text-align: left; padding: 6px 8px; font-weight: 600; }
.rep-table td { border: 1px solid #d9dcd6; padding: 5px 8px; }
.rep-table tr:nth-child(odd) td { background: #f7f6f2; }
.rep-table tr.nocount td { color: var(--faint); }
.rep-table tr.total td { background: #efece3; font-weight: 700; }
.rep-table .num { text-align: right; }
.rep-foot { border-top: 1px solid var(--kkb-gold); margin-top: 18px; padding-top: 6px; font-size: 11px; color: var(--muted); }
@media (max-width: 760px) { .rep-two, .rep-follow { grid-template-columns: 1fr; } .rep-tiles { grid-template-columns: 1fr 1fr; } .rep-title { font-size: 18px; } }
@media print {
  @page { size: letter landscape; margin: .35in; }
  body { background: #fff; }
  .top, .no-print, #toast, .demo-band { display: none !important; }
  main, .wrap { padding: 0 !important; max-width: none !important; }
  .report { box-shadow: none; padding: 0; }
  .rep-band, .rep-table th, .rep-table td, .rep-table tr.total td { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .rep-input { border-bottom: 1px solid #bbb; }
  .rep-table tr { break-inside: avoid; }
}

.rep-more summary { cursor: pointer; color: var(--navy-2); font-size: 13px; margin-top: 4px; }

.subtabs { display: flex; gap: 4px; width: 100%; border-bottom: 1px solid var(--line); }
.subtab { background: none; border: 0; border-bottom: 2px solid transparent; padding: 6px 10px; cursor: pointer; color: var(--muted); font-size: 13.5px; }
.subtab.on { color: var(--ink); border-bottom-color: var(--navy); font-weight: 600; }
.stage-why { font-size: 12.5px; margin-top: 3px; color: var(--muted); }
.roster-row { display: flex; gap: 10px; align-items: center; padding: 4px 0; font-size: 14px; border-bottom: 1px solid var(--line); }
.roster-row select { padding: 4px 6px; border: 1px solid var(--line); border-radius: 6px; }

th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
th.sortable:hover { color: var(--ink); }
th.sortable .arrow { margin-left: 4px; font-size: 10px; opacity: .35; }
th.sortable.on .arrow { opacity: 1; color: var(--navy-2); }

.backbar { margin: 0 0 10px; }
.clean-row { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; }
.clean-head { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: baseline; }
.clean-have { margin: 4px 0 6px; font-size: 13px; }
.clean-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.clean-form label { display: flex; flex-direction: column; font-size: 12px; color: var(--muted, #667); gap: 2px; flex: 1 1 160px; }
.clean-form label.wide { flex: 2 1 240px; }
.clean-form label.narrow { flex: 0 1 80px; }
.clean-form input, .aside-box input { padding: 6px 8px; border: 1px solid var(--line); border-radius: 6px; font: inherit; font-size: 14px; }
.clean-acts { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; width: 100%; margin-top: 2px; }
.aside-box { display: inline-flex; gap: 6px; margin-left: auto; }
.aside-box input { width: 170px; }
.btn .count { opacity: .7; margin-left: 4px; }
/* KKB assistant panel */
.ai-fab { position: fixed; right: 20px; bottom: 20px; z-index: 40; background: var(--forest); border: 2px solid var(--brass) !important; color: #fff; border: 0; border-radius: 999px; padding: 11px 18px; font: inherit; font-weight: 600; box-shadow: 0 6px 20px rgba(0,0,0,.18); cursor: pointer; display: flex; align-items: center; gap: 8px; }
.ai-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--brass); display: inline-block; }
.ai-panel { position: fixed; top: 0; right: 0; bottom: 0; width: min(420px, 100vw); background: #fff; box-shadow: -8px 0 30px rgba(0,0,0,.15); z-index: 50; display: none; flex-direction: column; }
.ai-panel.open { display: flex; }
.ai-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); gap: 8px; }
.ai-sub { font-size: 12px; color: var(--muted, #667); }
.ai-thread { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; background: var(--bg, #f4f5f7); }
.ai-msg { max-width: 88%; padding: 9px 12px; border-radius: 12px; font-size: 14px; line-height: 1.45; }
.ai-msg.a { background: #fff; border: 1px solid var(--line); align-self: flex-start; }
.ai-msg.u { background: var(--forest); color: #fff; align-self: flex-end; }
.ai-msg.error { border-color: #f1b5b5; background: #fff5f5; }
.ai-msg.pending { color: var(--muted, #667); }
.ai-acts { margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px; }
.ai-acts span { font-size: 12px; background: #e8f5ec; color: #1d6b3a; border-radius: 6px; padding: 2px 6px; }
.ai-note { font-size: 13px; align-self: center; }
.ai-form { display: flex; gap: 8px; padding: 10px; border-top: 1px solid var(--line); }
.ai-form textarea { flex: 1; resize: none; font: inherit; font-size: 14px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; }
@media print { .ai-fab, .ai-panel, #backslot { display: none !important; } }
.steps { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.step { display: flex; gap: 10px; align-items: center; text-align: left; border: 1px solid var(--line); background: #fff; border-radius: 12px; padding: 10px 12px; font: inherit; cursor: pointer; }
.step .n { width: 26px; height: 26px; border-radius: 50%; background: var(--bg, #eef1f5); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; flex: none; }
.step b { display: block; font-size: 15.5px; font-family: var(--serif); font-weight: 600; color: var(--forest); } .step small { display: block; color: var(--muted, #667); font-size: 12px; }
.step.on { border-color: var(--forest); box-shadow: 0 0 0 1px var(--forest); }
.step.on .n { background: var(--forest); color: #fff; }
.step.done .n { background: var(--brass); color: #fff; }
.progress { height: 6px; background: var(--bg, #eef1f5); border-radius: 4px; overflow: hidden; margin-bottom: 10px; }
.progress div { height: 100%; background: var(--brass); }
.panel.folded .ph { border-bottom: 0; }
.note.ok { background: #eaf6ee; border-color: #bfe3cb; color: #1d5e36; }
#backslot { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
#backslot .backbar { margin: 14px 0 -8px; }

/* Report Card and other section headings carry a brass mark, so long pages read as a set of named lists. */
.panel > .ph h2 { padding-left: 10px; border-left: 3px solid var(--brass); }
.panel.folded > .ph h2 { border-left-color: var(--line); }
.page-head h1 + p { font-size: 15.5px; }

/* Section toggles (Report Card, Reports, Flows): shown sections are marked, hidden ones fade. */
.foldchip { border: 1px solid #cfd5cd; background: #fff; color: var(--forest); border-radius: 999px; padding: 3px 11px; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.foldchip::before { content: "✓ "; color: var(--brass-deep); }
.foldchip.off { color: var(--faint); background: transparent; border-style: dashed; }
.foldchip.off::before { content: ""; }
.foldchip .count { color: var(--muted); font-weight: 500; margin-left: 3px; }
@media (max-width: 600px) {
  main { padding-bottom: 110px; }
  .ai-fab { right: 12px; bottom: 12px; padding: 10px 14px; }
  .ai-fab .ai-label { display: none; }
  .ai-fab::after { content: "Ask"; }
}
