/** @format */

:root {
  /* Modern color palette */
  --primary-color: #1e1e2c;
  --secondary-color: #f8f9fa;
  --accent-color: #3a86ff;
  --accent-color-hover: #2667cc;
  --text-color: #333333;
  --text-light: #6c757d;
  --bg-light: #ffffff;
  --bg-dark: #121212;
  --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  --spacing: 2rem;

  /* Typography */
  --font-heading: "Poppins", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Import modern fonts */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Poppins:wght@400;500;600;700&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-body);
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--secondary-color);
  overflow-x: hidden;
  font-weight: 400;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing);
  width: 100%;
}

/* Navbar - Modern Glass Effect */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
  z-index: 1000;
  transition: all 0.3s ease;
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem var(--spacing);
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--primary-color);
  text-decoration: none;
  letter-spacing: -0.5px;
  transition: transform 0.3s ease;
}

.logo:hover {
  transform: translateY(-2px);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2.5rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  transition: all 0.3s ease;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  position: relative;
  font-size: 0.95rem;
}

.nav-links a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 50%;
  background-color: var(--accent-color);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.nav-links a:hover {
  color: var(--accent-color);
}

.nav-links a:hover::after {
  width: 70%;
}

.nav-links a.active {
  color: var(--accent-color);
}

.nav-links a.active::after {
  width: 70%;
}

/* Hero Section - Dynamic and Modern */
#hero {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(135deg, var(--primary-color) 0%, #2d2d45 100%);
  color: var(--secondary-color);
  position: relative;
  overflow: hidden;
}

#hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(
    circle at center,
    rgba(255, 255, 255, 0.1) 0%,
    rgba(255, 255, 255, 0) 70%
  );
  pointer-events: none;
}

/* Add a modern, subtle grain texture */
#hero::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
  opacity: 0.3;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 5;
  max-width: 800px;
  padding: 0 2rem;
}

.hero-content h1 {
  font-family: var(--font-heading);
  font-size: 5rem;
  margin-bottom: 1.5rem;
  animation: fadeInUp 1.2s ease;
  font-weight: 700;
  letter-spacing: -1px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  background: linear-gradient(90deg, #ffffff, #e0e0e0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.subtitle {
  font-family: var(--font-body);
  font-size: 1.5rem;
  opacity: 0.9;
  animation: fadeInUp 1.2s ease 0.3s;
  animation-fill-mode: both;
  margin-bottom: 2rem;
  font-weight: 300;
}

/* Modern call-to-action button */
.hero-cta {
  display: inline-block;
  background: var(--accent-color);
  color: white;
  padding: 0.8rem 2rem;
  border-radius: 50px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(58, 134, 255, 0.3);
  animation: fadeInUp 1.2s ease 0.6s;
  animation-fill-mode: both;
}

.hero-cta:hover {
  background: var(--accent-color-hover);
  transform: translateY(-3px);
  box-shadow: 0 6px 25px rgba(58, 134, 255, 0.4);
}

/* Work Grid - Modern Card Layout */
.work-grid {
  display: flex;
  flex-direction: column;
  gap: 6rem;
  padding: var(--spacing) 0;
}

/* Category Styling */
.category-section {
  padding: 4rem 0;
  scroll-margin-top: 80px; /* Accounts for fixed header */
  position: relative;
}

.category-header {
  margin-bottom: 3rem;
  text-align: center;
  position: relative;
}

.category-header h3 {
  font-family: var(--font-heading);
  font-size: 2.75rem;
  color: var(--primary-color);
  margin-bottom: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.5px;
  position: relative;
  display: inline-block;
}

.category-header h3::after {
  content: "";
  position: absolute;
  width: 60px;
  height: 3px;
  background: var(--accent-color);
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 2px;
}

.category-description {
  max-width: 800px;
  margin: 0 auto;
  color: var(--text-light);
  font-size: 1.15rem;
  line-height: 1.7;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2.5rem;
  padding: 1rem 0;
}

/* Work Item Styling - Modern Cards */
.work-item {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  background-color: var(--bg-light);
  box-shadow: var(--card-shadow);
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  display: flex;
  flex-direction: column;
  height: auto;
  min-height: 200px;
  border: 1px solid rgba(0, 0, 0, 0.04);
}

.work-item:hover {
  transform: translateY(-12px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.work-item img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.work-item:hover img {
  transform: scale(1.05);
}

.work-item-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 2rem;
}

.work-item-content h4 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
  font-weight: 600;
}

.work-item-content p {
  color: var(--text-light);
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.description {
  margin-top: 1rem;
  font-style: italic;
  color: var(--text-light);
  line-height: 1.7;
  border-left: 3px solid var(--accent-color);
  padding-left: 1rem;
  background-color: rgba(58, 134, 255, 0.03);
  padding: 1rem;
  border-radius: 0 8px 8px 0;
}

/* Section Styling */
.section {
  padding: 8rem 0;
  position: relative;
  background-color: var(--bg-light);
}

.section:nth-child(even) {
  background-color: var(--secondary-color);
}

.section h2 {
  font-family: var(--font-heading);
  font-size: 3rem;
  margin-bottom: 3rem;
  text-align: center;
  font-weight: 600;
  color: var(--primary-color);
  letter-spacing: -0.5px;
  position: relative;
}

.section h2::after {
  content: "";
  position: absolute;
  width: 80px;
  height: 4px;
  background: var(--accent-color);
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 2px;
}

/* Modern Video Container */
.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  max-width: 100%;
  border-radius: 12px;
  box-shadow: var(--card-shadow);
  margin-bottom: 1.5rem;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 12px;
}

/* Enhanced Image Container */
.image-container {
  width: 100%;
  height: 0;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  position: relative;
  overflow: hidden;
  margin-bottom: 1.5rem;
  border-radius: 12px;
  box-shadow: var(--card-shadow);
}

.image-container img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  border-radius: 12px;
}

