.jt-reaction {
    --jt-reaction-bg: #ffffff;
    --jt-reaction-border: #d9dee8;
    --jt-reaction-text: #18243a;
    --jt-reaction-muted: #697386;
    --jt-reaction-accent: #2563eb;
    --jt-reaction-accent-strong: #163fae;
    --jt-reaction-glow: rgba(37, 99, 235, 0.24);

    position: relative;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    min-width: 132px;
    padding: 0 18px !important;
    border: 1px solid var(--jt-reaction-border) !important;
    border-radius: 999px !important;
    background:
        radial-gradient(circle at 30% 15%, rgba(255, 255, 255, 0.92), transparent 34%),
        linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    color: var(--jt-reaction-text) !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    letter-spacing: 0 !important;
    text-decoration: none !important;
    cursor: pointer;
    overflow: visible;
    transform: translateZ(0);
    transition:
        transform 160ms ease,
        border-color 160ms ease,
        box-shadow 160ms ease,
        background 160ms ease,
        color 160ms ease;
    -webkit-tap-highlight-color: transparent;
}

.jt-reaction:hover,
.jt-reaction:focus-visible {
    border-color: rgba(37, 99, 235, 0.45) !important;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.11), 0 0 0 4px var(--jt-reaction-glow);
    transform: translateY(-1px);
    outline: none;
}

.jt-reaction:active {
    transform: translateY(0) scale(0.98);
}

.jt-reaction.is-active,
.jt-reaction.active,
.jt-reaction.favorited,
.jt-reaction.simplefavorite-button.active {
    border-color: rgba(37, 99, 235, 0.5) !important;
    background:
        radial-gradient(circle at 28% 18%, rgba(255, 255, 255, 0.24), transparent 34%),
        linear-gradient(135deg, var(--jt-reaction-accent) 0%, var(--jt-reaction-accent-strong) 100%) !important;
    box-shadow: 0 14px 34px rgba(37, 99, 235, 0.22);
    color: #ffffff !important;
}

.jt-reaction__icon {
    display: inline-grid;
    place-items: center;
    width: 19px;
    height: 19px;
    flex: 0 0 auto;
}

.jt-reaction__icon svg {
    display: block;
    width: 19px;
    height: 19px;
    stroke-width: 2.25;
}

.jt-reaction__label,
.jt-reaction__count {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
}

.jt-reaction__count {
    color: var(--jt-reaction-muted);
    font-size: 13px;
    font-weight: 750;
}

.jt-reaction.is-active .jt-reaction__count,
.jt-reaction.active .jt-reaction__count,
.jt-reaction.favorited .jt-reaction__count {
    color: rgba(255, 255, 255, 0.82);
}

.jt-reaction__count:empty,
.jt-reaction[data-jt-count="0"] .jt-reaction__count {
    display: none;
}

.jt-reaction__burst {
    position: absolute;
    inset: -12px;
    pointer-events: none;
    opacity: 0;
}

.jt-reaction.is-popping .jt-reaction__burst {
    animation: jt-reaction-burst 620ms ease-out;
}

.jt-reaction__spark {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 5px;
    height: 5px;
    border-radius: 999px;
    background: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
    transform: translate(-50%, -50%) rotate(var(--angle)) translateY(-27px) scale(0);
}

.jt-reaction.is-popping .jt-reaction__spark {
    animation: jt-reaction-spark 620ms ease-out forwards;
}

.jt-reaction__toast {
    position: absolute;
    left: 50%;
    top: -34px;
    padding: 7px 11px;
    border-radius: 999px;
    background: #111827;
    box-shadow: 0 12px 22px rgba(15, 23, 42, 0.18);
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    opacity: 0;
    transform: translate(-50%, 8px) scale(0.94);
    pointer-events: none;
    white-space: nowrap;
}

.jt-reaction.is-popping .jt-reaction__toast {
    animation: jt-reaction-toast 900ms ease-out;
}

@keyframes jt-reaction-burst {
    0% {
        opacity: 0;
        transform: scale(0.72);
    }
    35% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: scale(1.12);
    }
}

@keyframes jt-reaction-spark {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) rotate(var(--angle)) translateY(-10px) scale(0);
    }
    32% {
        opacity: 1;
        transform: translate(-50%, -50%) rotate(var(--angle)) translateY(-31px) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) rotate(var(--angle)) translateY(-42px) scale(0.25);
    }
}

@keyframes jt-reaction-toast {
    0% {
        opacity: 0;
        transform: translate(-50%, 8px) scale(0.94);
    }
    18%,
    72% {
        opacity: 1;
        transform: translate(-50%, 0) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -6px) scale(0.98);
    }
}

@media (max-width: 520px) {
    .jt-reaction {
        min-width: 124px;
        min-height: 42px;
        padding-inline: 15px !important;
        font-size: 14px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .jt-reaction,
    .jt-reaction__burst,
    .jt-reaction__spark,
    .jt-reaction__toast {
        animation: none !important;
        transition: none !important;
    }
}
