:root {
  --bg: #fbfaf7; --surface: #ffffff; --text: #26231d; --muted: #6f695c;
  --line: #e4dfd2; --accent: #c5a45e; --accent-text: #2b2208; --error: #a3261a;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1913; --surface: #24211a; --text: #f0ece1; --muted: #a39d8e;
    --line: #38342a; --accent: #c5a45e; --accent-text: #1b1604; --error: #ff8a7a;
  }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.5 Georgia, "Times New Roman", serif; }
h1, h2, button, input, select, th, nav, label, .note {
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
h1 { font-size: 1.5rem; margin: 0 0 1rem; }
h2 { font-size: 1.1rem; margin: 2rem 0 .75rem; }
nav { display: flex; align-items: center; gap: 1.25rem; padding: .75rem 1.5rem;
  border-bottom: 1px solid var(--line); background: var(--surface); }
nav .brand { font-weight: 700; margin-right: auto; }
nav a { color: var(--text); text-decoration: none; padding: .25rem 0; }
nav a.active { border-bottom: 2px solid var(--accent); }
nav .who { color: var(--muted); font-size: .9rem; }
main { max-width: 1000px; margin: 0 auto; padding: 1.5rem; }
.login { max-width: 360px; margin: 12vh auto; padding: 0 1.5rem; }
label { display: block; margin: .75rem 0 .25rem; font-size: .9rem; color: var(--muted); }
input, select { width: 100%; padding: .6rem .7rem; font-size: 1rem; color: var(--text);
  background: var(--surface); border: 1px solid var(--line); border-radius: 6px; }
button { padding: .6rem 1rem; font-size: 1rem; cursor: pointer; border-radius: 6px;
  border: 1px solid var(--accent); background: var(--accent); color: var(--accent-text); }
button.secondary { background: transparent; color: var(--text); border-color: var(--line); }
button:disabled { opacity: .6; cursor: wait; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
form button { margin-top: 1rem; }
.toolbar { display: flex; gap: .75rem; align-items: end; margin-bottom: 1rem; }
.toolbar > div { min-width: 220px; }
.toolbar label { margin-top: 0; }
.note { color: var(--muted); font-size: .9rem; }
.error { color: var(--error); font-family: system-ui, sans-serif; margin-top: .75rem; min-height: 1.5em; }
.scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
table { border-collapse: collapse; width: 100%; min-width: 640px; }
th, td { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .85rem; color: var(--muted); font-weight: 600; }
tr:last-child td { border-bottom: 0; }
ul.plain { padding-left: 1.1rem; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
@media (max-width: 700px) { .grid2 { grid-template-columns: 1fr; } nav { flex-wrap: wrap; } }