.image-container:hover img {
  transform: scale(1.05);
}

/* Modern Articles Section */
.articles-section {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.articles-section h5 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
  color: var(--primary-color);
  font-weight: 600;
  position: relative;
  display: inline-block;
}

.articles-section h5::after {
  content: "";
  position: absolute;
  width: 30px;
  height: 2px;
  background: var(--accent-color);
  bottom: -8px;
  left: 0;
  border-radius: 2px;
}

.article-list {
  list-style: none;
  padding: 0;
}

.article-item {
  margin-bottom: 1.25rem;
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.article-item:last-child {
  margin-bottom: 0;
}

.article-item a {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  text-decoration: none;
  color: var(--text-color);
  padding: 1rem;
  border-radius: 8px;
  transition: all 0.3s ease;
  background-color: rgba(0, 0, 0, 0.02);
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.article-item a:hover {
  background-color: rgba(58, 134, 255, 0.05);
  transform: translateX(5px);
}

.article-snippet {
  flex: 1;
  margin-right: 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
}

.article-item i {
  color: var(--accent-color);
  font-size: 1rem;
  margin-top: 0.2rem;
  transition: transform 0.3s ease;
}

.article-item a:hover i {
  transform: translateX(3px);
}

/* Contact Section */
.contact-content {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
  padding: 3rem;
  border-radius: 16px;
  background-color: var(--bg-light);
  box-shadow: var(--card-shadow);
  position: relative;
  overflow: hidden;
}

.contact-content::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 6px;
  background: linear-gradient(
    90deg,
    var(--accent-color),
    var(--accent-color-hover)
  );
}

.contact-content h3 {
  font-family: var(--font-heading);
  font-size: 2rem;
  margin-bottom: 1.5rem;
  color: var(--primary-color);
}

.contact-content p {
  color: var(--text-light);
  font-size: 1.1rem;
  line-height: 1.8;
  margin-bottom: 2rem;
}

.contact-buttons {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.contact-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.9rem 2rem;
  background-color: var(--bg-light);
  color: var(--primary-color);
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 50px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
}

.contact-btn i {
  font-size: 1.1rem;
}

.contact-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
}

.contact-btn.primary {
  background-color: var(--accent-color);
  color: white;
  box-shadow: 0 4px 15px rgba(58, 134, 255, 0.3);
}

.contact-btn.primary:hover {
  background-color: var(--accent-color-hover);
  box-shadow: 0 8px 25px rgba(58, 134, 255, 0.4);
}

/* Footer Styling */
footer {
  padding: 4rem 0;
  background-color: var(--primary-color);
  color: var(--secondary-color);
  position: relative;
}

footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(
    90deg,
    var(--accent-color),
    rgba(255, 255, 255, 0.3),
    var(--accent-color)
  );
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 2rem;
}

.footer-logo {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 600;
  color: white;
  letter-spacing: -0.5px;
  margin-bottom: 1rem;
}

.footer-text {
  font-size: 0.95rem;
  opacity: 0.7;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-social {
  display: flex;
  gap: 1rem;
}

.social-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  text-decoration: none;
}

.social-icon:hover {
  background-color: var(--accent-color);
  transform: translateY(-3px);
}

