.back-to-top {
    position: fixed;
    right: 24px;
    bottom: calc(88px + env(safe-area-inset-bottom, 0px));
    z-index: 900;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(96, 165, 250, 0.38);
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.92);
    color: #e2e8f0;
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.32), 0 0 24px rgba(37, 99, 235, 0.12);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    cursor: pointer;
    transform: translateY(14px);
    transition: opacity 220ms ease, transform 220ms var(--ease-premium), visibility 220ms;
}

.back-to-top svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.back-to-top:hover,
.back-to-top:focus-visible {
    border-color: #60a5fa;
    background: rgba(37, 99, 235, 0.24);
    color: #fff;
}

body.kd-consent-open .back-to-top {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(14px);
}

@media (max-width: 620px) {
    .back-to-top {
        right: 16px;
        bottom: calc(80px + env(safe-area-inset-bottom, 0px));
        width: 44px;
        height: 44px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .back-to-top { transition-duration: 0.01ms; }
}
