/* --- Theme Toggle --- */
.theme-toggle {
  display: none;
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  /* Higher z-index */
  background: var(--bg-card);
  border: 1px solid var(--primary-blue);
  color: var(--text-main);
  padding: 0 20px;
  /* Use height for vertical padding */
  height: 44px;
  border-radius: 22px;
  /* Pills shape */
  cursor: pointer;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.theme-toggle:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.theme-toggle .icon-sun {
  display: flex;
  /* Default in dark mode is Sun icon (action) */
}

.theme-toggle .icon-moon {
  display: none;
}

.light-theme .theme-toggle .icon-sun {
  display: none;
}

.light-theme .theme-toggle .icon-moon {
  display: flex;
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media screen and (max-width: 768px) {
  .theme-toggle {
    top: 10px;
    right: 10px;
    padding: 8px 12px;
  }
}