/* Modern Mobile Menu Styles */

/* Hide mobile header and elements on desktop */
.mobile-header,
.mobile-menu-overlay,
.mobile-menu-sidebar {
  display: none;
}

/* Mobile styles - show only on screens below 992px */
@media only screen and (max-width: 991px) {
  /* Fix horizontal overflow issues */
  body {
    overflow-x: hidden;
    margin: 0;
    padding: 0;
  }

  html {
    overflow-x: hidden;
  }

  .container {
    max-width: 100% !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

  .row {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  /* Show mobile elements */
  .mobile-header {
    display: block;
  }

  /* Hide desktop header on mobile */
  .header-logo-menu {
    display: none !important;
  }

  /* Modern Fixed Mobile Header */
  .mobile-header {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
    padding: 0;
  }

  .mobile-header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    max-width: 100%;
    margin: 0 auto;
  }

  .mobile-logo a {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
  }

  .mobile-logo img {
    height: 40px;
    width: auto;
  }

  .mobile-logo span {
    font-size: 18px;
    font-weight: 700;
    color: #333;
    line-height: 1.2;
  }

  /* Hamburger Menu Button */
  .mobile-menu-toggle {
    background: transparent;
    border: none;
    width: 30px;
    height: 25px;
    position: relative;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
    flex-shrink: 0;
  }

  .mobile-menu-toggle span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: #333;
    border-radius: 3px;
    opacity: 1;
    left: 0;
    transition: all 0.3s ease;
  }

  .mobile-menu-toggle span:nth-child(1) {
    top: 0;
  }

  .mobile-menu-toggle span:nth-child(2) {
    top: 11px;
  }

  .mobile-menu-toggle span:nth-child(3) {
    top: 22px;
  }

  /* Hamburger animation when menu is open */
  .mobile-menu-toggle.active span:nth-child(1) {
    top: 11px;
    transform: rotate(135deg);
  }

  .mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
    left: -60px;
  }

  .mobile-menu-toggle.active span:nth-child(3) {
    top: 11px;
    transform: rotate(-135deg);
  }

  /* Add padding to body to account for fixed header */
  body {
    padding-top: 70px;
  }

  /* Adjust padding for pages with breadcrumb */
  .breadcrumb-banner-area {
    margin-top: 0;
    padding-top: 0;
  }

  /* Home page slider/hero adjustments */
  .slider-area {
    height: 80vh !important;
    max-height: 80vh !important;
    overflow: hidden !important;
    position: relative;
  }

  .slider-area .nivoSlider {
    height: 80vh !important;
    max-height: 80vh !important;
    position: relative !important;
    overflow: hidden !important;
  }

  .slider-area .nivo-main-image,
  .slider-area img {
    width: 100% !important;
    height: 80vh !important;
    max-height: 80vh !important;
    object-fit: cover !important;
    object-position: center !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
  }

  /* Fix slider transitions */
  .slider-area .nivoSlider img {
    display: block !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
  }

  .slider-area .nivo-slice {
    display: block !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    height: 100% !important;
  }

  /* Center slider text */
  .slider-area .banner-content {
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
  }

  .slider-area .banner-content .text-content {
    width: 100%;
    padding: 0 20px;
  }

  .slider-area .banner-content .text-content h1.title1,
  .slider-area .banner-content .text-content p.sub-title {
    text-align: center;
  }

  .slider-area .banner-content .banner-readmore {
    text-align: center;
  }

  /* Fix scroll-up button positioning */
  .scrollup {
    position: fixed !important;
    right: 15px !important;
    bottom: 15px !important;
    z-index: 999;
    width: 40px !important;
    height: 40px !important;
  }

  /* Overlay */
  .mobile-menu-overlay {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
  }

  .mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
  }

  /* Slide-in Menu Sidebar */
  .mobile-menu-sidebar {
    display: block;
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100vh;
    background: #fff;
    z-index: 1000;
    overflow-y: auto;
    transition: right 0.3s ease;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
  }

  .mobile-menu-sidebar.active {
    right: 0;
  }

  .mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #eee;
    background: #2bb8b1;
    color: #fff;
  }

  .mobile-menu-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
  }

  .mobile-menu-close {
    background: transparent;
    border: none;
    font-size: 24px;
    color: #fff;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Mobile Navigation */
  .mobile-nav {
    padding: 0;
  }

  .mobile-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
  }

  .mobile-nav > ul > li {
    border-bottom: 1px solid #eee;
  }

  .mobile-nav > ul > li > a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    color: #333;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
  }

  .mobile-nav > ul > li > a i.fa {
    margin-right: 10px;
    width: 20px;
    text-align: center;
    color: #2bb8b1;
  }

  .mobile-nav > ul > li > a:hover {
    background: #f8f8f8;
    padding-left: 25px;
  }

  /* Submenu */
  .mobile-nav .submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: #f8f8f8;
  }

  .mobile-nav .has-submenu.active .submenu {
    max-height: 500px;
  }

  .mobile-nav .submenu li a {
    display: block;
    padding: 12px 20px 12px 50px;
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
  }

  .mobile-nav .submenu li a:hover {
    background: #eee;
    padding-left: 55px;
    color: #2bb8b1;
  }

  .mobile-nav .submenu-toggle {
    font-size: 12px;
    transition: transform 0.3s ease;
  }

  .mobile-nav .has-submenu.active .submenu-toggle {
    transform: rotate(180deg);
  }

  /* Prevent body scroll when menu is open */
  body.mobile-menu-open {
    overflow: hidden;
  }
}

/* Tablet adjustments */
@media only screen and (min-width: 768px) and (max-width: 991px) {
  .mobile-logo span {
    font-size: 20px;
  }

  .mobile-logo img {
    height: 45px;
  }

  body {
    padding-top: 75px;
  }
}
