/**
 * FŐ STÍLUS FÁJL
 * 
 * Ez a fájl tartalmazza az összes CSS stílust a weboldalhoz.
 * Minden stílus centralizálva van itt, könnyen módosítható és karbantartható.
 * 
 * Felépítés:
 * 1. Globális stílusok
 * 2. Header és Footer
 * 3. Szűrősáv és űrlapok
 * 4. Termék kártyák és grid
 * 5. Lapozás
 * 6. Speciális elemek (badge-ek, stb.)
 */

/* ============================================
   1. GLOBÁLIS STÍLUSOK
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #334155;
    background-color: #f8fafc;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: inherit;
}

.fix-special-chars {
    /* Speciális karakterek javítása */
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* ============================================
   2. HEADER ÉS FOOTER
   ============================================ */
.header {
    background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
    color: white;
    padding: 30px 0;
    margin-bottom: 40px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border-bottom: 5px solid #10b981;
}

.header h1 {
    font-size: 2.8rem;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.header h1 i {
    font-size: 2.5rem;
    color: #10b981;
}

.header-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 300;
}

.footer {
    background: #1e293b;
    color: #cbd5e1;
    padding: 30px 0;
    margin-top: 50px;
    text-align: center;
    border-top: 5px solid #3b82f6;
}

.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.footer-link {
    color: #cbd5e1;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s;
}

.footer-link:hover {
    color: #60a5fa;
}

.footer-link i {
    font-size: 1.1rem;
}

/* ============================================
   3. SZŰRŐSÁV ÉS ŰRLAPOK
   ============================================ */
.filter-bar {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
}

.filter-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.filter-group {
    flex: 1;
    min-width: 250px;
}

.filter-label {
    display: block;
    font-weight: 600;
    color: #475569;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.filter-label i {
    margin-right: 8px;
    color: #3b82f6;
}

.search-input,
.select-input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
    background: white;
}

.search-input:focus,
.select-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.filter-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e2e8f0;
}

.search-btn,
.reset-btn {
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
}

.search-btn {
    background: #3b82f6;
    color: white;
    border: none;
}

.search-btn:hover {
    background: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.reset-btn {
    background: #f1f5f9;
    color: #64748b;
    border: 2px solid #cbd5e1;
}

.reset-btn:hover {
    background: #e2e8f0;
    color: #475569;
}

/* Teljes laptop szűrő speciális stílusai */
.filter-checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.filter-checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    flex: 1;
    font-size: 0.95rem;
    color: #475569;
}

.filter-checkbox-controls {
    display: flex;
    gap: 5px;
    margin-left: 10px;
}

.filter-checkbox-btn {
    background: #e2e8f0;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 12px;
    cursor: pointer;
    color: #64748b;
    text-decoration: none;
    transition: all 0.2s;
}

.filter-checkbox-btn:hover {
    background: #cbd5e1;
}

.filter-checkbox-btn.active {
    background: #3b82f6;
    color: white;
    border-color: #2563eb;
}

.filter-checkbox-btn.disabled {
    background: #f1f5f9;
    color: #94a3b8;
    cursor: not-allowed;
}

/* ============================================
   4. EREDMÉNY INFORMÁCIÓK
   ============================================ */
.results-info {
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 25px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 15px;
    border: 1px solid #e2e8f0;
}

.results-text {
    color: #475569;
    line-height: 1.5;
}

.results-text strong {
    color: #1e293b;
}

/* ============================================
   5. TERMÉK KÁRTYÁK ÉS GRID
   ============================================ */
.products-container {
    margin-bottom: 40px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 25px;
    padding: 10px 0;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
    position: relative;
    display: block;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: #cbd5e1;
}

/* Badge-ek */
.complete-pc-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #10b981;
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 5px;
}

.complete-calculator-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #3b82f6;
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 5px;
}

.category-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #8b5cf6;
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.subcategory-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #f59e0b;
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Kép konténer */
.image-container {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #f8fafc;
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 15px;
    transition: transform 0.5s ease;
}

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

