/**
 * UX İyileştirmeleri CSS
 * Toast, Loading, Form Validation, Dark Mode
 */

/* ===== TOAST NOTIFICATIONS ===== */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
}

.toast {
    background: var(--white);
    color: var(--secondary);
    padding: 16px 20px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    opacity: 0;
    transform: translateX(400px);
    transition: all 0.3s ease;
    position: relative;
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.toast-message {
    flex: 1;
    font-size: 14px;
    line-height: 1.5;
}

.toast-close {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--secondary);
    opacity: 0.5;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
}

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

.toast-success {
    border-left: 4px solid #22c55e;
}

.toast-success .toast-icon {
    color: #22c55e;
}

.toast-error {
    border-left: 4px solid #ef4444;
}

.toast-error .toast-icon {
    color: #ef4444;
}

.toast-warning {
    border-left: 4px solid #f59e0b;
}

.toast-warning .toast-icon {
    color: #f59e0b;
}

.toast-info {
    border-left: 4px solid #3b82f6;
}

.toast-info .toast-icon {
    color: #3b82f6;
}

/* Dark Mode Toast - ŞİMDİLİK YORUM SATIRINA ALINDI */
/*
.dark-mode .toast {
    background: #1e293b;
    color: var(--offWhite);
}

.dark-mode .toast-close {
    color: var(--offWhite);
}
*/

/* ===== LOADING ANIMATIONS ===== */
.full-page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(14, 20, 34, 0.95);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
}

.loader-content {
    text-align: center;
    color: var(--white);
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

.loader-text {
    font-size: 16px;
    font-family: var(--font-urbanist);
}

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

/* Button Loading */
button.loading,
.btn.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

button.loading i.fa-spinner,
.btn.loading i.fa-spinner {
    animation: spin 1s linear infinite;
}

/* Form Loading */
form.loading {
    pointer-events: none;
    opacity: 0.7;
}

/* ===== FORM VALIDATION ===== */
.form-group {
    position: relative;
    margin-bottom: 20px;
}

input.error,
textarea.error,
select.error {
    border-color: #ef4444 !important;
    background-color: rgba(239, 68, 68, 0.1);
}

input.valid,
textarea.valid,
select.valid {
    border-color: #22c55e !important;
}

.field-error {
    color: #ef4444;
    font-size: 12px;
    margin-top: 5px;
    display: block;
    animation: slideDown 0.3s ease;
}

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

/* ===== DARK MODE ===== */
/* ŞİMDİLİK YORUM SATIRINA ALINDI */
/*
.dark-mode-toggle {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--white);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    margin-left: 0;
    margin-right: 0;
    flex-shrink: 0;
}

#dark-mode-toggle-container {
    display: flex;
    align-items: center;
}

.dark-mode-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

/* Dark Mode Variables */
:root {
    --bg-primary: var(--secondary);
    --bg-secondary: #131732;
    --text-primary: var(--offWhite);
    --text-secondary: rgba(251, 251, 251, 0.7);
}

.dark-mode {
    --bg-primary: #0a0e1a;
    --bg-secondary: #131732;
    --text-primary: #f1f5f9;
    --text-secondary: rgba(241, 245, 249, 0.7);
}

.dark-mode body {
    background: var(--bg-primary);
    color: var(--text-primary);
}

.dark-mode .header-area {
    background: rgba(10, 14, 26, 0.95);
}

.dark-mode .card,
.dark-mode .stat-card {
    background: var(--bg-secondary);
    border-color: rgba(255, 255, 255, 0.1);
}

.dark-mode input,
.dark-mode textarea,
.dark-mode select {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: rgba(255, 255, 255, 0.2);
}

.dark-mode input:focus,
.dark-mode textarea:focus,
.dark-mode select:focus {
    border-color: var(--primary);
}
*/

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .toast-container {
        left: 20px;
        right: 20px;
        max-width: none;
    }
    
    .toast {
        min-width: auto;
    }
    
    /* .dark-mode-toggle {
        width: 35px;
        height: 35px;
        font-size: 14px;
    } */
}




