/* BenimPOS - Market Yönetim Sistemi CSS */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f5f5;
    color: #333;
}

/* Header Styles */
.header {
    background: white;
    padding: 15px 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: 70px;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: #2563eb;
}

.search-bar {
    flex: 1;
    max-width: 400px;
    margin: 0 20px;
}

.search-bar input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.notification {
    position: relative;
    cursor: pointer;
}

.notification i {
    font-size: 20px;
    color: #666;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ef4444;
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.account-info {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #666;
}

.financial-summary {
    display: flex;
    gap: 30px;
    margin-top: 10px;
}

.financial-item {
    text-align: center;
}

.financial-label {
    font-size: 12px;
    color: #666;
    margin-bottom: 5px;
}

.financial-value {
    font-size: 24px;
    font-weight: bold;
}

.financial-value.paid {
    color: #ef4444;
}

.financial-value.total {
    color: #ef4444;
}

.financial-value.change {
    color: #10b981;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    left: 0;
    top: 70px;
    width: 250px;
    height: calc(100vh - 70px);
    background: white;
    box-shadow: 2px 0 4px rgba(0,0,0,0.1);
    overflow-y: auto;
    z-index: 999;
}

.sidebar-menu {
    list-style: none;
    padding: 20px 0;
}

.sidebar-menu li {
    margin-bottom: 5px;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
}

.sidebar-menu a:hover,
.sidebar-menu a.active {
    background: #2563eb;
    color: white;
}

.sidebar-menu i {
    margin-right: 12px;
    width: 20px;
    text-align: center;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    left: 0;
    top: 70px;
    width: 70px; /* Varsayılan olarak küçük */
    height: calc(100vh - 70px);
    background: white;
    box-shadow: 2px 0 4px rgba(0,0,0,0.1);
    overflow-y: auto;
    z-index: 999;
    transition: width 0.3s ease;
}

.sidebar.expanded {
    width: 250px; /* Genişletildiğinde */
}

.sidebar-toggle {
    position: absolute;
    top: 20px;
    right: -15px;
    width: 30px;
    height: 30px;
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.sidebar-toggle:hover {
    background: #1d4ed8;
    transform: scale(1.1);
}

/* Varsayılan olarak sağ ok (genişletmek için) */
#sidebar-toggle-icon {
    transform: rotate(180deg); /* Başlangıçta sağ ok */
}

.sidebar.expanded #sidebar-toggle-icon {
    transform: rotate(0deg); /* Genişletildiğinde sol ok */
}

.sidebar-menu {
    list-style: none;
    padding: 20px 0;
}

