/* ChronosNotification Widget Styles */

/* Toast enhancements */
.toast-container {
    max-width: 100vw;
    padding: 1rem;
}

.toast {
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    border-radius: 0.5rem;
    overflow: hidden;
}

.toast-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    font-weight: 600;
}

.toast-body {
    font-size: 0.875rem;
    line-height: 1.4;
}

/* Success toasts */
.toast.bg-success .toast-header {
    background-color: rgba(25, 135, 84, 0.9);
    color: white;
}

.toast.bg-success .btn-close {
    filter: invert(1);
}

/* Error/Danger toasts */
.toast.bg-danger .toast-header {
    background-color: rgba(220, 53, 69, 0.9);
    color: white;
}

.toast.bg-danger .btn-close {
    filter: invert(1);
}

/* Warning toasts */
.toast.bg-warning .toast-header {
    background-color: rgba(255, 193, 7, 0.9);
    color: var(--bs-dark);
}

/* Info toasts */
.toast.bg-info .toast-header {
    background-color: rgba(13, 202, 240, 0.9);
    color: white;
}

.toast.bg-info .btn-close {
    filter: invert(1);
}

/* Modal error styling */
.chronos-modal-error {
    animation: slideInDown 0.3s ease-out;
    border-left: 4px solid var(--bs-danger);
}

.chronos-modal-error .alert-heading {
    font-weight: 600;
    font-size: 1rem;
    display: flex;
    align-items: center;
}

.chronos-modal-error .alert-content {
    font-size: 0.875rem;
    line-height: 1.5;
}

/* Animation for modal errors */
@keyframes slideInDown {
    0% {
        transform: translateY(-20px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .toast-container {
        padding: 0.5rem;
        right: 0.5rem !important;
        left: 0.5rem !important;
        top: 0.5rem !important;
    }
    
    .toast {
        max-width: none;
        width: 100%;
    }
}

/* Dark mode support */
[data-bs-theme="dark"] .chronos-modal-error {
    background-color: rgba(220, 53, 69, 0.1);
    border-color: rgba(220, 53, 69, 0.3);
    color: #f8d7da;
}

[data-bs-theme="dark"] .chronos-modal-error .alert-heading {
    color: #f8d7da;
}

/* Integration with existing error summary */
.chronos-modal-error + .errorSummary,
.errorSummary + .chronos-modal-error {
    margin-top: 0.5rem;
}

/* Ensure proper z-index stacking */
.toast-container {
    z-index: 1060; /* Above modals (1055) but below tooltips (1070) */
}