.labs-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--secondary-color);
  text-decoration: none;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  background-color: rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  font-weight: 500;
}

.labs-link:hover {
  background-color: var(--accent-color);
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.labs-link i {
  font-size: 1.1rem;
}

.copyright {
  text-align: center;
  padding-top: 3rem;
  font-size: 0.9rem;
  opacity: 0.5;
}

/* Enhanced animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0% {
    transform: translate(0, 0) rotate(0deg);
  }
  50% {
    transform: translate(15px, -15px) rotate(2deg);
  }
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
}

/* Enhanced floating GIFs with Physics */
.floating-gifs {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  perspective: 1200px;
  transform-style: preserve-3d;
}

.floating-gif {
  position: absolute;
  width: 180px;
  height: 180px;
  object-fit: cover;
  border-radius: 24px;
  opacity: 0.75;
  filter: brightness(0.95) contrast(1.1);
  mix-blend-mode: multiply;
  will-change: transform;
  transform-origin: center center;
  transition: filter 0.5s ease, opacity 0.5s ease, border-radius 0.5s ease;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
  border: 4px solid rgba(255, 255, 255, 0.1);
}

/* Individual GIF styles with unique characteristics */
.floating-gif:nth-child(1) {
  top: 15%;
  left: 15%;
  width: 220px;
  height: 220px;
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  filter: brightness(0.95) contrast(1.1) hue-rotate(10deg);
}

.floating-gif:nth-child(2) {
  top: 65%;
  left: 25%;
  width: 160px;
  height: 160px;
  border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  filter: brightness(0.9) contrast(1.2) hue-rotate(-10deg);
}

.floating-gif:nth-child(3) {
  top: 35%;
  right: 20%;
  width: 190px;
  height: 190px;
  border-radius: 50% 50% 70% 30% / 30% 50% 50% 70%;
  filter: brightness(0.85) contrast(1.15) hue-rotate(5deg);
}

.floating-gif:nth-child(4) {
  bottom: 25%;
  right: 15%;
  width: 200px;
  height: 200px;
  border-radius: 30% 70% 50% 50% / 50% 50% 70% 30%;
  filter: brightness(0.92) contrast(1.1) hue-rotate(-5deg);
}

.floating-gif:nth-child(5) {
  top: 45%;
  left: 45%;
  width: 150px;
  height: 150px;
  border-radius: 70% 30% 50% 50% / 30% 50% 70% 50%;
  filter: brightness(0.88) contrast(1.12) hue-rotate(15deg);
}

/* Enhanced hover effects */
.floating-gif:hover {
  opacity: 0.9;
  filter: brightness(1.1) contrast(1.2);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  border-radius: 40%;
}

/* Loading indicator */
.loading-indicator {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--bg-light);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 2000;
}

.spinner {
  width: 60px;
  height: 60px;
  position: relative;
  margin-bottom: 30px;
}

.spinner:before,
.spinner:after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 5px solid transparent;
  border-top-color: var(--accent-color);
}

.spinner:before {
  z-index: 1;
  animation: spin 1s infinite;
}

.spinner:after {
  border: 5px solid rgba(0, 0, 0, 0.1);
}

