/* Production-scale refinement: keep the 390px device canvas, not miniature text. */
.mobile-stage { min-height: calc(100vh - 64px); padding-block: 12px; }
.mobile-frame { height: min(844px, calc(100vh - 96px)); min-height: 560px; }
.mobile-screen {
  --paper: #f7f8f7;
  --surface: #ffffff;
  --surface-2: #fafbfa;
  --line: #e8ece9;
  --line-strong: #dfe5e1;
  font-size: 14px;
  background: #fff;
}
.mobile-screen :where(button, input, select, textarea, label, p, span, b, strong) { font-size: 13px !important; }
.mobile-screen small { font-size: 11px !important; }
.mobile-screen h1 { font-size: 20px !important; }
.mobile-screen h2 { font-size: 18px !important; }
.mobile-screen h3 { font-size: 16px !important; }
.mobile-status { font-size: 12px; }
.mobile-status-surface { background: var(--surface); }
.mobile-status-transparent { background: transparent; }
.auth-page .mobile-status-surface { background: var(--ink); }
.mobile-status-paper, .mobile-page-title-paper, .tab-paper-topbar { color: var(--ink); background: var(--surface) !important; }
.mobile-page-title-paper, .tab-paper-topbar { border-bottom: 0; }
.mobile-status-dark, .mobile-page-title-dark { color: #fff; background: var(--ink) !important; }
.mobile-page-title-dark { border-bottom: 0; }
.mobile-page-title-dark > button { color: #fff; }
.profile-screen .mobile-status-dark,
.profile-screen .mobile-page-title-dark { color: var(--ink); background: var(--surface) !important; }
.profile-screen .mobile-page-title-dark { border-bottom: 0; }
.profile-screen .mobile-page-title-dark > button { color: var(--ink); }
.profile-screen .profile-header { padding-top: 25px; background: linear-gradient(135deg, var(--brand-2), var(--brand)) !important; }
.app-topbar { gap: 14px; padding: 7px 14px 11px; }
.app-home .app-topbar { border-bottom: 0; box-shadow: none; }
.app-home > .mobile-scroll { height: calc(100% - 31px - 52px); padding-bottom: 0 !important; }
.app-home .product-section { padding-bottom: 84px; }
.app-home,
.app-home > .mobile-scroll,
.app-home .quick-grid,
.app-home .product-section { background: #fff; }
.wordmark { width: auto; flex: 0 0 auto; }
.app-home .app-topbar > .mobile-search { display: flex !important; height: 34px; min-width: 0; align-items: center !important; justify-content: center !important; padding-inline: 10px; }
.app-home .app-topbar > .mobile-search { background: var(--surface-2); }
.app-home .commerce-banner { width: 100%; margin: 0 0 16px; border-radius: 0 !important; }
.app-home .commerce-banner.banner-tone-forest { background: #1c4b3b; }
.app-home .commerce-banner.banner-tone-clay { background: #7c4b3d; }
.app-home .commerce-banner.banner-tone-ocean { background: #315c67; }
.banner-slide-content { position: absolute; inset: 0; animation: banner-reveal .42s ease both; }
.banner-slide-content > .product-art { position: absolute; }
.banner-dots { position: absolute; z-index: 4; bottom: 13px; left: 50%; display: flex; align-items: center; justify-content: center; gap: 7px; transform: translateX(-50%); }
.banner-dots button { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 50%; background: rgba(255,255,255,.42); transition: transform .2s ease, background .2s ease, box-shadow .2s ease; }
.banner-dots button.active { background: #fff; box-shadow: 0 0 0 2px rgba(255,255,255,.24); transform: scale(1.08); }
@keyframes banner-reveal { from { opacity: .2; transform: translateX(10px); } to { opacity: 1; transform: translateX(0); } }
.mobile-search-content { display: inline-flex; align-items: center; justify-content: center; gap: 8px; margin: 0 auto; white-space: nowrap; }
.wechat-capsule { display: grid; width: 88px; height: 34px; flex: 0 0 88px; grid-template-columns: 1fr 1fr; place-items: center; border: 1px solid rgba(0,0,0,.15); border-radius: 18px; background: rgba(255,255,255,.94); box-shadow: 0 1px 4px rgba(23,37,31,.06); }
.wechat-capsule > span { display: grid; height: 18px; place-items: center; color: var(--ink); font-size: 12px !important; line-height: 1; }
.wechat-capsule > span:first-child { width: 100%; border-right: 1px solid rgba(23,37,31,.16); }
.wechat-capsule .capsule-more { display: grid; grid-template-columns: 5px 6px 5px; align-items: center; justify-content: center; column-gap: 3px; }
.wechat-capsule .capsule-more i { display: block; align-self: center; justify-self: center; width: 5px; height: 5px; margin: 0; border-radius: 50%; background: #050505; }
.wechat-capsule .capsule-more i:nth-child(2) { width: 6px; height: 6px; }
.wechat-capsule .capsule-target { position: relative; display: block; width: 18px; height: 18px; box-sizing: border-box; border: 2px solid #050505; border-radius: 50%; }
.wechat-capsule .capsule-target i { position: absolute; top: 50%; left: 50%; display: block; width: 7px; height: 7px; margin: 0; border-radius: 50%; background: #050505; transform: translate(-50%, -50%); }
.detail-side-actions { position: absolute; z-index: 6; top: 84px; right: 14px; display: flex; flex-direction: column; gap: 8px; }
.detail-side-actions button { display: grid; width: 34px; height: 34px; place-items: center; border: 0; border-radius: 50%; color: var(--ink); background: rgba(255,255,255,.88); box-shadow: 0 3px 12px rgba(20,40,30,.12); }
.detail-side-actions button.is-favorite { color: var(--price); }
.mobile-page-title h1 { font-size: 17px !important; }
.mobile-page-title { position: relative; height: 48px; grid-template-columns: 56px minmax(0, 1fr) auto; padding-right: 14px; }
.mobile-page-title > h1 { position: absolute; top: 50%; left: 50%; width: 132px; transform: translate(-50%, -50%); pointer-events: none; }
.mobile-page-title > button { width: auto; min-width: 40px; white-space: nowrap; }
.mobile-header-tools { z-index: 2; display: flex; grid-column: 3; align-items: center; justify-self: end; gap: 5px; }
.mobile-header-tools > button { display: inline-flex; width: auto; min-width: 30px; height: 32px; align-items: center; justify-content: center; padding: 0 5px; color: var(--brand); border: 0; background: transparent; font-size: 9px !important; white-space: nowrap; }
.mobile-header-tools .wechat-capsule { width: 88px; height: 34px; }
.product-detail .detail-floatbar { top: 38px; right: 14px; left: 14px; align-items: center; }
.product-detail .detail-floatbar > .wechat-capsule { display: grid; width: 88px; height: 34px; gap: 0; grid-template-columns: 1fr 1fr; }
.auth-page { position: relative; }
.auth-capsule { position: absolute; z-index: 20; top: 38px; right: 14px; }
.mobile-header-spacer { display: block; width: 40px; height: 40px; }
.mobile-screen .auth-mark { font-size: 28px !important; }
.mobile-screen .shop-logo-mark { font-size: 26px !important; }
.mobile-screen .about-mark { font-size: 34px !important; }
.profile-header .avatar { font-size: 18px !important; }
.mobile-sheet { max-height: calc(100% - 24px); overflow-y: auto; padding-bottom: 28px; overscroll-behavior: contain; scrollbar-width: none; }
.mobile-sheet::-webkit-scrollbar { display: none; }
.product-detail > .sheet-mask { top: 31px; bottom: -31px; }
.mobile-scroll:has(+ .mobile-bottom-nav) { padding-bottom: 78px; }
.quick-grid button, .mobile-bottom-nav button { font-size: 12px !important; }
.quick-icon { width: 46px; height: 46px; }
.banner-kicker, .banner-index { font-size: 11px !important; }
.banner-copy h1 { font-size: 25px !important; }
.section-heading h2, .section-heading.compact h2 { font-size: 17px !important; }
.section-heading > span, .section-heading.compact button { font-size: 12px !important; }
.category-strip button, .review-filter button, .coupon-tabs button, .order-tabs button { min-height: 32px; font-size: 12px !important; }
.product-card-name { font-size: 14px !important; }
.product-card-sub { font-size: 12px !important; }
.product-card-meta b, .price-line > b, .confirm-product strong, .summary-total strong, .confirm-submit-bar b, .points-product-page section > b, .campaign-copy strong { font-size: 21px !important; }
.product-card-meta small, .detail-metrics, .review-item span, .review-full-item header span, .review-full-item > small { font-size: 11px !important; }
.stars { font-size: 12px !important; }
.detail-main-info h1 { font-size: 20px !important; }
.detail-main-info > p, .story-panel span, .review-item p, .review-full-item p { font-size: 13px !important; }
.detail-choice-row, .address-panel, .confirm-options button, .confirm-options > div, .price-summary > div, .order-info-list > div { font-size: 13px !important; }
.detail-choice-row { min-height: 54px; }
.shop-line, .confirm-product b, .address-panel b, .order-address b, .mobile-order-card b { font-size: 14px !important; }
.address-panel p, .order-address p, .confirm-product span, .mobile-order-card span { font-size: 12px !important; }
.option-group label, .quantity-row label { font-size: 14px !important; }
.option-group button { min-width: 74px; height: 38px; }
.quantity-control { display: flex; width: 116px; height: 36px; align-items: stretch; flex: 0 0 116px; box-sizing: border-box; border-radius: 8px; }
.quantity-control button { width: 36px; height: 100%; min-width: 36px; flex: 0 0 36px; box-sizing: border-box; padding: 0; }
.quantity-control b { display: grid; width: auto; height: 100%; min-width: 0; place-items: center; flex: 1; box-sizing: border-box; margin: 0; padding: 0; font-size: 13px !important; line-height: 1; }
.cart-item .quantity-control { transform: none; }
.cart-item .quantity-control b { grid-column: auto; }
.mobile-action-bar button, .sheet-confirm, .form-submit, .feedback-submit, .single-bottom-action button, .auth-submit { font-size: 14px !important; }
.mobile-action-bar button { min-height: 46px; }
.status-ticket { font-size: 12px !important; }
.status-ticket.is-small { font-size: 11px !important; }
.points-balance > b { font-size: 34px !important; }
.points-records > div b, .points-product-list article b, .coupon-copy b, .activity-card h3 { font-size: 14px !important; }
.points-records > div small, .points-product-list article span, .coupon-copy span, .coupon-copy small, .activity-card span, .activity-card small { font-size: 11px !important; }
.points-mall-page { height: calc(100% - 31px - 48px); padding: 12px 12px 24px; }
.points-mall-tabs { display: flex; gap: 7px; margin-bottom: 12px; overflow-x: auto; }
.points-mall-tabs button { flex: 0 0 auto; min-height: 34px; padding: 0 13px; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); background: white; }
.points-mall-tabs button.active { color: var(--brand); border-color: var(--brand); background: var(--brand-soft); font-weight: 700; }
.coupon-center-page { height: calc(100% - 31px - 48px); padding-top: 12px; }
.coupon-center-note { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; padding: 13px; color: white; border-radius: 10px 3px 10px 3px; background: var(--ink); }
.coupon-center-note span { color: rgba(255,255,255,.68); font-size: 11px !important; }
.coupon-card { grid-template-columns: 78px minmax(0, 1fr) 68px; gap: 9px; padding: 12px; }
.coupon-value b { font-size: 22px !important; }
.coupon-value span { font-size: 11px !important; line-height: 1.35; }
.coupon-copy b { font-size: 14px !important; }
.coupon-card > button { width: 68px; height: 32px; white-space: nowrap; font-size: 12px !important; }
.points-record-title { display: flex !important; align-items: center; justify-content: space-between; }
.points-record-title button { min-height: 32px; padding: 0 9px; border: 1px solid var(--line); border-radius: 5px; color: var(--muted); background: white; }
.service-page { height: calc(100% - 31px - 48px); grid-template-rows: 76px 1fr 64px; }
.conversation-strip { padding: 8px 11px 10px; }
.conversation-strip button { min-width: 82px; gap: 4px; line-height: 1.25; }
.chat-bubble { padding: 10px 12px; font-size: 13px !important; line-height: 1.55; }
.conversation-strip i { width: 16px; height: 16px; font-size: 10px !important; }
.chat-stream { scrollbar-width: none; }
.chat-stream::-webkit-scrollbar { display: none; }
.chat-input { grid-template-columns: 40px minmax(0, 1fr) 56px; gap: 8px; padding: 7px 12px 12px 10px; }
.chat-input button, .chat-input input { height: 40px; }
.chat-input button.send { min-width: 56px; white-space: nowrap; border-radius: 8px; }

/* App cards use one symmetric radius system. Chat bubbles retain a directional tail. */
.mobile-screen :where(.commerce-banner, .product-card, .story-panel, .address-panel, .confirm-shop-card, .confirm-options, .price-summary, .order-goods, .order-timeline, .order-info-list, .category-feature, .cart-item, .mobile-order-card, .profile-order-panel, .profile-menu, .coupon-card, .coupon-center-note, .points-balance, .activity-card, .shop-list-card, .shop-feature, .logistics-page > section, .group-summary, .refund-detail-page > section, .address-list-page article, .feedback-page-proto > section) { border-radius: 12px !important; }
.mobile-screen :where(.quick-icon, .address-icon, .category-product-grid button, .points-product-list article, .shop-logo-mark, .state-icon, .avatar, .refund-product, .review-product-head, .review-conversation, .avatar-edit, .activity-products-page article, .coupon-select-card, .group-choice, .campaign-quantity, .random-group, .group-option, .refund-amount, .refund-detail-page > article, .preference-page section) { border-radius: 10px !important; }
.mobile-screen :where(.result-icon, .about-mark, .auth-mark) { border-radius: 16px !important; }

.profile-edit-fields { margin-top: 10px; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: white; }
.profile-field-row { display: grid; width: 100%; min-height: 50px; grid-template-columns: 72px minmax(0, 1fr); align-items: center; padding: 0 16px; text-align: left; border: 0; border-bottom: 1px solid #edf0ed; background: white; }
.profile-field-row:last-child { border-bottom: 0; }
.profile-field-row > span { color: var(--ink-2); }
.profile-field-row > b { display: flex; min-width: 0; align-items: center; justify-content: flex-end; gap: 8px; color: var(--ink); font-weight: 500; white-space: nowrap; }
.profile-field-row > b .icon { color: var(--muted); }
.profile-field-row.editable input { width: 100%; height: 49px; padding: 0 0 0 12px; text-align: right; border: 0; outline: 0; background: transparent; color: var(--ink); }
.profile-picker-sheet header { display: flex; align-items: center; justify-content: space-between; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.profile-picker-sheet header h2 { margin: 0; font-size: 18px !important; }
.profile-picker-sheet header > button { width: 30px; height: 30px; border: 0; border-radius: 50%; color: var(--muted); background: var(--paper); }
.profile-option-list { display: flex; flex-direction: column; padding-top: 8px; }
.profile-option-list > button { display: flex; min-height: 48px; align-items: center; justify-content: space-between; padding: 0 4px; border: 0; border-bottom: 1px solid #edf0ed; background: white; }
.profile-option-list > button.active { color: var(--brand); font-weight: 700; }
.profile-date-field, .profile-mobile-form label { display: flex; flex-direction: column; gap: 7px; margin-top: 14px; }
.profile-date-field input, .profile-mobile-form input { width: 100%; height: 44px; padding: 0 11px; border: 1px solid var(--line-strong); border-radius: 8px; background: white; }
.profile-date-field small { color: var(--muted); font-size: 11px !important; }
.profile-mobile-form label > div { display: grid; grid-template-columns: 1fr 96px; gap: 8px; }
.profile-mobile-form label > div button { border: 1px solid var(--line-strong); border-radius: 8px; color: var(--brand); background: white; white-space: nowrap; }

/* Every native-title page subtracts the same 48px title bar. */
.category-page { height: calc(100% - 31px - 48px - 66px); }
.cart-page { height: calc(100% - 31px - 48px - 66px - 62px); }
.profile-screen > .mobile-scroll { height: calc(100% - 31px - 48px); }
.mobile-order-list, .coupon-page { height: calc(100% - 31px - 48px - 40px); }
.mobile-screen :where(.product-list-page, .collection-page, .points-page, .activity-page, .address-list-page, .reviews-page, .feedback-page-proto, .settings-page, .secondary-page, .shop-detail-page, .result-page, .logistics-page, .form-page, .review-detail-page, .profile-edit-page, .activity-products-page, .points-product-page, .campaign-detail-page .mobile-scroll, .group-select-page, .refund-detail-page, .preference-page, .confirm-scroll, .order-detail-scroll) { height: calc(100% - 31px - 48px); }

/* Category prototype uses the production three-level layout and deliberately isolates legacy category rules. */
.mobile-screen .category-page { display: grid; height: calc(100% - 31px - 48px - 66px); grid-template-columns: 88px minmax(0, 1fr); overflow: hidden; background: #fff; }
.mobile-screen .category-page > aside { overflow-y: auto; background: #f7f8f7; }
.mobile-screen .category-page > aside > button { display: block; width: 100%; height: 50px; padding: 0 8px; border: 0 !important; border-left: 3px solid transparent !important; color: var(--muted); background: transparent !important; font-size: 11px !important; text-align: center; }
.mobile-screen .category-page > aside > button.active { color: var(--brand) !important; border-left-color: var(--brand) !important; background: #fff !important; font-weight: 700; }
.mobile-screen .category-page > section { display: flex; min-width: 0; overflow: hidden; flex-direction: column; padding: 0 !important; background: #fff; }
.mobile-screen .category-page .category-small-tabs { display: flex; min-height: 44px; gap: 18px; box-sizing: border-box; padding: 0 15px; overflow-x: auto; border-bottom: 0 !important; background: #fff; scrollbar-width: none; }
.mobile-screen .category-page .category-small-tabs::-webkit-scrollbar { display: none; }
.mobile-screen .category-page .category-small-tabs > button { position: relative; flex: 0 0 auto; height: 44px; padding: 0 !important; border: 0 !important; border-radius: 0 !important; color: var(--muted) !important; background: transparent !important; font-size: 10px !important; }
.mobile-screen .category-page .category-small-tabs > button.active { color: var(--brand) !important; font-weight: 700; }
.mobile-screen .category-page .category-all-scroll { flex: 1; overflow-y: auto; background: #fff; scroll-behavior: smooth; }
.mobile-screen .category-page .category-group-section { scroll-margin-top: 0; padding: 10px 13px 24px; }.mobile-screen .category-page .category-group-section + .category-group-section { padding-top: 18px; }
.mobile-screen .category-page .category-leaf-head { display: flex; align-items: center; min-height: 36px; box-sizing: border-box; padding: 0 3px 8px; background: #fff; }
.mobile-screen .category-page .category-leaf-head b { color: var(--ink); font-size: 13px !important; }.mobile-screen .category-page .category-leaf-head span { color: var(--muted); font-size: 9px !important; }
.mobile-screen .category-page .category-leaf-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 8px; box-sizing: border-box; padding: 0; background: #fff; }
.mobile-screen .category-page .category-leaf-card { display: flex; min-width: 0; min-height: 98px; align-items: center; justify-content: center; flex-direction: column; gap: 8px; padding: 4px !important; border: 0 !important; border-radius: 0 !important; color: var(--ink-2); background: transparent !important; font-size: 9px !important; }
.mobile-screen .category-page .category-leaf-card:hover { color: var(--brand); background: transparent !important; }.mobile-screen .category-page .category-leaf-card .product-art { width: 72px; height: 72px; border-radius: 0; background: transparent; box-shadow: none; }.mobile-screen .category-page .category-leaf-card span { display: block; overflow: hidden; width: 100%; white-space: nowrap; text-align: center; text-overflow: ellipsis; }
.mobile-screen .category-page .category-sub-empty { display: flex; min-height: 168px; align-items: center; justify-content: center; flex-direction: column; gap: 7px; color: var(--muted); text-align: center; }.mobile-screen .category-page .category-sub-empty b { color: var(--ink); font-size: 12px !important; }.mobile-screen .category-page .category-sub-empty > span:last-child { font-size: 9px !important; }
.mobile-screen .category-page .category-empty-state { display: flex; flex: 1; align-items: center; justify-content: center; flex-direction: column; gap: 9px; color: var(--muted); text-align: center; }.mobile-screen .category-page .category-empty-state b { color: var(--ink); font-size: 13px !important; }.mobile-screen .category-page .category-empty-state span { font-size: 10px !important; }

/* Flat mobile surfaces: hierarchy comes from spacing and dividers rather than floating cards. */
.app-home .product-grid { gap: 18px 12px; }
.app-home .product-card { padding-bottom: 4px; border: 0; border-radius: 0 !important; background: transparent; }
.app-home .product-card .product-art { border-radius: 10px; }
.app-home .product-card-name,
.app-home .product-card-sub,
.app-home .product-card-meta { margin-inline: 2px; }

.home-waterfall { display: flex; align-items: flex-start; gap: 12px; }
.home-waterfall-column { display: flex; width: calc(50% - 6px); flex-direction: column; }
.home-waterfall-item { display: block; width: 100%; margin: 0 0 9px; padding: 0; overflow: hidden; text-align: left; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.home-waterfall-art { display: block; width: 100%; overflow: hidden; border-bottom: 1px solid var(--line); background: #e6ebe8; }
.home-waterfall-art .product-art { display: block; width: 100%; height: 100%; border-radius: 0; }
.home-waterfall-copy { display: flex; min-width: 0; flex-direction: column; padding: 10px; }
.home-waterfall-name { display: block; overflow: hidden; color: var(--ink); font-size: 14px !important; font-weight: 700; line-height: 1.45; white-space: nowrap; text-overflow: ellipsis; }
.home-waterfall-promotion { align-self: flex-start; max-width: 100%; margin-top: 8px; padding: 3px 6px; overflow: hidden; color: var(--price); border-radius: 4px; background: var(--price-soft); font-size: 10px !important; line-height: 1.35; white-space: nowrap; text-overflow: ellipsis; }
.home-waterfall-subtitle { display: -webkit-box; margin-top: 7px; overflow: hidden; color: var(--muted); font-size: 11px !important; line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.home-waterfall-promotion + .home-waterfall-subtitle { -webkit-line-clamp: 1; }
.home-waterfall-meta { display: flex; align-items: flex-end; justify-content: space-between; gap: 6px; margin-top: 11px; }
.home-waterfall-meta b { color: var(--price); font: 700 20px var(--font-display); }
.home-waterfall-meta small { color: var(--muted); font-size: 10px !important; white-space: nowrap; }

.profile-screen .profile-header { margin: 0; padding: 20px 18px 22px; color: var(--ink); border-bottom: 1px solid var(--line); background: var(--surface) !important; }
.profile-screen .profile-header span { color: var(--muted); }
.profile-screen .profile-header button { color: var(--brand); }
.profile-screen .profile-header .avatar { color: #fff; border-radius: 14px !important; background: var(--brand); }
.profile-screen .profile-order-panel,
.profile-screen .profile-menu { margin: 10px 0 0; padding: 14px 18px; border: 0; border-radius: 0 !important; background: var(--surface); }
.profile-screen .profile-order-panel header { padding-bottom: 12px; }
.profile-screen .profile-order-panel > div { padding-top: 14px; }
.profile-screen .profile-menu { padding-block: 2px; }
.profile-screen .profile-menu button { height: 46px; padding-inline: 0; }

.mobile-screen .cart-page { padding: 0 0 20px; background: var(--surface); }
.mobile-screen .cart-item { margin: 0; padding: 14px 16px; border: 0; border-radius: 0 !important; }
.mobile-screen .cart-item .product-art { border-radius: 8px !important; }

.mobile-screen .mobile-order-list { padding: 0 0 24px; }
.mobile-screen .mobile-order-card { margin: 10px 0 0; padding: 14px 16px; border: 0; border-block: 1px solid var(--line); border-radius: 0 !important; }

.mobile-screen .story-panel { border: 0; border-radius: 0 !important; }
.mobile-screen .story-panel > div { padding-inline: 0; }

.mobile-screen .confirm-scroll { padding: 0 0 80px; }
.mobile-screen .address-panel,
.mobile-screen :where(.confirm-shop-card, .confirm-options, .price-summary) { margin: 0 0 8px; padding: 14px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }
.mobile-screen .address-panel { border-top: 0; }
.mobile-screen :where(.order-goods, .order-timeline, .order-info-list) { margin: 8px 0 0; padding: 14px 16px; border: 0; border-block: 1px solid var(--line); border-radius: 0 !important; }

.mobile-screen .secondary-page { padding: 0 0 20px; background: var(--surface); }
.mobile-screen .secondary-page > .list-search { margin: 12px; }
.mobile-screen .shop-list-search { display: grid; grid-template-columns: minmax(0, 1fr) 64px; gap: 8px; margin: 12px; }
.mobile-screen .shop-list-search .list-search { margin: 0; }
.mobile-screen .shop-list-search > button { border: 0; border-radius: 8px; color: #fff; background: var(--brand); font-size: 10px; font-weight: 700; }
.mobile-screen .shop-list-card { min-height: 90px; grid-template-columns: 62px minmax(0, 1fr) 20px; margin: 0; padding: 14px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }
.mobile-screen .shop-list-logo { display: block; width: 62px; height: 62px; border-radius: 10px; background: var(--surface-2); object-fit: cover; }
.mobile-screen .shop-list-card > div { gap: 8px; }
.mobile-screen .shop-list-card b { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.mobile-screen .shop-list-card > div > span { font-size: 9px; }
.mobile-screen .shop-product-grid .product-card,
.mobile-screen .collection-page .product-card,
.mobile-screen .product-list-page .product-card { border: 0; border-radius: 0 !important; background: transparent; }
.mobile-screen :where(.shop-product-grid, .collection-page, .product-list-page) .product-card .product-art { border-radius: 10px; }

.mobile-screen .points-page { padding: 0 0 22px; }
.mobile-screen .points-balance { border-radius: 0 !important; }
.mobile-screen .points-records { margin: 10px 0 0; padding: 14px 16px; border: 0; border-block: 1px solid var(--line); border-radius: 0; }
.mobile-screen .points-product-list { gap: 0; }
.mobile-screen .points-product-list article { padding: 13px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }

.mobile-screen .activity-card,
.mobile-screen .activity-products-page article { margin: 0; padding: 14px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }
.mobile-screen .activity-products-page > header { margin-bottom: 0; }

.mobile-screen .address-list-page { padding: 0; }
.mobile-screen .address-list-page article { margin: 0; padding: 14px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }

.mobile-screen .logistics-page { padding: 0 0 20px; }
.mobile-screen .logistics-page > section { border-radius: 0 !important; }
.mobile-screen .logistics-product { margin: 8px 0 0; padding: 12px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; }
.mobile-screen .logistics-page article { padding: 16px; border: 0; border-radius: 0; }

.mobile-screen .form-page { padding: 0 0 22px; }
.mobile-screen :where(.refund-product, .review-product-head, .rating-row) { padding: 14px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }
.mobile-screen .form-page > label,
.mobile-screen .form-page > .upload-grid,
.mobile-screen .form-page > .form-submit { margin-right: 16px; margin-left: 16px; }

.mobile-screen .review-detail-page { padding: 0; }
.mobile-screen .review-conversation { margin: 8px 0 0; padding: 16px; border: 0; border-block: 1px solid var(--line); border-radius: 0 !important; }
.mobile-screen .review-reply-box,
.mobile-screen .reply-waiting { margin-inline: 16px; }

.mobile-screen .profile-edit-page { padding: 0 0 20px; }
.mobile-screen .avatar-edit { padding: 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }
.mobile-screen .profile-edit-fields { margin-top: 8px; border: 0; border-radius: 0; }

.mobile-screen .refund-detail-page { padding: 0; }
.mobile-screen .refund-detail-page > section { border-radius: 0 !important; }
.mobile-screen .refund-amount,
.mobile-screen .refund-detail-page > article { margin: 8px 0 0; padding: 14px 16px; border: 0; border-block: 1px solid var(--line); border-radius: 0 !important; }

.mobile-screen .feedback-page-proto { padding: 0 0 20px; }
.mobile-screen .feedback-page-proto > section,
.mobile-screen .feedback-record { margin: 0; padding: 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0 !important; }
.mobile-screen .feedback-page-proto > h3 { margin-inline: 16px; }

.mobile-screen .settings-page { padding: 10px 0 20px; }
.mobile-screen .settings-page > button { padding-inline: 16px; border-radius: 0 !important; }
.mobile-screen .settings-page .logout-button { margin: 16px; width: calc(100% - 32px); }

.mobile-screen .result-page > div { padding-inline: 0; border: 0; border-block: 1px solid var(--line); border-radius: 0; }

/* White-first canvas: near-white gaps separate sections while content stays on clean white surfaces. */
.profile-screen,
.profile-screen > .mobile-scroll,
.mobile-screen :where(.mobile-order-list, .confirm-scroll, .order-detail-scroll, .points-page, .activity-page, .coupon-page, .logistics-page, .form-page, .review-detail-page, .profile-edit-page, .activity-products-page, .group-select-page, .refund-detail-page, .feedback-page-proto, .settings-page, .preference-page) {
  background: var(--paper);
}

.mobile-screen :where(.profile-header, .profile-order-panel, .profile-menu, .cart-item, .mobile-order-card, .address-panel, .confirm-shop-card, .confirm-options, .price-summary, .order-goods, .order-timeline, .order-info-list, .points-records, .activity-card, .shop-list-card, .logistics-product, .logistics-page article, .refund-product, .review-product-head, .review-conversation, .profile-edit-fields, .refund-amount, .refund-detail-page > article, .feedback-page-proto > section, .feedback-record, .settings-page > button) {
  background: #fff;
}

.service-page { background: #f7f8f7; }
.chat-input button:not(.send),
.quantity-control button,
.profile-picker-sheet header > button { background: #f7f8f7; }

/* Stronger whitespace segmentation: remove structural outlines and expose clear white section blocks. */
.mobile-screen { --paper: #f4f5f4; }
.mobile-screen .cart-page { background: var(--paper); }
.mobile-screen .cart-shop-group { margin: 0 0 10px; border: 0; border-radius: 0; background: #fff; }
.mobile-screen .cart-shop-group > header { padding-inline: 16px; border-bottom: 0; }
.mobile-screen .cart-shop-group > header .cart-shop-icon { color: #245743; background: transparent; }
.mobile-screen .cart-shop-group .cart-item { position: relative; background: #fff; }
.mobile-screen .cart-shop-group .cart-item + .cart-item { border-top: 0; }
.mobile-screen .cart-shop-group .cart-item + .cart-item::before {
  position: absolute;
  top: 0;
  right: 16px;
  left: 144px;
  height: 1px;
  background: var(--line);
  content: '';
}

.mobile-screen :where(.profile-header, .profile-order-panel, .profile-menu, .mobile-order-card, .address-panel, .confirm-shop-card, .confirm-options, .price-summary, .order-goods, .order-timeline, .order-info-list, .points-records, .activity-card, .shop-list-card, .logistics-product, .logistics-page article, .refund-product, .review-product-head, .review-conversation, .profile-edit-fields, .refund-amount, .refund-detail-page > article, .feedback-page-proto > section, .feedback-record) {
  border: 0 !important;
}

.profile-screen .profile-header,
.profile-screen .profile-order-panel,
.profile-screen .profile-menu { margin-bottom: 0; }
.profile-screen .profile-menu + .profile-menu { margin-top: 10px; }
.mobile-screen .mobile-order-card { margin-top: 10px; }
.mobile-screen :where(.confirm-shop-card, .confirm-options, .price-summary, .order-goods, .order-timeline, .order-info-list, .points-records, .logistics-product, .review-conversation, .refund-amount, .refund-detail-page > article) { margin-top: 10px; }

.service-page,
.chat-input button:not(.send),
.quantity-control button,
.profile-picker-sheet header > button { background: var(--paper); }

/* Admin pages use production-like table and form density. */
.admin-shell { font-size: 14px; grid-template-columns: 244px 1fr; }
.admin-shell :where(button, input, select, textarea, label, p, span, b, strong, td, th) { font-size: 13px !important; }
.admin-shell small { font-size: 11px !important; }
.admin-topbar { height: 60px; }
.admin-topbar b { font-size: 14px !important; }
.admin-sidebar nav button { font-size: 14px !important; }
.admin-page { height: calc(100vh - 124px); padding: 18px 22px 28px; }
.admin-page-heading h1 { font-size: 24px !important; }
.admin-page-heading p { font-size: 13px !important; }
.module-tabs { height: 44px; margin: 0 0 14px; }
.module-tabs button { height: 44px; font-size: 13px !important; }
.admin-filter-bar { padding: 16px; }
.filter-query-group { display: flex; min-width: 0; flex: 1; align-items: end; gap: 14px; }
.filter-query-group .filter-fields { flex: 0 1 auto; }
.filter-query-group .filter-actions, .filter-business-actions { flex: 0 0 auto; }
.filter-fields label > span, .dialog-field > span, .edit-form-grid label > span { font-size: 13px !important; }
.filter-fields input, .filter-fields select, .dialog-field input, .dialog-field select, .edit-form-grid input, .edit-form-grid select { height: 38px; font-size: 13px !important; }
.filter-actions button { height: 38px; min-width: 58px; white-space: nowrap; font-size: 13px !important; }
.filter-business-actions { display: flex; align-items: center; gap: 8px; }
.filter-business-actions button { display: flex; height: 38px; align-items: center; gap: 6px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 6px; background: white; white-space: nowrap; font-size: 13px !important; }
.filter-action-divider { width: 1px; height: 26px; margin: 0 2px; background: var(--line-strong); }
.filter-business-actions .business-primary { color: white; border-color: var(--brand); background: var(--brand); font-weight: 700; }
.table-toolbar { height: 50px; }
.table-toolbar b { font-size: 14px !important; }
.table-toolbar button { height: 32px; font-size: 12px !important; }
.admin-table th { height: 46px; font-size: 13px !important; }
.admin-table td { height: 62px; font-size: 13px !important; }
.member-table-cell b, .admin-table td > b { font-size: 13px !important; }
.member-table-cell small, .cell-sub { font-size: 11px !important; }
.admin-pagination { min-height: 52px; }
.admin-pagination button, .admin-pagination select { min-height: 32px; font-size: 12px !important; }
.overview-metrics span, .overview-metrics small, .overview-tasks b, .overview-tasks small, .service-console b, .service-console small, .service-console time { font-size: 12px !important; }
.overview-metrics b { font-size: 26px !important; }
.fake-chart i { font-size: 11px !important; }
.service-console { height: 100%; }
.service-console > main > header { grid-template-columns: 38px 1fr auto auto; }
.service-chat div, .service-console input, .service-console button { font-size: 13px !important; }
.admin-dialog h2, .admin-drawer h2 { font-size: 20px !important; }
.description-grid b, .description-grid span { font-size: 13px !important; }

/* Real menu hierarchy, with framework-owned sections clearly marked. */
.admin-menu-tree { gap: 4px !important; }
.sidebar-menu-group { display: block; }
.admin-sidebar nav .sidebar-group-toggle { height: 34px; padding: 0 9px; color: #7f9b8f; background: transparent !important; font-size: 12px !important; font-weight: 700; letter-spacing: .04em; }
.sidebar-group-toggle > span { flex: 1; }
.sidebar-group-toggle > small { padding: 2px 5px; border: 1px solid rgba(255,255,255,.12); border-radius: 3px; color: #9db1a8; font-size: 10px !important; font-weight: 500; letter-spacing: 0; }
.sidebar-group-toggle .icon { transition: transform .18s ease; }
.sidebar-group-toggle .icon.is-open { transform: rotate(180deg); }
.sidebar-group-items { display: flex; flex-direction: column; gap: 2px; }
.admin-sidebar nav .sidebar-group-items > button { height: 38px; padding-left: 20px; font-size: 13px !important; }
.admin-sidebar nav .sidebar-overview { margin-bottom: 5px; }
.framework-preserved-note { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; padding: 13px 15px; border: 1px solid #cddbd3; border-radius: 7px; color: var(--brand); background: var(--brand-soft); }
.framework-preserved-note > .framework-note-copy { display: flex; flex: 1; flex-direction: column; gap: 3px; }
.framework-preserved-note b { font-size: 14px !important; }
.framework-preserved-note small { color: var(--muted); }

@media (max-width: 1050px) {
  .admin-shell { grid-template-columns: 210px 1fr; }
  .admin-sidebar nav .sidebar-group-items > button { padding-left: 13px; }
}

/* Final system pass: shared flat surfaces, deliberate borders, and consistent overlays. */
.mobile-screen :where(.product-list-page, .collection-page, .shop-product-grid) .product-card {
  border: 1px solid var(--line);
  border-radius: 10px !important;
  background: #fff;
}
.mobile-screen .list-grid.single-column .product-card {
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0 !important;
}
.mobile-screen :where(.coupon-card, .coupon-select-card, .group-choice, .random-group, .group-option, .campaign-quantity) {
  border-color: var(--line);
  box-shadow: none;
}
.mobile-screen :where(.coupon-card, .coupon-select-card, .random-group, .group-option) { border-radius: 10px !important; }
.mobile-screen :where(.preference-page > label, .settings-page > button, .profile-field-row) { border-color: var(--line); }
.mobile-screen :where(.form-page input, .form-page select, .form-page textarea, .review-reply-box textarea, .profile-date-field input, .profile-mobile-form input) {
  border-color: var(--line-strong);
  background: #fff;
}
.mobile-screen .single-bottom-action,
.mobile-screen :where(.cart-submit, .confirm-submit-bar, .mobile-action-bar, .chat-input) {
  border-top: 1px solid var(--line);
  background: rgba(255,255,255,.98);
  box-shadow: 0 -8px 24px rgba(18,38,29,.035);
}
.mobile-screen .mobile-bottom-nav { border-top-color: var(--line); box-shadow: 0 -4px 18px rgba(18,38,29,.03); }
.mobile-screen .sheet-mask { background: rgba(16,29,23,.34); backdrop-filter: blur(2px); }
.mobile-screen .mobile-sheet {
  border-radius: 20px 20px 0 0;
  box-shadow: 0 -18px 48px rgba(18,38,29,.16);
}
.mobile-screen .mobile-sheet :where(input, select, textarea) { background: #fff; }
.mobile-screen .image-preview-mask { backdrop-filter: blur(4px); }

.admin-page { background: #f7f8f7; }
.admin-filter-bar {
  border: 0;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}
.admin-table-frame {
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}
.admin-table th { background: #fafbfa; }
.admin-table td { border-bottom-color: #edf0ee; }
.table-toolbar { border-bottom-color: #edf0ee; }
.overview-metrics article,
.overview-tasks article,
.settings-form-card {
  border: 0;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}
.module-tabs { border-bottom-color: var(--line); background: #fff; }
.admin-dialog {
  border: 0;
  border-radius: 12px;
  box-shadow: 0 24px 70px rgba(18,36,27,.22);
}
.admin-drawer { border-left: 0; box-shadow: -18px 0 48px rgba(18,36,27,.14); }
.dialog-mask,
.drawer-mask { backdrop-filter: blur(2px); }
.row-menu { border-color: var(--line); box-shadow: 0 12px 32px rgba(18,36,27,.14); }
.filter-fields :where(input, select),
.dialog-field :where(input, select, textarea),
.edit-form-grid :where(input, select, textarea),
.settings-form-grid :where(input, select, textarea) { border-color: var(--line-strong); background: #fff; }
