/* 全局样式重置 */ * { margin: 0; padding: 0; box-sizing: border-box; font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", Helvetica, Arial, sans-serif; } body { background-color: #f5f5f5; color: #333; font-size: 14px; overflow-x: hidden; /* 禁止页面横向滚动 */ } /* 顶部导航栏 */ .header { background: linear-gradient(to right, #ffe135, #ffd300); height: 44px; display: flex; align-items: center; justify-content: space-between; padding: 0 16px; position: relative; } .header::after { content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px; background: #f0f0f0; transform: scaleY(0.5); } .back-btn { width: 22px; height: 22px; background: url('data:image/svg+xml;utf8,') no-repeat center; cursor: pointer; } .header-title { font-size: 17px; font-weight: 600; color: #333; } .header-actions { display: flex; align-items: center; } .more-btn { width: 22px; height: 22px; background: url('data:image/svg+xml;utf8,') no-repeat center; cursor: pointer; } /* 活动更新通知框样式 */ .notice-container { background: #ffffff; border-radius: 8px; margin: 10px; padding: 12px; box-shadow: 0 1px 5px rgba(0,0,0,0.05); } .notice-title { font-size: 16px; font-weight: bold; color: #333; margin-bottom: 8px; padding-bottom: 8px; border-bottom: 1px solid #eeeeee; } .notice-list { max-height: 120px; overflow-y: auto; } .notice-item { font-size: 13px; color: #555; line-height: 24px; padding: 4px 0; border-bottom: 1px solid #f5f5f5; } .notice-item:last-child { border-bottom: none; } /* 按钮栏容器 - 核心修改部分 */ .button-bar-container { position: relative; margin: 10px; width: calc(100% - 20px); /* 确保容器不超出屏幕 */ overflow: hidden; /* 隐藏溢出内容 */ } .button-bar-placeholder { width: 100%; } .button-bar { position: absolute; top: 0; left: 0; width: 100%; background-color: #ffffff; padding: 8px 5px; /* 减少内边距 */ box-sizing: border-box; white-space: nowrap; border-radius: 8px; box-shadow: 0 1px 3px rgba(0,0,0,0.05); z-index: 10; } .button-bar.fixed { position: fixed; top: 0; left: 0; border-radius: 0; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); z-index: 999; } .button-item { display: inline-block; padding: 6px 14px; /* 减少按钮内边距 */ font-size: 14px; /* 缩小字体 */ color: #333; margin: 0 2px; /* 最小化左右间距 */ border-radius: 20px; background-color: #f5f5f5; transition: all 0.2s ease; cursor: pointer; border: none; outline: none; } /* 导航栏点击变色功能 */ .button-item[data-tab="tab1"] { background-color: #ffffff; } .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"] { background-color: #ffffff; } .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"] { background-color: #ffffff; } .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"] { background-color: #ffffff; } .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"] { background-color: #ffffff; } .button-item[data-tab="tab5"].active, .button-item[data-tab="tab5"]:active { background-color: #e92d34; color: #ffffff; transform: scale(0.96); } .button-item.active { font-weight: bold; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15); } /* 内容区域 */ .content { padding-top: -20px; /* 调整为更合适的高度 */ } /* 卡片样式 */ .card { width: calc(100% - 20px); height: 120px; margin: 10px auto; background-color: #fff; border-radius: 8px; border: 1px solid #eee; box-shadow: 0 1px 4px rgba(0,0,0,0.05); display: flex; overflow: hidden; cursor: pointer; } .card img { width: 160px; height: 100px; margin-left: 8px; margin-top: 10px; margin-bottom: 10px; border-radius: 6px; object-fit: cover; } .card-content { flex: 1; padding: 12px; display: flex; flex-direction: column; position: relative; } .card-title { display: block; color: #030303; font-size: 16px; font-weight: bold; margin-bottom: 5px; line-height: 1.2; letter-spacing: 0.5px; } .card-desc { display: block; color: #5E5D5D; font-size: 12px; margin-bottom: 10px; line-height: 1.4; letter-spacing: 0.3px; } .card-button { position: absolute; right: 12px; bottom: 12px; background-color: #FFC837; color: #f8f7f6; font-size: 12px; font-weight: bold; width: 90px; height: 30px; line-height: 30px; text-align: center; border-radius: 5px; cursor: pointer; } .card-time { display: block; color: #CFCBCB; font-size: 12px; margin-top: auto; line-height: 1.2; letter-spacing: 0.5px; } /* 弹窗样式 */ .popup-mask { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.5); z-index: 998; display: none; justify-content: center; align-items: center; } .popup { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 90%; max-width: 325px; background-color: #fff; border-radius: 8px; box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15); z-index: 999; padding: 15px; box-sizing: border-box; } .popup-close { position: absolute; top: 10px; right: 10px; width: 20px; height: 20px; line-height: 18px; text-align: center; font-size: 18px; color: #999; border-radius: 50%; background-color: #f5f5f5; cursor: pointer; } .popup-close:active { background-color: #e0e0e0; } .popup-title { font-size: 17px; font-weight: bold; color: #333; text-align: center; margin-bottom: 15px; padding-top: 5px; } .link-container { width: 100%; background-color: #FFF9E6; border-radius: 5px; padding: 12px; box-sizing: border-box; margin-bottom: 12px; border: 1px solid #FFE8A3; } .link-text { font-size: 13px; color: #333; word-break: break-all; line-height: 1.5; } .popup-desc-container { width: 100%; margin-bottom: 15px; } .popup-desc { font-size: 12px; color: #666; text-align: left; line-height: 1.4; margin-bottom: 3px; } .copy-btn { width: 100%; height: 40px; line-height: 40px; text-align: center; background-color: #FF7D00; color: #fff; font-size: 15px; font-weight: bold; border-radius: 5px; box-shadow: 0 2px 0 #E06A00; margin-top: 5px; border: none; cursor: pointer; } .copy-btn:active { background-color: #E06A00; box-shadow: 0 1px 0 #C05A00; transform: translateY(1px); } /* 更多提示 */ .more_hint { align-items: center; color: rgb(94, 92, 92); display: flex; font-size: 12px; justify-content: center; margin: 15px 0 30px; padding: 10px; } /* 滚动条样式 */ ::-webkit-scrollbar { width: 6px; height: 6px; } ::-webkit-scrollbar-thumb { background: #ddd; border-radius: 3px; } ::-webkit-scrollbar-track { background: #f5f5f5; } /* 标签内容容器 */ .tab-content { display: none; } .tab-content.active { display: block; } /* 提示框样式 */ .toast { position: fixed; bottom: 50px; left: 50%; transform: translateX(-50%); background-color: rgba(0, 0, 0, 0.7); color: #fff; padding: 8px 16px; border-radius: 4px; font-size: 14px; z-index: 1000; opacity: 0; transition: opacity 0.3s; } .toast.show { opacity: 1; } /* 底部导航栏样式 */ .page-nav { position: fixed; bottom: 0; left: 0; width: 100%; height: 58px; background-color: #fff; display: flex; box-shadow: 0 -1px 10px rgba(0, 0, 0, 0.08); z-index: 999; } .nav-tab { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; transition: all 0.2s; } .nav-tab.active { color: #FF7D00; } .tab-icon { width: 26px; height: 26px; margin-bottom: 4px; background-size: 100% 100%; background-repeat: no-repeat; } .tab-text { font-size: 12px; font-weight: 500; } /* 首页图标 */ .nav-tab:first-child .tab-icon { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z'/%3E%3C/svg%3E"); } /* 教程图标 */ .nav-tab:last-child .tab-icon { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='currentColor' d='M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z'/%3E%3C/svg%3E"); } /* 页面容器样式 */ .page-container { display: none; padding: 15px; } .page-container.active { display: block; } /* 教程页面样式 */ .tutorial-title { font-size: 18px; font-weight: bold; color: #333; margin: 15px 0; padding-bottom: 10px; border-bottom: 1px solid #eee; } .tutorial-step { margin-bottom: 25px; } .step-number { display: inline-block; width: 24px; height: 24px; line-height: 24px; text-align: center; background-color: #FF7D00; color: white; border-radius: 50%; margin-right: 8px; font-weight: bold; } .step-title { font-size: 16px; font-weight: 600; color: #333; margin-bottom: 8px; display: flex; align-items: center; } .step-content { font-size: 14px; color: #666; line-height: 1.6; margin-left: 32px; } .tutorial-note { background-color: #FFF9E6; border-left: 3px solid #FFC837; padding: 10px 15px; margin: 20px 0; font-size: 14px; color: #E6A23C; border-radius: 4px; } /* 内容区域底部留白 */ body { padding-bottom: 58px; margin: 0; font-family: -apple-system, BlinkMacSystemFont, sans-serif; }