﻿body {
    font-family: 'Open Sans', Arial, Helvetica, sans-serif;
}

:root {
    --brand-blue: #00aeef;
    --brand-blue-dark: #0090c8;
    --ink: #1a1a1a;
    --paper: #ffffff;
    --muted: #f6f6f6;
    --accent: #FFEA00;
    --nav-text: #FFFFFF;
}

.bg-primary-jer {
    background-color: var(--brand-blue);
}

.navimain {
    padding: 0px 25px;
}

@media (max-width: 768px) {
    .navimain {
        padding: 0px 15px;
    }
}

    .navbar {
        background-color: #00aeef;
    }

    .navbar-nav .nav-link {
        color: #F0F1F6 !important;
        font-size: 18px;
    }

    .nav-link:hover {
        text-decoration: underline;
    }

    .navbar .nav-link {
        color: var(--nav-text);
    }

        .navbar .nav-link:hover {
            opacity: .85;
        }


    .text-main-blue {
        color: #00aeef;
    }

    .text-main-white {
        color: #fff;
    }

    #nav-mega > .d-flex {
        width: 100%;
        padding-left: 0px;
        padding-right: 0px;
        margin-right: auto;
        margin-left: auto;
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
    }

    #nav-mega .dropdown-menu {
        margin-top: 1.5rem;
        --bs-dropdown-min-width: 0;
        min-width: 0;
        width: auto;
        padding: 0;
    }

    #nav-mega .mega-panel {
        display: flex;
        width: max-content;
        max-width: 95vw;
        background: var(--paper);
        min-width: 600px;
    }

    /* Left Navigation Menu */
    .mega-nav-left {
        background-color: #f5f5f5;
        min-width: 200px;
        padding: 1rem 0;
        display: flex;
        flex-direction: column;
    }

    .mega-sections-vertical {
        display: flex;
        flex-direction: column;
        height: 100%;
    }

    .mega-nav-item {
        display: flex;
        align-items: center;
        padding: 1rem 1.5rem;
        background: transparent;
        border: none;
        text-align: left;
        color: #666;
        font-size: 14px;
        font-weight: 600;
        letter-spacing: 0.5px;
        cursor: pointer;
        transition: all 0.2s ease;
        position: relative;
    }

    .mega-nav-item:hover {
        background-color: #eeeeee;
    }

    .mega-nav-item-active {
        color: var(--brand-blue);
        background-color: transparent;
    }

    .mega-nav-item-active .mega-nav-text {
        color: var(--brand-blue);
        font-weight: 700;
    }

    .mega-nav-indicator {
        position: absolute;
        left: 0;
        top: 0;
        bottom: 0;
        width: 4px;
        background-color: var(--brand-blue);
        display: none;
    }

    .mega-nav-item-active .mega-nav-indicator {
        display: block;
    }

    .mega-nav-text {
        flex: 1;
    }

    .mega-nav-item-active .fa-chevron-right {
        color: var(--brand-blue);
        font-size: 12px;
    }

    /* Discover Hidden Gems Button */
    .mega-discover-btn-container {
        margin-top: auto;
        padding: 1rem 1.5rem;
    }

    .mega-discover-btn {
        width: 100%;
        background-color: #e3f2fd;
        border: none;
        border-radius: 8px;
        padding: 1.5rem 1rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        cursor: pointer;
        transition: background-color 0.2s ease;
        text-decoration: none;
        color: inherit;
    }

    .mega-discover-btn:hover {
        background-color: #bbdefb;
    }

    .mega-discover-icon {
        color: var(--brand-blue);
        font-size: 24px;
        margin-bottom: 0.5rem;
    }

    .mega-discover-text {
        color: var(--brand-blue);
        font-size: 14px;
        font-weight: 600;
        margin-bottom: 0.25rem;
    }

    .mega-discover-link {
        color: var(--brand-blue);
        font-size: 12px;
        text-decoration: underline;
        font-weight: 500;
    }

    .mega-discover-link:hover {
        color: var(--brand-blue);
    }

    /* Main Content Area */
    .mega-content-area {
        flex: 1;
        padding: 1.5rem;
        min-width: 400px;
    }

    .mega-content-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 1.5rem;
    }

    .mega-content-title {
        font-size: 16px;
        font-weight: 700;
        color: #333;
        letter-spacing: 0.5px;
        margin: 0;
        text-transform: uppercase;
    }

    .mega-content-view-all {
        font-size: 14px;
        color: #333;
        text-decoration: none;
        font-weight: 500;
    }

    .mega-content-view-all:hover {
        text-decoration: underline;
        color: #333;
    }

    /* States Grid */
    .mega-states-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
        max-height: 400px;
        overflow-y: auto;
    }

    .mega-state-card {
        background: transparent;
        border: none;
        padding: 0;
        cursor: pointer;
        transition: transform 0.2s ease;
        display: flex;
        flex-direction: column;
    }

    .mega-state-card:hover {
        transform: translateY(-2px);
    }

    .mega-state-card-image {
        width: 100%;
        height: 140px;
        border-radius: 8px;
        overflow: hidden;
        margin-bottom: 0.75rem;
    }

    .mega-state-card-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .mega-state-card-name {
        font-size: 14px;
        font-weight: 600;
        color: #333;
        text-align: center;
    }

    .mega-state-card.active .mega-state-card-name {
        color: var(--brand-blue);
        font-weight: 700;
    }

    .mega-state-card.active .mega-state-card-image {
        border: 2px solid var(--brand-blue);
    }

    /* Experiences and Hot Deals Lists */
    .mega-experiences-list,
    .mega-hotdeals-list {
        max-height: 400px;
        overflow-y: auto;
    }

    .mega-experiences-list .state-item,
    .mega-hotdeals-list a {
        padding: 0.75rem 0.5rem;
        border-radius: 4px;
    }

    .mega-experiences-list .state-item:hover,
    .mega-hotdeals-list a:hover {
        background-color: #f5f5f5;
    }

    .mega-heading {
        font-weight: 700;
        letter-spacing: .02em;
        color: inherit;
        text-decoration: none;
    }

        .mega-heading:hover {
            text-decoration: none;
        }

    .mega-heading-view {
        font-weight: 700;
        letter-spacing: .02em;
        color: inherit;
        text-decoration: none;
    }

        .mega-heading-view:hover {
            text-decoration: underline;
        }
    /* Left column */

    .mega-sections .list-group-item {
        border: 0;
        padding: .8rem 0.6rem;
        border-radius: 0;
        width: max-content;
    }

        .mega-sections .list-group-item.active {
            background: transparent;
            color: var(--brand-blue);
            font-weight: 700;
        }

    /* Middle: States */
    .items-list {
        max-height: clamp(10rem, 50vw, 25rem);
    }

    .state-item {
        color: var(--ink);
        text-decoration: none;
        padding: .55rem .25rem;
    }

        .state-item img {
            width: 48px;
            height: 48px;
        }

        .state-item:hover {
            background: var(--muted);
        }

        .state-item.active span {
            background: transparent;
            color: var(--brand-blue);
            font-weight: 700;
        }

    .nav-state-products .btn {
        color: var(--ink);
    }
    /* Right: Attractions */

    #attractionList a.attraction-link {
        display: flex;
        align-items: center;
        gap: .75rem;
        padding: .6rem .4rem;
        color: var(--ink);
        text-decoration: none;
        border-radius: .5rem;
    }

        #attractionList a.attraction-link:hover {
            background: var(--muted);
        }

    #attractionList img {
        width: 48px;
        height: 48px;
        border-radius: 50%;
        object-fit: cover;
    }
    /* Fade-in animation for middle/right columns */

    #destinationsContent {
        opacity: 0;
        transform: translateY(10px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

        #destinationsContent.showing {
            opacity: 1;
            transform: translateY(0);
        }
        /* Hide without display:none so animation works */

        #destinationsContent.hidden {
            display: none;
        }

    #experiencesContent {
        opacity: 0;
        transform: translateY(10px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

        #experiencesContent.showing {
            opacity: 1;
            transform: translateY(0);
        }

        #experiencesContent.hidden {
            display: none;
        }

    #hotdealsContent {
        opacity: 0;
        transform: translateY(10px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

        #hotdealsContent.showing {
            opacity: 1;
            transform: translateY(0);
        }

        #hotdealsContent.hidden {
            display: none;
        }

    /* Let the search grow/shrink with the navbar */
    #nav-mega .search-flex {
        flex: 1 1 10rem;
        min-width: 0;
    }

        /* Make the autoComplete input fluid */
        #nav-mega .search-flex .autoComplete_wrapper > input,
        #nav-mega .search-flex > input {
            width: 100%;
        }

    /* keep suggestions above dropdowns */
    /*#nav-mega .autoComplete_wrapper > ul {
    z-index: 1071;
}*/


    /*#nav-mega .search-container {
    position: relative;
    flex-shrink: 1;
    flex-grow: 0;
}

#nav-mega .search-input {
    border-radius: 50rem;
    background-color: white;
    border: none;
    padding: 0.5rem 1.5rem;
    font-size: 18px;
    letter-spacing: 1px;
    color: #0A1A56;
    height: clamp(40px, 5vh, 50px);
}

    #nav-mega .search-input:focus {
        outline: none;
        box-shadow: none;
    }

#nav-mega .search-icon {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    height: 18px;
    width: 18px;
    opacity: 0.7;
}

*/

    .cart-btn {
        display: flex;
        justify-content: center;
        align-items: center;
        background-color: #00aeef;
        color: #fff;
        border: none;
        border-radius: 2rem;
        padding: 0.5rem 1rem;
        font-weight: 500;
        width: 150px;
        text-decoration: none;
        font-size: 20px;
        transition: background-color 0.3s ease, transform 0.3s ease;
    }

        .cart-btn:hover {
            background-color: #0090c8;
            color: #fff;
            transform: scale(1.05);
        }

    @media (max-width: 991.98px) {
        .list-group-item {
            border: 0;
        }

        .navbar-collapse {
            max-height: 85vh;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }

        /* Fix navbar collapse positioning to appear below navbar */
        #nav-mega > .d-flex {
            flex-wrap: wrap;
            position: relative;
        }

        #navbarNav {
            flex-basis: 100% !important;
            width: 100% !important;
            max-width: 100% !important;
            order: 999;
            margin-top: 0;
            padding: 1rem 0;
        }

        /* Ensure collapse appears below, not inline */
        #nav-mega > .d-flex > #navbarNav.show {
            display: block !important;
        }

        .dropdown-menu[aria-labelledby="attractionsMenu"] {
            width: 100%;
            left: 0 !important;
            right: 0 !important;
        }

        /* Main dropdown container scroll */
        #mobileMega {
            max-height: 60vh;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }

        /* Inner long lists scroll (states/products) */
        .mob-scroll {
            max-height: 40vh;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }

        /* Pin the active LEVEL-2 header (state/experience type) */
        #mob-dest-acc > button.is-open,
        #mob-exp-acc > button.is-open {
            position: sticky;
            top: 0;
        }

        /* Only LEVEL-3 (products) scrolls, header above stays visible */
        .mob-products-scroll {
            max-height: 60vh;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }

        #nav-mega .search-flex {
            flex: 1 0 100%;
            max-width: 100%;
        }
    }

    /* Custom Hamburger Menu */
    #nav-mega .custom-hamburger {
        border: none;
        background: transparent;
        padding: 0.5rem;
        width: 56px;
        height: 40px;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        align-items: center;
        cursor: pointer;
        outline: none;
        box-shadow: none;
    }

        #nav-mega .custom-hamburger:focus {
            outline: none;
            box-shadow: none;
        }

        #nav-mega .custom-hamburger:hover {
            opacity: 0.8;
        }

        #nav-mega .custom-hamburger .hamburger-line {
            width: 28px;
            height: 3px;
            background-color: #fff;
            border-radius: 2px;
        }

