/* =========================================================
   云帆发卡 - 前台样式（Toka 风格 · 玻璃拟态 / 暖琥珀 / 多色点缀）
   ========================================================= */

:root {
    --ink: rgba(97, 97, 97, .87);
    --ink-strong: #3b3b3b;
    --ink-muted: #9b9b9b;
    --brand: #258b63;
    --brand-2: #16a34a;
    --amber: #d98220;
    --amber-2: #ec9e42;
    --amber-3: #cc7416;
    --amber-edge: #b7650e;
    --pink: #fe00dc;
    --pink-soft: #ff4d9d;
    --blue: #1677ff;
    --blue-dark: #0f6af1;
    --green: #2ec25d;
    --warning: #d97706;
    --danger: #f04438;
    --card-bg: rgba(255, 255, 255, .85);
    --card-radius: 20px;
    --card-shadow: 0 15px 32px rgba(237, 169, 195, .14), 0 6px 0 rgba(0, 0, 0, .01);
    --font: "HarmonyOS Sans SC", "HarmonyOS Sans", "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --ease: cubic-bezier(.22, 1, .36, 1);
}

* { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent;
}

body.front-body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    background-color: #fff;
    background-image:
        radial-gradient(circle at 8% 0%, rgba(255, 214, 232, .24) 0%, rgba(255, 255, 255, 0) 34%),
        radial-gradient(circle at 92% 4%, rgba(255, 233, 204, .22) 0%, rgba(255, 255, 255, 0) 30%);
    background-repeat: no-repeat;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
button { font-family: inherit; }
.ic { display: inline-block; vertical-align: -2px; flex-shrink: 0; }

.mono { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; font-size: 13px; }
.muted { color: var(--ink-muted); }
.small { font-size: 12px; }

.container {
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ---------------- 顶部导航 ---------------- */
.top-navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 8px 0;
    background-color: rgba(255, 255, 255, .88);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 12px rgba(0, 0, 0, .06);
}

.navbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.user-area { display: flex; align-items: center; flex-shrink: 0; min-width: 0; }

.brand-link { display: inline-flex; align-items: center; }
.brand-seal { display: block; filter: drop-shadow(0 2px 5px rgba(240, 209, 212, .9)); }
.brand-avatar-img {
    display: block;
    flex-shrink: 0;
    border-radius: 50%;
    object-fit: cover;
    background: #fff;
    border: 1px solid rgba(217, 130, 32, .22);
    box-shadow: 0 2px 5px rgba(240, 209, 212, .9);
}
.brand-name {
    max-width: 180px;
    margin-left: 8px;
    overflow: hidden;
    color: var(--brand);
    font-size: 16px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 3D 琥珀按钮 */
.nav-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-width: 95px;
    height: 32px;
    margin-left: 14px;
    padding: 0 14px;
    border: 1px solid #c87417;
    border-bottom-color: var(--amber-edge);
    border-radius: 8px;
    background-color: var(--amber);
    background-image: linear-gradient(180deg, var(--amber-2) 0%, var(--amber) 58%, var(--amber-3) 100%);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    text-shadow: 0 1px 1px rgba(125, 65, 8, .3);
    box-shadow: 0 3px 0 var(--amber-edge), 0 5px 7px rgba(180, 96, 17, .2), inset 0 1px 0 rgba(255, 255, 255, .32);
    cursor: pointer;
    user-select: none;
    transition: box-shadow .15s ease, background-image .15s ease;
}
.nav-cta:hover { background-image: linear-gradient(180deg, #f0aa55 0%, #e08d2c 58%, #d47a19 100%); }
.nav-cta:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 var(--amber-edge), 0 2px 3px rgba(157, 80, 9, .2), inset 0 2px 3px rgba(125, 65, 8, .2);
}

.nav-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 9px; }
.nav-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-height: 36px;
    padding: 8px 11px;
    border: 1px solid transparent;
    border-radius: 8px;
    color: var(--amber);
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    transition: background-color .18s ease, border-color .18s ease, color .18s ease;
}
.nav-action:hover,
.nav-action.is-active {
    border-color: rgba(217, 130, 32, .3);
    background: rgba(217, 130, 32, .13);
    color: #9f5609;
}

/* ---------------- 内容区 ---------------- */
.content-wrapper { padding: 16px 0 0; }
.page-stack { display: flex; flex-direction: column; gap: 16px; padding-bottom: 40px; }
.page-narrow { max-width: 860px; margin: 0 auto; }

