/* SweetAlert2 Custom Styling for Theme Consistency (Sharp Corners) */
.swal2-popup {
    background-color: var(--card-bg) !important;
    color: var(--text-main) !important;
    border: 1px solid var(--border) !important;
    border-radius: 0 !important;
    /* Tetap sudut kaku/kotak */
    animation: none !important;
    /* Disable animations */
}

.swal2-show,
.swal2-hide {
    animation: none !important;
    /* Force no animation on show/hide */
}

.swal2-title {
    color: var(--text-main) !important;
}

.swal2-html-container {
    color: var(--text-muted) !important;
}

.swal2-confirm {
    background-color: var(--primary) !important;
    border-radius: 0 !important;
    /* Tetap sudut kaku/kotak */
    padding: 10px 24px !important;
    /* Kembali ke skala semula */
}

.swal2-confirm:hover {
    background-color: var(--primary-light) !important;
    /* Warna sedikit lebih terang saat hover */
}

.swal2-confirm.btn-danger {
    background-color: #d33 !important;
}

.swal2-confirm.btn-danger:hover {
    background-color: #be123c !important;
}

.swal2-cancel {
    border-radius: 0 !important;
    /* Tetap sudut kaku/kotak */
    padding: 10px 24px !important;
    /* Kembali ke skala semula */
}

/* Dark mode overrides for SweetAlert */
[data-theme="dark"] .swal2-popup {
    background-color: #24262d !important;
    border-color: #3f4354 !important;
}

/* Styling progress bar toast (Garis di bawah yang berkurang) */
.swal2-popup.swal2-toast {
    overflow: hidden !important;
    /* Agar progress bar tidak keluar dari kotak */
}

.swal2-timer-progress-bar-container {
    height: 3px !important;
    width: 100% !important;
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    background: rgba(0, 0, 0, 0.05) !important;
    z-index: 99 !important;
}

.swal2-timer-progress-bar {
    height: 3px !important;
    background-color: var(--primary) !important;
    /* Animasi diatur oleh SweetAlert2, sekarang sudah aktif karena fix di style.css */
}

/* Warna progress bar sesuai tipe */
.swal2-toast.swal2-icon-success .swal2-timer-progress-bar {
    background-color: var(--success) !important;
}

.swal2-toast.swal2-icon-error .swal2-timer-progress-bar {
    background-color: var(--danger) !important;
}

.swal2-toast.swal2-icon-warning .swal2-timer-progress-bar {
    background-color: var(--warning) !important;
}

.swal2-toast.swal2-icon-info .swal2-timer-progress-bar {
    background-color: #3fc3ee !important;
}