/* em-dialog — modal konfirmasi/alert + toast gaya SweetAlert (offline, selaras app-shell). */
.em-dialog-overlay {
    position: fixed; inset: 0; z-index: 2000;
    display: flex; align-items: center; justify-content: center;
    background: rgba(16, 24, 40, .45);
    opacity: 0; transition: opacity .16s ease;
    padding: 16px;
}
.em-dialog-overlay.show { opacity: 1; }

.em-dialog {
    background: #fff; border-radius: 16px; width: 100%; max-width: 380px;
    padding: 26px 24px 20px; text-align: center;
    box-shadow: 0 20px 60px rgba(16, 24, 40, .28);
    transform: translateY(8px) scale(.96); transition: transform .18s cubic-bezier(.2, .9, .3, 1.2);
}
.em-dialog-overlay.show .em-dialog { transform: none; }

.em-dialog-icon {
    width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 28px; font-weight: 700; line-height: 1;
}
.em-dialog-icon.is-question { background: #e7f0ff; color: #2563c9; }
.em-dialog-icon.is-warning  { background: #fef3e6; color: #f0820c; }
.em-dialog-icon.is-error    { background: #fde8e8; color: #d92d20; }
.em-dialog-icon.is-success  { background: #e7f5ee; color: #1e9e6a; }
.em-dialog-icon.is-info     { background: #eef0f4; color: #475467; }

.em-dialog-title { font-size: 1.12rem; font-weight: 700; color: #101828; margin-bottom: 6px; }
.em-dialog-text  { color: #475467; font-size: .94rem; line-height: 1.5; margin-bottom: 20px; white-space: pre-line; }
.em-dialog-actions { display: flex; gap: 10px; justify-content: center; }
.em-dialog-actions .btn { min-width: 104px; }

/* Input (mode prompt) */
.em-dialog-input {
    width: 100%; margin: 2px 0 18px; padding: 10px 12px;
    border: 1px solid var(--app-border, #d0d5dd); border-radius: 10px;
    font-size: .95rem; color: #101828; outline: none; text-align: left;
    transition: border-color .12s ease, box-shadow .12s ease;
}
.em-dialog-input:focus { border-color: var(--app-accent, #2563c9); box-shadow: 0 0 0 3px rgba(37, 99, 201, .15); }
.em-dialog-input.is-invalid { border-color: #d92d20; box-shadow: 0 0 0 3px rgba(217, 45, 32, .14); }

/* Toast */
.em-toast {
    position: fixed; top: 18px; right: 18px; z-index: 2100;
    display: flex; align-items: center; gap: 9px;
    background: #fff; border-radius: 12px; padding: 11px 16px;
    box-shadow: 0 10px 30px rgba(16, 24, 40, .18); border: 1px solid var(--app-border, #eaecf0);
    font-size: .9rem; color: #101828; max-width: 360px;
    transform: translateX(120%); opacity: 0; transition: transform .26s ease, opacity .26s ease;
}
.em-toast.show { transform: none; opacity: 1; }
.em-toast-ic {
    width: 22px; height: 22px; border-radius: 50%; flex: 0 0 22px;
    display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: #fff;
}
.em-toast-success .em-toast-ic { background: #1e9e6a; }
.em-toast-error .em-toast-ic   { background: #d92d20; }
.em-toast-info .em-toast-ic    { background: #475467; }
