/* ========== URUNLER PAGE ========== */

.urunler-page {
    padding-top: 18px;
    padding-bottom: 60px;
    min-height: 60vh;
    background: #f8f9fa;
}

/* --- Breadcrumb --- */
.urunler-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #888;
    margin-bottom: 14px;
    flex-wrap: wrap;
}
.urunler-breadcrumb a {
    color: #555;
    text-decoration: none;
    transition: color 0.2s;
}
.urunler-breadcrumb a:hover {
    color: #0d6efd;
}
.urunler-breadcrumb i {
    font-size: 10px;
    color: #bbb;
}
.urunler-breadcrumb span {
    color: #333;
    font-weight: 600;
}

/* --- Page Header --- */
.urunler-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
    flex-wrap: wrap;
    gap: 12px;
}
.urunler-header-left {
    display: flex;
    align-items: baseline;
    gap: 12px;
}
.urunler-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0;
}
.urunler-count {
    font-size: 13px;
    color: #888;
    font-weight: 500;
}

/* Sort */
.urunler-sort-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}
.urunler-sort-wrapper label {
    font-size: 13px;
    color: #666;
    white-space: nowrap;
    margin: 0;
}
.urunler-sort-select {
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    padding: 7px 14px;
    font-size: 13px;
    color: #333;
    background: #fff;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
    min-width: 190px;
}
.urunler-sort-select:focus {
    border-color: #0d6efd;
}

/* --- Quick Filter Tags --- */
.urunler-quick-filters {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}
.quick-filter-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 16px;
    border-radius: 20px;
    border: 1.5px solid #e0e0e0;
    background: #fff;
    color: #444;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}
.quick-filter-tag:hover {
    border-color: #0d6efd;
    color: #0d6efd;
    background: #f0f6ff;
}
.quick-filter-tag.active {
    background: linear-gradient(135deg, #0d6efd, #4f8eff);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.25);
}
.quick-filter-tag.active:hover {
    background: linear-gradient(135deg, #0b5ed7, #3d7cee);
}
.quick-filter-tag i {
    font-size: 13px;
}

/* --- Layout --- */
.urunler-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

/* --- Sidebar --- */
.urunler-sidebar {
    width: 260px;
    min-width: 260px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 1px 8px rgba(0,0,0,0.06);
    padding: 0;
    position: sticky;
    top: 120px;
    max-height: calc(100vh - 140px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #ddd #fff;
}
.urunler-sidebar::-webkit-scrollbar {
    width: 5px;
}
.urunler-sidebar::-webkit-scrollbar-thumb {
    background: #ddd;
    border-radius: 10px;
}
.sidebar-close-btn {
    display: none;
}

/* Filter Groups */
.filter-group {
    border-bottom: 1px solid #f0f0f0;
}
.filter-group:last-child {
    border-bottom: none;
}
.filter-group-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    cursor: pointer;
    user-select: none;
    transition: background 0.15s;
}
.filter-group-header:hover {
    background: #fafafa;
}
.filter-group-header h3 {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a2e;
    margin: 0;
}
.filter-group-header i {
    font-size: 13px;
    color: #999;
    transition: transform 0.25s;
}
.filter-group-body {
    padding: 0 18px 14px;
}

/* Category List */
.filter-category-list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.filter-category-list li {
    margin-bottom: 2px;
}
.filter-category-list a {
    display: block;
    padding: 5px 0;
    font-size: 13px;
    color: #555;
    text-decoration: none;
    transition: color 0.15s;
    border-left: 3px solid transparent;
    padding-left: 10px;
}
.filter-category-list a:hover {
    color: #0d6efd;
}
.filter-category-list a.active {
    color: #0d6efd;
    font-weight: 600;
    border-left-color: #0d6efd;
}

/* Search Box in Filters */
.filter-search-box {
    position: relative;
    margin-bottom: 10px;
}
.filter-search-box i {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 13px;
    color: #aaa;
}
.filter-search-box input {
    width: 100%;
    border: 1.5px solid #e8e8e8;
    border-radius: 8px;
    padding: 7px 10px 7px 32px;
    font-size: 12.5px;
    color: #333;
    outline: none;
    transition: border-color 0.2s;
    background: #fafafa;
}
.filter-search-box input:focus {
    border-color: #0d6efd;
    background: #fff;
}

/* Sub Label */
.filter-sub-label {
    font-size: 12px;
    font-weight: 700;
    color: #333;
    margin-bottom: 6px;
    margin-top: 2px;
}

/* Checkboxes */
.filter-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 0;
    cursor: pointer;
    font-size: 13px;
    color: #444;
    transition: color 0.15s;
}
.filter-checkbox:hover {
    color: #0d6efd;
}
.filter-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #0d6efd;
    cursor: pointer;
    flex-shrink: 0;
}

