/* ===== GLOBAL STYLES ===== */
:root {
  --primary: #003366;
  --secondary: #FFD700;
  --dark: #1a1a2e;
  --light: #f8f9fa;
  --danger: #dc3545;
  --success: #28a745;
  --warning: #ffc107;
}

/* ===== ADMIN DASHBOARD STYLES ===== */
body.admin-dashboard {
  display: flex;
  min-height: 100vh;
  background-color: #f5f5f5;
  margin: 0;
  font-family: 'Poppins', sans-serif;
}

/* Sidebar */
.sidebar {
  width: 250px;
  background: var(--primary);
  color: white;
  height: 100vh;
  position: fixed;
  transition: all 0.3s;
}

.sidebar-header {
  padding: 20px;
  background: rgba(0, 0, 0, 0.1);
  text-align: center;
}

.admin-profile {
  text-align: center;
  padding: 20px 0;
}

.admin-profile img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--secondary);
}

.admin-profile h4 {
  margin-top: 10px;
  font-weight: 600;
}

.sidebar-menu {
  padding: 0 10px;
}

.menu-item {
  margin-bottom: 5px;
}

.menu-item a {
  display: block;
  color: white;
  text-decoration: none;
  padding: 12px 15px;
  border-radius: 5px;
  transition: all 0.3s;
}

.menu-item a:hover, 
.menu-item a.active {
  background: rgba(255, 255, 255, 0.1);
  color: var(--secondary);
}

.menu-item i {
  margin-right: 10px;
  width: 20px;
  text-align: center;
}

/* Main Content */
.main-content {
  margin-left: 250px;
  width: calc(100% - 250px);
  padding: 20px;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  background: white;
  border-radius: 5px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  margin-bottom: 20px;
}

/* Cards */
.card {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
  padding: 20px;
  margin-bottom: 20px;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eee;
}

.card-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--primary);
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 30px;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: var(--primary);
}

input:checked + .slider:before {
  transform: translateX(30px);
}

/* Status Labels */
.status-text {
  font-weight: 500;
  margin-left: 10px;
}

.status-open {
  color: var(--success);
}

.status-closed {
  color: var(--danger);
}

/* Buttons */
.btn {
  padding: 8px 15px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s;
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover {
  background: #002147;
}

/* Alerts */
.alert {
  padding: 12px 15px;
  border-radius: 5px;
  margin-bottom: 20px;
}

.alert-success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

/* Settings Grid */
.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.setting-item {
  background: #f8f9fa;
  padding: 15px;
  border-radius: 5px;
  border-left: 4px solid var(--primary);
}

.setting-item label {
  display: block;
  font-weight: 500;
  margin-bottom: 5px;
}

.form-control {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  margin-bottom: 5px;
}

.text-muted {
  color: #6c757d;
  font-size: 0.85rem;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 15px;
}

.stat-card {
  padding: 15px;
  border-radius: 5px;
  color: white;
  text-align: center;
}

.stat-card h4 {
  font-size: 1rem;
  margin-bottom: 5px;
}

.stat-card p {
  font-size: 1.5rem;
  font-weight: bold;
  margin: 0;
}

.bg-primary { background: var(--primary); }
.bg-success { background: var(--success); }
.bg-danger { background: var(--danger); }
.bg-warning { background: var(--warning); color: #212529; }

/* Preview Box */
.preview-box {
  background: #f8f9fa;
  padding: 20px;
  border-radius: 5px;
  border: 1px dashed #ccc;
}

.preview-box h3 {
  color: var(--primary);
  margin-bottom: 15px;
}

/* Responsive */
@media (max-width: 768px) {
  .sidebar {
    width: 100%;
    height: auto;
    position: relative;
  }
  
  .main-content {
    margin-left: 0;
    width: 100%;
  }
  
  .settings-grid {
    grid-template-columns: 1fr;
  }
  
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}