/* Hide the checkbox */
.nav-toggle {
  display: none;
}

/* Mobile styles */
@media (max-width: 768px) {
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: white;
    padding: 0;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    flex-direction: column;
    width: 100%;
    /* Animation setup */
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease-in-out;
    opacity: 0;
  }

  .nav-links a {
    padding: 0.75rem 1rem;
    width: 100%;
    display: block;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
  }

  /* Show menu when checkbox is checked */
  #nav-toggle:checked ~ .nav-links {
    max-height: 500px; /* Adjust this value based on your content */
    opacity: 1;
    padding: 1rem 0;
  }

  #nav-toggle:checked ~ .nav-links a {
    transform: translateX(0);
  }

  /* Stagger the animation of each link */
  .nav-links a:nth-child(1) {
    transition-delay: 0.1s;
  }
  .nav-links a:nth-child(2) {
    transition-delay: 0.2s;
  }
  .nav-links a:nth-child(3) {
    transition-delay: 0.3s;
  }
  .nav-links a:nth-child(4) {
    transition-delay: 0.4s;
  }
  .nav-links a:nth-child(5) {
    transition-delay: 0.5s;
  }
  .nav-links a:nth-child(6) {
    transition-delay: 0.6s;
  }

  /* Animate hamburger icon */
  .nav-toggle-label svg {
    transition: transform 0.3s ease;
  }

  #nav-toggle:checked ~ .nav-toggle-label svg {
    transform: rotate(90deg);
  }
}

/* Desktop styles */
@media (min-width: 769px) {
  .nav-links {
    display: flex;
    gap: 2rem;
    opacity: 1;
    max-height: none;
    overflow: visible;
  }

  .nav-links a {
    transform: none;
  }
}

/* Small phones (up to 375px) */
@media screen and (max-width: 769px) {
  h2 {
    font-size: 40px !important;
    line-height: 1.2 !important;
  }

  h3 {
    font-size: 23px !important;
    line-height: 1.2;
  }

  nav img{
      width: 60px !important;
    }

  nav svg{
      width: 30px !important;
    }

  p {
    font-size: 18px !important;
  }

  a {
    font-size: 14px !important;
  }

  *{
    font-size: 15px;
  }
}

a:hover{
  opacity: 0.9;
  scale: 0.97;
  transition: all 200ms ease-in-out;
}

a{
  opacity: 1;
  scale: 1;
  transition: all 200ms ease-in-out;
}

img:hover{
  transition: all 200ms ease-in-out;
  filter: saturate(130%);
  cursor: pointer;
}

img{
  transition: all 200ms ease-in-out;
}

body, html{
  overflow-x: hidden;
}

.sm {
  font-size: 160% !important;
}