/* styles.css - Global Monochrome & Silver Design System for Klasse 9e Portal */

:root {
  /* Default: Dark Mode Palette */
  --bg-main: #0a0c10;
  --bg-card: #12151e;
  --bg-card-hover: #1a1e2b;
  --bg-input: #0e1118;
  --bg-elevated: #1e2230;

  --border-color: #2a2e3d;
  --border-focus: #94a3b8;
  --border-silver: rgba(226, 232, 240, 0.25);

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  --accent-primary: #f8fafc;
  --accent-primary-text: #0a0c10;
  --accent-hover: #cbd5e1;

  --badge-bg: #1e2230;
  --badge-text: #e2e8f0;
  --badge-border: #3a3f54;

  --action-positive-bg: #f8fafc;
  --action-positive-text: #0a0c10;
  --action-negative-bg: #1e2230;
  --action-negative-text: #f8fafc;
  --action-negative-border: #3a3f54;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;

  --font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 10px 30px -5px rgba(0, 0, 0, 0.5);
}

/* Explicit Theme Overrides */
html[data-theme="dark"] {
  --bg-main: #0a0c10;
  --bg-card: #12151e;
  --bg-card-hover: #1a1e2b;
  --bg-input: #0e1118;
  --bg-elevated: #1e2230;

  --border-color: #2a2e3d;
  --border-focus: #94a3b8;
  --border-silver: rgba(226, 232, 240, 0.25);

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  --accent-primary: #f8fafc;
  --accent-primary-text: #0a0c10;
  --accent-hover: #cbd5e1;

  --badge-bg: #1e2230;
  --badge-text: #e2e8f0;
  --badge-border: #3a3f54;

  --action-positive-bg: #f8fafc;
  --action-positive-text: #0a0c10;
  --action-negative-bg: #1e2230;
  --action-negative-text: #f8fafc;
  --action-negative-border: #3a3f54;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 10px 30px -5px rgba(0, 0, 0, 0.5);
}

html[data-theme="light"] {
  --bg-main: #ffffff;
  --bg-card: #f8fafc;
  --bg-card-hover: #f1f5f9;
  --bg-input: #ffffff;
  --bg-elevated: #e2e8f0;

  --border-color: #e2e8f0;
  --border-focus: #475569;
  --border-silver: rgba(15, 23, 42, 0.15);

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;

  --accent-primary: #0f172a;
  --accent-primary-text: #ffffff;
  --accent-hover: #1e293b;

  --badge-bg: #f1f5f9;
  --badge-text: #0f172a;
  --badge-border: #cbd5e1;

  --action-positive-bg: #0f172a;
  --action-positive-text: #ffffff;
  --action-negative-bg: #f1f5f9;
  --action-negative-text: #0f172a;
  --action-negative-border: #cbd5e1;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 10px 25px -5px rgba(0, 0, 0, 0.08);
}

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

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  font-family: var(--font-family);
  min-height: 100vh;
  line-height: 1.5;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 16px 40px 16px;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.3s ease, color 0.3s ease;
  position: relative;
}

/* Global Top Navigation Bar */
.top-navbar {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  background-color: var(--bg-card);
  border-bottom: 1px solid var(--border-color);
  padding: 10px 16px;
  display: flex;
  justify-content: center;
  z-index: 900;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  margin-bottom: 16px;
}

.nav-content {
  width: 100%;
  max-width: 1400px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding-right: 140px;
  position: relative;
  box-sizing: border-box;
}

.nav-links {
  display: flex;
  flex-wrap: nowrap !important;
  white-space: nowrap;
  overflow-x: auto !important;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  gap: 6px 8px;
  align-items: center;
  flex: 1;
  min-width: 0;
  padding: 2px 10px 2px 2px;
  scroll-behavior: smooth;
}

.nav-links::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
  white-space: nowrap;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
  display: inline-flex;
  align-items: center;
}

.nav-link:hover {
  color: var(--text-primary);
  background-color: var(--bg-card-hover);
}

