.cookie-consent {
    position: fixed;
    inset: 0;
    z-index: 90;
    pointer-events: none;
}

.cookie-consent__bar,
.cookie-consent__preferences,
.cookie-consent__backdrop {
    pointer-events: auto;
}

.cookie-consent__bar {
    position: absolute;
    right: 20px;
    bottom: 20px;
    left: 20px;
    width: min(1080px, calc(100% - 40px));
    margin: 0 auto;
    padding: 18px 20px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 18px 46px rgba(15, 23, 42, 0.16);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 20px;
    align-items: center;
}

.cookie-consent__content {
    min-width: 0;
}

.cookie-consent__title {
    margin: 0 0 5px;
    color: #111827;
    font-size: 18px;
    font-weight: 800;
    line-height: 1.2;
}

.cookie-consent__text {
    max-width: 680px;
    margin: 0;
    color: #475569;
    font-size: 14px;
    line-height: 1.5;
}

.cookie-consent__text a {
    color: #0b63ce;
    font-weight: 700;
}

.cookie-consent__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.cookie-consent__button {
    min-height: 44px;
    padding: 10px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    background: #ffffff;
    color: #111827;
    font: inherit;
    font-size: 14px;
    font-weight: 750;
    line-height: 1.2;
    text-align: center;
    cursor: pointer;
}

.cookie-consent__button--decision {
    border-color: #334155;
    background: #ffffff;
    color: #111827;
}

.cookie-consent__button--settings {
    border-color: #cbd5e1;
    background: #f8fafc;
}

.cookie-consent__button--save {
    border-color: #111827;
    background: #111827;
    color: #ffffff;
}

.cookie-consent__button:hover,
.cookie-consent__button:focus-visible,
.cookie-consent__close:hover,
.cookie-consent__close:focus-visible {
    border-color: #0b63ce;
    outline: 3px solid rgba(11, 99, 206, 0.2);
    outline-offset: 2px;
}

.cookie-consent__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.58);
}

.cookie-consent__preferences {
    position: absolute;
    top: 50%;
    left: 50%;
    width: min(820px, calc(100% - 32px));
    max-height: min(760px, calc(100vh - 32px));
    overflow-y: auto;
    padding: 24px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 24px 64px rgba(15, 23, 42, 0.24);
    transform: translate(-50%, -50%);
}

.cookie-consent__preferences:focus {
    outline: none;
}

.cookie-consent__preferences-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: start;
}

.cookie-consent__close {
    width: 42px;
    height: 42px;
    padding: 0;
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    background: #ffffff;
    color: #111827;
    font: inherit;
    font-size: 25px;
    line-height: 1;
    cursor: pointer;
}

.cookie-consent__eyebrow {
    margin: 0 0 7px;
    color: #64748b;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.cookie-consent__preferences-title {
    margin: 0 0 8px;
    color: #111827;
    font-size: 30px;
    line-height: 1.1;
}

.cookie-consent__preferences-text {
    max-width: 650px;
    margin: 0;
    color: #475569;
    font-size: 15px;
    line-height: 1.55;
}

.cookie-consent__options {
    display: grid;
    gap: 10px;
    margin-top: 20px;
}

.cookie-consent__option {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: start;
    padding: 15px;
    border: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: 16px;
    background: #f8fafc;
    color: #111827;
}

.cookie-consent__option input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #0b63ce;
}

.cookie-consent__option strong,
.cookie-consent__option small {
    display: block;
}

.cookie-consent__option small {
    margin-top: 4px;
    color: #64748b;
    line-height: 1.45;
}

.cookie-consent__option em {
    padding: 4px 8px;
    border-radius: 999px;
    background: #e2e8f0;
    color: #475569;
    font-size: 11px;
    font-style: normal;
    font-weight: 800;
    white-space: nowrap;
}

.cookie-consent__option:focus-within {
    border-color: #0b63ce;
    box-shadow: 0 0 0 3px rgba(11, 99, 206, 0.16);
}

.cookie-consent__actions--preferences {
    margin-top: 20px;
}

.cookie-preferences-open {
    overflow: hidden;
}

.site-footer__link-button {
    display: inline;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.site-footer__link-button:hover,
.site-footer__link-button:focus-visible {
    text-decoration: underline;
}

.cookie-consent[hidden],
.cookie-consent__bar[hidden],
.cookie-consent__preferences[hidden],
.cookie-consent__backdrop[hidden] {
    display: none;
}

@media (max-width: 900px) {
    .cookie-consent__bar {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .cookie-consent__actions--bar {
        justify-content: stretch;
    }

    .cookie-consent__actions--bar .cookie-consent__button {
        flex: 1 1 180px;
    }
}

@media (max-width: 620px) {
    .cookie-consent__bar {
        right: 10px;
        bottom: 10px;
        left: 10px;
        width: calc(100% - 20px);
        padding: 16px;
        border-radius: 18px;
    }

    .cookie-consent__preferences {
        top: auto;
        bottom: 0;
        left: 0;
        width: 100%;
        max-height: calc(100vh - 12px);
        padding: 18px 14px max(18px, env(safe-area-inset-bottom));
        border-right: 0;
        border-bottom: 0;
        border-left: 0;
        border-radius: 18px 18px 0 0;
        transform: none;
    }

    .cookie-consent__preferences-title {
        font-size: 26px;
    }

    .cookie-consent__option {
        grid-template-columns: 22px minmax(0, 1fr);
        padding: 13px;
    }

    .cookie-consent__option em {
        grid-column: 2;
        width: fit-content;
    }

    .cookie-consent__actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .cookie-consent__button {
        width: 100%;
        white-space: normal;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cookie-consent *,
    .cookie-consent *::before,
    .cookie-consent *::after {
        scroll-behavior: auto;
        transition: none;
    }
}
