body { background-color: #f0f2f5; font-family: 'Segoe UI', sans-serif; }
.main-content { margin-left: 0; padding: 20px; transition: 0.3s; }

/* Eğer sidebar varsa PHP'den style olarak margin eklenecek, varsayılan 0 */

.guest-banner { background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%); border-radius: 16px; color: white; padding: 30px; margin-bottom: 25px; box-shadow: 0 8px 24px rgba(13, 110, 253, 0.25); text-align: center; }
.guest-banner h3 { font-weight: 800; margin-bottom: 10px; }
.guest-banner p { margin-bottom: 20px; opacity: 0.95; }
.guest-banner .btn { font-weight: 700; padding: 12px 32px; font-size: 1.1rem; }

.info-banner { background: linear-gradient(135deg, #198754 0%, #20c997 100%); border-radius: 16px; color: white; padding: 25px; position: relative; overflow: hidden; margin-bottom: 25px; box-shadow: 0 8px 24px rgba(25, 135, 84, 0.25); }
.info-banner::after { content: '\f4c4'; font-family: "Font Awesome 6 Free"; font-weight: 900; position: absolute; right: 30px; top: 50%; transform: translateY(-50%); font-size: 5rem; opacity: 0.1; color: white; }

.ticker-container { display: flex; align-items: center; background: white; border-radius: 12px; overflow: hidden; border: 1px solid #e9ecef; margin-bottom: 20px; box-shadow: 0 4px 12px rgba(0,0,0,0.05); }
.ticker-label { background: #198754; color: white; font-weight: 800; font-size: 0.85rem; padding: 8px 15px; white-space: nowrap; z-index: 2; }
.ticker-wrap { flex-grow: 1; overflow: hidden; white-space: nowrap; }
.ticker-move { display: inline-block; animation: ticker 60s linear infinite; }
.ticker-item { display: inline-block; padding: 8px 20px; font-size: 0.85rem; border-right: 1px solid #f0f0f0; }
@keyframes ticker { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* YAPIŞKAN (STICKY) KATEGORİ BARI */
.category-scroll-container { 
    display: flex; gap: 12px; overflow-x: auto; padding: 10px 10px 15px 10px; 
    scroll-behavior: smooth; -webkit-overflow-scrolling: touch; 
    scrollbar-width: thin; 
    scrollbar-color: #198754 #e9ecef; 
    position: sticky; top: 0; z-index: 1020; background: #f0f2f5; 
    margin-left: -15px; margin-right: -15px;
}
.category-scroll-container::-webkit-scrollbar { height: 6px; }
.category-scroll-container::-webkit-scrollbar-track { background: #e9ecef; border-radius: 10px; }
.category-scroll-container::-webkit-scrollbar-thumb { background: #198754; border-radius: 10px; }
.category-scroll-container::-webkit-scrollbar-thumb:hover { background: #157347; }

.modern-cat-btn { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; padding: 8px 20px; background: white; border: 2px solid #eef2f6; border-radius: 50px; text-decoration: none; color: #555; transition: all 0.3s ease; box-shadow: 0 2px 5px rgba(0,0,0,0.02); white-space: nowrap; font-weight: 600; font-size: 0.9rem; }
.modern-cat-btn:hover { transform: translateY(-2px); box-shadow: 0 4px 10px rgba(0,0,0,0.08); color: #198754; border-color: #198754; }
.modern-cat-btn.active { background: linear-gradient(145deg, #198754, #157347); color: white; border-color: #198754; box-shadow: 0 4px 12px rgba(25, 135, 84, 0.3); }

/* SKELETON LOADER CSS */
.skeleton-card { border: 1px solid #eef2f6; border-radius: 20px; background: #fff; overflow: hidden; height: 100%; display: flex; flex-direction: column; pointer-events: none; }
.skeleton-pulse { animation: shimmer 1.5s infinite linear; background: linear-gradient(90deg, #f0f2f5 25%, #e2e8f0 50%, #f0f2f5 75%); background-size: 200% 100%; }
.skeleton-img { height: 240px; width: 100%; }
.skeleton-body { padding: 15px; display: flex; flex-direction: column; flex-grow: 1; gap: 10px; }
.skeleton-title { height: 20px; width: 80%; border-radius: 4px; }
.skeleton-price { height: 24px; width: 40%; border-radius: 4px; align-self: flex-end; margin-top: -30px; }
.skeleton-line { height: 14px; width: 100%; border-radius: 4px; }
.skeleton-line.short { width: 60%; }
.skeleton-footer { display: flex; align-items: center; gap: 10px; margin-top: auto; padding-top: 15px; border-top: 1px solid #eee; }
.skeleton-avatar { width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* VİTRİN SLIDER CSS */
.showcase-wrapper { margin-bottom: 30px; }
.showcase-header { display: flex; align-items: center; margin-bottom: 15px; padding-left: 5px;}
.showcase-header h5 { font-weight: 800; color: #212529; margin: 0; display: flex; align-items: center; }
.showcase-scroll { display: flex; gap: 15px; overflow-x: auto; padding-bottom: 20px; padding-left: 5px; padding-right: 5px; scroll-behavior: smooth; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.showcase-scroll::-webkit-scrollbar { display: none; }
.showcase-item { flex: 0 0 280px; }
@media (max-width: 768px) { .showcase-item { flex: 0 0 240px; } }
.showcase-card { border: 2px solid #ffc107 !important; box-shadow: 0 8px 25px rgba(255, 193, 7, 0.2) !important; background: linear-gradient(180deg, #fffdf5 0%, #ffffff 100%) !important; }

/* PRODUCT CARDS */
.product-card { border: 1px solid #eef2f6; border-radius: 20px; background: white; transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); overflow: hidden; height: 100%; position: relative; display: flex; flex-direction: column; }
.product-card:hover { transform: translateY(-8px); box-shadow: 0 16px 40px rgba(0,0,0,0.12); border-color: #d0d7de; }

.product-card.pending-listing { border: 2px dashed #ffc107; background-color: #fffdf5; opacity: 0.9; }
.badge-pending { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 30; background: rgba(0, 0, 0, 0.7); color: white; padding: 10px 20px; border-radius: 50px; font-weight: bold; white-space: nowrap; backdrop-filter: blur(4px); box-shadow: 0 4px 15px rgba(0,0,0,0.3); font-size: 0.9rem; pointer-events: none;}

.product-card.pro-listing { border: 2px solid #eef2f6; background: linear-gradient(180deg, #fffefb 0%, #ffffff 100%); }
.product-card.pro-listing::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: linear-gradient(90deg, #ffc107, #ff9800); }
.pro-badge { position: absolute; top: 12px; left: 12px; z-index: 20; background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%); color: #000; padding: 6px 12px; border-radius: 8px; font-size: 0.7rem; font-weight: 800; box-shadow: 0 4px 12px rgba(255, 193, 7, 0.4); animation: pulse-badge 2s infinite; }

.firsat-badge { position: absolute; top: 12px; right: 12px; z-index: 25; background: linear-gradient(135deg, #198754, #20c997); color: white; padding: 6px 12px; border-radius: 8px; font-weight: 800; font-size: 0.75rem; letter-spacing: 0.5px; box-shadow: 0 3px 10px rgba(25, 135, 84, 0.5); animation: pulse 2s infinite; display:flex; align-items:center; gap:5px;}

@keyframes pulse-badge { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }
.product-card.sponsored-listing { border: 2px solid #FFD700 !important; background: linear-gradient(180deg, #fffff0 0%, #ffffff 100%) !important; box-shadow: 0 0 20px rgba(255, 215, 0, 0.25); z-index: 2; }
.product-card.sponsored-listing:hover { box-shadow: 0 0 25px rgba(255, 215, 0, 0.4); transform: translateY(-7px) scale(1.01); }
.badge-sponsored { position: absolute; top: 12px; left: 12px; z-index: 25; background: linear-gradient(135deg, #FFD700, #FFC107); color: #000; padding: 6px 12px; border-radius: 8px; font-weight: 800; font-size: 0.75rem; letter-spacing: 0.5px; box-shadow: 0 3px 8px rgba(255, 193, 7, 0.4); animation: pulse 2s infinite; }
@keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.05); } 100% { transform: scale(1); } }
.btn-boost { background: linear-gradient(135deg, #6610f2, #6f42c1); color: white; border: none; font-size: 0.8rem; font-weight: bold; padding: 5px 15px; border-radius: 20px; box-shadow: 0 4px 10px rgba(111, 66, 193, 0.3); transition: 0.3s; width: 100%; display: block; margin-top: 5px; }

.img-container { height: 240px; position: relative; overflow: hidden; background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%); }
.img-container img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1); }
.product-card:not(.pending-listing):hover .img-container img { transform: scale(1.08); }
.price-badge { font-size: 1.3rem; font-weight: 800; color: #198754; text-shadow: 0 1px 2px rgba(0,0,0,0.1); }

.seller-info-box { display: flex; flex-direction: column; justify-content: center;}
.seller-stars { color: #ffc107; font-size: 0.75rem; display: flex; align-items: center; gap: 2px;}

.card-actions { position: absolute; top: 12px; right: 12px; z-index: 20; display: flex; gap: 8px; }
.has-firsat .card-actions { top: 45px; }

.action-btn { width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,0.95); backdrop-filter: blur(10px); display: flex; align-items: center; justify-content: center; color: #555; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); border: none; cursor: pointer; box-shadow: 0 4px 12px rgba(0,0,0,0.15); }
.action-btn.active { color: #dc3545; background: #fff; }
.action-btn.fav-active { color: #ffc107; background: #fff; }
.feature-badge { font-size: 0.7rem; padding: 4px 10px; border-radius: 6px; font-weight: 700; color: white; box-shadow: 0 2px 6px rgba(0,0,0,0.2); }

.bg-organic { background-color: #198754; }
.bg-fast { background-color: #0d6efd; }
.bg-bulk { background-color: #fd7e14; }
.bg-shipping { background-color: #6610f2; }
.bg-negotiate { background-color: #20c997; }

.desc-truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; font-size: 0.9rem; color: #6c757d; height: 1.5em; line-height: 1.5; cursor: help; }
.modal-content { border-radius: 24px; border: none; box-shadow: 0 20px 60px rgba(0,0,0,0.3); }
.type-option { display: none; }
.type-label { display: flex; align-items: center; justify-content: center; gap: 10px; border: 2px solid #dee2e6; border-radius: 12px; padding: 16px; cursor: pointer; transition: all 0.3s; background: #fff; height: 100%; color: #555; font-size: 1rem; font-weight: 600; }
.type-label:hover { background: #f8f9fa; border-color: #adb5bd; transform: translateY(-2px); }
.type-option:checked + .type-label.sell-label { border-color: #198754; background: #d1e7dd; color: #198754; box-shadow: 0 4px 12px rgba(25, 135, 84, 0.2); border-width: 3px; }
.type-option:checked + .type-label.buy-label { border-color: #0d6efd; background: #cfe2ff; color: #0d6efd; box-shadow: 0 4px 12px rgba(13, 110, 253, 0.2); border-width: 3px; }
.upload-area { border: 3px dashed #dee2e6; border-radius: 16px; padding: 20px; text-align: center; background: #f8f9fa; cursor: pointer; transition: all 0.3s; }
.upload-area:hover { border-color: #198754; background: #f0fff4; }

/* 🚀 YENİ: KOMPAKT ÜST MENÜ HİZALAMASI */
.compact-menu-wrapper {
    display: flex;
    flex-wrap: wrap; /* Ekran küçülürse alt alta geçmeye izin ver */
    align-items: center;
    gap: 15px; /* Elemanlar arası sabit boşluk */
    width: 100%;
}

.compact-search-form {
    flex: 0 1 350px; /* Arama çubuğu genişlesin ama en fazla 350px olsun. Ortada devasa boşluk yaratmasın. */
    min-width: 200px;
    margin-bottom: 0 !important;
}

.compact-filter-group,
.compact-action-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

@media (max-width: 991px) {
    .compact-search-form {
        flex: 1 1 100%; /* Mobilde arama çubuğu tam genişlik alsın */
        max-width: 100%;
    }
    .compact-filter-group {
        flex: 1 1 auto; /* Satılık/Alım butonları mobilde sola yaslı genişlesin */
    }
}

@media (max-width: 768px) {
    .main-content { margin-left: 0 !important; padding: 8px; padding-bottom: 100px; }
    #sidebar { display: none; }
    .desktop-actions { display: none !important; }
    .img-container { height: 200px; } 
    .modern-cat-btn { padding: 6px 14px; font-size: 0.8rem; }
    #itemModal .modal-body { padding-bottom: 100px !important; max-height: 80vh; overflow-y: auto; }
    .category-scroll-container { top: 0px; padding-top: 15px; } 
    .mobile-cat-dropdown {
        width: 260px !important;
        max-width: 85vw !important;
        z-index: 1050 !important;
        padding-right: 5px !important;
    }
    .mobile-cat-dropdown .dropdown-item { white-space: normal !important; }
}