.nav-link.active {
  color: var(--text-primary);
  background-color: var(--bg-elevated);
}

.container {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
}

.text-center {
  text-align: center !important;
}

.text-center .badge {
  margin-left: auto;
  margin-right: auto;
}

.grid-centered {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
}

.grid-centered .card {
  width: 100%;
  max-width: 380px;
}

/* User Account & Theme Nav Buttons */
.user-nav-bar {
  position: fixed;
  top: 10px;
  right: 16px;
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 8px;
}

.user-icon-btn {
  background-color: var(--bg-card-hover);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
  min-height: 36px;
}

.user-icon-btn:hover {
  border-color: var(--border-focus);
}

/* Mobile Navigation Toggle Button & Dropdown Menu */
.nav-toggle-btn {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  min-width: 36px;
  height: 36px;
  min-height: 36px;
  padding: 0;
  margin-left: 6px;
  background-color: var(--bg-card-hover);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
  box-sizing: border-box;
}

.nav-toggle-btn:hover {
  border-color: var(--border-focus);
}

.nav-toggle-btn svg {
  transition: transform 0.25s ease;
}

.nav-toggle-btn.open svg {
  transform: rotate(180deg);
}

/* Dropdown Menu when toggled */
.top-navbar .nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  right: 140px;
  left: auto;
  min-width: 240px;
  max-width: 320px;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
  padding: 10px 12px;
  max-height: calc(85vh - 60px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  flex-direction: column;
  gap: 4px;
  z-index: 1050;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.top-navbar .nav-dropdown-menu.open {
  display: flex !important;
}

.top-navbar .nav-dropdown-menu .nav-link {
  width: 100%;
  padding: 12px 16px;
  font-size: 0.925rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-sizing: border-box;
  white-space: normal;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.top-navbar .nav-dropdown-menu .nav-link:last-child {
  border-bottom: none;
}

@media (max-width: 768px) {
  .top-navbar {
    padding: 8px 10px;
    margin-bottom: 12px;
  }

  .nav-content {
    width: 100%;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-right: 84px;
    gap: 4px;
    box-sizing: border-box;
  }

  .nav-links {
    display: flex;
    flex-wrap: nowrap !important;
    white-space: nowrap;
    overflow-x: auto !important;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    flex: 1 1 auto;
    min-width: 0;
    padding: 2px 6px 2px 2px;
    scroll-behavior: smooth;
  }

  .nav-links::-webkit-scrollbar {
    display: none;
  }

  .nav-toggle-btn {
    display: inline-flex !important;
    width: 34px;
    min-width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
    margin-left: 4px;
    flex-shrink: 0;
  }

  #user-btn-label {
    display: none !important;
  }

  .top-navbar .nav-dropdown-menu {
    position: fixed;
    top: 52px;
    left: 8px;
    right: 8px;
    min-width: auto;
    max-width: none;
    max-height: calc(100vh - 70px);
    padding: 12px 14px;
    padding-bottom: max(60px, env(safe-area-inset-bottom, 24px) + 24px);
    border-radius: var(--radius-lg);
    z-index: 1060;
  }

  .user-nav-bar {
    top: 8px;
    right: 8px;
    gap: 5px;
  }

  .user-icon-btn {
    padding: 0;
    width: 34px;
    min-width: 34px;
    height: 34px;
    min-height: 34px;
    justify-content: center;
    font-size: 0.775rem;
  }
}

/* Auth Modal Overlay */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-overlay.open {
  display: flex;
}

.modal-box {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-md);
  color: var(--text-primary);
}

/* Header */
.app-header {
  margin-bottom: 32px;
}

.app-title {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.app-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  font-weight: 400;
}

/* Badges & Pills */
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  background-color: var(--bg-card);
  color: var(--text-primary);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 12px;
  border: 1px solid var(--border-color);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.775rem;
  font-weight: 600;
  background-color: var(--badge-bg);
  color: var(--badge-text);
  border: 1px solid var(--badge-border);
}

