/* 通用样式 - 所有页面共享 */ /* 全局样式 */ * { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; background-color: #f5f5f5; color: #333; line-height: 1.6; overflow-x: hidden; } .container { max-width: 414px; margin: 0 auto; background-color: #f5f5f5; min-height: 100vh; position: relative; padding-bottom: 80px; } /* 头部样式 */ .header { background-color: #fff; padding: 15px 20px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #eee; position: sticky; top: 0; z-index: 100; } .header-left { display: flex; align-items: center; gap: 15px; } .header-left i { font-size: 18px; color: #333; cursor: pointer; } .header-left h1 { margin: 0; font-size: 18px; font-weight: 600; color: #333; } .header-title { font-size: 20px; font-weight: 600; color: #333; text-align: left; } /* 底部导航 */ .bottom-nav { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 414px; background-color: #fff; border-top: 1px solid #eee; display: flex; justify-content: space-around; padding: 10px 0; z-index: 1000; } .nav-item { display: flex; flex-direction: column; align-items: center; gap: 5px; cursor: pointer; transition: color 0.2s; } .nav-item i { font-size: 20px; color: #999; } .nav-item span { font-size: 12px; color: #999; } .nav-item.active i, .nav-item.active span { color: #ff6900; } /* 切换开关样式 */ .toggle-switch { width: 50px; height: 30px; background: #e0e0e0; border-radius: 15px; position: relative; cursor: pointer; transition: background-color 0.3s; } .toggle-switch.active { background: #34C759; } .toggle-slider { width: 26px; height: 26px; background: white; border-radius: 50%; position: absolute; top: 2px; left: 2px; transition: transform 0.3s; box-shadow: 0 2px 4px rgba(0,0,0,0.2); } .toggle-switch.active .toggle-slider { transform: translateX(20px); } /* 响应式设计 */ @media (max-width: 414px) { .container { max-width: 100%; } } /* 动画效果 */ @keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } } /* 自定义滚动条 */ ::-webkit-scrollbar { width: 4px; } ::-webkit-scrollbar-track { background: #f1f1f1; } ::-webkit-scrollbar-thumb { background: #ccc; border-radius: 2px; } ::-webkit-scrollbar-thumb:hover { background: #999; } /* 隐藏类 */ .hidden { display: none !important; } /* 空状态样式 */ .empty-state { text-align: center; padding: 20px 0; } .empty-state i { font-size: 48px; color: #ddd; margin-bottom: 15px; } .empty-state h3 { font-size: 16px; color: #666; margin-bottom: 8px; } .empty-state p { font-size: 14px; color: #999; }