* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: #d7d5d1; font-family: Arial, "PingFang SC", "Microsoft YaHei", sans-serif; color: #071326; }
button { font: inherit; border: 0; cursor: pointer; }
.mobile-shell { min-height: 100vh; display: flex; justify-content: center; background: #d7d5d1; }
.app-phone { width: min(100vw, 430px); min-height: 100vh; background: #f3f8f7; overflow: hidden; position: relative; }
.page { height: 100vh; overflow-y: auto; padding: 0 16px 150px; }
.page-head { text-align: center; padding: 8px 0 12px; background: #fff; margin: 0 -16px 10px; position: sticky; top: 0; z-index: 5; }
.page-head h1 { margin: 0; font-size: 18px; font-weight: 900; }
.page-head p { margin: 4px 0 0; color: #6d7884; font-size: 12px; }
.task-back { position: absolute; left: 12px; top: 13px; width: 30px; height: 30px; border-radius: 50%; background: #eefbf8; color: #008b80; font-size: 0; line-height: 1; display: grid; place-items: center; font-weight: 900; }
.task-back::before { content: "‹"; transform: translateY(-1px); font-size: 26px; line-height: 1; }

.store-card { min-height: 146px; display: grid; grid-template-columns: 42% 1fr; gap: 10px; align-items: center; padding: 10px 10px 10px 14px; border-radius: 12px; background: linear-gradient(135deg, #14b7a7 0%, #078b87 48%, #075f68 100%); box-shadow: inset 0 1px rgba(255,255,255,.38), 0 10px 24px rgba(6,78,79,.18); color: #fff; overflow: hidden; position: relative; }
.store-card::before { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, rgba(255,255,255,.16), transparent 35%, rgba(255,255,255,.08) 55%, transparent 70%); pointer-events: none; }
.store-copy { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; text-align: center; min-width: 0; }
.store-logo { width: 75px; height: 45px; object-fit: contain; margin-bottom: 6px; }
.store-copy h2 { margin: 0; font-size: 21px; line-height: 1.05; font-weight: 900; }
.store-copy p { margin: 2px 0 8px; font-size: 14px; line-height: 1.05; }
.store-copy small { display: inline-flex; align-items: center; border-radius: 18px; padding: 6px 11px; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.22); font-size: 12px; }
.heart { color: #fb3b30; }
.store-media { position: relative; z-index: 1; height: 124px; border-radius: 10px; overflow: hidden; background: rgba(255,255,255,.88); padding: 1px; }
.store-media img { width: 100%; height: 100%; object-fit: cover; border-radius: 9px; display: block; }
.zoom-btn { position: absolute; right: 6px; bottom: 6px; width: 22px; height: 22px; border-radius: 50%; background: rgba(6,137,132,.9); color: #fff; display: grid; place-items: center; font-size: 17px; line-height: 1; box-shadow: 0 4px 10px rgba(0,0,0,.25); }

.order-layout { margin-top: 14px; display: grid; grid-template-columns: 78px minmax(0, 1fr); gap: 10px; align-items: start; }
.category-tabs { position: sticky; top: 64px; z-index: 2; display: flex; flex-direction: column; background: #fff; border-radius: 8px; overflow: hidden; box-shadow: 0 10px 24px rgba(12,55,51,.05); }
.category-tabs button { min-height: 58px; padding: 8px 6px; background: #fff; color: #243444; font-size: 16px; line-height: 1.05; word-break: break-word; }
.category-tabs button.active { color: #008b80; font-weight: 900; background: #eefbf8; border-left: 4px solid #079886; }
.food-list { display: flex; flex-direction: column; gap: 10px; }
.food-card { min-height: 108px; padding: 10px 50px 10px 10px; border-radius: 10px; background: #fff; box-shadow: 0 8px 22px rgba(18,54,52,.06); display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 12px; position: relative; }
.product-art { width: 88px; height: 88px; border-radius: 8px; background: #f0f6f5; display: grid; place-items: center; overflow: hidden; }
.product-art img { width: 100%; height: 100%; object-fit: contain; display: block; }
.food-info { min-width: 0; padding-top: 2px; }
.food-info h3 { margin: 0 0 6px; font-size: 17px; font-weight: 900; line-height: 1.2; }
.food-info p { margin: 0 0 5px; color: #6f7a85; font-size: 14px; line-height: 1.25; }
.food-info strong { color: #ff3b22; font-size: 15px; font-weight: 900; }
.plus { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border-radius: 50%; padding: 0; background: radial-gradient(circle at 30% 20%, #4acfc4, #057a76 70%); box-shadow: 0 7px 16px rgba(0,120,112,.25); display: grid; place-items: center; overflow: visible; }
.plus img { width: 36px; height: 36px; object-fit: contain; }

.cart-bar { position: fixed; left: 50%; bottom: 74px; transform: translateX(-50%); width: min(calc(100vw - 28px), 402px); min-height: 64px; background: rgba(255,255,255,.94); border-radius: 18px; box-shadow: 0 -8px 26px rgba(15,64,60,.14); z-index: 22; display: grid; grid-template-columns: 56px 1fr 116px; gap: 10px; align-items: center; padding: 8px; }
.bag { width: 50px; height: 50px; border-radius: 11px; background: linear-gradient(135deg, #26bdb4, #006d72); position: relative; display: grid; place-items: center; }
.bag img { width: 41px; height: 41px; object-fit: contain; }
.bag span { position: absolute; right: -3px; top: -7px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 99px; background: #ff4638; color: #fff; font-size: 12px; font-weight: 900; border: 2px solid #fff; display: grid; place-items: center; }
.cart-summary { font-size: 15px; line-height: 1.35; }
.cart-summary strong { display: block; font-weight: 900; }
.submit-task, .primary-action { min-height: 46px; border-radius: 12px; background: linear-gradient(135deg, #21b8b0, #006d72); color: #fff; font-weight: 900; box-shadow: inset 0 1px rgba(255,255,255,.45); }

.bottom-tab { position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); width: min(100vw, 430px); height: 74px; background: rgba(255,255,255,.94); z-index: 21; display: grid; grid-template-columns: repeat(4, 1fr); box-shadow: 0 -8px 22px rgba(18,54,52,.08); }
.bottom-tab button { background: transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #7b8794; gap: 3px; font-size: 13px; }
.bottom-tab img { width: 34px; height: 34px; object-fit: contain; }
.bottom-tab .active { color: #008b80; font-weight: 900; }

.sheet-mask, .cart-mask, .rescue-mask { position: fixed; inset: 0; z-index: 60; background: rgba(0,0,0,.45); display: grid; align-items: end; justify-items: center; }
[hidden] { display: none !important; }
.store-sheet, .cart-sheet { width: min(100vw, 430px); max-height: 84vh; overflow-y: auto; background: #fff; border-radius: 20px 20px 0 0; padding: 18px 18px 28px; position: relative; box-shadow: 0 -16px 50px rgba(0,0,0,.18); }
.sheet-close { position: absolute; right: 12px; top: 12px; width: 32px; height: 32px; border-radius: 50%; background: #fff7ed; color: #bf7a18; font-size: 20px; }
.sheet-image { height: 190px; border-radius: 12px; overflow: hidden; background: #eef6f5; }
.sheet-image img { width: 100%; height: 100%; object-fit: contain; display: block; }
.store-sheet h2 { margin: 18px 0 10px; font-size: 24px; }
.store-sheet h2 span { font-size: 12px; color: #009b8f; background: #dff8f3; border-radius: 999px; padding: 4px 8px; vertical-align: middle; }
.store-sheet p { margin: 0 0 16px; }
.store-sheet small { display: block; margin-bottom: 14px; }
.notice-box { background: #eff7f6; border-radius: 8px; padding: 12px; color: #52616e; line-height: 1.6; margin-bottom: 18px; }

.cart-sheet h2 { margin: 0 0 4px; font-size: 22px; }
.cart-row { display: grid; grid-template-columns: 56px 1fr 80px; gap: 10px; align-items: center; border-top: 1px solid #edf1f1; padding: 10px 0; }
.cart-row img { width: 56px; height: 56px; object-fit: contain; border-radius: 8px; background: #f0f6f5; }
.qty { display: flex; align-items: center; justify-content: flex-end; gap: 8px; font-weight: 900; }
.qty button { width: 26px; height: 26px; border-radius: 50%; color: #fff; background: #008b80; font-weight: 900; }
.cart-sheet-total { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid #edf1f1; padding-top: 14px; font-size: 18px; font-weight: 900; }
.cart-sheet-total strong { color: #ff3b22; }

.rescue-mask { align-items: center; background: rgba(0,0,0,.35); }
.rescue-popup { width: min(88vw, 350px); min-height: 430px; position: relative; display: grid; justify-items: center; align-content: center; }
.rescue-close { position: absolute; right: 18px; top: 8px; width: 30px; height: 30px; border-radius: 50%; background: #fff; color: #c7823f; font-size: 20px; z-index: 4; }
.speech { position: absolute; top: 20px; width: 82%; min-height: 92px; padding: 20px 30px; border-radius: 50% 45% 50% 45%; background: #fff5dc; color: #5a2407; border: 3px solid #f1c35f; text-align: center; font-size: 23px; line-height: 1.05; font-weight: 900; z-index: 2; }
.rescue-animal { width: 96%; max-height: 330px; object-fit: contain; filter: drop-shadow(0 16px 22px rgba(0,0,0,.22)); margin-top: 80px; }
.help-button { position: absolute; bottom: 18px; width: 72%; height: 54px; border-radius: 999px; background: #101012; border: 3px solid #ffd86f; color: #ff9b30; font-size: 24px; font-weight: 900; text-shadow: 0 2px #fff; animation: breathe 1.8s ease-in-out infinite; }
@keyframes breathe { 0%,100% { transform: scale(1); } 50% { transform: scale(1.035); } }

.toast { position: fixed; left: 50%; bottom: 150px; transform: translateX(-50%); z-index: 90; background: rgba(8,26,31,.86); color: #fff; border-radius: 999px; padding: 10px 18px; font-size: 14px; }
.task-panel { margin-top: 14px; padding: 16px; border-radius: 14px; background: #fff; box-shadow: 0 10px 26px rgba(18,54,52,.08); }
.task-panel h2 { margin: 0 0 4px; color: #05233b; font-size: 22px; font-weight: 900; }
.task-panel p { margin: 0 0 14px; color: #657383; font-size: 14px; }
.task-list { display: flex; flex-direction: column; gap: 10px; }
.task-item { min-height: 86px; display: grid; grid-template-columns: 72px 1fr; gap: 12px; align-items: center; padding: 10px; border-radius: 12px; background: #f3f8f7; }
.task-item img { width: 72px; height: 72px; object-fit: contain; border-radius: 10px; background: #fff; }
.task-item h3 { margin: 0 0 5px; color: #071629; font-size: 17px; line-height: 1.1; font-weight: 900; }
.task-item p { margin: 0; color: #697585; font-size: 13px; }
.task-item strong { display: block; margin-top: 7px; color: #ff3b22; font-size: 15px; }
.task-empty { padding: 18px; border-radius: 12px; background: #f3f8f7; color: #667583; text-align: center; font-weight: 800; }
.task-footer-brand { position: fixed; left: 50%; bottom: 82px; transform: translateX(-50%); z-index: 18; width: min(calc(100vw - 40px), 380px); display: grid; justify-items: center; gap: 7px; opacity: .28; pointer-events: none; }
.task-footer-brand img { width: 118px; height: 50px; object-fit: contain; }
.task-footer-brand p { margin: 0; color: #0b6768; font-size: 14px; font-weight: 900; }
.task-floating-tip { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 42; width: min(calc(100vw - 28px), 402px); padding: 13px 16px; border-radius: 16px; background: linear-gradient(135deg, #25bcb4, #006d72); color: #fff; font-size: 15px; font-weight: 900; text-align: center; box-shadow: 0 10px 28px rgba(0,109,114,.26); animation: tip-breathe 1.7s ease-in-out infinite; }
@keyframes tip-breathe { 0%, 100% { transform: translateX(-50%) scale(1); box-shadow: 0 10px 28px rgba(0,109,114,.26); } 50% { transform: translateX(-50%) scale(1.035); box-shadow: 0 14px 34px rgba(0,109,114,.36); } }
@media (max-width: 380px) {
  .page { padding-left: 14px; padding-right: 14px; }
  .store-copy h2 { font-size: 18px; }
  .store-media { height: 112px; }
  .order-layout { grid-template-columns: 76px 1fr; }
  .food-card { grid-template-columns: 82px 1fr; padding-right: 44px; }
  .product-art { width: 82px; height: 82px; }
}
