:root{
  --bg:#f4f7fb;
  --sidebar:#0f172a;
  --sidebar2:#111c34;
  --primary:#5b6cff;
  --primary2:#8b5cf6;
  --text:#172033;
  --muted:#64748b;
  --card:#ffffff;
  --line:#e5e7eb;
}
*{box-sizing:border-box}
body.app-body{background:var(--bg);color:var(--text);font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
a{text-decoration:none}
.login-page{min-height:100vh;background:radial-gradient(circle at 15% 5%, rgba(91,108,255,.45), transparent 35%),radial-gradient(circle at 85% 20%, rgba(139,92,246,.4), transparent 30%),linear-gradient(135deg,#061027,#111827 55%,#020617);display:flex;align-items:center;justify-content:center;padding:24px}
.login-card{max-width:440px;width:100%;border:1px solid rgba(255,255,255,.14);background:rgba(255,255,255,.94);backdrop-filter:blur(18px);border-radius:28px;box-shadow:0 28px 80px rgba(0,0,0,.35)}
.login-logo{width:64px;height:64px;border-radius:20px;background:linear-gradient(135deg,var(--primary),var(--primary2));color:white;display:grid;place-items:center;font-size:30px;box-shadow:0 12px 30px rgba(91,108,255,.35)}
.app-shell{display:flex;min-height:100vh}.sidebar{position:fixed;left:0;top:0;width:280px;height:100vh;background:linear-gradient(180deg,var(--sidebar),var(--sidebar2));color:white;padding:22px;display:flex;flex-direction:column;z-index:20;box-shadow:18px 0 50px rgba(15,23,42,.18);overflow:hidden}
.brand-link{display:flex;gap:12px;align-items:center;color:white;margin-bottom:28px}.brand-link:hover{color:white}.brand-icon{width:46px;height:46px;border-radius:16px;display:grid;place-items:center;background:linear-gradient(135deg,var(--primary),var(--primary2));box-shadow:0 10px 24px rgba(91,108,255,.4)}.brand-link small{display:block;color:#94a3b8;font-size:12px;margin-top:-2px}.sidebar-nav{display:grid;gap:6px;overflow-y:auto;overflow-x:hidden;flex:1;min-height:0;padding-right:4px;scrollbar-width:thin;scrollbar-color:rgba(255,255,255,.35) transparent}.sidebar-nav::-webkit-scrollbar{width:6px}.sidebar-nav::-webkit-scrollbar-thumb{background:rgba(255,255,255,.25);border-radius:999px}.sidebar-nav a{display:flex;align-items:center;gap:12px;color:#cbd5e1;border-radius:14px;padding:12px 14px;font-weight:600}.sidebar-nav a:hover,.sidebar-nav a.active{color:white;background:rgba(255,255,255,.10)}.sidebar-section{font-size:11px;text-transform:uppercase;letter-spacing:.08em;color:#64748b;font-weight:800;margin:14px 10px 4px}.sidebar-footer{margin-top:14px;padding:16px;border-radius:18px;background:rgba(255,255,255,.08);border:1px solid rgba(255,255,255,.08)}
.content-area{margin-left:280px;width:calc(100% - 280px)}.topbar{position:sticky;top:0;background:rgba(244,247,251,.82);backdrop-filter:blur(14px);border-bottom:1px solid rgba(226,232,240,.85);padding:20px 30px;display:flex;align-items:center;justify-content:space-between;z-index:10}.page-wrap{padding:28px 30px}.premium-card{background:var(--card);border:1px solid rgba(226,232,240,.9);border-radius:24px;box-shadow:0 14px 40px rgba(15,23,42,.06)}.stat-card{padding:22px}.stat-icon{width:46px;height:46px;border-radius:16px;display:grid;place-items:center;background:#eef2ff;color:var(--primary);font-size:22px}.stat-value{font-size:30px;font-weight:800;letter-spacing:-.04em}.table{vertical-align:middle}.table th{font-size:12px;text-transform:uppercase;letter-spacing:.06em;color:#64748b;font-weight:800}.badge-soft{background:#eef2ff;color:#4338ca;border:1px solid #c7d2fe}.status-dot{width:9px;height:9px;border-radius:50%;display:inline-block;margin-right:6px}.dot-active{background:#22c55e}.dot-suspended,.dot-revoked,.dot-expired,.dot-blocked{background:#ef4444}.dot-trial{background:#f59e0b}.code-box,code{background:#f8fafc;border:1px solid #e2e8f0;border-radius:12px;padding:10px;color:#0f172a}.code-inline{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono",monospace;font-size:13px}.copy-text,.copy-btn{cursor:pointer}.form-control,.form-select{border-radius:14px;border-color:#dbe3ef;padding:.72rem .9rem}.btn{border-radius:13px;font-weight:700}.btn-primary{background:linear-gradient(135deg,var(--primary),var(--primary2));border:0}.btn-outline-primary{border-color:#c7d2fe}.btn-outline-primary:hover{background:var(--primary);border-color:var(--primary)}.section-title{font-weight:800;letter-spacing:-.03em}.empty-state{padding:46px;text-align:center;color:var(--muted)}
@media(max-width: 992px){.sidebar{position:relative;width:100%;height:auto}.app-shell{display:block}.content-area{margin-left:0;width:100%}.topbar{position:relative;align-items:flex-start;gap:12px;flex-direction:column}.page-wrap{padding:18px}.sidebar-footer{display:none}}

.invoice-print-header{display:none}.invoice-total-row{font-size:18px;font-weight:800}.amount-cell{text-align:right;white-space:nowrap}.mini-metric{padding:14px 16px;border:1px solid #e2e8f0;border-radius:18px;background:#f8fafc}.role-badge{background:#ecfeff;color:#155e75;border:1px solid #a5f3fc}.status-pill{display:inline-flex;align-items:center;gap:6px;border-radius:999px;padding:4px 10px;font-weight:700;font-size:12px}.status-draft{background:#f1f5f9;color:#334155}.status-sent{background:#eef2ff;color:#4338ca}.status-partial{background:#fef3c7;color:#92400e}.status-paid{background:#dcfce7;color:#166534}.status-overdue,.status-void{background:#fee2e2;color:#991b1b}.status-active{background:#dcfce7;color:#166534}.status-disabled{background:#fee2e2;color:#991b1b}.status-archived{background:#f1f5f9;color:#475569}
@media print{.sidebar,.topbar,footer,.no-print,.alert{display:none!important}.content-area{margin-left:0!important;width:100%!important}.page-wrap{padding:0!important}.premium-card{box-shadow:none!important;border:0!important;border-radius:0!important}.invoice-print-header{display:block}.app-body{background:#fff!important}.table th,.table td{padding:.45rem}}

.feature-chip{display:inline-flex;align-items:center;gap:6px;border-radius:999px;padding:4px 10px;background:#f8fafc;border:1px solid #e2e8f0;font-size:12px;font-weight:700;color:#334155}.feature-chip.on{background:#dcfce7;color:#166534;border-color:#bbf7d0}.feature-chip.off{background:#fee2e2;color:#991b1b;border-color:#fecaca}.permission-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:10px}.export-card{border:1px dashed #cbd5e1;background:#f8fafc;border-radius:20px;padding:18px}.status-expired,.status-blocked{background:#fee2e2;color:#991b1b}.status-trial{background:#fef3c7;color:#92400e}.status-watchlist{background:#fff7ed;color:#9a3412}.status-suspended,.status-revoked{background:#fee2e2;color:#991b1b}
