/* Inline Notifications CSS */

.notification-container {
    position: relative;
    margin: 0.5rem 0;
}

.notification-message {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    margin: 0.5rem 0;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.notification-message.show {
    opacity: 1;
    transform: translateY(0);
}

.notification-message.hide {
    opacity: 0;
    transform: translateY(-10px);
}

/* Success Messages */
.notification-message.success {
    background-color: #d1eddd;
    border: 1px solid #badbcc;
    color: #155724;
}

.notification-message.success .notification-icon {
    background-color: #28a745;
}

/* Error Messages */
.notification-message.error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.notification-message.error .notification-icon {
    background-color: #dc3545;
}

/* Warning Messages */
.notification-message.warning {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

.notification-message.warning .notification-icon {
    background-color: #ffc107;
}

/* Info Messages */
.notification-message.info {
    background-color: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.notification-message.info .notification-icon {
    background-color: #17a2b8;
}

/* Icon Styles */
.notification-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    margin-right: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.notification-icon::after {
    color: white;
    font-weight: bold;
    font-size: 12px;
}

.notification-message.success .notification-icon::after {
    content: "✓";
}

.notification-message.error .notification-icon::after {
    content: "✕";
}

.notification-message.warning .notification-icon::after {
    content: "⚠";
}

.notification-message.info .notification-icon::after {
    content: "i";
}

/* Close Button */
.notification-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: inherit;
    opacity: 0.7;
    padding: 0 0.25rem;
    transition: opacity 0.2s ease;
}

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

/* Field Error Messages (for form fields) */
.field-error {
    display: block;
    color: #721c24;
    font-size: 0.8rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    padding: 0.5rem 0.75rem;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 0.375rem;
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.3s ease;
    position: relative;
    z-index: 10;
    width: 100%;
    box-sizing: border-box;
}

.field-error.show {
    opacity: 1;
    transform: translateY(0);
}

.field-error::before {
    content: "⚠ ";
    margin-right: 0.25rem;
    color: #dc3545;
}

/* Phone input container özel düzenleme - Field error altında görünmeli */
.position-relative.d-flex + .field-error {
    margin-top: 0.5rem;
    clear: both;
    width: 100%;
    display: block;
}

/* Input group içindeki field error */
.input-group + .field-error {
    margin-top: 0.5rem;
    width: 100%;
    display: block;
}

/* Register page phone input düzenlemesi - Alt satırda */
.register-phone + .field-error {
    margin-top: 0.5rem;
    margin-left: 0;
    width: 100%;
    display: block;
}

/* D-flex container sonrasında field error */
.d-flex + .field-error {
    margin-top: 0.5rem;
    width: 100%;
    display: block;
    clear: both;
}

/* Responsive field error */
@media (max-width: 768px) {
    .field-error {
        font-size: 0.75rem;
        padding: 0.4rem 0.6rem;
    }
}

/* Input Error State */
.form-control.error {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

.form-control.success {
    border-color: #28a745;
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
}

/* Loading State */
.notification-loading {
    background-color: #e7f3ff;
    border: 1px solid #b3d7ff;
    color: #004085;
}

.notification-loading .notification-icon {
    background-color: #007bff;
    animation: spin 1s linear infinite;
}

.notification-loading .notification-icon::after {
    content: "⟳";
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .notification-message {
        padding: 0.6rem 0.8rem;
        font-size: 0.85rem;
    }
    
    .notification-icon {
        width: 18px;
        height: 18px;
        margin-right: 0.5rem;
    }
}

/* Animation Classes */
.shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-3px); }
    20%, 40%, 60%, 80% { transform: translateX(3px); }
}

.bounce-in {
    animation: bounceIn 0.6s ease-out;
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}