.status-pill.success {
  background-color: var(--accent-primary);
  color: var(--accent-primary-text);
  border-color: var(--accent-primary);
}

.status-pill.danger {
  background-color: var(--bg-elevated);
  color: var(--text-muted);
  border-color: var(--border-color);
}

.status-pill.warning {
  background-color: var(--badge-bg);
  color: var(--text-secondary);
  border-color: var(--border-focus);
}

/* Grid & Cards */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

/* Admin Dashboard Multi-Column Grid Layout */
.admin-grid-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

.admin-grid-2col .panel {
  margin-bottom: 0;
}

.card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.2s ease;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-sm);
}

.card:hover {
  background-color: var(--bg-card-hover);
  border-color: var(--border-focus);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.card-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.card-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 20px;
}

.btn-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* Admin Grid */
.admin-grid-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}

/* Panels */
.panel {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
  margin-bottom: 24px;
}

/* Stepper Bar */
.stepper {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 6px;
  margin-bottom: 24px;
}

.step-item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: all 0.2s ease;
}

.step-item .num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg-elevated);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}

.step-item.active {
  background-color: var(--bg-elevated);
  color: var(--text-primary);
}

.step-item.active .num {
  background-color: var(--accent-primary);
  color: var(--accent-primary-text);
}

.step-item.completed {
  color: var(--text-primary);
}

.step-item.completed .num {
  background-color: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border-focus);
}

/* Form Controls */
.form-group {
  margin-bottom: 18px;
  text-align: left;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.form-control, input[type="text"], input[type="email"], input[type="password"], input[type="number"], input[type="date"], input[type="time"], textarea {
  width: 100%;
  background-color: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  color: var(--text-primary);
  font-family: var(--font-family, inherit);
  font-size: 0.95rem;
  min-height: 44px;
  outline: none;
  transition: all 0.2s ease;
}

.form-control:focus, input:focus, textarea:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.15);
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

select, select.form-control, .custom-select {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  background-color: var(--bg-input) !important;
  color: var(--text-primary) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius-md) !important;
  padding: 10px 38px 10px 14px !important;
  font-family: var(--font-family, inherit) !important;
  font-size: 0.95rem !important;
  font-weight: 500 !important;
  min-height: 44px !important;
  outline: none !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'></polyline></svg>") !important;
  background-repeat: no-repeat !important;
  background-position: right 14px center !important;
  background-size: 16px 16px !important;
  box-shadow: var(--shadow-sm, 0 1px 3px rgba(0,0,0,0.2));
}

select:hover, select.form-control:hover, .custom-select:hover {
  border-color: var(--border-focus) !important;
  background-color: var(--bg-card-hover) !important;
}

select:focus, select.form-control:focus, .custom-select:focus {
  border-color: var(--border-focus) !important;
  box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.2) !important;
}

select option, select.form-control option {
  background-color: var(--bg-card, #12151e) !important;
  color: var(--text-primary, #f8fafc) !important;
  padding: 10px 14px !important;
  font-size: 0.95rem !important;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s ease;
  text-decoration: none;
  min-height: 44px;
}

.btn-primary {
  background-color: var(--accent-primary);
  color: var(--accent-primary-text);
}

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

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-outline {
  background-color: transparent;
  border-color: var(--border-color);
  color: var(--text-primary);
}

.btn-outline:hover {
  background-color: var(--bg-card-hover);
}

.btn-success {
  background-color: var(--action-positive-bg);
  color: var(--action-positive-text);
}

.btn-danger {
  background-color: var(--action-negative-bg);
  color: var(--action-negative-text);
  border: 1px solid var(--action-negative-border);
}

.btn-sm {
  padding: 8px 14px;
  font-size: 0.825rem;
  border-radius: var(--radius-sm);
  min-height: 38px;
}

.btn-block {
  width: 100%;
}

.admin-btn-group {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 8px !important;
  flex-wrap: nowrap !important;
}

.admin-btn-group .btn {
  white-space: nowrap !important;
  min-height: 34px !important;
}

/* Voting Stack & Results */
.voting-card, .result-card, .winner-box, .date-card {
  background-color: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-top: 16px;
}

.date-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
}

.date-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-secondary);
  background: var(--bg-elevated);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  width: fit-content;
}

