:root {
    --bg: #eef2f7;
    --panel: #ffffff;
    --panel-2: #f8fafc;
    --line: rgba(15, 23, 42, 0.08);
    --text: #1e293b;
    --muted: #64748b;
    --primary: #5e72e4;
    --primary-2: #825ee4;
    --success: #2dce89;
    --warning: #fb8c00;
    --danger: #f5365c;
    --yellow: #f4d03f;
    --green: #58d68d;
    --shadow: 0 20px 45px rgba(15, 23, 42, 0.08);
    --radius: 20px;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: #f5f7fb; color: var(--text); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.auth-body { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: linear-gradient(135deg,#f5f7fb,#eef2f7); }
.auth-card, .installer-card { width: min(980px, 100%); background: var(--panel); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: 28px; padding: 32px; }
.auth-card { max-width: 540px; }
.auth-top, .brand-card { display: flex; gap: 18px; align-items: center; margin-bottom: 22px; }
.auth-top h1, .topbar h2, .brand-card h1 { margin: 0 0 6px; }
.auth-top p, .panel-header p, .muted { color: var(--muted); margin: 0; }
.auth-avatar, .brand-avatar { width: 68px; height: 68px; border-radius: 18px; object-fit: cover; box-shadow: 0 10px 30px rgba(94,114,228,.22); }
.brand-kicker { font-size: 12px; text-transform: uppercase; letter-spacing: .16em; color: #8898aa; margin-bottom: 4px; }
.app-shell { display: grid; grid-template-columns: 290px 1fr; min-height: 100vh; }
.sidebar { background: linear-gradient(180deg, #172b4d 0%, #1a174d 100%); color: #fff; padding: 24px; display: flex; flex-direction: column; justify-content: space-between; gap: 20px; }
.sidebar-footer { border-top: 1px solid rgba(255,255,255,0.12); padding-top: 20px; }
.nav-menu { display: grid; gap: 10px; margin-top: 26px; }
.nav-link, .btn { border-radius: 14px; transition: .2s ease; }
.nav-link { padding: 14px 16px; color: rgba(255,255,255,.86); background: rgba(255,255,255,0.05); border: 1px solid transparent; }
.nav-link:hover, .nav-link.active { background: linear-gradient(135deg, rgba(255,255,255,.16), rgba(255,255,255,.08)); border-color: rgba(255,255,255,0.18); transform: translateY(-1px); }
.content-area { padding: 28px; }
.topbar { display: flex; justify-content: space-between; gap: 16px; align-items: center; margin-bottom: 24px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-bottom: 22px; }
.stat-card, .panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.stat-card { padding: 22px; }
.stat-card span { color: var(--muted); display: block; margin-bottom: 8px; }
.stat-card strong { font-size: 28px; }
.panel { padding: 22px; }
.panel-header { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; min-width: 980px; }
th, td { padding: 16px 12px; border-bottom: 1px solid #edf2f7; text-align: left; vertical-align: middle; }
th { color: #8898aa; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
tr:hover td { background: #fafbff; }
.table-logo { width: 44px; height: 44px; border-radius: 14px; object-fit: cover; border: 1px solid var(--line); background: #fff; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.single-col { grid-template-columns: 1fr; }
label { display: block; margin-bottom: 8px; color: #344767; font-size: 14px; font-weight: 600; }
input, select, textarea { width: 100%; border-radius: 14px; border: 1px solid #d2d6da; background: #fff; color: var(--text); padding: 14px 15px; outline: none; }
input:focus, select:focus, textarea:focus { border-color: rgba(94,114,228,0.6); box-shadow: 0 0 0 4px rgba(94,114,228,0.12); }
textarea { resize: vertical; }
.full-width { grid-column: 1 / -1; }
.actions, .actions-end, .pagination { display: flex; gap: 8px; flex-wrap: wrap; }
.actions-end { justify-content: flex-end; }
.btn { display: inline-flex; justify-content: center; align-items: center; gap: 8px; padding: 12px 16px; cursor: pointer; border: none; color: white; font-weight: 700; }
.btn-sm { padding: 8px 12px; border-radius: 12px; font-size: 13px; }
.btn-primary { background: linear-gradient(135deg, var(--primary), var(--primary-2)); }
.btn-outline { background: transparent; border: 1px solid rgba(255,255,255,0.16); color: inherit; }
.content-area .btn-outline { color: #344767; border-color: #d2d6da; }
.btn-secondary { background: #8392ab; }
.btn-danger { background: var(--danger); }
.btn-warning { background: var(--warning); }
.btn-success { background: var(--success); }
.full { width: 100%; }
.badge { display: inline-flex; align-items: center; padding: 8px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.badge.success { background: rgba(45,206,137,0.15); color: #1a936f; }
.badge.warning { background: rgba(251,140,0,0.15); color: #b45309; }
.badge.danger { background: rgba(245,54,92,0.12); color: #c1121f; }
.alert { padding: 14px 16px; border-radius: 16px; margin-bottom: 18px; }
.alert.success { background: rgba(45,206,137,0.14); color: #1a936f; }
.alert.danger { background: rgba(245,54,92,0.14); color: #b91c1c; }
.alert.info { background: rgba(94,114,228,0.12); color: #3f51b5; }
.empty-state { text-align: center; color: var(--muted); }
.small-text { font-size: 12px; }
.text-success { color: #1a936f; }
.text-warning { color: #b45309; }
.text-danger { color: #c1121f; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.days-pill { display:inline-flex; align-items:center; justify-content:center; min-width:50px; height:38px; padding:0 14px; border-radius:999px; font-weight:800; }
.days-red { background:#e74c3c; color:#fff; }
.days-orange { background:#e67e22; color:#fff; }
.days-yellow { background:#f4d03f; color:#463c00; }
.days-green { background:#58d68d; color:#0f5132; }
.days-muted { background:#e5e7eb; color:#6b7280; }
.notification-card { display:flex; align-items:center; gap:12px; background:rgba(255,255,255,.1); padding:14px; border-radius:18px; }
.notification-icon { width:40px; height:40px; display:grid; place-items:center; background:rgba(255,255,255,.14); border-radius:12px; }
.mini-list { display:grid; gap:12px; }
.mini-item { display:flex; justify-content:space-between; align-items:center; gap:12px; padding:14px 16px; border-radius:18px; background:#fbfcff; border:1px solid #edf2f7; }
.mini-item h4 { margin:0 0 4px; }
.pagination { justify-content:flex-end; margin-top: 18px; }
.pagination a, .pagination span { padding:10px 14px; border-radius:12px; border:1px solid #d2d6da; color:#344767; background:#fff; }
.pagination .active { background:linear-gradient(135deg, var(--primary), var(--primary-2)); color:#fff; border-color:transparent; }
.settings-grid { display:grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap:18px; }
.code-note { padding:12px 14px; border-radius:14px; background:#f8fafc; border:1px dashed #cbd5e1; color:#475569; }
@media (max-width: 980px) { .app-shell { grid-template-columns: 1fr; } .sidebar { border-bottom: 1px solid var(--line); } .stats-grid, .settings-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .content-area, .sidebar, .auth-card, .installer-card { padding: 18px; } .stats-grid, .form-grid, .settings-grid { grid-template-columns: 1fr; } .topbar { flex-direction: column; align-items: stretch; } .actions-end .btn, .topbar .btn { width: 100%; } }
