* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; background: #f4f6f8; color: #222; }
.topbar { background: #1a365d; color: #fff; padding: 12px 20px; display: flex; gap: 16px; align-items: center; }
.topbar a { color: #bee3f8; margin-left: auto; }
.nav { background: #fff; border-bottom: 1px solid #e2e8f0; padding: 0 12px; display: flex; flex-wrap: wrap; gap: 4px; }
.nav a { padding: 12px 14px; text-decoration: none; color: #4a5568; }
.nav a.active, .nav a:hover { color: #2b6cb0; border-bottom: 2px solid #2b6cb0; }
.main { padding: 20px; max-width: 1200px; margin: 0 auto; }
.card { background: #fff; border-radius: 8px; padding: 16px; margin-bottom: 16px; box-shadow: 0 1px 3px rgba(0,0,0,.08); }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { border-bottom: 1px solid #edf2f7; padding: 8px 10px; text-align: left; vertical-align: top; }
th { background: #f7fafc; }
.btn { display: inline-block; padding: 8px 14px; background: #2b6cb0; color: #fff; border: 0; border-radius: 4px; text-decoration: none; cursor: pointer; }
.btn.secondary { background: #718096; }
.btn.danger { background: #c53030; }
label { display: block; margin: 8px 0 4px; font-weight: 600; }
input, select, textarea { width: 100%; max-width: 480px; padding: 8px; border: 1px solid #cbd5e0; border-radius: 4px; }
textarea { max-width: 100%; min-height: 120px; }
.flash { padding: 10px 12px; border-radius: 4px; margin-bottom: 12px; }
.flash.ok { background: #c6f6d5; }
.flash.err { background: #fed7d7; }
.login-wrap { max-width: 360px; margin: 80px auto; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }
.stat { background: #ebf8ff; padding: 14px; border-radius: 6px; }
.stat strong { display: block; font-size: 22px; }
.filter-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.filter-row > div { min-width: 140px; }
.filter-actions { display: flex; gap: 8px; align-items: end; }
.pager a { margin-right: 12px; }
.muted { color: #718096; font-size: 13px; }
