/* ========== 全局变量 ========== */
:root{--delta-green:#a8d600;--bg-light:#f8f9fb;--card-white:#fff;--text-main:#1a1d21;--text-sub:#999;--danger:#ff4d4f;--orange:#fa8c16}
*{margin:0;padding:0;box-sizing:border-box}
body{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;background:var(--bg-light);color:var(--text-main);padding-bottom:80px;-webkit-tap-highlight-color:transparent}
a{text-decoration:none;color:inherit}
img{max-width:100%;display:block}

/* ========== 页面容器 ========== */
.page-container{min-height:100vh;padding-bottom:80px}

/* ========== 顶部导航栏(通用) ========== */
.top-bar{position:sticky;top:0;z-index:50;background:#1a1d21;padding:12px 15px;display:flex;align-items:center;gap:12px}
.top-bar .back-btn{color:var(--delta-green);font-size:22px;flex-shrink:0;width:32px;height:32px;display:flex;align-items:center;justify-content:center}
.top-bar .page-title{flex:1;color:#fff;font-size:16px;font-weight:800;letter-spacing:1px}
.top-bar .page-title small{font-size:9px;color:rgba(168,214,0,.5);font-family:monospace;margin-left:6px}

/* ========== 分类横向滚动 ========== */
.category-scroll{display:flex;overflow-x:auto;gap:10px;padding:12px 15px;background:#fff;-webkit-overflow-scrolling:touch;scrollbar-width:none}
.category-scroll::-webkit-scrollbar{display:none}
.category-item{flex-shrink:0;padding:6px 16px;background:#f4f6f9;border-radius:4px;font-size:13px;font-weight:700;color:#666;white-space:nowrap;transition:all .2s;border:1px solid transparent}
.category-item.active{background:#1a1d21;color:var(--delta-green);border-color:rgba(168,214,0,.3)}

/* ========== 筛选栏 ========== */
.filter-bar{display:flex;align-items:center;padding:10px 15px;background:#fff;border-bottom:1px solid rgba(0,0,0,.04);gap:4px}
.filter-item{flex:1;text-align:center;font-size:12px;font-weight:700;color:#999;padding:6px 0;position:relative;cursor:pointer;transition:color .2s}
.filter-item.active{color:var(--delta-green)}
.filter-item.active::after{content:'';position:absolute;bottom:0;left:30%;right:30%;height:2px;background:var(--delta-green)}
.filter-item i{font-size:14px;margin-left:2px;vertical-align:middle}

/* ========== 瀑布流商品卡片 ========== */
.waterfall-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:10px 12px}

.product-card{
    background:#fff;border-radius:12px;overflow:hidden;position:relative;
    box-shadow:0 2px 12px rgba(0,0,0,.06),0 0 0 1px rgba(0,0,0,.03);
    transition:transform .25s cubic-bezier(.25,.46,.45,.94),box-shadow .25s ease;
}
.product-card:active{transform:scale(.97);box-shadow:0 1px 6px rgba(0,0,0,.08)}

/* 图片区域 */
.product-card .card-img-wrap{
    position:relative;width:100%;aspect-ratio:4/3;overflow:hidden;background:linear-gradient(135deg,#f0f2f5,#e8eaed);
}
.product-card .card-img-wrap::after{
    content:'';position:absolute;bottom:0;left:0;right:0;height:40%;
    background:linear-gradient(to top,rgba(0,0,0,.15),transparent);pointer-events:none;z-index:2;
}
.product-card .card-img{width:100%;height:100%;object-fit:cover;transition:transform .4s cubic-bezier(.25,.46,.45,.94)}
.product-card:active .card-img{transform:scale(1.03)}
.product-card .card-img-preview{
    position:absolute;bottom:8px;right:8px;width:30px;height:30px;
    background:rgba(0,0,0,.45);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
    border-radius:8px;display:flex;align-items:center;justify-content:center;
    color:rgba(255,255,255,.9);font-size:16px;cursor:pointer;z-index:10;
    transition:all .2s;border:1px solid rgba(255,255,255,.15);
}
.product-card .card-img-preview:active{background:rgba(0,0,0,.7);transform:scale(.9)}

/* 认证角标 */
.product-card .card-tag{
    padding:2px 5px;
    font-size:7px;font-weight:800;color:#fff;letter-spacing:.2px;
    background:rgba(0,0,0,.45);backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);
    border-radius:3px;line-height:1.3;
    display:inline-flex;align-items:center;gap:2px;flex-shrink:0;
}
.product-card .card-tag img{width:9px;height:9px;object-fit:contain}
.product-card .card-tag.cert{background:rgba(250,140,22,.8)}

/* 卡片内容区 */
.product-card .card-body{padding:10px 10px 12px}

/* 分类标签 */
.product-card .card-cat-tag{
    display:inline-block;font-size:9px;padding:2px 6px;
    background:linear-gradient(135deg,rgba(168,214,0,.12),rgba(168,214,0,.06));
    color:#6d8f00;border-radius:4px;font-weight:800;margin-bottom:6px;
    border:1px solid rgba(168,214,0,.15);letter-spacing:.3px;
}

/* 标题 */
.product-card .card-title{
    font-size:13px;font-weight:700;color:#1a1d21;line-height:1.45;
    display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;
    overflow:hidden;margin-bottom:8px;min-height:38px;
    letter-spacing:-.2px;
}

/* 价格区域 */
.product-card .card-price-wrap{
    display:flex;align-items:center;gap:6px;margin-bottom:10px;
}
.product-card .card-price{
    font-size:20px;font-weight:900;color:var(--danger);letter-spacing:-.5px;
    line-height:1;
}
.product-card .card-price small{font-size:12px;font-weight:800;margin-right:1px}
.product-card .card-badges{display:flex;align-items:center;gap:3px;margin-left:auto}
.product-card .card-badge-icon{
    width:18px;height:18px;border-radius:4px;display:flex;align-items:center;justify-content:center;font-size:11px;
}
.product-card .card-badge-icon.green{background:rgba(76,175,80,.1);color:#4caf50}
.product-card .card-badge-icon.orange{background:rgba(255,152,0,.1);color:#ff9800}

/* 用户信息区 */
.product-card .card-meta{
    display:flex;align-items:center;justify-content:space-between;gap:6px;
    padding-top:8px;border-top:1px solid rgba(0,0,0,.04);
}
.product-card .card-user{display:flex;align-items:center;gap:6px;flex:1;min-width:0}
.product-card .card-user img{
    width:22px;height:22px;border-radius:50%;object-fit:cover;flex-shrink:0;
    border:1.5px solid rgba(0,0,0,.06);
}
.product-card .card-user-info{flex:1;min-width:0;display:flex;flex-direction:column;gap:1px}
.product-card .card-user-name{
    font-size:11px;font-weight:700;color:#333;
    overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
.product-card .card-credit{
    font-size:9px;font-weight:700;color:#52c41a;display:flex;align-items:center;gap:1px;
}
.product-card .card-credit i{font-size:10px}
.product-card .card-stats{
    font-size:9px;color:#aaa;font-weight:700;flex-shrink:0;white-space:nowrap;
    background:#f8f9fb;padding:2px 6px;border-radius:4px;
}

/* 底部信息 */
.product-card .card-footer{
    display:flex;align-items:center;justify-content:space-between;margin-top:8px;
}
.product-card .card-time{
    font-size:10px;color:#bbb;font-weight:500;
    display:flex;align-items:center;gap:3px;
}
.product-card .card-time i{font-size:12px}

/* 商家认证标签 */
.user-cert-tag{
    display:inline-flex;align-items:center;gap:2px;
    font-size:8px;padding:1px 5px;border-radius:3px;font-weight:800;flex-shrink:0;
    letter-spacing:.3px;
}
.user-cert-tag img{width:9px;height:9px}
.user-cert-tag.cert1{background:linear-gradient(135deg,#fff8e6,#fff3d6);color:#c4862e;border:1px solid rgba(196,134,46,.15)}
.user-cert-tag.cert2{background:linear-gradient(135deg,#f0fdf4,#e6f9ec);color:#16a34a;border:1px solid rgba(22,163,74,.15)}
.user-cert-tag.cert3{background:linear-gradient(135deg,#eff6ff,#e5efff);color:#3b82f6;border:1px solid rgba(59,130,246,.15)}

/* ========== 空状态 ========== */
.empty-state{text-align:center;padding:60px 20px;color:#ccc}
.empty-state i{font-size:48px;margin-bottom:12px;display:block}
.empty-state p{font-size:13px;font-weight:600}

/* ========== 加载更多 ========== */
.load-more{text-align:center;padding:20px;font-size:12px;color:#bbb;font-weight:700}

/* ========== 底部导航栏 ========== */
.bottom-nav-wrap{position:fixed;bottom:0;left:0;right:0;z-index:100}
.bottom-nav{position:relative;height:58px;background:#1a1d21;display:flex;align-items:center;justify-content:space-around;box-shadow:0 -1px 12px rgba(0,0,0,.3);padding-bottom:env(safe-area-inset-bottom);border-top:1px solid rgba(168,214,0,.15)}
.nav-item{display:flex;flex-direction:column;align-items:center;justify-content:center;flex:1;height:58px;text-decoration:none;color:#555;transition:color .2s}
.nav-item.active{color:var(--delta-green)}
.nav-item i{font-size:22px;line-height:1}
.nav-item span{font-size:10px;margin-top:3px;font-weight:700;letter-spacing:.5px}
.nav-item-publish{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;flex:1;height:58px;text-decoration:none;padding-bottom:5px}
.publish-btn-ring{position:absolute;top:-24px;width:64px;height:64px;background:#1a1d21;border-radius:50%;display:flex;align-items:center;justify-content:center;box-shadow:0 -3px 10px rgba(0,0,0,.3);border:1px solid rgba(168,214,0,.15)}
.publish-btn{width:50px;height:50px;background:linear-gradient(135deg,#c4e600,#a8d600);border-radius:50%;display:flex;align-items:center;justify-content:center;box-shadow:0 4px 16px rgba(168,214,0,.35)}
.publish-btn i{font-size:28px;color:#1a1d21;transition:transform .3s}
.publish-btn.rotated i{transform:rotate(45deg)}
.nav-item-publish span{font-size:10px;font-weight:700;color:#555;letter-spacing:.5px}

/* 发布弹出 */
.publish-overlay{position:fixed;inset:0;background:rgba(0,0,0,.55);z-index:98;opacity:0;pointer-events:none;transition:opacity .3s}
.publish-overlay.show{opacity:1;pointer-events:auto}
.publish-popup{position:fixed;bottom:100px;left:50%;transform:translateX(-50%) translateY(40px);opacity:0;pointer-events:none;display:flex;gap:36px;transition:all .35s cubic-bezier(.34,1.56,.64,1);z-index:101}
.publish-popup.show{transform:translateX(-50%) translateY(0);opacity:1;pointer-events:auto}
.publish-popup-item{display:flex;flex-direction:column;align-items:center;gap:14px;cursor:pointer}
.glass-bubble{width:100px;height:100px;background:rgba(255,255,255,.089);clip-path:polygon(15% 0%,100% 0%,100% 85%,85% 100%,0% 100%,0% 15%);display:flex;align-items:center;justify-content:center;box-shadow:0 10px 30px rgba(0,0,0,.3);transition:transform .2s;position:relative;border-radius:5px}
.glass-bubble::before{content:'';position:absolute;top:4px;right:4px;width:5px;height:5px;border-top:1.5px solid var(--delta-green);border-right:1.5px solid var(--delta-green)}
.glass-bubble img{width:70px;height:70px;object-fit:contain;position:relative;z-index:1}
.publish-popup-item .popup-label{font-size:13px;font-weight:800;color:var(--delta-green);letter-spacing:1.5px;font-family:monospace;text-shadow:0 0 6px rgba(168,214,0,.3)}

/* ========== 表单样式 ========== */
.form-group{margin-bottom:16px}
.form-group label{display:block;font-size:13px;font-weight:700;color:#1a1d21;margin-bottom:6px}
.form-group label small{color:#999;font-weight:400;margin-left:4px}
.form-input{width:100%;height:42px;padding:0 12px;border:1px solid rgba(0,0,0,.08);border-radius:4px;font-size:14px;background:#fff;outline:none;transition:border-color .2s}
.form-input:focus{border-color:var(--delta-green)}
.form-textarea{width:100%;min-height:80px;padding:10px 12px;border:1px solid rgba(0,0,0,.08);border-radius:4px;font-size:14px;background:#fff;outline:none;resize:vertical}
.form-textarea:focus{border-color:var(--delta-green)}

/* 标签选择 */
.tag-select{display:flex;flex-wrap:wrap;gap:8px}
.tag-option{padding:6px 14px;background:#f4f6f9;border:1px solid transparent;border-radius:4px;font-size:12px;font-weight:700;color:#666;cursor:pointer;transition:all .2s}
.tag-option.active{background:#1a1d21;color:var(--delta-green);border-color:rgba(168,214,0,.3)}

/* 提交按钮 */
.btn-submit{width:100%;height:48px;background:linear-gradient(135deg,#c4e600,#a8d600);border:none;border-radius:6px;font-size:16px;font-weight:800;color:#1a1d21;cursor:pointer;letter-spacing:1px}
.btn-submit:active{opacity:.8}
.btn-submit:disabled{opacity:.4;cursor:not-allowed}

/* ========== 用户中心 ========== */
.user-header{background:#1a1d21;padding:30px 20px 40px;position:relative;overflow:hidden}
.user-header::after{content:'';position:absolute;inset:0;background-image:radial-gradient(rgba(168,214,0,.03) 1px,transparent 1px);background-size:10px 10px}
.user-info-row{display:flex;align-items:center;gap:15px;position:relative;z-index:1}
.user-avatar{width:60px;height:60px;border-radius:50%;border:2px solid rgba(168,214,0,.3);object-fit:cover;background:#333}
.user-name{font-size:18px;font-weight:800;color:#fff}
.user-cert-badge{display:inline-block;font-size:9px;padding:2px 6px;background:rgba(250,140,22,.2);color:#fa8c16;border-radius:2px;font-weight:700;margin-left:6px}
.user-id-text{font-size:10px;color:rgba(255,255,255,.4);font-family:monospace;margin-top:2px}

/* 资产卡片 */
.asset-card{margin:-20px 15px 15px;background:#fff;border-radius:8px;padding:20px;box-shadow:0 4px 16px rgba(0,0,0,.04);position:relative;z-index:2;display:flex;justify-content:space-around;text-align:center}
.asset-item .asset-val{font-size:22px;font-weight:900;color:#1a1d21}
.asset-item .asset-label{font-size:11px;color:#999;font-weight:600;margin-top:2px}

/* 功能菜单 */
.menu-section{margin:15px;background:#fff;border-radius:8px;overflow:hidden;box-shadow:0 2px 8px rgba(0,0,0,.02)}
.menu-section .section-title{padding:14px 16px 8px;font-size:12px;font-weight:800;color:#bbb;letter-spacing:1px;font-family:monospace}
.menu-item{display:flex;align-items:center;padding:14px 16px;border-bottom:1px solid rgba(0,0,0,.03)}
.menu-item:last-child{border-bottom:none}
.menu-item i{font-size:20px;color:var(--delta-green);margin-right:12px;width:24px;text-align:center}
.menu-item .menu-text{flex:1;font-size:14px;font-weight:600}
.menu-item .menu-arrow{color:#ccc;font-size:16px}
.menu-item .menu-badge{background:var(--danger);color:#fff;font-size:10px;padding:1px 6px;border-radius:10px;font-weight:700;margin-right:8px}

/* ========== 订单状态标签 ========== */
.status-tag{display:inline-block;font-size:10px;padding:2px 8px;border-radius:3px;font-weight:700}
.status-tag.pending{background:#fff7ed;color:#fa8c16}
.status-tag.frozen{background:#e6f7ff;color:#1890ff}
.status-tag.done{background:#f0fff0;color:#52c41a}
.status-tag.cancel{background:#f5f5f5;color:#999}
.status-tag.refund{background:#fff1f0;color:#ff4d4f}

/* ========== 订单卡片 ========== */
.order-card{background:#fff;margin:10px 15px;border-radius:6px;padding:14px;box-shadow:0 2px 8px rgba(0,0,0,.02);border:1px solid rgba(0,0,0,.04)}
.order-card .order-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:10px;padding-bottom:8px;border-bottom:1px dashed rgba(0,0,0,.05)}
.order-card .order-no{font-size:11px;color:#999;font-family:monospace}
.order-card .order-body{display:flex;gap:12px}
.order-card .order-img{width:70px;height:70px;border-radius:4px;object-fit:cover;background:#f4f6f9;flex-shrink:0}
.order-card .order-info{flex:1}
.order-card .order-title{font-size:13px;font-weight:700;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.order-card .order-price{font-size:16px;font-weight:900;color:var(--danger);margin-top:4px}
.order-card .order-footer{display:flex;justify-content:flex-end;gap:8px;margin-top:12px;padding-top:10px;border-top:1px dashed rgba(0,0,0,.05)}
.order-card .order-btn{padding:6px 16px;border-radius:4px;font-size:12px;font-weight:700;border:1px solid rgba(0,0,0,.1);background:#fff;color:#666;cursor:pointer}
.order-card .order-btn.primary{background:var(--delta-green);color:#1a1d21;border-color:var(--delta-green)}

/* ========== Toast提示 ========== */
.toast-msg{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);background:rgba(0,0,0,.75);color:#fff;padding:10px 24px;border-radius:6px;font-size:13px;font-weight:600;z-index:9999;pointer-events:none;opacity:0;transition:opacity .3s}
.toast-msg.show{opacity:1}

/* ========== 公告横幅 ========== */
.notice-banner{display:flex;align-items:center;margin:10px 15px;padding:10px 14px;background:linear-gradient(135deg,rgba(168,214,0,.12),rgba(168,214,0,.04));border:1px solid rgba(168,214,0,.25);border-radius:8px;overflow:hidden;gap:10px}
.notice-banner-icon{flex-shrink:0;width:28px;height:28px;border-radius:6px;background:var(--delta-green);display:flex;align-items:center;justify-content:center;color:#1a1d21;font-size:14px}
.notice-banner-content{flex:1;overflow:hidden;white-space:nowrap}
.notice-text{display:inline-block;font-size:13px;color:#1a1d21;font-weight:600;animation:noticeScroll 12s linear infinite}
@keyframes noticeScroll{0%{transform:translateX(100%)}100%{transform:translateX(-100%)}}

/* ========== 公告弹窗(子页面) ========== */
.sub-notice-overlay{position:fixed;inset:0;background:rgba(10,12,16,.55);backdrop-filter:blur(12px);z-index:9000;display:flex;align-items:center;justify-content:center;opacity:0;animation:snOverIn .4s ease forwards}
@keyframes snOverIn{to{opacity:1}}
.sub-notice-wrap{position:relative;width:calc(100% - 40px);max-width:360px;transform:translateY(30px);opacity:0;animation:snCardIn .5s .15s cubic-bezier(.22,.68,0,1.2) forwards}
@keyframes snCardIn{to{transform:translateY(0);opacity:1}}
.sub-notice-modal{background:#fff;border-radius:20px;overflow:hidden;box-shadow:0 20px 60px rgba(0,0,0,.15),0 0 0 1px rgba(0,0,0,.04)}
.sn-header{padding:24px 24px 12px;text-align:center;position:relative}
.sn-header .sn-icon{width:52px;height:52px;margin:0 auto 12px;background:linear-gradient(135deg,rgba(168,214,0,.12),rgba(168,214,0,.05));border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:24px;color:var(--delta-green)}
.sn-header .sn-title{font-size:18px;font-weight:900;color:#1a1d21;letter-spacing:.5px}
.sn-body{padding:4px 24px 20px}
.sn-body .sn-content{background:#f8f9fb;border:1px solid rgba(0,0,0,.04);border-radius:12px;padding:16px;max-height:220px;overflow-y:auto;font-size:14px;line-height:1.8;color:#333;white-space:pre-wrap;word-break:break-all}
.sn-body .sn-content::-webkit-scrollbar{width:3px}
.sn-body .sn-content::-webkit-scrollbar-thumb{background:rgba(168,214,0,.3);border-radius:3px}
.sn-footer{padding:0 24px 24px;text-align:center}
.sn-close-btn{width:100%;height:44px;border:none;border-radius:12px;font-size:14px;font-weight:800;cursor:pointer;background:linear-gradient(135deg,var(--delta-green),#c4e600);color:#1a1d21;box-shadow:0 4px 15px rgba(168,214,0,.2);transition:transform .2s;letter-spacing:.5px}
.sn-close-btn:active{transform:scale(.96)}
