/* Add these CSS variables to your root element */
:root {
  /* Light mode colors (default) */
  --background-color: #ffffff;
  --text-color: #333333;
  --link-color: #0066cc;
  --border-color: #dddddd;
  --coming-soon-color: #666;
}

/* Dark mode colors */
@media (prefers-color-scheme: dark) {
  html:not(.light-mode) {
    --background-color: #1a1a1a;
    --text-color: #ffffff;
    --link-color: #66b3ff;
    --border-color: #404040;
    --coming-soon-color: #999;
  }
}

/* Manual theme overrides */
html.light-mode {
  --background-color: #ffffff;
  --text-color: #333333;
  --link-color: #0066cc;
  --border-color: #dddddd;
  --coming-soon-color: #666;
}

html.dark-mode {
  --background-color: #1a1a1a;
  --text-color: #ffffff;
  --link-color: #66b3ff;
  --border-color: #404040;
  --coming-soon-color: #999;
}

/* Add smooth transitions for theme changes */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 20px;
  display: flex;
  background-color: var(--background-color);
  color: var(--text-color);
  transition: background-color 0.3s ease, color 0.3s ease;
}

nav {
  width: 200px;
  padding-right: 20px;
  position: sticky;
  top: 20px;
  align-self: flex-start;
}

nav ul {
  list-style-type: none;
  padding: 0;
}

nav li {
  margin-bottom: 10px;
}

nav a {
  text-decoration: none;
  color: var(--text-color);
}

nav a:hover {
  text-decoration: underline;
}

nav h1 {
  margin: 0 0 20px 0;
  font-size: 1.8em;
  color: var(--text-color);
}

main {
  flex-grow: 1;
  max-width: 800px;
  line-height: 1.6;
}

main a {
  color: var(--link-color);
  text-decoration: none;
}

main a:hover {
  text-decoration: underline;
}

footer {
  margin-top: 40px;
  border-top: 1px solid var(--border-color);
  padding-top: 20px;
  font-size: 0.9em;
}

/* Blog specific styles */
.coming-soon {
  font-style: italic;
  color: var(--coming-soon-color);
}

.blog-list {
  padding-left: 20px;
}

/* Links specific styles */
.link-item {
  margin-bottom: 20px;
}

/* Image styles */
img {
  max-width: 100%;
  height: auto;
}

@media (min-width: 768px) {
  img {
    max-width: 600px;
  }
}

/* Theme switcher styles - updated */
.theme-switch {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 20px;
  margin: 0;
}

.theme-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 20px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 2px;
  bottom: 2px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #66b3ff;
}

input:checked + .slider:before {
  transform: translateX(20px);
}

.theme-switch-wrapper {
  display: flex;
  align-items: center;
  margin-top: 20px;
  justify-content: flex-start;
}

/* Remove the theme label styles */
.theme-switch-label {
  display: none;
}

/* Remove the old dark mode toggle button styles */
.dark-mode-toggle {
  display: none;
}

a {
  transition: color 0.3s ease;
}

.home-layout {
    display: flex;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    box-sizing: border-box;
}

.image-container {
    flex: 1;
    min-width: 300px;
}

.image-container img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.about-content {
    flex: 1;
    min-width: 300px;
}

@media (max-width: 768px) {
    .home-layout {
        flex-direction: column;
        padding: 1rem;
        gap: 1rem;
        width: 100%;
    }

    .image-container {
        min-width: auto;
        order: -1;
    }

    .about-content {
        min-width: auto;
    }

    main {
        padding: 0 15px;
        width: 100%;
        box-sizing: border-box;
        overflow-x: hidden;
    }

    .image-container img {
        width: 100%;
        max-width: 100%;
        height: auto;
    }

    ul {
        padding-left: 20px;
        box-sizing: border-box;
    }

    /* Hide brick breaker link and theme switch on mobile */
    nav li:nth-child(3), /* Brick Breaker link */
    .theme-switch-wrapper {
        display: none;
    }
}

.game-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 20px;
}

canvas {
    border: 2px solid #333;
    background: #000000;
    border-radius: 8px;
}

.controls {
    margin-top: 20px;
    text-align: center;
}

button {
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 5px;
}

/* Add this to your CSS file */
@media (max-width: 768px) {
    .mobile-hidden {
        display: none;
    }
}

/* Add media query for mobile devices */
@media (max-width: 768px) {
    body {
        flex-direction: column;
        padding: 0;
    }

    nav {
        width: 100%;
        position: relative;
        padding: 15px;
        top: 0;
        margin-bottom: 20px;
        border-bottom: 1px solid var(--border-color);
    }

    nav ul {
        display: flex;
        gap: 15px;
        margin: 10px 0;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
    }

    nav ul::-webkit-scrollbar {
        display: none; /* Chrome, Safari, Edge */
    }

    nav li {
        margin-bottom: 0;
        white-space: nowrap;
    }

    .theme-switch-wrapper {
        margin-top: 10px;
        margin-bottom: 5px;
    }

    main {
        padding: 0 15px;
    }
}

* {
    max-width: 100%;
    box-sizing: border-box;
} 