* { box-sizing: border-box; }
body {
    font-family: system-ui, -apple-system, sans-serif;
    background: #0f0f10;
    color: #e5e5e5;
    margin: 0;
}
a { color: #7dd3fc; }
.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1.5rem;
    background: #17181a;
    border-bottom: 1px solid #2a2a2d;
}
.topbar .brand { font-weight: 700; color: #fff; }
.nav { display: flex; gap: 1.25rem; }
.nav a { text-decoration: none; color: #aaa; font-size: 0.9rem; }
.nav a:hover, .nav a.active { color: #fff; }
.user-menu { font-size: 0.85rem; color: #999; display: flex; align-items: center; gap: 0.75rem; }
.container { max-width: 1100px; margin: 0 auto; padding: 2rem 1.5rem; }
.card {
    background: #1a1b1d;
    border: 1px solid #2a2a2d;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.card h2 { margin-top: 0; font-size: 1.05rem; }
table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
th, td { text-align: left; padding: 0.5rem 0.6rem; border-bottom: 1px solid #2a2a2d; }
th { color: #999; font-weight: 600; font-size: 0.8rem; text-transform: uppercase; }
tr:hover td { background: #202124; }
.btn {
    display: inline-block;
    padding: 0.45rem 0.9rem;
    border-radius: 6px;
    border: 1px solid #333;
    background: #232427;
    color: #eee;
    text-decoration: none;
    font-size: 0.85rem;
    cursor: pointer;
}
.btn:hover { background: #2b2c30; }
.btn-primary { background: #2563eb; border-color: #2563eb; color: #fff; }
.btn-primary:hover { background: #1d4ed8; }
.btn-danger { background: #dc2626; border-color: #dc2626; color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-sm { padding: 0.25rem 0.6rem; font-size: 0.78rem; }
input[type=text], input[type=password], input[type=number], select {
    width: 100%;
    padding: 0.5rem 0.6rem;
    background: #111214;
    border: 1px solid #333;
    border-radius: 6px;
    color: #eee;
    font-size: 0.9rem;
}
label { display: block; font-size: 0.8rem; color: #999; margin-bottom: 0.3rem; margin-top: 0.9rem; }
.form-row { margin-bottom: 0.5rem; }
.alert {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}
.alert-error { background: #3b1418; color: #fca5a5; border: 1px solid #7f1d1d; }
.alert-success { background: #0f2e1c; color: #86efac; border: 1px solid #14532d; }
.badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 600;
}
.badge-owner { background: #3b0764; color: #d8b4fe; }
.badge-admin { background: #1e3a8a; color: #93c5fd; }
.badge-moderator { background: #164e63; color: #67e8f9; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1rem; }
.stat { background: #1a1b1d; border: 1px solid #2a2a2d; border-radius: 10px; padding: 1.2rem; }
.stat .num { font-size: 1.8rem; font-weight: 700; color: #fff; }
.stat .label { font-size: 0.8rem; color: #999; margin-top: 0.25rem; }
.login-wrap { display: flex; align-items: center; justify-content: center; min-height: 100vh; }
.login-box { width: 340px; background: #1a1b1d; border: 1px solid #2a2a2d; border-radius: 12px; padding: 2rem; }
.login-box h1 { font-size: 1.2rem; text-align: center; margin-bottom: 1.5rem; }
.muted { color: #999; font-size: 0.85rem; }
.grade-row { display: grid; grid-template-columns: 1fr 1fr 1fr auto auto; gap: 0.5rem; align-items: center; margin-bottom: 0.4rem; }
