
/* Shared AIV site header */
.aiv-site-header {
    position: sticky;
    top: 0;
    z-index: 10000;
    width: 100%;
    background: rgba(255, 255, 255, 0.97);
    border-bottom: 1px solid #ece9e4;
    box-shadow: 0 5px 24px rgba(23, 36, 51, 0.06);
    backdrop-filter: blur(12px);
}

.admin-bar .aiv-site-header {
    top: 32px;
}

.aiv-header-inner {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: min(100% - 48px, 1500px);
    min-height: 92px;
    margin: 0 auto;
}

.aiv-brand {
    display: inline-flex;
    align-items: center;
    flex: 0 0 auto;
    text-decoration: none;
}

.aiv-brand img {
    display: block;
    width: 184px;
    height: 72px;
    object-fit: contain;
}

.aiv-primary-nav > ul {
    display: flex;
    align-items: center;
    gap: clamp(34px, 4vw, 70px);
    margin: 0;
    padding: 0;
    list-style: none;
}

.aiv-primary-nav li {
    position: relative;
    margin: 0;
}

.aiv-primary-nav a,
.aiv-destinations-toggle {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 32px 0;
    border: 0;
    background: transparent;
    color: #172433;
    font-family: "Jost", Arial, sans-serif;
    font-size: 17px;
    font-weight: 600;
    line-height: 1;
    text-transform: none;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s ease;
}

.aiv-primary-nav a:hover,
.aiv-primary-nav a:focus,
.aiv-destinations-toggle:hover,
.aiv-destinations-toggle:focus {
    color: #a81f2d;
}

.aiv-destinations-toggle svg {
    width: 11px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
    transition: transform 0.2s ease;
}

.aiv-destinations-item.is-open .aiv-destinations-toggle svg {
    transform: rotate(180deg);
}

.aiv-destinations-menu {
    position: absolute;
    top: calc(100% - 13px);
    right: -100px;
    width: min(940px, calc(100vw - 40px));
    max-height: min(620px, calc(100vh - 130px));
    padding: 18px;
    overflow-y: auto;
    overscroll-behavior: contain;
    border: 1px solid #ece9e4;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 20px 55px rgba(23, 36, 51, 0.16);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.aiv-destinations-item:hover .aiv-destinations-menu,
.aiv-destinations-item:focus-within .aiv-destinations-menu,
.aiv-destinations-item.is-open .aiv-destinations-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.aiv-destination-states {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 26px 30px;
}

.aiv-destination-state {
    min-width: 0;
}

.aiv-destination-state h3 {
    margin: 0 0 10px;
    padding: 0 5px 8px;
    border-bottom: 1px solid #eadfd9;
    color: #a81f2d;
    font-family: "Jost", Arial, sans-serif;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.02em;
    line-height: 1.25;
    text-transform: none;
}

.aiv-destination-cities {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.aiv-destination-cities a {
    display: block;
    padding: 7px 5px;
    border-radius: 7px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.25;
}

.aiv-destination-cities a:hover,
.aiv-destination-cities a:focus {
    padding-left: 9px;
    background: #faf5f3;
}

.aiv-menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 10px;
    border: 0;
    border-radius: 50%;
    background: #172433;
    cursor: pointer;
}

.aiv-menu-toggle > span:not(.screen-reader-text) {
    display: block;
    width: 100%;
    height: 2px;
    margin: 5px 0;
    border-radius: 2px;
    background: #fff;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (max-width: 782px) {
    .admin-bar .aiv-site-header {
        top: 46px;
    }
}

@media (max-width: 900px) {
    .aiv-header-inner {
        width: min(100% - 30px, 1500px);
        min-height: 76px;
    }

    .aiv-brand img {
        width: 145px;
        height: 58px;
    }

    .aiv-menu-toggle {
        display: block;
    }

    .aiv-primary-nav {
        position: absolute;
        top: calc(100% + 1px);
        right: 0;
        left: 0;
        padding: 10px 16px 18px;
        border: 1px solid #ece9e4;
        border-top: 0;
        border-radius: 0 0 16px 16px;
        background: #fff;
        box-shadow: 0 20px 35px rgba(23, 36, 51, 0.12);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-8px);
        transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    }

    .aiv-primary-nav.is-open {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .aiv-primary-nav > ul {
        display: block;
    }

    .aiv-primary-nav a,
    .aiv-destinations-toggle {
        width: 100%;
        justify-content: space-between;
        padding: 15px 8px;
        font-size: 16px;
    }

    .aiv-destinations-menu {
        position: static;
        width: 100%;
        max-height: 0;
        padding: 0;
        overflow: hidden;
        border: 0;
        border-radius: 10px;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        transition: max-height 0.25s ease, padding 0.25s ease;
    }

    .aiv-destinations-item.is-open .aiv-destinations-menu {
        max-height: min(560px, calc(100vh - 190px));
        padding: 7px;
        background: #faf8f5;
        overflow-y: auto;
    }

    .aiv-destination-states {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 24px 18px;
    }

    .aiv-destination-cities a {
        padding: 8px 5px;
    }
}

@media (max-width: 430px) {
    .aiv-destination-states {
        grid-template-columns: 1fr;
    }
}
