:root {
  --bg: #f6f7f9; --surface: #fff; --border: #e6e8ec; --text: #0f172a;
  --muted: #64748b; --brand: #2563eb; --green: #16a34a; --red: #dc2626; --amber: #d97706;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
a { color: inherit; }
.layout { display: flex; min-height: 100vh; }
aside { width: 232px; border-right: 1px solid var(--border); background: var(--surface);
  flex-shrink: 0; height: 100vh; position: sticky; top: 0; display: flex; flex-direction: column; padding: 12px; }
.brand { font-weight: 800; font-size: 18px; letter-spacing: -.4px; padding: 12px; }
.brand small { display: block; font-size: 11px; color: var(--muted); font-weight: 400; }
.navlink { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 9px;
  color: var(--muted); font-size: 14px; font-weight: 500; text-decoration: none; }
.navlink:hover { background: #f1f5f9; color: var(--text); }
.navlink.active { background: #eef2ff; color: var(--brand); font-weight: 600; }
.main { flex: 1; min-width: 0; }
header.top { display: flex; align-items: center; justify-content: space-between; padding: 14px 28px;
  border-bottom: 1px solid var(--border); background: var(--surface); position: sticky; top: 0; z-index: 10; }
main.content { padding: 28px; max-width: 1200px; margin: 0 auto; }
h1 { font-size: 24px; font-weight: 800; letter-spacing: -.5px; margin: 0; }
h2 { font-size: 15px; font-weight: 700; }
h3 { font-weight: 700; margin: 0; }
.sub { color: var(--muted); font-size: 14px; margin-top: 2px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 1px 2px rgba(16,24,40,.04); }
.grid { display: grid; gap: 14px; }
.chip { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 600;
  padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border); }
.btn { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600;
  padding: 7px 12px; border-radius: 9px; border: 1px solid var(--border); background: var(--surface);
  color: var(--text); cursor: pointer; text-decoration: none; }
.btn:hover { background: #f1f5f9; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn-green { background: var(--green); border-color: var(--green); color: #fff; }
.btn-sm { padding: 4px 9px; font-size: 12px; }
.input, .select { width: 100%; font-size: 13px; padding: 8px 10px; border-radius: 9px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text); }
.stat { padding: 18px; }
.stat .label { font-size: 12px; color: var(--muted); font-weight: 600; }
.stat .value { font-size: 26px; font-weight: 800; margin-top: 6px; }
.stat .sub { font-size: 12px; color: var(--muted); margin-top: 4px; }
table.fv { width: 100%; border-collapse: collapse; font-size: 13px; }
table.fv th { text-align: left; color: var(--muted); font-weight: 600; font-size: 11px;
  text-transform: uppercase; letter-spacing: .04em; padding: 10px 12px; border-bottom: 1px solid var(--border); }
table.fv td { padding: 11px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.fv tr:last-child td { border-bottom: none; }
.toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 10px; padding: 3px; background: var(--surface); }
.toggle a { font-size: 13px; font-weight: 600; padding: 5px 14px; border-radius: 7px; color: var(--muted); text-decoration: none; }
.toggle a.active { color: #fff; }
.field label { font-size: 11px; color: var(--muted); font-weight: 600; display: block; margin-bottom: 4px; }
.muted { color: var(--muted); }
.flex { display: flex; }
