:root {
    --btp-alert-navy: #10233f;
    --btp-alert-blue: #2878bd;
    --btp-alert-blue-dark: #1d6098;
    --btp-alert-ink: #17243a;
    --btp-alert-muted: #68758a;
    --btp-alert-line: #d9e2ef;
    --btp-alert-wash: #f4f7fb;
    --btp-alert-danger: #a52727;
}

.btp-alert-kicker {
    margin: 0 0 .35rem !important;
    color: var(--btp-alert-blue) !important;
    font: 700 .7rem/1.2 Arial, sans-serif !important;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.btp-alert-button {
    min-height: 44px;
    padding: .7rem 1rem;
    border: 1px solid transparent;
    border-radius: 6px;
    font-family: inherit;
    font-size: .88rem;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    transition: background-color .16s ease, border-color .16s ease, color .16s ease, transform .16s ease;
}

.btp-alert-button:hover { transform: translateY(-1px); }
.btp-alert-button:focus-visible,
.btp-alert-dialog input:focus-visible,
.btp-alert-dialog__close:focus-visible {
    outline: 3px solid rgba(40, 120, 189, .35);
    outline-offset: 2px;
}

.btp-alert-button--primary { background: var(--btp-alert-blue); color: #fff; }
.btp-alert-button--primary:hover { background: var(--btp-alert-blue-dark); color: #fff; }
.btp-alert-button--secondary { background: #fff; color: var(--btp-alert-navy); border-color: var(--btp-alert-line); }
.btp-alert-button:disabled { opacity: .65; cursor: wait; transform: none; }

.btp-alert-dialog {
    box-sizing: border-box;
    width: min(92vw, 650px);
    max-width: calc(100vw - 1rem);
    max-height: min(88vh, 820px);
    padding: 0;
    color: var(--btp-alert-ink);
    background: #fff;
    border: 1px solid var(--btp-alert-line);
    border-radius: 12px;
    box-shadow: 0 26px 80px rgba(8, 23, 43, .28);
    overflow: auto;
    font-family: inherit;
}

/* Theme-Schriften duerfen Formularelemente sonst auf Systemfonts zuruecksetzen. */
.btp-alert-dialog .btp-alert-dialog__shell,
.btp-alert-dialog .btp-alert-dialog__shell * {
    font-family: inherit !important;
}

.btp-vorgang-alert-button {
    min-height: 30px;
    padding: .28rem .7rem;
    color: var(--btp-alert-navy);
    background: #fff;
    border: 1px solid rgba(255, 255, 255, .72);
    border-radius: 6px;
    box-shadow: 0 1px 2px rgba(8, 23, 43, .14);
    font-family: inherit;
    font-size: .76rem;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    transition: background-color .16s ease, box-shadow .16s ease;
}
.btp-vorgang-alert-button:hover { color: var(--btp-alert-navy); background: #f4f8fc; box-shadow: 0 2px 6px rgba(8, 23, 43, .2); }
.btp-vorgang-alert-button:focus-visible { outline: 3px solid rgba(255, 255, 255, .55); outline-offset: 2px; }

.btp-alert-dialog::backdrop { background: rgba(8, 23, 43, .62); backdrop-filter: blur(3px); }
.btp-alert-dialog__shell { position: relative; }
.btp-alert-dialog__shell,
.btp-alert-dialog__header,
.btp-alert-form { box-sizing: border-box; min-width: 0; }
.btp-alert-dialog__header { padding: 2rem 3.75rem 1.45rem 2rem; border-bottom: 1px solid var(--btp-alert-line); }
.btp-alert-dialog__header h2,
.btp-alert-success h2 { margin: 0 0 .6rem !important; color: var(--btp-alert-navy) !important; font: 700 clamp(1.55rem, 4vw, 2rem)/1.18 Georgia, serif !important; }
.btp-alert-dialog__header > p:last-child { margin: 0 !important; color: var(--btp-alert-muted) !important; line-height: 1.55 !important; }

.btp-alert-dialog__close {
    position: absolute;
    z-index: 2;
    top: .8rem;
    right: .8rem;
    display: grid;
    place-items: center;
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    color: var(--btp-alert-muted);
    background: transparent;
    border: 0;
    border-radius: 50%;
    font: 400 1.7rem/1 Arial, sans-serif;
    cursor: pointer;
}
.btp-alert-dialog__close:hover { color: var(--btp-alert-navy); background: var(--btp-alert-wash); }

.btp-alert-form { display: grid; gap: 1.35rem; padding: 1.6rem 2rem 2rem; }
.btp-alert-fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.btp-alert-fieldset legend,
.btp-alert-email-field > label {
    display: block;
    margin-bottom: .65rem;
    color: var(--btp-alert-navy);
    font: 700 .82rem/1.3 Arial, sans-serif;
}
.btp-alert-object-list { display: grid; gap: .65rem; }
.btp-alert-choice {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: .75rem;
    align-items: center;
    padding: .85rem .95rem;
    border: 1px solid var(--btp-alert-line);
    border-radius: 7px;
    cursor: pointer;
}
.btp-alert-choice:has(input:checked) { border-color: var(--btp-alert-blue); background: #f4f9fd; box-shadow: inset 3px 0 0 var(--btp-alert-blue); }
.btp-alert-choice input { position: absolute; opacity: 0; pointer-events: none; }
.btp-alert-choice__control { width: 1rem; height: 1rem; border: 2px solid #9aa7b8; border-radius: 50%; }
.btp-alert-choice input:checked + .btp-alert-choice__control { border: 4px solid var(--btp-alert-blue); }
.btp-alert-choice input:focus-visible + .btp-alert-choice__control { outline: 3px solid rgba(40, 120, 189, .3); outline-offset: 3px; }
.btp-alert-choice strong,
.btp-alert-channel strong { display: block; color: var(--btp-alert-navy); font: 700 .91rem/1.35 Arial, sans-serif; }
.btp-alert-choice > span:last-child,
.btp-alert-channel > span { min-width: 0; overflow-wrap: anywhere; }
.btp-alert-choice small,
.btp-alert-channel small { display: block; margin-top: .2rem; color: var(--btp-alert-muted); font: 400 .78rem/1.4 Arial, sans-serif; }

.btp-alert-channel-list { display: grid; grid-template-columns: 1fr 1fr; gap: .65rem; }
.btp-alert-channel { position: relative; display: block; padding: .85rem .95rem .85rem 2.55rem; border: 1px solid var(--btp-alert-line); border-radius: 7px; cursor: pointer; }
.btp-alert-channel input { position: absolute; left: .9rem; top: 1rem; accent-color: var(--btp-alert-blue); }
.btp-alert-channel:has(input:checked) { border-color: var(--btp-alert-blue); background: #f4f9fd; }
.btp-alert-channel:has(input:disabled) { opacity: .5; cursor: not-allowed; }

.btp-alert-email-field input {
    box-sizing: border-box;
    width: 100%;
    min-height: 46px;
    padding: .75rem .85rem;
    color: var(--btp-alert-ink);
    background: #fff;
    border: 1px solid #aeb9c8;
    border-radius: 6px;
    font: 400 1rem/1.3 Arial, sans-serif;
}
.btp-alert-consent { display: grid; grid-template-columns: auto 1fr; gap: .65rem; align-items: start; color: var(--btp-alert-muted); font: 400 .78rem/1.5 Arial, sans-serif; }
.btp-alert-consent input { width: 1rem; height: 1rem; margin-top: .1rem; accent-color: var(--btp-alert-blue); }
.btp-alert-consent a { color: var(--btp-alert-blue); }
.btp-alert-selection { display: flex; justify-content: space-between; gap: 1rem; padding: .8rem .9rem; background: var(--btp-alert-wash); border-radius: 6px; font: 400 .78rem/1.4 Arial, sans-serif; }
.btp-alert-selection span { color: var(--btp-alert-muted); }
.btp-alert-selection strong { color: var(--btp-alert-navy); text-align: right; }
.btp-alert-submit { width: 100%; position: relative; }
.btp-alert-remove {
    justify-self: center;
    margin-top: -.55rem;
    padding: .25rem;
    color: var(--btp-alert-muted);
    background: transparent;
    border: 0;
    font: 600 .75rem/1.4 Arial, sans-serif;
    text-decoration: underline;
    cursor: pointer;
}
.btp-alert-remove:hover { color: var(--btp-alert-navy); }
.btp-alert-spinner { display: none; width: .9rem; height: .9rem; margin-left: .5rem; border: 2px solid rgba(255,255,255,.45); border-top-color: #fff; border-radius: 50%; animation: btp-alert-spin .7s linear infinite; vertical-align: -.15rem; }
.btp-alert-submit.is-loading .btp-alert-spinner { display: inline-block; }
.btp-alert-form__message { min-height: 0; margin: -.55rem 0 0 !important; color: var(--btp-alert-muted) !important; font: 600 .8rem/1.45 Arial, sans-serif !important; }
.btp-alert-form__message:empty { display: none; }
.btp-alert-form__message.is-error { display: block; padding: .7rem .8rem; color: var(--btp-alert-danger) !important; background: #fff2f2; border-left: 3px solid var(--btp-alert-danger); }
.btp-alert-fineprint { margin: -.65rem 0 0 !important; color: var(--btp-alert-muted) !important; text-align: center; font: 400 .72rem/1.45 Arial, sans-serif !important; }
.btp-alert-success { padding: 3rem 2rem; text-align: center; }
.btp-alert-success__mark { display: grid; place-items: center; width: 3rem; height: 3rem; margin: 0 auto 1rem; color: #fff; background: var(--btp-alert-blue); border-radius: 50%; font: 700 1.35rem/1 Arial, sans-serif; }
.btp-alert-success > p:not(.btp-alert-kicker) { max-width: 460px; margin: 0 auto 1.5rem !important; color: var(--btp-alert-muted) !important; line-height: 1.6 !important; }

@keyframes btp-alert-spin { to { transform: rotate(360deg); } }

@media (max-width: 680px) {
    .btp-alert-dialog { width: calc(100vw - 1rem); max-height: calc(100dvh - 1rem); }
    .btp-alert-dialog__header { padding: 1.7rem 3.6rem 1.25rem 1.25rem; }
    .btp-alert-form { padding: 1.3rem 1.25rem 1.5rem; }
    .btp-alert-channel-list { grid-template-columns: 1fr; }
    .btp-alert-selection { display: grid; }
    .btp-alert-selection strong { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
    .btp-alert-button { transition: none; }
    .btp-alert-button:hover { transform: none; }
    .btp-alert-spinner { animation-duration: 1.5s; }
}