.fm-mobile-search > .autoComplete_wrapper {
    display: block !important;
}

/* ============ Command Palette Search Trigger Button ============ */
.fm-search-trigger {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    height: 38px;
    padding: 0 14px;
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
    border-radius: 999px;
    cursor: pointer;
    transition: background .15s ease, border-color .15s ease, box-shadow .15s ease;
    font-family: inherit;
}

.fm-search-trigger:hover {
    background: #fff;
    border-color: #bbb;
    box-shadow: 0 0 0 4px rgba(0,0,0,.04);
}

.fm-search-trigger i {
    color: rgba(0,0,0,.55);
    font-size: 14px;
}

.fm-search-hint {
    font-size: 14px;
    color: rgba(0,0,0,.45);
    white-space: nowrap;
}

.fm-search-kbd {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    margin-left: 4px;
}

.fm-search-kbd span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    color: #666;
    font-family: inherit;
    line-height: 1;
}

/* Hide kbd hint on smaller screens */
@media (max-width: 1199px) {
    .fm-search-kbd {
        display: none;
    }
    .fm-search-trigger {
        padding: 0 12px;
    }
}

/* ============ Command Palette Modal ============ */
.cmd-palette {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
}

.cmd-palette.open {
    display: block;
}

.cmd-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity .2s ease;
}

