/* =========================
   VARIABLES + BASE
   ========================= */
:root {
  --orange: #ff7e00;
  --nav-height: 7vh;
  --top-navbar-height: 60px;
  --sidebar-width: 8rem;

  --sidebar-main-bg-color: #212529;
  --sidebar-secondary-bg-color: #2e3134;
  --sidebar-tertiary-bg-color: #222528;
}

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
}

/* Layout wrappers */
.wrapper {
  display: flex;
  min-height: 100vh;
}

#body-wrapper {
  min-height: 100vh;
  padding-bottom: var(--nav-height);
}

#content-wrapper {
  flex: 1;
  margin-left: 0;
  margin-top: var(--top-navbar-height);
  padding: 1.5rem;
  min-height: calc(100vh - var(--top-navbar-height));
  transition: margin-left 0.3s;
}

#content {
  position: relative;
}

.page {
  height: 100%;
}

/* Overlay (shared) */
.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
  cursor: pointer;
}

.overlay.active {
  display: block;
  opacity: 1;
}

/* =========================
   SIDEBAR (Modern + Responsive)
   ========================= */

/* Tuning knobs */
:root {
  --sb-width: 14rem; /* desktop sidebar width */
  --sb-width-collapsed: 5.25rem; /* optional if you ever add collapsed mode */
  --sb-radius: 16px;
  --sb-item-radius: 12px;

  --sb-bg: #171a1d;
  --sb-surface: #1e2327;
  --sb-surface-2: #242a2f;
  --sb-border: rgba(255, 255, 255, 0.08);

  --sb-text: rgba(255, 255, 255, 0.92);
  --sb-muted: rgba(255, 255, 255, 0.6);
  --sb-hover: rgba(255, 255, 255, 0.08);

  --sb-accent: var(--orange); /* your orange */
  --sb-accent-soft: rgba(255, 126, 0, 0.18);
  --sb-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
}

/* Base container */
#sidebar {
  width: var(--sb-width);
  max-width: var(--sb-width);
  min-width: var(--sb-width);

  background: linear-gradient(180deg, var(--sb-bg) 0%, #14171a 100%);
  color: var(--sb-text);

  position: fixed;
  top: 0;
  left: calc(-1 * var(--sb-width));
  height: 100vh;
  z-index: 1001;

  display: flex;
  flex-direction: column;

  border-right: 1px solid var(--sb-border);
  box-shadow: var(--sb-shadow);
  transition: left 0.28s cubic-bezier(0.4, 0, 0.2, 1);

  overflow: hidden; /* header + scroll area get rounded cleanly */
}

/* Open state */
#sidebar.active {
  left: 0;
}

/* Header */
#sidebar .sidebar-header {
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.03);
  border-bottom: 1px solid var(--sb-border);
  position: relative;

  display: flex;
  align-items: center;
  justify-content: center;

  /* subtle “glass” */
  backdrop-filter: blur(10px);
}

/* Logo */
#sidebar .sidebar-header img {
  max-width: 48%;
  height: auto;
  display: block;
  filter: saturate(1.05);
  user-select: none;
}

/* Logo link wrapper */
#sidebar .sidebar-header a {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  line-height: 0;
}

/* Close button (more modern) */
.sidebar-close-btn {
  position: absolute;
  top: 10px;
  left: 10px;

  width: 38px;
  height: 38px;
  border-radius: 12px;

  border: 1px solid var(--sb-border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--sb-text);

  display: flex;
  align-items: center;
  justify-content: center;

  cursor: pointer;
  transition:
    transform 0.15s ease,
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.sidebar-close-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  transform: translateY(-1px);
}

.sidebar-close-btn:active {
  transform: translateY(0) scale(0.98);
}

/* Scrollable area */
#sidebarContent {
  padding: 10px 10px 14px;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1;

  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.25) transparent;
}

#sidebarContent::-webkit-scrollbar {
  width: 6px;
}
#sidebarContent::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 10px;
}

/* Remove old component border if present */
#sidebar ul.components {
  border-bottom: none;
  padding: 0;
  margin: 0;
}

/* List spacing */
#sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* Main items */
#sidebar ul li {
  margin: 6px 0;
}

