:root {
  color: #17211b;
  background: #f4f6f3;
  font-family: system-ui, sans-serif;
  line-height: 1.5;
}

body { margin: 0; }
a { color: #245c3c; }
.site-header, .page-shell { max-width: 70rem; margin: 0 auto; padding: 1rem 1.5rem; }
.site-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #d8ded9; }
.site-title { color: inherit; font-weight: 700; text-decoration: none; }
.page-shell { padding-top: 2.5rem; }
.page-heading { display: flex; justify-content: space-between; align-items: start; gap: 2rem; margin-bottom: 2rem; }
.page-heading h1 { margin: 0; }
.page-heading p { margin-bottom: 0; }
.eyebrow { color: #52705f; font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.button { display: inline-block; border: 0; border-radius: .35rem; padding: .7rem 1rem; color: white; background: #245c3c; font: inherit; text-decoration: none; cursor: pointer; }
.button-secondary { color: #245c3c; background: white; box-shadow: inset 0 0 0 1px #52705f; }
.button-danger { background: #8b1e1e; }
.button-compact { padding: .5rem .75rem; }
.action-group { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.table-wrap { overflow-x: auto; background: white; border: 1px solid #d8ded9; border-radius: .5rem; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: .85rem 1rem; border-bottom: 1px solid #e5e9e6; text-align: left; vertical-align: top; }
th { color: #52705f; font-size: .8rem; text-transform: uppercase; }
.statement, .fact-id { display: block; }
.statement { font-weight: 600; }
.fact-id { margin-top: .3rem; color: #617067; font-family: monospace; font-size: .75rem; }
.empty-state, form { max-width: 42rem; padding: 2rem; border: 1px solid #d8ded9; border-radius: .5rem; background: white; }
.detail-card, .version-card { padding: 1.25rem 1.5rem; border: 1px solid #d8ded9; border-radius: .5rem; background: white; }
.detail-card, .review-section, .history-section { margin-bottom: 2rem; }
.review-panel { padding: 1.5rem; border: 2px solid #52705f; border-radius: .5rem; background: #edf4ef; }
.review-panel h2 { margin-top: 0; }
.review-panel form { padding: 0; border: 0; background: transparent; }
.notice-panel, .warning-panel { max-width: 42rem; margin-bottom: 1.5rem; padding: 1.25rem 1.5rem; border-radius: .5rem; }
.notice-panel { border: 1px solid #52705f; background: #edf4ef; }
.warning-panel { border: 2px solid #8b1e1e; background: #fff3f1; }
.notice-panel h2, .warning-panel h2 { margin-top: 0; }
.warning-panel form { padding: 0; border: 0; background: transparent; }
.fact-details, .version-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.fact-details div:first-child { grid-column: 1 / -1; }
dt { color: #52705f; font-size: .8rem; font-weight: 700; text-transform: uppercase; }
dd { margin: .2rem 0 0; white-space: pre-wrap; }
.version-card { margin-bottom: 1rem; }
.version-card h3 { margin-top: 0; }
.field { margin-bottom: 1.25rem; }
.field label { display: block; margin-bottom: .35rem; font-weight: 700; }
.field textarea, .field select, form input { box-sizing: border-box; width: 100%; padding: .65rem; border: 1px solid #9ba79f; border-radius: .25rem; font: inherit; }
.help-text { margin: .3rem 0; color: #617067; font-size: .9rem; }
.errorlist, .error-summary { color: #8b1e1e; }
.linked-list { padding-left: 1.25rem; }
.linked-list li { margin-bottom: .75rem; }
.muted { display: block; color: #617067; font-size: .9rem; }
.field ul { margin: 0; padding: .75rem; list-style: none; border: 1px solid #d8ded9; border-radius: .25rem; }
.field ul label { display: flex; gap: .6rem; align-items: start; font-weight: 400; }
.field ul input { width: auto; margin-top: .3rem; }
.message { padding: .8rem 1rem; border-radius: .35rem; }
.message-success { color: #174b2f; background: #dff2e6; }
.workspace-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.workspace-card { padding: 1.5rem; border: 1px solid #d8ded9; border-radius: .5rem; background: white; }
.workspace-card h2 { margin-top: 0; }
.record-count { color: #52705f; font-weight: 700; }
.structured-value { display: block; margin-bottom: .35rem; }
.auth-shell { max-width: 38rem; }
.auth-card { padding: 2rem; border: 1px solid #d8ded9; border-radius: .5rem; background: white; }
.auth-card form { padding: 0; border: 0; }
.auth-card form p { margin-bottom: 1.25rem; }
.auth-card label { display: block; margin-bottom: .35rem; font-weight: 700; }

@media (max-width: 40rem) {
  .site-header { align-items: start; gap: 1rem; }
  .site-header nav { display: flex; flex-direction: column; gap: .35rem; }
  .page-heading { display: block; }
  .page-heading .button { margin-top: 1rem; }
  .fact-details, .version-details { grid-template-columns: 1fr; }
  .workspace-grid { grid-template-columns: 1fr; }
}
