/* Category Showcase Container */
.category-showcase-container {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 40px;
    width: 100%;
}

/* ========================================
   LEFT COLUMN - CATEGORIES
======================================== */

.category-left-column {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background-color: #ffffff;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.category-card:hover {
    border-color: #5E35B1;
    box-shadow: 0 4px 12px rgba(94, 53, 177, 0.15);
    transform: translateY(-2px);
}

.category-card.active {
    background-color: #f5f5f5;
    border-color: #5E35B1;
    box-shadow: 0 2px 8px rgba(94, 53, 177, 0.2);
}

/* Category Icon */
.category-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    position: relative;
    overflow: visible;
    transition: all 0.3s ease;
}

.category-icon i,
.category-icon svg,
.category-icon img {
    transition: all 0.3s ease;
}

/* Hover Circle - Yellow */
.category-icon::after {
    content: '';
    position: absolute;
    bottom: -10px;
    right: -10px;
    width: 20px;
    height: 20px;
    background-color: #ffd500;
    border-radius: 50%;
    transform: scale(0);
    transform-origin: center center;
    transition: transform 0.35s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 10;
    will-change: transform;
}

.category-card:hover .category-icon::after {
    transform: scale(1);
}

/* Category Title */
.category-card-title {
    font-size: 16px;
    font-weight: 500;
    color: #333333;
    text-align: center;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.category-card:hover .category-card-title {
    color: #5E35B1;
}

/* ========================================
   RIGHT COLUMN - SLIDESHOW & SUBCATEGORIES
======================================== */

.category-right-column {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Slideshow Wrapper */
.category-slideshow-wrapper {
    position: relative;
    width: 100%;
}

.category-slideshow {
    display: none;
}

.category-slideshow.active {
    display: block;
}

.slideshow-container {
    position: relative;
    width: 100%;
    height: clamp(350px, 35vh, 480px);
    background-color: #f0f0f0;
    border-radius: 8px;
    overflow: hidden;
}

.slideshow-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

.slideshow-image.active {
    opacity: 1;
    z-index: 1;
}

/* Slideshow Navigation */
.slideshow-prev,
.slideshow-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 12px 16px;
    font-size: 20px;
    cursor: pointer;
    border-radius: 4px;
    z-index: 10;
    transition: background-color 0.3s ease;
}

.slideshow-prev:hover,
.slideshow-next:hover {
    background-color: rgba(0, 0, 0, 0.7);
}

.slideshow-prev {
    left: 15px;
}

.slideshow-next {
    right: 15px;
}

/* Slideshow Dots */
.slideshow-dots {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.slideshow-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.slideshow-dot:hover {
    background-color: rgba(255, 255, 255, 0.8);
}

.slideshow-dot.active {
    background-color: #ffffff;
    transform: scale(1.2);
}

/* Subcategories Wrapper */
.category-subcategories-wrapper {
    position: relative;
}

.category-subcategories {
    display: none;
}

.category-subcategories.active {
    display: block;
}

.category-subcategories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

/* Subcategory Item */
.subcategory-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 15px;
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.subcategory-item:hover {
    background-color: #f5f5f5;
    border-color: #5E35B1;
    transform: translateX(3px);
}

.subcategory-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.subcategory-icon i,
.subcategory-icon svg,
.subcategory-icon img {
    transition: all 0.3s ease;
}

.subcategory-title {
    font-size: 14px;
    color: #333333;
    line-height: 1.4;
}

/* ========================================
   MOBILE MODAL
======================================== */

.category-mobile-modal {
    display: none;
}

/* ========================================
   RESPONSIVE - TABLET
======================================== */

@media (max-width: 1024px) {
    .category-showcase-container {
        grid-template-columns: 350px 1fr;
        gap: 30px;
    }
    
    .category-subcategories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========================================
   RESPONSIVE - MOBILE
======================================== */

@media (max-width: 768px) {
    .category-showcase-container {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    /* Hide right column on mobile */
    .category-right-column {
        display: none;
    }
    
    /* Left column - 1 column */
    .category-left-column {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    /* Mobile Modal */
    .category-mobile-modal {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 9999;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
    }
    
    .category-mobile-modal.active {
        opacity: 1;
        visibility: visible;
    }
    
    .category-modal-overlay {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(0, 0, 0, 0.8);
    }
    
    .category-modal-content {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%) scale(0.9);
        width: 90%;
        max-width: 500px;
        max-height: 80vh;
        background-color: #ffffff;
        border-radius: 12px;
        overflow-y: auto;
        padding: 20px;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    .category-mobile-modal.active .category-modal-content {
        transform: translate(-50%, -50%) scale(1);
    }
    
    .category-modal-close {
        position: absolute;
        top: 10px;
        right: 10px;
        background: none;
        border: none;
        font-size: 32px;
        color: #333333;
        cursor: pointer;
        z-index: 10;
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        transition: background-color 0.3s ease;
    }
    
    .category-modal-close:hover {
        background-color: #f0f0f0;
    }
    
    .category-modal-slideshow {
        margin-bottom: 20px;
    }
    
    .category-modal-slideshow .slideshow-container {
        height: clamp(250px, 40vh, 350px);
    }
    
    .category-modal-subcategories .category-subcategories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .category-card {
        padding: 15px;
    }
    
    .category-card-title {
        font-size: 14px;
    }
    
    .slideshow-prev,
    .slideshow-next {
        padding: 8px 12px;
        font-size: 16px;
    }
    
    .slideshow-prev {
        left: 10px;
    }
    
    .slideshow-next {
        right: 10px;
    }
    
    .subcategory-item {
        padding: 8px 12px;
        gap: 8px;
    }
    
    .subcategory-title {
        font-size: 13px;
    }
    
    .category-modal-content {
        width: 95%;
        padding: 15px;
    }
}

/* ========================================
   ACCESSIBILITY
======================================== */

@media (prefers-reduced-motion: reduce) {
    .category-card,
    .category-icon,
    .category-icon::after,
    .slideshow-image,
    .subcategory-item {
        transition: none;
    }
}
