/**
 * Professional Toast Notification Styles
 * Beautiful, animated toast notifications
 */

/* Toast Container */
#toast-container {
    z-index: 9999;
    pointer-events: none;
}

#toast-container .toast {
    pointer-events: auto;
    min-width: 300px;
    max-width: 500px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    margin-bottom: 1rem;
    overflow: hidden;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Toast Animation - Slide In */
#toast-container .toast.toast-slide-in {
    opacity: 1;
    transform: translateX(0);
}

/* Toast Animation - Slide Out */
#toast-container .toast.toast-slide-out {
    opacity: 0;
    transform: translateX(100%);
}

/* Toast Body */
#toast-container .toast-body {
    padding: 1rem 1.25rem;
    font-size: 0.95rem;
    font-weight: 500;
    display: flex;
    align-items: center;
}

#toast-container .toast-body i {
    font-size: 1.2rem;
}

/* Toast Close Button */
#toast-container .btn-close {
    opacity: 0.8;
}

#toast-container .btn-close:hover {
    opacity: 1;
}

/* Toast Types - Enhanced Colors with Gradients */
#toast-container .toast.bg-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

#toast-container .toast.bg-error,
#toast-container .toast.bg-danger {
    background: linear-gradient(135deg, #dc3545 0%, #e74c3c 100%) !important;
}

#toast-container .toast.bg-warning {
    background: linear-gradient(135deg, #ffc107 0%, #f39c12 100%) !important;
}

#toast-container .toast.bg-info {
    background: linear-gradient(135deg, #17a2b8 0%, #20c997 100%) !important;
}

/* Toast Hover Effect */
#toast-container .toast:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
}

/* Confirmation Modal Styling */
.modal-content {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.modal-header {
    border-bottom: none;
    padding: 1.5rem 1.5rem 0.5rem;
}

.modal-body {
    padding: 1rem 1.5rem;
    font-size: 1.05rem;
}

.modal-footer {
    border-top: none;
    padding: 0.5rem 1.5rem 1.5rem;
}

/* Modal Animation */
.modal.fade .modal-dialog {
    transform: scale(0.8) translateY(-50px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.modal.show .modal-dialog {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* Modal Buttons */
.modal-footer .btn {
    border-radius: 8px;
    padding: 0.5rem 1.5rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.modal-footer .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Responsive Design */
@media (max-width: 576px) {
    #toast-container {
        left: 0.5rem;
        right: 0.5rem;
    }

    #toast-container .toast {
        min-width: auto;
        width: 100%;
    }

    .modal-dialog {
        margin: 0.5rem;
    }
}

/* Progress Bar for Auto-Dismiss (Optional Enhancement) */
#toast-container .toast.with-progress::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.5);
    animation: progress-bar 4s linear forwards;
}

@keyframes progress-bar {
    from {
        width: 100%;
    }
    to {
        width: 0%;
    }
}

/* Loading Spinner for Toast (if needed) */
.toast-spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spinner-rotation 0.8s linear infinite;
    margin-right: 0.5rem;
}

@keyframes spinner-rotation {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}