.product-image-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    background: #f1f5f9;
}

.product-image-fallback i {
    font-size: 3rem;
    margin-bottom: 10px;
    color: #cbd5e1;
}

.corner-price {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.75);
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    z-index: 5;
    backdrop-filter: blur(4px);
}

/* Termék információ */
.product-info {
    padding: 20px;
    border-top: 1px solid #f1f5f9;
}

.product-name {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 15px;
    line-height: 1.4;
    min-height: 3em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.brand-model {
    color: #475569;
    margin-bottom: 15px;
}

.brand,
.model,
.component {
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.brand strong,
.model strong,
.component strong {
    color: #334155;
    margin-right: 5px;
}

.components-info {
    background: #f8fafc;
    padding: 12px;
    border-radius: 8px;
    margin-top: 12px;
    border: 1px solid #e2e8f0;
}

.price-display {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
    border: 2px solid #3b82f6;
    text-align: center;
}

.price-label {
    display: block;
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 5px;
}

.price-value {
    font-size: 1.8rem;
    font-weight: 800;
    color: #1e293b;
    display: block;
}

.no-price-message {
    font-size: 1.2rem;
    font-weight: 600;
    color: #ef4444;
    display: block;
}

/* Üres állapot */
.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 12px;
    border: 2px dashed #cbd5e1;
}

.empty-icon {
    font-size: 4rem;
    color: #cbd5e1;
    margin-bottom: 20px;
}

.empty-state h2 {
    color: #475569;
    margin-bottom: 15px;
}

.empty-state p {
    color: #64748b;
    max-width: 600px;
    margin: 0 auto 25px;
    line-height: 1.6;
}

/* ============================================
   6. LAPOZÁS
   ============================================ */
.pagination {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-top: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    border: 1px solid #e2e8f0;
}

.page-indicator {
    font-size: 1rem;
    color: #475569;
    font-weight: 600;
}

.page-numbers {
    display: flex;
    gap: 8px;
    align-items: center;
}

.page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    height: 45px;
    border-radius: 8px;
    background: #f1f5f9;
    color: #475569;
    font-weight: 600;
    transition: all 0.2s;
    border: 2px solid transparent;
}

.page-link:hover {
    background: #e2e8f0;
    color: #1e293b;
    border-color: #cbd5e1;
}

.page-link.active {
    background: #3b82f6;
    color: white;
    border-color: #2563eb;
}

.page-link.page-nav {
    font-size: 1.2rem;
}

/* ============================================
   7. ÁRTARTOMÁNY STÍLUSOK
   ============================================ */
.price-range-container {
    background: #f8fafc;
    border-radius: 10px;
    padding: 15px;
    margin-top: 10px;
    border: 1px solid #e2e8f0;
}

.price-range-slider {
    position: relative;
    height: 40px;
    margin: 15px 0;
}

.price-range-values {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    font-size: 0.9rem;
    color: #64748b;
}

/* ============================================
   8. RESZPONZÍV TERVEZÉS
   ============================================ */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .header h1 {
        font-size: 2.2rem;
    }
    
    .filter-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .filter-group {
        min-width: 100%;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 15px;
    }
    
    .pagination {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 15px;
    }
    
    .filter-actions {
        flex-direction: column;
    }
    
    .search-btn,
    .reset-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .header {
        padding: 20px 0;
    }
    
    .header h1 {
        font-size: 1.8rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .page-link {
        min-width: 40px;
        height: 40px;
        font-size: 0.9rem;
    }
    
    .complete-pc-badge,
    .complete-calculator-badge,
    .category-badge,
    .subcategory-badge {
        font-size: 11px;
        padding: 4px 8px;
    }
}

/* ============================================
   9. ANIMÁCIÓK
   ============================================ */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-card {
    animation: fadeIn 0.3s ease-out;
}

/* ============================================
   10. SEGÉD OSZTÁLYOK
   ============================================ */
.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.hidden {
    display: none !important;
}

.loading-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3b82f6;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

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