/* alert uses site font */
.alert-overlay, .alert-box, .alert-box * { font-family: 'Vazirmatn', sans-serif !important; }
/* ============================================
   کارشیو | Alert / Confirm / Toast System
   ============================================ */

.alert-overlay {
    position: fixed;
    inset: 0;
    background: rgba(13, 71, 161, 0.45);
    z-index: 9990;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s ease;
}

.alert-overlay.show {
    opacity: 1;
    visibility: visible;
}

.alert-box {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 360px;
    padding: 1.75rem 1.5rem 1.5rem;
    text-align: center;
    box-shadow: 0 12px 40px rgba(13, 71, 161, 0.25);
    transform: scale(0.85) translateY(20px);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.alert-overlay.show .alert-box {
    transform: scale(1) translateY(0);
}

.alert-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.1rem;
    font-size: 1.8rem;
}

.alert-icon.success {
    background: #e8f5e9;
    color: #2e7d32;
}

.alert-icon.error {
    background: #ffebee;
    color: #c62828;
}

.alert-icon.warning {
    background: #fff8e1;
    color: #f9a825;
}

.alert-icon.info {
    background: #e3f2fd;
    color: #1565c0;
}

.alert-icon.confirm {
    background: #e3f2fd;
    color: #0d47a1;
}

.alert-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1a237e;
    margin-bottom: 0.5rem;
}

.alert-message {
    font-size: 0.95rem;
    color: #546e7a;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.alert-actions {
    display: flex;
    gap: 0.75rem;
}

.alert-actions .btn {
    flex: 1;
    padding: 0.8rem;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.alert-btn-confirm {
    background: #1565c0;
    color: white;
}

.alert-btn-confirm:hover {
    background: #0d47a1;
}

.alert-btn-cancel {
    background: #f5f5f5;
    color: #546e7a;
}

.alert-btn-cancel:hover {
    background: #e0e0e0;
}

.alert-btn-ok {
    background: #1565c0;
    color: white;
    width: 100%;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: calc(56px + 0.75rem);
    left: 0;
    right: 0;
    z-index: 9980;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    pointer-events: none;
    padding: 0 1rem;
}

.toast {
    background: white;
    border-radius: 12px;
    padding: 0.85rem 1.15rem;
    box-shadow: 0 6px 20px rgba(13, 71, 161, 0.18);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 280px;
    max-width: 400px;
    width: 100%;
    pointer-events: auto;
    transform: translateY(-20px);
    opacity: 0;
    transition: all 0.3s ease;
    border-right: 4px solid #1565c0;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

.toast.success { border-right-color: #2e7d32; }
.toast.error { border-right-color: #c62828; }
.toast.warning { border-right-color: #f9a825; }
.toast.info { border-right-color: #0288d1; }

.toast-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.toast.success .toast-icon { color: #2e7d32; }
.toast.error .toast-icon { color: #c62828; }
.toast.warning .toast-icon { color: #f9a825; }
.toast.info .toast-icon { color: #0288d1; }

.toast-body {
    flex: 1;
    font-size: 0.9rem;
    color: #1a237e;
    font-weight: 500;
}

.toast-close {
    background: none;
    border: none;
    color: #90a4ae;
    cursor: pointer;
    font-size: 1rem;
    padding: 0.25rem;
}

.toast-close:hover {
    color: #546e7a;
}
