.gnis-consent,
.gnis-consent * {
    box-sizing: border-box;
    letter-spacing: 0;
}

.gnis-consent[hidden],
.gnis-consent [hidden],
.gnis-consent__reopen[hidden] {
    display: none !important;
}

.gnis-consent {
    --gnis-consent-ink: #171717;
    --gnis-consent-muted: #5c6470;
    --gnis-consent-line: #dfe3e8;
    --gnis-consent-yellow: #ffd200;
    --gnis-consent-white: #fff;
    position: relative;
    z-index: 2147483000;
    color: var(--gnis-consent-ink);
    font-family: inherit;
}

.gnis-consent__banner {
    position: fixed;
    right: 20px;
    bottom: 20px;
    left: 20px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 22px;
    align-items: center;
    width: min(960px, calc(100vw - 40px));
    margin: 0 auto;
    padding: 18px 20px;
    border: 1px solid #cfd4da;
    border-radius: 8px;
    background: var(--gnis-consent-white);
    box-shadow: 0 16px 42px rgba(0, 0, 0, .18);
}

.gnis-consent__copy h2,
.gnis-consent__dialog h2 {
    margin: 0 0 6px;
    color: var(--gnis-consent-ink);
    font-size: 19px;
    line-height: 1.25;
    font-weight: 750;
}

.gnis-consent__copy p,
.gnis-consent__dialog p {
    margin: 0;
    color: var(--gnis-consent-muted);
    font-size: 14px;
    line-height: 1.5;
}

.gnis-consent__actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(168px, 1fr));
    gap: 8px;
    width: 390px;
}

.gnis-consent__button,
.gnis-consent__link,
.gnis-consent__close,
.gnis-consent__reopen {
    min-height: 42px;
    border: 0;
    border-radius: 6px;
    font: inherit;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.25;
    cursor: pointer;
}

.gnis-consent__button {
    padding: 10px 14px;
}

.gnis-consent__button--accept,
.gnis-consent__button--save {
    border: 2px solid #dbb500;
    color: #111;
    background: var(--gnis-consent-yellow);
}

.gnis-consent__button:hover,
.gnis-consent__button:focus-visible {
    filter: brightness(.94);
}

.gnis-consent__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 2px 8px;
    color: #303741;
    font-size: 13px;
    font-weight: 650;
    text-decoration: underline;
    text-underline-offset: 3px;
    background: transparent;
}

.gnis-consent__button--accept {
    grid-column: 1 / -1;
}

.gnis-consent__reopen {
    --gnis-consent-ink: #171717;
    --gnis-consent-white: #fff;
    position: static;
    display: grid;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-items: center;
    min-height: 42px;
    padding: 0;
    border: 1px solid #cfd4da;
    color: var(--gnis-consent-ink);
    background: var(--gnis-consent-white);
    box-shadow: none;
    margin: 18px;
}

.gnis-consent__reopen svg {
    display: block;
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

body.woocommerce-cart .gnis-consent__reopen,
body.woocommerce-checkout .gnis-consent__reopen,
body.gnis-side-cart-open .gnis-consent__reopen,
body.gnis-quick-scroll-locked .gnis-consent__reopen,
body.gnis-card-quick-scroll-locked .gnis-consent__reopen,
body.gnh2-scroll-locked .gnis-consent__reopen,
body.gnism-open .gnis-consent__reopen {
    display: none;
}

.gnis-consent__backdrop {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(17, 24, 39, .62);
}

.gnis-consent__dialog {
    width: min(680px, 100%);
    max-height: min(760px, calc(100vh - 40px));
    overflow: auto;
    border-radius: 8px;
    background: var(--gnis-consent-white);
    box-shadow: 0 26px 70px rgba(0, 0, 0, .28);
}

.gnis-consent__dialog-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 40px;
    gap: 14px;
    align-items: start;
    padding: 22px 22px 18px;
    border-bottom: 1px solid var(--gnis-consent-line);
}

.gnis-consent__close {
    width: 40px;
    min-height: 40px;
    padding: 0;
    color: #323842;
    background: #f1f3f5;
    font-size: 25px;
    font-weight: 500;
}

.gnis-consent__categories {
    padding: 4px 22px;
}

