/* Back to Top Button Styles */

.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary), #7b3ccd);
    color: #ffffff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 82, 204, 0.3), 0 2px 4px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.8);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    padding: 0;
}

.back-to-top:hover {
    transform: translateY(-2px) scale(1);
    box-shadow: 0 8px 20px rgba(0, 82, 204, 0.4), 0 4px 8px rgba(0, 0, 0, 0.15);
}

.back-to-top:active {
    transform: translateY(0) scale(0.95);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.back-to-top .material-symbols-outlined {
    font-size: 1.5rem;
    font-weight: 600;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .back-to-top {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 2.75rem;
        height: 2.75rem;
    }
    
    .back-to-top .material-symbols-outlined {
        font-size: 1.35rem;
    }
}

@media (max-width: 480px) {
    .back-to-top {
        bottom: 1.25rem;
        right: 1.25rem;
        width: 2.5rem;
        height: 2.5rem;
    }
    
    .back-to-top .material-symbols-outlined {
        font-size: 1.25rem;
    }
}

/* Accessibility - Focus state */
.back-to-top:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.back-to-top:focus:not(:focus-visible) {
    outline: none;
}

.back-to-top:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .back-to-top {
        transition: opacity 0.2s ease, visibility 0.2s ease;
        transform: none !important;
    }
    
    .back-to-top.show {
        transform: none !important;
    }
}