/* Anchor: modern row layout */
#sidebar ul li a {
  display: flex;
  align-items: center;
  gap: 12px;

  padding: 11px 12px;
  border-radius: var(--sb-item-radius);

  color: var(--sb-text);
  text-decoration: none;

  background: transparent;
  border: 1px solid transparent;

  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    transform 0.15s ease;
  font-size: 0.95rem;
  letter-spacing: 0.2px;
}

/* Icon: align left, consistent size */
#sidebar ul li a i {
  font-size: 1.25rem;
  width: 26px;
  text-align: center;
  margin: 0; /* override older styles */
  opacity: 0.95;
}

/* Hover */
#sidebar ul li a:hover {
  background: var(--sb-hover);
  border-color: rgba(255, 255, 255, 0.06);
  transform: translateY(-1px);
}

/* Active state: modern “accent rail” */
#sidebar ul li a.active,
#sidebar ul li.active > a {
  background: var(--sb-accent-soft);
  border-color: rgba(255, 126, 0, 0.22);
  color: #fff;
  position: relative;
}

#sidebar ul li a.active::before,
#sidebar ul li.active > a::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 3px;
  background: var(--sb-accent);
}

/* Dropdown toggle indicator (chevron) */
#sidebar .dropdown-toggle {
  position: relative;
  padding-right: 38px; /* space for chevron */
}

#sidebar .dropdown-toggle::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid rgba(255, 255, 255, 0.55);
  border-bottom: 2px solid rgba(255, 255, 255, 0.55);
  transform: translateY(-50%) rotate(45deg);
  transition:
    transform 0.2s ease,
    border-color 0.2s ease;
  display: block; /* override your earlier 'display:none' */
}

#sidebar .dropdown-toggle[aria-expanded="true"]::after {
  transform: translateY(-50%) rotate(-135deg);
  border-color: rgba(255, 255, 255, 0.8);
}

/* Submenu container */
#sidebar ul ul {
  margin: 6px 0 0 0;
  padding: 8px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

/* Submenu items */
#sidebar ul ul a {
  padding: 10px 10px;
  font-size: 0.92rem !important;
  border-radius: 10px;
  background: transparent;
  border: 1px solid transparent;
  color: rgba(255, 255, 255, 0.88);
}

#sidebar ul ul a:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.06);
  color: #fff;
}

/* Better focus for keyboard users */
#sidebar a:focus-visible,
.sidebar-close-btn:focus-visible {
  outline: 2px solid rgba(255, 126, 0, 0.7);
  outline-offset: 2px;
}

/* Responsive behavior:
   - On small screens: wider, easier to tap
   - On desktop: fixed width
*/
@media (max-width: 992px) {
  :root {
    --sb-width: 18.5rem;
  }
}

@media (max-width: 576px) {
  :root {
    --sb-width: min(92vw, 20rem);
  }

  #sidebar .sidebar-header img {
    max-width: 58%;
  }

  #sidebar ul li a {
    padding: 13px 12px;
    font-size: 1rem;
  }

  #sidebar ul li a i {
    font-size: 1.35rem;
    width: 28px;
  }
}

/* Optional: reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  #sidebar,
  #sidebar ul li a,
  .sidebar-close-btn,
  #sidebar .dropdown-toggle::after {
    transition: none !important;
  }
}

/* =========================
   TOP NAVBAR
   ========================= */
#top-navbar {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--top-navbar-height);
  background-color: var(--sidebar-secondary-bg-color) !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  z-index: 998;
  padding: 0 1.5rem;
}

#top-navbar .container-fluid {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0;
}

#top-navbar .btn-dark {
  background-color: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  padding: 0.5rem 0.75rem;
  transition: all 0.2s;
}

#top-navbar .btn-dark:hover {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
}

#top-navbar .btn-dark:active {
  background-color: rgba(255, 255, 255, 0.2);
  transform: scale(0.95);
}

/* Welcome */
.navbar-bienvenido {
  flex-grow: 1;
  display: flex;
  justify-content: center;
  margin: 0 1rem;
}

.bienvenido-navbar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  color: #fff;
  font-size: 0.9rem;
}

