 /* ________      ___    ___      ________  _______   ________          ________  ___  ___  ________  ___  ___  ___  ___     
|\   __  \    |\  \  /  /|    |\   ____\|\  ___ \ |\   __  \        |\   ____\|\  \|\  \|\   __  \|\  \|\  \|\  \|\  \    
\ \  \|\ /_   \ \  \/  / /    \ \  \___|\ \   __/|\ \  \|\  \       \ \  \___|\ \  \\\  \ \  \|\  \ \  \\\  \ \  \\\  \   
 \ \   __  \   \ \    / /      \ \_____  \ \  \_|/_\ \  \\\  \       \ \  \    \ \  \\\  \ \   ____\ \  \\\  \ \   __  \  
  \ \  \|\  \   \/  /  /        \|____|\  \ \  \_|\ \ \  \\\  \       \ \  \____\ \  \\\  \ \  \___|\ \  \\\  \ \  \ \  \ 
   \ \_______\__/  / /            ____\_\  \ \_______\ \_______\       \ \_______\ \_______\ \__\    \ \_______\ \__\ \__\
    \|_______|\___/ /            |\_________\|_______|\|_______|        \|_______|\|_______|\|__|     \|_______|\|__|\|__|
             \|___|/             \|_________|                                                                              */
:root {
  --admin-bg: #0d0d0d;
  --admin-surface: #171717;
  --admin-card: #1f1f1f;
  --admin-border: #2a2a2a;
  --admin-primary: #cc0000;
  --admin-primary-hover: #b30000;
  --admin-gold: #ffc107;
  --admin-blue: #007bff;
  --admin-green: #28a745;
  --admin-danger: #dc3545;
  --admin-text: #ffffff;
  --admin-muted: #a0a0a0;
  --admin-sidebar-w: 250px;
}

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

