/* ========================================
   Products Page Styles
   ======================================== */

/* Mobile Filter Overlay */
.mobile-filter-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-filter-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Filter Sidebar */
.filter-sidebar {
    background: white;
    padding: 20px;
    border-radius: 10px;
    border: 1px solid #dee2e6;
    position: relative;
}

/* Mobile Filter Header (Hidden on desktop) */
.mobile-filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 15px;
    margin-bottom: 20px;
    border-bottom: 2px solid #FF8C00;
}

.mobile-filter-header h5 {
    font-weight: 600;
    color: #333;
}

/* Filter Groups */
.filter-group {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e9ecef;
}

.filter-group:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.filter-title {
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 1rem;
    color: #333;
}

.form-check {
    margin-bottom: 10px;
}

.form-check-label {
    font-size: 0.9rem;
    cursor: pointer;
}

/* Results Header */
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.results-info h4 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
}

.results-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sort-select {
    min-width: 150px;
}

/* Product Card */
.product-card {
    border: 1px solid #dee2e6;
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
    background: white;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.product-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1/1;
    background: #f8f9fa;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 10px;
    /* left: 10px; */
    background: #ff6b6b;
    color: white;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 600;
    z-index: 2;
}

.badge-featured {
    background: #28a745;
}

.badge-discount {
    background: #ff6b6b;
}

.wishlist-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 2;
    font-size: 14px;
}

.wishlist-btn:hover {
    background: #FF8C00;
    color: white;
    transform: scale(1.1);
}

.wishlist-btn.active {
    background: #dc3545;
    color: white;
}

.wishlist-btn.active i {
    color: white;
}

.product-info {
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-category {
    color: #6c757d;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    display: block;
}

.product-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.3;
    min-height: 36px;
}

.product-title a {
    color: #333;
    text-decoration: none;
}

.product-title a:hover {
    color: #FF8C00;
}

.product-description {
    color: #6c757d;
    font-size: 12px;
    margin-bottom: 10px;
    display: none;
}

.product-price {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.current-price {
    font-size: 18px;
    font-weight: 700;
    color: #FF8C00;
}

.original-price {
    font-size: 13px;
    color: #6c757d;
    text-decoration: line-through;
}

.subscription-info {
    background: #e7f3ff;
    padding: 6px 8px;
    border-radius: 6px;
    font-size: 11px;
    margin-bottom: 10px;
    display: none;
}

.product-actions {
    margin-top: auto;
}

.product-actions .btn {
    font-size: 12px;
    padding: 6px 12px;
}

/* List View Styles */
.list-view {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.list-view .product-card {
    flex-direction: row;
    max-width: 100%;
}

.list-view .product-image {
    width: 200px;
    aspect-ratio: 1/1;
    flex-shrink: 0;
}

.list-view .product-info {
    flex: 1;
    padding: 20px;
}

.list-view .product-description {
    display: block;
}

/* Mobile Responsive Styles */
@media (max-width: 991px) {
    /* Mobile Filter Sidebar */
    .filter-sidebar {
        position: fixed;
        top: 0;
        left: -100%;
        width: 85%;
        max-width: 320px;
        height: 100vh;
        z-index: 1050;
        overflow-y: auto;
        transition: left 0.3s ease;
        border-radius: 0;
        border: none;
        padding-top: 10px;
    }
    
    .filter-sidebar.active {
        left: 0;
    }
    
    .mobile-filter-header {
        position: sticky;
        top: 0;
        background: white;
        z-index: 10;
        margin: -10px -20px 20px -20px;
        padding: 15px 20px;
    }
}

/* Tablet (768px - 991px) */
@media (min-width: 768px) and (max-width: 991px) {
    .product-title {
        font-size: 15px;
        min-height: 40px;
    }
    
    .current-price {
        font-size: 20px;
    }
    
    .product-badge {
        font-size: 11px;
        padding: 5px 12px;
    }
    
    .wishlist-btn {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
    
    .product-description {
        display: block;
        font-size: 13px;
    }
    
    .subscription-info {
        display: block;
        font-size: 12px;
    }
}

/* Desktop (992px+) */
@media (min-width: 992px) {
    .product-title {
        font-size: 16px;
        min-height: 48px;
    }
    
    .current-price {
        font-size: 22px;
    }
    
    .original-price {
        font-size: 15px;
    }
    
    .product-badge {
        font-size: 12px;
        padding: 5px 12px;
    }
    
    .wishlist-btn {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
    
    .product-info {
        padding: 16px;
    }
    
    .product-category {
        font-size: 11px;
    }
    
    .product-description {
        display: block;
        font-size: 13px;
    }
    
    .subscription-info {
        display: block;
        font-size: 12px;
    }
    
    .product-actions .btn {
        font-size: 13px;
        padding: 8px 16px;
    }
}

/* Extra Small Mobile (< 375px) */
@media (max-width: 374px) {
    .product-title {
        font-size: 13px;
        min-height: 32px;
    }
    
    .current-price {
        font-size: 16px;
    }
    
    .original-price {
        font-size: 12px;
    }
    
    .product-badge {
        font-size: 9px;
        padding: 3px 8px;
    }
    
    .wishlist-btn {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
    
    .product-info {
        padding: 10px;
    }
    
    .product-actions .btn {
        font-size: 11px;
        padding: 5px 10px;
    }
}

/* Filter Button Badge */
#activeFiltersCount {
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 10px;
}

/* Breadcrumb Responsive */
@media (max-width: 575px) {
    .breadcrumb-section {
        padding: 15px 0;
        margin-bottom: 20px;
    }
    
    .breadcrumb {
        font-size: 0.85rem;
    }
}

/* Results Header Responsive */
@media (max-width: 575px) {
    .results-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .results-info h4 {
        font-size: 1.2rem;
    }
    
    .results-info p {
        font-size: 0.85rem;
    }
    
    .results-controls {
        width: 100%;
        justify-content: space-between;
    }
    
    .sort-select {
        flex: 1;
        min-width: auto;
        font-size: 0.85rem;
    }
}

/* Pagination Responsive */
@media (max-width: 575px) {
    .pagination {
        font-size: 0.85rem;
    }
    
    .page-link {
        padding: 0.4rem 0.7rem;
    }
}