.bau-cookie-banner[hidden],
.bau-cookie-modal[hidden] {
    display: none !important;
}

.bau-cookie-banner {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 10050;
    padding: 20px;
    color: #14253d;
    background: #fff;
    border-top: 1px solid #dbe3ee;
    box-shadow: 0 -10px 36px rgba(1, 38, 90, .16);
}

.bau-cookie-banner__content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: min(1240px, 100%);
    margin: 0 auto;
    gap: 28px;
}

.bau-cookie-banner__text {
    max-width: 690px;
}

.bau-cookie-banner h2,
.bau-cookie-modal h2,
.bau-cookie-modal h3 {
    color: #01265a;
    font-weight: 700;
}

.bau-cookie-banner h2 {
    margin: 0 0 8px;
    font-size: 22px;
}

.bau-cookie-banner p,
.bau-cookie-modal p {
    margin: 0;
    font-size: 15px;
    line-height: 1.6;
}

.bau-cookie-banner a {
    color: #2020bf;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.bau-cookie-banner__actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(150px, 1fr));
    gap: 10px;
}

.bau-cookie-button {
    min-height: 48px;
    padding: 10px 18px;
    color: #fff;
    background: #01265a;
    border: 2px solid #01265a;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 650;
    line-height: 1.25;
    text-align: center;
}

.bau-cookie-button:hover,
.bau-cookie-button:focus-visible {
    color: #fff;
    background: #4949ff;
    border-color: #4949ff;
}

.bau-cookie-button:focus-visible,
.bau-cookie-modal__close:focus-visible,
.bau-cookie-switch input:focus-visible + span {
    outline: 3px solid #f5b700;
    outline-offset: 3px;
}

.bau-cookie-modal {
    position: fixed;
    inset: 0;
    z-index: 10060;
    display: grid;
    place-items: center;
    padding: 20px;
}

.bau-cookie-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 18, 46, .72);
}

.bau-cookie-modal__dialog {
    position: relative;
    width: min(680px, 100%);
    max-height: calc(100vh - 40px);
    padding: clamp(24px, 4vw, 38px);
    overflow-y: auto;
    color: #26364a;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 24px 70px rgba(0, 18, 46, .28);
}

.bau-cookie-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 10px;
}

.bau-cookie-modal h2 {
    margin: 0;
    font-size: 27px;
}

.bau-cookie-modal__close {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    padding: 0;
    color: #01265a;
    background: #eef3fa;
    border: 0;
    border-radius: 50%;
    font-size: 30px;
    line-height: 1;
}

.bau-cookie-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 20px 0;
    border-bottom: 1px solid #dbe3ee;
}

.bau-cookie-option h3 {
    margin: 0 0 5px;
    font-size: 18px;
}

.bau-cookie-option p {
    color: #526176;
    font-size: 14px;
}

.bau-cookie-switch {
    position: relative;
    display: block;
    width: 52px;
    height: 30px;
    flex: 0 0 52px;
    margin: 0;
}

.bau-cookie-switch input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.bau-cookie-switch input + span {
    position: absolute;
    inset: 0;
    cursor: pointer;
    background: #a8b2c0;
    border-radius: 30px;
    transition: background .2s ease;
}

.bau-cookie-switch input + span::after {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 22px;
    height: 22px;
    content: '';
    background: #fff;
    border-radius: 50%;
    transition: transform .2s ease;
}

.bau-cookie-switch input:checked + span {
    background: #2446a8;
}

.bau-cookie-switch input:checked + span::after {
    transform: translateX(22px);
}

.bau-cookie-switch input:disabled + span {
    cursor: not-allowed;
    opacity: .72;
}

.bau-cookie-modal__actions {
    display: flex;
    justify-content: flex-end;
    padding-top: 24px;
}

body.bau-cookie-modal-open {
    overflow: hidden;
}

@media (max-width: 991.98px) {
    .bau-cookie-banner__content {
        align-items: stretch;
        flex-direction: column;
        gap: 18px;
    }
}

@media (max-width: 575.98px) {
    .bau-cookie-banner {
        max-height: 88vh;
        padding: 18px 16px;
        overflow-y: auto;
    }

    .bau-cookie-banner__actions {
        grid-template-columns: 1fr;
    }

    .bau-cookie-button {
        width: 100%;
    }

    .bau-cookie-modal {
        padding: 10px;
    }

    .bau-cookie-modal__dialog {
        max-height: calc(100vh - 20px);
        border-radius: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bau-cookie-switch input + span,
    .bau-cookie-switch input + span::after {
        transition: none;
    }
}
