/**
 * MAJYA.cz - Heureka Hodnocení Styly
 * Responzivní styly pro widget hodnocení
 */

/* === ZÁKLADNÍ STYLY === */
.heureka-widget {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    font-family: 'Arial', sans-serif;
    transition: all 0.3s ease;
    max-width: 100%;
}

.heureka-widget:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

/* === CERTIFIKÁT === */
.heureka-certificate {
    flex-shrink: 0;
}

.heureka-cert-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 4px;
}

/* === INFORMACE O HODNOCENÍ === */
.heureka-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
}

/* === HVĚZDIČKY === */
.heureka-rating {
    display: flex;
    align-items: center;
    gap: 8px;
}

.heureka-stars {
    display: flex;
    gap: 2px;
}

.heureka-star {
    font-size: 18px;
    line-height: 1;
    transition: all 0.2s ease;
}

.heureka-star-full {
    color: #ff6b35;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.heureka-star-half {
    background: linear-gradient(90deg, #ff6b35 50%, #ddd 50%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: none;
}

.heureka-star-empty {
    color: #ddd;
}

.heureka-rating-number {
    font-weight: bold;
    font-size: 16px;
    color: #333;
}

/* === POČET HODNOCENÍ === */
.heureka-review-count {
    font-size: 14px;
    color: #666;
}

.heureka-review-count span {
    font-weight: 500;
}

/* === ODKAZ === */
.heureka-link {
    color: #ff6b35;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: color 0.2s ease;
}

.heureka-link:hover {
    color: #e55a2b;
    text-decoration: underline;
}

/* === LAYOUT VARIANTY === */

/* Horizontální layout (výchozí) */
.heureka-layout-horizontal {
    flex-direction: row;
}

/* Vertikální layout */
.heureka-layout-vertical {
    flex-direction: column;
    text-align: center;
    max-width: 200px;
}

.heureka-layout-vertical .heureka-info {
    align-items: center;
}

/* Kompaktní layout */
.heureka-layout-compact {
    padding: 10px;
    gap: 10px;
}

.heureka-layout-compact .heureka-cert-icon {
    width: 40px;
    height: 40px;
}

.heureka-layout-compact .heureka-star {
    font-size: 14px;
}

.heureka-layout-compact .heureka-rating-number {
    font-size: 14px;
}

/* === RESPONZIVNÍ DESIGN === */

/* Tablet */
@media (max-width: 768px) {
    .heureka-widget {
        padding: 12px;
        gap: 12px;
    }
    
    .heureka-cert-icon {
        width: 50px;
        height: 50px;
    }
    
    .heureka-star {
        font-size: 16px;
    }
}

/* Mobil */
@media (max-width: 480px) {
    .heureka-widget {
        flex-direction: column;
        text-align: center;
        padding: 15px 10px;
    }
    
    .heureka-layout-horizontal {
        flex-direction: column;
    }
    
    .heureka-cert-icon {
        width: 45px;
        height: 45px;
    }
    
    .heureka-info {
        align-items: center;
    }
    
    .heureka-rating {
        justify-content: center;
    }
}

/* === STAVY NAČÍTÁNÍ === */
.heureka-widget:not(.heureka-widget-loaded) {
    opacity: 0.7;
    pointer-events: none;
}

.heureka-widget.heureka-widget-loaded {
    opacity: 1;
}

.heureka-widget.heureka-widget-fallback {
    border-color: #ffa500;
    background: #fff9e6;
}

.heureka-widget.heureka-widget-fallback::after {
    content: "Záložní data";
    position: absolute;
    top: 5px;
    right: 5px;
    font-size: 10px;
    color: #ffa500;
    background: #fff;
    padding: 2px 4px;
    border-radius: 2px;
}

/* === ANIMACE === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.heureka-widget-loaded {
    animation: fadeInUp 0.5s ease-out;
}

/* === TMAVÝ REŽIM === */
@media (prefers-color-scheme: dark) {
    .heureka-widget {
        background: #2a2a2a;
        border-color: #444;
        color: #fff;
    }
    
    .heureka-rating-number {
        color: #fff;
    }
    
    .heureka-review-count {
        color: #ccc;
    }
    
    .heureka-star-empty {
        color: #555;
    }
}

/* === PRINT STYLY === */
@media print {
    .heureka-widget {
        box-shadow: none;
        border: 1px solid #000;
        background: #fff;
        color: #000;
    }
    
    .heureka-link {
        color: #000;
        text-decoration: underline;
    }
    
    .heureka-link::after {
        content: " (" attr(href) ")";
        font-size: 10px;
    }
}
