/* Dokunmatik Ekranlar İçin Modern Renkli Tasarım */

:root {
    --touch-target-size: 56px;
    
    /* Modern Renk Paleti - Canlı ama Sade */
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    
    --secondary-color: #8b5cf6;
    --secondary-dark: #7c3aed;
    
    --success-color: #10b981;
    --success-dark: #059669;
    
    --danger-color: #ef4444;
    --danger-dark: #dc2626;
    
    --warning-color: #f59e0b;
    --warning-dark: #d97706;
    
    --info-color: #06b6d4;
    --info-dark: #0891b2;
    
    --background: #f8fafc;
    --surface: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* Genel Ayarlar */
* {
    -webkit-tap-highlight-color: transparent;
    box-sizing: border-box;
}

body {
    font-size: 16px;
    line-height: 1.6;
    touch-action: manipulation;
    background: var(--background);
    color: var(--text-primary);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Dokunmatik Butonlar - Renkli ve Büyük */
.touch-button {
    min-height: var(--touch-target-size);
    min-width: var(--touch-target-size);
    padding: 14px 28px;
    font-size: 18px;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
    border: none;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.touch-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.touch-button:active::before {
    width: 300px;
    height: 300px;
}

.touch-button:active {
    transform: scale(0.96);
    box-shadow: var(--shadow-sm);
}

.btn-lg.touch-button {
    min-height: 64px;
    font-size: 20px;
    padding: 18px 36px;
    border-radius: 14px;
}

.btn-primary.touch-button {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

.btn-primary.touch-button:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
    transform: translateY(-2px);
}

.btn-success.touch-button {
    background: linear-gradient(135deg, var(--success-color) 0%, var(--success-dark) 100%);
    color: white;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.btn-success.touch-button:hover {
    background: linear-gradient(135deg, var(--success-dark) 0%, var(--success-color) 100%);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
    transform: translateY(-2px);
}

.btn-danger.touch-button {
    background: linear-gradient(135deg, var(--danger-color) 0%, var(--danger-dark) 100%);
    color: white;
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.4);
}

.btn-danger.touch-button:hover {
    background: linear-gradient(135deg, var(--danger-dark) 0%, var(--danger-color) 100%);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.5);
    transform: translateY(-2px);
}

.btn-warning.touch-button {
    background: linear-gradient(135deg, var(--warning-color) 0%, var(--warning-dark) 100%);
    color: white;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
}

.btn-warning.touch-button:hover {
    background: linear-gradient(135deg, var(--warning-dark) 0%, var(--warning-color) 100%);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.5);
    transform: translateY(-2px);
}

.btn-secondary.touch-button {
    background: linear-gradient(135deg, var(--text-secondary) 0%, #475569 100%);
    color: white;
}

/* Dokunmatik Input Alanları */
.touch-input {
    min-height: var(--touch-target-size);
    font-size: 18px;
    padding: 14px 18px;
    border-radius: 12px;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
    background: var(--surface);
    color: var(--text-primary);
}

.touch-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
    outline: none;
    background: white;
}

.form-control-lg.touch-input {
    min-height: 64px;
    font-size: 20px;
    padding: 18px 22px;
    border-radius: 14px;
}

/* Dokunmatik Checkbox */
.touch-checkbox {
    width: 28px;
    height: 28px;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    border: 3px solid var(--border-color);
    border-radius: 6px;
    position: relative;
    transition: all 0.3s ease;
    background: var(--surface);
}

.touch-checkbox:checked {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-color: var(--primary-color);
}

.touch-checkbox:checked::after {
    content: '\2713';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 18px;
    font-weight: bold;
}

/* Dokunmatik Kartlar */
.touch-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    cursor: pointer;
    background: var(--surface);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
}

.touch-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-light);
}

.touch-card:active {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* Login Sayfası - Renkli Gradient */
.login-container {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.login-container::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: moveBackground 20s linear infinite;
}

@keyframes moveBackground {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

.login-container .card {
    border-radius: 24px;
    backdrop-filter: blur(20px);
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.3);
    position: relative;
    z-index: 1;
}

/* Navbar - Renkli Gradient */
.navbar {
    min-height: 70px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%) !important;
    box-shadow: var(--shadow-lg);
    border: none;
}

