/* CBA Practice Lab - styles. Brand: off-white, ink, lime. No build step. */
:root {
  --bg: #FCFCFC;
  --paper: #FFFFFF;
  --ink: #101D26;
  --ink-2: #33414B;
  --muted: #5E676D;
  --gray: #9DA3A5;
  --line: #D5D8D8;
  --line-2: #E5E6E6;
  --soft: #F3F4F4;
  --lime: #9EDB2B;
  --lime-600: #86C21C;
  --green-text: #4A7310;
  --pale: #EBFAD6;
  --pale-2: #E4F8C7;
  --bad: #B42318;
  --bad-bg: #FDEDEB;
  --bad-line: #F4C4BE;
  --warn: #8A5A00;
  --warn-bg: #FFF6DC;
  --tip-bg: #EEF4F8;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(16, 29, 38, .06), 0 4px 16px rgba(16, 29, 38, .05);
  --font: 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --font-head: 'Montserrat', 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --mono: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--ink); text-decoration-color: var(--lime-600); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--green-text); }
h1, h2, h3 { font-family: var(--font-head); font-weight: 800; line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.35rem); }
h2 { font-size: clamp(1.25rem, 1.1rem + .6vw, 1.55rem); }
h3 { font-size: 1.08rem; }
p { margin: 0 0 .8em; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.muted { color: var(--muted); }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
:focus-visible { outline: 3px solid var(--lime-600); outline-offset: 2px; }

.skip-link { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 12px; border-radius: 6px; z-index: 50; }
.skip-link:focus { left: 8px; color: #fff; }

.wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }

/* ---------- Header / footer ---------- */
.site-header { background: var(--paper); border-bottom: 1px solid var(--line-2); position: sticky; top: 0; z-index: 20; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font-family: var(--font-head); font-weight: 800; font-size: 1.05rem; }
.brand-sub { font-size: .78rem; color: var(--muted); font-weight: 600; }
.site-nav { display: flex; gap: 4px; }
.site-nav a { text-decoration: none; font-weight: 700; font-size: .92rem; padding: 8px 12px; border-radius: 999px; color: var(--ink-2); }
.site-nav a:hover { background: var(--soft); color: var(--ink); }
.site-nav a.active { background: var(--pale); color: var(--ink); }
.nav-short { display: none; }

main { padding-top: 28px; padding-bottom: 56px; min-height: 60vh; }
main:focus { outline: none; }

.site-footer { border-top: 1px solid var(--line-2); background: var(--paper); padding: 20px 0 28px; font-size: .9rem; color: var(--ink-2); }
.footer-inner p { margin: 0 0 4px; }
.footer-small { color: var(--muted); font-size: .82rem; }
.link-btn { background: none; border: 0; padding: 0; color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--gray); cursor: pointer; font-size: inherit; }
.link-btn:hover { color: var(--bad); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 40px; padding: 8px 16px;
  border: 1.5px solid var(--line); border-radius: 999px;
  background: var(--paper); color: var(--ink);
  font-weight: 700; font-size: .95rem; line-height: 1.1;
  cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: background .12s, border-color .12s, transform .06s;
}
.btn:hover { border-color: var(--gray); background: var(--soft); color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn .icon svg { width: 18px; height: 18px; }
.btn-primary { background: var(--lime); border-color: var(--lime); color: var(--ink); }
.btn-primary:hover { background: var(--lime-600); border-color: var(--lime-600); }
.btn-dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-dark:hover { background: #22323d; border-color: #22323d; color: #fff; }
.btn-quiet { border-color: transparent; background: transparent; }
.btn-quiet:hover { background: var(--soft); border-color: transparent; }
.btn-sm { min-height: 32px; padding: 5px 12px; font-size: .85rem; }
.icon { display: inline-flex; flex: none; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 8px; border: 0; background: transparent; color: var(--muted); cursor: pointer; }
.icon-btn:hover { background: var(--soft); color: var(--bad); }
.icon-btn:disabled { opacity: .4; cursor: not-allowed; }

/* ---------- Common blocks ---------- */
.card { background: var(--paper); border: 1px solid var(--line-2); border-radius: var(--radius); box-shadow: var(--shadow); }
.pill { display: inline-flex; align-items: center; gap: 4px; font-size: .75rem; font-weight: 800; letter-spacing: .02em; padding: 3px 9px; border-radius: 999px; background: var(--soft); color: var(--ink-2); white-space: nowrap; }
.pill.green { background: var(--pale); color: var(--green-text); }
.pill.dark { background: var(--ink); color: #fff; }
.pill.outline { background: transparent; border: 1px solid var(--line); }
.eyebrow { display: inline-block; font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--green-text); margin-bottom: 6px; }
.lead { font-size: 1.08rem; color: var(--ink-2); max-width: 70ch; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: .88rem; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--muted); font-weight: 700; }
.crumbs .sep { color: var(--gray); }
.laptop-note { display: none; align-items: flex-start; gap: 10px; background: var(--tip-bg); border-radius: var(--radius-sm); padding: 10px 12px; font-size: .9rem; margin: 0 0 16px; }
.noscript { background: var(--warn-bg); padding: 12px; border-radius: 8px; }
.callout { display: flex; gap: 10px; align-items: flex-start; background: var(--pale); border-radius: var(--radius-sm); padding: 12px 14px; font-size: .95rem; }
.callout.gray { background: var(--soft); }
.callout .icon { color: var(--green-text); margin-top: 2px; }
.callout p:last-child { margin-bottom: 0; }

/* ---------- Home ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 28px; align-items: center; margin-bottom: 36px; }
.hero h1 { margin-bottom: 10px; }
.hero-church { padding: 20px 22px; }
.hero-church h2 { font-size: 1.05rem; margin-bottom: 6px; }
.hero-church p { font-size: .93rem; color: var(--ink-2); }
.hero-church .facts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.hero-steps { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 14px; padding: 0; list-style: none; font-weight: 700; font-size: .93rem; }
.hero-steps li { display: flex; align-items: center; gap: 6px; }
.hero-steps .dot { width: 24px; height: 24px; border-radius: 50%; background: var(--lime); display: inline-flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 800; }

.course { margin-bottom: 40px; }
.course-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 2px solid var(--ink); }
.course-head h2 { margin: 0; }
.course-head p { margin: 4px 0 0; color: var(--muted); }
.progress { display: flex; align-items: center; gap: 10px; min-width: 220px; }
.progress-bar { flex: 1; height: 10px; background: var(--line-2); border-radius: 999px; overflow: hidden; min-width: 120px; }
.progress-bar > span { display: block; height: 100%; background: var(--lime); border-radius: 999px; }
.progress-label { font-size: .85rem; font-weight: 800; white-space: nowrap; }
.sub-head { font-size: .8rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 22px 0 10px; display: flex; align-items: center; gap: 8px; }
.sub-head .icon svg { width: 16px; height: 16px; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.lesson-card { display: flex; flex-direction: column; gap: 8px; padding: 16px 16px 14px; text-decoration: none; color: var(--ink); transition: border-color .12s, transform .12s, box-shadow .12s; }
.lesson-card:hover { border-color: var(--lime-600); transform: translateY(-2px); color: var(--ink); }
.lesson-card .lc-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.lesson-card .lc-no { font-size: .78rem; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.lesson-card h3 { margin: 0; font-size: 1.02rem; }
.lesson-card p { margin: 0; font-size: .88rem; color: var(--ink-2); }
.lesson-card .lc-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 8px; font-size: .85rem; font-weight: 700; color: var(--muted); }
.lesson-card .lc-go { color: var(--ink); display: inline-flex; align-items: center; gap: 4px; }
.lesson-card.sim { background: linear-gradient(180deg, var(--pale) 0, var(--paper) 70px); }
.lesson-card.sim .lc-ico { width: 34px; height: 34px; border-radius: 9px; background: var(--ink); color: var(--lime); display: inline-flex; align-items: center; justify-content: center; }
.mini-bar { height: 6px; background: var(--line-2); border-radius: 999px; overflow: hidden; }
.mini-bar > span { display: block; height: 100%; background: var(--lime); }
.done-badge { display: inline-flex; align-items: center; gap: 3px; color: var(--green-text); font-weight: 800; }
.done-badge .icon svg { width: 16px; height: 16px; }

/* ---------- Page head for practice screens ---------- */
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px 24px; margin-bottom: 18px; }
.page-head h1 { margin: 0; font-size: clamp(1.4rem, 1.1rem + 1.2vw, 2rem); }
.page-head .sub { color: var(--muted); margin: 4px 0 0; }
.page-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.select { min-height: 40px; padding: 6px 34px 6px 12px; border: 1.5px solid var(--line); border-radius: 999px; background: var(--paper) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23101D26' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 12px center; appearance: none; font-weight: 700; font-size: .92rem; max-width: 100%; }

/* ---------- JE Builder layout ---------- */
.q-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-bottom: 14px; }
.q-dots { display: flex; flex-wrap: wrap; gap: 6px; }
.q-dot { width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--line); background: var(--paper); font-weight: 800; font-size: .8rem; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; color: var(--ink-2); padding: 0; }
.q-dot:hover { border-color: var(--gray); }
.q-dot.current { border-color: var(--ink); background: var(--ink); color: #fff; }
.q-dot.done { background: var(--lime); border-color: var(--lime); color: var(--ink); }
.q-dot.done.current { box-shadow: 0 0 0 3px var(--ink); }
.q-dot.tried { border-color: var(--gray); border-style: dashed; }
.q-count { font-weight: 800; font-size: .92rem; }
.q-arrows { display: flex; gap: 6px; margin-left: auto; }

.scenario { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 18px; margin-bottom: 18px; }
.scenario.no-doc { grid-template-columns: minmax(0, 1fr); }
.prompt-card { padding: 18px 20px; }
.prompt-card .q-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.prompt-card h2 { font-size: 1.2rem; margin-bottom: 8px; }
.prompt-card .prompt { font-size: 1.04rem; margin-bottom: 12px; }
.prompt-card .given { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: .88rem; color: var(--muted); border-top: 1px dashed var(--line); padding-top: 10px; }
.prompt-card .given b { color: var(--ink); }
.status-line { display: inline-flex; align-items: center; gap: 6px; font-size: .85rem; font-weight: 800; }
.status-line.done { color: var(--green-text); }

/* Source document card */
.doc-card { margin: 0; background: #FFFEF8; border: 1px solid #E8E4D4; border-radius: 6px; padding: 16px 18px 14px; box-shadow: 0 1px 0 #EEEADB, 0 6px 18px rgba(16, 29, 38, .06); font-size: .9rem; position: relative; align-self: start; }
.doc-card::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: repeating-linear-gradient(90deg, var(--lime) 0 14px, transparent 14px 20px); border-radius: 6px 6px 0 0; opacity: .8; }
.doc-kind { font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.doc-title { font-family: var(--font-head); font-weight: 800; font-size: 1.02rem; margin: 2px 0 0; }
.doc-from { color: var(--ink-2); margin-bottom: 8px; }
.doc-meta { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; margin: 0 0 8px; font-size: .84rem; }
.doc-meta dt { color: var(--muted); }
.doc-meta dd { margin: 0; }
.doc-lines { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.doc-lines td { padding: 4px 0; border-bottom: 1px dotted #DAD5C3; }
.doc-total { display: flex; justify-content: space-between; font-weight: 800; padding-top: 6px; border-top: 2px solid var(--ink); margin-top: 4px; }
.doc-note { margin-top: 8px; font-size: .82rem; color: var(--ink-2); font-style: italic; }

/* ---------- Journal entry form (practice) ---------- */
.je-practice { margin-bottom: 8px; }
.je-form { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: visible; }
.je-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px 20px; padding: 14px 18px; border-bottom: 1px solid var(--line-2); background: #FAFBFB; border-radius: var(--radius) var(--radius) 0 0; }
.je-title { display: flex; align-items: center; gap: 8px; font-family: var(--font-head); font-weight: 800; font-size: 1.15rem; }
.practice-tag { font-family: var(--font); font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; background: var(--pale); color: var(--green-text); border-radius: 999px; padding: 2px 8px; }
.je-meta { display: flex; gap: 12px; flex-wrap: wrap; }
.field { display: flex; flex-direction: column; gap: 4px; font-size: .8rem; font-weight: 700; color: var(--ink-2); }
.field input, .field select, .field textarea { font-size: .95rem; font-weight: 600; color: var(--ink); border: 1px solid var(--line); border-radius: 6px; padding: 7px 10px; background: var(--paper); min-height: 38px; }
.field input:disabled { background: var(--soft); color: var(--ink-2); }
.field.small input { width: 110px; }
.je-date { width: 170px; }
.je-date.need { border-color: var(--lime-600); box-shadow: 0 0 0 3px var(--pale-2); }
.je-table-wrap { padding: 4px 8px 0; }
.je-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.je-table th { text-align: left; font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 10px 6px 8px; border-bottom: 1px solid var(--line); }
.je-table td { padding: 6px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.je-table .c-num { width: 34px; text-align: center; color: var(--muted); font-weight: 700; font-size: .85rem; }
.je-table .c-acct { width: 28%; }
.je-table .c-amt { width: 12%; }
.je-table th.c-amt { text-align: right; }
.je-table .c-desc { width: 18%; }
.je-table .c-name { width: 13%; }
.je-table .c-class { width: 14%; }
.je-table .c-del { width: 42px; text-align: center; }
.je-row.row-bad td { background: var(--bad-bg); }
.je-row.row-bad td:first-child { box-shadow: inset 4px 0 0 var(--bad); }
.je-row.row-good td { background: #F6FCEC; }
.je-row.row-good td:first-child { box-shadow: inset 4px 0 0 var(--lime-600); }
.je-msg td { padding: 0 8px 10px 44px; border-bottom: 1px solid var(--line-2); background: var(--bad-bg); }
.je-msg.tip-only td { background: var(--tip-bg); }
.row-note { display: flex; gap: 6px; align-items: flex-start; font-size: .88rem; font-weight: 600; padding-top: 2px; }
.row-note.bad { color: var(--bad); }
.row-note.tip { color: var(--ink-2); font-weight: 500; }
.row-note .icon svg { width: 17px; height: 17px; margin-top: 1px; }
.amt-input, .txt-input, .acct-input, .class-select {
  width: 100%; min-height: 38px; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); padding: 6px 8px; font-size: .92rem;
}
.amt-input { text-align: right; font-variant-numeric: tabular-nums; }
.amt-input:focus, .txt-input:focus, .acct-input:focus, .class-select:focus { border-color: var(--ink); outline: 2px solid var(--pale-2); outline-offset: 0; }
.class-select { padding-right: 4px; }
.je-table tfoot td { border-bottom: 0; padding-top: 10px; padding-bottom: 12px; font-weight: 800; }
.tot-label { text-align: right; color: var(--muted); font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; }
.c-amt.tot { text-align: right; font-variant-numeric: tabular-nums; padding-right: 10px; }
.bal-state { padding-left: 10px; }
.bal-chip { display: inline-flex; align-items: center; gap: 4px; font-size: .82rem; font-weight: 800; padding: 3px 10px; border-radius: 999px; }
.bal-chip .icon svg { width: 16px; height: 16px; }
.bal-chip.ok { background: var(--pale); color: var(--green-text); }
.bal-chip.warn { background: var(--warn-bg); color: var(--warn); }
.bal-chip.muted { background: var(--soft); color: var(--muted); }
.je-tools { display: flex; gap: 8px; padding: 4px 14px 14px; flex-wrap: wrap; }
.je-form.locked .je-tools, .je-form.locked .c-del .icon-btn { visibility: hidden; }
.je-form.locked input, .je-form.locked select { background: #FAFBFB; }

/* Account combobox */
.acct-combo { position: relative; }
.acct-input { padding-right: 26px; background: var(--paper) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7' viewBox='0 0 10 7'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%235E676D' stroke-width='1.8'/%3E%3C/svg%3E") no-repeat right 9px center; text-overflow: ellipsis; }
.acct-list { position: absolute; z-index: 30; top: calc(100% + 4px); left: 0; width: max(100%, 340px); max-height: 300px; overflow-y: auto; margin: 0; padding: 4px 0; list-style: none; background: var(--paper); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 10px 30px rgba(16, 29, 38, .16); }
.acct-group { font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding: 8px 12px 4px; background: #FAFBFB; position: sticky; top: -4px; }
.acct-opt { display: flex; justify-content: space-between; gap: 10px; padding: 7px 12px; cursor: pointer; font-size: .9rem; }
.acct-opt.active, .acct-opt:hover { background: var(--pale); }
.acct-opt[aria-selected='true'] { font-weight: 700; }
.acct-opt-type { color: var(--muted); font-size: .78rem; white-space: nowrap; }
.acct-empty { padding: 10px 12px; color: var(--muted); font-size: .88rem; }

/* Action bar + feedback */
.action-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; margin: 14px 0 0; }
.action-left, .action-right { display: flex; flex-wrap: wrap; gap: 8px; }
.fb-region:empty { display: none; }
.fb { border-radius: var(--radius); padding: 14px 16px; margin-top: 14px; border: 1.5px solid; }
.fb-good { background: var(--pale); border-color: var(--lime-600); }
.fb-bad { background: var(--bad-bg); border-color: var(--bad-line); }
.fb-head { display: flex; align-items: center; gap: 8px; font-size: 1.05rem; }
.fb-good .fb-icon { color: var(--green-text); }
.fb-bad .fb-icon { color: var(--bad); }
.fb-list { margin: 8px 0 0; padding-left: 22px; }
.fb-list li { margin-bottom: 3px; }
.fb-sub { margin: 6px 0 0; font-size: .92rem; color: var(--ink-2); }
.fb-why { margin-top: 10px; background: rgba(255, 255, 255, .7); border-radius: 8px; padding: 10px 12px; }
.fb-why p { margin: 0; }
.why-label { display: block; font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--green-text); margin-bottom: 2px; }
.fb-next { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.hint-box { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; background: var(--warn-bg); border-radius: var(--radius-sm); padding: 12px 14px; }
.hint-box[hidden] { display: none; }
.hint-box .icon { color: var(--warn); }
.hint-box p { margin: 0; }
.answer-box { margin-top: 14px; border: 1.5px dashed var(--gray); border-radius: var(--radius); padding: 14px 16px; background: var(--paper); }
.answer-box[hidden] { display: none; }
.answer-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.table-scroll { overflow-x: auto; }
.answer-table { width: 100%; border-collapse: collapse; margin-bottom: 10px; font-size: .93rem; }
.answer-table th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); border-bottom: 1px solid var(--line); padding: 6px; }
.answer-table td { padding: 6px; border-bottom: 1px solid var(--line-2); }
.answer-table th.num, .answer-table td.num { text-align: right; }
.answer-date { font-size: .9rem; font-weight: 700; }

/* ---------- Sims: steps ---------- */
.sim-intro { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: start; margin-bottom: 18px; }
.steps { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; padding: 0; list-style: none; }
.steps li { display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border-radius: 999px; background: var(--soft); font-weight: 700; font-size: .88rem; color: var(--muted); }
.steps li .n { width: 24px; height: 24px; border-radius: 50%; background: var(--paper); border: 1.5px solid var(--line); display: inline-flex; align-items: center; justify-content: center; font-size: .78rem; font-weight: 800; }
.steps li.current { background: var(--ink); color: #fff; }
.steps li.current .n { background: var(--lime); border-color: var(--lime); color: var(--ink); }
.steps li.done { background: var(--pale); color: var(--green-text); }
.steps li.done .n { background: var(--lime); border-color: var(--lime); color: var(--ink); }
.step-panel { padding: 18px 20px; margin-bottom: 18px; }
.step-panel.locked { opacity: .55; }
.step-panel.done > h2 .n { background: var(--ink); color: var(--lime); }
.step-panel > h2 { font-size: 1.15rem; display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.step-panel > h2 .n { width: 28px; height: 28px; border-radius: 50%; background: var(--lime); display: inline-flex; align-items: center; justify-content: center; font-size: .85rem; flex: none; }
.step-panel.locked > h2 .n { background: var(--line-2); }
.step-panel .task { color: var(--ink-2); margin-bottom: 12px; }
.step-done-note { display: inline-flex; align-items: center; gap: 6px; color: var(--green-text); font-weight: 800; font-size: .9rem; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; margin-bottom: 12px; }
.form-grid .wide { grid-column: span 2; }
.field .bad-field { border-color: var(--bad); background: var(--bad-bg); }
.field .good-field { border-color: var(--lime-600); background: #F6FCEC; }
.field-note { font-size: .8rem; font-weight: 600; color: var(--bad); }

/* Spreadsheet-like schedules */
.sheet-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); -webkit-overflow-scrolling: touch; }
.sheet { border-collapse: collapse; width: 100%; font-size: .88rem; font-variant-numeric: tabular-nums; }
.sheet caption { text-align: left; padding: 12px 12px 8px; font-weight: 800; }
.sheet caption .sheet-sub { display: block; font-weight: 600; color: var(--muted); font-size: .82rem; }
.sheet th { background: var(--ink); color: #fff; font-weight: 800; font-size: .76rem; text-transform: none; padding: 8px 8px; text-align: left; white-space: nowrap; border-right: 1px solid #2A3944; }
.sheet th.num { text-align: right; }
.sheet th.cur { background: #2B3F18; box-shadow: inset 0 -3px 0 var(--lime); }
.sheet td { padding: 6px 8px; border-bottom: 1px solid var(--line-2); border-right: 1px solid var(--line-2); white-space: nowrap; }
.sheet td.wrap-cell { white-space: normal; min-width: 170px; }
.sheet td.cur { background: #F6FCEC; }
.sheet tr.new-row td { background: var(--pale); }
.sheet tr.total td { font-weight: 800; border-top: 2px solid var(--ink); background: #FAFBFB; }
.sheet tr.books td { background: #FAFBFB; }
.sheet tr.tie td { font-weight: 800; }
.sheet .tie-ok { color: var(--green-text); }
.sheet .tie-bad { color: var(--bad); }
.sheet td.input-cell { padding: 3px 4px; }
.sheet td.input-cell input { width: 110px; min-height: 32px; border: 1px solid var(--lime-600); border-radius: 5px; text-align: right; padding: 4px 6px; font-variant-numeric: tabular-nums; background: #FFFFF4; }
.sheet td.input-cell input.bad-field { border-color: var(--bad); background: var(--bad-bg); }
.sheet td.input-cell input.good-field { border-color: var(--lime-600); background: #F1FADF; }
.sheet td.input-cell select { min-height: 32px; border: 1px solid var(--lime-600); border-radius: 5px; padding: 3px 6px; background: #FFFFF4; }
.sheet td.coding { font-size: .8rem; color: var(--ink-2); white-space: normal; min-width: 130px; max-width: 170px; }
.sheet .cell-note { display: block; font-size: .76rem; white-space: normal; color: var(--bad); font-weight: 700; max-width: 240px; }
.sheet .cell-note.ok { color: var(--green-text); }
.sheet td.dim { color: var(--gray); }
.sheet-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: .8rem; color: var(--muted); padding: 8px 12px; border-top: 1px solid var(--line-2); }
.swatch { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: -1px; margin-right: 4px; border: 1px solid var(--lime-600); background: #FFFFF4; }
.swatch.cur { background: #F6FCEC; border-color: var(--line); }

.split { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.panel-title { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 0 0 8px; }
.register { width: 100%; border-collapse: collapse; font-size: .85rem; font-variant-numeric: tabular-nums; }
.register th { text-align: left; font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); border-bottom: 1px solid var(--line); padding: 6px; white-space: nowrap; }
.register td { padding: 6px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.register tr.new td { background: var(--pale); }
.register tr.end td { font-weight: 800; border-top: 2px solid var(--ink); border-bottom: 0; }
.register .memo { color: var(--ink-2); }
.choice-list { display: grid; gap: 8px; margin: 10px 0; }
.choice { display: flex; gap: 10px; align-items: flex-start; border: 1.5px solid var(--line); border-radius: 10px; padding: 10px 12px; cursor: pointer; background: var(--paper); }
.choice:hover { border-color: var(--gray); }
.choice input { margin-top: 4px; accent-color: var(--ink); }
.choice.right { border-color: var(--lime-600); background: var(--pale); }
.choice.wrong { border-color: var(--bad-line); background: var(--bad-bg); }
.choice .why { display: block; font-size: .85rem; color: var(--bad); font-weight: 700; margin-top: 2px; }
.complete-banner { display: flex; gap: 14px; align-items: center; background: var(--ink); color: #fff; border-radius: var(--radius); padding: 18px 20px; margin: 18px 0; }
.complete-banner .big { width: 44px; height: 44px; border-radius: 50%; background: var(--lime); color: var(--ink); display: inline-flex; align-items: center; justify-content: center; flex: none; }
.complete-banner h2 { color: #fff; margin: 0 0 2px; font-size: 1.2rem; }
.complete-banner p { margin: 0; color: #D5D8D8; }
.complete-banner .btn { margin-left: auto; }
.inline-fb { margin-top: 12px; }
.inline-fb:empty { display: none; }
.kpis { display: flex; flex-wrap: wrap; gap: 10px; margin: 10px 0; }
.kpi { background: var(--soft); border-radius: 10px; padding: 8px 12px; min-width: 150px; }
.kpi .k { font-size: .74rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.kpi .v { font-family: var(--font-head); font-weight: 800; font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.kpi.good { background: var(--pale); }
.kpi.good .v { color: var(--green-text); }
.kpi.bad { background: var(--bad-bg); }
.kpi.bad .v { color: var(--bad); }
.money-input { display: inline-flex; align-items: center; gap: 6px; }
.money-input input { width: 150px; text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- Bank reconciliation (practice) ---------- */
.rec-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 20px; align-items: flex-start; margin-bottom: 14px; }
.scenario-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.scenario-tabs a { text-decoration: none; font-weight: 800; font-size: .88rem; padding: 7px 14px; border-radius: 999px; border: 1.5px solid var(--line); color: var(--ink-2); background: var(--paper); display: inline-flex; align-items: center; gap: 6px; }
.scenario-tabs a.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.scenario-tabs a .icon svg { width: 15px; height: 15px; }
.rec-card { overflow: hidden; }
.rec-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line-2); background: #FAFBFB; }
.rec-head .title { font-family: var(--font-head); font-weight: 800; font-size: 1.15rem; display: flex; align-items: center; gap: 8px; }
.rec-head .acct { font-size: .88rem; color: var(--muted); font-weight: 700; }
.rec-summary { display: grid; grid-template-columns: auto auto 1fr auto; gap: 18px; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line-2); }
.rec-fig .v { font-family: var(--font-head); font-weight: 800; font-size: 1.35rem; font-variant-numeric: tabular-nums; line-height: 1.1; }
.rec-fig .k { font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.rec-math { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; justify-content: center; font-variant-numeric: tabular-nums; font-size: .9rem; }
.rec-math .op { color: var(--gray); font-weight: 800; }
.rec-math .part .v { font-weight: 800; }
.rec-math .part .k { font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.rec-diff { text-align: right; padding: 8px 14px; border-radius: 10px; background: var(--bad-bg); min-width: 150px; }
.rec-diff .v { color: var(--bad); }
.rec-diff.zero { background: var(--pale); }
.rec-diff.zero .v { color: var(--green-text); }
.rec-body { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); }
.rec-list { border-right: 1px solid var(--line-2); min-width: 0; }
.rec-tools { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; padding: 10px 12px; border-bottom: 1px solid var(--line-2); }
.tabs { display: flex; gap: 2px; background: var(--soft); border-radius: 999px; padding: 3px; }
.tabs button { border: 0; background: transparent; padding: 6px 12px; border-radius: 999px; font-weight: 800; font-size: .84rem; cursor: pointer; color: var(--ink-2); }
.tabs button[aria-selected='true'] { background: var(--paper); color: var(--ink); box-shadow: 0 1px 3px rgba(16, 29, 38, .15); }
.rec-table-wrap { overflow-x: auto; }
.rec-table { width: 100%; border-collapse: collapse; font-size: .86rem; font-variant-numeric: tabular-nums; }
.rec-table th { position: sticky; top: 0; background: var(--paper); text-align: left; font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 8px 6px; border-bottom: 1px solid var(--line); white-space: nowrap; z-index: 1; }
.rec-table th.num { text-align: right; }
.rec-table td { padding: 7px 6px; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
.rec-table td.payee { white-space: normal; min-width: 130px; }
.rec-table tr.checked td { background: #F6FCEC; }
.rec-table tr.added td { font-style: italic; }
.rec-table tr.row-bad td { background: var(--bad-bg); }
.rec-table tr.prior td:first-child { box-shadow: inset 3px 0 0 var(--gray); }
.rec-check { width: 42px; text-align: center; }
.circle-check { appearance: none; -webkit-appearance: none; width: 24px; height: 24px; border: 2px solid var(--gray); border-radius: 50%; cursor: pointer; background: var(--paper); display: inline-block; vertical-align: middle; position: relative; margin: 0; }
.circle-check:checked { background: var(--lime); border-color: var(--lime-600); }
.circle-check:checked::after { content: ''; position: absolute; left: 7px; top: 3px; width: 6px; height: 11px; border: solid var(--ink); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.circle-check:disabled { cursor: default; opacity: .8; }
.amt-edit { display: inline-flex; align-items: center; gap: 2px; }
.amt-edit input { width: 90px; text-align: right; border: 1px solid var(--ink); border-radius: 5px; padding: 3px 5px; font-variant-numeric: tabular-nums; }
.pencil-btn { width: 26px; height: 26px; border: 0; background: transparent; cursor: pointer; color: var(--muted); border-radius: 6px; display: inline-flex; align-items: center; justify-content: center; }
.pencil-btn:hover { background: var(--soft); color: var(--ink); }
.pencil-btn .icon svg { width: 15px; height: 15px; }
.fixed-flag { font-size: .7rem; font-weight: 800; color: var(--green-text); margin-left: 4px; }
.bank-panel { padding: 12px; background: #FBFBF6; min-width: 0; }
.bank-stmt { overflow-x: auto; background: #FFFEF8; border: 1px solid #E8E4D4; border-radius: 6px; padding: 12px 14px; font-size: .84rem; box-shadow: 0 1px 0 #EEEADB; }
.bank-stmt h3 { font-size: .95rem; margin: 0; }
.bank-stmt .bank-sub { font-size: .78rem; color: var(--muted); margin-bottom: 8px; }
.bank-stmt table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.bank-stmt th { font-size: .66rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); text-align: left; padding: 4px 3px; border-bottom: 1px solid #DAD5C3; }
.bank-stmt th.num { text-align: right; }
.bank-stmt td { padding: 4px 3px; border-bottom: 1px dotted #DAD5C3; }
.bank-stmt tr.matched td { color: var(--gray); }
.bank-stmt tr.matched td:first-child::before { content: '\2713 '; color: var(--green-text); font-weight: 800; }
.bank-stmt tr.bank-only td { background: var(--warn-bg); }
.bank-stmt tr.bank-only.matched td { background: transparent; }
.bank-stmt .bal-row td { font-weight: 800; border-bottom: 0; border-top: 2px solid var(--ink); }
.bank-stmt .open-row td { font-weight: 700; color: var(--ink-2); }
.add-item { margin-top: 12px; }
.add-form { border: 1.5px solid var(--lime-600); background: var(--paper); border-radius: 10px; padding: 12px; margin-top: 10px; }
.add-form .form-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.add-form .acct-field { grid-column: 1 / -1; }
.rec-foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 18px; border-top: 1px solid var(--line-2); background: #FAFBFB; }
.rec-report { margin-top: 14px; }
.rec-report table { border-collapse: collapse; width: 100%; max-width: 560px; font-variant-numeric: tabular-nums; font-size: .92rem; }
.rec-report td { padding: 4px 6px; border-bottom: 1px solid var(--line-2); }
.rec-report tr.sub td { padding-left: 22px; color: var(--ink-2); font-size: .88rem; }
.rec-report tr.grand td { font-weight: 800; border-top: 2px solid var(--ink); }

/* ---------- COA page ---------- */
.coa-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; align-items: start; }
.coa-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.coa-table th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); padding: 8px; border-bottom: 1px solid var(--line); }
.coa-table td { padding: 7px 8px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.coa-table tr.grp td { background: var(--ink); color: #fff; font-weight: 800; font-size: .82rem; letter-spacing: .03em; }
.coa-table tr.grp td .grp-note { font-weight: 600; color: var(--lime); margin-left: 8px; }
.coa-table .acct-num { font-weight: 800; font-variant-numeric: tabular-nums; width: 64px; }
.coa-table .desc { color: var(--ink-2); font-size: .85rem; }
.side-card { padding: 16px; margin-bottom: 14px; }
.side-card h3 { margin-bottom: 8px; }
.class-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.class-list li { display: flex; justify-content: space-between; gap: 8px; font-size: .9rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .rec-body { grid-template-columns: minmax(0, 1fr); }
  .rec-list { border-right: 0; border-bottom: 1px solid var(--line-2); }
  .rec-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rec-math { grid-column: 1 / -1; order: 3; justify-content: flex-start; }
  .rec-diff { order: 2; }
  .coa-layout { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 900px) {
  .hero { grid-template-columns: minmax(0, 1fr); }
  .scenario, .split, .sim-intro { grid-template-columns: minmax(0, 1fr); }
  .laptop-note { display: flex; }
}
@media (max-width: 760px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  main { padding-top: 18px; }
  .brand-sub { display: none; }
  .brand-name { white-space: nowrap; font-size: .98rem; }
  .site-nav a { padding: 7px 10px; font-size: .88rem; white-space: nowrap; }
  .nav-long { display: none; }
  .nav-short { display: inline; }
  .q-arrows { margin-left: 0; }
  /* JE grid becomes stacked cards */
  .je-table-wrap { padding: 8px; }
  .je-table, .je-table tbody, .je-table tfoot { display: block; }
  .je-table thead { display: none; }
  .je-table tr.je-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; padding: 12px 10px 10px; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 10px; position: relative; }
  .je-table tr.je-row td { display: flex; flex-direction: column; gap: 3px; padding: 0; border: 0; width: auto; background: transparent !important; box-shadow: none !important; }
  .je-table tr.je-row td::before { content: attr(data-label); font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
  .je-table tr.je-row td.c-num { position: absolute; top: 8px; right: 44px; width: auto; }
  .je-table tr.je-row td.c-num::before { content: 'Line'; display: none; }
  .je-table tr.je-row td.c-acct, .je-table tr.je-row td.c-desc { grid-column: 1 / -1; }
  .je-table tr.je-row td.c-acct { padding-right: 70px; }
  .je-table tr.je-row td.c-del { position: absolute; top: 4px; right: 4px; width: auto; }
  .je-table tr.je-row td.c-del::before { display: none; }
  .je-table tr.je-row.row-bad { border-color: var(--bad); background: var(--bad-bg); }
  .je-table tr.je-row.row-good { border-color: var(--lime-600); background: #F6FCEC; }
  .je-table tr.je-msg { display: block; margin: -6px 0 10px; }
  .je-table tr.je-msg[hidden] { display: none; }
  .je-table tr.je-msg td { display: block; padding: 8px 10px; border-radius: 0 0 10px 10px; }
  .je-table tfoot tr { display: grid; grid-template-columns: auto 1fr 1fr; gap: 6px; align-items: center; }
  .je-table tfoot td { padding: 4px; }
  .je-table tfoot td.c-num { display: none; }
  .je-table tfoot .bal-state { grid-column: 1 / -1; padding-left: 0; }
  .acct-list { width: 100%; }
  .rec-summary { gap: 12px; }
  .rec-fig .v { font-size: 1.12rem; }
  .form-grid .wide { grid-column: auto; }
  .complete-banner { flex-wrap: wrap; }
  .complete-banner .btn { margin-left: 0; }
  .action-bar { flex-direction: column; align-items: stretch; }
  .action-left, .action-right { justify-content: stretch; }
  .action-right .btn { flex: 1; }
  .page-head { align-items: flex-start; }
  .coa-table .desc, .coa-table th:nth-child(3) { display: none; }
  /* Reconcile list becomes stacked rows */
  .rec-table thead { display: none; }
  .rec-table, .rec-table tbody { display: block; }
  .rec-table tr { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; position: relative; padding: 9px 52px 9px 12px; border-bottom: 1px solid var(--line-2); }
  .rec-table td { border: 0; padding: 0; white-space: normal; background: transparent !important; }
  .rec-table td:nth-child(-n+3) { font-size: .78rem; color: var(--muted); font-weight: 700; }
  .rec-table td.payee { flex-basis: 100%; font-weight: 700; font-size: .92rem; min-width: 0; }
  .rec-table td.num:empty { display: none; }
  .rec-table td.num::before { content: attr(data-label) ' '; font-size: .74rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
  .rec-table td.rec-check { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); width: auto; }
  .rec-table tr.checked { background: #F6FCEC; }
  .rec-table tr.prior { box-shadow: inset 3px 0 0 var(--gray); }
  .bank-stmt { font-size: .8rem; }
}
@media (max-width: 420px) {
  .rec-summary { grid-template-columns: minmax(0, 1fr); }
  .progress { min-width: 0; width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}
@media print {
  .site-header, .site-footer, .action-bar, .je-tools { display: none; }
}

/* Round checkboxes inside schedules */
.sheet td.input-cell input.circle-check { width: 24px; height: 24px; min-height: 0; padding: 0; border: 2px solid var(--gray); border-radius: 50%; background: var(--paper); }
.sheet td.input-cell input.circle-check:checked { background: var(--lime); border-color: var(--lime-600); }
.sheet tr.row-bad td { background: var(--bad-bg); }
.page-head > div { min-width: 0; max-width: 100%; }
.page-tools { min-width: 0; max-width: 100%; }
.page-tools .select { min-width: 0; text-overflow: ellipsis; }
@media (max-width: 760px) {
  .page-tools { width: 100%; }
  .page-tools .select { width: 100%; }
}
@media (max-width: 760px) {
  .bank-stmt th, .bank-stmt td { padding: 4px 2px; }
  .bank-stmt th { letter-spacing: .02em; }
}
.sheet.compact { font-size: .8rem; }
.sheet.compact th { font-size: .72rem; padding: 7px 6px; white-space: normal; }
.sheet.compact td { padding: 5px 6px; }
.sheet.compact td.wrap-cell { min-width: 120px; }
.sheet.compact td.input-cell input { width: 96px; }
.sheet.compact td.w-amt { min-width: 92px; }
.sheet.compact td.wrap-cell { max-width: 170px; }
