/* Products Section */
.products-section {
    padding: 60px 0 100px;
    background-color: var(--primary-white);
}

/* Page Title */
.page-title {
    margin-bottom: 40px;
}

.page-title h1 {
    font-size: 72px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -3px;
    line-height: 1;
}

.page-title h1 sup {
    font-size: 18px;
    font-weight: 500;
    vertical-align: super;
    letter-spacing: 0;
}

/* Filters Bar */
.filters-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-top: 1px solid #e0e0e0;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 40px;
}

.filters-left {
    display: flex;
    gap: 30px;
}

.filter-dropdown {
    position: relative;
}

.filter-btn {
    background: none;
    border: none;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-btn .arrow {
    font-size: 8px;
    transition: transform 0.3s ease;
}

.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--primary-white);
    border: 1px solid #e0e0e0;
    min-width: 180px;
    padding: 15px;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.dropdown-content.show {
    display: block;
}

.dropdown-content label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 13px;
    cursor: pointer;
}

.dropdown-content label:hover {
    color: #666;
}

.dropdown-content input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* Size Dropdown Styling */
.size-dropdown {
    /* Display handled by show class */
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    min-width: 200px;
    padding: 10px;
}

.size-dropdown.show {
    display: grid;
}

.size-dropdown label {
    padding: 0;
    margin: 0;
    display: block;
}

.size-dropdown input[type="checkbox"] {
    display: none;
}

.size-dropdown label span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 35px;
    border: 1px solid #e0e0e0;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.size-dropdown label:hover span {
    border-color: var(--primary-black);
}

/* Price Filter Styling */
.price-dropdown {
    width: 300px;
    padding: 20px;
}

.price-header-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 12px;
    color: #666;
}

.price-reset {
    color: var(--primary-black);
    text-decoration: underline;
    font-size: 11px;
}

/* Slider */
.price-slider-container {
    position: relative;
    width: 100%;
    height: 30px;
    margin-bottom: 25px;
}

.slider-track {
    width: 100%;
    height: 2px;
    background-color: #e0e0e0;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border-radius: 5px;
}

.price-slider-container input[type="range"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 100%;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    pointer-events: none;
    margin: 0;
}

.price-slider-container input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 16px;
    width: 16px;
    border-radius: 50%;
    background-color: #fff;
    border: 1px solid #000;
    pointer-events: auto;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.price-slider-container input[type="range"]::-moz-range-thumb {
    -webkit-appearance: none;
    height: 16px;
    width: 16px;
    border-radius: 50%;
    background-color: #fff;
    border: 1px solid #000;
    pointer-events: auto;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

/* Inputs */
.price-inputs {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.price-field {
    display: flex;
    align-items: center;
    border: 1px solid #e0e0e0;
    padding: 8px 12px;
    width: 100px;
}

.price-field span {
    font-size: 13px;
    color: #333;
    margin-right: 5px;
}

.price-field input {
    width: 100%;
    border: none;
    outline: none;
    font-size: 13px;
    font-weight: 500;
    color: var(--primary-black);
}

.price-separator {
    font-size: 12px;
    color: #666;
}

/* Chrome/Safari specific reset for input number */
.price-field input[type=number]::-webkit-inner-spin-button,
.price-field input[type=number]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Color Dropdown Styling */
.color-dropdown label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    transition: background 0.2s ease;
}

.color-dropdown label:hover {
    background-color: #f5f5f5;
}

.color-dropdown input[type="checkbox"] {
    display: none;
}

.color-dropdown label span:last-child {
    font-size: 13px;
    font-weight: 500;
}

.color-dropdown .color-swatch {
    display: inline-block;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 1px solid #e0e0e0;
    position: relative;
}

.color-dropdown input:checked+.color-swatch::after {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    border: 1px solid var(--primary-black);
    border-radius: 50%;
}

/* Sort Dropdown */
.filters-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sort-dropdown {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sort-dropdown span {
    font-size: 12px;
    font-weight: 600;
    color: #666;
}

.sort-dropdown select {
    border: none;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    background: transparent;
    cursor: pointer;
    padding: 5px 0;
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

/* Product Card Listing */
.product-card-listing {
    position: relative;
    cursor: pointer;
}

.product-badges {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
}

.badge {
    display: inline-block;
    padding: 5px 10px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.badge.sale {
    background: var(--primary-black);
    color: var(--primary-white);
}

.badge.discount {
    background: var(--primary-black);
    color: var(--primary-white);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    font-size: 11px;
}

.product-image-listing {
    aspect-ratio: 1;
    overflow: hidden;
    margin-bottom: 15px;
    background: #f8f8f8;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-listing img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-card-listing:hover .product-image-listing img {
    transform: scale(1.05);
}

.product-info-listing {
    margin-bottom: 10px;
}

.product-info-listing h3 {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}

.price-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.original-price {
    font-size: 13px;
    color: #999;
    text-decoration: line-through;
}

.sale-price {
    font-size: 13px;
    font-weight: 600;
}

.current-price {
    font-size: 13px;
    font-weight: 600;
}

/* Color Swatches */
.color-swatches {
    display: flex;
    gap: 8px;
    margin-bottom: 15px;
}

.swatch {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.swatch:hover {
    transform: scale(1.1);
}

.swatch.active {
    box-shadow: 0 0 0 2px var(--primary-white), 0 0 0 3px var(--primary-black);
}

/* Product Tags */
.product-tags {
    display: flex;
    gap: 5px;
    overflow: hidden;
    white-space: nowrap;
}

.tag {
    padding: 4px 8px;
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    flex-shrink: 0;
}

.tag.sale-tag {
    background: var(--primary-black);
    color: var(--primary-white);
}

.tag.flash-tag {
    background: #f0f0f0;
    color: var(--primary-black);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 60px;
}

.page-nav,
.page-num {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.page-nav {
    font-size: 16px;
}

.page-nav:hover:not(:disabled) {
    background: #f0f0f0;
}

.page-nav:disabled {
    color: #ccc;
    cursor: not-allowed;
}

.page-num {
    border: 2px solid transparent;
}

.page-num:hover {
    border-color: #e0e0e0;
}

.page-num.active {
    background: var(--primary-black);
    color: var(--primary-white);
    border-color: var(--primary-black);
}

/* Responsive */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .page-title h1 {
        font-size: 56px;
    }

    .filters-bar {
        flex-direction: column;
        gap: 20px;
        align-items: flex-start;
    }

    .filters-left {
        flex-wrap: wrap;
    }
}

@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .page-title h1 {
        font-size: 42px;
    }

    .filters-left {
        gap: 15px;
    }

    .filter-btn {
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr;
    }
}