/* =========================================================
   SIDEBAR
   ========================================================= */
.sidebar {
  background: #0f172a;
  color: #e5e7eb;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 20px 15px;
  width: 230px;
}

.sidebar .logo {
  align-items: center;
  display: flex;
  font-size: 20px;
  font-weight: bold;
  gap: 8px;
  margin-bottom: 10px;
}

.sidebar .logo i {
  color: #38bdf8;
}

.nav-section-title {
  color: #9ca3af;
  font-size: 12px;
  margin: 10px 0 5px;
  text-transform: uppercase;
}

.sidebar-nav a {
  align-items: center;
  border-radius: 6px;
  color: #e5e7eb;
  display: flex;
  font-size: 14px;
  gap: 10px;
  margin-bottom: 3px;
  padding: 8px 10px;
  text-decoration: none;
  transition: background 0.15s ease, transform 0.1s ease;
}

.sidebar-nav a:hover {
  background: #1f2937;
  transform: translateX(2px);
}

.sidebar-nav a.active {
  background: #2563eb;
  color: #f9fafb;
}

/* =========================================================
   TOP NAVIGATION
   ========================================================= */
.topnav {
  align-items: center;
  background: var(--nav-bg);
  color: var(--nav-text);
  display: flex;
  gap: 20px;
  padding: 12px 24px;
}

.title {
  align-items: center;
  display: flex;
  font-size: 20px;
  font-weight: bold;
  gap: 8px;
}

.topnav-right {
  align-items: center;
  display: flex;
  gap: 25px;
  margin-left: auto;
}

.right {
  align-items: center;
  display: flex;
  gap: 18px;
}

.right a {
  align-items: center;
  color: var(--nav-text);
  display: flex;
  font-size: 14px;
  font-weight: bold;
  gap: 6px;
  text-decoration: none;
}

.right a:hover {
  text-decoration: underline;
}

/* =========================================================
   THEME TOGGLE
   ========================================================= */
.toggle-wrapper {
  align-items: center;
  cursor: pointer;
  display: flex;
  font-size: 13px;
  gap: 6px;
  user-select: none;
}

.toggle-switch {
  background: #6b7280;
  border-radius: 10px;
  height: 20px;
  position: relative;
  transition: background 0.15s;
  width: 40px;
}

.toggle-thumb {
  background: #f9fafb;
  border-radius: 50%;
  height: 18px;
  left: 1px;
  position: absolute;
  top: 1px;
  transition: transform 0.15s;
  width: 18px;
}

[data-theme="dark"] .toggle-switch {
  background: #2563eb;
}

[data-theme="dark"] .toggle-thumb {
  transform: translateX(20px);
}

.sidebar-footer {
  margin-top: auto;
  /* pushes footer to the bottom */
  padding-top: 20px;
  font-size: 12px;
  color: #9ca3af;
  text-align: center;
  opacity: 0.8;
}