/* Authentication Error Handling Styles */

/* Django form errors - errorlist styling */
.errorlist {
    list-style: none;
    padding: 0;
    margin: 4px 0 0 0;
}

.errorlist li {
    color: #e53e3e;
    font-size: 13px;
}

/* Error animation - fades out and collapses */
.errorlist.hiding {
    animation: fadeOutError 0.5s ease-out forwards !important;
}

@keyframes fadeOutError {
    0% {
        opacity: 1;
        margin: 4px 0 0 0;
        height: auto;
    }
    100% {
        opacity: 0;
        margin: 0 !important;
        padding: 0 !important;
        height: 0 !important;
        line-height: 0 !important;
        font-size: 0 !important;
        border: none !important;
        visibility: hidden !important;
        display: none !important;
    }
}

/* Alert messages styling */
.alert {
    margin-bottom: 20px;
    font-size: 13px;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
}

.alert-danger,
.alert-error {
    background: transparent;
    color: #e53e3e;
    border: none;
}

.alert-success {
    background: transparent;
    color: #10b981;
    border: none;
}

.alert-info {
    background: transparent;
    color: #2563eb;
    border: none;
}

/* Real-time field validation errors */
.field-error {
    font-size: 12px;
    color: #e53e3e;
    margin-top: 4px;
    display: none;
    min-height: 18px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.field-error.show {
    display: flex;
}

.field-error-icon {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.field-error-icon i {
    font-size: 14px;
    color: #e53e3e;
}

.field-error-text {
    flex: 1;
}

.form-control.has-error {
    border-color: #e53e3e;
}

input.is-invalid {
    border-color: #fc8181;
}
