/**
 * Responsive Styles
 */

@media (max-width: 1200px) {
    .nav-container {
        padding: 0 20px;
    }
    
    .nav-center {
        gap: 15px;
    }
    
    .package-content-layout {
        grid-template-columns: 300px 1fr;
        gap: 30px;
    }
}

@media (max-width: 968px) {
    .hero-title {
        font-size: 42px;
    }
    
    .section-title {
        font-size: 36px;
    }
    
    .package-card-large {
        grid-template-columns: 1fr;
    }
    
    .package-image-large {
        height: 300px;
    }
    
    .package-content-layout {
        grid-template-columns: 1fr;
    }
    
    .booking-summary-card {
        position: static;
    }
    
    .nav-center {
        gap: 8px;
    }
    
    .nav-link {
        padding: 6px 10px;
    }
    
    .nav-icon {
        font-size: 18px;
    }
    
    .nav-label {
        font-size: 10px;
        display: block;
    }
    
    /* Tablet: 5x1 grid becomes 3 columns */
    .destinations-grid-5x1 {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(2, 250px);
        display: grid;
    }
    
    .destinations-grid-5x1 .destination-card:nth-child(1),
    .destinations-grid-5x1 .destination-card:nth-child(2),
    .destinations-grid-5x1 .destination-card:nth-child(3) {
        grid-row: 1 / 2;
    }
    
    .destinations-grid-5x1 .destination-card:nth-child(4),
    .destinations-grid-5x1 .destination-card:nth-child(5) {
        grid-row: 2 / 3;
    }
    
    .destinations-grid-5x1 .destination-card:nth-child(1),
    .destinations-grid-5x1 .destination-card:nth-child(4) {
        grid-column: 1 / 2;
    }
    
    .destinations-grid-5x1 .destination-card:nth-child(2),
    .destinations-grid-5x1 .destination-card:nth-child(5) {
        grid-column: 2 / 3;
    }
    
    .destinations-grid-5x1 .destination-card:nth-child(3) {
        grid-column: 3 / 4;
    }
}

