/* ========================================
   MOBILE MENU FIX - Suya Jerks
   ======================================== */

/* --- Base Navigation Styles --- */
.sj-nav {
  background: #fff;
  border-bottom: 1px solid #eee;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.sj-nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.sj-logo img {
  height: 36px;
  width: auto;
  display: block;
}

/* --- Desktop Navigation Links --- */
.sj-links {
  display: flex;
  gap: 24px;
  align-items: center;
}

.sj-links a {
  color: #333;
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  padding: 8px 12px;
  border-radius: 8px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.sj-links a:hover,
.sj-links a.active,
.sj-links a.current-menu-item {
  color: #ed1f24;
  background: rgba(237, 31, 36, 0.08);
}

/* --- Book Button --- */
.sj-book {
  background: #ed1f24;
  color: #fff !important;
  padding: 10px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.sj-book:hover {
  background: #c91a1f;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(237, 31, 36, 0.3);
}

/* --- Burger Button (Hidden on Desktop) --- */
.sj-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: none;
  padding: 8px;
  cursor: pointer;
  z-index: 1001;
  position: relative;
}

.sj-burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #333;
  transition: all 0.3s ease;
  border-radius: 2px;
}

.sj-burger.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.sj-burger.is-open span:nth-child(2) {
  opacity: 0;
}

.sj-burger.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ========================================
   MOBILE MENU STYLES (Tablet & Below)
   ======================================== */

@media (max-width: 1024px) {
  
  /* Show burger button */
  .sj-burger {
    display: flex;
  }

  /* Hide desktop book button on mobile */
  .sj-nav-inner > .sj-book {
    display: none;
  }

  /* Mobile menu container */
  .sj-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height for mobile browsers */
    background: #fff;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 80px 0 40px;
    overflow-y: auto;
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);
    z-index: 1000;
  }

  .sj-links.open {
    right: 0;
  }

  /* Mobile menu links */
  .sj-links a {
    padding: 16px 32px;
    border-radius: 0;
    border-bottom: 1px solid #f0f0f0;
    font-size: 16px;
    color: #333;
  }

  .sj-links a:hover,
  .sj-links a.active,
  .sj-links a.current-menu-item {
    background: #f8f8f8;
    color: #ed1f24;
    border-left: 4px solid #ed1f24;
    padding-left: 28px;
  }

  /* Book button in mobile menu */
  .sj-links .sj-book-mobile {
    margin: 20px 32px;
    text-align: center;
    display: block;
    background: #ed1f24;
    color: #fff !important;
    padding: 14px 24px;
    border-radius: 8px;
    font-weight: 600;
    border-left: none !important;
  }

  .sj-links .sj-book-mobile:hover {
    background: #c91a1f;
    padding-left: 24px;
  }

  /* Mobile overlay */
  body.sj-nav-open::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    animation: fadeIn 0.3s ease;
  }

  @keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
  }

  /* Prevent body scroll when menu open */
  body.sj-nav-open {
    overflow: hidden;
  }
}

/* ========================================
   SMALL MOBILE (< 480px)
   ======================================== */

@media (max-width: 480px) {
  .sj-nav-inner {
    padding: 12px 16px;
  }

  .sj-logo img {
    height: 32px;
  }

  .sj-links {
    width: 90%;
    max-width: none;
    padding: 70px 0 30px;
  }

  .sj-links a {
    padding: 14px 24px;
    font-size: 15px;
  }

  .sj-links a:hover,
  .sj-links a.active,
  .sj-links a.current-menu-item {
    padding-left: 20px;
  }

  .sj-links .sj-book-mobile {
    margin: 16px 24px;
    padding: 12px 20px;
  }
}

/* ========================================
   ACCESSIBILITY IMPROVEMENTS
   ======================================== */

/* Focus visible styles */
.sj-links a:focus-visible,
.sj-book:focus-visible,
.sj-burger:focus-visible {
  outline: 2px solid #ed1f24;
  outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .sj-links,
  .sj-burger span,
  .sj-links a {
    transition: none;
  }
}

/* ========================================
   FIX FOR EXISTING CONFLICTS
   ======================================== */

/* Override any conflicting mobile menu styles */
#sjMobileNav,
#sjMobileOverlay,
#sjMobileToggle,
#sjMobileClose {
  display: none !important;
}

/* Ensure proper stacking */
.sj-nav {
  position: sticky;
  z-index: 1000;
}

.sj-burger {
  z-index: 1001;
}

.sj-links {
  z-index: 1000;
}
