/* Reset all styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #e50914;
  --secondary: #b20710;
  --primary-light: #ff3b43;
  --primary-transparent: rgba(229, 9, 20, 0.1);
  --text: #ffffff;
  --text-secondary: #b3b3b3;
  --text-tertiary: #737373;
  --background: #141414;
  --surface: #1f1f1f;
  --surface-light: #2a2a2a;
  --surface-lighter: #333333;
  --border: #333333;
  --border-light: #444444;
  --success: #46d369;
  --success-bg: rgba(70, 211, 105, 0.15);
  --warning: #ffc107;
  --warning-bg: rgba(255, 193, 7, 0.15);
  --danger: #dc3545;
  --danger-bg: rgba(220, 53, 69, 0.15);
  --info: #0071eb;
  --info-bg: rgba(0, 113, 235, 0.15);
  --shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.3);
  --sidebar-width: 250px;
  --header-height: 64px;
}

body {
  font-family: "Montserrat", sans-serif;
  color: var(--text);
  line-height: 1.5;
  background-color: var(--background);
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Sidebar */
.sidebar {
  width: var(--sidebar-width);
  background-color: var(--surface);
  height: 100vh;
  position: fixed;
  left: 0;
  top: 0;
  overflow-y: auto;
  z-index: 100;
  border-right: 1px solid var(--border);
}

.sidebar-header {
  padding: 20px;
  border-bottom: 1px solid var(--border);
}

.sidebar-title {
  color: var(--text);
  font-family: "Playfair Display", serif;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0;
}

.sidebar-subtitle {
  color: var(--text-secondary);
  font-size: 0.875rem;
  margin-top: 5px;
}

.sidebar-nav {
  padding: 20px 0;
}

.nav-item {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
  border-left: 3px solid transparent;
}

.nav-item:hover {
  background-color: var(--surface-light);
  color: var(--text);
  border-left-color: var(--primary);
}

.nav-item.active {
  background-color: var(--primary-transparent);
  color: var(--text);
  border-left-color: var(--primary);
}

.nav-icon {
  margin-right: 12px;
  font-size: 20px;
}

.sidebar-footer {
  padding: 20px;
  border-top: 1px solid var(--border);
  color: var(--text-tertiary);
  font-size: 0.75rem;
  text-align: center;
  position: absolute;
  bottom: 0;
  width: 100%;
}

/* Main Content */
.main {
  flex: 1;
  margin-left: var(--sidebar-width);
  padding: 20px;
  transition: margin-left 0.3s ease;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.header-title {
  font-family: "Playfair Display", serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text);
}

.header-actions {
  display: flex;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  color: var(--text);
  border: none;
  border-radius: 4px;
  font-family: "Montserrat", sans-serif;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow);
}

.btn:hover {
  background: linear-gradient(90deg, var(--primary-light), var(--primary));
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.btn-outline:hover {
  background-color: var(--surface-light);
  color: var(--text);
  border-color: var(--primary);
}

.btn-icon {
  margin-right: 8px;
  font-size: 18px;
}

/* Dashboard Grid */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background-color: var(--surface);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 20px;
  display: flex;
  align-items: center;
  border: 1px solid var(--border);
  transition: all 0.3s ease;
  position: relative;
}

.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-light);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 16px;
  color: var(--text);
}
.card-icon.plans {
  background-color: rgba(0, 113, 235, 0.15);
  color: #0071eb;
}

.stat-icon.info {
  background-color: rgba(0, 113, 235, 0.15);
  color: #0071eb;
}

.stat-icon.primary {
  background-color: var(--primary-transparent);
  color: var(--primary);
}

.stat-icon.success {
  background-color: var(--success-bg);
  color: var(--success);
}

.stat-icon.warning {
  background-color: var(--warning-bg);
  color: var(--warning);
}

.stat-data {
  flex: 1;
}

.stat-value {
  font-size: 24px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--text);
}

.stat-label {
  font-size: 14px;
  color: var(--text-secondary);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  margin-bottom: 24px;
}

.card {
  background-color: var(--surface);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-light);
}

.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text);
}

.card-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
}

.card-icon.profile {
  background-color: var(--primary-transparent);
  color: var(--primary);
}

.card-icon.calendar {
  background-color: var(--success-bg);
  color: var(--success);
}

.card-icon.volunteer {
  background-color: var(--warning-bg);
  color: var(--warning);
}

.card-body {
  padding: 20px;
  flex: 1;
}

.card-text {
  color: var(--text-secondary);
  margin-bottom: 16px;
  font-size: 0.9rem;
  line-height: 1.5;
}

.card-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  text-align: right;
}

/* Mobile Responsive */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  font-size: 24px;
  cursor: pointer;
}

@media (max-width: 992px) {
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }

  .sidebar.active {
    transform: translateX(0);
  }

  .main {
    margin-left: 0;
  }

  .menu-toggle {
    display: block;
    margin-right: 16px;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 576px) {
  .stats {
    grid-template-columns: 1fr;
  }

  .header-actions {
    margin-top: 16px;
    width: 100%;
    justify-content: flex-end;
  }

  .header {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-title-container {
    width: 100%;
    display: flex;
    align-items: center;
  }
}

/* Overlay for mobile sidebar */
.overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(3px);
  z-index: 99;
}

.overlay.active {
  display: block;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--surface);
}

::-webkit-scrollbar-thumb {
  background-color: var(--border);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background-color: var(--text-tertiary);
}

.stat-link {
  position: absolute;
  bottom: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  text-decoration: none;
  opacity: 0;
  transition: all 0.3s ease;
}

.stat-card:hover .stat-link {
  opacity: 1;
}

.stat-link:hover {
  background-color: var(--primary);
  color: white;
  transform: scale(1.1);
}

.stat-link .material-symbols-outlined {
  font-size: 18px;
}