.navbar-brand,
.nav-link {
    font-size: 18px;
    padding: 14px 18px !important;
    font-weight: 500;
}

.nav-link {
    min-height: var(--touch-target-size);
    display: flex;
    align-items: center;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(4px);
}

/* Tablo - Modern ve Renkli */
.table {
    font-size: 16px;
    background: var(--surface);
    border-radius: 12px;
    overflow: hidden;
}

.table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%) !important;
    color: white !important;
}

.table thead th {
    color: white !important;
    border: none !important;
}

.table th {
    font-size: 18px;
    font-weight: 600;
    padding: 18px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 14px;
}

.table td {
    padding: 18px;
    vertical-align: middle;
    border-bottom: 1px solid var(--border-color);
}

.table tbody tr {
    transition: all 0.2s ease;
}

.table tbody tr:hover {
    background: rgba(99, 102, 241, 0.05);
    transform: scale(1.01);
}

.table .btn-sm {
    min-height: 44px;
    min-width: 44px;
    padding: 10px 14px;
    border-radius: 10px;
}

/* Form Label */
.form-label {
    font-size: 18px;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-primary);
}

/* Alert - Renkli ve Modern */
.alert {
    font-size: 16px;
    padding: 18px 24px;
    border-radius: 12px;
    border: none;
    box-shadow: var(--shadow-md);
    font-weight: 500;
}

.alert-success {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(16, 185, 129, 0.05) 100%);
    color: var(--success-dark);
    border-left: 4px solid var(--success-color);
}

.alert-danger {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(239, 68, 68, 0.05) 100%);
    color: var(--danger-dark);
    border-left: 4px solid var(--danger-color);
}

.alert-dismissible .btn-close {
    width: 36px;
    height: 36px;
    border-radius: 8px;
}

/* Card - Modern ve Renkli */
.card {
    border-radius: 16px;
    border: none;
    box-shadow: var(--shadow-lg);
    background: var(--surface);
    overflow: hidden;
    transition: all 0.3s ease;
}

.card:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-4px);
}

.card-header {
    border-radius: 16px 16px 0 0 !important;
    padding: 24px;
    font-size: 20px;
    font-weight: 600;
    border: none;
}

.card-header.bg-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%) !important;
}

.card-header.bg-success {
    background: linear-gradient(135deg, var(--success-color) 0%, var(--success-dark) 100%) !important;
}

.card-header.bg-warning {
    background: linear-gradient(135deg, var(--warning-color) 0%, var(--warning-dark) 100%) !important;
}

.card-body {
    padding: 28px;
}

/* Badge - Renkli */
.badge {
    font-size: 14px;
    padding: 10px 14px;
    border-radius: 8px;
    font-weight: 600;
}

.badge.bg-success {
    background: linear-gradient(135deg, var(--success-color) 0%, var(--success-dark) 100%) !important;
}

.badge.bg-danger {
    background: linear-gradient(135deg, var(--danger-color) 0%, var(--danger-dark) 100%) !important;
}

/* Footer */
.footer {
    margin-top: auto;
    padding: 24px;
    font-size: 16px;
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    border-top: 1px solid var(--border-color);
}

/* Main Content */
.main-content {
    min-height: calc(100vh - 200px);
    padding: 24px;
    background: var(--background);
}

