/* shangpinhui 商城扩展样式（在模板 style.css 基础上追加） */

/* 商品卡：按需求图样式 —— 名称 / 价格+佣金 / 赚多少+品牌方姓名 */
.sph-price-row { display: flex; align-items: center; gap: 6px; margin-top: 4px; flex-wrap: wrap; }
.sph-price { color: #07c160; font-weight: 700; font-size: .95rem; }
.sph-comm { color: #a06ee8; font-size: .78rem; font-weight: 600; }
.sph-earn-row { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.sph-earn { color: #f43f3b; border: 1px solid #f43f3b; border-radius: 4px; padding: 0 5px; font-size: .75rem; font-weight: 700; line-height: 1.5; }
.sph-person { color: #999; font-size: .78rem; text-decoration: none; }
.sph-person:hover { color: #07c160; }

/* 排序条 */
.sph-sortbar { display: flex; gap: 4px; background: #fff; padding: 8px 10px; border-radius: 10px; margin: 10px 12px 0; box-shadow: 0 1px 4px rgba(0,0,0,.05); }
.sph-sortbar a { flex: 1; text-align: center; font-size: .82rem; color: #666; padding: 6px 0; border-radius: 8px; text-decoration: none; }
.sph-sortbar a.on { color: #07c160; font-weight: 700; background: #eefbf3; }

/* 分类筛选 chips */
.sph-cats { display: flex; gap: 8px; overflow-x: auto; padding: 10px 12px; -webkit-overflow-scrolling: touch; }
.sph-cats a { flex-shrink: 0; padding: 5px 12px; border-radius: 999px; background: #fff; border: 1px solid #e5e5e5; font-size: .8rem; color: #555; text-decoration: none; }
.sph-cats a.on { background: #07c160; border-color: #07c160; color: #fff; }

/* 分类页：布局切换按钮 */
.sph-view-toggle { display: inline-flex; align-items: center; gap: 4px; float: right; font-size: .78rem; color: #666; background: #fff; border: 1px solid #e5e5e5; border-radius: 8px; padding: 5px 10px; text-decoration: none; }

/* 横向排列（列表模式） */
.sph-rows { padding: 0 12px 12px; }
.sph-row { display: flex; gap: 12px; background: #fff; border-radius: 12px; padding: 12px; margin-top: 10px; text-decoration: none; color: #333; }
/* 横向排列：商品图继续加大（132 → 152px），内容区上下分布，与加高后的图片协调 */
.sph-row-img { width: 152px; height: 152px; border-radius: 10px; object-fit: cover; flex-shrink: 0; background: #f4f4f4; }
.sph-row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: space-between; padding: 6px 0; }
.sph-row-title { font-size: .88rem; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* 商城模式（竖排两列网格） */
.sph-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 12px 12px; }
.sph-grid-card { background: #fff; border-radius: 12px; overflow: hidden; text-decoration: none; color: #333; display: block; }
.sph-grid-card img { width: 100%; aspect-ratio: 1/1; object-fit: cover; display: block; background: #f4f4f4; }
.sph-grid-body { padding: 8px 10px 10px; }
.sph-grid-title { font-size: .82rem; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.3em; }

/* 空状态 */
.sph-empty { text-align: center; color: #999; font-size: .85rem; padding: 46px 20px; }

/* 品牌方页头部 */
.sph-brand-head { background: #fff; margin: 10px 12px 0; border-radius: 12px; padding: 16px; display: flex; gap: 12px; align-items: center; }
.sph-brand-ava { width: 54px; height: 54px; border-radius: 50%; object-fit: cover; background: #eefbf3; color: #07c160; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; font-weight: 700; flex-shrink: 0; }
.sph-brand-name { font-size: 1rem; font-weight: 700; }
.sph-brand-sub { font-size: .76rem; color: #999; margin-top: 3px; }

/* 商品详情页 */
.sph-pd-img { width: 100%; aspect-ratio: 1/1; object-fit: cover; display: block; background: #f4f4f4; }
.sph-pd-body { background: #fff; border-radius: 14px; margin: 10px 12px; padding: 16px; }
.sph-pd-title { font-size: 1.02rem; font-weight: 700; line-height: 1.5; }
.sph-pd-kv { display: flex; font-size: .85rem; padding: 7px 0; border-bottom: 1px dashed #f0f0f0; }
.sph-pd-kv b { color: #999; font-weight: 400; width: 76px; flex-shrink: 0; }
.sph-pd-kv span { color: #333; word-break: break-all; }

/* 联系信息卡（权限门） */
.sph-contact { background: #fff; border-radius: 14px; margin: 10px 12px; padding: 16px; }
.sph-contact h3 { font-size: .95rem; margin: 0 0 10px; }
.sph-contact-line { font-size: .85rem; padding: 5px 0; color: #333; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.sph-contact-line b { color: #999; font-weight: 400; }
.sph-copy { color: #07c160; font-size: .76rem; border: 1px solid #07c160; border-radius: 6px; padding: 1px 8px; cursor: pointer; background: none; }
.sph-lock { text-align: center; padding: 8px 0 2px; }
.sph-lock-btn { display: inline-block; background: #07c160; color: #fff; border: none; border-radius: 10px; padding: 10px 26px; font-size: .9rem; cursor: pointer; }
.sph-lock-tip { font-size: .76rem; color: #999; margin-top: 8px; }

/* 星星弹窗 */
.sph-modal-mask { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 999; display: flex; align-items: center; justify-content: center; padding: 24px; }
.sph-modal { background: #fff; border-radius: 16px; padding: 22px 20px; max-width: 340px; width: 100%; text-align: center; }
.sph-modal h4 { font-size: 1rem; margin: 0 0 10px; }
.sph-modal p { font-size: .86rem; color: #555; line-height: 1.7; margin: 0 0 16px; }
.sph-modal .star-num { color: #f59e0c; font-weight: 700; }
.sph-modal-btns { display: flex; gap: 10px; }
.sph-modal-btns button { flex: 1; border-radius: 10px; padding: 10px 0; font-size: .9rem; cursor: pointer; border: none; }
.sph-btn-no { background: #f2f2f2; color: #666; }
.sph-btn-yes { background: #07c160; color: #fff; }
.sph-btn-yes:disabled { background: #ccc; }

/* 搜索结果提示 */
.sph-q-tip { padding: 10px 14px 0; font-size: .8rem; color: #999; }

@media (min-width: 720px) {
    .sph-grid { grid-template-columns: repeat(4, 1fr); }
    .sph-rows, .sph-grid { max-width: 960px; margin: 0 auto; }
}

/* ========== 第28轮：搜索修复 / 消息角标 / 推荐条 / 会员中心 ========== */

/* 搜索框：模板原样式是白字（看不见输入），修复为深字 + 搜索按钮 */
.sph-search { background: #fff !important; border: 1px solid #ddd !important; }
.sph-search input { color: #333 !important; background: none !important; }
.sph-search input::placeholder { color: #aaa; }
.sph-search-btn { flex-shrink: 0; border: none; background: #07c160; color: #fff; font-size: .9rem; width: 44px; height: 32px; border-radius: 0 100px 100px 0; cursor: pointer; }
.sph-search input { width: calc(100% - 44px) !important; }

/* 消息未读角标 */
.sph-bell { position: relative; }
.sph-notice-badge { position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px; line-height: 16px; background: #f43f3b; color: #fff; font-size: .62rem; border-radius: 999px; text-align: center; padding: 0 4px; }

/* 推荐条：横向滑动 */
.sph-recs { display: flex; gap: 10px; overflow-x: auto; padding: 4px 12px 10px; -webkit-overflow-scrolling: touch; }
.sph-recs::-webkit-scrollbar { display: none; }
.sph-rec { flex-shrink: 0; width: 42%; border-radius: 10px; overflow: hidden; display: block; }
.sph-rec img { width: 100%; aspect-ratio: 1/1; object-fit: cover; display: block; background: #f4f4f4; }

/* 登录 / 注册 */
.sph-auth { background: #fff; margin: 12px; border-radius: 14px; padding: 18px 16px; }
.sph-auth-tabs { display: flex; gap: 10px; margin-bottom: 16px; }
.sph-auth-tabs button { flex: 1; border: none; background: #f2f2f2; color: #666; border-radius: 10px; padding: 10px 0; font-size: .95rem; cursor: pointer; }
.sph-auth-tabs button.on { background: #07c160; color: #fff; font-weight: 700; }
.sph-auth-form label { display: block; font-size: .82rem; color: #666; margin: 12px 0 6px; }
.sph-auth-form input[type=tel], .sph-auth-form input[type=password], .sph-auth-form input[type=text] {
    width: 100%; border: 1px solid #e0e0e0; border-radius: 10px; padding: 10px 12px; font-size: .9rem; color: #333; background: #f9f9f9;
}
.sph-auth-form input[type=file] { font-size: .82rem; color: #666; }
.sph-auth-btn { width: 100%; margin-top: 18px; border: none; background: #07c160; color: #fff; border-radius: 10px; padding: 12px 0; font-size: 1rem; font-weight: 700; cursor: pointer; }
.sph-plats { display: flex; flex-direction: column; gap: 8px; }
.sph-plat { border: 1px solid #eee; border-radius: 10px; padding: 8px 10px; }
.sph-plat-check { display: flex; align-items: center; gap: 6px; font-size: .88rem; color: #333; margin: 0 !important; cursor: pointer; }
.sph-plat-check input { width: 16px; height: 16px; }
.sph-plat-fields { display: none; gap: 8px; margin-top: 8px; }
.sph-plat.on .sph-plat-fields { display: flex; }
.sph-plat-fields input { flex: 1; min-width: 0; }

/* 我的账号 */
.sph-me { background: #fff; margin: 12px 12px 0; border-radius: 14px; padding: 16px; display: flex; gap: 12px; align-items: center; }
.sph-me-ava { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.sph-me-ava-ph { background: #eefbf3; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; }
.sph-me-main { flex: 1; min-width: 0; }
.sph-me-phone { font-size: 1.05rem; font-weight: 700; }
.sph-me-sub { font-size: .74rem; color: #999; margin-top: 3px; }
.sph-me-out { font-size: .78rem; color: #999; border: 1px solid #e0e0e0; border-radius: 999px; padding: 5px 14px; text-decoration: none; }

/* 面板 / 键值 */
.sph-panel { background: #fff; margin: 12px 12px 0; border-radius: 14px; padding: 14px 16px; }
.sph-panel h3 { font-size: .95rem; margin: 0 0 8px; }
.sph-kv { display: flex; font-size: .85rem; padding: 6px 0; border-bottom: 1px dashed #f0f0f0; }
.sph-kv:last-child { border-bottom: none; }
.sph-kv b { color: #999; font-weight: 400; width: 76px; flex-shrink: 0; }
.sph-kv span { color: #333; }

/* 钱包 */
.sph-wallet { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; }
.sph-wallet-num { font-size: 1.6rem; font-weight: 800; color: #f59e0c; }
.sph-wallet-num small { font-size: .8rem; color: #999; font-weight: 400; }
.sph-recharge { border: none; background: linear-gradient(135deg, #ffb340, #f59e0c); color: #fff; border-radius: 999px; padding: 10px 30px; font-size: .95rem; font-weight: 700; cursor: pointer; }
.sph-wallet-tip { font-size: .74rem; color: #999; border-top: 1px dashed #f0f0f0; padding-top: 8px; }

/* 订单 */
.sph-order { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px dashed #f0f0f0; align-items: center; }
.sph-order:last-child { border-bottom: none; }
.sph-order-main { flex: 1; min-width: 0; }
.sph-order-brand { font-size: .88rem; font-weight: 700; }
.sph-order-brand small { color: #999; font-weight: 400; }
.sph-order-prod { font-size: .76rem; color: #999; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sph-order-time { font-size: .72rem; color: #bbb; flex-shrink: 0; }

/* 消息通知 */
.sph-notice { background: #fff; border-radius: 12px; padding: 14px 16px; margin-bottom: 10px; }
.sph-notice-title { font-size: .92rem; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.sph-notice .sph-dot { width: 8px; height: 8px; border-radius: 50%; background: #f43f3b; flex-shrink: 0; }
.sph-notice-body { font-size: .84rem; color: #555; line-height: 1.7; margin-top: 8px; }
.sph-notice-time { font-size: .72rem; color: #bbb; margin-top: 8px; }

/* 闪存提示 */
.sph-flash { margin: 12px 12px 0; border-radius: 10px; padding: 10px 14px; font-size: .85rem; }
.sph-flash-ok { background: #eefbf3; color: #07c160; border: 1px solid #b9e8cd; }
.sph-flash-error { background: #fdf0ef; color: #f43f3b; border: 1px solid #f6c6c4; }

/* ============ 第29轮：卡片布局 / 详情页完整字段 / 分享 / 分页加载 ============ */

/* 商城模式卡片底部：赚多少 + 品牌方姓名 同一行，姓名靠右 */
.sph-grid-foot { padding: 0 10px 10px; margin-top: 0; justify-content: space-between; }
.sph-grid-foot .sph-person { margin-left: auto; max-width: 58%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: right; }
/* 横向排列卡片：姓名同样靠右 */
.sph-row .sph-earn-row .sph-person { margin-left: auto; max-width: 55%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 价格单位跟随（¥10/个：单位小一号） */
.sph-price .sph-unit { font-size: .72em; font-weight: 500; }

/* 加载更多 */
.sph-loadmore { text-align: center; padding: 16px 0 20px; color: #999; font-size: .82rem; }

/* 悬浮分享按钮 */
.sph-share-fab {
    position: fixed; right: 14px; bottom: 86px; z-index: 900;
    width: 52px; height: 52px; border-radius: 50%; border: none; cursor: pointer;
    background: linear-gradient(135deg, #07c160, #05a650); color: #fff;
    box-shadow: 0 6px 18px rgba(7, 193, 96, .45);
    font-size: 19px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0;
}
.sph-share-fab span { font-size: 10px; line-height: 1.2; transform: scale(.92); }

/* 分享弹窗 */
.sph-share-box { position: relative; text-align: center; }
.sph-share-x { position: absolute; top: 8px; right: 10px; border: none; background: none; font-size: 16px; color: #999; cursor: pointer; }
.sph-share-pc { display: flex; gap: 14px; align-items: center; text-align: left; margin: 10px 0; }
.sph-share-qr { width: 150px; height: 150px; flex-shrink: 0; background: #fff; border: 1px solid #eee; border-radius: 8px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.sph-share-pc-side { flex: 1; font-size: .8rem; color: #555; line-height: 1.7; }
.sph-share-pc-side b { color: #07c160; }
.sph-share-demo { width: 100%; border-radius: 10px; border: 1px solid #f0f0f0; margin: 6px 0 10px; }
.sph-share-link input { width: 100%; box-sizing: border-box; border: 1px solid #e5e5e5; border-radius: 8px; padding: 9px 10px; font-size: .8rem; color: #555; background: #fafafa; }

/* 微信转发引导层 */
.sph-wx-guide { position: fixed; inset: 0; z-index: 1400; background: rgba(0,0,0,.82); }
.sph-wx-guide-arrow { position: absolute; top: 8px; right: 26px; }
.sph-wx-guide-txt { position: absolute; top: 118px; right: 30px; color: #fff; font-size: 16px; line-height: 1.9; text-align: center; }
.sph-wx-guide-txt span { font-size: 12px; color: #cfcfcf; }
.sph-wx-guide-ok { position: absolute; left: 50%; bottom: 18%; transform: translateX(-50%); background: #07c160; color: #fff; border-radius: 999px; padding: 10px 42px; font-size: 15px; }

/* 商品详情页（对齐品牌方详情页完整字段） */
.sph-pd-gallery { background: #fff; }
.sph-pd-gallery .m-slider { border-radius: 0; }
.sph-pd-card { background: #fff; border-radius: 12px; margin: 10px 12px; padding: 14px; }
.sph-pd-h1 { font-size: 1.05rem; font-weight: 800; color: #222; line-height: 1.5; }
.sph-pd-h1 em { font-style: normal; font-size: .72rem; color: #999; background: #f4f4f4; border-radius: 4px; padding: 2px 7px; margin-left: 6px; font-weight: 400; }
.sph-pd-oneline { font-size: .82rem; color: #888; margin-top: 6px; line-height: 1.6; }
.sph-pd-chips { margin-top: 8px; }
.sph-pd-chips em { font-style: normal; display: inline-block; font-size: .72rem; color: #f43f3b; border: 1px solid #f6c6c4; background: #fff7f6; border-radius: 4px; padding: 2px 8px; margin: 0 6px 6px 0; }
.sph-pd-cols { display: flex; gap: 10px; margin-top: 10px; border-top: 1px dashed #f0f0f0; padding-top: 12px; }
.sph-pd-col { flex: 1; min-width: 0; }
.sph-pd-kv2 { font-size: .84rem; color: #999; line-height: 2; }
.sph-pd-kv2 i { font-style: normal; color: #f43f3b; font-weight: 700; }
.sph-pd-kv2 em { font-style: normal; color: #333; }
.sph-pd-mech { font-size: .84rem; color: #999; margin-top: 8px; border-top: 1px dashed #f0f0f0; padding-top: 10px; }
.sph-pd-mech b { color: #f43f3b; font-weight: 500; }
.sph-pd-express { margin-top: 10px; }
.sph-pd-express em { font-style: normal; display: inline-block; font-size: .72rem; color: #07c160; border: 1px solid #b9e8cd; background: #f2fbf6; border-radius: 4px; padding: 2px 8px; margin: 0 6px 6px 0; }
.sph-pd-sample { font-size: .82rem; color: #07c160; font-weight: 600; }
.sph-pd-sec-t { font-size: .95rem; font-weight: 800; color: #222; margin-bottom: 10px; }
.sph-pd-sec-t:before { content: ''; display: inline-block; width: 4px; height: 14px; border-radius: 2px; background: #07c160; margin-right: 7px; vertical-align: -2px; }
.sph-pd-txt { font-size: .85rem; color: #555; line-height: 1.9; white-space: pre-wrap; word-break: break-word; }
.sph-pd-link { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px dashed #f0f0f0; }
.sph-pd-link:last-child { border-bottom: none; }
.sph-pd-link .u { flex: 1; min-width: 0; font-size: .78rem; color: #666; word-break: break-all; line-height: 1.6; }
.sph-pd-link button { flex-shrink: 0; border: none; background: #f2fbf6; color: #07c160; border-radius: 6px; padding: 5px 12px; font-size: .76rem; cursor: pointer; }
.sph-pd-owner { display: flex; gap: 12px; align-items: center; }
.sph-pd-owner-ava { width: 54px; height: 54px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: #eef7f1; color: #07c160; font-size: 22px; font-weight: 800; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.sph-pd-owner-main { flex: 1; min-width: 0; }
.sph-pd-owner-name { font-size: .92rem; font-weight: 700; color: #222; }
.sph-pd-owner-name small { color: #999; font-weight: 400; font-size: .76rem; }
.sph-pd-owner-wx { font-size: .8rem; color: #777; margin-top: 5px; line-height: 1.8; }
.sph-pd-owner-wx .lab { color: #aaa; }
.sph-pd-owner-wx .cp { color: #07c160; cursor: pointer; }
.sph-pd-tel { flex-shrink: 0; width: 40px; height: 40px; border-radius: 50%; background: #07c160; color: #fff; display: flex; align-items: center; justify-content: center; text-decoration: none; font-size: 18px; }
.sph-pd-more-link { text-align: center; padding: 2px 0 6px; }

/* ============ 第30轮：头部分享图标 / 底部「我的」未读红点 / 品牌信息卡 / 收藏夹 ============ */
/* 顶部右侧分享转发图标（简单线性 SVG 图标） */
.sph-share-ico { display: flex; align-items: center; justify-content: center; color: #333; }
.sph-share-ico .icon { font-style: normal; font-size: 19px; display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.sph-share-ico svg { display: block; }
/* 底部「我的」入口未读消息红点 */
.aui-tabBar-item-icon { position: relative; }
.sph-tab-badge { position: absolute; top: -4px; right: -14px; min-width: 16px; height: 16px; line-height: 16px; background: #f43f3b; color: #fff; font-size: .62rem; border-radius: 999px; text-align: center; padding: 0 4px; z-index: 2; }
/* 品牌合集页：品牌方详细信息卡（跟随后台三档开关） */
.sph-brand-info { background: #fff; margin: 10px 12px 0; border-radius: 12px; padding: 12px 16px 8px; }
.sph-bi-title { font-size: .9rem; font-weight: 800; color: #222; margin-bottom: 6px; }
.sph-brand-info .sph-contact-line { padding: 7px 0; border-bottom: 1px dashed #f0f0f0; }
.sph-brand-info .sph-contact-line:last-child { border-bottom: none; }
/* 我的收藏夹 */
.sph-fav { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px dashed #f0f0f0; align-items: center; }
.sph-fav:last-child { border-bottom: none; }
.sph-fav-img { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; flex-shrink: 0; background: #f4f4f4; display: block; }
.sph-fav-main { flex: 1; min-width: 0; }
.sph-fav-name { font-size: .86rem; line-height: 1.4; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sph-fav-time { font-size: .72rem; color: #bbb; margin-top: 3px; }
.sph-fav-del { flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; border: 1px solid #eee; background: #fafafa; color: #999; font-size: 12px; cursor: pointer; }

/* ============ 第31轮：佣金靠右 / 商务悬浮标 / 联系人查看弹窗 ============ */
/* 佣金在价格这一行靠右显示 */
.sph-price-row { justify-content: space-between; }
.sph-comm { margin-left: auto; }
/* 对接商务悬浮标：仅员工账号可见，固定在商品图片左下方 */
.sph-imgbox { position: relative; flex-shrink: 0; display: block; overflow: hidden; border-radius: 10px; } /* overflow:hidden：悬浮角标绝不溢出到相邻商品图上（修复两个商品悬浮标重叠） */
.sph-sw-badge { position: absolute; left: 4px; bottom: 4px; display: flex; align-items: center; gap: 4px; max-width: calc(100% - 8px); background: rgba(0,0,0,.62); color: #fff; border-radius: 999px; padding: 2px 8px 2px 2px; font-size: .64rem; line-height: 18px; z-index: 2; pointer-events: none; }
.sph-sw-badge img { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; display: block; flex-shrink: 0; }
.sph-sw-badge i { width: 18px; height: 18px; border-radius: 50%; background: #07c160; font-style: normal; font-size: .6rem; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.sph-sw-badge em { font-style: normal; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* 商务筛选条（员工专属） */
.sph-swbar { display: flex; gap: 8px; overflow-x: auto; padding: 8px 14px 2px; scrollbar-width: none; }
.sph-swbar::-webkit-scrollbar { display: none; }
.sph-swbar a { flex-shrink: 0; padding: 5px 12px; border-radius: 999px; background: #fff; border: 1px solid #eee; font-size: .76rem; color: #555; text-decoration: none; }
.sph-swbar a.on { background: #e8f8ee; border-color: #07c160; color: #07c160; font-weight: 600; }
.sph-swbar .swb-lab { flex-shrink: 0; align-self: center; font-size: .76rem; color: #999; }
/* 品牌合集页：姓名行右侧「查看」按钮（联系方式默认隐藏，点击弹窗展开） */
.sph-view-btn { flex-shrink: 0; margin-left: auto; border: none; background: #07c160; color: #fff; font-size: .74rem; border-radius: 999px; padding: 4px 14px; cursor: pointer; }
.sph-view-btn:disabled { opacity: .6; }
/* 我的查看记录统计行 */
.sph-view-stat { font-size: .8rem; color: #777; padding: 2px 0 10px; }
.sph-view-stat b { color: #f59e0b; font-size: 1rem; }

/* ============ 会员资料：一对一公开开关（iOS 风格滑动开关） ============ */
.sph-switches { border: 1px solid #eee; border-radius: 10px; overflow: hidden; margin: 4px 0 12px; }
.sph-switch-row { display: flex; align-items: center; justify-content: space-between; padding: 11px 14px; font-size: .85rem; color: #333; border-bottom: 1px solid #f4f4f4; cursor: pointer; margin: 0; }
.sph-switch-row:last-child { border-bottom: none; }
.sph-switch { position: relative; display: inline-block; width: 44px; height: 25px; flex-shrink: 0; }
.sph-switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.sph-switch i { position: absolute; inset: 0; background: #ddd; border-radius: 999px; transition: background .2s ease; }
.sph-switch i:after { content: ''; position: absolute; top: 2.5px; left: 3px; width: 20px; height: 20px; background: #fff; border-radius: 50%; transition: left .2s ease; box-shadow: 0 1px 3px rgba(0,0,0,.25); }
.sph-switch input:checked + i { background: #07c160; }
.sph-switch input:checked + i:after { left: 21px; }
/* 我的资料设置表单 */
.sph-prof-form label { display: block; font-size: .8rem; color: #888; margin: 10px 0 5px; }
.sph-prof-form input[type=text] { width: 100%; box-sizing: border-box; border: 1px solid #e5e5e5; border-radius: 9px; padding: 9px 12px; font-size: .88rem; outline: none; }
.sph-prof-form input[type=text]:focus { border-color: #07c160; }

/* ============ 图片页内弹窗放大（lightbox.js 配套样式，商品详情页图集点击放大） ============ */
.img-lightbox { position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.88); display: flex; align-items: center; justify-content: center; opacity: 0; pointer-events: none; transition: opacity .18s ease; padding: 20px; box-sizing: border-box; touch-action: none; overscroll-behavior: contain; }
.img-lightbox.show { opacity: 1; pointer-events: auto; }
.img-lightbox img { max-width: 94vw; max-height: 88vh; border-radius: 10px; box-shadow: 0 8px 40px rgba(0,0,0,.6); object-fit: contain; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; will-change: transform; }
.img-lightbox .ilb-close { position: absolute; top: calc(14px + env(safe-area-inset-top)); right: 16px; width: 42px; height: 42px; border-radius: 50%; border: none; cursor: pointer; background: rgba(255,255,255,.14); color: #fff; font-size: 20px; line-height: 1; display: flex; align-items: center; justify-content: center; z-index: 1; }
.img-lightbox .ilb-close:hover { background: rgba(255,255,255,.28); }
img.zoomable { cursor: zoom-in; }

/* ============ 固定悬浮「返回上一页」按钮（后台关闭底部菜单时显示在页面左上方） ============ */
.sph-back-float { position: fixed; top: calc(10px + env(safe-area-inset-top)); left: 10px; z-index: 1000; width: 38px; height: 38px; border-radius: 50%; background: #f2f3f5; color: #333; display: flex; align-items: center; justify-content: center; text-decoration: none; box-shadow: 0 2px 8px rgba(0,0,0,.12); }
.sph-back-float:active { background: #e4e6ea; }

/* ============ PC 端居中：页面整体 + 头部 + 底部菜单（移动端不变） ============
   宽度由 CSS 变量 --sph-pc-w 控制（默认 680px，后台「商品汇设置 → 电脑浏览时的页面总宽度」可调） */
@media (min-width: 681px) {
    body { background: #e9ebf0; }
    .aui-flexView { max-width: var(--sph-pc-w, 680px); margin: 0 auto; background: #fff; box-shadow: 0 0 24px rgba(0,0,0,.10); }
    /* 悬浮返回按钮对齐内容栏左边缘（与手机端一致贴在栏内左上角） */
    .sph-back-float { left: calc(50% - (var(--sph-pc-w, 680px) / 2) + 10px); }
    /* 悬浮分享按钮对齐内容栏右边缘 */
    .sph-share-fab { right: calc(50% - (var(--sph-pc-w, 680px) / 2) + 14px); }
}

/* ============ 列表页头部 返回/分享 图标：统一浅灰圆底 ============ */
.sph-share-circle, .sph-back-circle { flex: 0 0 auto; min-width: 0; width: 34px; height: 34px; border-radius: 50%; background: #f2f3f5; display: flex; align-items: center; justify-content: center; padding: 0; color: #333; }
/* :last-child 提高优先级，压住全局 .aui-navBar-item:last-child{justify-content:flex-end}，保证图标在圆底内居中 */
.sph-share-circle:last-child, .sph-back-circle:last-child { justify-content: center; }
.sph-share-circle { margin-right: 12px; margin-left: auto; }
.sph-back-circle { margin-left: 12px; }
.sph-share-circle .icon-share { float: none; }
.sph-share-circle:active, .sph-back-circle:active { background: #e4e6ea; }

/* 品牌页：可溯源高亮标 + 关注按钮 */
.sph-suyuan-tag{display:inline-flex;align-items:center;gap:3px;font-size:.62rem;font-weight:700;color:#fff;background:linear-gradient(90deg,#00c97b,#00a35f);padding:2px 8px;border-radius:10px;margin-left:6px;vertical-align:2px;box-shadow:0 2px 8px rgba(0,163,95,.4);text-decoration:none;animation:sphSyPulse 2s infinite}
@keyframes sphSyPulse{0%,100%{box-shadow:0 2px 8px rgba(0,163,95,.4)}50%{box-shadow:0 2px 14px rgba(0,163,95,.75)}}
.sph-follow-btn{display:inline-block;font-size:.68rem;font-weight:600;padding:3px 10px;border-radius:11px;border:1px solid #15bebb;color:#15bebb;background:transparent;cursor:pointer;margin-left:8px;vertical-align:2px}
.sph-follow-btn.followed{background:rgba(21,190,187,.12);color:#0f9a98;border-color:rgba(21,190,187,.4)}

/* 图片角标组合条：商务名称 + 寄样图标（内部身份可见） */
.sph-badges { position: absolute; left: 4px; bottom: 4px; display: flex; align-items: center; gap: 4px; max-width: calc(100% - 8px); z-index: 2; pointer-events: none; flex-wrap: nowrap; overflow: hidden; }
.sph-badges .sph-sw-badge { position: static; max-width: none; }
.sph-sample-badge { display: inline-flex; align-items: center; background: rgba(255,107,0,.92); color: #fff; border-radius: 999px; padding: 2px 8px; font-size: .64rem; line-height: 18px; white-space: nowrap; flex-shrink: 0; }
.sph-src-badge { display: inline-flex; align-items: center; color: #fff; border-radius: 999px; padding: 2px 8px; font-size: .64rem; line-height: 18px; white-space: nowrap; flex-shrink: 0; font-weight: 600; }
.sph-src-cloud { background: rgba(7,121,228,.92); }
.sph-src-xp { background: rgba(146,64,222,.92); }

/* 系统消息弹窗（后台推送，未读弹出；查看详情 / 关闭） */
.sph-npop-mask { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 999; display: flex; align-items: center; justify-content: center; padding: 30px; }
.sph-npop { width: 100%; max-width: 340px; background: #fff; border-radius: 16px; padding: 18px 18px 14px; box-shadow: 0 12px 40px rgba(0,0,0,.25); }
.sph-npop-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.sph-npop-tt { font-size: .8rem; color: #999; }
.sph-npop-cnt { font-size: .72rem; color: #bbb; }
.sph-npop-title { font-size: 1rem; font-weight: 700; color: #222; line-height: 1.5; }
.sph-npop-body { font-size: .85rem; color: #555; line-height: 1.8; margin-top: 8px; max-height: 40vh; overflow-y: auto; white-space: pre-wrap; word-break: break-all; }
.sph-npop-time { font-size: .7rem; color: #bbb; margin-top: 8px; }
.sph-npop-ops { display: flex; gap: 10px; margin-top: 14px; }
.sph-npop-detail { flex: 1; text-align: center; padding: 10px 0; border-radius: 10px; background: #f2f3f5; color: #333; font-size: .85rem; text-decoration: none; }
.sph-npop-close { flex: 1; border: none; padding: 10px 0; border-radius: 10px; background: linear-gradient(135deg,#15bebb,#0ea5a2); color: #fff; font-size: .85rem; }
/* 佣金加密条（详情页）：点数购买查看 */
.sph-comm-lock { text-align: center; padding: 12px 14px 10px; }
.sph-comm-lock-txt { display: block; font-size: .84rem; color: #b08322; margin-bottom: 8px; }
