/* Catalog Page Specific Styles */

.catalog-header {
    padding: 120px 0 60px;
    background: linear-gradient(135deg, var(--primary-black), var(--secondary-black));
    text-align: center;
}

.catalog-title h1 {
    font-family: var(--font-primary);
    font-size: 3.5rem;
    background: linear-gradient(45deg, var(--white), var(--primary-gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
}

.catalog-title p {
    font-size: 1.2rem;
    color: var(--medium-gray);
    max-width: 600px;
    margin: 0 auto;
}

/* Filters Section */
.catalog-filters {
    padding: 2rem 0;
    background: var(--secondary-black);
    border-bottom: 1px solid var(--accent-black);
    position: sticky;
    top: 70px;
    z-index: 100;
}

.filters-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr auto;
    gap: 1.5rem;
    align-items: center;
}

.search-box {
    position: relative;
}

.search-box input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    background: var(--accent-black);
    border: 1px solid var(--medium-gray);
    border-radius: 25px;
    color: var(--white);
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-gold);
    box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2);
}

.search-box i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--medium-gray);
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-size: 0.9rem;
    color: var(--primary-gold);
    font-weight: 500;
}

.filter-group select {
    padding: 0.5rem;
    background: var(--accent-black);
    border: 1px solid var(--medium-gray);
    border-radius: 8px;
    color: var(--white);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.filter-group select:focus {
    outline: none;
    border-color: var(--primary-gold);
}

.view-toggle {
    display: flex;
    gap: 0.5rem;
}

.view-btn {
    padding: 0.5rem;
    background: var(--accent-black);
    border: 1px solid var(--medium-gray);
    color: var(--medium-gray);
    border-radius: 6px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.view-btn.active,
.view-btn:hover {
    background: var(--primary-gold);
    color: var(--primary-black);
    border-color: var(--primary-gold);
}

/* Products Section */
.catalog-products {
    padding: 2rem 0 4rem;
    background: var(--primary-black);
}

.products-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--accent-black);
}

.results-count {
    color: var(--medium-gray);
    font-size: 0.9rem;
}

.products-per-page {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.products-per-page label {
    color: var(--medium-gray);
    font-size: 0.9rem;
}

.products-per-page select {
    padding: 0.25rem 0.5rem;
    background: var(--accent-black);
    border: 1px solid var(--medium-gray);
    border-radius: 4px;
    color: var(--white);
    font-size: 0.9rem;
}

/* Products Grid */
.products-grid {
    transition: all var(--transition-fast);
}

.products-grid.grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.products-grid.list-view {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* List View Product Card */
.products-grid.list-view .product-card {
    display: grid;
    grid-template-columns: 200px 1fr auto;
    gap: 1.5rem;
    align-items: center;
    padding: 1.5rem;
}

.products-grid.list-view .product-image {
    height: 150px;
    width: 200px;
}

.products-grid.list-view .product-info {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 1rem;
    align-items: start;
    padding: 0;
}

.products-grid.list-view .product-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.products-grid.list-view .product-actions {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    min-width: 150px;
}

.products-grid.list-view .product-price {
    font-size: 1.8rem;
    margin-bottom: 0;
}

.products-grid.list-view .product-description {
    max-width: none;
    margin-bottom: 0.5rem;
}

/* Enhanced Product Card */
.product-card {
    background: var(--secondary-black);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--accent-black);
    transition: all var(--transition-fast);
    position: relative;
    cursor: pointer;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
    border-color: var(--primary-gold);
}

.product-card.out-of-stock {
    opacity: 0.6;
}

.product-card.out-of-stock::after {
    content: 'Out of Stock';
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: rgba(220, 53, 69, 0.9);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 2;
}

.product-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--primary-gold);
    color: var(--primary-black);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 2;
}

.product-badge.new {
    background: #28a745;
    color: white;
}

.product-badge.bestseller {
    background: #dc3545;
    color: white;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 3rem;
}