.bienvenido-user {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.bienvenido-greeting {
  font-weight: 400;
  opacity: 0.9;
}

.bienvenido-name {
  font-weight: 600;
  font-size: 1rem;
}

/* Theme switcher */
.theme-switcher {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.theme-icon {
  color: #fff;
  font-size: 1.2rem;
  opacity: 0.5;
  transition: opacity 0.3s;
  cursor: pointer;
}
.theme-icon.active {
  opacity: 1;
  color: var(--orange);
}

.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #ccc;
  transition: 0.4s;
}
.slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: #fff;
  transition: 0.4s;
}
input:checked + .slider {
  background-color: var(--orange);
}
input:checked + .slider:before {
  transform: translateX(26px);
}
.slider.round {
  border-radius: 24px;
}
.slider.round:before {
  border-radius: 50%;
}

/* Navbar actions */
.navbar-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.navbar-notifications,
.navbar-account {
  position: relative;
}

.navbar-icon-btn {
  position: relative;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}
.navbar-icon-btn:hover {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
}
.navbar-icon-btn i {
  font-size: 1.2rem;
}

.navbar-badge,
.notification-toggle .badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: #dc3545;
  color: #fff;
  border-radius: 50%;
  padding: 0.125rem 0.375rem;
  font-size: 0.7rem;
  font-weight: 600;
  min-width: 1.2rem;
  height: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pulse 2s infinite;
}

/* Dropdowns (topbar) */
.navbar-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background: #fff;
  border-radius: 0.5rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  border: 1px solid #e0e0e0;
  display: none;
  flex-direction: column;
  z-index: 1060;
  min-width: 200px;
}
.navbar-dropdown.active {
  display: flex;
}
.navbar-notifications .navbar-dropdown {
  width: 350px;
  max-height: 500px;
}

/* Account dropdown */
.account-dropdown .dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  color: #495057;
  text-decoration: none;
  transition: background-color 0.2s;
  border-bottom: 1px solid #f0f0f0;
}
.account-dropdown .dropdown-item:last-child {
  border-bottom: none;
}
.account-dropdown .dropdown-item:hover {
  background-color: #f8f9fa;
  color: var(--orange);
}
.account-dropdown .dropdown-item i {
  font-size: 1.1rem;
  width: 20px;
  text-align: center;
}
.account-dropdown .dropdown-divider {
  height: 1px;
  background-color: #e0e0e0;
  margin: 0;
}

/* =========================
   BOTTOM NAV (Modern)
   ========================= */

:root {
  --bn-h: 64px; /* bottom nav height */
  --bn-pad-y: 10px;
  --bn-pad-x: 10px;
  --bn-radius: 18px;

  --bn-bg: rgba(0, 0, 0, 0.86);
  --bn-border: rgba(255, 255, 255, 0.1);

  --bn-item-radius: 14px;
  --bn-item-hover: rgba(255, 255, 255, 0.08);
  --bn-item-active: rgba(255, 126, 0, 0.18);
}

/* make room for navbar + safe area */
#body-wrapper {
  min-height: 100vh;
  padding-bottom: calc(var(--bn-h) + env(safe-area-inset-bottom, 0px));
}

#bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;

  height: calc(var(--bn-h) + env(safe-area-inset-bottom, 0px));
  padding: var(--bn-pad-y) var(--bn-pad-x)
    calc(var(--bn-pad-y) + env(safe-area-inset-bottom, 0px));

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;

  background: var(--bn-bg);
  border-top: 1px solid var(--bn-border);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 1050;
}

#bottom-nav a,
#bottom-nav .notification-toggle {
  flex: 1 1 0;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  gap: 4px;
  height: calc(var(--bn-h) - 2 * var(--bn-pad-y));

  border-radius: var(--bn-item-radius);
  text-decoration: none;
  user-select: none;

  color: rgba(255, 255, 255, 0.92);
  font-size: 0.72rem;
  letter-spacing: 0.2px;

  transition:
    background-color 0.18s ease,
    transform 0.12s ease,
    color 0.18s ease;
}

#bottom-nav a:hover,
#bottom-nav .notification-toggle:hover {
  background: var(--bn-item-hover);
}

