/* Cookie consent banner — dark theme, bottom-right.
   Self-contained, loaded directly (not part of the webpack bundle). */

.cookie-consent {
    position: fixed;
    right: 1.25rem;
    bottom: 1.25rem;
    z-index: 1080;
    width: 420px;
    max-width: calc(100vw - 2.5rem);
    font-family: "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    color: #fff;
}

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

.cookie-consent__card {
    background: #0d0d12;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    padding: 20px 20px 18px;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.55);
    max-height: calc(100vh - 2.5rem);
    overflow-y: auto;
}

.cookie-consent__title {
    font-family: "Montserrat", sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 10px;
}

.cookie-consent__text {
    font-size: 13px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.78);
    margin: 0 0 16px;
}

.cookie-consent__text b,
.cookie-consent__text strong {
    color: #fff;
    font-weight: 600;
}

/* Actions ------------------------------------------------------------- */

.cookie-consent__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.cookie-consent__btn {
    appearance: none;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 10px 18px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
    white-space: nowrap;
}

.cookie-consent__btn:focus-visible {
    outline: 2px solid #3861FB;
    outline-offset: 2px;
}

.cookie-consent__btn--accept {
    background: #3861FB;
    color: #fff;
    flex: 1 1 auto;
}

.cookie-consent__btn--accept:hover {
    background: #2b4fe0;
}

.cookie-consent__btn--decline {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.cookie-consent__btn--decline:hover {
    border-color: rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.04);
}

.cookie-consent__btn--ghost {
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    padding: 10px 8px;
    text-decoration: underline;
}

.cookie-consent__btn--ghost:hover {
    color: #fff;
}

/* Views --------------------------------------------------------------- */

.cookie-consent__prefs {
    display: none;
}

.cookie-consent--prefs .cookie-consent__banner {
    display: none;
}

.cookie-consent--prefs .cookie-consent__prefs {
    display: block;
}

.cookie-consent__prefs-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.cookie-consent__close {
    appearance: none;
    background: transparent;
    border: 0;
    color: rgba(255, 255, 255, 0.6);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
    flex: 0 0 auto;
}

.cookie-consent__close:hover {
    color: #fff;
}

/* Category rows ------------------------------------------------------- */

.cookie-consent__cat {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    padding: 12px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.cookie-consent__cat-name {
    font-size: 13px;
    font-weight: 600;
    margin: 0 0 3px;
}

.cookie-consent__cat-desc {
    font-size: 12px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.6);
    margin: 0;
}

/* Toggle switch ------------------------------------------------------- */

.cookie-consent__switch {
    position: relative;
    flex: 0 0 auto;
    width: 42px;
    height: 24px;
    margin-top: 2px;
}

.cookie-consent__switch input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    cursor: pointer;
}

.cookie-consent__slider {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    transition: background-color 0.2s ease;
    pointer-events: none;
}

.cookie-consent__slider::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    transition: transform 0.2s ease;
}

.cookie-consent__switch input:checked + .cookie-consent__slider {
    background: #3861FB;
}

.cookie-consent__switch input:checked + .cookie-consent__slider::before {
    transform: translateX(18px);
}

.cookie-consent__switch input:disabled {
    cursor: not-allowed;
}

.cookie-consent__switch input:disabled + .cookie-consent__slider {
    background: #3861FB;
    opacity: 0.5;
}

.cookie-consent__switch input:focus-visible + .cookie-consent__slider {
    outline: 2px solid #3861FB;
    outline-offset: 2px;
}

.cookie-consent__prefs-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.cookie-consent__prefs-actions .cookie-consent__btn {
    flex: 1 1 auto;
}

/* Footer re-open link ------------------------------------------------- */

.cookie-settings-link {
    background: none;
    border: 0;
    padding: 0;
    color: inherit;
    font: inherit;
    cursor: pointer;
    text-decoration: none;
}

/* Mobile: full-width bottom sheet ------------------------------------- */

@media (max-width: 600px) {
    .cookie-consent {
        right: 0;
        left: 0;
        bottom: 0;
        width: 100%;
        max-width: 100%;
    }

    .cookie-consent__card {
        border-radius: 16px 16px 0 0;
        border-left: 0;
        border-right: 0;
        border-bottom: 0;
    }

    .cookie-consent__btn {
        flex: 1 1 100%;
        text-align: center;
    }
}