.sidebar-menu li {
    margin-bottom: 5px;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

.sidebar-menu a:hover,
.sidebar-menu a.active {
    background: #2563eb;
    color: white;
}

.sidebar-menu i {
    margin-right: 12px;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.sidebar-menu span {
    transition: opacity 0.3s ease;
}

/* Varsayılan olarak küçük durumda */
.sidebar-menu span {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.sidebar-menu a {
    padding: 12px 20px;
    justify-content: center;
}

.sidebar-menu i {
    margin-right: 0;
}

/* Genişletildiğinde */
.sidebar.expanded .sidebar-menu span {
    opacity: 1;
    width: auto;
    overflow: visible;
}

.sidebar.expanded .sidebar-menu a {
    padding: 12px 20px;
    justify-content: flex-start;
}

.sidebar.expanded .sidebar-menu i {
    margin-right: 12px;
}

/* Tooltip for collapsed sidebar */
.sidebar-menu a::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    background: #1f2937;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    margin-left: 10px;
}

.sidebar-menu a::before {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 5px solid transparent;
    border-right-color: #1f2937;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    margin-left: 5px;
}

.sidebar-menu a:hover::after,
.sidebar-menu a:hover::before {
    opacity: 1;
    visibility: visible;
}

/* Sidebar hover ile geçici açılma */
.sidebar:hover {
    width: 250px !important;
    z-index: 1001; /* Üstte kalması için */
}

.sidebar:hover + .main-content {
    margin-left: 250px !important;
    transition: margin-left 0.3s ease !important;
}

.sidebar:hover .sidebar-menu span {
    opacity: 1 !important;
    width: auto !important;
    overflow: visible !important;
}

.sidebar:hover .sidebar-menu a {
    padding: 12px 20px !important;
    justify-content: flex-start !important;
}

.sidebar:hover .sidebar-menu i {
    margin-right: 12px !important;
}

.sidebar:hover .sidebar-menu a::after,
.sidebar:hover .sidebar-menu a::before {
    display: none !important;
}

/* Genişletildiğinde tooltip'leri gizle */
.sidebar.expanded .sidebar-menu a::after,
.sidebar.expanded .sidebar-menu a::before {
    display: none;
}

/* Main Content */
.main-content {
    margin-left: 70px; /* Varsayılan olarak küçük sidebar */
    margin-top: 70px;
    padding: 20px;
    min-height: calc(100vh - 70px);
    display: flex;
    flex-direction: column;
    transition: margin-left 0.3s ease;
}

.sidebar.expanded ~ .main-content {
    margin-left: 250px; /* Genişletildiğinde */
}

.sidebar:hover ~ .main-content {
    margin-left: 250px !important; /* Hover'da da */
}

.content-area {
    flex: 1;
    width: 100%;
}

/* Sales Page Styles */
.sales-container {
    display: grid;
    grid-template-columns: 1fr 500px; /* Varsayılan olarak geniş sağ taraf */
    gap: 20px;
    height: calc(100vh - 110px);
    min-height: 600px;
    transition: grid-template-columns 0.3s ease; /* Grid transition eklendi */
}

/* Sidebar expanded olduğunda daha dar alan - TÜM SAYFALAR İÇİN */
.sidebar.expanded ~ .main-content .sales-container {
    grid-template-columns: 1fr 450px; /* Daha dar */
}

/* Sidebar hover olduğunda da dar alan - TÜM SAYFALAR İÇİN */
.sidebar:hover ~ .main-content .sales-container {
    grid-template-columns: 1fr 450px !important; /* Daha dar */
}


.sales-left {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.sales-right {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%; /* Tam yükseklik kullan */
    min-height: 600px; /* Minimum yükseklik */
}

/* Product Input Section */
.product-input-section {
    margin-bottom: 24px;
    background: #f8fafc;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.price-dropdown {
    margin-bottom: 16px;
}

.price-dropdown select {
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    background: white;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    transition: all 0.2s ease;
    width: 100%;
    max-width: 200px;
}

.price-dropdown select:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.barcode-input {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.barcode-input input {
    flex: 1;
    min-width: 200px;
    padding: 14px 18px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.2s ease;
    background: white;
}

.barcode-input input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.action-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-primary {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white;
}

.btn-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.btn-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.btn-info {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    color: white;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Customer Tabs */
.customer-tabs {
    margin-bottom: 24px;
    background: #f8fafc;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.tab-list {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.tab {
    padding: 12px 20px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
    color: #6b7280;
    min-width: 120px;
    text-align: center;
}

.tab.active {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}

.tab:hover:not(.active) {
    background: #f3f4f6;
    border-color: #d1d5db;
}

.product-controls {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    align-items: center;
    flex-wrap: wrap;
}

.product-controls input,
.product-controls select {
    padding: 10px 14px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.2s ease;
    background: white;
}

.product-controls input:focus,
.product-controls select:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Product List Table */
.product-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 16px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    flex: 1;
}

.product-table th,
.product-table td {
    padding: 16px 12px;
    text-align: left;
    border-bottom: 1px solid #f1f5f9;
}

.product-table th {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    font-weight: 700;
    color: #374151;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-table tr:hover {
    background: #f8fafc;
}

.product-table tr:last-child td {
    border-bottom: none;
}

.delete-btn {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.2);
}

.delete-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(239, 68, 68, 0.3);
}

.product-table input[type="number"] {
    width: 80px;
    padding: 8px 10px;
    border: 2px solid #e2e8f0;
    border-radius: 4px;
    text-align: center;
    font-weight: 600;
    transition: all 0.2s ease;
}

.product-table input[type="number"]:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Payment Section */
.payment-section {
    margin-bottom: 24px;
    background: #f8fafc;
    padding: 24px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    flex-shrink: 0; /* Ödeme bölümünün küçülmesini engelle */
}

.customer-select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
    font-weight: 500;
    background: white;
    transition: all 0.2s ease;
}

.customer-select:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.datetime-info {
    text-align: center;
    margin-bottom: 20px;
    color: #6b7280;
    font-size: 16px;
    font-weight: 600;
    background: white;
    padding: 12px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.limit-info {
    text-align: center;
    margin-bottom: 20px;
    color: #6b7280;
    font-size: 14px;
    background: white;
    padding: 12px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.limit-info select {
    margin-left: 8px;
    padding: 6px 10px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 12px;
}

.financial-summary-section {
    margin-bottom: 24px;
    background: white;
    padding: 20px;
    border-radius: 8px;
    border: 2px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.financial-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.financial-item {
    text-align: center;
    padding: 16px;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.financial-label {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.financial-value {
    font-size: 20px;
    font-weight: 800;
    line-height: 1;
}

.financial-value.total {
    color: #1f2937;
}

.financial-value.paid {
    color: #2563eb;
}

.financial-value.change {
    color: #10b981;
}

.quick-amounts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 20px;
}

.quick-amount-btn {
    padding: 12px 16px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 700;
    color: #374151;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.quick-amount-btn:hover {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.2);
}

.payment-methods {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 32px;
}

.payment-btn {
    padding: 18px 20px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 700;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.payment-btn.cash {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.payment-btn.pos {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white;
}

.payment-btn.account {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.payment-btn.partial {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    color: white;
}

.payment-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

.payment-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Quick Products */
.quick-products {
    margin-top: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0; /* Flexbox için önemli */
}

.product-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    flex-shrink: 0; /* Sekmelerin küçülmesini engelle */
}

.product-tab {
    padding: 12px 20px;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
    color: #6b7280;
    min-width: 80px;
    text-align: center;
}

.product-tab.active {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}

.product-tab:hover:not(.active) {
    background: #f3f4f6;
    border-color: #d1d5db;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); /* Varsayılan olarak küçük */
    gap: 10px; /* Daha az gap */
    flex: 1;
    overflow-y: auto;
    padding: 4px;
    min-height: 0; /* Flexbox için önemli */
    max-height: none; /* Yükseklik sınırını kaldır */
    transition: grid-template-columns 0.3s ease; /* Grid transition eklendi */
}

/* Sidebar expanded olduğunda daha büyük ürün kartları - TÜM SAYFALAR İÇİN */
.sidebar.expanded ~ .main-content .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); /* Daha büyük */
}

/* Sidebar hover olduğunda da büyük ürün kartları - TÜM SAYFALAR İÇİN */
.sidebar:hover ~ .main-content .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)) !important; /* Daha büyük */
}


.product-item {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px; /* Daha küçük border radius */
    padding: 12px; /* Daha az padding */
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    min-height: 85px; /* Daha küçük minimum yükseklik */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.product-item:hover {
    background: #f8fafc;
    border-color: #2563eb;
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(37, 99, 235, 0.15);
}

.product-name {
    font-size: 12px; /* Daha küçük font */
    font-weight: 700;
    margin-bottom: 6px; /* Daha az margin */
    color: #374151;
    line-height: 1.2; /* Daha sıkı line height */
}

.product-price {
    font-size: 14px; /* Daha küçük font */
    font-weight: 800;
    color: #10b981;
    background: #ecfdf5;
    padding: 3px 6px; /* Daha az padding */
    border-radius: 4px; /* Daha küçük border radius */
    border: 1px solid #d1fae5;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .sales-container {
        grid-template-columns: 1fr;
        height: auto;
        min-height: auto;
    }
    
    .sales-right {
        order: -1;
        margin-bottom: 20px;
    }
    
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
        flex-direction: column;
    }
    
    .content-area {
        width: 100%;
    }
    
    /* Mobilde sidebar toggle gizle */
    .sidebar-toggle {
        display: none;
    }
    
    /* Mobilde hover efektini kapat */
    .sidebar:hover {
        width: 70px !important;
    }
    
    .sidebar:hover ~ .main-content {
        margin-left: 0 !important;
    }
}

@media (max-width: 1024px) and (min-width: 769px) {
    .sales-container {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .sales-right {
        order: -1;
        margin-bottom: 16px;
    }
    
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        max-height: 400px; /* Tablet'te scroll için */
    }
    
    .quick-products {
        min-height: 500px; /* Tablet'te minimum yükseklik */
    }
    
    .financial-summary-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .quick-amounts {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .payment-methods {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 12px;
    }
    
    .sales-left,
    .sales-right {
        padding: 16px;
        border-radius: 8px;
    }
    
    .barcode-input {
        flex-direction: column;
    }
    
    .barcode-input input {
        min-width: auto;
        width: 100%;
    }
    
    .action-buttons {
        justify-content: center;
    }
    
    .tab-list {
        flex-direction: column;
    }
    
    .tab {
        min-width: auto;
        width: 100%;
    }
    
    .product-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .product-controls input,
    .product-controls select {
        width: 100%;
    }
    
    .product-table {
        font-size: 12px;
    }
    
    .product-table th,
    .product-table td {
        padding: 8px 6px;
    }
    
    .quick-amounts {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .payment-methods {
        grid-template-columns: 1fr;
    }
    
    .financial-summary-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .financial-item {
        padding: 12px;
    }
    
    .financial-value {
        font-size: 18px;
    }
    
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 8px;
        max-height: 300px; /* Mobilde scroll için */
    }
    
    .product-item {
        min-height: 80px;
        padding: 12px;
    }
    
    .product-name {
        font-size: 11px;
    }
    
    .product-price {
        font-size: 14px;
    }
    
    .quick-products {
        min-height: 400px; /* Mobilde minimum yükseklik */
    }
}

@media (max-width: 480px) {
    .header {
        padding: 10px 15px;
        height: 60px;
    }
    
    .logo {
        font-size: 20px;
    }
    
    .main-content {
        padding: 8px;
        margin-top: 60px;
    }
    
    .sales-left,
    .sales-right {
        padding: 12px;
    }
    
    .btn {
        padding: 10px 16px;
        font-size: 13px;
        min-height: 40px;
    }
    
    .payment-btn {
        padding: 14px 16px;
        font-size: 14px;
    }
    
    .quick-amounts {
        grid-template-columns: 1fr;
    }
    
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        max-height: 250px; /* Küçük mobilde scroll için */
    }
    
    .product-item {
        min-height: 70px;
        padding: 8px;
    }
    
    .product-name {
        font-size: 10px;
    }
    
    .product-price {
        font-size: 12px;
    }
    
    .quick-products {
        min-height: 350px; /* Küçük mobilde minimum yükseklik */
    }
}

/* Other Pages Styles */
.page-header {
    margin-bottom: 30px;
}

.page-title {
    font-size: 28px;
    font-weight: bold;
    color: #1f2937;
    margin-bottom: 10px;
}

.page-content {
    background: white;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: width 0.3s ease, margin 0.3s ease; /* Genel transition */
}

/* TÜM SAYFALAR İÇİN - Sidebar durumuna göre genel düzenlemeler */
.sidebar.expanded ~ .main-content .page-content {
    width: calc(100% - 20px); /* Sidebar genişken daha dar */
}

.sidebar:hover ~ .main-content .page-content {
    width: calc(100% - 20px) !important; /* Sidebar hover'da da dar */
}

/* Utility Classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mb-20 { margin-bottom: 20px; }
.mt-20 { margin-top: 20px; }
.p-20 { padding: 20px; }

/* Touch Interactions */
@media (hover: none) and (pointer: coarse) {
    .btn:hover,
    .payment-btn:hover,
    .quick-amount-btn:hover,
    .product-item:hover,
    .tab:hover,
    .product-tab:hover {
        transform: none;
        box-shadow: none;
    }
    
    .btn:active,
    .payment-btn:active,
    .quick-amount-btn:active,
    .product-item:active,
    .tab:active,
    .product-tab:active {
        transform: scale(0.95);
        transition: transform 0.1s ease;
    }
    
    .btn,
    .payment-btn,
    .quick-amount-btn,
    .product-item,
    .tab,
    .product-tab {
        min-height: 44px;
        min-width: 44px;
    }
}

/* Loading and Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #2563eb;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
