@layer utilities { .content-auto { content-visibility: auto; /* 自动控制内容可见性,优化渲染性能 */ } .scrollbar-thin { scrollbar-width: thin; /* 定义细滚动条样式 */ } .text-shadow { text-shadow: 0 1px 2px rgba(0,0,0,0.1); /* 文本阴影效果,增强可读性 */ } .card-shadow { box-shadow: 0 1px 4px rgba(0,0,0,0.05); /* 卡片阴影,增强层次感 */ } } /* 全局样式重置与基础设置 */ * { margin: 0; padding: 0; box-sizing: border-box; /* 盒模型计算方式:width/height包含边框和内边距 */ /* 使用系统默认字体栈,确保在不同设备上显示一致 */ font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", Helvetica, Arial, sans-serif; } html { /* 响应式字体计算:以375px屏幕为基准,动态调整字体大小 */ font-size: calc(100vw / 375 * 7); } body { background-color: #f5f5f5; /* 页面背景色:浅灰色 */ color: #333; /* 主要文本颜色:深灰色 */ font-size: 1.4rem; /* 基础字体大小 */ overflow-x: hidden; /* 隐藏水平滚动条,防止页面横向溢出 */ padding-bottom: 7rem; /* 底部预留空间,避免被导航栏遮挡 */ } /* 头部区域样式 */ .header { height: 6.5rem; /* 头部高度 */ line-height: 6.5rem; /* 行高等于高度,实现文字垂直居中 */ text-align: center; /* 文字水平居中 */ font-size: 1.8rem; /* 标题字体大小 */ background-color: #fff; /* 白色背景 */ border-bottom: 1px solid #eee; /* 底部浅灰色边框,分隔头部与内容 */ position: relative; /* 相对定位,用于内部元素绝对定位 */ } .back-btn { position: absolute; /* 绝对定位,相对于header */ left: 1.2rem; /* 距离左侧1.2rem */ top: 50%; /* 垂直方向居中起点 */ transform: translateY(-50%); /* 向上移动自身50%高度,实现垂直居中 */ width: 3rem; /* 按钮宽度 */ height: 3rem; /* 按钮高度 */ /* 背景图:返回箭头SVG图标 */ background: url('data:image/svg+xml;utf8,') no-repeat center; } /* 轮播图容器样式 - 首页边距基准元素 */ .banner-swiper { width: 96%; /* 宽度占屏幕94% */ height: 20rem; /* 轮播图高度 */ margin: 0 2%; /* 左右各3%边距 - 首页核心边距标准 */ margin-top: 1rem; /* 顶部1rem间距 */ border-radius: 1rem; /* 1rem圆角 */ overflow: hidden; /* 隐藏超出容器的内容 */ position: relative; /* 相对定位,用于轮播项定位 */ } .banner-slide { width: 100%; /* 轮播项宽度占满容器 */ height: 100%; /* 轮播项高度占满容器 */ display: none; /* 默认隐藏 */ } .banner-slide.active { display: block; /* 激活状态的轮播项显示 */ } .banner-swiper img { width: 100% !important; /* 图片宽度占满容器 */ height: 100% !important; /* 图片高度占满容器 */ object-fit: cover !important; /* 图片自适应裁剪,保持比例并覆盖容器 */ } /* 快捷按钮容器样式 */ .button-container { display: flex; /* 使用flex布局,子元素横向排列 */ padding: 1rem; /* 内边距1rem */ gap: 1rem; /* 子元素之间间距1rem */ box-sizing: border-box; /* 盒模型计算方式 */ background-color: #f5f5f5; /* 与页面背景色一致 */ } .btn { border: none; /* 去除边框 */ padding: 0; /* 去除内边距 */ margin: 0; /* 去除外边距 */ background: transparent; /* 透明背景 */ display: flex; /* flex布局,内容居中 */ align-items: center; /* 垂直居中 */ justify-content: center; /* 水平居中 */ overflow: hidden; /* 隐藏超出部分 */ border-radius: 1rem; /* 1rem圆角 */ position: relative; /* 相对定位,用于图片绝对定位 */ } .big-btn { width: 50%; /* 宽度占容器一半 */ height: 12rem; /* 高度12rem */ } .right-buttons { display: flex; /* flex布局 */ flex-direction: column; /* 子元素纵向排列 */ gap: 1rem; /* 子元素之间间距1rem */ flex: 1; /* 占据剩余空间 */ } .small-btn { width: 100%; /* 宽度占满父容器 */ height: 5.5rem; /* 高度5.5rem */ } .btn-img { position: absolute; /* 绝对定位,覆盖按钮 */ top: 0; /* 顶部对齐 */ left: 0; /* 左侧对齐 */ width: 100% !important; /* 宽度占满按钮 */ height: 100% !important; /* 高度占满按钮 */ object-fit: cover; /* 图片自适应裁剪 */ flex-shrink: 0; /* 不缩小 */ } .btn:active { transform: scale(0.98); /* 点击时轻微缩小,提供反馈 */ opacity: 0.9; /* 点击时轻微透明 */ } /* 标签栏容器样式 */ .button-bar-container { position: relative; /* 相对定位 */ margin-top: 0.5rem; /* 顶部0.5rem间距 */ } .button-bar-placeholder { width: 100%; /* 宽度占满 */ /* 高度将通过JS动态设置,用于占位防止滚动跳动 */ } .button-bar { position: absolute; /* 绝对定位 */ top: 0; /* 顶部对齐 */ left: 0; /* 左侧对齐 */ width: 100%; /* 宽度占满 */ background-color: #f5f5f4; /* 背景色 */ padding: 0.8rem 0.5rem 0.5rem; /* 内边距:上0.8rem,左右0.5rem,下0.5rem */ box-sizing: border-box; /* 盒模型计算方式 */ white-space: nowrap; /* 不换行,确保按钮在一行显示 */ transition: all 0.2s ease; /* 过渡动画,0.2秒缓动 */ display: flex; /* flex布局 */ justify-content: space-between; /* 子元素均匀分布 */ } .button-bar.fixed { position: fixed; /* 固定定位,滚动时保持在顶部 */ z-index: 999; /* 层级999,避免被遮挡 */ box-shadow: 0 0.1rem 0.5rem rgba(0, 0, 0, 0.1); /* 轻微阴影 */ top: 0; /* 顶部对齐 */ } .button-item { flex: 1; /* 平均分配宽度 */ display: inline-block; /* 行内块元素 */ padding: 0.6rem 0; /* 垂直内边距0.6rem */ font-size: 2rem; /* 字体大小2rem */ color: #333; /* 文字颜色 */ margin: 0 0.3rem; /* 左右0.3rem间距 */ border-radius: 3rem; /* 3rem圆角 */ background-color: #ffffff; /* 白色背景 */ transition: all 0.3s; /* 过渡动画0.3秒 */ border: none; /* 去除边框 */ cursor: pointer; /* 鼠标指针为手型 */ text-align: center; /* 文字居中 */ max-width: 20%; /* 最大宽度限制20% */ } .button-item.active { font-weight: bold; /* 激活状态文字加粗 */ box-shadow: 0 0.2rem 0.6rem rgba(0, 0, 0, 0.2); /* 激活状态阴影 */ } /* 各平台标签按钮激活状态样式 */ .button-item[data-tab="tab1"].active, .button-item[data-tab="tab1"]:active { background-color: #F5CA20; color: #ffffff; transform: scale(0.96); } .button-item[data-tab="tab2"].active, .button-item[data-tab="tab2"]:active { background-color: #27AAE2; color: #ffffff; transform: scale(0.96); } .button-item[data-tab="tab3"].active, .button-item[data-tab="tab3"]:active { background-color: #E16942; color: #ffffff; transform: scale(0.96); } .button-item[data-tab="tab4"].active, .button-item[data-tab="tab4"]:active { background-color: #be0e17; color: #ffffff; transform: scale(0.96); } .button-item[data-tab="tab5"].active, .button-item[data-tab="tab5"]:active { background-color: #e92d34; color: #ffffff; transform: scale(0.96); } /* 首页卡片样式 - 边距基准元素 */ .card { width: 96% !important; /* 宽度占屏幕96% - 核心边距标准 */ height: 15rem !important; /* 高度15rem */ margin: 0.6rem auto !important; /* 上下0.6rem,水平居中 - 核心边距标准 */ background-color: #fff; /* 白色背景 */ border-radius: 1rem !important; /* 1rem圆角 */ border: 1px solid #eee !important; /* 浅灰色边框 */ box-shadow: 0 0.1rem 0.5rem rgba(0,0,0,0.05) !important; /* 轻微阴影 */ display: flex; /* flex布局 */ overflow: hidden; /* 隐藏超出部分 */ cursor: pointer; /* 鼠标指针为手型 */ } .card img { width: 41% !important; /* 图片宽度占卡片41% */ height: 86% !important; /* 图片高度占卡片86% */ margin-left: 0.8rem !important; /* 左0.8rem */ margin-right: -0.5rem !important; /* 右-0.5rem */ margin-top: 1.2rem !important; /* 上1.2rem */ margin-bottom: 0.5rem !important; /* 下0.5rem */ border-radius: 0.8rem !important; /* 0.8rem圆角 */ object-fit: cover !important; /* 图片自适应裁剪 */ } .card-content { flex: 1; /* 占据剩余空间 */ padding: 1.2rem; /* 内边距1.2rem */ display: flex; /* flex布局 */ flex-direction: column; /* 纵向排列 */ position: relative; /* 相对定位 */ } .card-title { display: block !important; /* 块级元素 */ color: #030303 !important; /* 标题颜色 */ font-size: 2rem !important; /* 2rem字体 */ font-weight: bold !important; /* 加粗 */ margin-top: -0.3rem !important; /* 上-0.3rem */ margin-bottom: 0.3rem !important; /* 下0.3rem */ margin-left: 0.8rem !important; /* 左0.8rem */ text-align: left !important; /* 左对齐 */ line-height: 1.2 !important; /* 行高1.2 */ white-space: nowrap; /* 不换行 */ overflow: hidden; /* 隐藏超出部分 */ text-overflow: ellipsis; /* 超出显示省略号 */ } .card-desc { display: block !important; /* 块级元素 */ color: #5E5D5D !important; /* 描述颜色 */ font-size: 1.7rem !important; /* 1.7rem字体 */ margin-top: 0.1rem !important; /* 上0.1rem */ margin-bottom: 0.8rem !important; /* 下0.8rem */ margin-left: 0.8rem !important; /* 左0.8rem */ text-align: left !important; /* 左对齐 */ line-height: 1.4 !important; /* 行高1.4 */ display: -webkit-box; /* WebKit盒模型 */ -webkit-line-clamp: 2; /* 最多显示2行 */ -webkit-box-orient: vertical; /* 纵向排列 */ overflow: hidden; /* 隐藏超出部分 */ } .card-button { position: absolute; /* 绝对定位 */ right: 1.2rem; /* 右1.2rem */ bottom: 1.2rem; /* 下1.2rem */ background-color: #FFC837 !important; /* 按钮颜色 */ color: #f8f7f6 !important; /* 按钮文字颜色 */ font-size: 1.7rem !important; /* 1.7rem字体 */ font-weight: bold !important; /* 加粗 */ width: 12rem !important; /* 宽度12rem */ height: 4rem !important; /* 高度4rem */ line-height: 4rem !important; /* 行高4rem,垂直居中 */ text-align: center; /* 水平居中 */ border-radius: 0.8rem !important; /* 0.8rem圆角 */ cursor: pointer; /* 手型指针 */ } .card-time { display: block !important; /* 块级元素 */ color: #CFCBCB !important; /* 时间颜色 */ font-size: 1.6rem !important; /* 1.6rem字体 */ margin-top: auto; /* 自动上外边距,推至底部 */ margin-left: 0.8rem !important; /* 左0.8rem */ text-align: left !important; /* 左对齐 */ line-height: 1.2 !important; /* 行高1.2 */ } /* 通知容器样式 */ .notice-container { background: #eeeeec; /* 背景色 */ border-radius: 1rem; /* 1rem圆角 */ margin: 1.5rem; /* 1.5rem外边距 */ padding: 1.2rem; /* 1.2rem内边距 */ box-shadow: 0 0.1rem 0.5rem rgba(0,0,0,0.05); /* 轻微阴影 */ } .notice-title { font-size: 2rem; /* 2rem字体 */ font-weight: bold; /* 加粗 */ color: #333; /* 颜色 */ margin-bottom: 0.8rem; /* 下0.8rem */ } .notice-list { max-height: 20rem; /* 最大高度20rem */ overflow-y: auto; /* 垂直滚动 */ } .notice-item { font-size: 1.7rem; /* 1.7rem字体 */ color: rgb(43, 43, 43); /* 颜色 */ line-height: 3rem; /* 行高3rem */ border-bottom: 1px solid #aaaaaa; /* 底部边框 */ } /* 弹窗遮罩样式 */ .popup-mask { position: fixed; /* 固定定位 */ top: 0; /* 顶部对齐 */ left: 0; /* 左侧对齐 */ width: 100%; /* 宽度100% */ height: 100%; /* 高度100% */ background-color: rgba(0, 0, 0, 0.5); /* 半透明黑色 */ z-index: 998; /* 层级998 */ display: none; /* 默认隐藏 */ justify-content: center; /* 水平居中 */ align-items: center; /* 垂直居中 */ } .popup { position: fixed; /* 固定定位 */ top: 50%; /* 垂直居中起点 */ left: 50%; /* 水平居中起点 */ transform: translate(-50%, -50%); /* 平移居中 */ width: 90% !important; /* 宽度90% */ max-width: 500px; /* 最大宽度500px */ background-color: #fff; /* 白色背景 */ border-radius: 1rem; /* 1rem圆角 */ box-shadow: 0 0.3rem 1rem rgba(0, 0, 0, 0.15); /* 阴影 */ z-index: 999; /* 层级999 */ padding: 2rem; /* 2rem内边距 */ box-sizing: border-box; /* 盒模型计算 */ } .popup-close { position: absolute; /* 绝对定位 */ top: 1.5rem; /* 上1.5rem */ right: 1.5rem; /* 右1.5rem */ width: 3rem; /* 宽3rem */ height: 3rem; /* 高3rem */ line-height: 2.8rem; /* 行高2.8rem */ text-align: center; /* 居中 */ font-size: 2rem; /* 2rem字体 */ color: #999; /* 颜色 */ border-radius: 50%; /* 圆形 */ background-color: #f5f5f5; /* 背景色 */ cursor: pointer; /* 手型指针 */ } .popup-close:active { background-color: #e0e0e0; /* 点击时背景色 */ } .popup-title { font-size: 1.8rem; /* 1.8rem字体 */ font-weight: bold; /* 加粗 */ color: #333; /* 颜色 */ text-align: center; /* 居中 */ margin-bottom: 1.5rem; /* 下1.5rem */ padding-top: 0.5rem; /* 上0.5rem */ } .link-container { width: 100%; /* 宽度100% */ background-color: #FFF9E6; /* 背景色 */ border-radius: 0.8rem; /* 0.8rem圆角 */ padding: 1.5rem; /* 1.5rem内边距 */ box-sizing: border-box; /* 盒模型 */ margin-bottom: 1.5rem; /* 下1.5rem */ border: 1px solid #FFE8A3; /* 边框 */ } .link-text { font-size: 1.4rem; /* 1.4rem字体 */ color: #333; /* 颜色 */ word-break: break-all; /* 允许单词内换行 */ line-height: 1.5; /* 行高1.5 */ } .popup-desc-container { width: 100%; /* 宽度100% */ margin-bottom: 1.5rem; /* 下1.5rem */ } .popup-desc { font-size: 1.3rem; /* 1.3rem字体 */ color: #666; /* 颜色 */ text-align: left; /* 左对齐 */ line-height: 1.4; /* 行高1.4 */ margin-bottom: 0.5rem; /* 下0.5rem */ } .copy-btn { width: 100%; /* 宽度100% */ height: 5rem; /* 高度5rem */ line-height: 5rem; /* 行高5rem */ text-align: center; /* 居中 */ background-color: #FF7D00; /* 背景色 */ color: #fff; /* 文字色 */ font-size: 1.6rem; /* 1.6rem字体 */ font-weight: bold; /* 加粗 */ border-radius: 0.8rem; /* 0.8rem圆角 */ box-shadow: 0 0.2rem 0 #E06A00; /* 阴影 */ margin-top: 0.5rem; /* 上0.5rem */ border: none; /* 无边框 */ cursor: pointer; /* 手型指针 */ } .copy-btn:active { background-color: #E06A00; /* 点击背景色 */ box-shadow: 0 0.1rem 0 #C05A00; /* 点击阴影 */ transform: translateY(0.1rem); /* 轻微下移 */ } /* 分享按钮样式 */ .shareCon { background-image: linear-gradient(#ffd622, #eb7200, hsla(0, 0%, 100%, 0)); /* 渐变背景 */ border-radius: 6rem 0 0 6rem; /* 左侧半圆 */ top: 15rem; /* 上15rem */ right: -1rem; /* 右-1rem(部分超出屏幕) */ position: fixed; /* 固定定位 */ color: rgb(253, 253, 253); /* 文字色 */ width: 7rem; /* 宽7rem */ height: 5rem; /* 高5rem */ font-size: 1.6rem; /* 1.6rem字体 */ display: flex; /* flex布局 */ align-items: center; /* 垂直居中 */ justify-content: center; /* 水平居中 */ padding: 0; /* 无内边距 */ line-height: 1; /* 行高1 */ border: none; /* 无边框 */ cursor: pointer; /* 手型指针 */ } .shareget:active { transform: scale(0.95); /* 点击缩小 */ } /* 更多提示样式 */ .more_hint { align-items: center; /* 垂直居中 */ color: rgb(94, 92, 92); /* 颜色 */ display: flex; /* flex布局 */ font-size: 1.4rem; /* 1.4rem字体 */ justify-content: center; /* 水平居中 */ margin-top: 2rem; /* 上2rem */ padding: 0.5rem; /* 0.5rem内边距 */ } /* 底部导航栏样式 */ .bottom-nav { position: fixed; /* 固定定位 */ bottom: 0; /* 底部对齐 */ left: 0; /* 左侧对齐 */ width: 100%; /* 宽度100% */ height: 7rem; /* 高度7rem */ display: flex; /* flex布局 */ background-color: #fff; /* 白色背景 */ border-top: 1px solid #eee; /* 顶部边框 */ z-index: 9999; /* 最高层级 */ } .nav-item { flex: 1; /* 平均分配宽度 */ display: flex; /* flex布局 */ justify-content: center; /* 水平居中 */ align-items: center; /* 垂直居中 */ font-size: 2.3rem; /* 2.3rem字体 */ color: #666; /* 颜色 */ position: relative; /* 相对定位 */ cursor: pointer; /* 手型指针 */ } .nav-item.active { color: #FF7D00; /* 激活状态颜色 */ } .nav-item.active::after { content: ''; /* 伪元素内容 */ position: absolute; /* 绝对定位 */ bottom: 0; /* 底部对齐 */ left: 50%; /* 水平居中起点 */ transform: translateX(-50%); /* 平移居中 */ width: 3rem; /* 宽3rem */ height: 0.4rem; /* 高0.4rem */ background-color: #FF7D00; /* 背景色 */ border-radius: 0.2rem; /* 0.2rem圆角 */ } /* 内容容器样式 */ .content-container { padding-bottom: 7rem; /* 底部预留7rem空间 */ } /* 教程内容样式 */ .tutorial-content { padding: 1rem 0.5rem; /* 调整内边距,左右仅0.5rem,让内容更贴近边缘 */ background-color: #f5f5f5; /* 背景色 */ min-height: calc(100vh - 7rem); /* 最小高度:屏幕高度-导航栏高度 */ box-sizing: border-box; /* 盒模型 */ } /* 教程盒子样式 - 调整边距使其更贴近屏幕边缘 */ .tutorial-box { background-color: #ffd622; /* 背景色 */ border-radius: 1rem; /* 1rem圆角 */ padding: 1.5rem; /* 内边距 */ width: calc(100% - 1rem); /* 宽度:屏幕宽度减去1rem(左右各0.5rem) */ margin: 0.6rem 0.5rem; /* 上下0.6rem,左右0.5rem - 更贴近屏幕边缘 */ box-sizing: border-box; /* 盒模型 */ } /* 活动更新通知框样式 - 调整边距使其更贴近屏幕边缘 */ .notice-box { border: 2px solid #f7ca20; /* 边框 */ border-radius: 1rem; /* 1rem圆角 */ padding: 1rem 1.5rem; /* 内边距 */ width: calc(100% - 1rem); /* 宽度:屏幕宽度减去1rem(左右各0.5rem) */ margin-top: 1rem; /* 上边距1rem */ margin-bottom: 2rem; /* 下边距0.6rem */ margin-left: 0.5rem; /* 左边距0.5rem */ margin-right: 0.5rem; /* 右边距0.5rem */ background-color: #fdfdfd; /* 背景色 */ box-sizing: border-box; /* 盒模型 */ } .tutorial-title { font-size: 2.2rem; /* 2.2rem字体 */ font-weight: bold; /* 加粗 */ color: rgb(7, 7, 7); /* 颜色 */ display: block; /* 块级 */ margin-bottom: 1.5rem; /* 下1.5rem */ padding-left: 0.5rem; /* 左0.5rem */ text-align: left; /* 左对齐 */ } .tutorial-btn { width: 100%; /* 宽度100% */ margin-bottom: 1.5rem; /* 下1.5rem */ border-radius: 0.8rem; /* 0.8rem圆角 */ overflow: hidden; /* 隐藏超出 */ box-shadow: 0 0.1rem 0.3rem rgba(0,0,0,0.1); /* 阴影 */ cursor: pointer; /* 手型指针 */ } .tutorial-btn:active { transform: scale(0.99); /* 点击缩小 */ } .tutorial-btn:last-child { margin-bottom: 0.5rem; /* 最后一个按钮下0.5rem */ } .tutorial-img { width: 100%; /* 宽度100% */ height: 10rem; /* 高度10rem */ object-fit: cover; /* 图片裁剪 */ display: block; /* 块级 */ } /* 标签内容与页面内容显示控制 */ .tab-content, .page-content { display: none; /* 默认隐藏 */ } .tab-content.active, .page-content.active { display: block; /* 激活状态显示 */ } /* 提示框样式 */ .toast { position: fixed; /* 固定定位 */ top: 50%; /* 垂直居中 */ left: 50%; /* 水平居中 */ transform: translate(-50%, -50%); /* 平移居中 */ background-color: rgba(0, 0, 0, 0.7); /* 半透明黑 */ color: #fff; /* 白色文字 */ padding: 0.8rem 1.5rem; /* 内边距 */ border-radius: 0.5rem; /* 0.5rem圆角 */ font-size: 1.4rem; /* 1.4rem字体 */ z-index: 1000; /* 层级1000 */ opacity: 0; /* 默认透明 */ transition: opacity 0.3s; /* 透明度过渡 */ } .toast.show { opacity: 1; /* 显示时不透明 */ }
外卖领券
美团神劵包
1.美团神劵包 9.9元购600元神劵包 活动期至:
2025-07-31
点击领取
美团神劵包
1.美团神劵包 9.9元购600元神劵包
点击领取
活动期至:2025-07-31
美团外卖节
2.美团外卖节 1.惊喜红包
点击领取
活动期至:2025-12-31
美团名创优品
7.美团名创优品 满90减40
点击领取
活动期至:2025-12-31
饿了么天天领红包
1.饿了么天天领红包 最低0元吃外卖
点击领取
活动期至:2025-09-30
闪购超级品牌日
1.闪购超级品牌日 单单有福利
点击领取
活动期至:2025-12-31
京东外卖百亿补贴
1.京东外卖百亿补贴 满减劵,限时抢
点击领取
活动期至:2026-12-31
滴滴出行
1.滴滴出行 打车5折起
点击领取
活动期至:2026-12-31
更多功能持续更新中,敬请期待...
活动更新通知:
2025-08-08 闪购-1.零售品牌日
2025-08-02 饿了么-3.饿了么天天领红包
2025-07-25 美团-2.美团外卖节
2025-08-08 闪购-1.零售品牌日
2025-08-02 饿了么-3.饿了么天天领红包
2025-07-25 美团-2.美团外卖节
2025-08-10 京东-4.京东生鲜日
教程.外卖小技巧
教程1
教程2
教程3