/* Stars in filter */
.filter-stars {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 13px;
    color: #444;
}
.filter-stars i {
    color: #f5a623;
    font-size: 13px;
}
.filter-stars i.bi-star {
    color: #ddd;
}

/* Show All Button */
.filter-show-all {
    display: block;
    background: none;
    border: none;
    color: #0d6efd;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    padding: 6px 0 0;
    transition: color 0.15s;
}
.filter-show-all:hover {
    color: #0b5ed7;
    text-decoration: underline;
}

/* Color Swatches */
.filter-color-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.filter-color-swatch {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    outline: none;
}
.filter-color-swatch:hover {
    transform: scale(1.15);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.filter-color-swatch.selected {
    border-color: #0d6efd;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.25);
}
.filter-color-swatch.selected::after {
    content: '\2713';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0,0,0,0.4);
}

/* Price Range */
.filter-price-range {
    display: flex;
    align-items: center;
    gap: 6px;
}
.price-input {
    width: 100%;
    border: 1.5px solid #e8e8e8;
    border-radius: 8px;
    padding: 7px 10px;
    font-size: 12.5px;
    color: #333;
    outline: none;
    background: #fafafa;
    transition: border-color 0.2s;
}
.price-input:focus {
    border-color: #0d6efd;
    background: #fff;
}
.price-dash {
    color: #bbb;
    font-weight: 600;
    flex-shrink: 0;
}
.price-apply-btn {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: none;
    background: linear-gradient(135deg, #0d6efd, #4f8eff);
    color: #fff;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s;
}
.price-apply-btn:hover {
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.3);
}

/* --- Products Content Area --- */
.urunler-content {
    flex: 1;
    min-width: 0;
}

/* --- Promoted Store Banner --- */
.urunler-promoted-store {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff;
    border-radius: 14px;
    padding: 14px 20px;
    margin-bottom: 16px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.05);
    border: 1px solid #f0f0f0;
}
.promoted-store-info {
    display: flex;
    align-items: center;
    gap: 12px;
}
.promoted-store-logo {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: cover;
    border: 1px solid #eee;
}
.promoted-store-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.promoted-store-name {
    font-size: 14px;
    font-weight: 700;
    color: #1a1a2e;
}
.promoted-store-badge {
    font-size: 12px;
    color: #0d6efd;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}
.promoted-store-badge i {
    font-size: 13px;
}
.promoted-store-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 18px;
    border-radius: 8px;
    border: 1.5px solid #0d6efd;
    color: #0d6efd;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    white-space: nowrap;
}
.promoted-store-btn:hover {
    background: #0d6efd;
    color: #fff;
}

/* --- Promoted Products Horizontal --- */
.urunler-promoted-products {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
}
.urunler-promoted-products::-webkit-scrollbar {
    display: none;
}
.promoted-product-card {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    border-radius: 12px;
    padding: 10px 14px;
    min-width: 220px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
    border: 1px solid #f0f0f0;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}
.promoted-product-card:hover {
    box-shadow: 0 3px 12px rgba(0,0,0,0.1);
    transform: translateY(-1px);
}
.promoted-product-card img {
    width: 56px;
    height: 56px;
    border-radius: 8px;
    object-fit: cover;
}
.promoted-product-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}
.promoted-product-name {
    font-size: 12px;
    color: #333;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.promoted-product-price {
    font-size: 14px;
    font-weight: 700;
    color: #e74c3c;
}

/* --- Product Grid --- */
.urunler-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 32px;
}

/* Override card styling for grid layout */
.urunler-grid .urun-karti {
    width: 100% !important;
    min-width: 0 !important;
    flex: none !important;
}

/* --- Pagination --- */
.urunler-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 20px 0;
}
.pagination-btn {
    min-width: 40px;
    height: 40px;
    border-radius: 10px;
    border: 1.5px solid #e0e0e0;
    background: #fff;
    color: #555;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.pagination-btn:hover:not(.disabled):not(.active) {
    border-color: #0d6efd;
    color: #0d6efd;
    background: #f0f6ff;
}
.pagination-btn.active {
    background: linear-gradient(135deg, #0d6efd, #4f8eff);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.25);
}
.pagination-btn.disabled {
    opacity: 0.4;
    cursor: not-allowed;
}
.pagination-dots {
    font-size: 14px;
    color: #999;
    letter-spacing: 2px;
    padding: 0 4px;
}

/* --- Mobile Filter Button --- */
.urunler-mobile-filter-btn {
    display: none;
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    z-index: 999;
    padding: 12px 28px;
    border-radius: 30px;
    border: none;
    background: linear-gradient(135deg, #0d6efd, #4f8eff);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(13, 110, 253, 0.35);
    transition: all 0.3s ease;
    gap: 6px;
    align-items: center;
    opacity: 0;
    pointer-events: none;
}
.urunler-mobile-filter-btn.visible {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    pointer-events: auto;
}
.urunler-mobile-filter-btn:hover {
    box-shadow: 0 6px 20px rgba(13, 110, 253, 0.45);
    transform: translateX(-50%) translateY(-2px);
}
.urunler-mobile-filter-btn.visible:hover {
    transform: translateX(-50%) translateY(-2px);
}

/* Sidebar Overlay */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.45);
    z-index: 1049;
    backdrop-filter: blur(2px);
}
.sidebar-overlay.active {
    display: block;
}

