:root {
  color: #20251f;
  background: #f4f5f2;
  font-family: Arial, "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }

.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-form { width: min(420px, 100%); background: #fff; border: 1px solid #d8ddd5; border-radius: 6px; padding: 32px; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 6px; font-size: 26px; font-weight: 700; }
h2 { font-size: 20px; margin-bottom: 16px; }
h3 { font-size: 15px; margin-bottom: 6px; }
.eyebrow { color: #236c4e; font-size: 12px; font-weight: 700; margin-bottom: 8px; }
label { display: grid; gap: 7px; font-weight: 700; font-size: 14px; }
input, textarea, select { width: 100%; border: 1px solid #bbc3b8; border-radius: 4px; padding: 10px; background: #fff; color: #20251f; }
textarea { min-height: 92px; resize: vertical; }
button { border: 1px solid #236c4e; border-radius: 4px; padding: 9px 14px; background: #236c4e; color: #fff; font-weight: 700; }
button:hover { background: #19533a; }
button.quiet, button.secondary { color: #236c4e; background: #fff; }
button.quiet { border-color: #c9d1c7; }
button.danger { color: #a63b2c; background: #fff; border-color: #dfb6b0; }
.login-form button { width: 100%; margin-top: 18px; }
.form-error { min-height: 20px; color: #a63b2c; margin: 12px 0 0; font-size: 14px; }

.app-shell { width: min(1120px, calc(100% - 32px)); margin: 0 auto; padding: 22px 0 42px; }
.topbar { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid #d8ddd5; margin: 22px 0; overflow-x: auto; }
.tab { color: #576054; background: transparent; border: 0; border-bottom: 3px solid transparent; border-radius: 0; padding: 11px 14px; white-space: nowrap; }
.tab:hover { color: #236c4e; background: #e8eee8; }
.tab.active { color: #236c4e; border-bottom-color: #236c4e; }

.summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
.metric, .panel { background: #fff; border: 1px solid #d8ddd5; border-radius: 6px; }
.metric { padding: 18px; }
.metric strong { display: block; color: #236c4e; font-size: 29px; margin-bottom: 4px; }
.metric span { color: #65705f; font-size: 14px; }
.layout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.7fr); gap: 16px; }
.panel { padding: 20px; }
.panel-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.panel-header h2 { margin: 0; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-grid .wide { grid-column: 1 / -1; }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 14px; }
.list { display: grid; gap: 8px; }
.row { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid #e7eae4; }
.row:last-child { border-bottom: 0; }
.row-title { font-weight: 700; }
.row-meta { margin-top: 4px; color: #65705f; font-size: 13px; }
.row-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.row-actions button { font-size: 13px; padding: 6px 9px; }
.completed .row-title { color: #7b8379; text-decoration: line-through; }
.empty { color: #65705f; padding: 12px 0; }
.tag { display: inline-block; background: #ebf2e8; color: #236c4e; border-radius: 3px; padding: 3px 6px; font-size: 12px; font-weight: 700; }
.answer { white-space: pre-wrap; line-height: 1.65; background: #f4f5f2; border-left: 3px solid #b6751c; padding: 14px; }
.notice { color: #65705f; font-size: 14px; line-height: 1.55; }

@media (max-width: 700px) {
  .app-shell { width: min(100% - 20px, 1120px); padding-top: 14px; }
  .summary, .layout { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .topbar { align-items: center; }
  .panel { padding: 16px; }
}
