/* Product Listing Page Styles */
/* Professional & Modern Design 3b82f6 */

:root {
    --primary-color: #2563EB;
    --secondary-color: #1e40af;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --dark-color: #1f2937;
    --light-color: #f9fafb;
    --border-color: #e5e7eb;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --transition: all 0.3s ease;
}

/* ===== Page Header ===== */
.page-header {
    padding: 80px 0 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.3;
}

.page-header .breadcrumb {
    background: transparent;
    padding: 0;
    margin-bottom: 20px;
}

.page-header .breadcrumb-item {
    color: rgba(255, 255, 255, 0.8);
}

.page-header .breadcrumb-item + .breadcrumb-item::before {
    content: '›';
    color: rgba(255, 255, 255, 0.6);
}

.page-header .breadcrumb-item a {
    color: white;
    text-decoration: none;
    transition: var(--transition);
}

.page-header .breadcrumb-item a:hover {
    color: rgba(255, 255, 255, 0.8);
}

.page-header .breadcrumb-item.active {
    color: rgba(255, 255, 255, 0.9);
}

.page-title {
    font-size: 3rem;
    font-weight: 900;
    color: white;
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.page-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    position: relative;
    z-index: 1;
}

/* ===== Filter Section ===== */
.filter-section {
    padding: 40px 0;
    background: white;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.search-box {
    position: relative;
}

.search-box i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.search-box .form-control {
    padding: 12px 16px 12px 48px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
    font-size: 1rem;
    transition: var(--transition);
}

.search-box .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    outline: none;
}

.filter-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.filter-btn {
    padding: 10px 20px;
    border: 2px solid var(--border-color);
    background: white;
    color: var(--text-primary);
    border-radius: var(--radius-lg);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.filter-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.filter-btn i {
    font-size: 1rem;
}

/* ===== Products Section ===== */
.products-section {
    padding: 80px 0;
    background: var(--light-color);
    min-height: 600px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 32px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Product Card ===== */
.product-card {
    background: white;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.product-image-wrapper {
    position: relative;
    padding: 40px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 220px;
}

.product-image {
    width: 120px;
    height: 120px;
    object-fit: contain;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
    transition: var(--transition);
}

.product-card:hover .product-image {
    transform: scale(1.1) rotate(5deg);
}

.product-badges {
    position: absolute;
    top: 16px;
    left: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.product-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    width: fit-content;
}

.badge-featured {
    background: linear-gradient(135deg, #ffd700 0%, #ffa500 100%);
    color: #1a1a1a;
}

.badge-new {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.badge-popular {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.badge-free {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.product-content {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-category {
    color: var(--primary-color);
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.product-name {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 12px;
    line-height: 1.3;
}

.product-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 16px;
    flex-grow: 1;
}

.product-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 6px;
}

.rating-stars {
    display: flex;
    gap: 2px;
}

.rating-stars i {
    color: #fbbf24;
    font-size: 0.9rem;
}

.rating-value {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 0.95rem;
}

.product-platform {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.product-platform i {
    font-size: 1rem;
}

.product-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.product-price {
    font-size: 1.75rem;
    font-weight: 900;
    color: var(--primary-color);
}

.product-price.free {
    color: var(--success-color);
}

.product-actions {
    display: flex;
    gap: 8px;
}

.btn-view {
    padding: 10px 20px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.btn-view:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    color: white;
}

.btn-download {
    padding: 10px 16px;
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: var(--radius-md);
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: var(--transition);
}

.btn-download:hover {
    background: var(--primary-color);
    color: white;
}

/* ===== Loading State ===== */
.loading-state {
    text-align: center;
    padding: 80px 20px;
}

.loading-state .spinner-border {
    width: 3rem;
    height: 3rem;
    margin-bottom: 20px;
}

.loading-state p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* ===== No Results State ===== */
.no-results-state {
    text-align: center;
    padding: 80px 20px;
}

.no-results-state i {
    font-size: 4rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
    opacity: 0.5;
}

.no-results-state h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.no-results-state p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 24px;
}

/* ===== Error State ===== */
.error-state {
    text-align: center;
    padding: 80px 20px;
}

.error-state i {
    font-size: 4rem;
    color: var(--danger-color);
    margin-bottom: 24px;
}

.error-state h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.error-state p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 24px;
}

/* ===== Stats Section ===== */
.stats-section {
    padding: 80px 0;
    background: white;
}

.stat-card {
    text-align: center;
    padding: 32px 20px;
    background: var(--light-color);
    border-radius: var(--radius-xl);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.stat-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.stat-icon i {
    font-size: 1.75rem;
    color: white;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 1rem;
    margin: 0;
}

/* ===== CTA Section ===== */
.cta-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.cta-content {
    text-align: center;
    position: relative;
    z-index: 1;
}

.cta-content h2 {
    font-size: 2.5rem;
    font-weight: 800;
    color: white;
    margin-bottom: 16px;
}

.cta-content p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 32px;
}

.cta-content .btn-light {
    padding: 14px 32px;
    font-weight: 700;
    border-radius: var(--radius-lg);
    display: inline-flex;
    align-items: center;
    gap: 12px;
    transition: var(--transition);
}

.cta-content .btn-light:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* ===== Responsive Design ===== */
@media (max-width: 992px) {
    .page-title {
        font-size: 2.5rem;
    }
    
    .filter-buttons {
        justify-content: flex-start;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .page-title {
        font-size: 2rem;
    }
    
    .page-subtitle {
        font-size: 1.1rem;
    }
    
    .filter-section {
        padding: 24px 0;
    }
    
    .filter-buttons {
        gap: 8px;
    }
    
    .filter-btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .product-footer {
        flex-direction: column;
        align-items: stretch;
    }
    
    .product-actions {
        width: 100%;
    }
    
    .btn-view,
    .btn-download {
        flex: 1;
        justify-content: center;
    }
    
    .cta-content h2 {
        font-size: 1.75rem;
    }
}

@media (max-width: 480px) {
    .page-header {
        padding: 60px 0 40px;
    }
    
    .page-title {
        font-size: 1.75rem;
    }
    
    .filter-btn span {
        display: none;
    }
    
    .product-name {
        font-size: 1.25rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
}
