:root {
  --bg: #0f1115;
  --panel: #171a21;
  --panel-2: #1e2229;
  --border: #2a2e37;
  --text: #e8e9ec;
  --muted: #9aa0ab;
  --accent: #d97757;
  --accent-hover: #c96545;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif; background: var(--bg); color: var(--text); }
.hidden { display: none !important; }
.screen { min-height: 100vh; }

#login-screen { display: flex; align-items: center; justify-content: center; }
.login-box { background: var(--panel); border: 1px solid var(--border); border-radius: 12px; padding: 40px; width: 320px; text-align: center; }
.login-box h1 { margin: 0 0 4px; font-size: 22px; }
.subtitle { color: var(--muted); margin: 0 0 24px; font-size: 14px; }
.login-box input { width: 100%; padding: 10px 12px; margin-bottom: 12px; background: var(--panel-2); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-size: 14px; }
.login-box button { width: 100%; padding: 10px; background: var(--accent); border: none; border-radius: 8px; color: white; font-size: 14px; cursor: pointer; }
.login-box button:hover { background: var(--accent-hover); }
.error { color: #e05252; font-size: 13px; margin-top: 8px; min-height: 16px; }

.topbar { display: flex; justify-content: space-between; align-items: center; padding: 14px 24px; border-bottom: 1px solid var(--border); background: var(--panel); }
.brand { font-weight: 600; }
.topbar-actions { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--muted); }
.topbar-actions button { padding: 8px 14px; background: var(--panel-2); border: 1px solid var(--border); border-radius: 8px; color: var(--text); cursor: pointer; font-size: 13px; }

.content { max-width: 800px; margin: 0 auto; padding: 24px; }

.template-box { margin-bottom: 24px; background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 12px 16px; }
.template-box summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.template-box textarea { width: 100%; margin-top: 10px; padding: 10px; background: var(--panel-2); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-family: monospace; font-size: 13px; }
.template-box button { margin-top: 8px; padding: 8px 14px; background: var(--accent); border: none; border-radius: 8px; color: white; cursor: pointer; }

.audit-form { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.audit-form input, .audit-form select, .audit-form textarea {
  padding: 10px 12px; background: var(--panel-2); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-size: 14px; font-family: inherit;
}
.audit-form button { padding: 12px 18px; background: var(--accent); border: none; border-radius: 8px; color: white; cursor: pointer; align-self: flex-start; font-size: 14px; }
.audit-form button:hover { background: var(--accent-hover); }

.report-result { background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 20px; margin-bottom: 24px; }
.report-result pre { white-space: pre-wrap; font-family: inherit; font-size: 14px; margin: 0; }

.item-list { list-style: none; padding: 0; margin: 0; }
.item-list li { background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 12px 14px; margin-bottom: 8px; display: flex; justify-content: space-between; align-items: center; font-size: 14px; cursor: pointer; }
.item-list .item-title { font-weight: 500; }
.item-list .item-meta { color: var(--muted); font-size: 12px; margin-top: 2px; }
.item-list .del-btn { background: none; border: none; color: #e05252; cursor: pointer; font-size: 13px; }