.card {
    position: relative;
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, .9);
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    overflow: hidden;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 24px;
    border-bottom: 1px dashed rgba(255, 124, 124, .18);
}

.card-title {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    color: var(--ink);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .3px;
}
.card-title .ic { color: #b08a6a; }
.card-title-hint {
    margin-left: 8px;
    padding: 1px 8px;
    border-radius: 999px;
    background: rgba(217, 130, 32, .1);
    color: #b7650e;
    font-size: 12px;
    font-weight: 600;
}
.card-title-aside { margin: 0; color: var(--ink-muted); font-size: 13px; }

.card-block { padding: 14px 24px; }

.notice-card .notice-rich-content {
    max-height: 220px;
    overflow: auto;
    color: var(--ink);
    font-size: 14px;
    line-height: 1.9;
    word-break: break-word;
}

/* ---------------- 搜索 ---------------- */
.search-input-wrap {
    position: relative;
    display: flex;
    flex: 1 1 auto;
    align-items: center;
    gap: 8px;
    width: 100%;
}
.search-input-icon {
    position: absolute;
    left: 14px;
    z-index: 1;
    color: #b9b9b9;
    pointer-events: none;
}
.commodity-search {
    width: 100%;
    height: 38px;
    padding: 0 12px 0 38px;
    border: 1px solid rgba(128, 128, 128, .13);
    border-radius: 10px;
    background: #fff;
    color: var(--ink);
    font-size: 14px;
    transition: border-color .18s ease, box-shadow .18s ease;
}
.commodity-search::placeholder { color: #b5b2b2; }
.commodity-search:focus {
    outline: none;
    border-color: rgba(217, 130, 32, .55);
    box-shadow: 0 0 0 3px rgba(217, 130, 32, .12);
}
.search-form { display: flex; align-items: center; gap: 10px; }
.search-input-wrap { min-width: 0; }
.btn-search {
    flex: 0 0 auto;
    white-space: nowrap;
    height: 38px;
    padding: 0 26px;
    border: 0;
    border-radius: 10px;
    background: #28d094;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(40, 208, 148, .22);
    transition: background .16s ease, transform .16s ease;
}
.btn-search:hover { background: #22bd86; }
.btn-search:active { transform: translateY(1px); }

/* ---------------- 双栏 ---------------- */
.shop-layout {
    display: grid;
    grid-template-columns: 352px minmax(0, 1fr);
    gap: 16px;
    align-items: stretch;
}
.category-panel,
.shop-panel {
    display: flex;
    flex-direction: column;
    height: clamp(560px, calc(100vh - 260px), 820px);
    min-height: 0;
}
.category-panel { overflow: visible; position: relative; }
.category-list {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 10px 16px 16px;
    scrollbar-width: thin;
    scrollbar-color: rgba(127, 127, 127, .28) transparent;
}
.category-list::-webkit-scrollbar { width: 4px; }
.category-list::-webkit-scrollbar-thumb { border-radius: 999px; background: rgba(127, 127, 127, .28); }

.category-row {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 10px 10px;
    border-radius: 12px;
    cursor: pointer;
    transition: background .16s ease, color .16s ease;
}
.category-row:hover { background: rgba(22, 163, 74, .06); }
.category-main { display: flex; align-items: center; gap: 8px; min-width: 0; }
.category-icon { font-size: 17px; line-height: 1; }
.category-name {
    color: var(--brand-2);
    font-size: 15px;
    font-weight: 700;
    line-height: 1.55;
    word-break: break-word;
}
.category-row.is-checked { background: rgba(22, 163, 74, .09); }
.category-row.is-checked .category-name { color: #15803d; }
.category-side { flex-shrink: 0; }
.category-count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 7px;
    border: 1px solid var(--badge-border, rgba(147, 197, 253, .75));
    border-radius: 999px;
    background: var(--badge-bg, linear-gradient(132deg, #dbeafe, #cffafe));
    box-shadow: var(--badge-shadow, 0 6px 14px rgba(59, 130, 246, .14));
    color: var(--badge-text, #2563eb);
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}
.badge-p1 { --badge-bg: linear-gradient(132deg, #dbeafe, #cffafe); --badge-text: #2563eb; --badge-shadow: 0 6px 14px rgba(59, 130, 246, .14); --badge-border: rgba(147, 197, 253, .78); }
.badge-p2 { --badge-bg: linear-gradient(132deg, #ede9fe, #fce7f3); --badge-text: #7e22ce; --badge-shadow: 0 6px 14px rgba(168, 85, 247, .14); --badge-border: rgba(216, 180, 254, .78); }
.badge-p3 { --badge-bg: linear-gradient(132deg, #dcfce7, #ccfbf1); --badge-text: #047857; --badge-shadow: 0 6px 14px rgba(16, 185, 129, .14); --badge-border: rgba(134, 239, 172, .78); }
.badge-p4 { --badge-bg: linear-gradient(132deg, #ffedd5, #fef3c7); --badge-text: #c2410c; --badge-shadow: 0 6px 14px rgba(249, 115, 22, .14); --badge-border: rgba(253, 186, 116, .78); }
.badge-p5 { --badge-bg: linear-gradient(132deg, #e0f2fe, #e0e7ff); --badge-text: #1d4ed8; --badge-shadow: 0 6px 14px rgba(37, 99, 235, .14); --badge-border: rgba(165, 180, 252, .78); }
.badge-p6 { --badge-bg: linear-gradient(132deg, #fce7f3, #fae8ff); --badge-text: #be185d; --badge-shadow: 0 6px 14px rgba(236, 72, 153, .14); --badge-border: rgba(244, 114, 182, .72); }
.badge-p7 { --badge-bg: linear-gradient(132deg, #cffafe, #dbeafe); --badge-text: #0e7490; --badge-shadow: 0 6px 14px rgba(6, 182, 212, .14); --badge-border: rgba(103, 232, 249, .72); }
.badge-p8 { --badge-bg: linear-gradient(132deg, #fee2e2, #ffedd5); --badge-text: #b91c1c; --badge-shadow: 0 6px 14px rgba(239, 68, 68, .14); --badge-border: rgba(252, 165, 165, .72); }

/* 移动端竖排引导 */
.category-scroll-guide {
    display: none;
    position: absolute;
    z-index: 20;
    right: 6px;
    top: 58px;
    width: 30px;
    min-height: 140px;
    padding: 10px 5px 8px;
    border: 1px solid rgba(255, 255, 255, .88);
    border-radius: 999px;
    background: linear-gradient(180deg, #ff4d9d 0%, #ff75b5 52%, #ff9ac9 100%);
    box-shadow: 0 8px 20px rgba(255, 77, 157, .3), inset 0 1px 0 rgba(255, 255, 255, .34);
    color: #fff;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 1px;
    line-height: 1;
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity .16s linear, visibility .16s linear;
    pointer-events: none;
}
.category-scroll-guide span:first-child {
    display: block;
    writing-mode: vertical-rl;
    text-orientation: upright;
    text-shadow: 0 1px 3px rgba(128, 0, 55, .26);
}
.category-scroll-guide .guide-arrow {
    display: block;
    margin-top: 6px;
    animation: guideArrow 1.05s ease-in-out infinite;
}
.category-scroll-guide.is-visible { opacity: 1; visibility: visible; }
@keyframes guideArrow {
    0%, 100% { transform: translateY(-2px); }
    50% { transform: translateY(4px); }
}
@media (prefers-reduced-motion: reduce) {
    .category-scroll-guide .guide-arrow { animation: none; }
}

/* ---------------- 商品表 ---------------- */
.shop-content {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 4px 24px 16px;
    scrollbar-width: thin;
    scrollbar-color: rgba(127, 127, 127, .28) transparent;
}
.shop-content::-webkit-scrollbar { width: 4px; }
.shop-content::-webkit-scrollbar-thumb { border-radius: 999px; background: rgba(127, 127, 127, .28); }

.shop-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.shop-table th {
    padding: 12px 0;
    border-bottom: 1px solid rgba(0, 0, 0, .06);
    color: var(--ink);
    font-size: 14px;
    font-weight: 700;
    text-align: left;
    white-space: nowrap;
}
.shop-table th .ic { color: #a9a2a9; margin-right: 4px; }
.shop-table .col-name { width: 42%; }
.shop-table .col-price { width: 16%; }
.shop-table .col-stock { width: 18%; }
.shop-table .col-action { width: 24%; text-align: center; }

.commodity-row td {
    padding: 12px 0;
    border-bottom: 1px solid #f1eef2;
    vertical-align: middle;
    font-size: 14px;
}
.commodity-row:last-child td { border-bottom: none; }
.commodity-row:hover td { background: rgba(255, 245, 250, .55); }

.commodity-name-wrap { display: flex; align-items: center; gap: 8px; min-width: 0; }
.commodity-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    border: 1px solid #f0edf1;
    border-radius: 9px;
    background: #fbf9fb;
    font-size: 15px;
}
.commodity-name-text {
    min-width: 0;
    color: var(--ink);
    font-weight: 600;
    line-height: 1.5;
    word-break: break-word;
}
.tag {
    display: inline-block;
    margin-left: 6px;
    padding: 1px 6px;
    border-radius: 6px;
    font-size: 11px;
    font-style: normal;
    font-weight: 600;
    vertical-align: 1px;
    white-space: nowrap;
}
.tag-auto { background: rgba(22, 163, 74, .12); color: #15803d; }
.tag-manual { background: rgba(217, 119, 6, .14); color: #b45309; }

.price { color: var(--pink); font-size: 15px; font-weight: 800; letter-spacing: .2px; }
.commodity-price-cell .price { font-size: 14px; }

.stock-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--green);
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}
.stock-badge.stock-available { color: var(--green); }
.stock-badge.stock-warning { color: var(--warning); }
.stock-badge.stock-out { color: var(--danger); }

.commodity-action-cell { text-align: center; }
.commodity-click {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 70px;
    height: 34px;
    padding: 0 12px;
    border: 1px solid var(--blue);
    border-radius: 10px;
    background: var(--blue);
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(22, 119, 255, .2);
    transition: background .16s ease, transform .16s ease, box-shadow .16s ease;
}
.commodity-click:hover:not(:disabled) {
    background: var(--blue-dark);
    border-color: var(--blue-dark);
    transform: translateY(-1px);
    box-shadow: 0 6px 12px rgba(22, 119, 255, .24);
}
.commodity-click:active:not(:disabled) { transform: translateY(0) scale(.98); }
.commodity-click:disabled {
    border-color: #c7ccd6;
    background: #c7ccd6;
    box-shadow: none;
    cursor: not-allowed;
}

/* ---------------- 弹窗 ---------------- */
.modal-mask {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(38, 24, 34, .38);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}
.modal-mask[hidden] { display: none; }

.commodity-modal {
    position: relative;
    width: 620px;
    max-width: 100%;
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    padding: 26px 30px 22px;
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(255, 255, 255, .97) 0%, #fff3f8 60%, #ffe7f4 100%);
    box-shadow: 0 7px 29px rgba(253, 173, 204, .35), inset 0 1px 0 rgba(255, 255, 255, .8);
    animation: modalPop .22s var(--ease);
}
@keyframes modalPop {
    from { opacity: 0; transform: translateY(10px) scale(.98); }
    to { opacity: 1; transform: none; }
}
.modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 50%;
    background: rgba(120, 120, 120, .12);
    color: #6d6a6d;
    cursor: pointer;
    transition: background .16s ease;
}
.modal-close:hover { background: rgba(120, 120, 120, .2); }

.commodity-name {
    margin: 0 0 16px;
    padding-bottom: 14px;
    border-bottom: 1px dashed rgba(255, 124, 124, .23);
    color: #7a7878;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.4;
    text-align: center;
    word-break: break-word;
}
.share-url {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin: 0 0 12px;
    color: #8e8eef;
    font-size: 13px;
    cursor: pointer;
    user-select: none;
}
.commodity-desc {
    margin-bottom: 14px;
    color: #7c7674;
    font-size: 14px;
    line-height: 1.8;
    white-space: pre-wrap;
    word-break: break-word;
}
.commodity-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}
.commodity-price { color: #008000; font-size: 21px; font-weight: 800; }

.form-row { margin-bottom: 14px; }
.form-row > label {
    display: block;
    margin-bottom: 6px;
    color: #7c7674;
    font-size: 13px;
    font-weight: 600;
}
.form-row > label i { color: var(--pink-soft); font-style: normal; }
.form-row-inline { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-control {
    width: 100%;
    height: 38px;
    padding: 0 12px;
    border: 1px solid rgba(128, 128, 128, .13);
    border-radius: 8px;
    background: #fff;
    color: var(--ink);
    font-family: inherit;
    font-size: 14px;
    transition: border-color .18s ease, box-shadow .18s ease;
}
.form-control::placeholder { color: #bfbaba; }
.form-control:focus {
    outline: none;
    border-color: rgba(255, 77, 157, .55);
    box-shadow: 0 0 0 3px rgba(255, 77, 157, .1);
}
textarea.form-control { height: auto; padding: 10px 12px; line-height: 1.6; resize: vertical; }
select.form-control { padding: 0 8px; }

.qty-control { display: flex; align-items: center; gap: 6px; }
.qty-control input { width: 74px; text-align: center; }
.qty-btn {
    width: 34px;
    height: 38px;
    border: 1px solid rgba(128, 128, 128, .16);
    border-radius: 8px;
    background: #fff;
    color: #6d6a6d;
    font-size: 16px;
    cursor: pointer;
}
.qty-btn:hover { background: #faf7fa; }

.captcha-row { display: flex; align-items: center; gap: 8px; }
.captcha-input { flex: 1 1 auto; width: 120px; }
.captcha-question {
    padding: 7px 12px;
    border: 1px solid rgba(255, 77, 157, .32);
    border-radius: 8px;
    background: #ffeaf4;
    color: #c2185b;
    font-family: "Courier New", monospace;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 2px;
    white-space: nowrap;
}
.captcha-refresh {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid rgba(128, 128, 128, .13);
    border-radius: 8px;
    background: #fff;
    color: #8a858a;
    cursor: pointer;
}
.captcha-refresh:hover { color: #c2185b; }

.pay-section {
    margin-top: 6px;
    padding-top: 12px;
    border-top: 1px dashed rgba(255, 124, 124, .23);
}
.pay-title {
    display: flex;
    align-items: center;
    gap: 5px;
    margin: 0 0 8px;
    color: #bba0a3;
    font-size: 14px;
    font-weight: 700;
}
.pay-methods { display: flex; flex-wrap: wrap; gap: 8px; }
.pay-method { cursor: pointer; }
.pay-method input { position: absolute; opacity: 0; pointer-events: none; }
.pay-method-pill {
    display: inline-flex;
    align-items: center;
    padding: 7px 14px;
    border: 1px solid transparent;
    border-radius: 10px;
    background: rgba(70, 166, 255, .35);
    box-shadow: 0 1px 4px rgba(255, 153, 232, .6);
    color: #5f6670;
    font-size: 14px;
    font-weight: 700;
    transition: all .18s ease;
}
.pay-method:hover .pay-method-pill { background: rgba(70, 166, 255, .5); color: #fff; }
.pay-method input:checked + .pay-method-pill {
    border-color: #1677ff;
    background: #1677ff;
    color: #fff;
    box-shadow: 0 4px 10px rgba(22, 119, 255, .28);
}

.modal-footer { margin-top: 18px; }
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 38px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 10px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    transition: all .16s ease;
}
.btn-block { display: flex; width: 100%; }
.btn-lg { min-height: 46px; font-size: 15px; }
.btn-primary {
    border-color: #c87417;
    border-bottom-color: var(--amber-edge);
    background-color: var(--amber);
    background-image: linear-gradient(180deg, var(--amber-2) 0%, var(--amber) 58%, var(--amber-3) 100%);
    color: #fff;
    text-shadow: 0 1px 1px rgba(125, 65, 8, .25);
    box-shadow: 0 3px 0 var(--amber-edge), 0 5px 7px rgba(180, 96, 17, .18), inset 0 1px 0 rgba(255, 255, 255, .3);
}
.btn-primary:hover { background-image: linear-gradient(180deg, #f0aa55 0%, #e08d2c 58%, #d47a19 100%); }
.btn-primary:active {
    transform: translateY(2px);
    box-shadow: 0 1px 0 var(--amber-edge), 0 2px 3px rgba(157, 80, 9, .18);
}
.btn-ghost {
    border-color: rgba(128, 128, 128, .16);
    background: #fff;
    color: #6d6a6d;
}
.btn-ghost:hover { border-color: rgba(217, 130, 32, .4); color: #b7650e; }
.btn-small { min-height: 30px; padding: 0 12px; font-size: 13px; }
.btn-danger { border-color: #f6c9c3; background: #fff2f0; color: #cf3b30; }
.btn-danger:hover { background: #ffe7e3; }
.btn:disabled { opacity: .55; cursor: not-allowed; }

.modal-tip {
    margin: 10px 0 0;
    color: #b5a9ad;
    font-size: 12px;
    line-height: 1.6;
    text-align: center;
}

/* ---------------- 状态 / 提示 ---------------- */
.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 9px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.7;
    white-space: nowrap;
}
.st-warn { background: #fff3e0; color: #b45309; }
.st-info { background: #e8f1ff; color: #1d4ed8; }
.st-ok { background: #e6f8ee; color: #15803d; }
.st-danger { background: #ffefed; color: #cf3b30; }
.st-muted { background: #f2f0f3; color: #8a858a; }

.empty-state { padding: 42px 16px; text-align: center; color: var(--ink-muted); }
.empty-state.small { padding: 22px 12px; }
.empty-emoji { margin-bottom: 8px; font-size: 34px; }
.empty-state p { margin: 0 0 12px; font-size: 14px; }

.toast-stack {
    position: fixed;
    top: 70px;
    left: 50%;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: min(420px, calc(100vw - 32px));
    transform: translateX(-50%);
    pointer-events: none;
}
.toast {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 11px 14px;
    border: 1px solid rgba(255, 255, 255, .9);
    border-radius: 12px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 10px 30px rgba(31, 38, 135, .16);
    color: #4a4a4a;
    font-size: 13px;
    line-height: 1.6;
    animation: toastIn .22s var(--ease);
    pointer-events: auto;
}
.toast-dot { flex: 0 0 8px; width: 8px; height: 8px; margin-top: 6px; border-radius: 50%; background: #28d094; }
.toast-error .toast-dot { background: #f04438; }
.toast-warning .toast-dot { background: #f59e0b; }
.toast-success .toast-dot { background: #28d094; }
.toast.is-hide { opacity: 0; transform: translateY(-6px); transition: all .2s ease; }
@keyframes toastIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: none; }
}

/* ---------------- 支付页 / 订单 / 查询 / 工单 ---------------- */
.info-list { margin: 4px 0 14px; }
.info-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 9px 0;
    border-bottom: 1px dashed rgba(0, 0, 0, .06);
    font-size: 14px;
}
.info-row:last-child { border-bottom: none; }
.info-row > span { color: var(--ink-muted); flex-shrink: 0; }
.info-row > strong { color: var(--ink-strong); font-weight: 600; text-align: right; word-break: break-all; }

.pay-amount-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-bottom: 16px;
    padding: 18px;
    border: 1px dashed rgba(217, 130, 32, .28);
    border-radius: 14px;
    background: linear-gradient(180deg, #fffdfa, #fff6ec);
}
.pay-amount-label { color: var(--ink-muted); font-size: 13px; }
.pay-amount { color: #b7650e; font-size: 34px; font-weight: 800; line-height: 1.2; }
.pay-method-name { color: var(--ink-muted); font-size: 13px; }

.demo-alert {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 12px 0 16px;
    padding: 10px 12px;
    border: 1px solid rgba(250, 140, 22, .22);
    border-radius: 10px;
    background: #fff7e6;
    color: #7a3b00;
    font-size: 12px;
    line-height: 1.7;
}
.demo-alert .ic { margin-top: 2px; flex-shrink: 0; }
.demo-alert.warm { border-color: rgba(217, 130, 32, .3); }
.demo-alert a { color: #b45309; font-weight: 700; text-decoration: underline; }

.pay-actions,
.order-actions,
.service-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.verify-box {
    padding: 4px 2px 8px;
}
.verify-box h3 { margin: 4px 0 6px; color: var(--ink-strong); font-size: 17px; }
.verify-box p { margin: 0 0 14px; font-size: 13px; }
.verify-form { max-width: 460px; }

.order-steps {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 6px 0 16px;
    padding: 12px 14px;
    border-radius: 12px;
    background: linear-gradient(180deg, #fffdfa, #fff8f1);
    border: 1px dashed rgba(217, 130, 32, .25);
}
.order-step { display: flex; align-items: center; gap: 6px; color: #a9a4a9; font-size: 13px; font-weight: 700; }
.order-step.is-done { color: #15803d; }
.step-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #f0edf1;
    color: #9b959b;
    font-size: 12px;
    font-weight: 800;
}
.order-step.is-done .step-dot { background: #dcfce7; color: #15803d; }
.step-line { flex: 1 1 auto; height: 2px; min-width: 18px; border-radius: 2px; background: #eee9ee; }

.cards-box { margin: 16px 0 4px; }
.cards-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
    color: var(--ink-strong);
    font-size: 14px;
    font-weight: 700;
}
.cards-head > span { display: inline-flex; align-items: center; gap: 6px; }
.cards-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid rgba(22, 163, 74, .25);
    border-radius: 10px;
    background: #f7fdf9;
    color: #14532d;
    font-family: "SFMono-Regular", Consolas, monospace;
    font-size: 13px;
    line-height: 1.8;
    resize: vertical;
}

.query-form .query-input-row { display: flex; gap: 10px; align-items: center; }
.query-password-row { margin-top: 10px; max-width: 420px; }
.query-results { margin-top: 20px; }
.section-title { margin: 0 0 10px; color: var(--ink); font-size: 15px; font-weight: 700; }
.order-row-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 10px;
    padding: 12px 14px;
    border: 1px solid #f0edf1;
    border-radius: 12px;
    background: #fff;
}
.order-row-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 14px; }
.order-icon { font-size: 18px; }
.order-row-meta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 4px; color: var(--ink-muted); font-size: 12px; }
.order-row-action { flex-shrink: 0; }
.query-tips {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin-top: 16px;
    color: var(--ink-muted);
    font-size: 12px;
    line-height: 1.7;
}
.query-tips .ic { margin-top: 3px; flex-shrink: 0; }

.ticket-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.ticket-create .btn { margin-top: 4px; }
.ticket-item {
    display: block;
    margin-bottom: 10px;
    padding: 12px 14px;
    border: 1px solid #f0edf1;
    border-radius: 12px;
    background: #fff;
    transition: border-color .16s ease, box-shadow .16s ease;
}
.ticket-item:hover { border-color: rgba(217, 130, 32, .35); box-shadow: 0 6px 16px rgba(217, 130, 32, .08); }
.ticket-item-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 14px; }
.ticket-item-meta { display: flex; gap: 14px; margin-top: 4px; color: var(--ink-muted); font-size: 12px; }

.ticket-order-box {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 14px;
    padding: 12px 14px;
    border-radius: 12px;
    background: #fff8f0;
    border: 1px dashed rgba(217, 130, 32, .25);
    font-size: 14px;
}
.ticket-order-box strong { color: var(--ink-strong); }
.ticket-order-box p { margin: 2px 0 0; }

.chat-thread { display: flex; flex-direction: column; gap: 14px; margin: 8px 0 18px; }
.chat-item { display: flex; gap: 10px; align-items: flex-start; }
.chat-item.is-admin { flex-direction: row-reverse; }
.chat-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #fff3e6;
    color: #b7650e;
    font-size: 12px;
    font-weight: 700;
}
.chat-item.is-admin .chat-avatar { background: #e8f1ff; color: #1d4ed8; }
.chat-body { max-width: 76%; }
.chat-bubble {
    padding: 10px 12px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #f0edf1;
    color: var(--ink);
    font-size: 14px;
    line-height: 1.7;
    word-break: break-word;
}
.chat-item.is-admin .chat-bubble { background: #eef5ff; border-color: #dbe9ff; }
.chat-time { display: block; margin-top: 4px; color: var(--ink-muted); font-size: 11px; }
.chat-item.is-admin .chat-time { text-align: right; }
.chat-reply-form { display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.chat-reply-form textarea { width: 100%; }
.chat-reply-form .btn { align-self: flex-end; }

.service-box { text-align: center; padding: 18px 12px 8px; }
.service-emoji { font-size: 40px; }
.service-box p { margin: 8px 0 10px; color: var(--ink-muted); font-size: 14px; }
.service-contact {
    display: inline-block;
    margin-bottom: 16px;
    padding: 12px 18px;
    border-radius: 12px;
    background: #fff9f1;
    border: 1px dashed rgba(217, 130, 32, .28);
    color: var(--ink-strong);
    font-size: 14px;
    line-height: 1.9;
}
.service-links { justify-content: center; }

/* ---------------- 悬浮工单按钮 ---------------- */
.complaint-float {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 90;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-width: 120px;
    height: 48px;
    padding: 0 18px;
    border: 1px solid rgba(255, 255, 255, .92);
    border-radius: 16px;
    background: rgba(255, 255, 255, .82);
    -webkit-backdrop-filter: blur(18px) saturate(160%);
    backdrop-filter: blur(18px) saturate(160%);
    box-shadow: 0 10px 30px rgba(31, 38, 135, .16), inset 0 1px 0 rgba(255, 255, 255, .95);
    color: #333;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    transition: transform .25s ease, background .25s ease, box-shadow .25s ease;
}
.complaint-float:hover {
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 14px 38px rgba(31, 38, 135, .22);
    transform: translateY(-4px);
}
.complaint-float:active { transform: translateY(-1px) scale(.98); }
.complaint-float-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    border: 1px solid rgba(255, 73, 104, .22);
    border-radius: 50%;
    background: rgba(255, 73, 104, .14);
    color: #ff4968;
    font-size: 15px;
    font-weight: 800;
}

/* ---------------- 页脚 ---------------- */
.site-footer { padding: 18px 0 26px; }
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    color: #a9a2a9;
    font-size: 12px;
}
.footer-left, .footer-right { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.footer-sep { color: #d9d2d9; }
.footer-muted { color: #b9b2b9; }
.footer-admin-link { color: #a9a2a9; }
.footer-admin-link:hover { color: var(--amber); }

/* ---------------- 响应式 ---------------- */
@media (max-width: 991.98px) {
    .top-navbar { padding: 0; }
    .navbar-container { display: block; padding: 0; }
    .user-area {
        width: 100%;
        min-height: 52px;
        padding: 8px 15px;
        justify-content: space-between;
        border-bottom: 1px solid rgba(0, 0, 0, .05);
    }
    .brand-name { max-width: calc(100vw - 220px); font-size: 15px; }
    .nav-cta { margin-left: 10px; min-width: 84px; height: 30px; padding: 0 12px; }
    .nav-actions {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        width: 100%;
        padding: 8px 12px 11px;
        gap: 8px;
    }
    .nav-action { width: 100%; min-width: 0; min-height: 42px; padding: 8px 4px; font-size: 12px; }
    .nav-action span { overflow: hidden; text-overflow: ellipsis; }

    .shop-layout { grid-template-columns: 1fr; }
    .category-panel { height: auto; }
    .category-list { max-height: 280px; position: relative; }
    .category-scroll-guide { display: block; }
    .shop-panel { height: auto; }
    .shop-content { overflow: visible; padding: 4px 18px 18px; }
    .category-list { padding: 10px 14px 14px; }
    .card-header { padding: 10px 18px; }
    .card-block { padding: 12px 18px; }
}

@media (max-width: 767.98px) {
    .container { padding: 0 10px; }
    .card { border-radius: 16px; }
    .page-stack { gap: 12px; padding-bottom: 84px; }
    .content-wrapper { padding-top: 12px; }
    .category-list { padding-right: 46px; }
    .shop-table .col-name { width: 37%; }
    .shop-table .col-price { width: 20%; }
    .shop-table .col-stock { width: 17%; }
    .shop-table .col-action { width: 26%; }
    .commodity-price-cell { padding-right: 4px; }
    .shop-table th { font-size: 13px; padding: 10px 0; }
    .commodity-row td { font-size: 13px; padding: 10px 0; }
    .commodity-icon { flex-basis: 24px; width: 24px; height: 24px; font-size: 13px; }
    .commodity-click { min-width: 62px; height: 30px; padding: 0 8px; font-size: 12px; border-radius: 8px; }
    .price { font-size: 13px; }
    .stock-badge { font-size: 13px; }
    .tag { display: none; }
    .modal-mask { padding: 0; align-items: stretch; }
    .commodity-modal {
        width: 100%;
        max-height: none;
        min-height: 100vh;
        border-radius: 0;
        padding: 18px 18px 28px;
    }
    .commodity-name { font-size: 19px; margin-bottom: 12px; }
    .form-row-inline { grid-template-columns: 1fr; gap: 0; }
    .modal-close { right: 10px; top: 10px; }
    .toast-stack { top: 60px; }
    .ticket-layout { grid-template-columns: 1fr; }
    .order-row-card { flex-direction: column; align-items: flex-start; }
    .order-row-action { width: 100%; }
    .order-row-action .btn { width: 100%; }
    .info-row { font-size: 13px; }
    .chat-body { max-width: 82%; }
    .complaint-float { right: 14px; bottom: 18px; min-width: 104px; height: 44px; padding: 0 14px; font-size: 13px; border-radius: 14px; }
    .complaint-float-icon { width: 22px; height: 22px; font-size: 14px; }
    .footer-inner { flex-direction: column; align-items: flex-start; gap: 6px; }
}

@media (max-width: 575.98px) {
    .brand-name { max-width: calc(100vw - 200px); font-size: 14px; }
    .nav-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .nav-action { min-height: 44px; flex-direction: column; gap: 3px; font-size: 12px; }
    .search-form { flex-direction: row; }
    .btn-search { padding: 0 18px; }
    .category-name { font-size: 14px; }
    .query-form .query-input-row { flex-direction: column; align-items: stretch; }
    .query-form .query-input-row .btn { width: 100%; }
    .order-steps { flex-wrap: wrap; }
    .step-line { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}
