/* Giveaway like (heart) button - list cards and detail hero */

.gw-like-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    border: 1px solid rgba(22, 26, 39, 0.16);
    background: rgba(255, 255, 255, 0.94);
    color: #1f2937;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.15s ease, background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.gw-like-btn:hover,
.gw-like-btn:focus-visible {
    color: #b91c1c;
    border-color: rgba(var(--cc-danger-rgb), 0.44);
    text-decoration: none;
}

.gw-like-btn:focus-visible {
    outline: 2px solid #b91c1c;
    outline-offset: 2px;
}

/* Solid backing keeps the liked heart legible on photos and the dark hero. */
.gw-like-btn.is-liked {
    border-color: rgba(var(--cc-danger-rgb), 0.44);
    color: #b91c1c;
    background: #fdecee;
}

.gw-like-btn[aria-busy="true"] {
    opacity: 0.65;
    pointer-events: none;
}

.gw-like-btn.is-error {
    border-color: var(--cc-danger);
    animation: gw-like-error-pulse 0.3s ease 2;
}

@keyframes gw-like-error-pulse {
    50% { transform: translateX(2px); }
}

.gw-like-btn .bi {
    font-size: 1.05rem;
    line-height: 1;
}

.gw-like-count {
    font-size: 0.82rem;
    font-weight: 600;
    line-height: 1;
}

.gw-like-count:empty {
    display: none;
}

.gw-like-sr-count {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Overlay variant: floats on the giveaway card image (eBay-style) */
.gw-like-btn--media {
    position: absolute;
    top: 0.6rem;
    right: 0.6rem;
    z-index: 2;
    min-width: 44px;
    min-height: 44px;
    padding: 0 0.55rem;
    border-radius: 999px;
    box-shadow: 0 4px 12px rgba(22, 26, 39, 0.18);
}

.gw-like-btn--media:hover {
    transform: scale(1.06);
}

/* Pill variant: sits inline with other chips (card heading, hero pills) */
.gw-like-btn--pill {
    min-height: 44px;
    padding: 0.35rem 0.8rem;
    border-radius: 999px;
    font-size: 0.86rem;
}

/* Keep the small decorative hero chips vertically centered instead of
   stretching to the 44px tap height of the like pill. */
.gw-hero-pills {
    align-items: center;
}

@media (prefers-reduced-motion: reduce) {
    .gw-like-btn,
    .gw-like-btn--media:hover {
        transition: none;
        transform: none;
    }

    .gw-like-btn.is-error {
        animation: none;
    }
}
