/* ── Reactions toggle button (bottom-left, mirrors chat's bottom-right) ── */
.reactions-toggle-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 70;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: linear-gradient(135deg, var(--surface), #1a0f2e);
    color: var(--text);
    font-size: 1.4rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.reactions-toggle-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
}

/* ── Emoji bar ── */
.reactions-bar {
    position: fixed;
    bottom: 80px;
    left: 20px;
    z-index: 71;
    display: flex;
    gap: 4px;
    padding: 8px;
    background: rgba(42, 26, 74, 0.97);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    animation: reactions-slide-up 0.2s ease-out;
}

@keyframes reactions-slide-up {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .reactions-bar {
        animation: none;
    }
}

.reactions-emoji-btn {
    width: 44px;
    height: 44px;
    border: none;
    background: transparent;
    border-radius: 8px;
    font-size: 1.5rem;
    cursor: pointer;
    transition: transform 0.15s, background 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.reactions-emoji-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.2);
}

.reactions-emoji-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
}

/* ── Floating reactions container ── */
.reactions-float-container {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 75;
    overflow: hidden;
}

.reactions-float-item {
    position: absolute;
    bottom: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: react-float-up 2.5s ease-out forwards;
    opacity: 0;
    animation-fill-mode: forwards;
}

@keyframes react-float-up {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    70% {
        opacity: 0.8;
        transform: translateY(-50vh) scale(1.1);
    }
    100% {
        opacity: 0;
        transform: translateY(-65vh) scale(0.8);
    }
}

@media (prefers-reduced-motion: reduce) {
    .reactions-float-item {
        animation: none;
    }
}

.reactions-float-emoji {
    font-size: 2rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.reactions-float-name {
    font-size: 0.65rem;
    font-family: 'Quicksand', sans-serif;
    color: var(--muted);
    white-space: nowrap;
    margin-top: 2px;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

/* ── Mobile ── */
@media (max-width: 600px) {
    .reactions-toggle-btn {
        bottom: 16px;
        left: 16px;
        width: 46px;
        height: 46px;
        font-size: 1.2rem;
    }

    .reactions-bar {
        bottom: 70px;
        left: 16px;
        gap: 2px;
        padding: 6px;
    }

    .reactions-emoji-btn {
        width: 38px;
        height: 38px;
        font-size: 1.3rem;
    }
}
