首页移动端全面适配优化
All checks were successful
continuous-integration/drone/push Build is passing

- 优化导航栏在平板和手机端的显示
  - 调整 logo 和导航项尺寸
  - 手机端隐藏主导航菜单(预留汉堡菜单空间)
  - 优化登录/注册按钮尺寸

- Banner 轮播区域响应式优化
  - 平板端:500px 高度,文字居中
  - 手机端:450px 高度,标题 32px
  - 小手机:400px 高度,标题 28px

- 热销产品表格移动端卡片化
  - 平板端保持表格形式,添加横向滚动
  - 手机端转换为卡片布局
  - 使用 CSS 伪元素自动添加标签
  - 为 td 添加 data-label 属性增强可访问性

- 解决方案区域响应式布局
  - 平板端改为上下布局
  - 手机端优化按钮和文字尺寸
  - 小手机端全面缩小间距和图片尺寸

- Footer 页脚全面优化
  - 平板端改为垂直布局
  - 手机端承诺区域 2 列显示
  - 版权信息改为垂直堆叠居中

- 其他优化
  - 基础设施数据改为垂直布局
  - 手机端隐藏侧边工具栏,保留回到顶部按钮
  - 移动端禁用复杂动画提升性能

响应式断点:≤1199px / ≤991px / ≤767px / ≤575px
所有改动在媒体查询内,不影响桌面端样式

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
yiqiu
2025-12-12 19:49:44 +08:00
parent 0f6da17a30
commit 3682b29757
3 changed files with 490 additions and 29 deletions

View File

@@ -1031,3 +1031,189 @@
width: calc(33.33% - 14px);
}
}
/* 移动端导航栏和页脚优化 */
@media screen and (max-width: 991px) {
/* 导航栏 */
.nav-header {
padding: 0 15px;
}
.nav-header .nav-left .nav-icon img {
width: 120px;
height: 26px;
margin-right: 20px;
}
.nav-menu .nav-item {
padding: 0 15px;
font-size: 15px;
height: 60px;
}
/* Footer 区域 */
.footer-content .footer-nav {
flex-direction: column;
gap: 30px;
}
.footer .footer-nav .footer-nav-left {
margin-right: 0;
flex-wrap: wrap;
gap: 20px;
}
.footer-nav-box {
flex: 0 1 calc(50% - 10px);
min-width: 150px;
}
.footer-content .footer-nav .footer-nav-right {
width: 100%;
}
/* 侧边工具栏 */
.aside-tools {
right: 10px;
}
.back-top-wrapper {
right: 10px;
bottom: 30px;
}
}
@media screen and (max-width: 767px) {
/* 导航栏 */
.nav-header {
height: 60px;
}
.nav-header .nav-left .nav-icon img {
width: 100px;
height: 22px;
margin-right: 10px;
}
.nav-menu .nav-item {
padding: 0 10px;
font-size: 14px;
height: 60px;
}
.nav-right .control {
margin: 0 10px;
font-size: 13px;
}
/* 下拉菜单 */
.nav-cont {
top: 60px;
}
.nav-content {
padding: 30px 15px;
gap: 15px;
}
.nav-content a {
width: 100%;
}
.nav-item-box {
min-width: auto;
width: 100%;
}
/* Footer 区域 */
.promise-box {
padding: 20px 0;
font-size: 14px;
flex: 1 1 50%;
}
.promise-box img {
height: 28px;
width: 28px;
}
.footer-content .footer-nav {
padding: 30px 0;
}
.footer-nav-box {
flex: 1 1 100%;
}
.footer-nav-box .footer-nav-head {
font-size: 15px;
}
.footer-nav-box .footer-nav-item {
font-size: 13px;
}
.footer .footer-record {
flex-direction: column;
height: auto;
padding: 20px 0;
text-align: center;
gap: 10px;
}
/* 侧边工具栏优化 */
.aside-tools {
display: none; /* 在移动端隐藏侧边工具栏,避免遮挡内容 */
}
/* 保留回到顶部按钮 */
.back-top-wrapper {
display: flex;
width: 45px;
height: 45px;
bottom: 20px;
right: 15px;
}
}
@media screen and (max-width: 575px) {
/* 导航栏进一步优化 */
.nav-header .nav-left .nav-icon img {
width: 90px;
height: 20px;
}
.nav-menu .nav-item {
padding: 0 8px;
font-size: 13px;
}
.nav-right .control {
margin: 0 8px;
font-size: 12px;
}
/* Footer */
.promise-box {
flex: 1 1 100%;
padding: 15px 0;
}
.footer-nav-right .qr-code img {
width: 70px;
height: 70px;
}
/* 回到顶部按钮 */
.back-top-wrapper {
width: 40px;
height: 40px;
bottom: 15px;
right: 10px;
}
.back-top-wrapper img {
width: 18px;
height: 18px;
}
}