/* ========== RESPONSIVE ========== */

/* Tablet */
@media (max-width: 1200px) {
    .urunler-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .urunler-sidebar {
        width: 230px;
        min-width: 230px;
    }
}

@media (max-width: 992px) {
    .urunler-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .urunler-promoted-products {
        gap: 10px;
    }
    .promoted-product-card {
        min-width: 190px;
    }
    .urunler-page-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .urunler-page {
        padding-top: 12px;
        padding-bottom: 100px;
    }

    /* Container sol/sağ boşluğunu azalt */
    .urunler-page .container-fluid {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    .urunler-sidebar {
        position: fixed;
        top: 0;
        left: -300px;
        width: 290px;
        min-width: 290px;
        height: 100vh;
        max-height: 100vh;
        z-index: 1050;
        border-radius: 0 14px 14px 0;
        transition: left 0.3s ease;
        box-shadow: 4px 0 24px rgba(0,0,0,0.15);
    }
    .urunler-sidebar.open {
        left: 0;
    }

    .sidebar-close-btn {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        padding: 14px 18px 0;
        cursor: pointer;
    }
    .sidebar-close-btn i {
        font-size: 20px;
        color: #666;
        transition: color 0.15s;
    }
    .sidebar-close-btn:hover i {
        color: #e74c3c;
    }

    .urunler-mobile-filter-btn {
        display: flex;
    }

    .urunler-layout {
        gap: 0;
    }

    .urunler-title {
        font-size: 18px;
    }
    .urunler-count {
        font-size: 12px;
    }

    .urunler-quick-filters {
        gap: 6px;
        margin-bottom: 14px;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 4px;
        scrollbar-width: none;
    }
    .urunler-quick-filters::-webkit-scrollbar {
        display: none;
    }
    .quick-filter-tag {
        padding: 6px 12px;
        font-size: 12px;
    }

    .urunler-promoted-store {
        padding: 10px 14px;
        border-radius: 10px;
    }
    .promoted-store-logo {
        width: 36px;
        height: 36px;
    }
    .promoted-store-name {
        font-size: 13px;
    }
    .promoted-store-btn {
        padding: 6px 12px;
        font-size: 12px;
    }

    .urunler-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .pagination-btn {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .urunler-promoted-store {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    .promoted-product-card {
        min-width: 170px;
        padding: 8px 10px;
    }
    .promoted-product-card img {
        width: 44px;
        height: 44px;
    }
}

/* --- Empty State --- */
.urunler-empty-state {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 400px;
    background: #fff;
    border-radius: 16px;
    padding: 40px 20px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.04);
}
.empty-state-content {
    max-width: 450px;
}
.empty-state-icon {
    width: 80px;
    height: 80px;
    background: #f0f6ff;
    color: #0d6efd;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    margin: 0 auto 24px;
}
.empty-state-content h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 12px;
}
.empty-state-content p {
    font-size: 15px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 30px;
}
.btn-empty-state-action {
    display: inline-block;
    background: linear-gradient(135deg, #0d6efd, #4f8eff);
    color: #fff;
    padding: 12px 30px;
    border-radius: 10px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.2);
}
.btn-empty-state-action:hover {
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(13, 110, 253, 0.3);
}

/* --- Out of Stock States --- */
.urun-karti.urun-stokta-yok {
    position: relative;
}
.urun-karti.urun-stokta-yok .urun-karti-image img {
    filter: grayscale(1) opacity(0.6);
}
.urun-karti.urun-stokta-yok::after {
    content: 'STOKTA YOK';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-15deg);
    background: rgba(231, 76, 60, 0.9);
    color: #fff;
    padding: 8px 20px;
    font-weight: 800;
    font-size: 14px;
    border-radius: 4px;
    z-index: 10;
    pointer-events: none;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    border: 2px solid #fff;
    letter-spacing: 1px;
}
.urun-karti.urun-stokta-yok .urun-sepet-btn {
    background: #f1f5f9 !important;
    color: #94a3b8 !important;
    cursor: not-allowed;
    border-color: #e2e8f0 !important;
}
.urun-karti.urun-stokta-yok .urun-sepet-btn i {
    color: #94a3b8 !important;
}
