/* Modern Category Display - Frissített Verzió CSS */

/* Alapértelmezett betűtípus */
* {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Fő konténer */
.category-display-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 50px 0;
    padding: 0;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 16px;
    padding: 25px;
}

/* Kategória elem - modern címke stílus */
.category-item {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border: 2px solid transparent;
    border-radius: 16px;
    padding: 8px;
    overflow: hidden;
    box-shadow: 
        0 12px 24px rgba(15, 23, 42, 0.06),
        0 6px 12px rgba(15, 23, 42, 0.04);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    height: 80px;
    position: relative;
}

.category-item::before {
    content: '';
    position: absolute;
    inset: 0;
    padding: 2px;
    background: linear-gradient(135deg, #06b6d4, #3b82f6, #8b5cf6, #ec4899);
    border-radius: inherit;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.category-item:hover::before {
    opacity: 1;
}

.category-item:hover {
    transform: translateY(-6px) scale(1.03);
    box-shadow: 
        0 20px 40px rgba(15, 23, 42, 0.12),
        0 10px 20px rgba(15, 23, 42, 0.08);
}

/* Kategória link */
.category-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    width: 100%;
    height: 100%;
    border-radius: 14px;
}

/* Kép wrapper - bal oldali kör */
.category-image-wrapper {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    overflow: hidden;
    background: linear-gradient(135deg, #e0f2fe, #cffafe);
    flex-shrink: 0;
    margin: 0 4px 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #f0f9ff;
    position: relative;
}

.category-image-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.5) 50%, transparent 70%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.category-item:hover .category-image-wrapper::before {
    transform: translateX(100%);
}

/* Kategória kép */
.category-image {
    width: 100%;
    height: 100% !important;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    filter: brightness(1.1) contrast(1.05);
}

.category-item:hover .category-image {
    transform: scale(1.15) rotate(2deg);
}

/* Kategória információk - jobb oldali szöveg */
.category-info {
    padding: 0 20px 0 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    flex-grow: 1;
    min-width: 0;
}

/* Kategória név */
.category-name {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.2;
    transition: all 0.3s ease;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -0.3px;
    background: linear-gradient(135deg, #06b6d4, #3b82f6);
    background-size: 0% 3px;
    background-repeat: no-repeat;
    background-position: left bottom;
}

.category-link:hover .category-name {
    color: #0891b2;
    background-size: 100% 3px;
}

/* Bejegyzések száma */
.category-count {
    font-size: 12px;
    color: #64748b;
    font-weight: 600;
    opacity: 0.8;
    white-space: nowrap;
    flex-shrink: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
    padding: 2px 8px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.category-item:hover .category-count {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    color: white;
    transform: scale(1.05);
}

/* ===== ALTERNATÍV MÉRETEK ===== */

/* Nagy címke */
.category-display-container.large .category-item {
    height: 90px;
    border-radius: 20px;
    padding: 10px;
}

.category-display-container.large .category-image-wrapper {
    width: 70px;
    height: 70px;
    border-radius: 18px;
}

.category-display-container.large .category-info {
    padding: 0 24px 0 18px;
    gap: 6px;
}

.category-display-container.large .category-name {
    font-size: 18px;
}

.category-display-container.large .category-count {
    font-size: 13px;
    padding: 3px 10px;
}

/* Kis címke */
.category-display-container.small .category-item {
    height: 60px;
    border-radius: 12px;
    padding: 6px;
}

.category-display-container.small .category-image-wrapper {
    width: 48px;
    height: 48px;
    border-radius: 12px;
}

.category-display-container.small .category-info {
    padding: 0 16px 0 12px;
    gap: 2px;
}

.category-display-container.small .category-name {
    font-size: 14px;
}

.category-display-container.small .category-count {
    font-size: 11px;
    padding: 2px 6px;
}

/* ===== SZÍNES VÁLTOZATOK ===== */

/* Színes címkék - Vibráns gradiens */
.category-item.colored {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: transparent;
    color: white;
}

.category-item.colored::before {
    background: linear-gradient(135deg, #f093fb, #f5576c, #4facfe, #00f2fe);
}

.category-item.colored .category-image-wrapper {
    background: linear-gradient(135deg, rgba(255,255,255,0.2), rgba(255,255,255,0.1));
    border-color: rgba(255,255,255,0.3);
}

.category-item.colored .category-name {
    color: white;
    background: linear-gradient(135deg, #f093fb, #f5576c);
    background-size: 0% 3px;
}

.category-item.colored .category-count {
    background: rgba(255,255,255,0.2);
    color: rgba(255,255,255,0.9);
    border-color: rgba(255,255,255,0.3);
}

.category-item.colored:hover .category-name {
    color: #f1c40f;
    background-size: 100% 3px;
}

.category-item.colored:hover .category-count {
    background: rgba(241,196,15,0.3);
    color: #f1c40f;
}

/* Outline stílus - Modern keretezés */
.category-item.outline {
    background: transparent;
    border: 2px solid #06b6d4;
}

.category-item.outline::before {
    background: linear-gradient(135deg, #06b6d4, #0891b2, #0e7490);
}

.category-item.outline .category-image-wrapper {
    background: linear-gradient(135deg, #e0f7fa, #b2ebf2);
    border-color: #06b6d4;
}

.category-item.outline .category-name {
    color: #06b6d4;
}

.category-item.outline .category-count {
    background: linear-gradient(135deg, #e0f7fa, #b2ebf2);
    color: #0891b2;
    border-color: #06b6d4;
}

.category-item.outline:hover {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
}

.category-item.outline:hover .category-name,
.category-item.outline:hover .category-count {
    color: white;
}

.category-item.outline:hover .category-count {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.3);
}

/* ===== SPECIÁLIS KATEGÓRIA SZÍNEK ===== */

/* Tech kategória - Kék */
.category-item.tech {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
}

.category-item.tech .category-image-wrapper {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
}

/* Sport kategória - Zöld */
.category-item.sport {
    background: linear-gradient(135deg, #10b981 0%, #047857 100%);
}

.category-item.sport .category-image-wrapper {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
}

/* Divat kategória - Pink */
.category-item.fashion {
    background: linear-gradient(135deg, #ec4899 0%, #be185d 100%);
}

.category-item.fashion .category-image-wrapper {
    background: linear-gradient(135deg, #fce7f3, #fbcfe8);
}

/* Étel kategória - Narancs */
.category-item.food {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.category-item.food .category-image-wrapper {
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
}

/* Utazás kategória - Lila */
.category-item.travel {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
}

.category-item.travel .category-image-wrapper {
    background: linear-gradient(135deg, #f3e8ff, #e9d5ff);
}

/* ===== RESZPONZÍV DESIGN ===== */

/* Desktop */
@media (max-width: 1200px) {
    .category-display-container {
        gap: 18px;
        padding: 20px;
    }
}

/* Tablet */
@media (max-width: 1024px) {
    .category-display-container {
        gap: 16px;
        margin: 40px 0;
        padding: 18px;
    }
    
    .category-item {
        height: 70px;
        border-radius: 14px;
    }
    
    .category-image-wrapper {
        width: 54px;
        height: 54px;
        border-radius: 14px;
    }
    
    .category-info {
        padding: 0 18px 0 14px;
    }
    
    .category-name {
        font-size: 15px;
    }
    
    .category-count {
        font-size: 11px;
    }
}

/* Mobil nagy */
@media (max-width: 768px) {
    .category-display-container {
        gap: 14px;
        margin: 30px 0;
        padding: 15px;
        border-radius: 12px;
    }
    
    .category-item {
        height: 65px;
        border-radius: 12px;
    }
    
    .category-image-wrapper {
        width: 49px;
        height: 49px;
        border-radius: 12px;
    }
    
    .category-info {
        padding: 0 16px 0 12px;
    }
    
    .category-name {
        font-size: 14px;
    }
    
    .category-count {
        font-size: 10px;
        padding: 2px 6px;
    }
}

/* Mobil */
@media (max-width: 480px) {
    .category-display-container {
        gap: 12px;
        margin: 25px 0;
        padding: 12px;
    }
    
    .category-item {
        height: 60px;
        border-radius: 10px;
    }
    
    .category-image-wrapper {
        width: 44px;
        height: 44px;
        border-radius: 10px;
    }
    
    .category-info {
        padding: 0 14px 0 10px;
        gap: 2px;
    }
    
    .category-name {
        font-size: 13px;
    }
    
    .category-count {
        font-size: 9px;
        padding: 1px 5px;
    }
}

/* Extra kis mobil */
@media (max-width: 360px) {
    .category-display-container {
        gap: 10px;
        padding: 10px;
    }
    
    .category-item {
        height: 55px;
        border-radius: 8px;
    }
    
    .category-image-wrapper {
        width: 39px;
        height: 39px;
        border-radius: 8px;
    }
    
    .category-info {
        padding: 0 12px 0 8px;
    }
    
    .category-name {
        font-size: 12px;
    }
    
    /* Bejegyzésszám elrejtése nagyon kis képernyőn */
    .category-count {
        display: none;
    }
}

/* ===== SPECIÁLIS STÍLUSOK ===== */

/* Hover effektusok kikapcsolása érintős eszközökön */
@media (hover: none) {
    .category-item:hover {
        transform: none;
        box-shadow: 
            0 12px 24px rgba(15, 23, 42, 0.06),
            0 6px 12px rgba(15, 23, 42, 0.04);
    }
    
    .category-item:hover .category-image {
        transform: none;
    }
    
    .category-item:hover::before {
        opacity: 0;
    }
}

/* Sötét mód támogatás */
@media (prefers-color-scheme: dark) {
    .category-display-container {
        background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    }
    
    .category-item {
        background: linear-gradient(145deg, #1e293b 0%, #334155 100%);
        border-color: #475569;
    }
    
    .category-item:hover {
        border-color: #22d3ee;
    }
    
    .category-name {
        color: #f8fafc;
        background: linear-gradient(135deg, #22d3ee, #06b6d4);
    }
    
    .category-link:hover .category-name {
        color: #22d3ee;
    }
    
    .category-count {
        color: #cbd5e1;
        background: linear-gradient(135deg, #334155, #475569);
        border-color: #64748b;
    }
    
    .category-image-wrapper {
        background: linear-gradient(135deg, #334155, #475569);
        border-color: #64748b;
    }
}

/* Mozgás csökkentése preferencia */
@media (prefers-reduced-motion: reduce) {
    .category-item,
    .category-image,
    .category-name,
    .category-count,
    .category-image-wrapper::before {
        transition: none;
    }
    
    .category-item:hover {
        transform: none;
    }
    
    .category-item:hover .category-image {
        transform: none;
    }
    
    .category-item:hover .category-image-wrapper::before {
        transform: translateX(-100%);
    }
}

/* Magas kontraszt mód */
@media (prefers-contrast: high) {
    .category-item {
        border: 3px solid #000;
        background: #fff;
    }
    
    .category-name {
        color: #000;
        font-weight: 800;
    }
    
    .category-link:hover .category-name {
        color: #0066cc;
    }
    
    .category-count {
        color: #333;
        background: #f0f0f0;
        border-color: #000;
    }
    
    .category-image-wrapper {
        border: 2px solid #000;
        background: #f8f8f8;
    }
}

/* Printelhető nézet */
@media print {
    .category-display-container {
        display: block;
        margin: 0;
        background: white;
        padding: 0;
    }
    
    .category-item {
        display: inline-flex;
        margin: 8px;
        box-shadow: none;
        border: 2px solid #ddd;
        break-inside: avoid;
        background: white;
        height: 50px;
    }
    
    .category-image-wrapper {
        width: 35px;
        height: 35px;
        background: #f5f5f5;
        border-color: #ddd;
    }
    
    .category-info {
        padding: 0 10px 0 8px;
    }
    
    .category-name {
        color: #000 !important;
        font-size: 12px;
        background: none;
    }
    
    .category-count {
        color: #666 !important;
        font-size: 10px;
        background: #f0f0f0;
        border-color: #ccc;
    }
}

/* Focus állapot akadálymentességhez */
.category-link:focus {
    outline: 3px solid #06b6d4;
    outline-offset: 3px;
    border-radius: 20px;
}

.category-link:focus .category-item {
    border-color: #06b6d4;
    box-shadow: 
        0 0 0 3px rgba(6, 182, 212, 0.2),
        0 12px 24px rgba(15, 23, 42, 0.06);
}

/* ===== ALTERNATÍV LAYOUTOK ===== */

/* Kompakt layout */
.category-display-container.compact {
    gap: 12px;
    padding: 15px;
}

.category-display-container.compact .category-item {
    height: 50px;
    padding: 4px;
}

.category-display-container.compact .category-image-wrapper {
    width: 42px;
    height: 42px;
}

.category-display-container.compact .category-name {
    font-size: 13px;
}

.category-display-container.compact .category-count {
    font-size: 10px;
}

/* Vertical layout */
.category-display-container.vertical {
    flex-direction: column;
    align-items: stretch;
    gap: 15px;
}

.category-display-container.vertical .category-item {
    height: 70px;
    width: 100%;
}

/* Grid layout */
.category-display-container.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

/* Masonry layout effect */
.category-display-container.masonry {
    column-count: auto;
    column-width: 280px;
    column-gap: 20px;
}

.category-display-container.masonry .category-item {
    break-inside: avoid;
    margin-bottom: 20px;
    width: 100%;
}