/* 摘下阳光·会员牧场 — 设计系统（移动端优先，阳光甄选配色，与官网统一）
   主色：取自 LOGO 的太阳（橙黄渐变）+ 棕色描边 + 生态绿点缀 + 阳光红 */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
:root {
  --gold: #F7B500; --gold-deep: #E5891B; --gold-light: #FFF3D2; --sun-soft: #FFE8B0;
  --green: #4A8E3C; --green-deep: #3A7A2D; --green-light: #EAF4E4;
  --brown: #6B3410; --brown-deep: #4A2208;
  --ink: #2A2522; --ink-2: #6E665D; --ink-3: #9A9086;
  --bg: #FFFBF1; --card: #FFFFFF; --line: rgba(214, 157, 46, .25);
  --red: #D9482A; --blue: #3D6FE0;
  --radius: 14px; --shadow: 0 4px 14px rgba(213, 140, 30, .10);
}
html, body { background: #F3E7CD; font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; color: var(--ink); }
body { display: flex; justify-content: center; min-height: 100vh; }

/* 手机外壳 */
#phone { width: 100%; max-width: 430px; min-height: 100vh; background: var(--bg); position: relative; display: flex; flex-direction: column; box-shadow: 0 0 40px rgba(0,0,0,.15); }
@media (min-width: 500px) { #phone { min-height: 860px; height: 860px; margin: 24px 0; border-radius: 28px; overflow: hidden; } }

/* 顶栏（与官网头部一致） */
.topbar { padding: 12px 16px 10px; display: flex; align-items: center; gap: 12px; background: rgba(255, 251, 241, .94); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.topbar .logo { position: relative; display: inline-flex; align-items: center; justify-content: center; height: 50px; padding: 0 14px; background: radial-gradient(circle at 30% 30%, #FFF6D5 0%, #FFE49A 60%, #FFC857 100%); border-radius: 25px; box-shadow: 0 4px 12px rgba(107, 52, 16, .18), inset 0 1px 0 rgba(255, 255, 255, .75), inset 0 -2px 4px rgba(229, 137, 27, .18); }
.topbar .logo img { height: 40px; width: auto; display: block; border-radius: 8px; filter: drop-shadow(0 2px 4px rgba(107, 52, 16, .25)); }
.topbar .logo-text { font-size: 22px; font-weight: 900; letter-spacing: 3px; line-height: 1.1; color: var(--brown); }
.topbar .logo-text small { display: block; font-size: 9.5px; letter-spacing: 3px; color: #8B5A3C; font-weight: 600; }
.topbar .spacer { flex: 1; }
.topbar .icon-btn { width: 32px; height: 32px; border-radius: 50%; background: #fff; border: none; font-size: 15px; display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow); cursor: pointer; }

/* 主滚动区 */
#view { flex: 1; overflow-y: auto; padding: 0 14px 90px; scrollbar-width: none; }
#view::-webkit-scrollbar { display: none; }

/* 底部 Tab */
#tabbar { position: absolute; bottom: 0; left: 0; right: 0; background: #fff; border-top: 1px solid var(--line); display: flex; padding: 6px 4px calc(8px + env(safe-area-inset-bottom)); z-index: 40; }
.tab { flex: 1; border: none; background: none; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 10px; color: var(--ink-3); cursor: pointer; padding: 4px 0; }
.tab .ti { font-size: 21px; line-height: 1; }
.tab.active { color: var(--gold-deep); font-weight: 600; }

/* 通用组件 */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; margin-bottom: 12px; border: 1px solid rgba(247, 181, 0, .14); }
.section-title { display: flex; align-items: baseline; gap: 8px; margin: 14px 2px 10px; }
.section-title h3 { font-size: 15px; color: var(--brown); }
.section-title .more { margin-left: auto; font-size: 12px; color: var(--ink-3); cursor: pointer; }
.btn { border: none; border-radius: 22px; padding: 10px 18px; font-size: 14px; font-weight: 600; cursor: pointer; }
.btn-primary { background: linear-gradient(135deg, var(--gold), var(--gold-deep)); color: #fff; box-shadow: 0 4px 12px rgba(229, 137, 27, .35); }
.btn-green { background: linear-gradient(135deg, var(--green), #6BA85E); color: #fff; box-shadow: 0 4px 12px rgba(74, 142, 60, .30); }
.btn-ghost { background: #fff; border: 1px solid var(--gold); color: var(--gold-deep); }
.btn-block { display: block; width: 100%; padding: 13px; font-size: 15px; }
.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn:disabled { opacity: .5; }
.tag { display: inline-block; font-size: 10px; padding: 2px 8px; border-radius: 10px; background: var(--gold-light); color: var(--brown); margin-right: 6px; }
.tag.green { background: var(--green-light); color: var(--green-deep); }
.tag.red { background: #FDECE8; color: var(--red); }
.muted { color: var(--ink-3); font-size: 12px; }
.price { color: var(--red); font-weight: 700; }
.price.big { font-size: 20px; }
.price s { color: var(--ink-3); font-weight: 400; font-size: 12px; margin-left: 4px; }
.row { display: flex; align-items: center; gap: 10px; }
.grow { flex: 1; }
.empty { text-align: center; color: var(--ink-3); padding: 40px 0; font-size: 13px; }
.empty .ei { font-size: 40px; display: block; margin-bottom: 8px; }

/* 首页 hero（暖阳渐变） */
.hero { margin: 12px 0; border-radius: 18px; padding: 22px 18px; color: #fff; background: linear-gradient(120deg, #F7B500 0%, #E5891B 55%, #D9482A 100%); position: relative; overflow: hidden; box-shadow: 0 6px 18px rgba(229, 137, 27, .30); }
.hero::after { content: '🐔'; position: absolute; right: -6px; bottom: -14px; font-size: 84px; opacity: .18; transform: rotate(-12deg); }
.hero::before { content: ''; position: absolute; left: -30px; top: -40px; width: 140px; height: 140px; border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,.35), transparent 70%); }
.hero h1 { font-size: 21px; letter-spacing: 1px; }
.hero p { font-size: 12px; opacity: .92; margin-top: 6px; }
.hero .hero-acts { display: flex; gap: 8px; margin-top: 14px; position: relative; z-index: 1; }
.hero .hero-acts .btn { background: rgba(255,255,255,.94); color: var(--gold-deep); font-size: 12px; padding: 8px 14px; }

/* 会员卡条（首页顶部） */
.vip-strip { margin-top: 12px; border-radius: var(--radius); padding: 12px 14px; background: linear-gradient(120deg, var(--brown-deep), var(--brown)); color: #F9E7C0; display: flex; align-items: center; gap: 10px; box-shadow: var(--shadow); cursor: pointer; }
.vip-strip .vicon { font-size: 22px; }
.vip-strip .vname { font-weight: 700; font-size: 14px; }
.vip-strip .vsub { font-size: 10px; opacity: .75; }
.vip-strip .bar { height: 4px; background: rgba(255,255,255,.18); border-radius: 2px; margin-top: 5px; overflow: hidden; }
.vip-strip .bar i { display: block; height: 100%; background: linear-gradient(90deg, #FFD25A, #FFE8B0); border-radius: 2px; }
.guest-strip { margin-top: 12px; padding: 14px; border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); display: flex; align-items: center; gap: 12px; }

/* 快捷宫格 */
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 12px 0; }
.grid4 .gi { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px 4px; text-align: center; cursor: pointer; border: none; border: 1px solid rgba(247, 181, 0, .14); }
.grid4 .gi .gico { font-size: 22px; }
.grid4 .gi .glab { font-size: 11px; color: var(--ink-2); margin-top: 4px; }

/* 商品卡 */
.p-list { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.p-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; cursor: pointer; border: 1px solid rgba(247, 181, 0, .14); }
.p-card .p-img { height: 108px; display: flex; align-items: center; justify-content: center; font-size: 46px; background: linear-gradient(160deg, #FFF6D5, #FFE3A6); }
.p-card .p-body { padding: 10px; }
.p-card .p-name { font-size: 13px; font-weight: 600; line-height: 1.35; }
.p-card .p-spec { font-size: 10px; color: var(--ink-3); margin: 3px 0 6px; }
.p-card .p-foot { display: flex; align-items: center; }
.p-card .p-sales { font-size: 10px; color: var(--ink-3); margin-left: auto; }
.p-img-big { height: 150px; border-radius: var(--radius); display: flex; align-items: center; justify-content: center; font-size: 64px; background: linear-gradient(160deg, #FFF6D5, #FFE3A6); margin-bottom: 12px; }

/* 签到 */
.signin-card { background: linear-gradient(135deg, #FFF6D5, #FFDD9A); border: none; }
.sign-calendar { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin: 10px 0; }
.sign-calendar .d { aspect-ratio: 1; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--ink-2); background: #fff; }
.sign-calendar .d.on { background: var(--gold); color: #fff; font-weight: 700; }
.sign-calendar .d.today { border: 2px solid var(--gold-deep); }
.sign-calendar .d.void { visibility: hidden; }

/* 会员中心（暖棕金卡） */
.vip-card { border-radius: 18px; padding: 18px; color: #F9EBC8; background: linear-gradient(125deg, var(--brown-deep), #7A4A1E 55%, #B87A1E); box-shadow: 0 8px 20px rgba(74, 34, 8, .30); }
.vip-card .vc-top { display: flex; align-items: center; gap: 12px; }
.vip-card .avatar { width: 52px; height: 52px; border-radius: 50%; background: radial-gradient(circle at 30% 30%, #FFE49A, #E5891B); display: flex; align-items: center; justify-content: center; font-size: 24px; }
.vip-card .vc-name { font-size: 16px; font-weight: 700; }
.vip-card .vc-lv { font-size: 11px; opacity: .85; margin-top: 2px; }
.vip-card .vc-stats { display: flex; margin-top: 16px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.15); }
.vip-card .vs { flex: 1; text-align: center; }
.vip-card .vs b { font-size: 16px; display: block; }
.vip-card .vs span { font-size: 10px; opacity: .75; }
.vip-card .vc-bar { height: 6px; background: rgba(255,255,255,.18); border-radius: 3px; margin-top: 14px; overflow: hidden; }
.vip-card .vc-bar i { display: block; height: 100%; background: linear-gradient(90deg, #FFD25A, #FFE8B0); }
.menu-list { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.menu-item { display: flex; align-items: center; gap: 12px; padding: 14px; border-bottom: 1px solid var(--line); cursor: pointer; background: none; width: 100%; text-align: left; border-left: none; border-right: none; border-top: none; font-size: 14px; color: var(--ink); }
.menu-item:last-child { border-bottom: none; }
.menu-item .mi { font-size: 18px; }
.menu-item .arrow { margin-left: auto; color: var(--ink-3); }

/* 套餐卡 */
.plan-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; margin-bottom: 10px; position: relative; border: 1px solid rgba(247, 181, 0, .14); }
.plan-card.hot { border: 1.5px solid var(--gold); }
.plan-card .hot-badge { position: absolute; top: -8px; right: 12px; background: var(--red); color: #fff; font-size: 10px; padding: 2px 10px; border-radius: 10px; }
.plan-card .pc-name { font-weight: 700; font-size: 15px; }
.plan-card .pc-desc { font-size: 12px; color: var(--ink-2); margin: 6px 0; line-height: 1.5; }
.plan-card .pc-foot { display: flex; align-items: center; margin-top: 8px; }
.plan-card .pc-save { font-size: 11px; color: var(--green-deep); background: var(--green-light); padding: 2px 8px; border-radius: 8px; }
.perk-list { margin: 8px 0 0; padding: 0; list-style: none; }
.perk-list li { font-size: 12px; color: var(--ink-2); padding: 3px 0 3px 18px; position: relative; }
.perk-list li::before { content: '✓'; position: absolute; left: 0; color: var(--green); font-weight: 700; }

/* 鸡场卡 */
.field-card { border-radius: var(--radius); overflow: hidden; background: #fff; box-shadow: var(--shadow); margin-bottom: 12px; }
.field-card .fc-banner { height: 110px; background: linear-gradient(140deg, #6BA85E, #4A8E3C 70%); position: relative; display: flex; align-items: flex-end; padding: 12px; color: #fff; }
.field-card .fc-banner .grain { position: absolute; right: 10px; top: -6px; font-size: 64px; opacity: .25; }
.field-card .fc-no { font-size: 11px; opacity: .85; }
.field-card .fc-name { font-size: 17px; font-weight: 700; }
.field-card .fc-body { padding: 12px 14px; }
.diary { border-left: 3px solid var(--sun-soft); padding-left: 12px; margin: 8px 0; }
.diary .d-item { position: relative; padding: 0 0 12px; }
.diary .d-item::before { content: ''; position: absolute; left: -19px; top: 4px; width: 9px; height: 9px; border-radius: 50%; background: var(--gold); border: 2px solid #fff; }
.diary .d-date { font-size: 10px; color: var(--ink-3); }
.diary .d-stage { font-size: 13px; font-weight: 700; margin: 2px 0; }
.diary .d-note { font-size: 12px; color: var(--ink-2); line-height: 1.5; }

/* 明细行 */
.trace-item { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.trace-item:last-child { border-bottom: none; }
.trace-item .tk { color: var(--ink-3); width: 64px; flex-shrink: 0; }
.trace-code { font-family: monospace; background: var(--gold-light); padding: 4px 10px; border-radius: 8px; font-size: 13px; letter-spacing: 1px; }

/* 弹层 */
.mask { position: absolute; inset: 0; background: rgba(42, 33, 18, .45); z-index: 60; display: flex; align-items: flex-end; }
.sheet { background: #fff; border-radius: 18px 18px 0 0; width: 100%; max-height: 78%; overflow-y: auto; padding: 16px 16px calc(20px + env(safe-area-inset-bottom)); }
.sheet .sh-title { text-align: center; font-weight: 700; margin-bottom: 12px; position: relative; }
.sheet .sh-close { position: absolute; right: 0; top: -2px; border: none; background: #FFF3D2; width: 26px; height: 26px; border-radius: 50%; cursor: pointer; }
.modal { position: absolute; inset: 0; background: rgba(42, 33, 18, .45); z-index: 70; display: flex; align-items: center; justify-content: center; padding: 30px; }
.modal .mo-box { background: #fff; border-radius: 16px; padding: 22px 18px; width: 100%; max-width: 320px; text-align: center; }
.modal .mo-box h4 { margin-bottom: 8px; }
.modal .mo-box p { font-size: 13px; color: var(--ink-2); line-height: 1.6; }
.modal .mo-acts { display: flex; gap: 10px; margin-top: 16px; }
.modal .mo-acts .btn { flex: 1; }

/* 表单 */
.field { margin-bottom: 12px; }
.field label { display: block; font-size: 12px; color: var(--ink-2); margin-bottom: 5px; }
.field input, .field select { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; font-size: 14px; background: #FFFCF4; outline: none; }
.field input:focus { border-color: var(--gold); }

/* Toast */
#toast { position: absolute; left: 50%; bottom: 120px; transform: translateX(-50%); background: rgba(74, 34, 8, .88); color: #fff; padding: 10px 20px; border-radius: 20px; font-size: 13px; z-index: 99; opacity: 0; transition: opacity .25s; pointer-events: none; max-width: 82%; text-align: center; }
#toast.show { opacity: 1; }

/* 子页头 */
.subhead { display: flex; align-items: center; gap: 8px; padding: 14px 2px 8px; }
.subhead .back { border: none; background: #fff; width: 30px; height: 30px; border-radius: 50%; box-shadow: var(--shadow); cursor: pointer; font-size: 14px; }
.subhead h2 { font-size: 16px; }

/* 订单 */
.order-card .oc-head { display: flex; font-size: 11px; color: var(--ink-3); margin-bottom: 8px; }
.order-card .oc-status { margin-left: auto; color: var(--gold-deep); font-weight: 700; }
.order-line { display: flex; font-size: 13px; padding: 4px 0; }
.order-line .ol-qty { color: var(--ink-3); margin-left: auto; flex-shrink: 0; padding-left: 10px; }
.order-total { text-align: right; font-size: 13px; margin-top: 6px; }

/* 大字号适老模式 */
html.font-big { font-size: 18px; }
html.font-big .tab .ti { font-size: 24px; }
html.font-big .p-card .p-name { font-size: 15px; }

/* 引导页（暖阳徽章 + LOGO） */
.onboard { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 30px; text-align: center; }
.onboard .ob-logo { position: relative; display: inline-flex; align-items: center; justify-content: center; height: 110px; padding: 0 28px; background: radial-gradient(circle at 35% 35%, #FFF6D5 0%, #FFD982 55%, #F7B500 100%); border-radius: 55px; box-shadow: 0 6px 22px rgba(107, 52, 16, .25), inset 0 2px 0 rgba(255, 255, 255, .7), inset 0 -3px 6px rgba(229, 137, 27, .28); margin-bottom: 20px; }
.onboard .ob-logo img { height: 92px; width: auto; display: block; border-radius: 14px; filter: drop-shadow(0 4px 6px rgba(107, 52, 16, .35)); }
.onboard h1 { font-size: 24px; letter-spacing: 2px; color: var(--brown); }
.onboard p { color: var(--ink-2); font-size: 13px; margin: 10px 0 30px; line-height: 1.7; }
.onboard .btn { width: 100%; margin-bottom: 12px; }

/* ===== 页底品牌页脚（与官网页脚一模一样） ===== */
.app-footer { margin: 26px -14px 0; padding: 44px 16px 30px; text-align: center; background: radial-gradient(circle at 15% 0%, rgba(247, 181, 0, .15) 0%, transparent 60%), linear-gradient(180deg, #4A2208 0%, #2A1404 100%); }
.footer-brand { font-size: 20px; font-weight: 800; color: #FFE9B0; letter-spacing: 3px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.footer-logo { position: relative; display: inline-flex; align-items: center; justify-content: center; height: 110px; padding: 0 28px; background: radial-gradient(circle at 35% 35%, #FFF6D5 0%, #FFD982 55%, #F7B500 100%); border-radius: 55px; box-shadow: 0 6px 22px rgba(107, 52, 16, .25), inset 0 2px 0 rgba(255, 255, 255, .7), inset 0 -3px 6px rgba(229, 137, 27, .28); }
.footer-logo img { height: 92px; width: auto; border-radius: 14px; filter: drop-shadow(0 4px 6px rgba(107, 52, 16, .35)); }
.footer-brand p { font-size: 13px; font-weight: 400; margin-top: 4px; letter-spacing: 3px; color: #c9b78a; }
.footer-copy { font-size: 12.5px; color: #8a7d60; letter-spacing: 1px; margin-top: 20px; }

/* ===== 正式版新增：结算/订单/储值/等级 ===== */
.co-title { font-weight: 700; font-size: 15px; margin-bottom: 10px; color: var(--brown); }
.co-item { display: flex; align-items: center; gap: 10px; padding: 7px 0; font-size: 14px; }
.co-item span:first-child { flex: 1; }
.co-item b { font-size: 13px; }
.co-total { display: flex; justify-content: flex-end; align-items: center; gap: 8px; padding-top: 12px; margin-top: 6px; border-top: 1px solid var(--line); font-size: 13px; }
.mode-item { display: flex; gap: 12px; padding: 13px 12px; border: 1.5px solid #f0e6d2; border-radius: 12px; margin-bottom: 10px; align-items: flex-start; }
.mode-item.on { border-color: var(--gold); background: #FFFBF1; }
.mode-radio { width: 17px; height: 17px; border-radius: 50%; border: 2px solid #d8c9a8; margin-top: 3px; flex-shrink: 0; }
.mode-item.on .mode-radio { border-color: var(--deep); background: radial-gradient(circle, var(--gold) 45%, transparent 55%); }
.mode-label { font-weight: 700; font-size: 14px; margin-bottom: 2px; }
.mode-item.on .mode-label { color: #B8760A; }
.zone-row { display: flex; flex-wrap: wrap; gap: 8px; }
.zone { border: 1.5px solid #f0e6d2; border-radius: 10px; padding: 8px 14px; font-size: 12px; text-align: center; background: #fff; }
.zone.on { border-color: var(--gold); background: #FFF1CE; color: #B8760A; font-weight: 700; }
.zone-fee { font-size: 10px; color: var(--ink-3); margin-top: 2px; }
.qty-row { display: flex; justify-content: space-between; align-items: center; font-size: 14px; }
.stepper { display: flex; align-items: center; gap: 4px; }
.st-btn { width: 32px; height: 32px; border-radius: 50%; background: #FFF1CE; color: #B8760A; border: none; font-size: 17px; display: flex; align-items: center; justify-content: center; }
.o-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.o-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--line); }
.s-created { color: #D9482A; } .s-paid { color: #B8760A; } .s-delivering { color: #2c6fd1; }
.s-done { color: #4A8E3C; } .s-canceled { color: #b7a88d; }
.rc-grid { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.rc-card { width: calc(50% - 5px); background: #fff; border-radius: 14px; padding: 20px 0; text-align: center; box-shadow: 0 3px 10px rgba(107,52,16,.07); }
.rc-amount { font-size: 22px; font-weight: 800; color: var(--brown); }
.rc-bonus { font-size: 12px; color: #D9482A; margin-top: 4px; font-weight: 600; }
.lv-track { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 4px; margin-top: 10px; }
.lv-node { display: flex; flex-direction: column; align-items: center; font-size: 11px; color: #b7a88d; gap: 1px; }
.lv-node.on { color: #B8760A; font-weight: 700; }
.lv-node span:first-child { font-size: 19px; }
.lv-node b { font-size: 12px; }
.lv-sub { font-size: 9px; color: var(--ink-3); }
.lv-arrow { color: #d8c9a8; font-size: 12px; }
