/* Cookie consent banner + preferences modal — matches custom.css's button/
   color conventions (cta-blue #192440, cta-green #0090e7, 22px pill buttons). */

#cookie-consent-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: -100%;
    z-index: 1080;
    background: #192440;
    color: #ffffff;
    padding: 20px;
    box-shadow: 0 -0.5rem 1.5rem rgba(0, 0, 0, 0.25);
    transition: bottom 0.4s ease-in-out;
}

#cookie-consent-banner.show {
    bottom: 0;
}

#cookie-consent-banner .cc-text {
    font-size: 14px;
    margin: 0;
}

#cookie-consent-banner .cc-text a {
    color: #ffffff;
    text-decoration: underline;
}

#cookie-consent-banner .cc-actions .btn {
    white-space: nowrap;
}

#cookie-consent-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1090;
    background: rgba(25, 36, 64, 0.6);
    padding: 20px;
    overflow-y: auto;
}

#cookie-consent-modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

#cookie-consent-modal .cc-modal-dialog {
    background: #ffffff;
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1.5rem rgba(0, 144, 231, 0.2);
    max-width: 560px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
}

#cookie-consent-modal .cc-modal-header,
#cookie-consent-modal .cc-modal-footer {
    padding: 20px 25px;
}

#cookie-consent-modal .cc-modal-header {
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

#cookie-consent-modal .cc-modal-header h5 {
    font-weight: 700;
    margin: 0;
}

#cookie-consent-modal .cc-modal-close {
    background: none;
    border: none;
    font-size: 22px;
    line-height: 1;
    color: #192440;
}

#cookie-consent-modal .cc-modal-body {
    padding: 20px 25px;
}

#cookie-consent-modal .cc-category {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid #f0f0f0;
}

#cookie-consent-modal .cc-category:last-child {
    border-bottom: none;
}

#cookie-consent-modal .cc-category h6 {
    font-weight: 700;
    margin: 0 0 5px;
}

#cookie-consent-modal .cc-category p {
    font-size: 13px;
    color: #666;
    margin: 0;
}

#cookie-consent-modal .cc-modal-footer {
    border-top: 1px solid #eee;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

/* Pure-CSS toggle switch, no JS/Bootstrap component dependency */
.cc-toggle {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.cc-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cc-toggle .cc-toggle-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: #ccc;
    border-radius: 24px;
    transition: 0.2s;
}

.cc-toggle .cc-toggle-slider::before {
    content: "";
    position: absolute;
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: #ffffff;
    border-radius: 50%;
    transition: 0.2s;
}

.cc-toggle input:checked + .cc-toggle-slider {
    background-color: #0090e7;
}

.cc-toggle input:checked + .cc-toggle-slider::before {
    transform: translateX(20px);
}

.cc-toggle input:disabled + .cc-toggle-slider {
    background-color: #0090e7;
    opacity: 0.5;
    cursor: not-allowed;
}

@media (max-width: 767px) {
    #cookie-consent-banner .row {
        text-align: center;
    }

    #cookie-consent-banner .cc-actions {
        margin-top: 15px;
        justify-content: center !important;
    }
}