/* Sidebar - Renkli Gradient */
.sidebar {
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100vh;
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    z-index: 1050;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.sidebar.active {
    left: 0;
}

.sidebar-header {
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    min-height: 70px;
    background: rgba(0, 0, 0, 0.1);
}

.sidebar-header h4 {
    color: white;
    margin: 0;
    font-size: 22px;
    font-weight: 700;
}

.sidebar-header button {
    color: white;
    font-size: 22px;
    min-width: 44px;
    min-height: 44px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.sidebar-header button:hover {
    background: rgba(255, 255, 255, 0.2);
}

.sidebar-user-info {
    padding: 24px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.15);
}

.user-avatar {
    margin-bottom: 12px;
}

.user-avatar i {
    color: rgba(255, 255, 255, 0.9);
}

.user-details {
    color: white;
}

.user-details strong {
    display: block;
    font-size: 18px;
    margin-bottom: 6px;
    font-weight: 600;
}

.sidebar-menu {
    flex: 1;
    padding: 12px 0;
    overflow-y: auto;
}

.sidebar-menu .nav {
    padding: 0;
}

.sidebar-menu .nav-item {
    margin: 6px 12px;
}

.sidebar-menu .nav-link {
    color: rgba(255, 255, 255, 0.9);
    padding: 18px 24px;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 18px;
    min-height: 60px;
    display: flex;
    align-items: center;
    text-decoration: none;
    font-weight: 500;
}

.sidebar-menu .nav-link:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    transform: translateX(8px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.sidebar-menu .nav-link.active {
    background: rgba(255, 255, 255, 0.3);
    color: white;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.sidebar-menu .nav-link i {
    width: 28px;
    text-align: center;
    font-size: 20px;
}

/* Sidebar Overlay */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Main Wrapper */
.main-wrapper {
    transition: margin-left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--background);
}

.main-wrapper.sidebar-open {
    margin-left: 0;
}

/* Navbar Toggle Button */
#sidebarToggleBtn {
    min-width: 56px;
    min-height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    border-radius: 12px;
    transition: all 0.3s ease;
}

#sidebarToggleBtn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: scale(1.1);
}

/* Input Group */
.input-group .btn {
    min-height: var(--touch-target-size);
    min-width: var(--touch-target-size);
    border-radius: 12px;
}

.input-group .form-control-lg + .btn {
    min-height: 64px;
    min-width: 64px;
    border-radius: 14px;
}

/* Dropdown */
.dropdown-item {
    font-size: 16px;
    padding: 14px 24px;
    min-height: var(--touch-target-size);
    display: flex;
    align-items: center;
    border-radius: 8px;
    margin: 4px 8px;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background: rgba(99, 102, 241, 0.1);
    transform: translateX(4px);
}

/* Responsive Sidebar */
@media (min-width: 992px) {
    .sidebar {
        left: 0;
    }
    
    .main-wrapper {
        margin-left: 280px;
    }
    
    .sidebar-header button {
        display: none;
    }
    
    .sidebar-overlay {
        display: none;
    }
    
    #sidebarToggleBtn {
        display: none;
    }
}

@media (max-width: 991px) {
    .sidebar {
        left: -280px;
    }
    
    .sidebar.active {
        left: 0;
    }
    
    .main-wrapper {
        margin-left: 0;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .touch-button {
        width: 100%;
        margin-bottom: 12px;
    }
    
    .table-responsive {
        font-size: 14px;
    }
    
    .table th,
    .table td {
        padding: 14px 10px;
    }
    
    .card-body {
        padding: 20px;
    }
    
    .main-content {
        padding: 16px;
    }
}

/* Animasyonlar */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.card {
    animation: fadeIn 0.4s ease;
}

.sidebar-menu .nav-item {
    animation: slideIn 0.3s ease backwards;
}

.sidebar-menu .nav-item:nth-child(1) { animation-delay: 0.1s; }
.sidebar-menu .nav-item:nth-child(2) { animation-delay: 0.2s; }
.sidebar-menu .nav-item:nth-child(3) { animation-delay: 0.3s; }
.sidebar-menu .nav-item:nth-child(4) { animation-delay: 0.4s; }

/* Utility Classes */
.text-primary {
    color: var(--primary-color) !important;
}

.bg-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%) !important;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border: none;
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* İstatistik Kartları */
.stat-card {
    background: var(--surface);
    border-radius: 16px;
    padding: 28px;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    border-left: 4px solid var(--primary-color);
}

.stat-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
}

.stat-card.border-primary {
    border-left-color: var(--primary-color);
}

.stat-card.border-success {
    border-left-color: var(--success-color);
}

.stat-card.border-warning {
    border-left-color: var(--warning-color);
}

.stat-card.border-info {
    border-left-color: var(--info-color);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-track {
    background: var(--background);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--secondary-dark) 100%);
}
