.flash-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 1050;
    width: 350px; /* Increased width slightly */
}

.alert {
    border-radius: 8px;
    padding: 16px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border: none;
    display: flex;
    align-items: center;
}

/* Icon styling */
.alert::before {
    content: '';
    display: inline-block;
    width: 24px;
    height: 24px;
    margin-right: 12px;
    flex-shrink: 0;
}

/* Success styles */
.alert-success {
    background-color: #F0FDF4; /* Lighter green */
    color: #14532D; /* Darker green text */
}

.alert-success::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor' class='w-6 h-6'%3E%3Cpath fill-rule='evenodd' d='M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zm13.36-1.814a.75.75 0 10-1.22-.872l-3.236 4.53L9.53 12.22a.75.75 0 00-1.06 1.06l2.25 2.25a.75.75 0 001.14-.094l3.75-5.25z' clip-rule='evenodd' /%3E%3C/svg%3E%0A");
    filter: invert(25%) sepia(27%) saturate(1488%) hue-rotate(105deg) brightness(93%) contrast(94%);
}

/* Danger styles */
.alert-danger {
    background-color: #FEF2F2; /* Lighter red */
    color: #991B1B; /* Darker red text */
}

.alert-danger::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor' class='w-6 h-6'%3E%3Cpath fill-rule='evenodd' d='M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zm8.706-1.442c1.146 0 2.083.937 2.083 2.083s-.937 2.083-2.083 2.083-2.083-.937-2.083-2.083.937-2.083 2.083-2.083zM10.294 5.083a.75.75 0 01.75.75v3.5a.75.75 0 01-1.5 0v-3.5a.75.75 0 01.75-.75z' clip-rule='evenodd' /%3E%3C/svg%3E%0A");
    filter: invert(22%) sepia(48%) saturate(2493%) hue-rotate(339deg) brightness(94%) contrast(90%);
}

.alert .btn-close {
    filter: invert(25%) opacity(50%);
}


/* Animations */
.alert.slide-in {
    animation: slideInRight 0.4s ease-out forwards;
}

.alert.slide-out {
    animation: slideOutRight 0.4s ease-in forwards;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}