/* Cookie consent banner */
.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    background: #fff;
    color: #333;
    border-top: 3px solid var(--primary-gold);
    box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.18);
    padding: 12px 0;
    max-height: 70vh;
    overflow-y: auto;
    font-size: 0.9rem;
    line-height: 1.45;
}

#cookie-banner-desc {
    margin-bottom: 0.6rem;
}

.cookie-banner[hidden] {
    display: none;
}

.cookie-banner-title {
    color: var(--dark-red);
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}

.cookie-banner-title:focus {
    outline: none;
}

.cookie-banner a {
    color: var(--dark-red);
    text-decoration: underline;
}

.cookie-settings fieldset {
    border: 0;
    margin: 0 0 0.75rem;
    padding: 0;
}

.cookie-option {
    background: var(--light-bg);
    border-left: 4px solid var(--primary-gold);
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.4rem;
}

.cookie-option input {
    width: 1.1rem;
    height: 1.1rem;
    margin-right: 0.5rem;
    vertical-align: middle;
    accent-color: var(--dark-red);
}

.cookie-option label {
    font-weight: 700;
    vertical-align: middle;
}

.cookie-option p {
    margin: 0.15rem 0 0 1.6rem;
    font-size: 0.85rem;
}

.cookie-always {
    font-weight: 400;
    color: #555;
}

.cookie-actions,
.consent-embed-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* Accept and reject use the same style so neither choice is visually favoured */
.cookie-btn {
    background: var(--dark-red);
    color: #fff;
    border: 2px solid var(--dark-red);
    border-radius: 6px;
    padding: 0.4rem 1rem;
    font-size: 0.875rem;
    font-weight: 700;
    line-height: 1.3;
    white-space: nowrap;
    cursor: pointer;
}

.cookie-btn:hover {
    background: var(--primary-red);
    border-color: var(--primary-red);
}

.cookie-btn-outline {
    background: #fff;
    color: var(--dark-red);
}

.cookie-btn-outline:hover {
    color: #fff;
}

.cookie-btn:focus-visible,
.footer-link-button:focus-visible {
    outline: 3px solid var(--primary-gold);
    outline-offset: 2px;
}

/* Click-to-load placeholder for third-party embeds */
.consent-embed {
    width: 100%;
    height: 100%;
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--light-bg);
    color: #333;
}

.map-container .consent-embed {
    height: 450px;
}

.consent-embed-placeholder {
    max-width: 560px;
    padding: 1.5rem;
    text-align: center;
}

.consent-embed-actions {
    justify-content: center;
}

/* Wide screens: text on the left, buttons on the right, options in a row */
@media (min-width: 992px) {
    .cookie-banner-inner {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        column-gap: 2rem;
        align-items: center;
    }

    .cookie-banner-title,
    #cookie-banner-desc {
        grid-column: 1;
    }

    #cookie-banner-desc {
        margin-bottom: 0;
    }

    .cookie-actions {
        grid-column: 2;
        grid-row: 1 / span 2;
        justify-content: flex-end;
        flex-wrap: nowrap;
    }

    .cookie-settings {
        grid-column: 1 / -1;
        grid-row: 3;
        margin-top: 0.75rem;
    }

    .cookie-settings fieldset {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 0.5rem;
        margin-bottom: 0;
    }

    .cookie-option {
        margin-bottom: 0;
    }
}

/* Phones: smaller text, buttons share the row instead of stacking */
@media (max-width: 576px) {
    .cookie-banner {
        padding: 10px 0;
        font-size: 0.82rem;
    }

    .cookie-banner-title {
        font-size: 0.95rem;
    }

    .cookie-btn {
        flex: 1 1 auto;
        padding: 0.4rem 0.6rem;
        font-size: 0.8rem;
    }
}
