/* 返回顶部/底部按钮 */
/* 按钮基础样式 */
#backToTop, #backToBottom {
    cursor: pointer;
    border: none;
    padding: 0;
}

/* 过渡动画 */
#backToTop, #backToBottom {
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease;
    transform: translateY(10px);
}

#backToTop.visible, #backToBottom.visible {
    transform: translateY(0);
}

/* 悬停效果增强 */
#backToTop:hover, #backToBottom:hover {
    transform: translateY(0) scale(1.1);
}

/* 响应式调整 - 移动端隐藏按钮 */
@media (max-width: 768px) { /* 768px是常见的移动端与桌面端分界值，可根据需要调整 */
    #backToTop, #backToBottom {
        display: none !important; /* 强制隐藏 */
    }
}

/* 原移动端样式（被上面display:none覆盖） */
@media (max-width: 640px) {
    #backToTop, #backToBottom {
        width: 10vw;
        height: 10vw;
        max-width: 40px;
        max-height: 40px;
    }
    
    #backToTop {
        bottom: 4vh;
        right: 4vw;
    }
    
    #backToBottom {
        bottom: 12vh;
        right: 4vw;
    }
}