.page-btn {
    padding: 0.5rem 1rem;
    background: var(--accent-black);
    border: 1px solid var(--medium-gray);
    color: var(--white);
    border-radius: 8px;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.page-btn:hover:not(:disabled) {
    background: var(--primary-gold);
    color: var(--primary-black);
    border-color: var(--primary-gold);
}

.page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-numbers {
    display: flex;
    gap: 0.5rem;
}

.page-number {
    padding: 0.5rem 0.75rem;
    background: var(--accent-black);
    border: 1px solid var(--medium-gray);
    color: var(--white);
    border-radius: 6px;
    cursor: pointer;
    transition: all var(--transition-fast);
    min-width: 40px;
    text-align: center;
}

.page-number.active {
    background: var(--primary-gold);
    color: var(--primary-black);
    border-color: var(--primary-gold);
}

.page-number:hover:not(.active) {
    background: var(--secondary-black);
    border-color: var(--primary-gold);
}

/* Loading State */
.loading-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 4rem;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--accent-black);
    border-top: 4px solid var(--primary-gold);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* No Results */
.no-results {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--medium-gray);
}

.no-results i {
    font-size: 4rem;
    color: var(--primary-gold);
    margin-bottom: 1rem;
}

.no-results h3 {
    font-family: var(--font-primary);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--white);
}

/* Filter Tags */
.active-filters {
    margin-bottom: 1rem;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.filter-tag {
    background: var(--primary-gold);
    color: var(--primary-black);
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.filter-tag .remove {
    cursor: pointer;
    font-weight: bold;
    margin-left: 0.25rem;
}

.filter-tag .remove:hover {
    color: #dc3545;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .filters-container {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .search-box {
        order: -1;
    }
    
    .filter-groups {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1rem;
    }
}

@media (max-width: 968px) {
    .catalog-title h1 {
        font-size: 2.5rem;
    }
    
    .filters-container {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .products-header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .products-grid.list-view .product-card {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .products-grid.list-view .product-info {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .catalog-header {
        padding: 100px 0 40px;
    }
    
    .catalog-title h1 {
        font-size: 2rem;
    }
    
    .catalog-filters {
        position: static;
    }
    
    .products-grid.grid-view {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 1rem;
    }
    
    .products-grid.list-view .product-card {
        padding: 1rem;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .catalog-title h1 {
        font-size: 1.8rem;
    }
    
    .products-grid.grid-view {
        grid-template-columns: 1fr;
    }
    
    .page-numbers {
        display: none;
    }
}

/* Advanced Animations */
.product-card {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.6s ease-out forwards;
}

.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.2s; }
.product-card:nth-child(3) { animation-delay: 0.3s; }
.product-card:nth-child(4) { animation-delay: 0.4s; }
.product-card:nth-child(5) { animation-delay: 0.5s; }
.product-card:nth-child(6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hover Effects */
.product-card:hover .image-placeholder {
    transform: scale(1.05);
}

.product-card .image-placeholder {
    transition: transform var(--transition-fast);
}

/* Enhanced Quick Actions */
.quick-actions {
    position: absolute;
    top: 1rem;
    left: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    opacity: 0;
    transform: translateX(-20px);
    transition: all var(--transition-fast);
}

.product-card:hover .quick-actions {
    opacity: 1;
    transform: translateX(0);
}

.quick-action {
    width: 35px;
    height: 35px;
    background: rgba(10, 10, 10, 0.8);
    border: 1px solid var(--primary-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-gold);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.quick-action:hover {
    background: var(--primary-gold);
    color: var(--primary-black);
    transform: scale(1.1);
}

/* Product Comparison */
.compare-checkbox {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.product-card:hover .compare-checkbox {
    opacity: 1;
}

.compare-bar {
    position: fixed;
    bottom: -100px;
    left: 0;
    right: 0;
    background: var(--secondary-black);
    border-top: 2px solid var(--primary-gold);
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: bottom var(--transition-fast);
    z-index: 1000;
}

.compare-bar.active {
    bottom: 0;
}

.compare-items {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.compare-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--accent-black);
    padding: 0.5rem;
    border-radius: 8px;
}

.compare-item .remove {
    color: var(--primary-gold);
    cursor: pointer;
}

.nav-link.active {
    color: var(--primary-gold);
}

.nav-link.active::after {
    width: 100%;
}