/* =========================================
   TOGGLE.CSS - FIXED & SIMPLIFIED
   Mobile navigation hamburger menu
   ========================================= */

/* =========================================
   BASE MOBILE NAVIGATION STYLES
   ========================================= */

.mobile-nav {
  display: block;
  position: relative;
  z-index: 2000;
}

/* =========================================
   HAMBURGER BUTTON STYLES
   ========================================= */

.hamburger {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 20px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  position: relative;
}

.hamburger span {
  width: 100%;
  height: 3px;
  background-color: white;
  transition: all 0.3s ease;
  position: absolute;
  border-radius: 2px;
}

.hamburger span:nth-child(1) {
  top: 0;
}

.hamburger span:nth-child(2) {
  top: 50%;
  transform: translateY(-50%);
}

.hamburger span:nth-child(3) {
  bottom: 0;
}

/* =========================================
   HAMBURGER ANIMATION STATES
   ========================================= */

.hamburger.open span:nth-child(1) {
  transform: rotate(45deg);
  top: 50%;
}

.hamburger.open span:nth-child(2) {
  opacity: 0;
}

.hamburger.open span:nth-child(3) {
  transform: rotate(-45deg);
  top: 50%;
}

/* =========================================
   MOBILE MENU CONTAINER
   ========================================= */

.mobile-menu {
  position: fixed;
  top: 150px;
  left: 10px;
  right: 10px;
  bottom: 0;
  background-color: white;
  padding: 2rem;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
  z-index: 2001;
  display: none;
  border-radius: 25px;
}

.mobile-menu.open {
  transform: translateX(0);
  display: block;
  z-index: 2002;
}

/* =========================================
   MOBILE CONTENT CONTAINER
   ========================================= */

.mobile-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
}

/* =========================================
   MOBILE NAVIGATION ITEMS - SIMPLIFIED
   ========================================= */

.mobile-nav-item {
  padding: 0.8rem 0;
  width: 100%;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.1);
  border: 2px solid transparent;
}

/* Remove border from last visible items */
#registerOption,
#logoutOption {
  box-shadow: none;
}

.mobile-nav-item a {
  display: block;
  color: #333;
  font-size: 1.1rem;
  font-weight: 500;
  text-decoration: none;
  padding: 0.5rem 0.8rem;
}

/* Click/tap feedback - make text slightly bolder when clicked */
.mobile-nav-item a:active {
  font-weight: 600;
}

.mobile-nav-item a.active {
  color: #000;
  font-weight: 700;
}

/* =========================================
   MOBILE USER INFO
   ========================================= */

.mobile-username {
  font-weight: 700;
  font-size: 1.2rem;
  color: #333;
  padding: 0.5rem 0.8rem;
}

/* Override hover effects for the logged in info container */
#mobileLoggedInInfo {
  background-color: transparent;
  border: 2px solid transparent;
  border-radius: 0;
}

#mobileLoggedInInfo .mobile-username {
  color: #333;
}

/* =========================================
   SPECIAL MOBILE MENU ITEMS
   ========================================= */

#logoutOption a {
  color: #8b0000;
}

/* =========================================
   RESPONSIVE BREAKPOINTS
   ========================================= */

/* Show mobile nav on small screens (850px and below) */
@media (max-width: 850px) {
  .mobile-nav {
    display: block;
    margin: 0;
  }

  .mobile-menu.open {
    margin: 0;
  }
}

/* Tablets (768px and below) */
@media (max-width: 768px) {
  .mobile-menu {
    top: 150px;
    left: 15px;
    right: 15px;
  }
}

/* Small phones (480px and below) */
@media (max-width: 480px) {
  .mobile-menu {
    top: 150px;
    left: 10px;
    right: 10px;
    padding: 1.5rem;
  }

  .mobile-nav-item {
    padding: 0.6rem 0;
  }

  .mobile-nav-item a {
    font-size: 1rem;
    padding: 0.4rem 0.6rem;
  }

  .mobile-username {
    font-size: 1.1rem;
  }
}

/* Very small phones (375px and below) */
@media (max-width: 375px) {
  .mobile-menu {
    top: 150px;
    padding: 1rem;
  }

  .mobile-nav-item a {
    font-size: 0.95rem;
  }

  .mobile-username {
    font-size: 1rem;
  }
}

/* Hide mobile nav on desktop (851px and above) */
@media (min-width: 851px) {
  .mobile-nav {
    display: none !important;
  }
}