#bottom-nav a:active,
#bottom-nav .notification-toggle:active {
  transform: scale(0.98);
}

#bottom-nav a.active {
  background: var(--bn-item-active);
  color: #fff;
}

#bottom-nav i {
  font-size: 1.35rem;
  line-height: 1;
}

/* wrappers */
.submenu-wrapper {
  position: relative;
  flex: 1 1 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* =========================================
   Bottom submenus (Inventario/Cuenta/Admin)
   ========================================= */
.submenu {
  position: absolute;
  bottom: calc(var(--bn-h) + 10px);
  left: 50%;
  transform: translateX(-50%);

  display: none;
  flex-direction: column;

  min-width: 180px;
  max-width: min(92vw, 360px);

  background: rgba(15, 15, 15, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);

  overflow: hidden;
  z-index: 1060;
}

.submenu a {
  display: flex;
  align-items: center;
  gap: 10px;

  padding: 10px 12px;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.92);
  text-decoration: none;

  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.submenu a:last-child {
  border-bottom: none;
}

.submenu a:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.submenu a i {
  font-size: 1.05rem;
  width: 22px;
  text-align: center;
}

/* =========================================
   Bottom Notifications (fix positioning + UI)
   ========================================= */

/* your toggle */
.notification-wrapper {
  position: relative;
}

/* keep your markup (#notification-toggle is a div) */
#notification-toggle.notification-toggle {
  position: relative;
}

/* badge on bell */
#notification-badge.badge {
  position: absolute;
  top: 6px;
  right: 14px;

  background-color: #dc3545;
  color: #fff;
  border-radius: 999px;
  padding: 2px 7px;

  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
  min-width: 18px;
  text-align: center;
}

/* IMPORTANT:
   notification dropdown is also ".submenu", so we override its geometry
   and only control visibility via ".active" (not inline display) */
#notification-dropdown.notifications-dropdown {
  left: auto;
  transform: none;
  right: 0;

  width: min(92vw, 360px);
  max-height: min(62vh, 420px);
}

/* show via class (your JS toggles .active) */
#notification-dropdown.notifications-dropdown.active {
  display: flex;
}

/* header/footer match topbar visuals */
#notification-dropdown .notification-header {
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

#notification-dropdown .notification-title {
  color: rgba(255, 255, 255, 0.92);
  font-weight: 700;
  font-size: 0.88rem;
}

#notification-dropdown .mark-all-read-btn {
  color: rgba(255, 255, 255, 0.92);
}

#notification-dropdown .notifications-list {
  overflow-y: auto;
}

#notification-dropdown .notification-item {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

#notification-dropdown .notification-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

#notification-dropdown .notification-message {
  color: rgba(255, 255, 255, 0.92);
}

#notification-dropdown .notification-time {
  color: rgba(255, 255, 255, 0.6);
}

#notification-dropdown .notification-close {
  color: rgba(255, 255, 255, 0.7);
}

#notification-dropdown .notification-close:hover {
  background-color: rgba(220, 53, 69, 0.16);
  color: #ff5b6a;
}

#notification-dropdown .notification-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 10px;
}

#notification-dropdown .view-all-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

#notification-dropdown .view-all-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-1px);
}

/* small screens tuning */
@media (max-width: 420px) {
  :root {
    --bn-h: 60px;
  }
  #bottom-nav i {
    font-size: 1.25rem;
  }
  #bottom-nav a,
  #bottom-nav .notification-toggle {
    font-size: 0.68rem;
  }
}

/* Notifications list UI */
.notification-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  border-bottom: 1px solid #e0e0e0;
  background: #f8f9fa;
}

.notification-title {
  font-weight: 600;
  font-size: 0.9rem;
  color: #495057;
}

.mark-all-read-btn {
  background: none;
  border: none;
  color: #007bff;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 3px;
  transition: background-color 0.2s;
}
.mark-all-read-btn:hover {
  background-color: rgba(0, 123, 255, 0.1);
}

.notifications-list {
  flex: 1;
  overflow-y: auto;
  max-height: 300px;
}