.gnis-consent__category {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
    min-height: 86px;
    padding: 16px 0;
    border-bottom: 1px solid var(--gnis-consent-line);
}

.gnis-consent__category:last-child {
    border-bottom: 0;
}

.gnis-consent__category strong {
    display: block;
    margin-bottom: 4px;
    font-size: 15px;
    line-height: 1.3;
}

.gnis-consent__required {
    max-width: 130px;
    color: #2d6a3f;
    font-size: 12px;
    font-weight: 750;
    text-align: right;
}

.gnis-consent__switch {
    position: relative;
    display: block;
    width: 48px;
    height: 27px;
    flex: 0 0 48px;
}

.gnis-consent__switch input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.gnis-consent__switch span {
    position: absolute;
    inset: 0;
    border: 1px solid #9da5af;
    border-radius: 14px;
    background: #d7dce1;
    transition: background-color .16s ease, border-color .16s ease;
}

.gnis-consent__switch span::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 19px;
    height: 19px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
    transition: transform .16s ease;
}

.gnis-consent__switch input:checked + span {
    border-color: #1e5b34;
    background: #277a45;
}

.gnis-consent__switch input:checked + span::after {
    transform: translateX(21px);
}

.gnis-consent__switch input:focus-visible + span {
    outline: 3px solid rgba(30, 91, 52, .24);
    outline-offset: 2px;
}

.gnis-consent__details {
    margin: 0 22px 18px;
    border-top: 1px solid var(--gnis-consent-line);
}

.gnis-consent__details summary {
    padding: 16px 0;
    font-size: 14px;
    font-weight: 750;
    cursor: pointer;
}

.gnis-consent__table-wrap {
    overflow-x: auto;
    padding-bottom: 6px;
}

.gnis-consent__details table {
    width: 100%;
    min-width: 560px;
    border-collapse: collapse;
    font-size: 12px;
    line-height: 1.45;
}

.gnis-consent__details th,
.gnis-consent__details td {
    padding: 9px 10px;
    border: 1px solid var(--gnis-consent-line);
    text-align: left;
    vertical-align: top;
}

.gnis-consent__details th {
    background: #f4f5f6;
}

.gnis-consent__dialog-foot {
    position: sticky;
    bottom: 0;
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    padding: 16px 22px;
    border-top: 1px solid var(--gnis-consent-line);
    background: var(--gnis-consent-white);
}

.gnis-consent__dialog-foot a {
    color: #303741;
    font-size: 13px;
    font-weight: 650;
    text-decoration: underline;
    text-underline-offset: 3px;
}

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

@media (max-width: 782px) {
    .gnis-consent__banner {
        bottom: calc(76px + env(safe-area-inset-bottom, 0px));
        grid-template-columns: 1fr;
        gap: 14px;
        width: calc(100vw - 24px);
        padding: 16px;
    }

    .gnis-consent__actions {
        width: 100%;
    }

    .gnis-consent__reopen {
        align-self: start;
        margin: 0;
    }


    .gnis-consent__backdrop {
        align-items: end;
        padding: 0;
    }

    .gnis-consent__dialog {
        width: 100%;
        max-height: calc(100vh - 16px);
        border-radius: 8px 8px 0 0;
    }
}

@media (max-width: 480px) {
    .gnis-consent__copy h2,
    .gnis-consent__dialog h2 {
        font-size: 17px;
    }

    .gnis-consent__copy p,
    .gnis-consent__dialog p {
        font-size: 13px;
    }

    .gnis-consent__actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .gnis-consent__button--accept {
        grid-column: 1 / -1;
    }

    .gnis-consent__dialog-head,
    .gnis-consent__categories,
    .gnis-consent__dialog-foot {
        padding-right: 16px;
        padding-left: 16px;
    }

    .gnis-consent__details {
        margin-right: 16px;
        margin-left: 16px;
    }

    .gnis-consent__dialog-foot {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .gnis-consent__dialog-foot .gnis-consent__button {
        width: 100%;
    }

}

@media (prefers-reduced-motion: reduce) {
    .gnis-consent__switch span,
    .gnis-consent__switch span::after {
        transition: none;
    }
}
