.scroll-top-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, #0052cc 100%);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 15px rgba(0, 102, 204, 0.2),
                0 2px 8px rgba(0, 0, 0, 0.1),
                inset 0 1px 1px rgba(255, 255, 255, 0.2);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.9);
    font-size: 16px;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.scroll-top-button::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    padding: 2px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.scroll-top-button i {
    transform: translateY(1px);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.scroll-top-button.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.scroll-top-button:hover {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0047b3 100%);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.3),
                0 4px 12px rgba(0, 0, 0, 0.15),
                inset 0 1px 1px rgba(255, 255, 255, 0.3);
}

.scroll-top-button:hover i {
    transform: translateY(-1px);
}

.scroll-top-button:active {
    transform: translateY(0) scale(0.95);
    box-shadow: 0 2px 8px rgba(0, 102, 204, 0.2),
                0 1px 4px rgba(0, 0, 0, 0.1),
                inset 0 1px 1px rgba(255, 255, 255, 0.1);
    transition-duration: 0.1s;
}

@media (max-width: 768px) {
    .scroll-top-button {
        bottom: 25px;
        right: 25px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .scroll-top-button {
        transition: opacity 0.1s ease;
    }
    .scroll-top-button:hover {
        transform: none;
    }
} 