/* ============================================================
   Virexion Hosting — Design System
   Red & Black Glassmorphism UI
   ============================================================ */

:root {
  /* Color Palette */
  --brand-red:        #e63946;
  --brand-red-dark:   #b71c1c;
  --brand-red-glow:   rgba(230, 57, 70, 0.4);
  --brand-red-soft:   rgba(230, 57, 70, 0.15);

  --bg-void:          #050507;
  --bg-deep:          #0a0a0f;
  --bg-dark:          #0f0f17;
  --bg-card:          rgba(15, 15, 25, 0.75);
  --bg-card-hover:    rgba(20, 20, 35, 0.85);
  --bg-input:         rgba(255,255,255,0.05);
  --bg-input-focus:   rgba(230,57,70,0.08);

  --glass-border:     rgba(255,255,255,0.07);
  --glass-border-red: rgba(230,57,70,0.25);
  --glass-shine:      rgba(255,255,255,0.03);

  --text-primary:     #f0f0f8;
  --text-secondary:   #9090a8;
  --text-muted:       #505068;
  --text-red:         #e63946;
  --text-green:       #4caf50;
  --text-yellow:      #ffb300;
  --text-blue:        #42a5f5;

  --status-online:    #4caf50;
  --status-offline:   #f44336;
  --status-warning:   #ffb300;
  --status-pending:   #42a5f5;

  --sidebar-w:        260px;
  --header-h:         60px;
  --radius-sm:        6px;
  --radius-md:        10px;
  --radius-lg:        16px;
  --radius-xl:        24px;

  --shadow-red:       0 4px 30px rgba(230,57,70,0.2);
  --shadow-card:      0 8px 32px rgba(0,0,0,0.5);
  --shadow-glow:      0 0 20px rgba(230,57,70,0.3);

  --transition:       all 0.2s cubic-bezier(0.4,0,0.2,1);
  --font:             'Inter', 'Segoe UI', system-ui, sans-serif;
  --font-mono:        'JetBrains Mono', 'Fira Code', monospace;
}

/* ======================== RESET ======================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg-void);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

a { color: var(--brand-red); text-decoration: none; transition: var(--transition); }
a:hover { color: #ff6b6b; }

button { cursor: pointer; font-family: inherit; border: none; background: none; }
input, select, textarea { font-family: inherit; outline: none; }

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--brand-red-dark); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--brand-red); }

/* ======================== BACKGROUND ======================== */
.app-bg {
  position: fixed; inset: 0; z-index: -1;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(230,57,70,0.06) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 80%, rgba(100,20,30,0.08) 0%, transparent 60%),
    radial-gradient(ellipse at 50% 50%, rgba(15,5,10,0.4) 0%, transparent 100%),
    var(--bg-void);
}
.app-bg::after {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

/* ======================== GLASS CARD ======================== */
.glass {
  background: var(--bg-card);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card), inset 0 1px 0 var(--glass-shine);
}
.glass-red {
  background: rgba(20, 5, 8, 0.8);
  border-color: var(--glass-border-red);
  box-shadow: var(--shadow-card), var(--shadow-red), inset 0 1px 0 rgba(230,57,70,0.1);
}

/* ======================== LAYOUT ======================== */
#app { display: flex; min-height: 100vh; }

/* ======================== SIDEBAR ======================== */
.sidebar {
  width: var(--sidebar-w);
  min-height: 100vh;
  background: rgba(8, 8, 15, 0.9);
  backdrop-filter: blur(20px);
  border-right: 1px solid var(--glass-border);
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0; top: 0; bottom: 0;
  z-index: 100;
  transition: transform 0.3s ease;
  overflow-y: auto;
  overflow-x: hidden;
}
.sidebar-logo {
  padding: 20px 20px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--glass-border);
}
.sidebar-logo-icon {
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-glow);
  flex-shrink: 0;
  overflow: hidden;
  background: rgba(230,57,70,0.08);
}
.sidebar-logo-icon img {
  width: 100%; height: 100%;
  object-fit: contain;
  display: block;
}
.sidebar-logo-text { font-size: 16px; font-weight: 700; color: var(--text-primary); }
.sidebar-logo-sub { font-size: 10px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.1em; }

.sidebar-section { padding: 12px 0 4px; }
.sidebar-section-label {
  padding: 0 16px 6px;
  font-size: 10px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--text-muted);
}
.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 16px;
  margin: 1px 8px;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: 13.5px; font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}
