/* KKTC Smart Recommendations - Frontend Styles */

/* İlgili Ürünler Shortcode Styles */
.kktc-related-products {
    margin: 20px 0;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
    clear: both;
}

.kktc-related-products h3 {
    margin: 0 0 20px 0;
    color: #333;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
}

/* Product Grid Styles */
.kktc-products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.kktc-product-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 15px;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.kktc-product-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.kktc-product-image {
    margin-bottom: 10px;
}

.kktc-product-image img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

.kktc-product-title {
    font-size: 14px;
    font-weight: 600;
    margin: 10px 0 5px 0;
    color: #333;
}

.kktc-product-title a {
    color: #333;
    text-decoration: none;
}

.kktc-product-title a:hover {
    color: #0073aa;
}

.kktc-product-price {
    font-size: 16px;
    font-weight: bold;
    color: #27ae60;
    margin: 5px 0;
}

.kktc-product-rating {
    margin: 5px 0;
    font-size: 12px;
    color: #666;
}

/* Carousel Styles */
.kktc-products-carousel {
    position: relative;
    overflow: hidden;
    margin: 20px 0;
}

.kktc-carousel-container {
    position: relative;
}

.kktc-carousel-wrapper {
    overflow: hidden;
}

.kktc-carousel-track {
    display: flex;
    transition: transform 0.3s ease;
}

.kktc-carousel-slide {
    flex: 0 0 auto;
    padding: 0 10px;
}

.kktc-carousel-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.7);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    z-index: 10;
    transition: background-color 0.2s ease;
}

.kktc-carousel-nav:hover {
    background: rgba(0,0,0,0.9);
}

.kktc-carousel-nav.prev {
    left: 10px;
}

.kktc-carousel-nav.next {
    right: 10px;
}

.kktc-carousel-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* Pagination */
.kktc-carousel-pagination {
    text-align: center;
    margin-top: 15px;
}

.kktc-pagination-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ccc;
    margin: 0 5px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.kktc-pagination-dot.active {
    background: #0073aa;
}

/* No Results Message */
.kktc-no-products {
    text-align: center;
    padding: 40px 20px;
    color: #666;
    font-style: italic;
}

/* Loading State */
.kktc-loading {
    text-align: center;
    padding: 20px;
    color: #666;
}

.kktc-loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #ddd;
    border-top: 2px solid #0073aa;
    border-radius: 50%;
    animation: kktc-spin 1s linear infinite;
    margin-left: 10px;
}

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

/* Error State */
.kktc-error {
    background: #f8d7da;
    color: #721c24;
    padding: 15px;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    margin: 20px 0;
    text-align: center;
}

/* Brand Page Styles */
.kktc-brand-products {
    margin: 20px 0;
}

.kktc-brand-header {
    text-align: center;
    margin-bottom: 30px;
}

.kktc-brand-logo {
    max-width: 200px;
    height: auto;
    margin-bottom: 15px;
}

.kktc-brand-description {
    color: #666;
    font-size: 16px;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

/* Filter Styles */
.kktc-filters {
    background: #fff;
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 6px;
    margin-bottom: 20px;
}

.kktc-filter-group {
    display: inline-block;
    margin-right: 20px;
    margin-bottom: 10px;
}

.kktc-filter-label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    color: #333;
}

.kktc-filter-select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

/* Load More Button */
.kktc-load-more {
    text-align: center;
    margin: 30px 0;
}

.kktc-load-more-btn {
    background: #0073aa;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.kktc-load-more-btn:hover {
    background: #005177;
}

.kktc-load-more-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Responsive Design */
@media (max-width: 768px) {
    .kktc-products-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 15px;
    }
    
    .kktc-related-products {
        padding: 15px;
        margin: 15px 0;
    }
    
    .kktc-carousel-nav {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
    
    .kktc-filters {
        padding: 15px;
    }
    
    .kktc-filter-group {
        display: block;
        margin-right: 0;
        margin-bottom: 15px;
    }
}

@media (max-width: 480px) {
    .kktc-products-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 10px;
    }
    
    .kktc-product-item {
        padding: 10px;
    }
    
    .kktc-product-title {
        font-size: 12px;
    }
    
    .kktc-product-price {
        font-size: 14px;
    }
    
    .kktc-carousel-nav {
        width: 30px;
        height: 30px;
        font-size: 14px;
    }
    
    .kktc-carousel-nav.prev {
        left: 5px;
    }
    
    .kktc-carousel-nav.next {
        right: 5px;
    }
}

/* Accessibility */
.kktc-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

/* Focus Styles */
.kktc-product-item:focus,
.kktc-carousel-nav:focus,
.kktc-pagination-dot:focus,
.kktc-load-more-btn:focus {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .kktc-carousel-nav,
    .kktc-pagination-dot,
    .kktc-load-more-btn {
        display: none;
    }
    
    .kktc-products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}