/* A quiet paper surface: hierarchy comes from type and space, not nested boxes. */
:root {
  --brand: #2b6755;
  --bg: #fcfcf9;
  --text: #29332e;
  --muted: #69756d;
  --line: #e4e9e2;
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Avenir Next", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 14px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
h1 { font-size: 26px; font-weight: 500; line-height: 1.45; letter-spacing: -.4px; }
h2 { font-size: 17px; font-weight: 500; line-height: 1.6; }
h3 { font-weight: 500; }
strong { font-weight: 550; }
.shell { grid-template-columns: 176px minmax(0, 1fr); }
.sidebar { width: 176px; border: 0; background: var(--bg); padding: 0 16px; }
.brand { height: 88px; padding: 0 8px; gap: 8px; font-size: 15px; font-weight: 550; color: var(--text); }
.brand-mark { width: 22px; height: 28px; background: none; border-radius: 0; color: var(--brand); font-size: 17px; }
.nav { gap: 6px; }
.nav a { min-height: 46px; padding: 10px 12px; border-radius: 0; font-size: 13px; font-weight: 400; color: #69756d; }
.nav svg { width: 16px; height: 16px; }
.nav a.active { color: var(--brand); background: transparent; box-shadow: inset 2px 0 var(--brand); font-weight: 550; }
.nav a:hover { background: #f1f4ee; }
.nav-label small { display: none; }
.side-foot { border: 0; padding: 20px 8px; color: var(--muted); }
.side-foot strong { font-size: 11px; font-weight: 400; }
.side-foot p { font-size: 11px; line-height: 1.7; }
.side-foot .dot { width: 4px; height: 4px; background: #aa8c52; }
.topbar { height: 64px; padding: 0 48px; border: 0; background: var(--bg); }
.search-launch { border: 0; background: transparent; width: 278px; padding: 8px 0; color: var(--muted); font-size: 13px; align-items: center; }
.search-launch svg { width: 16px; height: 16px; }
.avatar { color: var(--brand); background: #eef2eb; }
.identity { font-size: 12px; gap: 8px; }
.identity .name { font-weight: 400; }
.content { max-width: 1180px; padding: 44px 48px 64px; }
.page-head { margin-bottom: 36px; gap: 24px; }
.page-head p { margin-top: 10px; color: var(--muted); font-size: 13px; line-height: 1.8; }
.page-head .actions { gap: 6px; }
.btn { border-color: transparent; background: transparent; color: var(--brand); border-radius: 5px; min-height: 40px; padding: 8px 14px; font-size: 13px; font-weight: 400; box-shadow: none; }
.btn.small { min-height: 36px; padding: 7px 10px; font-size: 12px; }
.btn:hover { background: #eef2eb; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 500; }
.btn.primary:hover { background: #215441; border-color: #215441; }
.btn.ghost { color: var(--muted); }
.btn.danger { border-color: transparent; color: #a44c43; }
.btn:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline-color: var(--brand); }
.card { background: transparent; border: 0; border-radius: 0; box-shadow: none; overflow: visible; margin-bottom: 32px; }
.card-head { padding: 18px 0; border-color: var(--line); background: transparent; }
.card-body { padding: 24px 0; }
.cards { gap: 24px; }
.stat { background: transparent; border: 0; border-radius: 0; padding: 12px 0; }
.stat .value { font-size: 24px; font-weight: 500; }
.stat .label, .stat .hint { color: var(--muted); }
.badge, .badge.blue, .badge.green, .badge.orange, .badge.red { border: 0; background: transparent; padding: 0; border-radius: 0; min-width: 0; min-height: 0; font-size: 12px; font-weight: 400; color: var(--muted); }
.badge.red { color: #a94d42; }
.badge.green { color: #46705a; }
.badge.orange { color: #8b7042; }
.badge.blue { color: var(--brand); }
.tabs { padding: 0; gap: 24px; border-color: var(--line); }
.tabs button, .guide-tab { color: var(--muted); font-size: 13px; font-weight: 400; }
.tabs button.active, .guide-tab.active { color: var(--brand); border-color: var(--brand); font-weight: 500; }
.toolbar { padding: 12px 0; border-color: var(--line); }
.pager { padding: 18px 0; border-color: var(--line); color: var(--muted); font-size: 12px; }
.checked-at { font-size: 11px; color: var(--muted); }
.today-board { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(220px, 340px); column-gap: 32px; }
.today-board>.tabs { align-self: end; border: 0; }
.today-board>#today-filter { border: 0; padding: 0; flex-wrap: nowrap; gap: 8px; }
#today-filter .actions:first-of-type { min-width: 0; }
#today-filter input[name=q] { width: 100%; min-width: 0; background: transparent; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; font-size: 12px; }
#today-filter .actions:last-of-type { flex-wrap: nowrap; gap: 0; }
#today-filter .btn { padding: 8px; font-size: 12px; }
.today-board>.today-date-filter, .today-board>.guide-task, .today-board>.pager, .today-board>.empty { grid-column: 1/-1; }
.today-date-filter { border-top: 1px solid var(--line); }
.today-date-filter>summary { padding: 10px 0; color: var(--muted); font-size: 12px; min-height: 40px; }
.today-date-filter>summary span { color: var(--muted); }
.guide-filters { background: transparent; padding: 8px 0 16px; gap: 8px; }
.guide-filters .btn { color: var(--muted); }
.guide-filters .btn.primary { color: var(--brand); border-color: transparent; background: #edf2e9; }
.guide-task { padding: 28px 0; gap: 20px; border-color: var(--line); }
.guide-task-heading { gap: 14px; }
.guide-task-heading strong { font-size: 17px; font-weight: 500; line-height: 1.6; }
.guide-task-index { color: #819080; font-size: 11px; padding-top: 6px; }
.guide-task p { font-size: 14px; line-height: 1.8; color: #59665e; margin: 10px 0; }
.guide-meta { color: var(--muted); font-size: 11px; gap: 4px 16px; }
.guide-task>.btn { min-width: 88px; }
.guide-policy { margin: 32px 0; padding: 4px 16px; border: 0; border-left: 2px solid #d2c29d; background: transparent; border-radius: 0; color: #816d48; }
.guide-policy strong { font-weight: 400; font-size: 12px; }
.guide-policy p { font-size: 12px; }
.guide-stats { margin: 32px 0; }
.guide-stats .stat { min-height: 48px; padding: 0 20px; }
.guide-stats .stat:first-child { padding-left: 0; }
.guide-stats .stat .value { font-size: 20px; font-weight: 400; }
.guide-stats .stat .hint { font-size: 11px; }
.guide-welcome { margin-top: 32px; }
.guide-welcome strong { font-size: 13px; color: var(--muted); font-weight: 400; }
.guide-start-help>summary, .internal-drafts>summary { padding: 16px 0; border-top: 1px solid var(--line); font-size: 13px; font-weight: 400; color: var(--muted); }
.library-grid { display: block; margin: 0 0 36px; }
.library-group { display: grid; grid-template-columns: 180px minmax(0, 1fr); column-gap: 48px; padding: 28px 0; margin: 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; }
.library-group h2 { grid-column: 1; font-size: 16px; font-weight: 500; }
.library-group>p { grid-column: 1; grid-row: 2; max-width: 180px; margin: 8px 0 0; font-size: 12px; line-height: 1.8; color: var(--muted); }
.library-links { grid-column: 2; grid-row: 1/3; gap: 4px 24px; align-content: start; }
.library-links .btn { justify-content: flex-start; padding: 8px 0; color: #35483b; font-size: 14px; font-weight: 400; min-height: 44px; border: 0; background: transparent; border-radius: 0; }
.library-links .btn:hover { color: var(--brand); text-decoration: underline; text-underline-offset: 6px; }
.library-catalog>summary, .library-connection>summary { padding: 18px 0; border-top: 1px solid var(--line); min-height: 56px; color: var(--muted); }
.library-catalog>summary h2, .library-connection>summary h2 { color: #526054; font-size: 14px; font-weight: 400; }
.library-catalog>summary span, .library-connection>summary span { font-size: 12px; }
.library-note { padding: 18px 0; color: var(--muted); }
.record-context h1 { font-size: 24px; font-weight: 500; line-height: 1.5; }
.record-context .page-head { margin-bottom: 14px; }
.record-context .page-head p { font-size: 12px; }
.record-sections { gap: 24px; padding-bottom: 18px; margin-bottom: 36px; }
.record-sections a { color: var(--muted); background: transparent; border-radius: 0; padding: 6px 0; min-height: 40px; font-size: 12px; }
.record-sections a:first-child { color: var(--brand); background: transparent; }
.record-sections a:hover { color: var(--brand); background: transparent; text-decoration: underline; text-underline-offset: 8px; }
.business-guide>.card-head { padding: 0; margin-bottom: 18px; border: 0; }
.business-guide>.card-head h2 { font-size: 13px; font-weight: 400; color: var(--muted); }
.guide-eyebrow { display: none; }
.business-guide>.card-body { padding: 0; }
.guide-step-heading h3 { font-size: 24px; font-weight: 500; }
.guide-intro { margin: 10px 0 24px; font-size: 13px; color: var(--muted); }
.guide-check-count { font-size: 12px; color: var(--muted); margin-bottom: 20px; }
.guide-check { padding: 20px 0; gap: 16px; border-color: var(--line); }
.guide-check strong { font-size: 14px; font-weight: 500; }
.guide-check p { color: var(--muted); font-size: 13px; line-height: 1.8; }
.guide-mark, .guide-check.is-done .guide-mark, .guide-check.is-focus .guide-mark { background: transparent; color: #8a9689; border-radius: 0; width: 16px; }
.guide-check.is-focus { border: 0; border-left: 2px solid #abc0a7; border-radius: 0; background: transparent; padding: 8px 0 8px 20px; margin: 16px 0 28px; }
.guide-check.is-focus .guide-mark { display: none; }
.guide-check.is-focus strong { font-size: 18px; font-weight: 500; }
.guide-focus-label { color: var(--brand); font-size: 11px; font-weight: 400; margin-bottom: 6px; }
.guide-check.is-focus>.btn { min-height: 44px; }
.guide-rules { background: transparent; border: 0; border-left: 2px solid #d2c29d; border-radius: 0; padding: 4px 16px; margin: 20px 0; }
.guide-rules strong, .guide-rules p { color: #816d48; font-size: 12px; font-weight: 400; }
.guide-next { margin-top: 20px; padding-top: 20px; border-color: var(--line); }
.guide-next>span { font-size: 12px; color: var(--muted); }
.guide-completed>summary, .guide-extra>summary, .guide-instructions>summary, .guide-journey>summary { color: var(--muted); font-size: 12px; min-height: 48px; padding: 16px 0; }
.guide-help summary { color: var(--muted); }
.guide-stages button { background: transparent; border-color: var(--line); border-radius: 4px; color: var(--muted); }
.guide-stages button.active { background: transparent; border-color: #a9bca5; color: var(--brand); }
.guide-stages button small { color: var(--muted); }
.guide-review-progress { background: #f2f5ef; border: 0; border-left: 2px solid #abc0a7; border-radius: 0; padding: 12px 18px; }
.record-tools { padding: 16px 0 32px; margin: 0; border-bottom: 1px solid var(--line); }
.record-tools strong { font-weight: 400; color: var(--muted); }
.record-tools p { color: var(--muted); }
.record-tools .actions .btn { min-width: 76px; }
.twocol { gap: 48px; }
.detail-grid { gap: 24px; }
.detail-grid dt { color: var(--muted); }
.detail-grid dd { font-weight: 400; }
.empty { padding: 28px 0; font-size: 12px; color: var(--muted); }
.empty strong { font-size: 14px; font-weight: 400; color: var(--muted); }
.fact, .summary, .help, .output-entry-status { background: transparent; border-color: var(--line); border-radius: 0; }
.summary { padding: 20px 0; gap: 36px; }
.summary strong { font-size: 22px; font-weight: 500; }
.breadcrumb { font-size: 11px; color: var(--muted); margin-bottom: 14px; }
th { background: #f3f5ef; color: #5f6b61; font-weight: 400; }
th, td { border-color: var(--line); }
tbody tr:hover { background: #f5f7f1; }
.operations-more[open]>summary { color: var(--brand); border-color: transparent; }
.operations-menu { border-color: var(--line); border-radius: 6px; box-shadow: 0 12px 32px #29332e12; }
.record-reference [tabindex="-1"]:focus, .library-catalog:focus { outline: 1px solid #b7c8b1; outline-offset: 6px; }
.modal-backdrop { background: #26312829; backdrop-filter: blur(5px); }
.modal, .modal.wide { width: min(760px, 100%); border-radius: 10px; box-shadow: 0 20px 70px #2631281a; }
.modal .card-head { padding: 24px 28px 12px; border: 0; }
.modal .card-head h2 { font-size: 17px; font-weight: 500; }
.modal-body { padding: 24px 28px 28px; }
.modal .form-footer { padding: 18px 28px; border-color: var(--line); gap: 12px; }
.form-direction { padding: 0; margin-bottom: 26px; border: 0; }
.form-direction>span { color: var(--muted); font-size: 11px; margin-bottom: 6px; }
.form-direction>strong { font-size: 21px; font-weight: 500; }
.form-direction>p { font-size: 13px; line-height: 1.8; color: var(--muted); }
.field-help-controls { margin-bottom: 22px; color: var(--muted); }
.form-grid { gap: 22px 24px; }
.field label { color: #59675d; font-size: 13px; font-weight: 400; }
.field input, .field select, .field textarea, .filter-input { min-height: 40px; border: 1px solid #e2e8df; border-radius: 4px; background: #f5f7f2; color: var(--text); padding: 8px 10px; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: #9bb195; background: #fff; }
.field small { color: var(--muted); }
.form-advanced { padding: 0; border: 0; border-top: 1px solid var(--line); background: transparent; border-radius: 0; }
.form-advanced>summary { color: var(--muted); font-size: 12px; padding: 16px 0; }
.form-advanced>p { font-size: 12px; color: var(--muted); }
.line-editor, .fee-editor { padding: 24px 0; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: transparent; }
.line-head strong { font-size: 13px; font-weight: 500; }
form:not(.show-field-help) .field>.guide-field-help { border-color: #d8e2d3; box-shadow: 0 8px 24px #29332e0f; color: #53674f; }
.guide-highlight { background: #f1f5ed; outline-color: #86a57e; }
.banner.info { background: #f3f6f0; border-color: #d8e2d1; color: #52654c; }
@media (max-width: 1100px) {
  .content { padding: 36px 32px 56px; }
  .topbar { padding: 0 32px; }
  .today-board { grid-template-columns: minmax(200px, 1fr) minmax(200px, 300px); column-gap: 16px; }
  .twocol { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .library-group { grid-template-columns: 160px minmax(0, 1fr); column-gap: 32px; }
}
@media (max-width: 820px) {
  .today-board { display: block; }
  .today-board>#today-filter { padding: 10px 0; }
  .library-group { grid-template-columns: minmax(0, 1fr); padding: 24px 0; }
  .library-group>p { max-width: none; margin: 6px 0 12px; }
  .library-links { grid-column: 1; grid-row: 3; }
}
@media (max-width: 640px) {
  .sidebar { width: 224px; padding: 0 20px; background: var(--bg); }
  .sidebar.open .nav-label small { display: block; color: var(--muted); font-size: 11px; }
  .sidebar.open .nav a { min-height: 58px; }
  .brand { height: 76px; }
  .topbar { height: 56px; padding: 0 20px; gap: 12px; }
  .search-launch { width: auto; font-size: 12px; }
  .content { padding: 26px 24px 44px; }
  h1, .record-context h1 { font-size: 22px; font-weight: 500; }
  .page-head { margin-bottom: 28px; gap: 14px; }
  .page-head p { font-size: 12px; line-height: 1.8; }
  .page-head .actions { gap: 4px; }
  .btn, .btn.small, .btn.ghost { min-height: 44px; }
  .page-head>.actions .btn { padding: 8px 10px; }
  .card-head { padding: 16px 0; }
  .card-body { padding: 20px 0; }
  .tabs { gap: 20px; }
  .guide-tab { font-size: 12px; min-height: 48px; }
  .today-board>#today-filter { display: grid; padding: 10px 0; }
  .today-date-filter>summary { min-height: 44px; padding: 10px 0; }
  .guide-task { padding: 24px 0; gap: 10px; }
  .guide-task-heading strong { font-size: 15px; }
  .guide-task p { font-size: 13px; line-height: 1.8; }
  .guide-task>.btn { justify-self: start; width: auto; min-width: 104px; margin-top: 8px; }
  .guide-filters { padding: 8px 0 16px; }
  .guide-policy { padding: 4px 12px; gap: 8px; margin: 28px 0; }
  .guide-stats .stat { padding: 0 12px; }
  .guide-stats .stat .value { font-size: 18px; }
  .guide-start-help>summary, .internal-drafts>summary { padding: 16px 0; }
  .library-links { gap: 4px 12px; }
  .library-links .btn { font-size: 13px; padding: 8px 0; }
  .library-catalog>summary, .library-connection>summary { padding: 16px 0; }
  .library-catalog>summary span, .library-connection>summary span { font-size: 11px; margin-top: 4px; }
  .record-sections { gap: 20px; margin-bottom: 28px; padding-bottom: 12px; }
  .record-sections a { font-size: 12px; min-height: 44px; padding: 6px 0; }
  .guide-step-heading h3 { font-size: 22px; }
  .guide-check { gap: 12px; padding: 20px 0; }
  .guide-check>.grow { flex: 1 1 calc(100% - 32px); }
  .guide-check>.btn { flex: 0 0 auto; margin-left: 28px; min-height: 44px; }
  .guide-check.is-focus { padding: 4px 0 4px 16px; margin: 16px 0 24px; }
  .guide-check.is-focus>.grow { flex: 1 1 100%; }
  .guide-check.is-focus>.btn { flex: 0 0 auto; margin-left: 0; min-height: 44px; min-width: 104px; }
  .guide-check.is-focus strong { font-size: 17px; }
  .guide-next>.btn { width: auto; min-width: 104px; }
  .record-tools .actions { display: flex; flex-wrap: wrap; width: 100%; }
  .record-tools .actions .btn { min-width: 76px; justify-content: flex-start; padding: 8px 0; }
  .modal-backdrop { padding: 12px; }
  .modal .card-head { padding: 20px 20px 8px; }
  .modal-body { padding: 20px; }
  .modal .form-footer { padding: 16px 20px; }
  .form-grid { gap: 20px; }
  .form-direction { margin-bottom: 24px; }
  .form-direction>strong { font-size: 19px; }
  .field-help-controls { margin-bottom: 20px; }
  .field input, .field select, .field textarea { min-height: 44px; }
  .form-advanced { padding: 0; }
}
