/* Willkommens-Verbindung nach dem Setup: Mobil-QR und Chat-Agent. Cookbook-Fläche. */

.overlay:has(.po-cl-dlg) {
    background: rgba(15, 23, 42, 0.48);
}

.po-cl-dlg .dialog-title,
.po-cl-dlg .dialog-actions {
    display: none !important;
}

.po-cl-dlg {
    width: 1040px !important;
    max-width: calc(100vw - 32px) !important;
    max-height: calc(100vh - 32px) !important;
    border-radius: 12px !important;
    overflow: auto;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
    border: 1px solid #e2e8f0;
    background: #f8f9fa;
}

.po-cl-dlg .dialog-content {
    padding: 0 !important;
    background: #f8f9fa;
}

.po-cl-launch {
    position: relative;
    padding: 22px 24px 18px;
    color: #0f172a;
    font-weight: 400;
}

.po-cl-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #667085;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    appearance: none;
}

.po-cl-close:hover,
.po-cl-close:focus-visible {
    background: #eef3f8;
    color: #4C6C8B;
    outline: none;
}

.po-cl-kicker {
    margin: 0 48px 6px 0;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #667085;
}

.po-cl-title {
    margin: 0 48px 8px 0;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.35;
    color: #0f172a;
}

.po-cl-lead {
    margin: 0 0 18px;
    max-width: 720px;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.5;
    color: #667085;
}

.po-cl-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    align-items: stretch;
}

.po-cl-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 280px;
    padding: 18px 18px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #ffffff;
}

.po-cl-card.is-connected {
    background: #EEF3EF;
    border-color: #D4DDD6;
}

.po-cl-card-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #eef3f8;
    color: #587899;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    margin-bottom: 12px;
}

.po-cl-card.is-connected .po-cl-card-icon {
    background: #ffffff;
    color: #6B8F71;
}

.po-cl-card-title {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.35;
    color: #0f172a;
}

.po-cl-card-desc,
.po-cl-hint,
.po-cl-reissue-hint,
.po-cl-status {
    margin: 0;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.5;
    color: #667085;
}

.po-cl-card-desc {
    margin-bottom: 14px;
}

.po-cl-actions {
    margin-top: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 14px;
}

.po-cl-fill,
.po-cl-outline,
.po-cl-later,
.po-cl-done {
    appearance: none;
    height: 36px;
    padding: 0 14px;
    border-radius: 10px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
}

.po-cl-fill,
.po-cl-done {
    border: 1px solid #587899;
    background: #587899;
    color: #ffffff;
}

.po-cl-fill:hover,
.po-cl-done:hover {
    background: #4C6C8B;
    border-color: #4C6C8B;
    color: #ffffff;
}

.po-cl-fill:active,
.po-cl-done:active {
    background: #405F7D;
    border-color: #405F7D;
}

.po-cl-outline,
.po-cl-later {
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #4C6C8B;
}

.po-cl-outline:hover,
.po-cl-later:hover,
.po-cl-outline:focus-visible,
.po-cl-later:focus-visible {
    background: #eef3f8;
    outline: none;
}

.po-cl-outline.is-success,
.po-cl-fill.is-success {
    border-color: #6B8F71;
    background: #EEF3EF;
    color: #0f172a;
}

.po-cl-qr-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
}

.po-cl-qr {
    width: 180px;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
}

.po-cl-qr img,
.po-cl-qr canvas,
.po-cl-qr table {
    display: block;
}

.po-cl-qr-fallback {
    padding: 10px;
    font-size: 12px;
    line-height: 1.4;
    color: #667085;
    word-break: break-all;
    text-align: center;
}

.po-cl-countdown {
    font-size: 12px;
    font-weight: 400;
    color: #667085;
}

.po-cl-token-row {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-top: 8px;
}

.po-cl-token {
    flex: 1 1 auto;
    min-width: 0;
    height: 36px;
    padding: 0 10px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #f8f9fa;
    color: #0f172a;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 12px;
    font-weight: 400;
}

.po-cl-clients {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 14px 0 10px;
}

.po-cl-client {
    appearance: none;
    height: 32px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #4C6C8B;
    font-family: inherit;
    font-size: 12px;
    font-weight: 400;
    cursor: pointer;
}

.po-cl-client.is-selected,
.po-cl-client[aria-pressed="true"] {
    border-color: #587899;
    background: #eef3f8;
    color: #0f172a;
}

.po-cl-steps {
    margin: 0;
    padding: 0;
    list-style: none;
}

.po-cl-steps li {
    display: grid;
    grid-template-columns: 22px 1fr;
    gap: 8px;
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.45;
    color: #0f172a;
}

.po-cl-step-n {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    background: #eef3f8;
    color: #587899;
    font-size: 12px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.po-cl-json {
    margin: 8px 0 0;
    padding: 10px 12px;
    max-height: 140px;
    overflow: auto;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #0f172a;
    color: #e4e9ef;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.45;
    white-space: pre-wrap;
    word-break: break-word;
}

.po-cl-busy {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    font-size: 13px;
    color: #667085;
}

.po-cl-error {
    margin-top: 10px;
    padding: 10px 12px;
    border: 1px solid #E5D0CC;
    border-radius: 10px;
    background: #F4EBE9;
    color: #0f172a;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.45;
}

.po-cl-footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 16px;
}

.po-cl-done[hidden],
.po-cl-later[hidden] {
    display: none !important;
}

@media (max-width: 900px) {
    .po-cl-launch {
        padding: 18px 16px 14px;
    }

    .po-cl-grid {
        grid-template-columns: 1fr;
    }

    .po-cl-card {
        min-height: 0;
    }
}
