#wplt-consent-card[hidden],
.wplt-consent-preferences[hidden] {
    display: none !important;
}

#wplt-consent-card {
    position: fixed;
    inset: auto 0 var(--wplt-consent-bottom, 0px);
    z-index: 950;
    max-height: 50vh;
    overflow-y: auto;
    box-sizing: border-box;
    margin: 0;
    padding: .75rem max(1rem, env(safe-area-inset-right))
        calc(.75rem + env(safe-area-inset-bottom)) max(1rem, env(safe-area-inset-left));
    border-top: 1px solid #d8e2dc;
    background: #fff;
    color: #213b30;
    box-shadow: 0 -4px 20px rgb(20 47 34 / 10%);
    font: inherit;
    font-size: .875rem;
    line-height: 1.45;
}

#wplt-consent-card[data-wplt-above-nav] {
    padding-bottom: .75rem;
}

.wplt-consent-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem 1.25rem;
    max-width: 72rem;
    margin-inline: auto;
}

#wplt-consent-card p {
    margin: 0;
}

.wplt-consent-actions {
    display: flex;
    flex: none;
    flex-wrap: wrap;
    gap: .5rem;
}

#wplt-consent-card button,
.wplt-consent-preferences button {
    box-sizing: border-box;
    margin: 0;
    padding: .5rem .75rem;
    min-height: 44px;
    color: #194c36;
    background: #fff;
    border: 1px solid #859e90;
    border-radius: .5rem;
    font: inherit;
    line-height: 1.3;
    font-weight: 600;
    cursor: pointer;
}

#wplt-consent-card button[data-wplt-choice="allow"] {
    color: #fff;
    background: #19623f;
    border-color: #19623f;
}

#wplt-consent-card button:focus-visible,
.wplt-consent-preferences button:focus-visible {
    outline: 2px solid #19623f;
    outline-offset: 2px;
}

.wplt-consent-preferences {
    width: min(100% - 2rem, 72rem);
    margin: 0 auto 1rem;
    font-size: .875rem;
}

.wplt-consent-spacer {
    height: var(--wplt-consent-height, 0px);
}

/* Leave the CouponF5 mobile offer accessible above the consent bar. */
:root .c5-sticky {
    bottom: calc(var(--wplt-consent-height, 0px) + var(--wplt-consent-bottom, 0px));
}

@media (max-width: 700px) {
    .wplt-consent-inner {
        display: grid;
    }
}

#wplt-consent-card {
    inset: auto auto calc(var(--wplt-consent-bottom, 0px) + max(14px, env(safe-area-inset-bottom))) max(16px, env(safe-area-inset-left));
    width: min(390px, calc(100vw - 32px));
    padding: 18px;
    border: 1px solid #d8e2dc;
    border-radius: 14px;
    box-shadow: 0 8px 32px rgb(20 47 34 / 16%);
}

#wplt-consent-card h2 {
    margin: 0 0 7px;
    color: inherit;
    font: inherit;
    font-size: 1.125rem;
    font-weight: 700;
}

#wplt-consent-card [hidden] {
    display: none !important;
}

#wplt-consent-card .wplt-consent-actions {
    margin-top: 12px;
}

#wplt-consent-card [data-wplt-save] {
    color: #fff;
    background: #19623f;
    border-color: #19623f;
}

#wplt-consent-card .wplt-settings-link {
    border-color: transparent;
    text-decoration: underline;
}

#wplt-consent-card .wplt-statistics-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    margin-top: 8px;
}

@media (max-width: 767px) {
    #wplt-consent-card {
        inset-inline: max(10px, env(safe-area-inset-left)) max(10px, env(safe-area-inset-right));
        bottom: calc(var(--wplt-consent-bottom, 0px) + 10px + env(safe-area-inset-bottom, 0px));
        width: auto;
        padding: 14px;
    }

    #wplt-consent-card[data-wplt-above-nav] {
        bottom: calc(var(--wplt-consent-bottom, 0px) + 10px);
    }

    :root .c5-sticky {
        bottom: calc(var(--wplt-consent-height, 0px) + var(--wplt-consent-bottom, 0px) + var(--wplt-consent-gap, 0px));
    }

    :root:has(#wplt-consent-card:not([hidden])) {
        --wplt-consent-gap: calc(10px + env(safe-area-inset-bottom, 0px));
    }

    :root:has(#wplt-consent-card[data-wplt-above-nav]:not([hidden])) {
        --wplt-consent-gap: 10px;
    }
}

@media (min-width: 768px) {
    .wplt-consent-spacer {
        height: 0;
    }
}