.nav-item:hover { background: rgba(255,255,255,0.05); color: var(--text-primary); }
.nav-item.active {
  background: var(--brand-red-soft);
  color: var(--brand-red);
  border: 1px solid var(--glass-border-red);
}
.nav-item.active::before {
  content: '';
  position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 60%;
  background: var(--brand-red);
  border-radius: 0 2px 2px 0;
  margin-left: -8px;
}
.nav-icon { width: 18px; height: 18px; flex-shrink: 0; opacity: 0.8; }
.nav-badge {
  margin-left: auto;
  background: var(--brand-red);
  color: #fff;
  font-size: 10px; font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
}

.sidebar-footer {
  margin-top: auto;
  padding: 16px;
  border-top: 1px solid var(--glass-border);
}
.sidebar-user {
  display: flex; align-items: center; gap: 10px;
  padding: 8px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}
.sidebar-user:hover { background: rgba(255,255,255,0.05); }
.sidebar-avatar {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, var(--brand-red), var(--brand-red-dark));
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff;
  flex-shrink: 0;
}
.sidebar-user-name { font-size: 13px; font-weight: 600; }
.sidebar-user-role { font-size: 11px; color: var(--text-muted); }

/* ======================== MAIN CONTENT ======================== */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  height: var(--header-h);
  background: rgba(8,8,15,0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--glass-border);
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 16px;
  position: sticky; top: 0; z-index: 50;
}
.topbar-title { font-size: 16px; font-weight: 600; }
.topbar-breadcrumb { font-size: 12px; color: var(--text-muted); }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 12px; }

.content { padding: 24px; flex: 1; }

/* ======================== BUTTONS ======================== */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 500;
  transition: var(--transition);
  cursor: pointer;
  white-space: nowrap;
}
.btn-primary {
  background: linear-gradient(135deg, var(--brand-red), var(--brand-red-dark));
  color: #fff;
  border: 1px solid transparent;
  box-shadow: 0 2px 12px rgba(230,57,70,0.3);
}
.btn-primary:hover {
  background: linear-gradient(135deg, #ff4d5a, var(--brand-red));
  box-shadow: 0 4px 20px rgba(230,57,70,0.5);
  transform: translateY(-1px);
}
.btn-secondary {
  background: rgba(255,255,255,0.06);
  color: var(--text-primary);
  border: 1px solid var(--glass-border);
}
.btn-secondary:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.15); }
.btn-danger {
  background: rgba(244,67,54,0.12);
  color: #f44336;
  border: 1px solid rgba(244,67,54,0.25);
}
.btn-danger:hover { background: rgba(244,67,54,0.2); }
.btn-ghost { color: var(--text-secondary); padding: 6px 10px; }
.btn-ghost:hover { color: var(--text-primary); background: rgba(255,255,255,0.05); }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-lg { padding: 11px 24px; font-size: 14px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }
.btn-icon { width: 32px; height: 32px; padding: 0; justify-content: center; border-radius: var(--radius-sm); }

/* ======================== FORMS ======================== */
.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 12px; font-weight: 500; color: var(--text-secondary); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.05em; }
.form-control {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 13.5px;
  transition: var(--transition);
}
.form-control:focus {
  background: var(--bg-input-focus);
  border-color: var(--brand-red);
  box-shadow: 0 0 0 3px rgba(230,57,70,0.12);
}
.form-control::placeholder { color: var(--text-muted); }
select.form-control option { background: var(--bg-dark); color: var(--text-primary); }
textarea.form-control { resize: vertical; min-height: 80px; }
.form-hint { font-size: 11px; color: var(--text-muted); margin-top: 4px; }
.form-error { font-size: 11px; color: var(--brand-red); margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ======================== STATS GRID ======================== */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card {
  padding: 20px;
  display: flex; align-items: flex-start; gap: 14px;
}
.stat-icon {
  width: 44px; height: 44px;
  background: var(--brand-red-soft);
  border: 1px solid var(--glass-border-red);
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0;
}
.stat-value { font-size: 26px; font-weight: 700; line-height: 1; margin-bottom: 4px; }
.stat-label { font-size: 12px; color: var(--text-secondary); }
.stat-trend { font-size: 11px; margin-top: 4px; }
.stat-trend.up { color: var(--status-online); }
.stat-trend.down { color: var(--status-offline); }

/* ======================== TABLE ======================== */
.table-container { overflow-x: auto; border-radius: var(--radius-md); }
table { width: 100%; border-collapse: collapse; }
thead { background: rgba(230,57,70,0.06); }
th {
  padding: 10px 14px;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--text-muted);
  text-align: left;
  border-bottom: 1px solid var(--glass-border);
  white-space: nowrap;
}
td {
  padding: 12px 14px;
  font-size: 13px;
  color: var(--text-primary);
  border-bottom: 1px solid rgba(255,255,255,0.03);
  vertical-align: middle;
}
tr:last-child td { border-bottom: none; }
tbody tr { transition: var(--transition); }
tbody tr:hover { background: rgba(255,255,255,0.02); }

