.flash {
    padding: 10px 15px;
    margin-bottom: 15px;
    border-radius: 4px;
    font-size: 14px; 
    color: #DA9100;
    background-color: #355E3B;
    border: 1px solid #2F4F32;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    opacity: 0;
    animation: fadeIn 0.5s forwards;
    position: fixed; /* Changed from relative to fixed */
    top: 20px; /* Position at top of viewport */
    left: 50%; /* Center horizontally */
    transform: translateX(-50%); /* Center adjustment */
    z-index: 9999; /* Very high z-index to be above all modals */
    min-width: 250px;
    max-width: 80%;
    text-align: center;
    transition: all 0.3s ease-in-out;
}

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

.flash.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

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

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

.flash:hover {
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15);
}

/* Stack multiple flash messages */
.flash + .flash {
    margin-top: 60px;
}

/* Rest of your animations remain the same */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -20px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translate(-50%, 0);
    }
    to {
        opacity: 0;
        transform: translate(-50%, -20px);
    }
}

.flash.fade-out {
    animation: fadeOut 0.5s forwards;
}