.cmd-palette.open .cmd-backdrop {
    opacity: 1;
}

.cmd-container {
    position: absolute;
    left: 50%;
    top: 15vh;
    transform: translateX(-50%) translateY(-10px);
    width: 100%;
    max-width: 580px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 25px 60px rgba(0,0,0,.25), 0 0 0 1px rgba(0,0,0,.08);
    overflow: hidden;
    opacity: 0;
    transition: opacity .2s ease, transform .2s ease;
}

.cmd-palette.open .cmd-container {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Search Input */
.cmd-search-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
}

.cmd-search-icon {
    color: var(--brand-blue, #00aeef);
    font-size: 18px;
    flex-shrink: 0;
}

.cmd-search-input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 18px;
    font-weight: 500;
    color: #111;
    background: transparent;
    font-family: inherit;
}

.cmd-search-input::placeholder {
    color: rgba(0,0,0,.35);
    font-weight: 400;
}

.cmd-close-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    padding: 0;
    cursor: pointer;
    flex-shrink: 0;
}

.cmd-close-btn kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 8px;
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    color: #666;
    font-family: inherit;
    transition: background .15s ease;
}

.cmd-close-btn:hover kbd {
    background: #eee;
}

/* Results Container */
.cmd-results {
    max-height: 400px;
    overflow-y: auto;
    padding: 8px;
}

