:root {
    --bg-body: #f8fafc;
    --bg-card: #ffffff;
    --bg-sidebar: #0f172a;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --text-light: #f8fafc;
    --primary: #d97706;
    --primary-hover: #b45309;
    --secondary: #3b82f6;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --border: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.03);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.05), 0 2px 4px -1px rgba(0,0,0,0.03);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -2px rgba(0,0,0,0.04);
    --radius: 16px;
}

* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Inter', sans-serif; }
body { background-color: var(--bg-body); color: var(--text-main); line-height: 1.5; -webkit-font-smoothing: antialiased; }

/* Login */
.login-body { display: flex; align-items: center; justify-content: center; min-height: 100vh; background: radial-gradient(circle at center, #f8fafc 0%, #e2e8f0 100%); }
.login-card { background: var(--bg-card); padding: 50px 40px; border-radius: var(--radius); box-shadow: var(--shadow-lg); width: 100%; max-width: 420px; text-align: center; border-top: 6px solid var(--primary); }
.brand-logo { width: 100px; height: auto; object-fit: contain; }
.login-logo-img { width: 80px; height: auto; object-fit: contain; margin-bottom: 5px; filter: drop-shadow(0 4px 6px rgba(217, 119, 6, 0.2)); }

/* App Layout & Sidebar */
.app-layout { display: flex; min-height: 100vh; }
.sidebar { width: 280px; background-color: var(--bg-sidebar); color: var(--text-light); display: flex; flex-direction: column; transition: transform 0.3s ease; z-index: 50; box-shadow: 4px 0 10px rgba(0,0,0,0.05); }
.sidebar-brand { padding: 25px 20px; display: flex; align-items: center; gap: 15px; border-bottom: 1px solid rgba(255,255,255,0.05); }
.sidebar-brand i { font-size: 1.8rem; color: var(--primary); }
.sidebar-brand h2 { font-size: 1.4rem; font-weight: 700; color: #fff; letter-spacing: -0.5px; }
.sidebar-nav { flex: 1; padding: 20px 0; display: flex; flex-direction: column; gap: 8px; }
.sidebar-nav a { padding: 14px 25px; color: #94a3b8; text-decoration: none; font-weight: 500; transition: all 0.2s; display: flex; align-items: center; gap: 12px; border-left: 4px solid transparent; }
.sidebar-nav a i { font-size: 1.1rem; width: 20px; text-align: center; }
.sidebar-nav a:hover, .sidebar-nav a.active { background: rgba(255,255,255,0.03); color: #fff; border-left-color: var(--primary); }
.sidebar-nav .nav-logout { margin-top: 15px; padding: 14px 25px; color: #fca5a5; text-decoration: none; font-weight: 500; display: flex; align-items: center; gap: 12px; border-left: 4px solid transparent; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); position: relative; }
.sidebar-nav .nav-logout i { font-size: 1.1rem; width: 20px; text-align: center; transition: transform 0.25s ease; }
.sidebar-nav .nav-logout:hover { background: rgba(239, 68, 68, 0.06); color: #ef4444; border-left-color: #ef4444; }
.sidebar-nav .nav-logout:hover i { transform: translateX(4px); }
.sidebar-footer { padding: 20px; border-top: 1px solid rgba(255,255,255,0.05); }
.user-info { margin-bottom: 15px; display: flex; align-items: center; gap: 10px; }
.user-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--primary); display: flex; align-items: center; justify-content: center; font-weight: bold; font-size: 1.2rem; text-transform: uppercase; }
.user-details { display: flex; flex-direction: column; }
.user-role { font-size: 0.7rem; color: var(--primary); letter-spacing: 1px; font-weight: 700; text-transform: uppercase; }
.btn-logout { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; padding: 12px; border-radius: 10px; background: rgba(239, 68, 68, 0.1); color: var(--danger); text-decoration: none; border: 1px solid rgba(239, 68, 68, 0.2); transition: 0.2s; font-weight: 600; }
.btn-logout:hover { background: var(--danger); color: #fff; border-color: var(--danger); }

.main-content { flex: 1; display: flex; flex-direction: column; overflow-x: hidden; }
.topbar { background: var(--bg-card); height: 80px; padding: 0 30px; display: flex; align-items: center; border-bottom: 1px solid var(--border); }
.topbar-title { font-size: 1.4rem; font-weight: 700; color: var(--text-main); display: flex; align-items: center; gap: 10px; }
.mobile-menu-btn { display: none; background: none; border: none; font-size: 1.5rem; cursor: pointer; margin-right: 15px; color: var(--text-main); }
.content-wrapper { padding: 30px 45px 30px 30px; max-width: 1600px; margin: 0 auto; width: 100%; box-sizing: border-box; }

/* Grids */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 25px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 25px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 25px; }

/* Cards */
.card { background: var(--bg-card); border-radius: var(--radius); padding: 25px; box-shadow: var(--shadow-md); margin-bottom: 25px; border: 1px solid var(--border); min-width: 0; }
.stat-box { padding: 25px; border-radius: var(--radius); background: linear-gradient(145deg, #ffffff, #f8fafc); border: 1px solid var(--border); box-shadow: var(--shadow-sm); position: relative; overflow: hidden; }
.stat-box i { position: absolute; right: -15px; bottom: -20px; font-size: 6rem; opacity: 0.04; color: currentColor; }
.stat-label { font-size: 0.85rem; color: var(--text-muted); text-transform: uppercase; font-weight: 700; margin-bottom: 8px; display: block; letter-spacing: 0.5px; }
.stat-value { font-size: clamp(1.4rem, 2vw, 2.2rem); font-weight: 800; color: var(--text-main); line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Formlar */
.form-group { margin-bottom: 22px; text-align: left; }
.form-group label { display: block; margin-bottom: 10px; font-weight: 600; color: var(--text-main); font-size: 0.95rem; }
.input-with-icon { position: relative; }
.input-with-icon i { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: var(--text-muted); font-size: 1.1rem; }
.input-with-icon input, .input-with-icon select { padding-left: 50px; }
input, select { width: 100%; padding: 14px 18px; border-radius: 12px; border: 1px solid var(--border); background: var(--bg-body); color: var(--text-main); font-size: 1rem; transition: all 0.25s ease; }
input:focus, select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(217, 119, 6, 0.1); background: #fff; }

/* Butonlar */
.btn { background: var(--primary); color: #fff; border: none; padding: 14px 24px; border-radius: 12px; font-size: 1rem; font-weight: 600; cursor: pointer; transition: 0.2s; width: 100%; display: inline-flex; align-items: center; justify-content: center; gap: 10px; text-decoration: none; }
.btn:hover { background: var(--primary-hover); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(217, 119, 6, 0.2); }
.btn-outline { background: transparent; color: var(--secondary); border: 1px solid var(--secondary); }
.btn-outline:hover { background: var(--secondary); color: #fff; }

/* Vardiya Seçimi */
.shift-selector { display: flex; gap: 15px; }
.shift-selector label { flex: 1; text-align: center; background: var(--bg-body); padding: 18px; border: 2px solid var(--border); border-radius: 12px; cursor: pointer; font-weight: 700; transition: all 0.2s; color: var(--text-muted); }
.shift-selector input { display: none; }
.shift-selector input:checked + span { color: var(--primary); }
.shift-selector label:has(input:checked) { border-color: var(--primary); background: rgba(217, 119, 6, 0.05); box-shadow: 0 4px 12px rgba(217, 119, 6, 0.1); }

/* Tablolar */
.table-responsive { width: 100%; overflow-x: auto; border-radius: 12px; border: 1px solid var(--border); }
table { width: 100%; border-collapse: collapse; background: #fff; }
th, td { padding: 14px 8px; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; font-size: clamp(0.75rem, 0.9vw, 0.95rem); }
th { color: var(--text-muted); font-size: 0.85rem; text-transform: uppercase; background: var(--bg-body); font-weight: 700; letter-spacing: 0.5px; }
tr:last-child td { border-bottom: none; }
tr:hover { background: #f8fafc; }

/* Badges */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 20px; font-size: 0.8rem; font-weight: 700; text-transform: uppercase; }
.badge-warning { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.badge-secondary { background: rgba(59, 130, 246, 0.1); color: var(--secondary); }
.badge-success { background: rgba(16, 185, 123, 0.1); color: var(--success); }
.badge-primary { background: rgba(217, 119, 6, 0.1); color: var(--primary); }

.fade-in { animation: fadeIn 0.4s ease-out; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(15px); } to { opacity: 1; transform: translateY(0); } }

/* Pagination */
.pagination { display: flex; justify-content: center; align-items: center; gap: 6px; margin: 30px 0; flex-wrap: wrap; }
.page-link { padding: 10px 16px; border: 1px solid var(--border); border-radius: 10px; color: var(--text-main); text-decoration: none; font-weight: 600; background: #fff; transition: all 0.2s ease; font-size: 0.95rem; display: inline-flex; align-items: center; justify-content: center; min-width: 40px; }
.page-link:hover { border-color: var(--primary); color: var(--primary); background: rgba(217, 119, 6, 0.02); }
.page-link.active { background: var(--primary); color: #fff; border-color: var(--primary); box-shadow: 0 4px 10px rgba(217, 119, 6, 0.15); }
.page-link.disabled { color: var(--text-muted); opacity: 0.4; cursor: not-allowed; pointer-events: none; background: var(--bg-body); }

/* Satis Ekle Custom Dropdown */
.custom-select-wrapper { position: relative; }
.dropdown-list { position: absolute; top: 100%; left: 0; right: 0; z-index: 100; background: var(--bg-card); border: 1px solid var(--border); border-radius: 0 0 12px 12px; max-height: 250px; overflow-y: auto; box-shadow: var(--shadow-md); margin-top: -5px; }
.dropdown-item { padding: 12px 18px; cursor: pointer; color: var(--text-main); font-weight: 600; border-bottom: 1px solid var(--bg-body); transition: background 0.2s; }
.dropdown-item:last-child { border-bottom: none; }
.dropdown-item:hover { background: rgba(217, 119, 6, 0.08); color: var(--primary); }

/* ========== RESPONSIVE ========== */
@media (max-width: 1400px) {
    .table-responsive { border: none; overflow: visible; background: var(--bg-body); padding: 20px; border-radius: 0 0 var(--radius) var(--radius); }
    .table-responsive table { border: none; background: transparent; display: block; }
    .table-responsive thead { display: none; }
    .table-responsive tbody { display: block; width: 100%; }
    .table-responsive tbody tr { display: flex; flex-direction: column; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 25px; box-shadow: var(--shadow-md); padding: 8px 0; }
    .table-responsive tbody td { display: flex; justify-content: space-between; align-items: center; padding: 14px 20px; border-bottom: 1px solid var(--border); text-align: right; width: 100%; box-sizing: border-box; }
    .table-responsive tbody td:last-child { border-bottom: none; }
    .table-responsive tbody td::before { content: attr(data-label); font-weight: 700; font-size: 0.8rem; color: var(--text-muted); text-transform: uppercase; text-align: left; margin-right: 15px; }
    .grid-4 { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    .stat-value { font-size: 1.8rem; }
}
@media (max-width: 1100px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 850px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

@media (max-width: 768px) {
    .sidebar { position: fixed; top: 0; left: 0; width: 85% !important; max-width: 320px; height: 100vh !important; background-color: var(--bg-sidebar); transform: translateX(-100%); transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1); z-index: 1050; overflow-y: auto !important; display: flex; flex-direction: column; padding-bottom: 20px; box-shadow: none; }
    .sidebar.open { transform: translateX(0) !important; box-shadow: 8px 0 30px rgba(0,0,0,0.3); }
    .sidebar::-webkit-scrollbar { width: 4px; }
    .sidebar::-webkit-scrollbar-track { background: rgba(255,255,255,0.05); }
    .sidebar::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 4px; }
    .sidebar-nav { flex: 1; overflow-y: auto; padding-bottom: 30px; }
    .sidebar-brand { padding: 15px 20px !important; position: sticky; top: 0; background: var(--bg-sidebar); z-index: 2; }
    .sidebar-nav a { padding: 14px 20px !important; margin: 0 8px; border-radius: 12px; border-left: none !important; font-size: 0.9rem !important; }
    .sidebar-nav a.active { background: rgba(217, 119, 6, 0.15); color: var(--primary); }
    .sidebar-nav .nav-logout { margin: 20px 8px 30px 8px; border-radius: 12px; background: rgba(239,68,68,0.1); justify-content: center; }

    .sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.7); backdrop-filter: blur(3px); z-index: 1040; transition: all 0.2s; }
    .sidebar-overlay.active { display: block !important; }

    .topbar { height: 70px; padding: 0 20px; }
    .content-wrapper { padding: 20px; }
    .mobile-menu-btn { display: block; }

    .grid-4, .grid-3 { grid-template-columns: 1fr !important; gap: 16px; }
    .stat-value { font-size: 1.6rem; }

    .card { padding: 20px 16px; margin-bottom: 90px; }
    .hesap-badge { font-size: 1.2rem; padding: 12px 20px; margin: 20px 0; }
    .extra-item-card { padding: 12px; }
    .dynamic-row { flex-direction: column; align-items: stretch; padding: 12px; }
    .dynamic-row .gider-grid { grid-template-columns: 1fr; gap: 12px; }
    .dynamic-row button { align-self: flex-end; width: 40px !important; height: 40px; border-radius: 30px; }
    input, select, .btn { font-size: 16px; }
    .input-with-icon i { font-size: 1rem; left: 14px; }
    .input-with-icon input, .input-with-icon select { padding-left: 40px; }
    .modal-emergency .modal-card { width: 90%; padding: 20px; margin: 20px; }
}
@media (max-width: 768px) and (max-height: 500px) {
    .sticky-footer-bar { position: relative; margin-top: 20px; }
    .card { margin-bottom: 20px; }
}
@media (max-width: 480px) {
    .sidebar { width: 90% !important; max-width: 260px; }
    .sidebar-brand h2 { font-size: 1rem !important; }
    .sidebar-brand img.brand-logo { width: 35px !important; }
}

/* Sticky Footer Bar – tüm kurallar tek bir yerde */
.sticky-footer-bar {
    position: fixed; bottom: 0; left: 0; width: 100%;
    background: var(--bg-sidebar); color: #fff;
    padding: 10px 25px; box-shadow: 0 -4px 15px rgba(0,0,0,0.1);
    display: flex; justify-content: space-between; align-items: center;
    z-index: 100; border-top: 3px solid var(--primary);
    gap: 15px; flex-wrap: wrap;
}
.sticky-footer-bar .net-tutar-label {
    font-size: 0.85rem; color: #94a3b8;
    text-transform: uppercase; font-weight: 700;
}
.sticky-footer-bar .net-tutar-value {
    font-size: 1.8rem; font-weight: 900;
    color: var(--success); line-height: 1.1;
}
.sticky-footer-left {
    display: flex; align-items: center;
    gap: 20px; flex-wrap: wrap;
}
.emergency-shift-btn {
    background: #ef4444; color: white; border: none;
    border-radius: 60px; width: 48px; height: 48px;
    font-size: 1.5rem; cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    transition: 0.2s; display: inline-flex;
    align-items: center; justify-content: center;
}
.emergency-shift-btn:hover {
    transform: scale(1.05); background: #dc2626;
    box-shadow: 0 4px 12px rgba(220,38,38,0.4);
}
@media (min-width: 769px) {
    .sticky-footer-bar { padding-left: calc(280px + 25px); }
}
@media (max-width: 768px) {
    .sticky-footer-bar {
        position: fixed; bottom: 0; left: 0; width: 100%;
        background: rgba(15,23,42,0.95); backdrop-filter: blur(10px);
        padding: 12px 16px !important;
        flex-direction: row !important; justify-content: space-between !important;
        align-items: center !important; gap: 12px !important;
        border-top: 2px solid var(--primary);
        box-shadow: 0 -5px 20px rgba(0,0,0,0.2);
    }
    .sticky-footer-left {
        display: flex !important; flex-direction: row !important;
        align-items: center !important; gap: 12px !important;
        flex-wrap: nowrap !important; width: auto !important;
    }
    .emergency-shift-btn {
        width: 44px !important; height: 44px !important;
        font-size: 1.3rem !important; background: rgba(239,68,68,0.9);
        box-shadow: 0 2px 8px rgba(239,68,68,0.4); flex-shrink: 0;
    }
    .sticky-footer-left div:last-child {
        display: flex; flex-direction: column; align-items: flex-start;
        line-height: 1.2;
    }
    .sticky-footer-bar .net-tutar-label {
        font-size: 0.7rem !important; color: #94a3b8;
        margin-bottom: 2px; letter-spacing: 0.5px;
    }
    .sticky-footer-bar .net-tutar-value {
        display: inline-flex !important; flex-direction: row !important;
        flex-wrap: nowrap !important; align-items: center;
        gap: 4px; white-space: nowrap; font-size: 1.4rem;
        font-weight: 800; color: #4ade80;
    }
    .sticky-footer-bar .btn {
        padding: 10px 16px !important; min-width: 120px;
        background: linear-gradient(135deg, var(--success), #059669);
        border-radius: 40px !important; font-weight: 700;
        white-space: nowrap; flex-shrink: 0; font-size: 0.85rem !important;
    }
    .sticky-footer-bar .btn i { font-size: 1rem; }
}
@media (max-width: 480px) {
    .sticky-footer-bar {
        padding: 6px 12px !important; gap: 8px !important;
    }
    .sticky-footer-left { gap: 6px !important; }
    .emergency-shift-btn {
        width: 32px !important; height: 32px !important;
        font-size: 1rem !important;
    }
    .sticky-footer-bar .net-tutar-label { font-size: 0.55rem !important; }
    .sticky-footer-bar .net-tutar-value { font-size: 1rem !important; }
    .sticky-footer-bar .btn {
        padding: 6px 10px !important; min-width: 80px !important;
        font-size: 0.7rem !important; height: 32px !important;
        border-radius: 20px !important;
    }
    .sticky-footer-bar .btn span.btn-text { display: none; }
    .sticky-footer-bar .btn i + span { display: inline; }
    .sticky-footer-bar .btn i { margin-right: 0; }
}
/* ===== EKLENEN/DEĞİŞTİRİLEN KISIMLAR ===== */

/* Ekstra Giderler - dinamik satırlar için grid (masaüstü yan yana) */
.dynamic-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-bottom: 12px;
    background: rgba(0,0,0,0.02);
    padding: 12px;
    border-radius: 12px;
}
.gider-grid {
    flex: 1;
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 12px;
    align-items: center;
}
.dynamic-row > button {
    flex-shrink: 0;
}
@media (max-width: 768px) {
    .gider-grid {
        grid-template-columns: 1fr;
        gap: 8px;
        width: 100%;
    }
    .dynamic-row {
        flex-direction: column;
        align-items: stretch;
    }
    .dynamic-row > button {
        align-self: flex-end;
        width: 40px;
        height: 40px;
    }
}

/* Acil Vardiya Modal - Pop-up stili */
.modal-emergency {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    animation: fadeInModal 0.2s ease-out;
}
.modal-emergency .modal-card {
    background: var(--bg-card);
    border-radius: 24px;
    max-width: 450px;
    width: 90%;
    padding: 28px 24px;
    box-shadow: 0 25px 40px rgba(0,0,0,0.2);
    border-top: 5px solid var(--danger);
    animation: slideUpModal 0.25s ease-out;
}
@keyframes fadeInModal {
    from { background-color: rgba(0,0,0,0); backdrop-filter: blur(0); }
    to { background-color: rgba(0,0,0,0.7); backdrop-filter: blur(5px); }
}
@keyframes slideUpModal {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
.modal-emergency .modal-card h3 {
    font-size: 1.4rem;
}
.modal-emergency .modal-card p {
    margin: 15px 0;
}
@media (max-width: 480px) {
    .modal-emergency .modal-card {
        padding: 20px;
        width: 85%;
    }
}

/* Mobilde üst kısım (Vardiya bilgi kartı) - premium iyileştirme */
@media (max-width: 768px) {
    /* Vardiya seçim kartı (ilk grid-3) */
    .grid-3[style*="margin-bottom: 25px; background: rgba(0,0,0,0.02);"] {
        background: linear-gradient(135deg, #ffffff, #fef9f0) !important;
        border: 1px solid rgba(217,119,6,0.2) !important;
        border-radius: 24px !important;
        padding: 20px 16px !important;
        box-shadow: 0 8px 20px rgba(0,0,0,0.03);
    }
    .grid-3 .form-group {
        margin-bottom: 16px !important;
    }
    .grid-3 label {
        font-size: 0.75rem;
        font-weight: 600;
        color: var(--primary);
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    .grid-3 .input-with-icon input,
    .grid-3 .input-with-icon select {
        background: #fff;
        border-radius: 16px;
        padding: 12px 16px 12px 40px;
        font-size: 0.95rem;
        box-shadow: 0 1px 2px rgba(0,0,0,0.02);
    }
    /* Başlık ikonları ve yazı boyutları */
    .card > h2 {
        font-size: 1.3rem !important;
        margin-bottom: 16px !important;
    }
    .hesap-badge {
        background: linear-gradient(135deg, #fef3c7, #ffedd5);
        border-radius: 20px;
        padding: 12px 16px;
        margin: 20px 0;
        text-align: center;
        border-left: 4px solid var(--primary);
    }
    .hesap-badge span:first-child {
        font-size: 0.7rem !important;
    }
    .hesap-badge #ui_tezgah_satis {
        font-size: 1.8rem !important;
        font-weight: 800;
        color: var(--primary);
    }
}


/* ============================================ */
/* MOBİL TOPBAR (MENU + BASLIK + AVATAR) PREMIUM */
/* ============================================ */

@media (max-width: 768px) {
    /* Topbar konteyner - daha kompakt ve şeffaf */
    .topbar {
        height: 64px !important;
        padding: 0 16px !important;
        background: rgba(255, 255, 255, 0.96) !important;
        backdrop-filter: blur(12px);
        border-bottom: 1px solid rgba(217, 119, 6, 0.1) !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
        position: sticky;
        top: 0;
        z-index: 100;
    }

    /* Hamburger buton - modern yuvarlak */
    .mobile-menu-btn {
        display: flex !important;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        border-radius: 30px;
        background: rgba(217, 119, 6, 0.08);
        font-size: 1.3rem !important;
        margin-right: 12px !important;
        color: var(--primary) !important;
        transition: all 0.2s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    }
    .mobile-menu-btn:active {
        background: rgba(217, 119, 6, 0.2);
        transform: scale(0.96);
    }

    /* Başlık alanı - ikon + yazı */
    .topbar-title {
        flex: 1;
        display: flex;
        align-items: center;
        gap: 8px !important;
        font-size: 1rem !important;
        font-weight: 700 !important;
        letter-spacing: -0.3px;
        background: linear-gradient(135deg, #1e293b, #334155);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
    }
    .topbar-title i {
        font-size: 1.2rem !important;
        color: var(--primary);
        background: none;
        -webkit-background-clip: unset;
        background-clip: unset;
    }
    /* Yazı taşarsa kısaltma */
    .topbar-title span {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 160px;
    }

    /* Sağ taraftaki kullanıcı bilgisi / avatar - düzenleme */
    /* Varsayılan sidebar-footer içinde .user-info var. Topbar'da ayrı bir yapı varsa ona göre ayarlıyoruz */
    /* Eğer topbar içinde .user-info varsa: */
    .topbar .user-info {
        margin: 0 !important;
        padding: 0 !important;
        gap: 6px !important;
        background: transparent !important;
    }
    .topbar .user-avatar {
        width: 38px !important;
        height: 38px !important;
        font-size: 1rem !important;
        background: linear-gradient(145deg, var(--primary), #b45309);
        box-shadow: 0 3px 8px rgba(217, 119, 6, 0.25);
        transition: transform 0.2s;
    }
    .topbar .user-avatar:active {
        transform: scale(0.95);
    }
    /* Kullanıcı adı ve rolü mobilde gizle (sadece avatar göster) */
    .topbar .user-details {
        display: none !important;
    }

    /* Alternatif: Eğer topbar'da farklı bir class kullanılıyorsa (örneğin .profile-badge) */
    .topbar .profile-badge .user-name,
    .topbar .profile-badge .user-role {
        display: none;
    }
    .topbar .profile-badge .user-avatar {
        width: 38px;
        height: 38px;
    }

    /* Sol menü açıldığında topbar'ın üstte kalması için */
    .sidebar.open ~ .main-content .topbar {
        z-index: 1;
    }
}

/* Çok küçük ekranlar (max 400px) için biraz daha inceltme */
@media (max-width: 400px) {
    .topbar {
        height: 56px !important;
        padding: 0 12px !important;
    }
    .mobile-menu-btn {
        width: 34px;
        height: 34px;
        font-size: 1.1rem !important;
    }
    .topbar-title {
        font-size: 0.85rem !important;
        gap: 6px !important;
    }
    .topbar-title i {
        font-size: 1rem !important;
    }
    .topbar-title span {
        max-width: 130px;
    }
    .topbar .user-avatar {
        width: 32px !important;
        height: 32px !important;
        font-size: 0.85rem !important;
    }
}


/* Sidebar içine kapatma butonu */
.sidebar .sidebar-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255,255,255,0.1);
    border: none;
    color: #fff;
    font-size: 1.3rem;
    width: 36px;
    height: 36px;
    border-radius: 30px;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    z-index: 1060;
}
.sidebar .sidebar-close-btn:hover {
    background: rgba(239,68,68,0.3);
    transform: scale(1.05);
}
/* Mobilde göster */
@media (max-width: 768px) {
    .sidebar .sidebar-close-btn {
        display: flex;
    }
    /* Sidebar açıkken topbar'daki mobile menu butonunun görünür olması için */
    .sidebar.open ~ .main-content .mobile-menu-btn {
        z-index: 1061;
        position: relative;
        background: rgba(217,119,6,0.2);
    }
    /* Sidebar açıkken logo alanı düzenlemesi - içerik kaymasın */
    .sidebar .sidebar-brand {
        padding-right: 40px; /* kapatma butonuna yer aç */
    }
}

/* ============================================ */
/* GİRİŞ SAYFASI MOBİL İYİLEŞTİRMELERİ */
/* ============================================ */

/* 768px ve altı (tablet/mobil) */
@media (max-width: 768px) {
    .login-body {
        background: radial-gradient(circle at center, #f8fafc 0%, #e2e8f0 100%);
        padding: 20px;
        align-items: center;
        min-height: 100vh;
    }
    .login-card {
        max-width: 90%;
        padding: 30px 20px;
        border-radius: 24px;
        box-shadow: 0 20px 35px -12px rgba(0,0,0,0.15);
        border-top-width: 4px;
    }
    .login-logo-img {
        width: 70px;
        margin-bottom: 10px;
    }
    .login-card h2 {
        font-size: 1.4rem !important;
        letter-spacing: -0.3px;
    }
    .login-card p {
        font-size: 0.85rem !important;
        margin-bottom: 25px !important;
    }
    .form-group label {
        font-size: 0.85rem;
        margin-bottom: 6px;
    }
    .input-with-icon i {
        font-size: 1rem;
        left: 14px;
    }
    .input-with-icon input {
        padding: 12px 16px 12px 42px;
        font-size: 1rem;
        border-radius: 14px;
    }
    .btn {
        padding: 12px 20px;
        font-size: 1rem;
        border-radius: 14px;
        height: auto;
        margin-top: 10px !important;
    }
    /* Alt footer */
    .login-body > div:last-child {
        position: fixed;
        bottom: 16px;
        left: 0;
        width: 100%;
        text-align: center;
        font-size: 0.7rem;
        padding: 8px;
        background: rgba(255,255,255,0.7);
        backdrop-filter: blur(4px);
        border-radius: 30px;
        width: 90%;
        margin: 0 5%;
        box-sizing: border-box;
    }
    /* Hata mesajı */
    .login-card [style*="background: rgba(239, 68, 68, 0.1)"] {
        padding: 10px 12px;
        font-size: 0.85rem;
        border-radius: 14px;
        margin-bottom: 20px;
    }
}

/* 480px ve altı (küçük telefonlar) */
@media (max-width: 480px) {
    .login-card {
        max-width: 95%;
        padding: 25px 16px;
    }
    .login-logo-img {
        width: 55px;
    }
    .login-card h2 {
        font-size: 1.2rem !important;
    }
    .login-card p {
        font-size: 0.75rem !important;
        margin-bottom: 20px !important;
    }
    .input-with-icon input {
        padding: 10px 14px 10px 38px;
        font-size: 0.95rem;
    }
    .btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }
    .login-body > div:last-child {
        font-size: 0.6rem;
        bottom: 12px;
        width: 92%;
        margin: 0 4%;
    }
}

/* Yatay mod (telefon yatay) ve küçük tabletler için ek düzenleme */
@media (max-width: 768px) and (orientation: landscape) {
    .login-body {
        padding: 15px;
        min-height: 100vh;
    }
    .login-card {
        padding: 20px 20px;
        max-width: 80%;
    }
    .login-logo-img {
        width: 50px;
    }
    .login-card h2 {
        font-size: 1.2rem;
        margin-bottom: 2px;
    }
    .login-card p {
        margin-bottom: 15px;
    }
    .form-group {
        margin-bottom: 15px;
    }
    .btn {
        margin-top: 5px !important;
    }
    .login-body > div:last-child {
        position: relative;
        margin-top: 20px;
        bottom: 0;
        background: transparent;
        backdrop-filter: none;
        width: auto;
    }
}