@import './tokens.css'; * { box-sizing: border-box; margin: 0; padding: 0; } body { font-family: var(--font-body); background: var(--color-background); color: var(--color-on-surface); max-width: 480px; margin: 0 auto; -webkit-font-smoothing: antialiased; } a { color: inherit; text-decoration: none; } button, input, select, textarea { font: inherit; } .material-symbols-outlined { font-family: 'Material Symbols Outlined'; font-weight: normal; font-style: normal; font-size: 24px; line-height: 1; letter-spacing: normal; text-transform: none; display: inline-block; white-space: nowrap; font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24; } /* Typography */ .headline-lg { font-family: var(--font-headline); font-size: 20px; font-weight: 600; line-height: 28px; color: var(--color-on-surface); } .headline-md { font-family: var(--font-headline); font-size: 18px; font-weight: 600; line-height: 26px; } .body-md { font-size: 14px; line-height: 20px; } .label-md { font-family: var(--font-label); font-size: 12px; font-weight: 500; line-height: 16px; letter-spacing: 0.05em; } .text-muted { color: var(--color-subtle-gray); } .text-variant { color: var(--color-on-surface-variant); } .text-primary { color: var(--color-heritage-red); } .text-success { color: var(--color-success-green); } .amount-lg { font-family: var(--font-headline); font-size: 24px; font-weight: 700; color: var(--color-heritage-red); } .amount-xl { font-family: var(--font-headline); font-size: 28px; font-weight: 700; color: var(--color-heritage-red); } /* Layout */ .page { min-height: 100vh; padding-bottom: 80px; background: var(--color-background); } .page-no-tab { min-height: 100vh; background: var(--color-background); } /* Brand logo */ .brand-logo { height: 36px; width: auto; min-width: 36px; display: inline-block; vertical-align: middle; } .brand-logo--lg { height: 48px; min-width: 48px; } .brand-logo .app-image-img.is-loaded { width: 100%; height: 100%; object-fit: contain; } .brand-logo--center { margin: 0 auto 24px; } /* Header */ .header { display: flex; align-items: center; justify-content: space-between; padding: var(--space-md) var(--space-page); background: var(--color-surface); } .header-title { font-family: var(--font-headline); font-size: 18px; font-weight: 700; line-height: 26px; color: var(--color-heritage-red); text-align: center; } /* 三端统一页面顶栏标题 */ .app-page-title { margin: 0; font-family: var(--font-headline); font-size: 18px; font-weight: 700; line-height: 26px; color: var(--color-heritage-red); text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .app-page-header { position: sticky; top: 0; z-index: 50; height: 56px; padding: 0 var(--space-page); display: flex; align-items: center; justify-content: center; background: var(--color-background); box-shadow: 0 1px 0 rgba(166, 29, 36, 0.05); } .app-page-header--fixed { position: fixed; left: 0; right: 0; } .app-page-header-action { position: absolute; top: 50%; transform: translateY(-50%); left: var(--space-page); border: none; background: none; display: flex; align-items: center; justify-content: center; color: var(--color-heritage-red); cursor: pointer; padding: 4px; } .app-page-header-action--end { left: auto; right: var(--space-page); } .app-page-header-action:active { opacity: 0.7; } .header-city { color: var(--color-heritage-red); font-size: 14px; } .back-btn { border: none; background: none; padding: 4px; color: var(--color-heritage-red); cursor: pointer; display: flex; align-items: center; } /* Cards */ .card { background: var(--color-card); border-radius: var(--radius-lg); margin: var(--space-gutter) var(--space-page); padding: var(--space-md); box-shadow: var(--shadow-card); border: var(--border-card); } .card-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; } /* Buttons */ .btn { border: none; border-radius: var(--radius-md); padding: 12px 24px; cursor: pointer; font-family: var(--font-label); font-weight: 500; font-size: 14px; letter-spacing: 0.05em; transition: opacity 0.2s, transform 0.1s; } .btn:active { transform: scale(0.98); } .btn-primary { background: var(--color-heritage-red); color: var(--color-on-primary); } .btn-outline { background: transparent; border: 1px solid var(--color-heritage-red); color: var(--color-heritage-red); } .btn-block { width: 100%; display: block; text-align: center; } .btn-pill { border-radius: var(--radius-full); padding: 6px 20px; font-size: 12px; } /* Forms */ .form-group { margin-bottom: var(--space-md); } .form-group label { display: block; margin-bottom: 6px; color: var(--color-on-surface-variant); font-size: 14px; } .form-group input, .form-group select, .form-group textarea { width: 100%; padding: 12px; border: 1px solid var(--color-outline-variant); border-radius: var(--radius-md); background: var(--color-card); color: var(--color-on-surface); } .form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; box-shadow: 0 0 0 1px rgba(130, 0, 18, 0.2); } /* Badges & status */ .benefit-badge { display: inline-flex; align-items: center; background: var(--color-aged-amber); color: var(--color-on-secondary-container); padding: 4px 12px; border-radius: 2px; font-family: var(--font-label); font-size: 12px; font-weight: 700; letter-spacing: 0.05em; } .status-tag { font-size: 13px; color: var(--color-heritage-red); font-weight: 600; } .status-open { padding: 2px 6px; border-radius: var(--radius-sm); background: rgba(45, 106, 79, 0.1); color: var(--color-success-green); font-family: var(--font-label); font-size: 10px; font-weight: 500; letter-spacing: 0.05em; } /* Tabs */ .tabs { display: flex; background: var(--color-card); border-bottom: 1px solid var(--color-surface-container); } .tab { flex: 1; text-align: center; padding: 12px 4px; font-size: 14px; color: var(--color-subtle-gray); border-bottom: 2px solid transparent; } .tab.active { color: var(--color-heritage-red); border-bottom-color: var(--color-heritage-red); font-weight: 600; } /* Tabbar (legacy) */ .tabbar { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 480px; display: flex; background: var(--color-surface); border-top: 1px solid rgba(141, 112, 110, 0.3); box-shadow: var(--shadow-tabbar); z-index: 100; } .tabbar-item { flex: 1; text-align: center; padding: 8px 0; font-size: 12px; color: var(--color-subtle-gray); } .tabbar-item.active { color: var(--color-heritage-red); } /* App tabbar (Material icons) */ .app-tabbar { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 480px; display: flex; justify-content: space-around; align-items: center; padding: 8px 16px calc(8px + env(safe-area-inset-bottom, 0px)); background: var(--color-surface); border-top: 1px solid rgba(141, 112, 110, 0.3); box-shadow: var(--shadow-tabbar); z-index: 100; } .app-tabbar-item { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 4px 16px; border-radius: 8px; color: var(--color-subtle-gray); text-decoration: none; transition: color 0.15s; } .app-tabbar-item.active { color: var(--color-heritage-red); } .app-tabbar-icon { font-size: 24px; line-height: 1; } .app-tabbar-label { font-family: var(--font-label); font-size: 12px; font-weight: 500; letter-spacing: 0.05em; line-height: 16px; margin-top: 2px; } /* Auth page */ .auth-page { min-height: 100vh; padding: 48px var(--space-page) var(--space-page); background: var(--color-background); display: flex; flex-direction: column; } .auth-subtitle { color: var(--color-subtle-gray); margin-bottom: var(--space-lg); text-align: center; } .auth-msg { color: var(--color-heritage-red); margin-bottom: 12px; font-size: 14px; } /* Mine profile */ .profile-avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--color-heritage-red); color: var(--color-on-primary); display: flex; align-items: center; justify-content: center; font-size: 24px; font-family: var(--font-headline); flex-shrink: 0; } .menu-link { display: block; padding: 12px 0; border-bottom: 1px solid var(--color-surface-container); } .menu-link:last-child { border-bottom: none; } .page-actions { padding: var(--space-md) var(--space-page); } .empty { text-align: center; padding: 48px var(--space-md); color: var(--color-subtle-gray); font-size: 14px; } /* Shop-specific */ .shop-header-card { background: var(--color-heritage-red); color: var(--color-on-primary); border-radius: var(--radius-lg); margin: var(--space-page); padding: 20px; box-shadow: var(--shadow-card); } .scan-btn { width: 120px; height: 120px; border-radius: 50%; background: var(--color-aged-amber); border: 4px solid var(--color-card); margin: 24px auto; display: flex; align-items: center; justify-content: center; font-size: 40px; cursor: pointer; box-shadow: var(--shadow-card); } .coupon-highlight { margin-top: 12px; padding: 12px; background: var(--color-secondary-container); border-radius: var(--radius-md); color: var(--color-on-secondary-container); } .code-box { word-break: break-all; font-family: monospace; font-size: 18px; background: var(--color-surface-container-low); padding: 16px; border-radius: var(--radius-md); } .line-2-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; } /* Page header */ .page-header { display: flex; align-items: center; justify-content: space-between; height: 56px; padding: 0 var(--space-page); background: var(--color-surface); border-bottom: 1px solid var(--color-surface-container); position: sticky; top: 0; z-index: 40; } .page-header-side { width: 64px; display: flex; align-items: center; } .page-header-side--right { justify-content: flex-end; } .page-header-spacer { width: 24px; display: inline-block; } .page-header-title { font-family: var(--font-headline); font-size: 18px; font-weight: 700; line-height: 26px; color: var(--color-heritage-red); text-align: center; flex: 1; } .page-header-title--spacer { font-size: 0; line-height: 0; min-height: 26px; } /* Coupon badge (ticket notch) */ .coupon-badge { position: relative; display: inline-flex; align-items: center; background: var(--color-aged-amber); color: var(--color-on-secondary-container); padding: 4px 12px; border-radius: 2px; font-family: var(--font-label); font-size: 12px; font-weight: 700; letter-spacing: 0.05em; } .coupon-badge::before, .coupon-badge::after { content: ''; position: absolute; top: 50%; width: 8px; height: 8px; background: var(--color-card); border-radius: 50%; transform: translateY(-50%); } .coupon-badge::before { left: -4px; } .coupon-badge::after { right: -4px; } /* Order status tabs */ .order-status-tabs { display: flex; overflow-x: auto; background: var(--color-card); border-bottom: 1px solid var(--color-surface-container); scrollbar-width: none; } .order-status-tabs::-webkit-scrollbar { display: none; } .order-status-tab { flex-shrink: 0; border: none; background: none; padding: 12px 16px; font-family: var(--font-label); font-size: 14px; font-weight: 500; color: var(--color-subtle-gray); border-bottom: 2px solid transparent; cursor: pointer; white-space: nowrap; } .order-status-tab.active { color: var(--color-heritage-red); border-bottom-color: var(--color-heritage-red); font-weight: 600; } /* Modal overlay */ .modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.4); backdrop-filter: blur(4px); z-index: 200; display: flex; align-items: flex-end; justify-content: center; } .modal-sheet { width: 100%; max-width: 480px; background: var(--color-card); border-radius: var(--radius-lg) var(--radius-lg) 0 0; padding: var(--space-page); max-height: 80vh; overflow-y: auto; } .modal-grabber { width: 40px; height: 4px; background: var(--color-surface-container-highest); border-radius: var(--radius-full); margin: 0 auto 16px; } .tag-reship { display: inline-block; padding: 2px 8px; border-radius: var(--radius-sm); background: rgba(42, 110, 187, 0.1); color: var(--color-status-blue); font-size: 11px; font-weight: 600; } /* App image loading / placeholder */ .app-image { position: relative; display: block; overflow: hidden; background: var(--color-surface-container-low); } .app-image--fill { width: 100%; height: 100%; } .app-image-img { display: block; width: 100%; height: 100%; opacity: 0; transition: opacity 0.25s ease; } .app-image-img--cover { object-fit: cover; } .app-image-img--contain { object-fit: contain; } .app-image-img.is-loaded { opacity: 1; } .app-image-placeholder { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: var(--color-surface-container-low); color: var(--color-outline); z-index: 1; } .app-image-fallback-icon { font-size: 32px; opacity: 0.45; } .app-image-spinner { width: 24px; height: 24px; border: 2px solid var(--color-outline-variant); border-top-color: var(--color-heritage-red); border-radius: 50%; animation: app-image-spin 0.75s linear infinite; } @keyframes app-image-spin { to { transform: rotate(360deg); } }