.content-body .map-container {
    padding: 0;
    border-radius: var(--border-radius-lg);
    background-color: white;
    box-shadow: var(--container-box-shadow);
    /* border-bottom: 1px solid var(--color-gray-light); */

    #map {
        width: 100%;
        max-width: 100%;
        height: 300px;
        max-height: 50vh;
        /* Match map main color */
        background-color: #f8f3e3;
        border: 2px solid white;
        border-radius: var(--border-radius-lg);
    }

    #map-spinner {
        width: 50px;
        height: 30px;
        position: absolute;
        display: flex;
        bottom: 0;
        right: 0;
        left: 0;
        top: -30px;
        margin: auto;
        pointer-events: none;
        opacity: 1;
        transition: opacity 0.1s ease-in, transform 0.1s ease-in;
        transition-delay: 0.3s;

        svg {
            width: 100%;
            height: auto;
            fill: var(--color-black);
        }

        &.done {
            opacity: 0;
            transform: scale(0.9);
        }

        &::before {
            content: 'Loading';
            width: 100%;
            position: absolute;
            top: -22px;
            line-height: 1;
            padding: 3px;
            text-align: center;
            background: #ffffff;
            border-radius: 14px;
            font-size: 10px;
            font-family: var(--font-family-bold);
            font-weight: var(--font-weight-bold);
        }
    }

    nav.event-day-nav {
        ul {
            list-style: none;
            padding: 2px 4px 4px;
            margin: 0;
            display: flex;
            justify-content: space-evenly;
            text-align: center;

            /*
            Fix for an iOS z-index scroll bug that makes 
            the header logo overhang go behind the map,
            despite valid z-indexing.
            */
            /* -webkit-transform: translate3d(0,0,0); */

            
            small {
                display: block;
                top: -6px;
                margin-bottom: -4px;
                position: relative;
            }
            
            li {
                max-height: 56px;
                position: relative;
                flex: 1 1 0px;
                aspect-ratio: 1 / 1;
                border-radius: calc(var(--border-radius-lg) - 2px);

                button {
                    height: 100%;
                    display: block;
                    margin: 0 auto;
                    padding: 0 7px;
                    font-family: var(--font-family-bold);
                    font-weight: var(--font-weight-bold);
                    letter-spacing: -0.3px;
                }

                &.active button {
                    color: white;
                    text-shadow: var(--text-shadow);

                    .day-event-count {
                        background-color: var(--color-black);
                    }
                }
            }

            .day-event-count {
                width: 15px;
                height: 15px;
                margin: auto;
                position: absolute;
                top: -12px;
                right: 0;
                left: 0;
                display: flex;
                justify-content: center;
                align-items: center;
                font-family: var(--font-family-bold);
                font-weight: var(--font-weight-bold);
                letter-spacing: -0.3px;
                font-size: 10px;
                color: #fff;
                background-color: var(--color-red);
                box-shadow: 0 0 0 2px white;
                border-radius: 3px;
                cursor: pointer;
            }
        }
    }
}

.marker-icon {
    width: 24px;
    height: 24px;
    font-family: var(--font-family-bold);
    font-weight: var(--font-weight-bold);
    letter-spacing: -0.3px;
    font-size: 14px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #FFF;
    cursor: pointer;

    &::after {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        width: 24px;
        height: 24px;
        background-color: var(--color-red);
        box-shadow: 0 0 0 2px #FFF, inset 0 0 0 2px var(--color-red-dark), inset 0 3px 0 0 rgba(255,255,255,0.26);
        border-radius: 100% 100% 100% 30%;
        transform: rotate(-45deg);
        z-index: -1;
    }
}

#map .marker-icon {
    animation-name: show-map-marker;
    animation-duration: 200ms;
    animation-timing-function: ease-in-out;
    animation-fill-mode: both;
}

#map .marker-icon:nth-child(1) {
    animation-delay: calc((1 * 180ms));
}

#map .marker-icon:nth-child(2) {
    animation-delay: calc((2 * 180ms));
}

#map .marker-icon:nth-child(3) {
    animation-delay: calc((3 * 180ms));
}

#map .marker-icon:nth-child(4) {
    animation-delay: calc((4 * 180ms));
}

#map .marker-icon:nth-child(5) {
    animation-delay: calc((5 * 180ms));
}

#map .marker-icon:nth-child(6) {
    animation-delay: calc((6 * 180ms));
}

