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

.agp-consent {
    --agp-consent-ink: var(--ink, #111111);
    --agp-consent-paper: var(--white, #ffffff);
    --agp-consent-red: var(--red, #ed1c24);
    --agp-consent-yellow: var(--yellow, #ffc600);
    position: relative;
    z-index: 2147483000;
    color: var(--agp-consent-ink);
    font-family: 'Roboto Flex', Arial, sans-serif;
}

.agp-consent-banner {
    position: fixed;
    right: clamp(12px, 2vw, 28px);
    bottom: clamp(12px, 2vw, 28px);
    left: clamp(12px, 2vw, 28px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: clamp(18px, 3vw, 48px);
    max-width: 1180px;
    margin-inline: auto;
    padding: clamp(18px, 2.5vw, 30px);
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: 18px;
    background: #111111;
    box-shadow: 0 18px 60px rgba(0, 0, 0, .28);
    color: #ffffff;
}

.agp-consent-copy {
    min-width: 0;
}

.agp-consent-copy h2,
.agp-consent-dialog h2 {
    margin: 0 0 8px;
    font-size: clamp(1.15rem, 2vw, 1.55rem);
    line-height: 1.08;
}

.agp-consent-copy p,
.agp-consent-dialog > p {
    max-width: 70ch;
    margin: 0;
    font-size: .94rem;
    line-height: 1.45;
}

.agp-consent-copy a,
.agp-consent-policy-link {
    display: inline-block;
    margin-top: 9px;
    color: inherit;
    font-size: .82rem;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.agp-consent-actions,
.agp-consent-dialog-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(112px, 1fr));
    gap: 8px;
}

:is(.agp-consent-actions button,.agp-consent-dialog-actions button) {
    min-height: 44px;
    padding: 10px 15px;
    border: 1px solid currentColor;
    border-radius: 999px;
    background: transparent;
    color: inherit;
    font: inherit;
    font-size: .84rem;
    font-weight: 700;
    line-height: 1.1;
    text-align: center;
    cursor: pointer;
}

.agp-consent-banner :is(.agp-consent-actions button,.agp-consent-dialog-actions button):hover,
.agp-consent-banner :is(.agp-consent-actions button,.agp-consent-dialog-actions button):focus-visible {
    border-color: var(--agp-consent-yellow);
    background: var(--agp-consent-yellow);
    color: #111111;
}

:is(.agp-consent-actions button,.agp-consent-dialog-actions button):focus-visible,
.agp-cookie-open:focus-visible,
.agp-consent-close:focus-visible,
.agp-consent a:focus-visible {
    outline: 3px solid var(--agp-consent-yellow);
    outline-offset: 3px;
}

.agp-consent-backdrop {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(0, 0, 0, .64);
}

.agp-consent-dialog {
    position: relative;
    width: min(620px, 100%);
    max-height: calc(100vh - 36px);
    overflow: auto;
    padding: clamp(22px, 4vw, 38px);
    border-radius: 18px;
    background: var(--agp-consent-paper);
    box-shadow: 0 24px 80px rgba(0, 0, 0, .34);
    color: var(--agp-consent-ink);
}

.agp-consent-close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 40px;
    height: 40px;
    border: 0;
    background: transparent;
    color: inherit;
    font-size: 1.7rem;
    line-height: 1;
    cursor: pointer;
}

.agp-consent-category {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 20px;
    margin-top: 16px;
    padding: 16px 0;
    border-top: 1px solid rgba(17, 17, 17, .16);
    cursor: pointer;
}

.agp-consent-category > div,
.agp-consent-category > span {
    display: grid;
    gap: 4px;
}

.agp-consent-category span span,
.agp-consent-category div span {
    color: rgba(17, 17, 17, .68);
    font-size: .83rem;
    line-height: 1.35;
}

.agp-consent-category input {
    width: 22px;
    height: 22px;
    accent-color: var(--agp-consent-red);
}

.agp-consent-dialog-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 18px;
}

.agp-consent-dialog .agp-consent-primary {
    border-color: var(--agp-consent-red);
    background: var(--agp-consent-red);
    color: #ffffff;
}

.agp-consent-dialog :is(.agp-consent-actions button,.agp-consent-dialog-actions button):hover,
.agp-consent-dialog :is(.agp-consent-actions button,.agp-consent-dialog-actions button):focus-visible {
    border-color: var(--agp-consent-ink);
    background: var(--agp-consent-ink);
    color: #ffffff;
}

.agp-consent-policy-link {
    color: inherit;
}

.agp-cookie-open {
    width: fit-content;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-size: inherit;
    line-height: inherit;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
}

.footer-legal .agp-cookie-open,
.footer-legal-links .agp-cookie-open {
    color: inherit;
    opacity: 1;
}

.footer-legal .agp-cookie-open:hover,
.footer-legal-links .agp-cookie-open:hover {
    color: var(--orange, #f3a712);
    opacity: 1;
}

body.agp-consent-dialog-open {
    overflow: hidden;
}

@media (max-width: 820px) {
    .agp-consent-banner {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .agp-consent-actions {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .agp-consent-banner {
        padding: 18px;
        border-radius: 14px;
    }

    .agp-consent-actions,
    .agp-consent-dialog-actions {
        grid-template-columns: 1fr;
    }

    .agp-consent-dialog {
        padding: 24px 18px;
        border-radius: 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .agp-consent *,
    .agp-consent *::before,
    .agp-consent *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}

/* Native <dialog> retains focus trapping and Escape behavior. */
.agency-preview :is(.agp-consent-banner,.agp-consent-dialog){box-sizing:border-box;font-family:'Roboto Flex',Arial,sans-serif;--agp-consent-ink:#111;--agp-consent-paper:#fff;--agp-consent-red:#be1622;--agp-consent-yellow:#ffc600}
.agency-preview .agp-consent-banner[hidden],.agency-preview .agp-consent-dialog [hidden]{display:none!important}
.agency-preview .agp-consent-dialog{position:fixed;inset:0;margin:auto;width:min(620px,calc(100% - 36px));border:0;max-height:calc(100dvh - 36px)}
.agency-preview .agp-consent-dialog::backdrop{background:rgba(0,0,0,.64)}
.agency-preview .agp-consent-dialog h2{padding-right:28px}
.agency-preview .agp-consent-category input{appearance:auto;flex:none;cursor:pointer}
.agency-preview .agp-consent-category input:disabled{cursor:default}
.agency-preview .agp-consent-status:empty{display:none}
.agency-preview .agp-consent-status{margin-top:12px;font-size:.83rem;line-height:1.35}
.agency-preview .agp-consent-category input:focus-visible{outline:3px solid #ffc600;outline-offset:3px}
.agency-preview .agp-consent-banner h2{color:#fff}
.agency-preview .agp-consent-banner a{color:#fff}
@media(max-width:520px){.agency-preview .agp-consent-dialog{padding:24px 18px;border-radius:14px}}
.agency-preview .agp-consent-copy h2,.agency-preview .agp-consent-dialog h2{margin:0 0 8px;font-size:clamp(1.15rem,2vw,1.55rem);font-weight:600;line-height:1.08;letter-spacing:-.035em}
.agency-preview .agp-consent-copy p,.agency-preview .agp-consent-dialog>p{max-width:70ch;margin:0;font-size:.94rem;line-height:1.45}
.agency-preview .agp-consent-dialog{max-width:620px}
.agency-preview .agp-consent-copy a,.agency-preview .agp-consent-policy-link{text-decoration:underline;text-underline-offset:3px}

.agency-preview .agp-consent-banner{z-index:10000}
.agency-preview .agp-consent-dialog{padding:clamp(22px,4vw,38px);color:#111}
@media(max-width:520px){.agency-preview .agp-consent-dialog{padding:24px 18px}}