.loading-text {
  font-family: var(--font-heading);
  color: var(--text-color);
  font-size: 1.1rem;
  letter-spacing: 1px;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Error message */
.error-message {
  padding: 2.5rem;
  background-color: #fff8f8;
  border-left: 4px solid #ff5757;
  margin: 2rem 0;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(255, 87, 87, 0.1);
}

.error-message h3 {
  color: #ff5757;
  margin-bottom: 1rem;
  font-family: var(--font-heading);
  font-size: 1.5rem;
}

.error-message p {
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.error-message button {
  background-color: var(--accent-color);
  color: white;
  padding: 0.8rem 2rem;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  margin-top: 1rem;
  transition: all 0.3s ease;
  font-weight: 500;
  font-family: var(--font-body);
  box-shadow: 0 4px 15px rgba(58, 134, 255, 0.3);
}

.error-message button:hover {
  background-color: var(--accent-color-hover);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(58, 134, 255, 0.4);
}

/* Mobile menu styles */
.menu-toggle {
  display: none;
}

/* Responsive Styles */
@media (max-width: 992px) {
  .category-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
  }

  .hero-content h1 {
    font-size: 4rem;
  }
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-color);
    cursor: pointer;
    z-index: 1001;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 400px;
    height: 100vh;
    background: var(--bg-light);
    display: flex;
    flex-direction: column;
    padding: 5rem 2rem 2rem;
    gap: 1.5rem;
    z-index: 1000;
    transition: right 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    align-items: flex-start;
  }

  .nav-links.active {
    right: 0;
  }

  .nav-links a {
    font-size: 1.2rem;
    width: 100%;
    padding: 1rem;
  }

  .nav-links a::after {
    display: none;
  }

  .nav-links a:hover {
    background-color: rgba(58, 134, 255, 0.08);
  }

  .nav-links a.active {
    background-color: rgba(58, 134, 255, 0.12);
  }

  .hero-content h1 {
    font-size: 3rem;
  }

  .subtitle {
    font-size: 1.2rem;
  }

  .category-header h3 {
    font-size: 2.25rem;
  }

  .section h2 {
    font-size: 2.5rem;
  }

  .work-item-content {
    padding: 1.5rem;
  }

  .work-item-content h4 {
    font-size: 1.35rem;
  }

  .contact-content {
    padding: 2rem;
  }

  .footer-content {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    justify-content: center;
  }

  .footer-social {
    justify-content: center;
  }

  /* Floating GIFs adjustments for mobile */
  .floating-gif {
    width: 120px;
    height: 120px;
  }

  .floating-gif:nth-child(1) {
    width: 140px;
    height: 140px;
  }

  .floating-gif:nth-child(2) {
    width: 100px;
    height: 100px;
  }

  .floating-gif:nth-child(3) {
    width: 130px;
    height: 130px;
  }

  .floating-gif:nth-child(4) {
    width: 140px;
    height: 140px;
  }

  .floating-gif:nth-child(5) {
    width: 110px;
    height: 110px;
  }
}

@media (max-width: 576px) {
  .hero-content h1 {
    font-size: 2.5rem;
  }

  .subtitle {
    font-size: 1.1rem;
  }

  .category-header h3 {
    font-size: 2rem;
  }

  .section h2 {
    font-size: 2.25rem;
  }

  .section {
    padding: 5rem 0;
  }

  .floating-gif {
    width: 100px;
    height: 100px;
  }

  .floating-gif:nth-child(1) {
    width: 120px;
    height: 120px;
  }

  .floating-gif:nth-child(2),
  .floating-gif:nth-child(5) {
    width: 80px;
    height: 80px;
  }

  .floating-gif:nth-child(3),
  .floating-gif:nth-child(4) {
    width: 110px;
    height: 110px;
  }
}

/* Light/Dark Mode Toggle */
.theme-switch {
  position: relative;
  width: 60px;
  height: 30px;
  background-color: rgba(0, 0, 0, 0.1);
  border-radius: 15px;
  cursor: pointer;
  transition: all 0.3s ease;
  overflow: hidden;
}

.theme-switch::before {
  content: "☀️";
  position: absolute;
  top: 50%;
  left: 5px;
  transform: translateY(-50%);
  font-size: 16px;
  transition: all 0.3s ease;
}

.theme-switch::after {
  content: "🌙";
  position: absolute;
  top: 50%;
  right: 5px;
  transform: translateY(-50%);
  font-size: 16px;
  transition: all 0.3s ease;
}

.theme-switch .slider {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background-color: white;
  transition: all 0.3s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

/* Dark mode styles */
body.dark-mode {
  --primary-color: #121212;
  --secondary-color: #1e1e2c;
  --text-color: #e0e0e0;
  --text-light: #a0a0a0;
  --bg-light: #252836;
  --bg-dark: #1a1a2a;
  --card-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);

  background-color: var(--secondary-color);
  color: var(--text-color);
}

body.dark-mode .navbar {
  background-color: rgba(30, 30, 44, 0.85);
}

body.dark-mode .logo {
  color: white;
}

body.dark-mode .nav-links a {
  color: var(--text-color);
}

body.dark-mode .work-item {
  background-color: var(--bg-light);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

body.dark-mode .work-item-content h4 {
  color: white;
}

body.dark-mode .category-header h3,
body.dark-mode .section h2 {
  color: white;
}

body.dark-mode .theme-switch {
  background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .theme-switch .slider {
  transform: translateX(30px);
  background-color: var(--primary-color);
}

body.dark-mode .article-item a {
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

body.dark-mode .loading-indicator {
  background-color: var(--bg-dark);
}

body.dark-mode .error-message {
  background-color: rgba(255, 87, 87, 0.1);
}

/* Add CSS for prefers-reduced-motion */
@media (prefers-reduced-motion) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .floating-gif {
    animation: none !important;
    transition: none !important;
  }
}
