.consent-root {
    position: fixed;
    inset: 0;
    z-index: 1080;
    pointer-events: none;
}

.consent-banner {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    background: var(--bs-body-bg, white);
    color: var(--bv-color-text);
    pointer-events: auto;
}

.consent-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.consent-actions .btn-link {
    grid-column: 1 / -1;
}

.consent-primary-action {
    min-height: 44px;
    min-width: 0;
}

.consent-backdrop {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgb(0 0 0 / 55%);
    pointer-events: auto;
}

.consent-dialog {
    width: min(100%, 42rem);
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
    border: 1px solid var(--bv-color-divider);
    border-radius: 0.5rem;
    background: var(--bs-body-bg, white);
    box-shadow: 0 1rem 3rem rgb(0 0 0 / 18%);
}

.consent-dialog-header,
.consent-dialog-footer,
.consent-category {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
}

.consent-dialog-header,
.consent-category {
    border-bottom: 1px solid var(--bv-color-card-border);
}

.consent-dialog-header {
    justify-content: space-between;
    align-items: flex-start;
}

.consent-category {
    justify-content: space-between;
    transition: background-color 160ms ease;
}

.consent-category-highlight {
    background: rgb(104 159 56 / 12%);
}

.consent-category .form-check {
    flex: 0 0 auto;
    margin: 0;
}

.consent-category .form-check-input {
    width: 2.5rem;
    height: 1.25rem;
}

.consent-dialog-footer {
    flex-wrap: wrap;
    justify-content: flex-end;
}

.consent-audit-status {
    flex: 1 0 100%;
}

body.consent-panel-open {
    overflow: hidden;
}

.gmaps {
    position: relative;
    min-height: 18rem;
}

.map-consent-placeholder {
    position: absolute;
    inset: 0;
    z-index: 12;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background:
        linear-gradient(45deg, var(--bv-color-card-border) 25%, transparent 25%),
        linear-gradient(-45deg, var(--bv-color-card-border) 25%, transparent 25%),
        var(--bs-secondary-bg);
    background-size: 2rem 2rem;
}

.map-consent-placeholder-inner {
    width: min(100%, 28rem);
    padding: 1.5rem;
    border: 1px solid var(--bv-color-divider);
    border-radius: 0.5rem;
    background: var(--bs-body-bg);
    text-align: center;
}

@media (max-width: 575.98px) {
    .consent-actions {
        grid-template-columns: 1fr;
    }

    .consent-actions .btn-link {
        grid-column: auto;
    }

    .consent-backdrop {
        align-items: flex-end;
        padding: 0;
    }

    .consent-dialog {
        width: 100%;
        max-height: 92vh;
        border-right: 0;
        border-bottom: 0;
        border-left: 0;
        border-radius: 0.75rem 0.75rem 0 0;
    }

    .consent-dialog-footer .btn {
        flex: 1 1 auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .consent-category {
        transition: none;
    }
}
