Files
dukang/apps/mini-user/src/styles/home.css
T
jacy fc2e5b65de
CI / verify (pull_request) Has been cancelled
v3.5.3版本更新1
2026-08-20 18:54:15 +08:00

318 lines
5.7 KiB
CSS
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/* 首页(Tab 顶栏样式见 styles/nav-bar.css */
.tab-main-city-pin {
width: 14px;
height: 14px;
border-radius: 50%;
background: var(--color-heritage-red);
flex-shrink: 0;
position: relative;
}
.tab-main-city-pin::after {
content: '';
position: absolute;
left: 50%;
top: 50%;
width: 5px;
height: 5px;
margin: -2px 0 0 -2px;
border-radius: 50%;
background: #fff;
}
.tab-main-city-label {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
max-width: 100px;
}
.home-page {
background: var(--color-background);
}
.home-promo-banner {
margin: 12px var(--space-page) 0;
border-radius: var(--radius-lg);
overflow: hidden;
background: var(--color-card);
box-shadow: var(--shadow-card);
aspect-ratio: 15 / 8;
}
.home-promo-banner-swiper {
width: 100%;
height: 100%;
}
.home-promo-banner-img {
width: 100%;
height: 100%;
display: block;
}
.home-aroma-nav {
display: flex;
align-items: center;
justify-content: space-between;
gap: 8px;
margin-top: 4px;
padding: 6px var(--space-page) 4px;
background: transparent;
border-bottom: none;
position: sticky;
top: 0;
z-index: 40;
background: rgba(250, 249, 247, 0.96);
}
.home-aroma-tabs {
display: flex;
align-items: center;
gap: 4px;
flex: 1;
min-width: 0;
}
.home-aroma-city {
flex-shrink: 0;
font-size: 11px;
color: var(--color-subtle-gray);
pointer-events: none;
max-width: 72px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.home-aroma-tab {
border: none;
background: transparent;
padding: 4px 10px;
font-family: var(--font-headline);
font-size: 14px;
font-weight: 600;
line-height: 22px;
color: var(--color-subtle-gray);
border-bottom: 2px solid transparent;
white-space: nowrap;
}
.home-aroma-tab--active {
color: var(--color-heritage-red);
border-bottom-color: var(--color-heritage-red);
}
.home-fulfillment-filters {
display: flex;
align-items: center;
gap: 8px;
padding: 4px var(--space-page) 2px;
overflow-x: auto;
}
.home-fulfillment-chip {
flex-shrink: 0;
padding: 4px 12px;
font-size: 12px;
line-height: 18px;
color: var(--color-subtle-gray);
background: rgba(0, 0, 0, 0.04);
border-radius: 999px;
}
.home-fulfillment-chip--active {
color: var(--color-heritage-red);
background: rgba(179, 38, 30, 0.1);
font-weight: 600;
}
.home-product-list {
display: flex;
flex-direction: column;
gap: 10px;
padding: 8px var(--space-page) 12px;
}
.home-aroma-section {
display: flex;
flex-direction: column;
gap: 10px;
scroll-margin-top: 48px;
}
.home-aroma-section + .home-aroma-section {
margin-top: 8px;
padding-top: 12px;
border-top: 1px solid rgba(0, 0, 0, 0.04);
}
.home-aroma-section-title {
font-family: var(--font-headline);
font-size: 15px;
font-weight: 700;
line-height: 22px;
color: var(--color-on-surface);
padding: 2px 2px 0;
}
.home-empty--section {
padding: 16px 0 8px;
}
.home-product-card {
background: var(--color-card);
border-radius: 12px;
overflow: hidden;
box-shadow: var(--shadow-card);
}
.home-product-card-inner {
display: flex;
align-items: stretch;
gap: 10px;
padding: 10px;
}
.home-product-thumb-wrap {
flex-shrink: 0;
width: 88px;
height: 88px;
border-radius: 8px;
overflow: hidden;
background: var(--color-surface-container);
}
.home-product-thumb {
width: 100%;
height: 100%;
display: block;
}
.home-product-thumb--empty {
background: var(--color-surface-container);
}
.home-product-main {
flex: 1;
min-width: 0;
display: flex;
flex-direction: column;
gap: 2px;
}
.home-product-row {
display: flex;
justify-content: space-between;
align-items: flex-start;
gap: 8px;
}
.home-product-name {
font-family: var(--font-headline);
font-size: 14px;
font-weight: 600;
line-height: 20px;
color: var(--color-on-surface);
flex: 1;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.home-product-price {
font-size: 15px;
font-weight: 700;
line-height: 20px;
color: var(--color-heritage-red);
flex-shrink: 0;
}
.home-product-sub {
font-size: 11px;
color: var(--color-subtle-gray);
line-height: 16px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.home-product-footer {
margin-top: 2px;
}
.home-product-actions {
margin-top: auto;
padding-top: 4px;
display: flex;
justify-content: flex-end;
gap: 6px;
}
.home-pickup-btn {
display: inline-flex;
align-items: center;
justify-content: center;
padding: 4px 10px;
border-radius: var(--radius-full);
background: var(--color-aged-amber);
color: #5c4500;
font-size: 11px;
font-weight: 600;
line-height: 16px;
border: none;
}
.home-buy-btn {
display: inline-flex;
align-items: center;
justify-content: center;
padding: 4px 12px;
border-radius: var(--radius-full);
background: var(--color-heritage-red);
color: #fff;
font-size: 11px;
font-weight: 600;
line-height: 16px;
border: none;
}
.home-promo-footer {
margin: 0 var(--space-page) 8px;
border-radius: var(--radius-lg);
overflow: hidden;
background: var(--color-card);
box-shadow: var(--shadow-card);
aspect-ratio: 15 / 4;
}
.home-promo-footer-img {
width: 100%;
height: 100%;
display: block;
object-fit: cover;
}
.home-empty {
text-align: center;
padding: 32px 24px;
color: var(--color-subtle-gray);
font-size: 13px;
}
.home-page .coupon-badge {
position: relative;
display: inline-flex;
align-items: center;
gap: 2px;
background: var(--color-aged-amber);
color: var(--color-on-secondary-container);
padding: 2px 8px;
border-radius: 2px;
font-family: var(--font-label);
font-size: 11px;
font-weight: 700;
letter-spacing: 0.02em;
line-height: 16px;
}