/**
 * Like System Styles - Hero Section
 */

/* Like Container in Hero */
.like-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: 30px;
}

/* Like Button - Compact Version */
.like-button {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid #ff1744;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 2px 10px rgba(255, 23, 68, 0.2);
    overflow: visible;
}

.like-button:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(255, 23, 68, 0.3);
    background: rgba(255, 255, 255, 1);
}

.like-button:active {
    transform: scale(0.95);
}

.like-button.liked {
    background: #ff1744;
    border-color: #ff1744;
    box-shadow: 0 4px 20px rgba(255, 23, 68, 0.4);
}

.like-button.liked .heart-icon {
    fill: white;
    stroke: white;
}

.like-button.loading {
    opacity: 0.7;
    cursor: wait;
    pointer-events: none;
}

.like-button.error {
    animation: shake 0.5s;
}

.like-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Heart Icon */
.heart-icon {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: #ff1744;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: all 0.3s ease;
}

.like-button.liked .heart-icon {
    fill: white;
    stroke: white;
}

/* Like Counter - Compact */
.like-counter {
    display: flex;
    align-items: center;
    justify-content: center;
}

.like-count {
    font-size: 28px;
    font-weight: 700;
    color: #ff1744;
    font-family: 'Funnel Display', sans-serif;
    line-height: 1;
    transition: transform 0.3s ease;
    min-width: 30px;
    text-align: center;
}

.like-count.animating {
    animation: scaleUp 0.8s ease-out;
}

/* Animazioni */
@keyframes heartBeat {
    0%, 100% {
        transform: scale(1);
    }
    25% {
        transform: scale(1.3);
    }
    50% {
        transform: scale(1.1);
    }
    75% {
        transform: scale(1.2);
    }
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-5px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(5px);
    }
}

@keyframes countUp {
    0% {
        transform: translateY(10px) scale(0.8);
        opacity: 0;
    }
    50% {
        transform: translateY(-5px) scale(1.2);
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes scaleUp {
    0% {
        transform: scale(1);
    }
    30% {
        transform: scale(1.3);
    }
    50% {
        transform: scale(1.1);
    }
    70% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

/* Animate class per il button */
.like-button.animate {
    animation: heartBeat 0.6s ease;
}

.like-button.animate .heart-icon {
    animation: heartBeat 0.6s ease;
}

/* Like Particles */
.like-particle {
    position: fixed;
    pointer-events: none;
    user-select: none;
    z-index: 10000;
}

/* Pulse effect quando cambia il contatore */
.like-count.update {
    animation: countUp 0.5s ease;
}

/* Responsive */
@media (max-width: 768px) {
    .like-container {
        gap: 12px;
        margin-top: 25px;
    }

    .like-button {
        width: 45px;
        height: 45px;
        padding: 10px;
    }

    .heart-icon {
        width: 20px;
        height: 20px;
    }

    .like-count {
        font-size: 24px;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .like-button,
    .heart-icon,
    .like-count {
        animation: none !important;
        transition: none !important;
    }
}
