/* ===== GENEL AYARLAR ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* ===== NAVİGASYON ===== */
.navbar {
    background: #fff;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
    flex-wrap: wrap;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 0;
}

.nav-logo {
    font-size: 28px;
}

.nav-title {
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 4px;
    flex-wrap: wrap;
}

.nav-menu a {
    text-decoration: none;
    color: #555;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s;
    display: block;
}

.nav-menu a:hover {
    background: #f0f4ff;
    color: #3b82f6;
}

.nav-menu a.active {
    background: #3b82f6;
    color: #fff;
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: #666;
}

/* ===== BUTONLAR ===== */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    text-align: center;
    transition: all 0.2s;
}

.btn-primary { background: #3b82f6; color: #fff; }
.btn-primary:hover { background: #2563eb; }

.btn-success { background: #22c55e; color: #fff; }
.btn-success:hover { background: #16a34a; }

.btn-danger { background: #ef4444; color: #fff; }
.btn-danger:hover { background: #dc2626; }

.btn-warning { background: #f59e0b; color: #fff; }
.btn-warning:hover { background: #d97706; }

.btn-secondary { background: #6b7280; color: #fff; }
.btn-secondary:hover { background: #4b5563; }

.btn-sm { padding: 6px 12px; font-size: 12px; }
.btn-lg { padding: 14px 28px; font-size: 16px; }

/* ===== BİLDİRİLER ===== */
.alert {
    padding: 14px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 14px;
    border-left: 4px solid;
}

.alert-success { background: #f0fdf4; color: #166534; border-color: #22c55e; }
.alert-danger { background: #fef2f2; color: #991b1b; border-color: #ef4444; }
.alert-warning { background: #fffbeb; color: #92400e; border-color: #f59e0b; }
.alert-info { background: #eff6ff; color: #1e40af; border-color: #3b82f6; }

/* ===== KARTLAR ===== */
.card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    padding: 24px;
    margin-bottom: 20px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 2px solid #f0f0f0;
}

.card-header h2 {
    font-size: 20px;
    color: #2c3e50;
}

/* ===== DASHBOARD KARTLARI ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    gap: 16px;
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-icon.blue { background: #eff6ff; }
.stat-icon.green { background: #f0fdf4; }
.stat-icon.red { background: #fef2f2; }
.stat-icon.orange { background: #fffbeb; }

.stat-info h3 {
    font-size: 28px;
    color: #2c3e50;
    line-height: 1.2;
}

.stat-info p {
    font-size: 13px;
    color: #888;
    margin-top: 2px;
}

/* ===== TABLOLAR ===== */
.table-wrapper {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

thead {
    background: #f8fafc;
}

th {
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    color: #64748b;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e2e8f0;
}

td {
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    color: #475569;
}

tr:hover {
    background: #f8fafc;
}

/* ===== STOK SEVİYE BADGE ===== */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.badge-success { background: #dcfce7; color: #166534; }
.badge-danger { background: #fee2e2; color: #991b1b; }
.badge-warning { background: #fef3c7; color: #92400e; }
.badge-info { background: #dbeafe; color: #1e40af; }

/* ===== FORMLAR ===== */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: #374151;
    font-size: 14px;
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s;
    background: #fff;
}

.form-control:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23999' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

/* ===== GİRİŞ SAYFASI ===== */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-card {
    background: #fff;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    width: 100%;
    max-width: 400px;
}

.login-card h1 {
    text-align: center;
    margin-bottom: 8px;
    color: #2c3e50;
}

.login-card .login-logo {
    text-align: center;
    font-size: 48px;
    margin-bottom: 16px;
}

.login-card .login-subtitle {
    text-align: center;
    color: #888;
    margin-bottom: 28px;
    font-size: 14px;
}

/* ===== ARAMA & FİLTRE ===== */
.toolbar {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.toolbar .form-control {
    max-width: 300px;
}

.search-box {
    position: relative;
}

.search-box input {
    padding-left: 36px;
}

.search-box::before {
    content: "🔍";
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
}

/* ===== KRİTİK STOK UYARISI ===== */
.kritik-stok {
    background: #fee2e2;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { background: #fee2e2; }
    50% { background: #fecaca; }
}

/* ===== MODAL ===== */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: #fff;
    border-radius: 16px;
    padding: 32px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.modal h3 {
    margin-bottom: 20px;
    color: #2c3e50;
}

/* ===== FOOTER ===== */
.footer {
    text-align: center;
    padding: 20px;
    color: #999;
    font-size: 13px;
    margin-top: 40px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        padding: 10px;
    }

    .nav-menu {
        width: 100%;
        justify-content: center;
    }

    .nav-user {
        width: 100%;
        justify-content: center;
        padding: 8px 0;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .toolbar {
        flex-direction: column;
    }

    .toolbar .form-control {
        max-width: 100%;
    }
}

/* ===== RAPOR ===== */
.rapor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

/* ===== HAREKET TİPİ ===== */
.hareket-giris { color: #22c55e; font-weight: 600; }
.hareket-cikis { color: #ef4444; font-weight: 600; }

/* ===== TABLO İÇİ BUTONLAR ===== */
.action-btns {
    display: flex;
    gap: 6px;
}

.action-btns .btn {
    padding: 6px 10px;
    font-size: 12px;
}
