/* ============================================================
   积分商城 / 我的礼品 —— 共用样式（橙色主题，移动端优先）
   页面：/points          积分商城
        /points?view=mine 我的礼品
   ============================================================ */
.pt-page {
    --or: #e8722c;
    --or-deep: #c85a18;
    --or-soft: #fdf1e7;
    --ink: #2b2b2f;
    --sub: #9a9aa2;
    --line: #f0f1f4;
    background: #f6f7f9;
    min-height: 100vh;
    padding: 0 0 104px;
    color: var(--ink);
    -webkit-font-smoothing: antialiased;
}
.pt-inner { max-width: 480px; margin: 0 auto; }

/* ---------- 顶部栏 ---------- */
.pt-topbar {
    position: sticky; top: 0; z-index: 30;
    display: flex; align-items: center; height: 50px; padding: 0 14px;
    background: rgba(246,247,249,.94); backdrop-filter: blur(8px);
}
.pt-icbtn {
    width: 34px; height: 34px; border-radius: 50%; border: 1px solid #e8e9ee; background: #fff;
    display: flex; align-items: center; justify-content: center; cursor: pointer; padding: 0;
    color: #5c5c66; flex: none; text-decoration: none;
}
.pt-topbar-title { flex: 1; text-align: center; font-size: 16.5px; font-weight: 600; letter-spacing: .5px; }

