/* Alert Container */
.alert-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
}

/* Alert Box */
.custom-alert {
    padding: 16px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    animation: slideIn 0.3s ease-out;
    position: relative;
    overflow: hidden;
}

.custom-alert::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
}

/* Alert Types */
.alert-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-success::before {
    background: #28a745;
}

.alert-danger,
.alert-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.alert-danger::before,
.alert-error::before {
    background: #dc3545;
}

.alert-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

.alert-warning::before {
    background: #ffc107;
}

.alert-info {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.alert-info::before {
    background: #17a2b8;
}

/* Alert Icon */
.alert-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.alert-icon svg {
    width: 24px;
    height: 24px;
}

/* Alert Content */
.alert-content {
    flex: 1;
}

.alert-content .alert-title {
    font-weight: 600;
    margin-bottom: 4px;
    font-size: 15px;
}

.alert-content .alert-message {
    font-size: 14px;
    line-height: 1.5;
}

/* Close Button */
.alert-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    margin-left: 8px;
    opacity: 0.6;
    transition: opacity 0.2s;
    flex-shrink: 0;
}

.alert-close:hover {
    opacity: 1;
}

.alert-close svg {
    width: 20px;
    height: 20px;
}

/* Animations */
@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

.alert-closing {
    animation: slideOut 0.3s ease-out forwards;
}

/* Responsive */
@media (max-width: 768px) {
    .alert-container {
        left: 20px;
        right: 20px;
        max-width: none;
    }

    @keyframes slideIn {
        from {
            transform: translateY(-100px);
            opacity: 0;
        }
        to {
            transform: translateY(0);
            opacity: 1;
        }
    }

    @keyframes slideOut {
        from {
            transform: translateY(0);
            opacity: 1;
        }
        to {
            transform: translateY(-100px);
            opacity: 0;
        }
    }
}