.cookie-consent,
.cookie-consent * {
    box-sizing: border-box;
}

.cookie-consent {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 15px;
    line-height: 1.45;
    color: #171717;
}

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

.cookie-consent__banner {
    position: fixed;
    z-index: 1100;
    left: 50%;
    bottom: 18px;
    width: min(760px, calc(100% - 32px));
    padding: 16px;
    border-radius: 12px;
    background: #fff;
    color: #171717;
    box-shadow: 0 10px 35px rgba(0, 0, 0, .28);
    transform: translateX(-50%);
}

.cookie-consent__banner-heading,
.cookie-consent__dialog-heading,
.cookie-consent__option h3 {
    color: #171717;
    font-family: inherit;
    font-weight: 700;
}

.cookie-consent__banner-heading {
    margin: 0 0 4px;
    font-size: 20px;
    line-height: 1.25;
}

.cookie-consent__banner-text {
    margin: 0;
}

.cookie-consent__banner-text > :first-child {
    margin-top: 0;
}

.cookie-consent__banner-text > :last-child {
    margin-bottom: 0;
}

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

.cookie-consent__button {
    min-height: 38px;
    padding: 7px 12px;
    border: 1px solid #b8b8b8;
    border-radius: 8px;
    background: #fff;
    color: #171717;
    cursor: pointer;
    font: inherit;
    line-height: 1.2;
}

.cookie-consent__button:hover {
    background: #f4f4f4;
}

.cookie-consent__button--strong {
    font-weight: 700;
}

.cookie-consent__button:focus-visible,
.cookie-consent__banner-links a:focus-visible,
.cookie-consent__banner-links button:focus-visible,
.cookie-consent__dialog-policy:focus-visible,
.cookie-consent__toggle input:focus-visible + .cookie-consent__toggle-track {
    outline: 3px solid #e86513;
    outline-offset: 2px;
}

.cookie-consent__banner-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin: 13px 0 0;
}

.cookie-consent__banner-links a,
.cookie-consent__banner-links button,
.cookie-consent__dialog-policy {
    color: #e86513;
    text-decoration: underline;
}

.cookie-consent__banner-links button {
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    font: inherit;
}

.cookie-consent__backdrop {
    position: fixed;
    z-index: 1200;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 24px;
    background: rgba(0, 0, 0, .68);
}

.cookie-consent__dialog {
    width: min(860px, 100%);
    max-height: calc(100vh - 48px);
    max-height: calc(100dvh - 48px);
    overflow-y: auto;
    padding: 18px;
    border-radius: 12px;
    background: #fff;
    color: #171717;
    box-shadow: 0 15px 50px rgba(0, 0, 0, .35);
}

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

.cookie-consent__dialog-heading {
    margin: 0 0 6px;
    font-size: 22px;
    line-height: 1.2;
}

.cookie-consent__dialog-introduction {
    margin: 0;
    font-size: 17px;
}

.cookie-consent__close {
    font-size: 16px;
}

.cookie-consent__option {
    margin-top: 15px;
    padding-top: 13px;
    border-top: 1px solid #dedede;
}

.cookie-consent__option-heading {
    display: flex;
    gap: 20px;
    align-items: center;
    justify-content: space-between;
}

.cookie-consent__option h3 {
    margin: 0;
    font-size: 16px;
    line-height: 1.3;
}

.cookie-consent__option p {
    max-width: 760px;
    margin: 13px 0 0;
}

.cookie-consent__always-active {
    color: #34823e;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

.cookie-consent__toggle {
    position: relative;
    display: inline-flex;
    flex: 0 0 auto;
    cursor: pointer;
}

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

.cookie-consent__toggle-track {
    position: relative;
    display: block;
    width: 54px;
    height: 30px;
    border-radius: 999px;
    background: #cfcfd1;
    transition: background-color .2s ease;
}

.cookie-consent__toggle-track::after {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .3);
    content: "";
    transition: transform .2s ease;
}

.cookie-consent__toggle input:checked + .cookie-consent__toggle-track {
    background: #34823e;
}

.cookie-consent__toggle input:checked + .cookie-consent__toggle-track::after {
    transform: translateX(24px);
}

.cookie-consent__dialog-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    margin-top: 14px;
    padding-top: 15px;
    border-top: 1px solid #dedede;
}

.cookie-consent__dialog-policy {
    margin-left: auto;
}

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

@media (max-width: 640px) {
    .cookie-consent {
        font-size: 15px;
    }

    .cookie-consent__banner {
        bottom: 12px;
        width: calc(100% - 24px);
        max-height: calc(100vh - 24px);
        max-height: calc(100dvh - 24px);
        overflow-y: auto;
    }

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

    .cookie-consent__backdrop {
        align-items: center;
        padding: 16px;
    }

    .cookie-consent__dialog {
        max-height: calc(100vh - 32px);
        max-height: calc(100dvh - 32px);
        padding: 18px;
    }

    .cookie-consent__dialog-header {
        gap: 12px;
    }

    .cookie-consent__dialog-heading {
        font-size: 21px;
    }

    .cookie-consent__dialog-introduction {
        font-size: 17px;
        line-height: 1.55;
    }

    .cookie-consent__option p {
        line-height: 1.55;
    }

    .cookie-consent__dialog-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .cookie-consent__save,
    .cookie-consent__dialog-policy {
        grid-column: 1 / -1;
    }

    .cookie-consent__dialog-policy {
        justify-self: start;
        margin: 14px 0 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cookie-consent__toggle-track,
    .cookie-consent__toggle-track::after {
        transition: none;
    }
}