body {
  background-color: var(--admin-bg);
  color: var(--admin-text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
}

.admin-wrapper {
  display: flex;
  width: 100%;
  min-height: 100vh;
}

.admin-sidebar {
  width: var(--admin-sidebar-w);
  background-color: #121212;
  border-right: 1px solid var(--admin-border);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 100;
}

.sidebar-header {
  padding: 20px 18px;
  border-bottom: 1px solid var(--admin-border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar-brand {
  font-family: 'Impact', 'Arial Black', sans-serif;
  font-size: 20px;
  letter-spacing: 1px;
  color: var(--admin-gold);
  display: flex;
  align-items: center;
  gap: 6px;
}

.sidebar-brand span {
  color: var(--admin-primary);
}

.sidebar-badge {
  font-size: 10px;
  background: #2a0000;
  color: #ff6666;
  border: 1px solid #770000;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: sans-serif;
  font-weight: bold;
}

.sidebar-menu {
  list-style: none;
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.menu-category {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #666666;
  padding: 8px 10px 4px 10px;
  font-weight: 700;
}

.menu-item a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  color: var(--admin-muted);
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s ease;
  text-decoration: none;
}

.menu-item a:hover {
  background-color: #1f1f1f;
  color: #ffffff;
}

.menu-item.active a {
  background-color: var(--admin-primary);
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(204, 0, 0, 0.4);
}

.menu-icon {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

.sidebar-footer {
  padding: 16px 18px;
  border-top: 1px solid var(--admin-border);
  background: #0a0a0a;
}

.user-profile-badge {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #333333;
  color: var(--admin-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
}

.user-details {
  overflow: hidden;
}

.user-name {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-role {
  font-size: 11px;
  color: var(--admin-gold);
  text-transform: uppercase;
}

.admin-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background-color: var(--admin-bg);
}

.admin-navbar {
  background-color: var(--admin-surface);
  border-bottom: 1px solid var(--admin-border);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar-title {
  font-size: 18px;
  font-weight: 800;
  color: #ffffff;
}

.navbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-view-site {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: #222222;
  color: #dddddd;
  border: 1px solid #444444;
  padding: 6px 12px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-view-site:hover {
  background-color: #333333;
  color: #ffffff;
  border-color: #666666;
}

.btn-logout {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: #3a0000;
  color: #ff9999;
  border: 1px solid #770000;
  padding: 6px 12px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-logout:hover {
  background-color: var(--admin-primary);
  color: #ffffff;
}

.admin-body {
  padding: 24px;
  flex: 1;
}

.admin-alert {
  padding: 12px 18px;
  border-radius: 6px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 500;
}

.admin-alert.alert-success {
  background-color: #0e3016;
  border: 1px solid #1c6b32;
  color: #68e88e;
}

.admin-alert.alert-danger {
  background-color: #3a0e10;
  border: 1px solid #821f24;
  color: #f78b91;
}

.admin-alert.alert-info {
  background-color: #0e2a3a;
  border: 1px solid #1a5b82;
  color: #8be0f7;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}

.stat-card {
  background-color: var(--admin-surface);
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-3px);
  border-color: #444444;
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}

.stat-icon.red { background-color: rgba(204, 0, 0, 0.2); color: #ff3333; }
.stat-icon.gold { background-color: rgba(255, 193, 7, 0.2); color: #ffc107; }
.stat-icon.blue { background-color: rgba(0, 123, 255, 0.2); color: #3897f0; }
.stat-icon.green { background-color: rgba(40, 167, 69, 0.2); color: #28a745; }

.stat-info .stat-value {
  font-size: 26px;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
}

.stat-info .stat-label {
  font-size: 13px;
  color: var(--admin-muted);
  margin-top: 4px;
}

.admin-card {
  background-color: var(--admin-surface);
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 24px;
}

.card-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--admin-border);
}

.card-heading {
  font-size: 16px;
  font-weight: 800;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-primary {
  background-color: var(--admin-primary);
  color: #ffffff;
  border: none;
  padding: 9px 18px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.btn-primary:hover {
  background-color: var(--admin-primary-hover);
}

.btn-secondary {
  background-color: #2b2b2b;
  color: #ffffff;
  border: 1px solid #444444;
  padding: 8px 16px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background-color: #3b3b3b;
}

.btn-sm {
  padding: 5px 10px;
  font-size: 12px;
  border-radius: 4px;
}

.btn-danger {
  background-color: #721c24;
  color: #f8d7da;
  border: 1px solid #f5c6cb;
}

.btn-danger:hover {
  background-color: #dc3545;
  color: #ffffff;
}

.admin-table-wrapper {
  width: 100%;
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  text-align: left;
}

.admin-table th {
  background-color: #111111;
  padding: 12px 14px;
  font-weight: 700;
  color: #aaaaaa;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.5px;
  border-bottom: 2px solid var(--admin-border);
}

.admin-table td {
  padding: 14px;
  border-bottom: 1px solid #222222;
  color: #dddddd;
  vertical-align: middle;
}

.admin-table tr:hover td {
  background-color: #1a1a1a;
}

.table-thumb {
  width: 64px;
  height: 42px;
  object-fit: contain;
  border-radius: 4px;
  background-color: #ffffff;
  border: 1px solid #333333;
  padding: 2px;
}

.badge {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-success { background: #0e3016; color: #4ade80; border: 1px solid #166534; }
.badge-secondary { background: #262626; color: #a3a3a3; border: 1px solid #404040; }
.badge-gold { background: #3b2a00; color: #facc15; border: 1px solid #854d0e; }
.badge-blue { background: #0c2b4e; color: #60a5fa; border: 1px solid #1e40af; }

.status-toggle-btn {
  cursor: pointer;
  background: transparent;
  border: none;
  padding: 0;
  font-family: inherit;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #dddddd;
  margin-bottom: 8px;
}

.form-control {
  width: 100%;
  background-color: #121212;
  border: 1.5px solid var(--admin-border);
  border-radius: 6px;
  padding: 10px 14px;
  color: #ffffff;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
  border-color: var(--admin-primary);
  box-shadow: 0 0 8px rgba(204, 0, 0, 0.4);
}

.form-hint {
  font-size: 12px;
  color: #888888;
  margin-top: 6px;
}

.input-group {
  display: flex;
  gap: 8px;
}

.input-group .form-control {
  flex: 1;
}

.thumb-preview-box {
  width: 160px;
  height: 90px;
  border-radius: 6px;
  border: 2px dashed #444444;
  background-color: #0c0c0c;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-top: 10px;
}

.thumb-preview-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.login-container {
  width: 100%;
  max-width: 420px;
  margin: 80px auto;
  padding: 32px;
  background-color: var(--admin-surface);
  border: 1.5px solid var(--admin-border);
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
}

.login-header {
  text-align: center;
  margin-bottom: 28px;
}

.login-title {
  font-size: 22px;
  font-weight: 800;
  color: #ffffff;
  margin-top: 12px;
}

.login-subtitle {
  font-size: 13px;
  color: var(--admin-muted);
}

.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
}

.toast {
  background: #1f1f1f;
  border: 1px solid var(--admin-border);
  color: #ffffff;
  padding: 12px 18px;
  border-radius: 6px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@media (max-width: 768px) {
  .admin-wrapper {
    flex-direction: column;
  }
  .admin-sidebar {
    width: 100%;
    height: auto;
    position: relative;
  }
  .sidebar-menu {
    flex-direction: row;
    flex-wrap: wrap;
  }
}
