/* Submenu styles */
.submenu {
  padding-left: 1rem;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55);
  margin-top: 0.5rem;
}

.submenu.open {
  max-height: 300px;
}

.submenu li {
  opacity: 0;
  transform: translateY(-10px);
  transition: all 0.3s ease;
  margin-bottom: 0.75rem;
}

.submenu.open li {
  opacity: 1;
  transform: translateY(0);
}

.submenu.open li:nth-child(1) {
  transition-delay: 0.1s;
}
.submenu.open li:nth-child(2) {
  transition-delay: 0.15s;
}
.submenu.open li:nth-child(3) {
  transition-delay: 0.2s;
}

/* ======= Responsive styles for tour pages ======= */

/* Global responsive grid */
.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -15px;
}

.col-lg-4,
.col-lg-6,
.col-lg-10,
.col-md-6,
.col-md-4,
.col-md-12 {
  padding: 0 15px;
  width: 100%;
}

/* Fullscreen menu responsive styles */
@media (max-width: 576px) {
  .fullscreen-menu-content {
    padding: 80px 15px;
  }

  .fullscreen-menu-nav ul li a {
    font-size: 1.5rem;
  }

  .menu-social a {
    width: 35px;
    height: 35px;
    font-size: 14px;
  }

  .menu-contact-info p {
    font-size: 14px;
  }

  .menu-cta .btn {
    width: 100%;
    padding: 12px;
    margin-bottom: 20px;
  }
}

/* Tours responsive styles */
@media (max-width: 992px) {
  /* Tour Hero Section */
  .tour-hero {
    height: 60vh;
  }

  .tour-hero-content .hero-title {
    font-size: 2.5rem;
  }

  .tour-meta {
    flex-wrap: wrap;
  }

  .tour-meta-item {
    margin-right: 15px;
    margin-bottom: 10px;
  }

  /* Columns */
  .col-lg-4 {
    width: 50%;
  }

  .col-lg-6 {
    width: 100%;
  }

  .col-lg-10.offset-lg-1 {
    width: 100%;
    margin-left: 0;
  }

  /* Overview Horizontal */
  .overview-horizontal {
    flex-direction: column;
    padding: 20px;
  }

  .overview-divider {
    width: 80%;
    height: 1px;
    margin: 15px 0;
  }

  .overview-item {
    width: 100%;
  }

  /* Inclusions/Exclusions */
  .inclusions-exclusions {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

@media (max-width: 768px) {
  /* Tour Hero Section */
  .tour-hero {
    height: 50vh;
  }

  .tour-hero-content .hero-title {
    font-size: 2rem;
  }

  .tour-hero-content .hero-subtitle {
    font-size: 1rem;
  }

  .tour-badge {
    font-size: 0.8rem;
  }

  /* Itinerary Section */
  .itinerary-day {
    padding: 20px 15px 20px 60px;
  }

  .day-number {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
    left: 15px;
  }

  /* Accommodation Section */
  .accommodation-tabs {
    flex-direction: column;
    align-items: stretch;
  }

  .accommodation-tab {
    margin: 5px 0;
  }

  .col-lg-4 {
    width: 100%;
  }

  .accommodation-card {
    margin-bottom: 20px;
  }

  /* Season Tabs */
  .season-tabs {
    flex-direction: column;
    align-items: stretch;
  }

  .season-tab {
    margin: 5px 0;
  }

  /* Pricing Tables */
  .price-table {
    font-size: 14px;
  }

  .price-table th,
  .price-table td {
    padding: 8px;
  }

  /* Create responsive table wrapper */
  .price-table-wrapper {
    overflow-x: auto;
    max-width: 100%;
    margin-bottom: 20px;
  }

  /* Forms */
  .col-md-6 {
    width: 100%;
  }

  .form-group {
    margin-bottom: 15px;
  }

  /* Form inputs and selects */
  input,
  select,
  textarea {
    width: 100%;
  }

  /* Fix for the fullscreen menu */
  .fullscreen-menu-content {
    padding: 80px 20px;
  }

  /* Improved form styles for mobile */
  .inquiry-form {
    padding: 25px;
  }

  .inquiry-form .row {
    margin: 0 -10px;
  }

  .inquiry-form .col-md-6 {
    padding: 0 10px;
  }

  .inquiry-form input,
  .inquiry-form select,
  .inquiry-form textarea {
    padding: 12px;
    font-size: 14px;
  }

  .inquiry-btn {
    width: 100%;
    padding: 12px 20px;
    font-size: 1rem;
  }

  .quick-inquiry-form {
    padding: 20px;
  }
}

@media (max-width: 576px) {
  /* Tour Hero Section */
  .tour-hero {
    height: 40vh;
  }

  .tour-hero-content .hero-title {
    font-size: 1.8rem;
  }

  .tour-meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .tour-meta-item {
    margin-bottom: 8px;
    margin-right: 0;
  }

  /* Itinerary Day */
  .itinerary-day {
    padding: 15px 10px 15px 50px;
  }

  .day-number {
    width: 35px;
    height: 35px;
    font-size: 1rem;
    left: 8px;
  }

  .day-details ul {
    padding-left: 15px;
  }

  /* Accommodation */
  .accommodation-image img {
    height: 180px;
  }

  /* Pricing Table */
  .price-table {
    font-size: 12px;
    min-width: 500px; /* Ensure it's scrollable on very small screens */
  }

  /* Inclusions/Exclusions */
  .inclusions-grid,
  .exclusions-grid {
    grid-template-columns: 1fr;
  }

  /* CTA section */
  .cta-features {
    flex-direction: column;
  }

  .cta-feature {
    margin-bottom: 10px;
  }

  .cta-buttons {
    flex-direction: column;
  }

  .cta-buttons .btn {
    margin: 5px 0;
    width: 100%;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  /* Booking CTA */
  .booking-cta {
    padding: 20px;
  }

  /* Form elements for very small screens */
  .inquiry-form {
    padding: 15px;
  }

  .inquiry-form h3,
  .quick-inquiry-form h3 {
    font-size: 1.5rem;
  }

  .form-group label {
    font-size: 14px;
  }

  .inquiry-btn {
    font-size: 0.9rem;
  }

  .quick-inquiry-form {
    padding: 15px;
  }
}

/* Fix for Android Chrome viewport height issue */
@media screen and (max-width: 767px) {
  .tour-hero {
    height: 50vh; /* fallback */
    height: calc(var(--vh, 1vh) * 50);
  }

  .fullscreen-menu {
    height: 100vh; /* fallback */
    height: calc(var(--vh, 1vh) * 100);
  }
}