/* ======================== BADGES ======================== */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.05em;
}
.badge-green { background: rgba(76,175,80,0.15); color: var(--status-online); border: 1px solid rgba(76,175,80,0.25); }
.badge-red { background: rgba(244,67,54,0.15); color: var(--status-offline); border: 1px solid rgba(244,67,54,0.25); }
.badge-yellow { background: rgba(255,179,0,0.15); color: var(--status-warning); border: 1px solid rgba(255,179,0,0.25); }
.badge-blue { background: rgba(66,165,245,0.15); color: var(--status-pending); border: 1px solid rgba(66,165,245,0.25); }
.badge-gray { background: rgba(255,255,255,0.07); color: var(--text-secondary); border: 1px solid var(--glass-border); }
.badge-dot::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

/* ======================== MODAL ======================== */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  opacity: 0; visibility: hidden;
  transition: all 0.25s ease;
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal {
  width: 100%; max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 28px;
  transform: scale(0.95) translateY(20px);
  transition: all 0.25s ease;
}
.modal-overlay.open .modal { transform: scale(1) translateY(0); }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.modal-title { font-size: 18px; font-weight: 700; }
.modal-close { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: var(--radius-sm); color: var(--text-muted); transition: var(--transition); font-size: 20px; }
.modal-close:hover { background: rgba(255,255,255,0.05); color: var(--text-primary); }
.modal-footer { display: flex; gap: 8px; justify-content: flex-end; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--glass-border); }

/* ======================== ALERTS ======================== */
.alert { padding: 12px 16px; border-radius: var(--radius-md); display: flex; align-items: flex-start; gap: 10px; font-size: 13px; margin-bottom: 16px; }
.alert-success { background: rgba(76,175,80,0.1); border: 1px solid rgba(76,175,80,0.25); color: #81c784; }
.alert-danger { background: rgba(244,67,54,0.1); border: 1px solid rgba(244,67,54,0.25); color: #ef9a9a; }
.alert-warning { background: rgba(255,179,0,0.1); border: 1px solid rgba(255,179,0,0.25); color: #ffcc80; }
.alert-info { background: rgba(66,165,245,0.1); border: 1px solid rgba(66,165,245,0.25); color: #90caf9; }

/* ======================== TOAST ======================== */
#toast-container { position: fixed; bottom: 24px; right: 24px; z-index: 9999; display: flex; flex-direction: column; gap: 8px; }
.toast {
  padding: 12px 16px;
  background: rgba(15,15,25,0.95);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(20px);
  display: flex; align-items: center; gap: 10px;
  font-size: 13px;
  min-width: 280px; max-width: 380px;
  animation: toastIn 0.3s ease;
  border-left: 3px solid var(--brand-red);
}
.toast.success { border-left-color: var(--status-online); }
.toast.error { border-left-color: var(--status-offline); }
.toast.warning { border-left-color: var(--status-warning); }
@keyframes toastIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes toastOut { from { transform: translateX(0); opacity: 1; } to { transform: translateX(100%); opacity: 0; } }

/* ======================== PROGRESS / LOADER ======================== */
.spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,0.1);
  border-top-color: var(--brand-red);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}
.spinner-lg { width: 36px; height: 36px; border-width: 3px; }
@keyframes spin { to { transform: rotate(360deg); } }
.progress-bar { width: 100%; height: 6px; background: rgba(255,255,255,0.07); border-radius: 3px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--brand-red-dark), var(--brand-red)); border-radius: 3px; transition: width 0.5s ease; }

