/* CSS Variables for Theme Colors */
:root {
  /* Light theme colors */
  --bg-color: #ffffff;
  --text-color: #333333;
  --text-secondary: #666666;
  --border-color: #cccccc;
  --card-bg: #ffffff;
  --header-bg: #e8e8e8;
  --link-color: #0076df;
  --link-hover: #00369f;
  --nav-link-color: #333333;
  --shadow-color: rgba(0, 0, 0, 0.1);
  --code-bg: #fafafa;
  --header-height: 72px;
}

[data-theme="dark"] {
  /* Dark theme colors */
  --bg-color: #1a1a1a;
  --text-color: #e0e0e0;
  --text-secondary: #b0b0b0;
  --border-color: #404040;
  --card-bg: #2a2a2a;
  --header-bg: #4a3728;
  --link-color: #4da6ff;
  --link-hover: #80bfff;
  --nav-link-color: #e0e0e0;
  --shadow-color: rgba(0, 0, 0, 0.3);
  --code-bg: #2d2d2d;
  --header-height: 72px;
}

/* Theme Styles */
body {
  background-color: var(--bg-color);
  color: var(--text-color);
  transition: background-color 0.3s ease, color 0.3s ease;
  margin: 0;
  padding: 0;
}

/* Header and Navigation */
.site-header {
  background-color: var(--header-bg);
  transition: background-color 0.3s ease;
  width: 100%;
  padding: 0;
  margin: 0;
  overflow-x: hidden;
  overflow-y: visible;
}

@media only screen and (max-width: 768px) {
  .site-header {
    overflow: visible;
  }
}

.nav-underline {
  color: var(--nav-link-color) !important;
  transition: color 0.3s ease;
}

.nav-underline:hover {
  color: var(--link-hover) !important;
}

/* Links */
a {
  color: var(--link-color);
  transition: color 0.3s ease;
}

a:hover {
  color: var(--link-hover);
}

/* Text colors */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-color);
}

p {
  color: var(--text-color);
}

/* Code blocks */
pre, code {
  background-color: var(--code-bg) !important;
  color: var(--text-color) !important;
  border: 1px solid var(--border-color);
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Theme toggle colors for dark mode */
[data-theme="dark"] .theme-toggle {
  color: var(--text-color);
}

/* Dark mode specific adjustments */
[data-theme="dark"] {
  /* Adjust form inputs */
  input, textarea, select {
    background-color: var(--card-bg);
    color: var(--text-color);
    border-color: var(--border-color);
  }
  
  /* Adjust tables */
  table, th, td {
    border-color: var(--border-color);
  }
  
  th {
    background-color: var(--card-bg);
  }
  
  /* Adjust blockquotes */
  blockquote {
    border-left-color: var(--border-color);
    color: var(--text-secondary);
  }
  
  /* Adjust horizontal rules */
  hr {
    border-color: var(--border-color);
  }
}

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