#map .marker-icon:nth-child(7) {
    animation-delay: calc((7 * 180ms));
}

#map .marker-icon:nth-child(8) {
    animation-delay: calc((8 * 180ms));
}

#map .marker-icon:nth-child(9) {
    animation-delay: calc((9 * 180ms));
}

#map .marker-icon:nth-child(10) {
    animation-delay: calc((10 * 180ms));
}

@keyframes show-map-marker {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

.alert-list {
    background: var(--color-brown-dark);
    padding: 5px 10px 6px 8px;
    border-radius: 8px;
    margin-top: var(--border-radius-md);
    line-height: 1.2;

    & > div {
        display: flex;
        gap: 5px;
        align-items: center;
    
        svg {
            width: 12px;
            height: 12px;
            margin-top: 1px;
            flex: 0 0 auto;
            vertical-align: middle;
            fill: var(--color-orange);
        }
    }
}

.maplibregl-map {
    font-family: var(--font-family-normal);
}

.maplibregl-popup {
    animation-name: popup-fade-animation;
    animation-duration: 90ms;
    animation-delay: 60ms;
    animation-timing-function: ease-out;
    animation-fill-mode: both;
}

/* Attribution html code added manually */
.map-custom-attribution {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    padding-right: 4px;
    bottom: 9px;
    right: 0;
    position: absolute;
    z-index: 2;
    text-align: right;

    a {
        display: block;
        line-height: 1;
        margin-bottom: 1px;
        color: var(--color-black);
    }

    .map-custom-logo {
        margin-bottom: 2px;

        a {
            width: 70px !important;
            height: 21px !important;
            background-size: 70px 21px !important;
            background-repeat: no-repeat;

            cursor: pointer;
            margin: 0px 0px -4px -4px;
            overflow: hidden;
            background-image: url("https://api.maptiler.com/resources/logo.svg");
        }
    }

    .map-custom-attrib {
        background-color: transparent;
        font-size: 9px;
        opacity: 0.9;
        text-align: right;
    }
}

@keyframes popup-fade-animation {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

.map-event-popup {
    /* Hide triangle tip of the popup */
    .maplibregl-popup-tip {
        display: none;
    }

    .maplibregl-popup-content {
        padding: 0;
        border-radius: 8px;
        box-shadow: 0 2px 20px rgba(0,0,0,0.15);
        overflow: hidden;
        font-weight: var(--font-weight-normal);
        font-family: var(--font-family-normal);

        & > div:last-child {
            margin-bottom: 10px;
        }
    }

    .popup-tags {
        padding: 9px 12px 0;
        opacity: 56%;
        font-size: 12px;
        line-height: 15px;
        font-family: var(--font-family-normal);
        font-weight: var(--font-weight-normal);
    }

    .popup-title {
        padding: 0 12px 1px;
        line-height: 1.1;
        font-size: 16px;
        font-family: var(--font-family-bold);
        font-weight: var(--font-weight-bold);
        letter-spacing: -0.3px;
    }

    .popup-time,
    .popup-location,
    .popup-link {
        padding: 0 12px;
        margin-top: 2px;
        line-height: 1.25;
        font-size: 14px;
        display: flex;
        align-items: center;
        gap: 3px;

        .icon-inline {
            top: 0;
            min-width: 1em;
        }
    }

    .popup-location,
    .popup-link {
        color: var(--color-red);
        
        .ellipsis {
            text-overflow: ellipsis;
            overflow: hidden;
            white-space: nowrap;
        }
    }

    .popup-location a:focus-visible,
    .popup-link a:focus-visible {
        outline-style: none;
    }
}

article.event-list-container {
    display: flex;
    flex-direction: column;
    padding: 5px 14px 14px;
    
    /* @media (max-width: 461px) {
        padding: 4px 6px 10px;
    } */

    .event-list-group {
        display: none;

        &.active {
            display: block;
        }
    }

    .event-list {
        li {
            padding: 10px 0 14px;
            display: flex;
            gap: 12px;

            animation-name: list-item-animation;
            animation-duration: 320ms;
            animation-delay: calc(10ms + ((var(--animation-order) + 1) * 200ms));
            animation-timing-function: ease-out;
            animation-fill-mode: both;

            &.is-on-map {
                &::after {
                    content: "";
                    background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGNsYXNzPSJsdWNpZGUgbHVjaWRlLWNoZXZyb24tcmlnaHQtaWNvbiBsdWNpZGUtY2hldnJvbi1yaWdodCI+PHBhdGggZD0ibTkgMTggNi02LTYtNiIvPjwvc3ZnPg==');
                    width: 18px;
                    height: 18px;
                    opacity: 0.3;
                    background-repeat: no-repeat;
                    background-size: contain;
                    position: absolute;
                    right: 0;
                    top: 0;
                    bottom: 0;
                    margin: auto;
                    transition: opacity 200ms ease-in-out;
                }

                .event-title {
                    margin-bottom: 2px;
                    text-underline-offset: 3px;
                    text-decoration-line: underline;
                    text-decoration-style: solid;
                    text-decoration-color: var(--color-gray);
                    text-decoration-thickness: 2px;
                    transition: text-decoration-color 200ms ease-in-out;
                }
            }

            &.is-on-map:hover {
                &::after {
                    opacity: 1;
                }

                .event-title {
                    text-decoration-color: var(--color-black);
                }
            }

            &.event-type-holiday {
                .event-meta {
                    display: none;
                }
            }

            & > div:first-child {
                flex-shrink: 0;
            }

            & > div:last-child {
                flex-grow: 1;
            }

            .list-icon {
                width: 24px;
                height: 24px;
                margin-top: 3px;
                font-family: var(--font-family-bold);
                font-weight: var(--font-weight-bold);
                letter-spacing: -0.3px;
                font-size: 14px;
                display: flex;
                justify-content: center;
                align-items: center;
                color: #FFF;
                cursor: pointer;
                position: relative;
                border-radius: 8px;

                &::after {
                    content: "";
                    position: absolute;
                    top: 0;
                    left: 0;
                    width: 24px;
                    height: 24px;
                    background-color: var(--color-red);
                    box-shadow: inset 0 0 0 2px var(--color-red-dark), inset 0 3px 0 0 rgba(255,255,255,0.26), -1.5px 1.5px 0 0 rgba(0,0,0,0.08);
                    border-radius: 100% 100% 100% 30%;
                    transform: rotate(-45deg);
                    z-index: -1;
                }

                &.list-icon--holiday,
                &.list-icon--sun {
                    cursor: auto;

                    &::after {
                        display: none;
                    }

                    svg {
                        width: 16px;
                        height: 16px;
                        fill: #ffffff;
                    }
                }

                &.list-icon--sun {
                    background-color: var(--color-blue);
                    box-shadow: inset 0 0 0 2px var(--color-blue-dark), inset 0 3px 0 0 rgba(255,255,255,0.26), 0 2px 0 0 rgba(0,0,0,0.08);
                }

                &.list-icon--holiday {
                    background-color: var(--color-teal);
                    box-shadow: inset 0 0 0 2px var(--color-teal-dark), inset 0 3px 0 0 rgba(255,255,255,0.26), 0 2px 0 0 rgba(0,0,0,0.08);
                }
            }
            
            .event-subtitle {
                width: 100%;
                position: relative;
                opacity: var(--text-muted-opacity);
                font-size: 12px;
                line-height: 15px;
                display: flex;
                gap: 10px;
                justify-content: space-between;

                .event-weather {
                    white-space: nowrap;

                    .icon-inline {
                        margin-top: -1.5px;
                    }
                }
            }

            .event-title {
                padding-right: 22px;
                font-size: 18px;
                font-family: var(--font-family-bold);
                font-weight: var(--font-weight-bold);
                letter-spacing: -0.3px;
                line-height: 21px;
            }

            .event-meta {
                display: flex;
                flex-direction: row;
                align-items: center;
                line-height: 1;
                gap: 4px;
                padding-top: 3px;

                .icon-inline {
                    width: 13px;
                    height: 13px;
                    top: 0;
                }
            }
        }
    
        &:not(.event-list-empty) li {
            cursor: pointer;
        }
    }
}

@keyframes list-item-animation {
    0% {
        opacity: 0;
        transform: translateY(-4px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.event-page-footer-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: space-between;
    margin: 50px 0;
    text-align: center;

    @media (min-width: 461px) {
        justify-content: space-around;
    }

    & > div {
        /* Equal sized elements */
        flex: 1 1 0px;
    }

    svg {
        display: block;
        margin: 0 auto 6px;
        width: 40px;
        height: 40px;
    }

    span {
        line-height: 1.2;
        display: block;
    }
}

.event-disclaimer {
    margin: 50px 0;
    text-align: center;
    color: var(--color-brown);
}