/* Branded alert/confirm dialogs — js/dialog.js (sbAlert / sbConfirm). */
.sb-dialog-overlay {
    --sb-tone: #f58220;
    --sb-tone-soft: #fff3e6;
    position: fixed;
    inset: 0;
    z-index: 20000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(20, 24, 31, 0.5);
    opacity: 0;
    transition: opacity .18s ease;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
.sb-dialog-overlay.show { opacity: 1; }

.sb-tone-success { --sb-tone: #2e7d32; --sb-tone-soft: #e8f5e9; }
.sb-tone-warning { --sb-tone: #f58220; --sb-tone-soft: #fff3e6; }
.sb-tone-danger  { --sb-tone: #c62828; --sb-tone-soft: #fdecea; }
.sb-tone-error   { --sb-tone: #c62828; --sb-tone-soft: #fdecea; }
.sb-tone-info    { --sb-tone: #1565c0; --sb-tone-soft: #e8f0fb; }

.sb-dialog {
    position: relative;
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: 18px;
    padding: 28px 26px 22px;
    text-align: center;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
    border-top: 5px solid var(--sb-tone);
    transform: translateY(10px) scale(.97);
    transition: transform .18s ease;
}
.sb-dialog-overlay.show .sb-dialog { transform: none; }

.sb-dialog-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 14px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--sb-tone-soft);
    color: var(--sb-tone);
    font-size: 26px;
}

.sb-dialog-title {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 800;
    color: #1f2933;
}

.sb-dialog-body {
    margin: 0 0 22px;
    font-size: 14px;
    line-height: 1.55;
    color: #5f6b7a;
    overflow-wrap: anywhere;
}

.sb-dialog-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.sb-dialog-btn {
    flex: 1 1 0;
    max-width: 170px;
    padding: 11px 16px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: filter .15s ease, background .15s ease;
}
.sb-dialog-btn:focus-visible { outline: 3px solid var(--sb-tone-soft); outline-offset: 2px; }

.sb-dialog-ok {
    border: none;
    background: var(--sb-tone);
    color: #fff;
}
.sb-dialog-ok:hover { filter: brightness(.92); }

.sb-dialog-cancel {
    border: 1px solid #e0e0e0;
    background: #f5f5f5;
    color: #5f6b7a;
}
.sb-dialog-cancel:hover { background: #ebebeb; }

@media (max-width: 480px) {
    .sb-dialog { padding: 24px 18px 18px; }
    .sb-dialog-actions { flex-direction: column-reverse; }
    .sb-dialog-btn { max-width: none; }
}

/* Grouped choices — sbChoose() (e.g. the Dashboard's Start Call sheet) */
.sb-dialog-groups { display: flex; flex-direction: column; gap: 10px; margin: 4px 0 18px; text-align: left; }
.sb-dialog-group {
    border: 1px solid #ececec;
    border-radius: 12px;
    padding: 12px 14px;
    background: #fafafa;
}
.sb-dialog-group-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.sb-dialog-group-title { font-size: 12px; font-weight: 800; color: #5f6b7a; text-transform: uppercase; letter-spacing: .4px; }
.sb-dialog-group-sub { font-size: 15px; font-weight: 700; color: #1f2933; font-variant-numeric: tabular-nums; }
.sb-dialog-group-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.sb-dialog-choice {
    flex: 1 1 0;
    min-width: 92px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 10px;
    border-radius: 9px;
    border: 1px solid #dcdcdc;
    background: #fff;
    color: #1f2933;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background .15s ease, border-color .15s ease;
}
.sb-dialog-choice:hover { background: var(--sb-tone-soft); border-color: var(--sb-tone); }
.sb-dialog-choice.primary { background: var(--sb-tone); border-color: var(--sb-tone); color: #fff; }
.sb-dialog-choice.primary:hover { filter: brightness(.92); }
.sb-dialog-choice:focus-visible { outline: 3px solid var(--sb-tone-soft); outline-offset: 2px; }
.sb-dialog-choice .fa-viber { color: #7360f2; }
.sb-dialog-choice.primary .fa-viber { color: #fff; }