/* Initial State */
.cmd-initial-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
    text-align: center;
}

.cmd-initial-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f4ff 100%);
    border-radius: 50%;
    margin-bottom: 16px;
}

.cmd-initial-icon i {
    font-size: 24px;
    color: var(--brand-blue, #00aeef);
}

.cmd-initial-text {
    font-size: 14px;
    color: #888;
    font-weight: 500;
}

/* Empty State */
.cmd-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
    text-align: center;
}

.cmd-empty-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
    border-radius: 50%;
    margin-bottom: 16px;
}

.cmd-empty-icon i {
    font-size: 24px;
    color: #bbb;
}

.cmd-empty-text {
    font-size: 14px;
    color: #666;
    font-weight: 600;
    margin-bottom: 4px;
}

.cmd-empty-hint {
    font-size: 13px;
    color: #999;
}

/* Result Items */
.cmd-result-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 12px;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    transition: background .1s ease;
}

.cmd-result-item:hover,
.cmd-result-item.active {
    background: #f5f5f5;
}

.cmd-result-item.active {
    background: #eef9ff;
}

.cmd-result-thumb {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    overflow: hidden;
    background: #f0f0f0;
    flex-shrink: 0;
}

.cmd-result-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cmd-result-info {
    flex: 1;
    min-width: 0;
}

.cmd-result-name {
    font-size: 14px;
    font-weight: 600;
    color: #111;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    margin-bottom: 2px;
}

.cmd-result-name mark {
    background: #fff3cd;
    color: inherit;
    padding: 0 2px;
    border-radius: 2px;
}

.cmd-result-location {
    font-size: 12px;
    color: #888;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.cmd-result-arrow {
    color: #ccc;
    font-size: 12px;
    flex-shrink: 0;
    opacity: 0;
    transition: opacity .1s ease;
}

.cmd-result-item:hover .cmd-result-arrow,
.cmd-result-item.active .cmd-result-arrow {
    opacity: 1;
}

/* Footer with keyboard hints */
.cmd-footer {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 12px 20px;
    border-top: 1px solid #f0f0f0;
    background: #fafafa;
}

.cmd-hint {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #888;
}

.cmd-hint kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    color: #666;
    font-family: inherit;
}

.cmd-hint kbd i {
    font-size: 10px;
}

/* Loading State */
.cmd-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.cmd-loading-spinner {
    width: 24px;
    height: 24px;
    border: 2px solid #f0f0f0;
    border-top-color: var(--brand-blue, #00aeef);
    border-radius: 50%;
    animation: cmd-spin .6s linear infinite;
}

@keyframes cmd-spin {
    to { transform: rotate(360deg); }
}

/* Hide command palette on mobile/tablet */
@media (max-width: 991.98px) {
    .cmd-palette {
        display: none !important;
    }
}