/* ---------- 顶部横幅 ---------- */
.pt-hero {
    position: relative; margin: 4px 12px 0; border-radius: 18px; overflow: hidden;
    background: linear-gradient(135deg, #fbd9b4 0%, #f6bd85 48%, #f2a55f 100%);
    padding: 18px 16px 20px; min-height: 178px;
}
.pt-hero-badge {
    display: inline-flex; align-items: center; gap: 5px;
    background: rgba(255,255,255,.86); color: #a8560f;
    font-size: 11px; font-weight: 600; padding: 5px 10px; border-radius: 999px;
}
.pt-hero-title { margin: 12px 0 0; font-size: 23px; line-height: 1.3; font-weight: 800; color: #6b3410; max-width: 72%; letter-spacing: .5px; }
.pt-hero-sub { margin: 8px 0 0; font-size: 12.5px; color: #96613a; max-width: 74%; line-height: 1.6; }
.pt-hero-pts {
    display: inline-flex; align-items: baseline; gap: 6px; margin-top: 14px;
    background: linear-gradient(180deg, #e07b2b 0%, #cc6717 100%); color: #fff;
    padding: 9px 15px; border-radius: 12px; box-shadow: 0 6px 14px rgba(200,90,24,.28);
}
.pt-hero-pts i { font-style: normal; font-size: 11px; opacity: .86; }
.pt-hero-pts b { font-size: 21px; font-weight: 800; line-height: 1; }
.pt-hero-deco { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); opacity: .95; pointer-events: none; }

/* ---------- 筛选 ---------- */
.pt-chips { display: flex; gap: 8px; padding: 16px 12px 4px; overflow-x: auto; scrollbar-width: none; }
.pt-chips::-webkit-scrollbar { display: none; }
.pt-chip {
    flex: none; height: 34px; padding: 0 16px; border-radius: 999px; border: 1px solid transparent;
    background: #fff; color: #5c5c66; font-size: 13px; display: inline-flex; align-items: center;
    cursor: pointer; text-decoration: none; box-shadow: 0 2px 6px rgba(30,30,40,.04);
}
.pt-chip.on { background: linear-gradient(180deg, #ef8637 0%, #e0701f 100%); color: #fff; border-color: transparent; box-shadow: 0 6px 14px rgba(224,112,31,.28); }

/* ---------- 区块标题 ---------- */
.pt-sec { padding: 18px 14px 0; display: flex; align-items: flex-end; gap: 8px; }
.pt-sec .kicker { font-size: 10.5px; font-weight: 800; letter-spacing: 2px; color: var(--or); text-transform: uppercase; }
.pt-sec h2 { margin: 3px 0 0; font-size: 21px; font-weight: 800; letter-spacing: .5px; }
.pt-sec .right { margin-left: auto; font-size: 12px; color: var(--sub); padding-bottom: 4px; }

/* ---------- 礼品栅格 ---------- */
.pt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 12px; }
.pt-card {
    background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 3px 12px rgba(30,30,40,.05);
    display: flex; flex-direction: column;
}
.pt-card-img { width: 100%; aspect-ratio: 4 / 3; background: #f6f7f9; display: block; object-fit: cover; }
.pt-card-img.ph { display: flex; align-items: center; justify-content: center; color: #d5d8de; }
.pt-card-body { padding: 10px 11px 11px; display: flex; flex-direction: column; flex: 1; }
.pt-card-title { font-size: 13.5px; font-weight: 700; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 38px; }
.pt-card-sub { font-size: 11px; color: var(--sub); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pt-card-meta { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; margin-top: 9px; }
.pt-card-pts { font-size: 16px; font-weight: 800; color: var(--or-deep); white-space: nowrap; }
.pt-card-pts i { font-style: normal; font-size: 10.5px; font-weight: 500; color: var(--sub); margin-left: 2px; }
.pt-card-stock { font-size: 10.5px; color: var(--sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pt-buy {
    width: 100%; height: 32px; margin-top: 10px; border: none; border-radius: 999px; cursor: pointer;
    background: linear-gradient(180deg, #ef8637 0%, #e0701f 100%); color: #fff; font-size: 12.5px; font-weight: 600;
    box-shadow: 0 4px 10px rgba(224,112,31,.26); white-space: nowrap;
}
.pt-buy:disabled { background: #eceef2; color: #b6b9c1; box-shadow: none; cursor: default; }

/* ---------- 空状态 ---------- */
.pt-empty {
    margin: 12px; background: #fff; border-radius: 16px; padding: 46px 24px 40px; text-align: center;
    border: 1px dashed #e6e8ed;
}
.pt-empty-ic {
    width: 66px; height: 66px; margin: 0 auto 18px; border-radius: 20px; background: var(--or-soft);
    display: flex; align-items: center; justify-content: center; color: var(--or);
}
.pt-empty h3 { margin: 0; font-size: 18px; font-weight: 800; }
.pt-empty p { margin: 10px 0 0; font-size: 12.5px; color: var(--sub); line-height: 1.8; }
.pt-empty-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    margin-top: 20px; height: 42px; padding: 0 26px; border: none; border-radius: 999px; cursor: pointer;
    background: linear-gradient(180deg, #ef8637 0%, #e0701f 100%); color: #fff; font-size: 14px; font-weight: 600;
    text-decoration: none; box-shadow: 0 8px 18px rgba(224,112,31,.26);
}

/* ---------- 我的礼品 ---------- */
.pt-acct {
    margin: 4px 12px 0; border-radius: 18px; padding: 18px 16px;
    background: linear-gradient(135deg, #fde3c8 0%, #f8c691 100%);
    display: flex; align-items: flex-start; gap: 12px;
}
.pt-acct .l { flex: 1; min-width: 0; }
.pt-acct .kicker { font-size: 10.5px; font-weight: 800; letter-spacing: 2px; color: #b9681f; }
.pt-acct h2 { margin: 6px 0 0; font-size: 22px; font-weight: 800; color: #5f2f0c; }
.pt-acct p { margin: 8px 0 0; font-size: 12px; color: #96613a; line-height: 1.7; }
.pt-acct .r { text-align: right; flex: none; }
.pt-acct .r b { display: block; font-size: 30px; font-weight: 800; color: #a8560f; line-height: 1; }
.pt-acct .r span { font-size: 11px; color: #96613a; }
.pt-rec { background: #fff; border-radius: 14px; margin: 12px; padding: 4px 14px; box-shadow: 0 3px 12px rgba(30,30,40,.05); }
.pt-rec-row { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.pt-rec-row:last-child { border-bottom: none; }
.pt-rec-img { width: 52px; height: 52px; border-radius: 10px; background: #f4f5f7; object-fit: cover; flex: none; }
.pt-rec-img.ph { display: flex; align-items: center; justify-content: center; color: #cfd2d9; }
.pt-rec-txt { flex: 1; min-width: 0; }
.pt-rec-txt b { display: block; font-size: 14px; font-weight: 700; }
.pt-rec-txt em { font-style: normal; font-size: 11.5px; color: var(--sub); }
.pt-rec-txt .deliver { display: block; font-size: 11.5px; color: var(--or-deep); margin-top: 3px; word-break: break-all; }
.pt-rec-r { text-align: right; flex: none; }
.pt-rec-r .pts { font-size: 13.5px; font-weight: 700; color: var(--or-deep); }
.pt-rec-r .st { display: block; font-size: 10.5px; color: var(--sub); margin-top: 3px; }
.pt-rec-r .st.done { color: #16a34a; }

/* ---------- 页脚 ---------- */
.pt-foot {
    display: flex; align-items: center; max-width: 480px; margin: 18px auto 0; padding: 14px 16px 0;
    border-top: 1px solid #ecedf1; font-size: 11.5px; color: #b0b3bb;
}
.pt-foot a { margin-left: auto; color: var(--or-deep); text-decoration: none; font-weight: 600; }

/* ---------- 兑换确认 / 成功 ---------- */
.pt-mask { position: fixed; inset: 0; background: rgba(30,25,20,.42); z-index: 9990; display: none; }
.pt-mask.open { display: block; }
.pt-sheet {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 9991; background: #fff;
    border-radius: 18px 18px 0 0; padding: 18px 16px calc(20px + env(safe-area-inset-bottom));
    transform: translateY(102%); transition: transform .26s ease; max-height: 86vh; overflow-y: auto;
}
.pt-sheet.open { transform: translateY(0); }
.pt-sheet-inner { max-width: 480px; margin: 0 auto; }
.pt-sheet h3 { margin: 0 0 14px; font-size: 16px; font-weight: 700; }
.pt-buy-row { display: flex; gap: 12px; align-items: center; }
.pt-buy-row img, .pt-buy-row .ph {
    width: 68px; height: 68px; border-radius: 12px; object-fit: cover; background: #f4f5f7; flex: none;
}
.pt-buy-row .ph { display: flex; align-items: center; justify-content: center; color: #cfd2d9; }
.pt-buy-row .t { flex: 1; min-width: 0; }
.pt-buy-row .t b { display: block; font-size: 14.5px; font-weight: 700; }
.pt-buy-row .t span { font-size: 12px; color: var(--sub); }
.pt-buy-row .p { font-size: 18px; font-weight: 800; color: var(--or-deep); white-space: nowrap; }
.pt-field { margin-top: 14px; }
.pt-field label { display: block; font-size: 12.5px; color: #5c5c66; margin-bottom: 6px; }
.pt-input {
    width: 100%; height: 40px; padding: 0 12px; border: 1px solid #e6e8ed; border-radius: 10px;
    font-size: 13px; color: var(--ink); box-sizing: border-box; background: #fff;
}
.pt-input:focus { outline: none; border-color: var(--or); box-shadow: 0 0 0 3px rgba(232,114,44,.10); }
.pt-balance-line { display: flex; align-items: center; font-size: 12.5px; color: var(--sub); margin-top: 14px; }
.pt-balance-line b { color: var(--or-deep); font-size: 14px; margin: 0 3px; }
.pt-confirm {
    width: 100%; height: 48px; margin-top: 18px; border: none; border-radius: 999px; cursor: pointer;
    background: linear-gradient(180deg, #ef8637 0%, #e0701f 100%); color: #fff; font-size: 15.5px; font-weight: 700;
    letter-spacing: 1px; box-shadow: 0 10px 22px rgba(224,112,31,.28);
}
.pt-confirm:disabled { background: #eceef2; color: #b6b9c1; box-shadow: none; cursor: default; }
.pt-cancel { width: 100%; height: 42px; margin-top: 10px; border: none; border-radius: 999px; background: #f4f5f7; color: #5c5c66; font-size: 14px; cursor: pointer; }
.pt-err { font-size: 12.5px; color: #ef4444; margin-top: 10px; min-height: 18px; }

.pt-ok {
    position: fixed; z-index: 9992; left: 50%; top: 50%; transform: translate(-50%,-46%) scale(.94);
    width: min(330px, 86vw); background: #fff; border-radius: 22px; padding: 26px 22px 30px;
    text-align: center; opacity: 0; pointer-events: none; transition: opacity .22s, transform .22s;
    box-shadow: 0 24px 60px rgba(40,32,20,.24);
}
.pt-ok.open { opacity: 1; transform: translate(-50%,-50%) scale(1); pointer-events: auto; }
.pt-ok-ring {
    width: 74px; height: 74px; margin: 6px auto 0; border-radius: 50%;
    border: 4px solid #52c41a; display: flex; align-items: center; justify-content: center; color: #52c41a;
}
.pt-ok-tip { font-size: 12.5px; color: var(--or-deep); margin-top: 14px; }
.pt-ok-title { font-size: 24px; font-weight: 800; margin-top: 6px; }
.pt-ok-sub { font-size: 13px; color: #8a8a92; margin-top: 10px; line-height: 1.7; }
.pt-ok-btn {
    width: 100%; height: 50px; margin-top: 20px; border: none; border-radius: 999px; cursor: pointer;
    background: linear-gradient(180deg, #ef8637 0%, #e0701f 100%); color: #fff; font-size: 16px; font-weight: 700;
    letter-spacing: 2px; box-shadow: 0 0 0 6px var(--or-soft), 0 10px 22px rgba(224,112,31,.24);
}

/* ============================================================
   电脑端（≥900px）：内容收进一张白色卡片里，礼品改成多列，弹层改成居中卡片
   手机端样式完全不动，只是在大屏上补一套版式
   ============================================================ */
@media (min-width: 900px) {
    .pt-page { background: linear-gradient(180deg, #fdf8f3 0%, #f7f3ef 100%); padding: 26px 22px 40px; }
    .pt-inner {
        max-width: 1080px; margin: 0 auto; background: #fff; border-radius: 20px;
        box-shadow: 0 20px 54px rgba(170,110,60,.14); overflow: hidden; padding-bottom: 8px;
    }

    /* 顶栏：大屏不用吸顶，做成卡片内的一条普通栏 */
    .pt-topbar {
        position: static; height: 58px; padding: 0 26px; background: #fff;
        border-bottom: 1px solid #f4efea; backdrop-filter: none;
    }
    .pt-topbar-title { font-size: 17px; }

    /* 横幅：拉高、文字放大，右侧礼物盒装饰放大一点 */
    .pt-hero { margin: 22px 26px 0; border-radius: 18px; padding: 30px 34px 32px; min-height: 214px; }
    .pt-hero-badge { font-size: 12px; padding: 6px 12px; }
    .pt-hero-title { font-size: 34px; max-width: 52%; margin-top: 16px; letter-spacing: 1.2px; }
    .pt-hero-sub { font-size: 14.5px; max-width: 50%; margin-top: 12px; }
    .pt-hero-pts { margin-top: 22px; padding: 11px 18px; border-radius: 14px; }
    .pt-hero-pts b { font-size: 26px; }
    .pt-hero-pts i { font-size: 12px; }
    .pt-hero-deco { right: 46px; }
    .pt-hero-deco svg { width: 92px; height: 92px; }

    /* 筛选与标题 */
    .pt-chips { padding: 22px 26px 0; gap: 10px; }
    .pt-chip { height: 36px; padding: 0 18px; font-size: 13px; }
    .pt-sec { padding: 22px 26px 0; }
    .pt-sec .kicker { font-size: 11px; }
    .pt-sec h2 { font-size: 24px; }
    .pt-sec .right { font-size: 13px; }

    /* 礼品：大屏三列，图改成正方形，卡片信息按比例放大 */
    .pt-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; padding: 16px 26px 8px; }
    .pt-card { border-radius: 16px; }
    .pt-card-img { aspect-ratio: 1 / 1; }
    .pt-card-body { padding: 13px 14px 14px; }
    .pt-card-title { font-size: 15px; min-height: 42px; }
    .pt-card-sub { font-size: 12px; }
    .pt-card-pts { font-size: 18px; }
    .pt-card-pts i { font-size: 11px; }
    .pt-card-stock { font-size: 11.5px; }
    .pt-buy { height: 42px; font-size: 14px; border-radius: 12px; }
    .pt-empty { padding: 54px 0 46px; }

    /* 页脚 */
    .pt-foot { max-width: none; padding: 20px 26px 22px; margin-top: 20px; font-size: 12px; }

    /* 确认弹层：底部抽屉改成居中卡片 */
    .pt-sheet {
        left: 50%; right: auto; top: 50%; bottom: auto;
        width: min(560px, calc(100vw - 60px)); border-radius: 20px;
        padding: 22px 24px 24px; max-height: 88vh;
        transform: translate(-50%, -46%) scale(.97); opacity: 0;
        transition: transform .24s ease, opacity .24s ease;
        box-shadow: 0 30px 70px rgba(40,32,20,.22);
    }
    .pt-sheet.open { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    .pt-sheet-inner { max-width: none; }
    .pt-sheet h3 { font-size: 18px; }
    .pt-buy-row img, .pt-buy-row .ph { width: 78px; height: 78px; }
    .pt-buy-row .t b { font-size: 15.5px; }
    .pt-buy-row .p { font-size: 20px; }
    .pt-confirm { height: 50px; font-size: 16px; }
    .pt-cancel { height: 44px; }

    /* 成功弹窗：大屏稍微放大一点 */
    .pt-ok { width: min(380px, 86vw); padding: 30px 26px 34px; }
    .pt-ok-ring { width: 84px; height: 84px; }
    .pt-ok-title { font-size: 26px; }
    .pt-ok-btn { height: 52px; }

    /* 我的礼品（/points?view=mine）在大屏也一起收进卡片 */
    .pt-rec { padding: 16px 18px; }
    .pt-rec-txt b { font-size: 15px; }
}