/* ======================== TABS ======================== */
.tabs { display: flex; gap: 2px; margin-bottom: 20px; background: rgba(255,255,255,0.03); border-radius: var(--radius-md); padding: 4px; }
.tab { padding: 7px 16px; font-size: 13px; font-weight: 500; border-radius: var(--radius-sm); cursor: pointer; color: var(--text-muted); transition: var(--transition); }
.tab.active { background: var(--brand-red-soft); color: var(--brand-red); border: 1px solid var(--glass-border-red); }
.tab:hover:not(.active) { color: var(--text-primary); background: rgba(255,255,255,0.04); }

/* ======================== CHARTS (CSS-based) ======================== */
.metric-chart { height: 120px; position: relative; overflow: hidden; }
.chart-bars { display: flex; align-items: flex-end; gap: 3px; height: 100%; padding: 0 4px; }
.chart-bar { flex: 1; border-radius: 2px 2px 0 0; background: linear-gradient(180deg, var(--brand-red), var(--brand-red-dark)); opacity: 0.7; min-height: 4px; transition: height 0.5s ease; }
.chart-bar:hover { opacity: 1; }

/* ======================== CODE / TERMINAL ======================== */
.code-block { background: rgba(0,0,0,0.4); border: 1px solid var(--glass-border); border-radius: var(--radius-md); padding: 16px; font-family: var(--font-mono); font-size: 12.5px; color: #a8d8a8; overflow-x: auto; line-height: 1.7; }

/* ======================== EMPTY STATE ======================== */
.empty-state { text-align: center; padding: 60px 20px; }
.empty-icon { font-size: 48px; margin-bottom: 16px; opacity: 0.4; }
.empty-title { font-size: 18px; font-weight: 600; margin-bottom: 8px; color: var(--text-secondary); }
.empty-text { font-size: 13px; color: var(--text-muted); max-width: 320px; margin: 0 auto 24px; }

/* ======================== PAGE HEADER ======================== */
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.page-title { font-size: 22px; font-weight: 700; }
.page-subtitle { font-size: 13px; color: var(--text-secondary); margin-top: 2px; }
.page-actions { display: flex; gap: 8px; }

/* ======================== SECTION CARD ======================== */
.section-card { padding: 20px; margin-bottom: 20px; }
.section-title { font-size: 15px; font-weight: 600; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.section-title::after { content: ''; flex: 1; height: 1px; background: var(--glass-border); }

/* ======================== RESOURCE USAGE ======================== */
.usage-bar { margin-bottom: 12px; }
.usage-header { display: flex; justify-content: space-between; font-size: 12px; margin-bottom: 6px; }
.usage-label { color: var(--text-secondary); }
.usage-value { font-weight: 600; }
.usage-fill { height: 8px; background: rgba(255,255,255,0.07); border-radius: 4px; overflow: hidden; }
.usage-fill-bar { height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--brand-red-dark), var(--brand-red)); transition: width 0.5s ease; }
.usage-fill-bar.warning { background: linear-gradient(90deg, #e65100, #ffb300); }
.usage-fill-bar.danger { background: linear-gradient(90deg, #b71c1c, #f44336); }

/* ======================== SERVICE STATUS ======================== */
.service-list { display: flex; flex-direction: column; gap: 8px; }
.service-item { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; background: rgba(255,255,255,0.02); border-radius: var(--radius-sm); border: 1px solid rgba(255,255,255,0.04); }
.service-name { font-size: 13px; font-weight: 500; }
.service-status { display: flex; align-items: center; gap: 6px; font-size: 12px; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--status-online); box-shadow: 0 0 6px currentColor; flex-shrink: 0; }
.status-dot.offline { background: var(--status-offline); }
.status-dot.warning { background: var(--status-warning); }

/* ======================== LICENSE BANNER ======================== */
.license-banner {
  background: linear-gradient(135deg, rgba(183,28,28,0.15), rgba(230,57,70,0.08));
  border: 1px solid rgba(230,57,70,0.3);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-bottom: 20px;
  display: flex; align-items: center; gap: 12px;
  font-size: 13px;
}

/* ======================== LOGIN PAGE ======================== */
.auth-page {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.auth-card {
  width: 100%; max-width: 420px;
  padding: 40px;
}
.auth-logo { text-align: center; margin-bottom: 32px; }
.auth-logo-icon {
  width: 56px; height: 56px;
  background: linear-gradient(135deg, var(--brand-red), var(--brand-red-dark));
  border-radius: var(--radius-md);
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 28px; font-weight: 900; color: #fff;
  box-shadow: var(--shadow-glow);
  margin-bottom: 16px;
}
.auth-title { font-size: 24px; font-weight: 700; margin-bottom: 4px; }
.auth-subtitle { font-size: 13px; color: var(--text-secondary); }

/* ======================== DROPDOWN ======================== */
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute; top: calc(100% + 6px); right: 0;
  min-width: 180px;
  background: rgba(12,12,20,0.97);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  z-index: 200;
  overflow: hidden;
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: all 0.15s ease;
}
.dropdown.open .dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-item { padding: 9px 14px; font-size: 13px; cursor: pointer; display: flex; align-items: center; gap: 8px; transition: var(--transition); color: var(--text-secondary); }
.dropdown-item:hover { background: rgba(255,255,255,0.05); color: var(--text-primary); }
.dropdown-item.danger { color: #ef5350; }
.dropdown-divider { height: 1px; background: var(--glass-border); margin: 4px 0; }

/* ======================== SEARCH ======================== */
.search-box { position: relative; }
.search-box input { padding-left: 34px; }
.search-icon { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--text-muted); font-size: 14px; pointer-events: none; }

/* ======================== TOGGLE ======================== */
.toggle { position: relative; display: inline-block; width: 36px; height: 20px; flex-shrink: 0; }
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider { position: absolute; inset: 0; background: rgba(255,255,255,0.1); border-radius: 10px; cursor: pointer; transition: var(--transition); }
.toggle-slider::before { content: ''; position: absolute; left: 2px; top: 2px; width: 16px; height: 16px; background: var(--text-secondary); border-radius: 50%; transition: var(--transition); }
.toggle input:checked + .toggle-slider { background: var(--brand-red); }
.toggle input:checked + .toggle-slider::before { transform: translateX(16px); background: #fff; }

/* ======================== PAGINATION ======================== */
.pagination { display: flex; gap: 4px; align-items: center; justify-content: center; margin-top: 20px; }
.page-btn { width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: var(--radius-sm); font-size: 13px; cursor: pointer; transition: var(--transition); color: var(--text-secondary); background: rgba(255,255,255,0.04); border: 1px solid var(--glass-border); }
.page-btn:hover { color: var(--text-primary); background: rgba(255,255,255,0.08); }
.page-btn.active { background: var(--brand-red); color: #fff; border-color: transparent; }

/* ======================== RESPONSIVE ======================== */
@media (max-width: 768px) {
  :root { --sidebar-w: 0px; }
  .sidebar { transform: translateX(-260px); }
  .sidebar.open { transform: translateX(0); width: 260px; }
  .main { margin-left: 0; }
  .form-row { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .page-header { flex-direction: column; align-items: flex-start; gap: 12px; }
}

/* ======================== ANIMATIONS ======================== */
@keyframes fadeIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }
.fade-in { animation: fadeIn 0.35s ease forwards; }
.pulse { animation: pulse 1.5s ease-in-out infinite; }

/* ======================== UTILITY ======================== */
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.text-sm { font-size: 12px; }
.text-muted { color: var(--text-muted); }
.text-red { color: var(--brand-red); }
.text-green { color: var(--status-online); }
.text-mono { font-family: var(--font-mono); font-size: 12px; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.full-width { width: 100%; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
.hidden { display: none !important; }


/* ======================== BRANDING UPDATES ======================== */
.auth-logo-wide {
  margin-bottom: 28px;
}
.auth-brand-logo {
  display: block;
  width: min(420px, 92vw);
  max-width: 100%;
  height: auto;
  margin: 0 auto 16px;
  object-fit: contain;
  filter: drop-shadow(0 0 20px rgba(230,57,70,0.24));
}
.panel-brand-header {
  width: 100%;
  min-height: 118px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px 24px;
  margin-bottom: 24px;
  background:
    radial-gradient(ellipse at center, rgba(230,57,70,0.10) 0%, rgba(10,10,15,0.74) 60%, rgba(5,5,7,0.80) 100%);
}
.panel-brand-logo {
  display: block;
  width: min(520px, 80%);
  max-height: 96px;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 24px rgba(230,57,70,0.24));
}
@media (max-width: 768px) {
  .auth-brand-logo { width: min(360px, 88vw); }
  .panel-brand-header { min-height: 92px; padding: 14px 16px; }
  .panel-brand-logo { width: min(360px, 90%); max-height: 72px; }
}
