/* Theme Toggle Styles - Add this to all your existing CSS files */

/* Light mode (default) - your existing colors */
:root {
  --neutral: #faeee7;
  --base-100: #33272a;
  --neutral-focus: #fffffe;
  --neutral-highlight: #d1d1e9;
  --primary: #6246ea;
  --secondary: #594a4e;
  --accent: #33272a;
  --spanhover: #c3f0ca;
  --card-bg-light: #ffffff;
  --card-bg-dark: #333333;
  --card-headline-light: #333333;
  --card-headline-dark: #ffffff;
}

/* Dark mode colors */
[data-theme="dark"] {
  --neutral: #1a1a1a;
  --base-100: #e8e8e8;
  --neutral-focus: #2d2d2d;
  --neutral-highlight: #4a4a6b;
  --primary: #8b7cf6;
  --secondary: #f7f0f3;
  --accent: #e8e8e8;
  --spanhover: #4ade80;
  --card-bg-light: #2d2d2d;
  --card-bg-dark: #1a1a1a;
  --card-headline-light: #e8e8e8;
  --card-headline-dark: #1a1a1a;
}

/* Theme toggle button styles */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: 2px solid var(--primary);
  border-radius: 50%;
  width: 42px;
  height: 42px;
  cursor: pointer;
  transition: all 0.3s ease;
  color: var(--primary);
  font-size: 18px;
  font-family: inherit;
  flex-shrink: 0; /* Prevent button from shrinking */
}

/* When inside nav-links, style as nav item */
.nav-links .theme-toggle {
  margin: 0;
  padding: 0;
}

/* When inside nav-links li, remove default list styling */
.nav-links li:has(.theme-toggle) {
  list-style: none;
  margin: 0;
  padding: 0;
}

/* Alternative selector for better compatibility */
.nav-links li .theme-toggle {
  width: 38px;
  height: 38px;
  font-size: 16px;
}

.theme-toggle:hover {
  background-color: var(--primary);
  color: var(--neutral);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(98, 70, 234, 0.3);
}

.theme-toggle:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(98, 70, 234, 0.3);
}

.theme-toggle-icon {
  transition: transform 0.3s ease;
  font-size: 18px;
}

.theme-toggle:hover .theme-toggle-icon {
  transform: rotate(180deg);
}

/* Smooth transitions for theme changes */
* {
  transition: background-color 0.3s ease, color 0.3s ease,
    border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Additional dark mode adjustments */
[data-theme="dark"] body {
  background-color: var(--neutral);
  color: var(--base-100);
}

[data-theme="dark"] .coming-soon-container {
  background: rgba(45, 45, 45, 0.9);
  border: 1px solid rgba(139, 124, 246, 0.2);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .progress-bar {
  background: rgba(45, 45, 45, 0.3);
}

[data-theme="dark"] .home-button {
  background: rgba(45, 45, 45, 0.3);
  border: 2px solid rgba(139, 124, 246, 0.3);
}

[data-theme="dark"] .project-card,
[data-theme="dark"] .project-tile,
[data-theme="dark"] .service-highlight,
[data-theme="dark"] .form-container,
[data-theme="dark"] .section {
  background-color: var(--card-bg-light);
  color: var(--card-headline-light);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] input,
[data-theme="dark"] textarea,
[data-theme="dark"] select {
  background-color: var(--neutral-focus);
  color: var(--base-100);
  border-color: #555;
}

[data-theme="dark"] input:focus,
[data-theme="dark"] textarea:focus,
[data-theme="dark"] select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(139, 124, 246, 0.1);
}

/* Mobile responsive adjustments for theme toggle */
@media (max-width: 768px) {
  .theme-toggle {
    width: 38px;
    height: 38px;
    font-size: 16px;
  }

  .theme-toggle-icon {
    font-size: 16px;
  }
}
