:root {
    --base-bg: #fff;
    --black: #0c0e0f;
    --border-separator: #f1f1f1;
    --checkbox-bg: #303030;
    --primary-btn: #4189dc;
    --primary-btn-hover: #1e5594;
    --secondary-btn: #1e2529;
    --secondary-btn-hover: #000;
    --section-bg: #f1f1f1;
    --section-bg-hover: #f1f1f1;
    --section-border: #e1e1e1;
    --section-border-expanded: #a1a1a1;
    --text-color: #3f3f3f;
    --toggle-bg: #525f6b;
    --white: #fff;
    --off-white: #f1f1f1;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* initial popup */
.consent-notice {
    background: var(--base-bg);
    border-radius: 5px;
    bottom: 10px;
    box-shadow: rgba(0, 0, 2, 0.3) 0px 8px 16px;
    color: var(--text-color);
    display: flex;
    flex-direction: column;
    font-family: sans-serif;
    left: 1rem;
    opacity: 0;
    overflow: hidden;
    position: fixed;
    transform: translateY(16px);
    transition: opacity .25s ease, visibility .25s ease, transform .25s ease;
    visibility: hidden;
    width: 100%;
    z-index: 7777;
    max-width: calc(100% - 20px);
}

.consent-notice.active {
    opacity: 1;
    transform: translateY(0px);
    visibility: visible !important;
}

@media (min-width: 768px) {
    .consent-notice {
        max-width: 360px;
    }
}
        
.consent-notice__body {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 8px;
    padding: 16px;
    position: relative;
}
            
.consent-notice__body--title {
    color: var(--black);
    font-size: 18px;
    margin: 0;
}
            
.consent-notice__body--desc {
    color: inherit;
    font-size: 16px;
    margin: 0;
}
        
.consent-notice__actions {
    border-top: 1px solid var(--border-separator);
    display: grid;
    grid-auto-columns: minmax(0px, 1fr);
    padding: 24px;
    
    button {
        background: var(--secondary-btn);
        border: 1px solid var(--secondary-btn);
        border-radius: 4px;
        color: var(--base-bg);
        cursor: pointer;
        font-size: 16px;
        font-weight: 600;
        min-height: 42px;
        padding: 8px 16px;
        text-align: center;
        transition: background-color 0.15s, border-color 0.15s, color 0.15s;

        &:not(:first-child) {
            margin-top: 6px;
        }
        
        &:hover {
            background: var(--secondary-btn-hover);
            border-color: var(--secondary-btn-hover);
        }
        
        &.consent-notice__actions--accept {
            background: var(--primary-btn);
            border: 1px solid var(--primary-btn);
            
            &:hover {
                background: var(--primary-btn-hover);
                border-color: var(--primary-btn-hover);
            }
        }
    }
}
                        
.consent-notice__footer {
    background: var(--off-white);
    padding: 8px 16px;
    
    ul {
        display: flex;
        flex-direction: row;
        gap: 16px;
        margin: 0;
        width: 100%;
        list-style-type: none;
        
        > li {
            color: var(--text-color);
            font-size: 16px;
            margin: 0;
            
            a {
                color: inherit;
                font-size: inherit;
                position: relative;
                text-decoration: none;
                
                &:hover {
                    color: var(--black);
                    text-decoration: underline;
                }
            }
        }
    }
}
        
/* main preferences modal */
.consent-modal {
    background: var(--base-bg);
    border-radius: 4px;
    box-shadow: rgba(0, 0, 2, 0.3) 0px 8px 16px;
    display: flex;
    flex-direction: column;
    font-family: sans-serif;
    height: calc(100% - 24px);
    left: 10px;
    margin: 0px auto;
    max-height: 480px;
    max-width: 560px;
    opacity: 0;
    overflow: hidden;
    position: fixed;
    right: 10px;
    top: 50%;
    transform: translateY(calc(-50% + 24px));
    transition: opacity .25s ease, visibility .25s ease, transform .25s ease;
    visibility: hidden;
    width: unset;
    z-index: 9999;
    
    &.active {
        opacity: 1;
        transform: translateY(-50%);
        visibility: visible !important;
    }
}
        
.consent-modal__header {
    align-items: center;
    border-bottom: 1px solid var(--border-separator);
    display: flex;
    justify-content: space-between;
    padding: 10px 14px;
    
    > h2 {
        all: unset;
        color: var(--white);
        font-weight: 600;
        margin: 0;
    }
}
        
.consent-modal__close {
    background: var(--secondary-btn);
    border: 1px solid var(--secondary-btn);
    border-radius: 4px;
    cursor: pointer;
    height: 40px;
    position: relative;
    transition: 0.15s;
    width: 40px;
    
    &:hover {
        background: var(--secondary-btn-hover);
        border-color: var(--secondary-btn-hover);
    }
    
    > span {
        display: flex;
        height: 100%;
        pointer-events: none;
        width: 100%;
        
        > svg {
            fill: none;
            stroke: var(--white);
            transform: scale(0.5);
            transition: stroke 0.15s;
            width: 100%;
        }
    }
}
        
.consent-modal__body {
    flex: 1;
    overscroll-behavior: auto contain;
    overflow-y: auto;
    overflow-y: overlay;
    padding: 10px 14px;
    scrollbar-width: thin;
    overflow-x: hidden;
}
    
.consent-modal__body--copy {
    margin-bottom: 16px;
}

.consent-modal__body--title {
    color: var(--black);
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.consent-modal__body--desc {
    color: var(--text-color);
    font-size: 16px;
    margin: 0;
}

.consent-modal__section {
    border-radius: 4px;
    border-top: none;
    display: flex;
    flex-direction: column;
    margin-bottom: 6px;
}
            
.consent-modal__section--title {
    align-items: center;
    display: flex;
    position: relative;
    
    .section__title {
        align-items: center;
        appearance: none;
        background: var(--section-bg);
        border: 1px solid var(--section-border);
        border-radius: 4px;
        color: var(--black);
        cursor: pointer;
        display: flex;
        font-family: inherit;
        font-size: 16px;
        font-weight: 600;
        justify-content: space-between;
        line-height: normal;
        margin: 0px;
        min-height: 58px;
        outline: revert;
        outline-offset: 2px;
        overflow: hidden;
        padding: 16px 80px 16px 48px;
        position: relative;
        transition: background-color 0.25s, border-color 0.25s;
        width: 100%;
        
        &:hover {
            background: var(--section-bg-hover);
        }
        
        .badge {
            align-items: center;
            background: var(--white);
            border-radius: 40px;
            color: var(--text-color);
            display: flex;
            flex: 0 0 auto;
            font-size: 14px;
            font-weight: 600;
            height: 23px;
            justify-content: center;
            margin-left: 16px;
            min-width: 23px;
            overflow: hidden;
            padding: 0px 8px 1px;
            position: relative;
            text-align: center;
            white-space: nowrap;
            width: auto;
        }
    }
    
    .section__arrow {
        background: var(--secondary-btn);
        border-radius: 100%;
        display: flex;
        height: 20px;
        justify-content: center;
        left: 18px;
        pointer-events: none;
        position: absolute;
        width: 20px;
        
        > svg {
            fill: none;
            stroke: var(--white);
            transform: scale(0.5);
            width: 100%;
        }
    }
    
    .section__toggle {
        border-radius: 40px;
        cursor: pointer;
        height: 23px;
        position: absolute;
        right: 18px;
        transform: translateZ(0px);
        width: 50px;
        z-index: 1;
        
        .section__checkbox {
            appearance: none;
            background-color: transparent;
            border-color: transparent;
            border-image: initial;
            border-style: initial;
            border-width: 0px;
            box-shadow: none !important;
            cursor: pointer;
            display: block;
            font-family: inherit;
            font-size: 100%;
            height: 23px;
            left: 0px;
            line-height: normal;
            margin: 0px;
            outline: revert;
            outline-offset: 2px;
            overflow: hidden;
            position: absolute;
            top: 0px;
            transform: translateZ(0px);
            width: 50px;
            
            &:disabled {
                cursor: not-allowed;
            }
            
            &:checked:disabled ~ .toggle__icon {
                background: var(--section-border-expanded);
                box-shadow: 0 0 0 1px var(--section-border-expanded);
                
                svg {
                    stroke: var(--section-border-expanded);
                }
            }
            
            &:checked ~ .toggle__icon {
                background: var(--primary-btn);
                box-shadow: 0 0 0 1px var(--primary-btn);
                
                .toggle__icon--circle {
                    transform: translate(27px);
                    
                    .toggle__icon--on {
                        opacity: 1;
                        
                        svg {
                            stroke: var(--primary-btn);
                        }
                    }
                    
                    .toggle__icon--off {
                        opacity: 0;
                    }
                }
            }
        }
        
        .toggle__icon {
            background: var(--toggle-bg);
            border-radius: 40px;
            box-shadow: 0 0 0 1px var(--toggle-bg);
            display: flex;
            flex-direction: row;
            height: 23px;
            pointer-events: none;
            position: absolute;
            transform: translateZ(0px);
            transition: 0.25s;
            width: 50px;
        }
            
        .toggle__icon--circle {
            background: var(--base-bg);
            border-color: initial;
            border-image: initial;
            border-radius: 100%;
            border-style: initial;
            border-width: 0px;
            display: block;
            height: 23px;
            left: 0px;
            position: absolute;
            top: 0px;
            transition: transform 0.25s, background-color 0.25s;
            width: 23px;
            
            .toggle__icon--on, .toggle__icon--off {
                height: 100%;
                position: absolute;
                transition: opacity 0.15s;
                width: 100%;
                
                svg {
                    fill: none;
                    position: absolute;
                    stroke: var(--toggle-bg);
                    transform: scale(0.55);
                    width: 100%;
                }
            }
            
            .toggle__icon--on {
                opacity: 0;
            }
            
            .toggle__icon--off {
                opacity: 1;
            }
        }
    }
}
            
.consent-modal__section--body {
    background-color: var(--white);
    border: 1px solid var(--section-border-expanded);
    border-radius: 0px 0px 4px 4px;
    border-top: none;
    color: var(--text-color);
    display: none;
    flex-direction: column;
    font-size: 16px;
    margin-top: 0px !important;
    overflow: hidden;
    padding: 10px;
    
    > p {
        all: unset;
    }
}

.consent-modal__section--desc {
    color: var(--text-color);
    font-size: 16px;
}

.consent-modal__section--expanded {
    background: unset;
    
    .section__title {
        border-bottom-left-radius: 0px;
        border-bottom-right-radius: 0px;
        border-color: var(--section-border-expanded);
    }
    
    .section__arrow {
        transform: rotate(180deg);
    }
    
    .consent-modal__section--body {
        border-color: var(--section-border-expanded);
        display: flex;
    }
}
        
.consent-modal__footer {
    border-top: 1px solid var(--border-separator);
    display: flex;
    justify-content: space-between;
    padding: 10px 14px;
    flex-direction: column;
    gap: 10px;

    @media (min-width: 768px) {
        flex-direction: row;
    }
    
    .button-group {
        display: flex;
        gap: 6px;
        
        button {
            appearance: none;
            background: var(--primary-btn);
            border: 1px solid var(--primary-btn);
            border-radius: 4px;
            color: var(--base-bg);
            cursor: pointer;
            flex: auto;
            font-family: inherit;
            font-size: 16px;
            font-weight: 600;
            line-height: normal;
            margin: 0;
            min-height: 42px;
            min-width: 110px;
            outline: revert;
            outline-offset: 2px;
            overflow: hidden;
            padding: 8px 16px;
            text-align: center;
            transition: background-color .15s ease, border-color .15s ease, color .15s ease;
            
            &:hover {
                background: var(--primary-btn-hover);
                border-color: var(--primary-btn-hover);
            }
            
            &#modal-reject-all,
            &#modal-save {
                background: var(--secondary-btn);
                border-color: var(--secondary-btn);
                color: var(--white);
                
                &:hover {
                    background: var(--secondary-btn-hover);
                    border-color: var(--secondary-btn-hover);
                }
            }
        }
    }
}
    
/* bg site overlay */
.consent-overlay {
    background: rgba(0, 0, 0, .65);
    content: "";
    inset: 0px;
    opacity: 0;
    position: fixed;
    transition: opacity .25s ease, visibility .25s ease, transform .25s ease;
    visibility: hidden;
    z-index: 8888;
    
    &.active {
        opacity: 1;
        visibility: visible;
    }
}
/* "Manage Cookie Preferences" link/button rendered by the
   [cookie_consent_preferences] shortcode (e.g. in a footer widget). */
.ccm-reopen-preferences {
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    font: inherit;
    padding: 0;
    text-decoration: underline;
}