.notification-item {
  display: flex;
  align-items: flex-start;
  padding: 0.75rem;
  border-bottom: 1px solid #f0f0f0;
  transition: background-color 0.2s;
}
.notification-item:hover {
  background-color: #f8f9fa;
}
.notification-content {
  flex: 1;
  cursor: pointer;
}
.notification-message {
  font-size: 0.85rem;
  line-height: 1.3;
  margin-bottom: 0.25rem;
  color: #495057;
}
.notification-time {
  font-size: 0.75rem;
  color: #6c757d;
}

.notification-close {
  background: none;
  border: none;
  color: #6c757d;
  cursor: pointer;
  padding: 0.25rem;
  margin-left: 0.5rem;
  border-radius: 3px;
  opacity: 0;
  transition: all 0.2s;
}
.notification-item:hover .notification-close {
  opacity: 1;
}
.notification-close:hover {
  background-color: rgba(220, 53, 69, 0.1);
  color: #dc3545;
}

.no-notifications {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  color: #6c757d;
  text-align: center;
}
.no-notifications i {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  opacity: 0.5;
}

.notification-footer {
  border-top: 1px solid #e0e0e0;
  padding: 0.5rem;
}

.view-all-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem;
  color: #fff;
  background-color: #333;
  text-decoration: none;
  border-radius: 0.375rem;
  transition: all 0.2s;
  font-size: 0.85rem;
  font-weight: 500;
}
.view-all-btn:hover {
  background-color: #444;
  text-decoration: none;
  color: #fff;
  transform: translateY(-1px);
}

/* =========================
   FLASH MESSAGES (moved from inline)
   ========================= */
.flash-messages-container {
  position: fixed;
  top: 70px;
  right: 20px;
  z-index: 1050;
  max-width: 400px;
  width: 100%;
}

.flash-message {
  margin-bottom: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.flash-message.fade-out {
  animation: fadeOut 0.3s ease-out forwards;
}

@keyframes fadeOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

/* =========================
   DARK THEME SUPPORT
   ========================= */
[data-theme="dark"] .navbar-dropdown,
[data-theme="dark"] .notifications-dropdown {
  background: var(--sidebar-secondary-bg-color);
  border-color: #444;
}

[data-theme="dark"] .account-dropdown .dropdown-item {
  color: #e0e0e0;
  border-bottom-color: #444;
}
[data-theme="dark"] .account-dropdown .dropdown-item:hover {
  background-color: #3a3d41;
}
[data-theme="dark"] .account-dropdown .dropdown-divider {
  background-color: #444;
}

[data-theme="dark"] .notification-header {
  background: #3a3d41;
  border-bottom-color: #444;
}
[data-theme="dark"] .notification-title {
  color: #e0e0e0;
}
[data-theme="dark"] .notification-item {
  border-bottom-color: #444;
}
[data-theme="dark"] .notification-item:hover {
  background-color: #3a3d41;
}
[data-theme="dark"] .notification-message {
  color: #e0e0e0;
}
[data-theme="dark"] .notification-time {
  color: #adb5bd;
}
[data-theme="dark"] .notification-footer {
  border-top-color: #444;
}
[data-theme="dark"] .view-all-btn {
  background-color: #444;
}
[data-theme="dark"] .view-all-btn:hover {
  background-color: #555;
}

/* =========================
   RESPONSIVE
   ========================= */
@media (max-width: 768px) {
  .navbar-bienvenido {
    display: none;
  }
  .theme-switcher {
    margin-left: auto;
  }

  /* dropdown width tweaks */
  #notification-dropdown.notifications-dropdown {
    width: 320px;
    right: -50px;
  }

  .notification-item {
    padding: 0.5rem;
  }
  .notification-message {
    font-size: 0.8rem;
  }

  .flash-messages-container {
    top: 10px;
    right: 10px;
    left: 10px;
    max-width: none;
  }
}

@media (max-width: 480px) {
  .bienvenido-navbar {
    font-size: 0.8rem;
  }
  .bienvenido-name {
    font-size: 0.9rem;
  }
  #top-navbar {
    padding: 0 1rem;
  }

  #notification-dropdown.notifications-dropdown {
    width: 280px;
    right: -70px;
  }
}
