/* ==========================================================================
   小智STEEL · 前台样式
   主色 #3b75bc
   ========================================================================== */

:root {
    --brand: #3b75bc;
    --brand-dark: #2c5c96;
    --brand-deep: #22456f;
    --brand-soft: #eaf1fa;
    --brand-soft-2: #f4f8fd;
    --ink: #1f2a37;
    --ink-2: #3d4b5c;
    --muted: #77869a;
    --line: #e3e9f2;
    --bg: #f5f7fb;
    --white: #fff;
    --warn: #b56a12;
    --radius: 16px;
    --radius-sm: 10px;
    --shadow-sm: 0 2px 8px rgba(31, 42, 55, .05);
    --shadow: 0 10px 30px rgba(59, 117, 188, .10);
    --shadow-lg: 0 24px 60px rgba(34, 69, 111, .18);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", system-ui, -apple-system, sans-serif;
    font-size: 15px;
    line-height: 1.75;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }

img { max-width: 100%; }

.wrap {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------------- 顶部 ---------------- */

.topbar {
    background: linear-gradient(90deg, #2b5590, #3b75bc 60%, #4a86cb);
    color: #dbe8f7;
    font-size: 13px;
    letter-spacing: .2px;
}
.topbar .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 38px;
    gap: 16px;
}
.topbar .tb-left { display: flex; align-items: center; gap: 10px; opacity: .92; }
.topbar .tb-right { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.topbar .hotline-ico { width: 14px; height: 14px; }
.topbar strong { color: #fff; font-weight: 600; letter-spacing: .5px; }

.site-header {
    background: rgba(255, 255, 255, .96);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 40;
    backdrop-filter: saturate(140%) blur(8px);
}
.site-header .wrap {
    display: flex;
    align-items: center;
    gap: 28px;
    min-height: 72px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 0 0 auto;
}
.brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(140deg, #4a86cb, var(--brand) 55%, var(--brand-deep));
    color: #fff;
    font-size: 21px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0;
    box-shadow: 0 6px 14px rgba(59, 117, 188, .28);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong {
    font-size: 21px;
    letter-spacing: 1px;
    color: var(--brand-deep);
    font-weight: 800;
}
.brand-text strong span { color: var(--brand); }
.brand-text em {
    font-style: normal;
    font-size: 11px;
    color: var(--muted);
    letter-spacing: 2px;
    margin-top: 2px;
}

.nav {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: 8px;
}
.nav a {
    padding: 8px 14px;
    border-radius: 9px;
    color: var(--ink-2);
    font-size: 14.5px;
    transition: all .16s ease;
}
.nav a:hover { background: var(--brand-soft); color: var(--brand-dark); }
.nav a.active { background: var(--brand-soft); color: var(--brand-dark); font-weight: 600; }

.header-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 40px;
    padding: 0 18px;
    border-radius: 10px;
    border: 1px solid transparent;
    font-size: 14.5px;
    font-family: inherit;
    cursor: pointer;
    transition: all .16s ease;
    white-space: nowrap;
}
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 6px 14px rgba(59, 117, 188, .22); }
.btn-primary:hover { background: var(--brand-dark); color: #fff; transform: translateY(-1px); }
.btn-ghost { background: #fff; border-color: #cfdcec; color: var(--brand-dark); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-soft-2); }
.btn-lg { height: 46px; padding: 0 26px; font-size: 15.5px; border-radius: 11px; }
.btn-sm { height: 34px; padding: 0 12px; font-size: 13px; border-radius: 8px; }

.user-chip {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 5px 6px 5px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
}
.user-chip .u-name { font-size: 13.5px; color: var(--ink-2); }
.user-chip .u-role {
    font-size: 11px;
    background: var(--brand-soft);
    color: var(--brand-dark);
    padding: 1px 8px;
    border-radius: 999px;
}
.user-chip a { font-size: 13px; color: var(--muted); }
.user-chip a:hover { color: var(--brand); }

/* ---------------- 首屏 ---------------- */

.hero {
    position: relative;
    padding: 56px 0 46px;
    background:
        radial-gradient(900px 320px at 12% -10%, #e2edfa 0%, rgba(226, 237, 250, 0) 70%),
        radial-gradient(800px 300px at 92% 0%, #e8f0fa 0%, rgba(232, 240, 250, 0) 68%),
        linear-gradient(180deg, #f3f8fd 0%, #f5f7fb 100%);
    overflow: hidden;
}
.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(59, 117, 188, .045) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(59, 117, 188, .045) 1px, transparent 1px);
    background-size: 46px 46px;
    mask-image: linear-gradient(180deg, #000 0%, transparent 78%);
    -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 78%);
    pointer-events: none;
}
.hero .wrap { position: relative; z-index: 2; }

.hero-head { text-align: center; margin-bottom: 30px; }
.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 12.5px;
    letter-spacing: 2px;
    color: var(--brand);
    background: rgba(59, 117, 188, .08);
    border: 1px solid rgba(59, 117, 188, .14);
    padding: 5px 14px;
    border-radius: 999px;
}
.hero h1 {
    margin: 16px 0 10px;
    font-size: 34px;
    line-height: 1.35;
    letter-spacing: 1px;
    color: var(--brand-deep);
    font-weight: 800;
}
.hero h1 em {
    font-style: normal;
    background: linear-gradient(100deg, var(--brand), #5d9ad9 70%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.hero-sub {
    margin: 0;
    color: var(--ink-2);
    font-size: 14.5px;
}
.hero-sub b { color: var(--brand-dark); font-weight: 700; }
.hero-sub .dot { color: #c3d2e4; margin: 0 10px; }

/* 搜索面板 */
.search-panel {
    background: #fff;
    border: 1px solid #e6edf6;
    border-radius: 18px;
    box-shadow: var(--shadow);
    padding: 26px 28px 22px;
}
.search-grid {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1fr 1fr auto;
    gap: 14px;
    align-items: end;
}
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field label {
    font-size: 12.5px;
    color: var(--muted);
    letter-spacing: .4px;
    padding-left: 2px;
}
.field label b { color: var(--ink-2); font-weight: 600; }
.field label small { margin-left: 6px; font-size: 11px; color: #99a6b8; letter-spacing: 0; }
.field-tip { display: none; margin: 0; padding-left: 2px; font-size: 11.5px; line-height: 1.5; color: #93a2b4; }
.input, .select {
    height: 46px;
    width: 100%;
    border: 1px solid #d9e2ef;
    border-radius: var(--radius-sm);
    padding: 0 14px;
    font-size: 14.5px;
    font-family: inherit;
    color: var(--ink);
    background: #fff;
    transition: border-color .16s, box-shadow .16s;
    outline: none;
}
.input::placeholder { color: #a9b6c6; }
.input:focus::placeholder { color: transparent; }
.input:hover, .select:hover { border-color: #bfd2e8; }
.input:focus, .select:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(59, 117, 188, .13);
}
.select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2377869a' d='M1.4 0 6 4.6 10.6 0 12 1.4 6 7.4 0 1.4z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 34px;
}
.search-actions { display: flex; gap: 10px; }

.search-note {
    margin: 14px 0 0;
    font-size: 12.5px;
    color: var(--muted);
    line-height: 1.7;
}
.search-note b { color: var(--brand-dark); }

.search-memory {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12.5px;
    color: var(--muted);
}
.search-memory form { display: inline; margin: 0; }
.search-memory .link-action {
    border: 0;
    background: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
}

.search-hint {
    margin-top: 16px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 13px;
    color: var(--muted);
}
.tag-link {
    display: inline-flex;
    align-items: center;
    height: 28px;
    padding: 0 11px;
    border-radius: 999px;
    background: var(--brand-soft-2);
    border: 1px solid #e2ebf7;
    color: var(--brand-dark);
    font-size: 12.5px;
    transition: all .15s;
}
.tag-link:hover { background: var(--brand); border-color: var(--brand); color: #fff; }

/* ---------------- 主体两栏 ---------------- */

.layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 318px;
    gap: 26px;
    align-items: start;
    padding-top: 30px;
    padding-bottom: 56px;
}

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 24px 18px;
    border-bottom: 1px solid var(--line);
    flex-wrap: wrap;
}
.card-head h2 {
    margin: 0;
    font-size: 19px;
    font-weight: 700;
    color: var(--brand-deep);
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: .3px;
}
.card-head h2::before {
    content: "";
    width: 4px;
    height: 19px;
    border-radius: 3px;
    background: linear-gradient(180deg, var(--brand), #6ba3dd);
}
.card-head h2 small {
    font-size: 12.5px;
    font-weight: 400;
    color: var(--muted);
    letter-spacing: 0;
}
.card-head .head-tools { display: flex; align-items: center; gap: 10px; }

.result-summary {
    padding: 14px 24px;
    background: var(--brand-soft-2);
    border-bottom: 1px solid var(--line);
    font-size: 13.5px;
    color: var(--ink-2);
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.result-summary b { color: var(--brand-dark); font-size: 15px; }
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1px solid #d8e4f3;
    color: var(--brand-dark);
    border-radius: 999px;
    padding: 2px 10px;
    font-size: 12.5px;
}
.filter-chip i { font-style: normal; color: var(--muted); }

/* 表格 */
.table-scroll { overflow-x: auto; }
table.data {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 14px;
}
table.data thead th {
    background: #f4f8fd;
    color: #5a6c80;
    font-weight: 600;
    font-size: 12.5px;
    letter-spacing: .3px;
    text-align: left;
    padding: 13px 12px;
    border-bottom: 1px solid var(--line);
    white-space: nowrap;
}
table.data thead th:first-child { padding-left: 24px; }
table.data thead th:last-child { padding-right: 24px; text-align: right; }
table.data tbody td {
    padding: 15px 12px;
    border-bottom: 1px solid #eef2f8;
    color: var(--ink-2);
    vertical-align: middle;
}
table.data tbody td:first-child { padding-left: 24px; }
table.data tbody td:last-child { padding-right: 24px; text-align: right; }
table.data tbody tr:hover td { background: #fafcff; }
table.data tbody tr:last-child td { border-bottom: 0; }

.grade-cell { min-width: 158px; }
.grade-cell .g {
    display: inline-block;
    font-weight: 700;
    color: var(--brand-deep);
    font-size: 15px;
    letter-spacing: .3px;
}
.grade-cell .p {
    display: block;
    font-size: 12px;
    color: var(--muted);
    margin-top: 1px;
}

/* 桌面端结果表：固定列宽，压缩牌号与规格列间距，保证操作列完整可见 */
@media (min-width: 721px) {
    .page-home .product-table { table-layout: fixed; }
    .page-home .product-table thead th { white-space: normal; padding: 12px 8px; line-height: 1.35; }
    .page-home .product-table thead th:first-child { padding-left: 16px; }
    .page-home .product-table thead th:last-child { padding-right: 12px; }
    .page-home .product-table tbody td { padding: 14px 8px; }
    .page-home .product-table tbody td:first-child { padding-left: 16px; }
    .page-home .product-table tbody td:last-child { padding-right: 12px; }

    .page-home .product-table th:nth-child(1) { width: 15%; }
    .page-home .product-table th:nth-child(2) { width: 8.5%; }
    .page-home .product-table th:nth-child(3) { width: 8.5%; }
    .page-home .product-table th:nth-child(4) { width: 9%; }
    .page-home .product-table th:nth-child(5) { width: 5.5%; }
    .page-home .product-table th:nth-child(6) { width: 9%; }
    .page-home .product-table th:nth-child(7) { width: 7.5%; }
    .page-home .product-table th:nth-child(8) { width: 7.5%; }
    .page-home .product-table th:nth-child(9) { width: 14.5%; }
    .page-home .product-table th:nth-child(10) { width: 15%; }

    .page-home .product-table .grade-cell { min-width: 0; }
    .page-home .product-table .grade-cell .g { max-width: 100%; overflow-wrap: anywhere; }
    .page-home .product-table .origin-pill { padding: 1px 6px; }
    .page-home .product-table .remark-text { max-width: 100%; }
    .page-home .product-table .row-actions {
        flex-direction: column;
        align-items: flex-end;
        justify-content: flex-start;
        gap: 4px;
    }
}
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.num em { font-style: normal; color: #a4b2c4; font-size: 11.5px; margin-left: 2px; }
.muted { color: var(--muted); }
.remark-text { color: #5f7188; font-size: 13px; max-width: 130px; display: inline-block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; }
.origin-pill {
    display: inline-block;
    padding: 1px 9px;
    border-radius: 6px;
    background: #f0f5fb;
    color: #47637f;
    font-size: 12.5px;
    white-space: nowrap;
}
.storage-text {
    display: block;
    margin-top: 4px;
    font-size: 11.5px;
    color: #8797a9;
    line-height: 1.5;
}
.link-complain {
    font-size: 12.5px;
    color: #b0574a;
    text-decoration: none;
    white-space: nowrap;
}
.link-complain:hover { color: #8f3a2d; text-decoration: underline; }
.pin-badge {
    display: inline-block;
    margin-right: 6px;
    padding: 0 7px;
    border-radius: 5px;
    background: #fff2e6;
    border: 1px solid #f6dcc0;
    color: #b4741c;
    font-size: 11px;
    font-weight: 600;
    line-height: 18px;
    vertical-align: 1px;
}
tr.pin-row { background: #fffcf6; }
tr.pin-row:hover { background: #fff8ee; }
.btn-view {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 30px;
    padding: 0 12px;
    border-radius: 8px;
    border: 1px solid #cfe0f2;
    background: #fff;
    color: var(--brand);
    font-size: 13px;
    cursor: pointer;
    transition: all .15s;
    white-space: nowrap;
}
.btn-view:hover { background: var(--brand); border-color: var(--brand); color: #fff; }

.empty {
    padding: 64px 24px;
    text-align: center;
    color: var(--muted);
}
.empty .empty-ico {
    width: 54px; height: 54px;
    margin: 0 auto 14px;
    border-radius: 16px;
    background: var(--brand-soft);
    display: flex; align-items: center; justify-content: center;
}
.empty p { margin: 0 0 14px; font-size: 14px; }

/* 分页 */
.pager {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 18px 24px;
    border-top: 1px solid var(--line);
    flex-wrap: wrap;
}
.page-btn {
    min-width: 36px;
    height: 34px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid #dbe5f1;
    background: #fff;
    color: var(--ink-2);
    font-size: 13.5px;
    transition: all .15s;
}
.page-btn:hover { border-color: var(--brand); color: var(--brand); }
.page-btn.active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.page-btn.disabled { color: #b8c4d3; background: #fafbfd; cursor: not-allowed; }
.page-info { margin-left: auto; font-size: 12.5px; color: var(--muted); }

/* ---------------- 侧栏 ---------------- */

.sidebar { display: flex; flex-direction: column; gap: 22px; position: sticky; top: 96px; }

.side-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 20px 22px 22px;
}
.side-card h3 {
    margin: 0 0 4px;
    font-size: 16px;
    color: var(--brand-deep);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
}
.side-card h3 .h3-ico {
    width: 28px; height: 28px;
    border-radius: 9px;
    background: var(--brand-soft);
    color: var(--brand);
    display: inline-flex; align-items: center; justify-content: center;
}
.side-card .side-sub {
    font-size: 12px;
    color: var(--muted);
    margin: 0 0 12px;
    letter-spacing: .3px;
}

.hot-list { list-style: none; margin: 0; padding: 0; }
.hot-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    margin: 0 -6px;
    border-radius: 9px;
    transition: background .15s;
}
.hot-item:hover { background: var(--brand-soft-2); }
.hot-rank {
    width: 22px; height: 22px;
    flex: 0 0 22px;
    border-radius: 7px;
    background: #f1f4f9;
    color: #7f8fa3;
    font-size: 12px;
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    font-variant-numeric: tabular-nums;
}
.hot-item:nth-child(1) .hot-rank { background: linear-gradient(140deg,#e8573f,#d83c25); color:#fff; }
.hot-item:nth-child(2) .hot-rank { background: linear-gradient(140deg,#f0973f,#e07f22); color:#fff; }
.hot-item:nth-child(3) .hot-rank { background: linear-gradient(140deg,#e8b83f,#d8a322); color:#fff; }
.hot-name {
    flex: 1;
    min-width: 0;
    font-size: 13.8px;
    color: var(--ink);
    font-weight: 600;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.hot-count { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.hot-count b { color: var(--brand); font-weight: 600; }

.vip-card {
    background: linear-gradient(150deg, #4a86cb 0%, #3b75bc 45%, #244a78 100%);
    border: 0;
    color: #fff;
    position: relative;
    overflow: hidden;
}
.vip-card::after {
    content: "";
    position: absolute;
    width: 220px; height: 220px;
    right: -80px; top: -100px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .1);
}
.vip-card h3 { color: #fff; }
.vip-card h3 .h3-ico { background: rgba(255, 255, 255, .16); color: #fff; }
.vip-card .side-sub { color: rgba(255, 255, 255, .8); }
.vip-card p { margin: 0 0 14px; font-size: 13.5px; color: rgba(255, 255, 255, .88); line-height: 1.8; }
.wechat-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: rgba(255, 255, 255, .14);
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 10px;
    padding: 9px 12px;
    margin-bottom: 14px;
}
.wechat-box .wx-label { font-size: 11.5px; letter-spacing: 1px; color: rgba(255,255,255,.8); }
.wechat-box .wx-num {
    font-family: ui-monospace, Menlo, Consolas, monospace;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1.2px;
    color: #fff;
}
.stat-row {
    display: flex;
    gap: 10px;
    margin-top: 16px;
    border-top: 1px solid rgba(255,255,255,.18);
    padding-top: 14px;
}
.stat-row div { flex: 1; }
.stat-row b { display: block; font-size: 19px; letter-spacing: .5px; }
.stat-row span { font-size: 11.5px; color: rgba(255,255,255,.75); }

/* ---------------- 模态框 ---------------- */

.modal-mask {
    position: fixed;
    inset: 0;
    background: rgba(23, 37, 54, .5);
    backdrop-filter: blur(3px);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 100;
}
.modal-mask.show { display: flex; }
.modal {
    width: 100%;
    max-width: 430px;
    background: #fff;
    border-radius: 18px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    animation: pop .18s ease;
}
@keyframes pop { from { transform: translateY(8px) scale(.98); opacity: 0 } to { transform: none; opacity: 1 } }
.modal-head {
    padding: 18px 22px;
    background: linear-gradient(120deg, #f4f8fd, #fff);
    border-bottom: 1px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.modal-head h4 { margin: 0; font-size: 16.5px; color: var(--brand-deep); }
.modal-close {
    width: 30px; height: 30px;
    border: 0; background: #f0f4fa; border-radius: 8px;
    color: var(--muted); font-size: 17px; cursor: pointer; line-height: 1;
}
.modal-close:hover { background: #e6edf7; color: var(--ink); }
.modal-body { padding: 22px; }
.modal-foot { padding: 0 22px 22px; }

.info-list { margin: 0; }
.info-row {
    display: flex;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px dashed #e8eef7;
    font-size: 14.5px;
}
.info-row:last-child { border-bottom: 0; }
.info-row .k { width: 74px; flex: 0 0 74px; color: var(--muted); font-size: 13px; }
.info-row .v { flex: 1; color: var(--ink); font-weight: 600; word-break: break-all; }
.info-row .v.phone { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 17px; color: var(--brand); letter-spacing: .6px; }

.gate {
    text-align: center;
    padding: 6px 4px 2px;
}
.gate .gate-ico {
    width: 56px; height: 56px;
    margin: 0 auto 12px;
    border-radius: 16px;
    background: var(--brand-soft);
    display: flex; align-items: center; justify-content: center;
    color: var(--brand);
}
.gate h5 { margin: 0 0 8px; font-size: 16px; color: var(--ink); }
.gate p { margin: 0 0 16px; font-size: 13px; color: var(--muted); line-height: 1.8; }
.gate .gate-wx {
    display: flex; align-items: center; justify-content: space-between;
    background: var(--brand-soft-2);
    border: 1px dashed #c9dbf0;
    border-radius: 10px;
    padding: 10px 14px;
    margin-bottom: 14px;
}
.gate .gate-wx .wx-num { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 18px; font-weight: 700; color: var(--brand-dark); letter-spacing: 1px; }

.toast {
    position: fixed;
    left: 50%;
    bottom: 40px;
    transform: translate(-50%, 20px);
    background: rgba(31, 42, 55, .92);
    color: #fff;
    padding: 10px 18px;
    border-radius: 10px;
    font-size: 13.5px;
    opacity: 0;
    transition: all .22s ease;
    pointer-events: none;
    z-index: 200;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------------- 页脚 ---------------- */

.site-footer {
    background: #22344a;
    color: #a9bbd0;
    padding: 46px 0 0;
    font-size: 13.5px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr 1.2fr;
    gap: 32px;
    padding-bottom: 34px;
}
.footer-grid h4 { color: #fff; font-size: 15px; margin: 0 0 12px; font-weight: 600; letter-spacing: .5px; }
.footer-grid p { margin: 0 0 8px; line-height: 1.9; color: #9fb2c8; }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.footer-brand .brand-mark { width: 36px; height: 36px; font-size: 18px; box-shadow: none; background: rgba(255,255,255,.12); }
.footer-brand strong { color: #fff; font-size: 18px; letter-spacing: 1px; }
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .09);
    padding: 16px 0 22px;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    font-size: 12.5px;
    color: #8199b3;
}

/* ---------------- 登录页 ---------------- */

.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    background:
        radial-gradient(700px 400px at 15% 10%, #e4effb, transparent 70%),
        radial-gradient(600px 400px at 90% 90%, #e9f1fb, transparent 70%),
        var(--bg);
}
.auth-card {
    width: 100%;
    max-width: 420px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
    box-shadow: var(--shadow);
    padding: 34px 34px 30px;
}
.auth-card .auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.auth-card h2 { margin: 0 0 4px; font-size: 20px; color: var(--brand-deep); }
.auth-card .auth-sub { margin: 0 0 24px; font-size: 13px; color: var(--muted); }
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-form .field label { font-size: 13px; color: var(--ink-2); }
.captcha-row { display: flex; gap: 10px; align-items: center; }
.captcha-row .input { flex: 1; }
.captcha-img {
    height: 46px;
    width: 120px;
    border-radius: 10px;
    border: 1px solid #d9e2ef;
    cursor: pointer;
    flex: 0 0 auto;
    background: #f7fafd;
}
.captcha-code {
    height: 46px;
    min-width: 120px;
    padding: 0 12px;
    box-sizing: border-box;
    border: 1px solid #d9e2ef;
    border-radius: 10px;
    background: #f7fafd;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    color: #106ebe;
    font: 700 24px/1 Consolas, "Courier New", monospace;
    letter-spacing: 5px;
    text-indent: 5px;
    user-select: none;
}
.captcha-tip { margin: 2px 0 0; font-size: 11.5px; color: #93a2b4; }
.auth-card .btn-lg { width: 100%; }
.auth-foot { margin-top: 18px; font-size: 12.5px; color: var(--muted); text-align: center; line-height: 1.9; }

.alert {
    border-radius: 10px;
    padding: 10px 14px;
    font-size: 13.5px;
    margin-bottom: 16px;
    line-height: 1.7;
}
.alert-error { background: #fdeeee; border: 1px solid #f6d3d0; color: #a63a2f; }
.alert-success { background: #edf8f1; border: 1px solid #cfe9da; color: #21794c; }

/* ---------------- 会员中心 ---------------- */

.toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 16px 24px;
    border-bottom: 1px solid var(--line);
    background: #fff;
}
.toolbar .input, .toolbar .select { height: 38px; font-size: 13.5px; width: auto; min-width: 120px; }
.toolbar .spacer { flex: 1; }

table.data .row-actions { display: inline-flex; gap: 6px; justify-content: flex-end; }
.link-action { font-size: 13px; color: var(--brand); }
.link-action.danger { color: #c04a3d; }
.link-action:hover { text-decoration: underline; }

.form-page { padding: 24px; }
.form-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px 20px; }
.form-grid .col-full { grid-column: 1 / -1; }
.form-actions { display: flex; gap: 12px; padding-top: 8px; margin-top: 6px; border-top: 1px dashed #e6ecf5; padding-top: 20px; }

/* 会员导入 / 导出页复用的小组件 */
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.stat-card {
    background: #fff;
    border: 1px solid #e6edf6;
    border-radius: 12px;
    padding: 16px 18px;
}
.stat-card .s-body b { display: block; font-size: 24px; line-height: 1.3; color: var(--brand-dark); font-variant-numeric: tabular-nums; }
.stat-card .s-body span { font-size: 12.5px; color: var(--muted); }

.upload-box {
    border: 1.5px dashed #cfdcee;
    border-radius: 14px;
    background: #f9fbfe;
    padding: 24px 20px;
    text-align: center;
}
.upload-box .u-ico { color: var(--brand); margin-bottom: 8px; }
.upload-box p { margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.upload-box input[type="file"] { font-size: 13px; color: var(--ink-2); }

@media (max-width: 720px) {
    .stat-grid { grid-template-columns: 1fr; }
}

/* ---------------- 响应式 ---------------- */

@media (max-width: 1120px) {
    .layout { grid-template-columns: minmax(0, 1fr) 290px; gap: 20px; }
    .search-grid { grid-template-columns: 1.8fr 1fr 1fr 1fr; }
    .search-grid .field-actions { grid-column: span 2; }
    .search-actions { justify-content: flex-end; }
}

@media (max-width: 960px) {
    .nav { display: none; }
    .layout { grid-template-columns: 1fr; }
    .sidebar { position: static; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .form-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
    .wrap { padding: 0 16px; }
    .hero { padding: 38px 0 32px; }
    .hero h1 { font-size: 25px; }
    .hero-sub { font-size: 13px; }
    .search-panel { padding: 18px 18px 16px; border-radius: 14px; }
    .search-grid { grid-template-columns: 1fr 1fr; }
    .search-grid .field-grade, .search-grid .field-actions { grid-column: 1 / -1; }
    .search-actions .btn { flex: 1; }
    .site-header .wrap { min-height: 62px; gap: 12px; }
    .brand-text strong { font-size: 18px; }
    .header-actions .btn-ghost { display: none; }
    .card-head { padding: 16px 16px 14px; }
    table.data thead th:first-child, table.data tbody td:first-child { padding-left: 16px; }
    table.data thead th:last-child, table.data tbody td:last-child { padding-right: 16px; }
    .pager { padding: 14px 16px; }
    .page-info { width: 100%; margin-left: 0; }
    .footer-grid { grid-template-columns: 1fr; gap: 22px; }
    .form-grid { grid-template-columns: 1fr; }
    .topbar .tb-left { display: none; }
    .topbar .wrap { justify-content: center; }
}

@media (max-width: 420px) {
    .search-grid { grid-template-columns: 1fr; }
}

/* ---------- 移动端首页：仅站名 + 搜索栏 ---------- */
.mobile-brand { display: none; }

@media (max-width: 720px) {
    .page-home .topbar,
    .page-home .site-header,
    .page-home .site-footer {
        display: none !important;
    }

    .mobile-brand {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        padding: 26px 16px 6px;
    }
    .mobile-brand .brand-mark {
        width: 38px;
        height: 38px;
        font-size: 19px;
        border-radius: 11px;
    }
    .mobile-brand strong {
        font-size: 24px;
        font-weight: 800;
        letter-spacing: 1px;
        color: var(--brand-deep);
    }
    .mobile-brand strong span { color: var(--brand); }

    .page-home .hero {
        padding: 10px 0 22px;
        background: transparent;
        overflow: visible;
    }
    .page-home .hero::after { display: none; }
    .page-home .hero-head { display: none; }
    .page-home .search-note,
    .page-home .search-hint { display: none; }
    .page-home .search-panel {
        margin: 0;
        border: 1px solid #e2eaf4;
        box-shadow: 0 8px 26px rgba(31, 56, 88, .08);
    }
    .page-home .search-grid { grid-template-columns: 1fr; }
    .page-home .search-grid label { display: block; font-size: 13px; color: var(--ink-2); padding-left: 2px; }
    .page-home .search-grid .field-tip { display: block; }
    .page-home .search-grid .field-actions label { display: none; }

    /* 无查询条件时，首页不展示推荐列表、搜索榜与会员卡片 */
    .page-home.home-landing .layout { display: none; }
    .page-home .sidebar { display: none; }

    /* 查询结果在手机上改为卡片式，避免表格横向溢出 */
    .page-home .product-table { display: block; width: 100%; }
    .page-home .product-table thead { display: none; }
    .page-home .product-table tbody { display: block; width: 100%; }
    .page-home .product-table tbody tr {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px 12px;
        padding: 14px 16px;
        border-bottom: 1px solid #eef2f8;
    }
    .page-home .product-table tbody tr:last-child { border-bottom: 0; }
    .page-home .product-table tbody td {
        display: block;
        min-width: 0;
        padding: 0 !important;
        border: 0 !important;
        text-align: left !important;
        background: transparent !important;
    }
    .page-home .product-table td.grade-cell {
        grid-column: 1 / -1;
        min-width: 0;
        display: flex;
        flex-wrap: wrap;
        align-items: baseline;
        gap: 4px 8px;
    }
    .page-home .product-table td.grade-cell .p { width: 100%; margin-top: 0; }
    .page-home .product-table td[data-label]::before {
        content: attr(data-label);
        display: block;
        margin-bottom: 2px;
        font-size: 11px;
        color: #8a99ad;
        line-height: 1.4;
        white-space: nowrap;
    }
    .page-home .product-table td:nth-child(7),
    .page-home .product-table td:nth-child(8),
    .page-home .product-table td:nth-child(9),
    .page-home .product-table td:last-child { grid-column: 1 / -1; }
    .page-home .product-table .remark-text {
        max-width: none;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
    }
    .page-home .product-table .storage-text { display: block; margin-top: 4px; }
    .page-home .product-table tbody td:last-child { padding-top: 2px !important; }
    .page-home .product-table .row-actions { justify-content: flex-start !important; }
    .page-home .product-table .row-actions .btn-view { flex: 0 0 auto; }
}

@media (max-width: 420px) {
    .page-home .product-table tbody tr { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mobile-brand strong { font-size: 21px; }
}

.share-page { max-width: 1180px; }
.share-hero {
    display: flex; justify-content: space-between; align-items: center; gap: 24px;
    background: linear-gradient(120deg, #2f66ad 0%, #3b75bc 55%, #4d8bd0 100%);
    color: #fff; border-radius: 16px; padding: 26px 30px;
    box-shadow: 0 12px 30px rgba(47, 102, 173, .22);
}
.share-badge {
    display: inline-block; font-size: 12px; letter-spacing: 1px;
    background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.28);
    border-radius: 999px; padding: 3px 10px; margin-bottom: 10px;
}
.share-hero h1 { font-size: 27px; margin: 0 0 8px; font-weight: 700; letter-spacing: .5px; }
.share-sub { margin: 0; font-size: 13px; color: rgba(255,255,255,.82); }
.share-sub b { color: #fff; }
.share-sub span { margin: 0 8px; color: rgba(255,255,255,.4); }
.share-hero-side { text-align: right; flex-shrink: 0; }
.share-hotline-label { display: block; font-size: 12px; color: rgba(255,255,255,.75); letter-spacing: 1px; }
.share-hotline {
    display: block; font-size: 26px; font-weight: 800; color: #fff;
    text-decoration: none; line-height: 1.3; letter-spacing: .5px;
}
.share-btns { display: flex; gap: 8px; justify-content: flex-end; margin-top: 10px; }
.share-btns .btn-primary { background: #fff; color: #2f66ad; border-color: #fff; }
.share-btns .btn-primary:hover { background: #eef5ff; }
.share-btns .btn-ghost { color: #fff; border-color: rgba(255,255,255,.45); background: rgba(255,255,255,.08); }
.share-btns .btn-ghost:hover { background: rgba(255,255,255,.16); }

.share-search { margin-top: 18px; padding: 16px 18px 12px; }
.share-search-form { display: flex; gap: 10px; align-items: center; }
.share-search-form .input { flex: 1; height: 44px; }
.share-search-form .btn { height: 44px; }
.share-search-tip { margin: 10px 2px 0; font-size: 12.5px; color: #77869a; }

.share-list { margin-top: 18px; }

.share-link-box {
    display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
    background: #f7fafd; border: 1px solid #e6edf6; border-radius: 12px; padding: 14px 16px;
}
.share-link-label { font-size: 13px; color: #5f7188; font-weight: 600; }
.share-link-box .input { flex: 1; min-width: 260px; background: #fff; }
.share-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.share-tip-mask {
    position: fixed; inset: 0; background: rgba(18, 32, 51, .45);
    display: none; align-items: center; justify-content: center; z-index: 900; padding: 20px;
}
.share-tip-mask.show { display: flex; }
.share-tip-box {
    background: #fff; border-radius: 14px; padding: 24px 26px; max-width: 460px; width: 100%;
    box-shadow: 0 18px 50px rgba(18, 32, 51, .28);
}
.share-tip-box h3 { margin: 0 0 12px; font-size: 17px; color: #1f2f45; }
.share-tip-box p { margin: 0; font-size: 13.5px; color: #5f7188; line-height: 1.95; }

@media (max-width: 860px) {
    .share-hero { flex-direction: column; align-items: flex-start; padding: 22px 20px; }
    .share-hero-side { text-align: left; width: 100%; }
    .share-btns { justify-content: flex-start; }
}
@media (max-width: 720px) {
    .share-search-form { flex-wrap: wrap; }
    .share-search-form .input { flex: 1 1 100%; }
    .share-link-box .input { min-width: 0; flex: 1 1 100%; }
    .share-page { padding-top: 16px !important; }
}

.footer-free { color: #ffffff; font-weight: 600; }

