/* ===================================
   Improved Reactions UI
   =================================== */

.post-reactions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.reaction-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    border-radius: 24px;
    background: var(--color-surface);
    color: var(--color-dark);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.reaction-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.reaction-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.reaction-btn i {
    font-size: 16px;
    transition: all 0.3s ease;
}

.reaction-btn span {
    min-width: 24px;
    text-align: center;
    font-weight: 700;
}

/* Positive Reaction (Like) */
.reaction-btn[data-type="positive"]:hover {
    border-color: var(--color-success);
    background: rgba(76, 175, 80, 0.1);
}

.reaction-btn[data-type="positive"]:hover i {
    color: var(--color-success);
    transform: scale(1.1);
}

.reaction-btn[data-type="positive"]:active i {
    transform: scale(1);
}

.reaction-btn.active-positive {
    border-color: var(--color-success);
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.2), rgba(76, 175, 80, 0.3));
    color: var(--color-success);
    box-shadow: 0 4px 16px rgba(76, 175, 80, 0.3);
}

.reaction-btn.active-positive i {
    color: var(--color-success);
    animation: likeAnimation 0.5s ease;
}

/* Negative Reaction (Dislike) */
.reaction-btn[data-type="negative"]:hover {
    border-color: #ff4444;
    background: rgba(255, 68, 68, 0.1);
}

.reaction-btn[data-type="negative"]:hover i {
    color: #ff4444;
    transform: scale(1.1);
}

.reaction-btn[data-type="negative"]:active i {
    transform: scale(1);
}

.reaction-btn.active-negative {
    border-color: #ff4444;
    background: linear-gradient(135deg, rgba(255, 68, 68, 0.2), rgba(255, 68, 68, 0.3));
    color: #ff4444;
    box-shadow: 0 4px 16px rgba(255, 68, 68, 0.3);
}

.reaction-btn.active-negative i {
    color: #ff4444;
    animation: dislikeAnimation 0.5s ease;
}

/* Score Display */
.post-score-display {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    border-radius: 24px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), rgba(255, 107, 53, 0.1));
    border: 2px solid rgba(255, 215, 0, 0.3);
    font-weight: 700;
    font-size: 16px;
    color: var(--color-primary);
}

.post-score-display i {
    font-size: 18px;
}

.post-score-display.positive {
    color: var(--color-success);
    border-color: rgba(76, 175, 80, 0.3);
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.1), rgba(76, 175, 80, 0.2));
}

.post-score-display.negative {
    color: #ff4444;
    border-color: rgba(255, 68, 68, 0.3);
    background: linear-gradient(135deg, rgba(255, 68, 68, 0.1), rgba(255, 68, 68, 0.2));
}

/* Animations */
@keyframes likeAnimation {
    0% { transform: scale(1); }
    50% { transform: scale(1.15) rotate(10deg); }
    100% { transform: scale(1) rotate(0deg); }
}

@keyframes dislikeAnimation {
    0% { transform: scale(1); }
    50% { transform: scale(1.15) rotate(-10deg); }
    100% { transform: scale(1) rotate(0deg); }
}

/* Ripple Effect */
.reaction-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.4s, height 0.4s;
    pointer-events: none;
}

.reaction-btn:active::before {
    width: 100%;
    height: 100%;
}

/* Disabled State */
.reaction-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Loading State */
.reaction-btn.loading {
    pointer-events: none;
    opacity: 0.7;
}

.reaction-btn.loading i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    .reaction-btn {
        padding: 8px 14px;
        font-size: 13px;
    }
    
    .reaction-btn i {
        font-size: 14px;
    }
    
    .post-score-display {
        padding: 8px 14px;
        font-size: 14px;
    }
}

/* Tooltip */
.reaction-btn[data-tooltip] {
    position: relative;
}

.reaction-btn[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 12px;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    font-size: 12px;
    white-space: nowrap;
    border-radius: 6px;
    margin-bottom: 8px;
    z-index: 1000;
}

.reaction-btn[data-tooltip]:hover::after {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: rgba(0, 0, 0, 0.9);
    margin-bottom: 2px;
    z-index: 1001;
}
