/* Баннер cookies и окно настроек */

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

.gma-cc-banner,
.gma-cc-modal {
    font-family: inherit;
    font-size: 14px;
    line-height: 1.45;
    color: #333333;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

.gma-cc-banner *,
.gma-cc-modal * {
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

.gma-cc-banner p,
.gma-cc-modal p {
    margin: 0 0 8px;
    font-size: 14px;
    line-height: 1.45;
    color: #333333;
}

.gma-cc-banner a,
.gma-cc-modal a {
    color: #333333;
    text-decoration: underline;
}

.gma-cc-title {
    margin: 0 0 10px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    color: #1f1f1f;
}

/* Баннер */

.gma-cc-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2147483000;
    max-height: 100vh;
    overflow-y: auto;
    background: #ffffff;
    border-top: 1px solid #e3e3e3;
    -webkit-box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.12);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.12);
}

.gma-cc-banner__inner {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: end;
    -ms-flex-align: end;
    align-items: flex-end;
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 16px;
}

.gma-cc-banner__text {
    -webkit-box-flex: 1;
    -ms-flex: 1 1 auto;
    flex: 1 1 auto;
    min-width: 0;
}

.gma-cc-banner__text p:last-child {
    margin-bottom: 0;
}

.gma-cc-banner__buttons {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-negative: 0;
    flex-shrink: 0;
    gap: 10px;
}

/* Кнопки */

.gma-cc-btn {
    display: inline-block;
    min-width: 130px;
    padding: 11px 20px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    color: #333333;
    background: #ffffff;
    border: 1px solid #333333;
    border-radius: 4px;
    cursor: pointer;
    -webkit-transition: background-color 0.15s, color 0.15s;
    transition: background-color 0.15s, color 0.15s;
}

.gma-cc-btn:hover,
.gma-cc-btn:focus {
    background: #f0f0f0;
}

.gma-cc-btn--primary {
    color: #ffffff;
    background: #333333;
}

.gma-cc-btn--primary:hover,
.gma-cc-btn--primary:focus {
    color: #ffffff;
    background: #1f1f1f;
}

/* Окно настроек */

.gma-cc-modal {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2147483001;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    padding: 16px;
}

.gma-cc-modal__overlay {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.5);
}

.gma-cc-modal__window {
    position: relative;
    width: 100%;
    max-width: 620px;
    max-height: 100%;
    overflow-y: auto;
    padding: 28px 28px 24px;
    background: #ffffff;
    border-radius: 6px;
    -webkit-box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
    outline: none;
}

.gma-cc-modal__close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 32px;
    height: 32px;
    padding: 0;
    font-size: 26px;
    line-height: 32px;
    color: #777777;
    background: none;
    border: 0;
    cursor: pointer;
}

.gma-cc-modal__close:hover,
.gma-cc-modal__close:focus {
    color: #1f1f1f;
}

.gma-cc-modal__buttons {
    margin-top: 18px;
}

.gma-cc-category {
    margin: 14px 0;
    padding: 14px 16px;
    background: #f7f7f7;
    border-radius: 4px;
}

.gma-cc-category p {
    margin: 8px 0 0;
    color: #555555;
}

.gma-cc-category__head {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
    gap: 12px;
}

.gma-cc-category__name {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: #1f1f1f;
    cursor: default;
}

label.gma-cc-category__name {
    cursor: pointer;
}

.gma-cc-category__state {
    -ms-flex-negative: 0;
    flex-shrink: 0;
    font-size: 13px;
    color: #777777;
}

/* Переключатель */

.gma-cc-switch {
    position: relative;
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -ms-flex-negative: 0;
    flex-shrink: 0;
    gap: 8px;
    margin: 0;
    cursor: pointer;
}

.gma-cc-switch input {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
}

.gma-cc-switch__track {
    position: relative;
    display: block;
    width: 44px;
    height: 24px;
    background: #bdbdbd;
    border-radius: 12px;
    -webkit-transition: background-color 0.15s;
    transition: background-color 0.15s;
}

.gma-cc-switch__track:after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: #ffffff;
    border-radius: 50%;
    -webkit-transition: left 0.15s;
    transition: left 0.15s;
}

.gma-cc-switch input:checked + .gma-cc-switch__track {
    background: #333333;
}

.gma-cc-switch input:checked + .gma-cc-switch__track:after {
    left: 22px;
}

.gma-cc-switch input:focus + .gma-cc-switch__track {
    -webkit-box-shadow: 0 0 0 2px rgba(51, 51, 51, 0.3);
    box-shadow: 0 0 0 2px rgba(51, 51, 51, 0.3);
}

.gma-cc-switch__label {
    min-width: 36px;
    font-size: 13px;
    color: #555555;
}

.gma-cc-switch__label:before {
    content: attr(data-off);
}

.gma-cc-switch input:checked ~ .gma-cc-switch__label:before {
    content: attr(data-on);
}

/* Ссылка «Настройки cookies» в подвале ведёт себя как остальные ссылки */

a[data-gma-cc="settings"] {
    cursor: pointer;
}

html.gma-cc-locked,
html.gma-cc-locked body {
    overflow: hidden;
}

@media (max-width: 767px) {
    .gma-cc-banner__inner {
        display: block;
        padding: 16px 12px;
    }

    .gma-cc-banner__buttons {
        margin-top: 14px;
    }

    .gma-cc-btn {
        -webkit-box-flex: 1;
        -ms-flex: 1 1 0px;
        flex: 1 1 0;
        min-width: 0;
    }

    .gma-cc-modal__window {
        padding: 22px 16px 18px;
    }

    .gma-cc-modal__buttons .gma-cc-btn {
        width: 100%;
    }
}