.winner-box {
  border-color: var(--border-focus);
}

.winner-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.voting-text {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.6;
  margin-bottom: 24px;
  word-break: break-word;
}

.vote-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.btn-vote-up {
  background-color: var(--action-positive-bg);
  color: var(--action-positive-text);
  border: 1px solid var(--border-color);
  padding: 14px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  transition: all 0.15s ease;
}

.btn-vote-up:hover {
  background-color: var(--accent-hover);
}

.btn-vote-down {
  background-color: var(--action-negative-bg);
  color: var(--action-negative-text);
  border: 1px solid var(--action-negative-border);
  padding: 14px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  transition: all 0.15s ease;
}

.btn-vote-down:hover {
  background-color: var(--bg-card-hover);
}

.progress-track {
  height: 8px;
  background-color: var(--bg-elevated);
  border-radius: 999px;
  overflow: hidden;
  display: flex;
  margin-top: 8px;
}

.progress-up {
  background-color: var(--text-primary);
  height: 100%;
  transition: width 0.4s ease;
}

.progress-down {
  background-color: var(--text-muted);
  height: 100%;
  transition: width 0.4s ease;
}

/* Collapsible Drawer */
.drawer-toggle {
  width: 100%;
  background-color: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  min-height: 46px;
}

.drawer-content {
  display: none;
  padding-top: 16px;
}

.drawer-content.open {
  display: block;
}

/* Expandable Proposal Details */
details.proposal-details {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  margin-bottom: 8px;
  transition: border-color 0.2s ease;
}

details.proposal-details[open] {
  border-color: var(--border-focus);
}

details.proposal-details summary {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
}

details.proposal-details summary::-webkit-details-marker {
  display: none;
}

details.proposal-details summary::after {
  content: " Ausklappen ▼";
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-left: 8px;
}

details.proposal-details[open] summary::after {
  content: " Einklappen ▲";
  color: var(--accent-primary);
}

.proposal-expanded-content {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed var(--border-color);
  color: var(--text-secondary);
  font-size: 0.875rem;
  line-height: 1.5;
}

/* Data Table & Responsive Wrapper */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 8px;
  font-size: 0.85rem;
  min-width: 500px;
}

.data-table th, .data-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.data-table th {
  color: var(--text-muted);
  font-weight: 600;
  background-color: var(--bg-input);
}

/* Toasts */
.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 340px;
}

.toast {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  box-shadow: var(--shadow-md);
}

.toast-success {
  border-left: 4px solid var(--text-primary);
}

.toast-danger {
  border-left: 4px solid var(--text-muted);
}

.sec-footer {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border-color);
}

/* Responsive Mobile Adjustments (< 840px / < 640px / < 480px) */
.grid-form-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Floating Admin Notification Button & Counter */
.admin-float-notif-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  background-color: var(--bg-card);
  border: 1px solid var(--border-focus);
  color: var(--text-primary);
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  transition: all 0.25s ease;
}

.admin-float-notif-btn:hover {
  transform: scale(1.08);
  border-color: var(--accent-primary);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5);
}

.notif-count-pill {
  position: absolute;
  top: -4px;
  right: -4px;
  background-color: #ef4444;
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 800;
  min-width: 22px;
  height: 22px;
  padding: 0 5px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--bg-card);
  animation: pulse-badge 2s infinite;
}

@keyframes pulse-badge {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

@media (max-width: 840px) {
  .admin-grid-2col {
    grid-template-columns: 1fr;
    gap: 16px;

/* Spinner Animation */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.top-navbar .nav-dropdown-menu .nav-link.active {
  background-color: var(--accent-subtle);
  color: var(--accent-primary);
  border-left: 3px solid var(--accent-primary);
  font-weight: 700;
}