@media (max-width: 768px) {
    .hero-section {
        height: 450px;
    }
    
    .hero-title {
        font-size: 28px;
        margin-bottom: 10px;
    }
    
    .hero-subtitle {
        font-size: 16px;
        display: block;
        margin-bottom: 20px;
    }
    
    .hero-content {
        padding: 0 15px;
    }
    
    /* Hero Navigation - Keep icons in one line on mobile */
    .hero-navigation {
        flex-wrap: nowrap !important;
        gap: 6px !important;
        padding: 8px 10px !important;
        max-width: 100% !important;
        right: 10px !important;
        left: 10px !important;
        top: 10px !important;
        justify-content: space-between;
    }
    
    .hero-nav-link {
        min-width: 0 !important;
        flex: 1 1 0;
        padding: 6px 4px !important;
        max-width: 25%;
    }
    
    .hero-nav-icon {
        font-size: 20px !important;
    }
    
    .hero-nav-label {
        font-size: 9px !important;
    }
    
    .search-wrapper {
        max-width: 95%;
        margin: 0 auto;
    }
    
    .search-input-wrapper {
        width: 100%;
        padding: 8px 8px 8px 15px;
        min-width: 0;
    }
    
    .search-icon {
        font-size: 16px;
    }
    
    .search-input {
        font-size: 14px;
    }
    
    .search-input::placeholder {
        font-size: 14px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    
    .search-btn {
        padding: 8px 16px;
        font-size: 13px;
        flex-shrink: 0;
    }
    
    .packages-carousel-wrapper {
        margin: 20px -20px 0;
        padding: 0 50px;
    }
    
    .packages-carousel .package-card {
        flex: 0 0 280px;
        min-width: 280px;
    }
    
    .carousel-nav-btn {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .carousel-prev {
        left: 5px;
    }
    
    .carousel-next {
        right: 5px;
    }
    
    /* Mobile Destinations - Horizontal Scroll */
    .destinations-grid {
        display: flex;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 15px;
        padding: 0 15px;
        margin: 0 -15px;
    }
    
    .destinations-grid-5x1 {
        display: flex;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 15px;
        padding: 0 15px;
        margin: 0 -15px;
        grid-template-columns: none;
        grid-template-rows: none;
    }
    
    .destinations-grid::-webkit-scrollbar,
    .destinations-grid-5x1::-webkit-scrollbar {
        display: none;
    }
    
    .destination-card {
        flex: 0 0 180px;
        min-width: 180px;
    }
    
    .destination-image {
        height: 200px;
    }
    
    /* Mobile Themes - Circular thumbnails in horizontal scroll */
    .themes-carousel {
        display: flex;
        overflow-x: auto;
        overflow-y: visible; /* Allow shadows to show above/below */
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 15px;
        padding: 20px 15px; /* Add vertical padding for shadow space */
        margin: 0 -15px;
        justify-content: flex-start;
        flex-wrap: nowrap;
    }
    
    .themes-carousel::-webkit-scrollbar {
        display: none;
    }
    
    .theme-card {
        flex: 0 0 120px;
        min-width: 120px;
        padding: 15px;
        border-radius: 50%;
        width: 120px;
        height: 120px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        /* Fix shadow clipping - add padding for shadow space */
        margin: 10px;
        /* Ensure shadow is fully visible around circle */
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), 0 2px 4px rgba(0, 0, 0, 0.1);
    }
    
    .theme-icon {
        font-size: 40px;
        margin-bottom: 8px;
    }
    
    .theme-name {
        font-size: 12px;
    }
    
    /* Deals carousel — slightly narrower cards on mobile */
    .deals-carousel .deal-card {
        flex: 0 0 240px;
        min-width: 240px;
        height: 260px;
    }

    .deal-title {
        font-size: 16px;
    }

    .deal-duration {
        font-size: 13px;
    }

    .deal-overlay {
        padding: 20px 15px 15px;
    }
}

/* Tablet and Medium Screens */
@media (max-width: 1024px) and (min-width: 769px) {
    .deals-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    /* Single row becomes 2 columns on tablet */
    .deals-grid-single-row {
        grid-template-rows: 300px;
    }
    
    .deals-grid-single-row .deal-card:nth-child(1) {
        grid-column: 1 / 2;
        grid-row: 1 / 2;
    }
    
    .deals-grid-single-row .deal-card:nth-child(2) {
        grid-column: 2 / 3;
        grid-row: 1 / 2;
    }
    
    .deals-grid-single-row .deal-card:nth-child(3) {
        grid-column: 1 / 2;
        grid-row: 2 / 3;
    }
    
    .deals-grid-single-row .deal-card:nth-child(4) {
        grid-column: 2 / 3;
        grid-row: 2 / 3;
    }
    
    /* Double row becomes 2 columns with auto rows on tablet */
    .deals-grid-double-row {
        grid-template-rows: repeat(4, 300px);
    }
    
    .deals-grid-double-row .deal-card:nth-child(odd) {
        grid-column: 1 / 2;
    }
    
    .deals-grid-double-row .deal-card:nth-child(even) {
        grid-column: 2 / 3;
    }
    
    .deals-grid-double-row .deal-card:nth-child(1),
    .deals-grid-double-row .deal-card:nth-child(2) {
        grid-row: 1 / 2;
    }
    
    .deals-grid-double-row .deal-card:nth-child(3),
    .deals-grid-double-row .deal-card:nth-child(4) {
        grid-row: 2 / 3;
    }
    
    .deals-grid-double-row .deal-card:nth-child(5),
    .deals-grid-double-row .deal-card:nth-child(6) {
        grid-row: 3 / 4;
    }
    
    .deals-grid-double-row .deal-card:nth-child(7),
    .deals-grid-double-row .deal-card:nth-child(8) {
        grid-row: 4 / 5;
    }

    .deal-title {
        font-size: 16px;
    }

    .deal-overlay {
        padding: 20px 15px 15px;
    }

    /* Mobile Navigation - Icons moved to hero section */
    .nav-center {
        display: none;
    }
    
    /* Hero Navigation - Mobile responsive */
    .hero-navigation {
        top: 15px;
        right: 15px;
        gap: 8px;
        padding: 10px 12px;
        max-width: calc(100% - 30px);
    }
    
    .hero-nav-link {
        min-width: 60px;
        padding: 6px 8px;
    }
    
    .hero-nav-icon {
        font-size: 20px;
    }
    
    .hero-nav-label {
        font-size: 10px;
    }
    
    .nav-icon {
        display: block;
        font-size: 22px;
        margin-bottom: 2px;
    }
    
    .nav-label {
        font-size: 11px;
        font-weight: 500;
        display: block;
        margin: 0;
    }
    
    .logo-img {
        max-height: 40px;
        max-width: 60px;
    }
    
    .logo-g {
        width: 40px;
        height: 40px;
    }
    
    .nav-container {
        padding: 0 15px;
        gap: 10px;
        max-width: 100%;
        display: flex;
        flex-wrap: nowrap;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .nav-left {
        order: 1;
        flex-shrink: 0;
    }
    
    .nav-center {
        order: 2;
        flex: 1;
        min-width: 0;
    }
    
    .nav-right {
        order: 3;
        gap: 8px;
        flex-shrink: 0;
    }
    
    .customer-service {
        display: none;
    }
    
    .currency-select {
        display: none;
    }
    
    .login-btn {
        display: none;
    }
    
    /* Floating CTA removed */
    
    .search-filters {
        flex-direction: column;
    }
    
    .filter-group {
        width: 100%;
    }
    
    .search-again-btn {
        width: 100%;
    }
    
    .traveler-count-group {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 28px;
    }
    
    .hero-subtitle {
        font-size: 16px;
    }
    
    .section-title {
        font-size: 24px;
    }
    
    .section-subtitle {
        font-size: 14px;
        margin-bottom: 15px;
    }
    
    .package-hero-content h1 {
        font-size: 28px;
    }
    
    .modal-content {
        padding: 25px;
        margin: 10% auto;
    }
    
    .nav-link {
        padding: 6px 12px;
        min-width: 65px;
    }
    
    .nav-icon {
        font-size: 20px;
    }
    
    .nav-label {
        font-size: 10px;
    }
    
    .nav-container {
        padding: 0 10px;
        gap: 5px;
    }
    
    .nav-center {
        gap: 12px;
        padding-left: 10px;
    }
    
    .theme-card {
        width: 100px;
        height: 100px;
        min-width: 100px;
        flex: 0 0 100px;
        /* Fix shadow clipping - add padding for shadow space */
        margin: 8px;
        /* Ensure shadow is fully visible around circle */
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), 0 2px 4px rgba(0, 0, 0, 0.1);
    }
    
    .theme-icon {
        font-size: 35px;
    }
    
    .theme-name {
        font-size: 11px;
    }
    
    .destination-card {
        flex: 0 0 160px;
        min-width: 160px;
    }
    
    .destination-image {
        height: 180px;
    }
    
    /* Floating CTA removed */
    
    .chatbot-indicator {
        bottom: 15px;
        right: 15px;
    }
    
    .chatbot-avatar {
        width: 50px;
        height: 50px;
        font-size: 12px;
    }
    
    .chatbot-bubble {
        width: 25px;
        height: 25px;
        font-size: 14px;
    }
    
    .packages-carousel-wrapper {
        padding: 0 40px;
    }

    .carousel-nav-btn {
        display: none;
    }

    /* Deals carousel — compact cards on very small phones */
    .deals-carousel .deal-card {
        flex: 0 0 200px;
        min-width: 200px;
        height: 240px;
    }
}
