.citizen-chat[data-citizen-chat-enabled] .citizen-chat__panel {
    width: min(calc(100vw - 2rem), 26rem);
    max-height: calc(100vh - 7rem);
    max-height: calc(100dvh - 7rem);
    overscroll-behavior: contain;
}
.citizen-chat[data-citizen-chat-enabled] .citizen-chat__body { gap: .75rem; }
.citizen-chat__welcome, .citizen-chat__notice, .citizen-chat__pending, .citizen-chat__feedback { margin: 0; overflow-wrap: anywhere; }
.citizen-chat__welcome { font-weight: 700; }
.citizen-chat__notice { color: #405367; font-size: .8125rem; line-height: 1.5; }
.citizen-chat__suggestions { display: flex; flex-wrap: wrap; gap: .5rem; }
.citizen-chat[data-citizen-chat-enabled] .citizen-chat__body button {
    font: inherit; min-height: 44px; border: 1px solid #93b6d5;
    border-radius: .7rem; padding: .5rem .75rem; color: #093d68; background: #edf6ff;
    cursor: pointer; overflow-wrap: anywhere; max-width: 100%;
}
.citizen-chat__history { display: grid; gap: .75rem; min-width: 0; }
.citizen-chat__exchange { display: grid; gap: .5rem; min-width: 0; }
.citizen-chat__bubble { padding: .7rem .8rem; border-radius: .85rem; background: #edf3f8; color: #17364c; min-width: 0; overflow-wrap: anywhere; }
.citizen-chat__bubble--user { margin-left: 1.5rem; background: #0b4e83; color: #fff; }
.citizen-chat__bubble--answer { margin-right: 1rem; }
.citizen-chat__bubble p { white-space: pre-wrap; margin: .25rem 0 0; line-height: 1.55; }
.citizen-chat__bubble strong { font-size: .8125rem; }
.citizen-chat__bubble a { display: inline-block; color: #064f91; text-decoration: underline; padding-block: .5rem; }
.citizen-chat__pending { padding: .7rem; border: 1px solid #c69a3a; background: #fff7e3; color: #634607; font-size: .875rem; }
.citizen-chat__refresh-row { text-align: right; }
.citizen-chat__feedback { color: #334f65; font-size: .875rem; }
.citizen-chat__feedback[data-error="true"] { color: #a01818; }
.citizen-chat__feedback:empty { display: none; }
.citizen-chat__form { display: grid; gap: .5rem; min-width: 0; }
.citizen-chat__form label { font-weight: 700; }
.citizen-chat__form textarea { box-sizing: border-box; width: 100%; max-width: 100%; min-height: 64px; resize: vertical; border: 1px solid #7898b2; border-radius: .6rem; padding: .65rem; font: inherit; font-size: 16px; color: #17364c; background: #fff; }
.citizen-chat[data-citizen-chat-enabled] .citizen-chat__form button { background: #07558f; border-color: #07558f; color: #fff; }
.citizen-chat[data-citizen-chat-enabled] .citizen-chat__body button:disabled { opacity: .6; cursor: wait; }
.citizen-chat[data-citizen-chat-enabled] .citizen-chat__body button:focus-visible,
.citizen-chat__form textarea:focus-visible, .citizen-chat__bubble a:focus-visible { outline: 3px solid #086cc4; outline-offset: 2px; }
.citizen-chat[data-citizen-chat-enabled] [hidden] { display: none !important; }
@media (max-width: 480px) {
    .citizen-chat[data-citizen-chat-enabled] .citizen-chat__panel { width: calc(100vw - 2.5rem); }
}
@media (max-width: 39.999rem) {
    body:has(.cookie-box.is-visible) .citizen-chat[data-citizen-chat-enabled] .citizen-chat__panel {
        /* Reserve the cookie offset, launcher, grid gap, and space above the panel. */
        max-height: calc(100vh - clamp(11.5rem, 44vw, 14rem) - 4.5rem - var(--space-3) - 1rem);
        max-height: calc(100dvh - clamp(11.5rem, 44vw, 14rem) - 4.5rem - var(--space-3) - 1rem);
    }
}
@media (min-width: 40rem) {
    body:has(.cookie-box.is-visible) .citizen-chat[data-citizen-chat-enabled] .citizen-chat__panel {
        max-height: calc(100vh - clamp(10rem, 20vw, 12rem) - 5.25rem - var(--space-3) - 1rem);
        max-height: calc(100dvh - clamp(10rem, 20vw, 12rem) - 5.25rem - var(--space-3) - 1rem);
    }
}
