/* =========================================================
   海淀区无证无照经营整治项目调查问卷
   H5 问卷 + 管理后台样式
   ========================================================= */

:root {
    --brand: #0b4f9c;
    --brand-2: #1c74cf;
    --brand-soft: #eef5ff;
    --accent: #0f9f8f;
    --ink: #16233a;
    --muted: #667085;
    --muted-2: #98a2b3;
    --line: #e3e9f2;
    --bg: #f2f5fa;
    --card: #ffffff;
    --danger: #d92d20;
    --danger-soft: #fef3f2;
    --warn: #b54708;
    --warn-soft: #fffaeb;
    --ok: #067647;
    --ok-soft: #ecfdf3;
    --radius: 16px;
    --shadow: 0 10px 30px rgba(16, 24, 40, .06);
}

* { box-sizing: border-box; }

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

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

a { color: var(--brand); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
img { max-width: 100%; display: block; }
code { background: #f3f5f9; padding: 1px 5px; border-radius: 5px; }

/* ---------------- H5 问卷 ---------------- */

.h5-body {
    background:
        radial-gradient(1100px 420px at 50% -120px, #dfeafb 0%, rgba(223, 234, 251, 0) 70%),
        var(--bg);
}

.h5-shell {
    width: 100%;
    max-width: 640px;
    margin: 0 auto;
    position: relative;
}

.hero {
    position: relative;
    overflow: hidden;
    padding: 22px 20px 30px;
    border-radius: 0 0 26px 26px;
    color: #fff;
    background: linear-gradient(135deg, #08376e 0%, #0b4f9c 46%, #1976c9 100%);
    box-shadow: 0 16px 34px rgba(8, 55, 110, .22);
}

.hero-deco {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, .08);
    pointer-events: none;
}
.hero-deco-1 { width: 190px; height: 190px; right: -70px; top: -70px; }
.hero-deco-2 { width: 120px; height: 120px; right: 64px; bottom: -86px; background: rgba(15, 159, 143, .28); }

.hero-top {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    font-size: 12px;
}
.hero-badge {
    display: inline-flex;
    align-items: center;
    height: 23px;
    padding: 0 9px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .18);
    border: 1px solid rgba(255, 255, 255, .28);
    font-weight: 600;
    letter-spacing: .5px;
}
.hero-org { opacity: .82; }

.hero h1 {
    position: relative;
    margin: 16px 0 8px;
    font-size: 25px;
    line-height: 1.4;
    letter-spacing: .5px;
    font-weight: 700;
}
.hero-desc {
    position: relative;
    margin: 0;
    font-size: 13px;
    line-height: 1.7;
    color: rgba(255, 255, 255, .82);
}
.hero-desc b { color: #ffd48a; }
.hero-meta {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    font-size: 12px;
    color: rgba(255, 255, 255, .72);
}
.hero-meta i { width: 3px; height: 3px; border-radius: 50%; background: rgba(255, 255, 255, .5); }

.survey-form {
    display: grid;
    gap: 14px;
    padding: 16px 14px 0;
}

.card {
    background: var(--card);
    border: 1px solid rgba(227, 233, 242, .9);
    border-radius: 18px;
    padding: 18px 16px 20px;
    box-shadow: var(--shadow);
}

.sec-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 1px dashed var(--line);
}
.sec-no {
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .5px;
    box-shadow: 0 6px 14px rgba(11, 79, 156, .24);
}
.sec-head h2 { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: .3px; }
.sec-head p { margin: 3px 0 0; font-size: 12px; color: var(--muted); }

.field { margin-top: 20px; }
.field:first-of-type { margin-top: 18px; }

.label {
    display: flex;
    align-items: center;
    gap: 3px;
    margin: 0 0 9px;
    font-size: 14px;
    font-weight: 600;
    color: #253858;
    line-height: 1.5;
}
.req { color: var(--danger); font-style: normal; font-weight: 700; margin-left: 1px; }

.hint {
    margin: 7px 0 0;
    font-size: 12px;
    line-height: 1.65;
    color: var(--muted);
}

.err {
    margin: 6px 0 0;
    font-size: 12px;
    color: var(--danger);
    line-height: 1.5;
}
.err:empty { display: none; }

.input {
    display: block;
    width: 100%;
    height: 48px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fbfcfe;
    color: var(--ink);
    font-size: 16px;
    outline: none;
    transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
    -webkit-appearance: none;
    appearance: none;
}
.input::placeholder { color: var(--muted-2); }
.input:focus {
    border-color: var(--brand);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(11, 79, 156, .10);
}
.input.is-invalid {
    border-color: #f04438;
    background: var(--danger-soft);
}
.textarea {
    height: auto;
    min-height: 96px;
    padding: 12px 14px;
    line-height: 1.65;
    resize: vertical;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    gap: 12px;
}
.grid-2 .field { margin-top: 20px; }

/* 单选列表 */
.opts { display: grid; gap: 8px; }
.opt { position: relative; display: block; cursor: pointer; }
.opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.opt-inner {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 46px;
    padding: 10px 13px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fbfcfe;
    transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.opt-text { font-size: 14px; line-height: 1.45; }
.dot {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 1.5px solid #c5cfdd;
    background: #fff;
    position: relative;
    transition: border-color .18s ease;
}
.dot::after {
    content: "";
    position: absolute;
    inset: 3px;
    border-radius: 50%;
    background: var(--brand);
    transform: scale(0);
    transition: transform .16s ease;
}
.opt input:checked + .opt-inner {
    border-color: var(--brand);
    background: var(--brand-soft);
    box-shadow: inset 0 0 0 1px var(--brand);
}
.opt input:checked + .opt-inner .dot { border-color: var(--brand); }
.opt input:checked + .opt-inner .dot::after { transform: scale(1); }
.opt input:focus-visible + .opt-inner { box-shadow: 0 0 0 4px rgba(11, 79, 156, .12); }
.opts.is-invalid .opt-inner { border-color: #f04438; }
.opts.is-invalid .opt:first-child .opt-inner { background: #fff7f6; }

/* 分段选择 */
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; }
.seg label { position: relative; display: block; cursor: pointer; }
.seg input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.seg span {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 44px;
    padding: 0 8px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: #fbfcfe;
    font-size: 14px;
    color: #344054;
    transition: border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}
.seg input:checked + span {
    border-color: var(--brand);
    background: var(--brand-soft);
    color: var(--brand);
    font-weight: 600;
    box-shadow: inset 0 0 0 1px var(--brand);
}
.seg input:focus-visible + span { box-shadow: 0 0 0 4px rgba(11, 79, 156, .12); }
.seg.is-invalid span { border-color: #f04438; }
.seg.is-locked { opacity: .62; pointer-events: none; }
.seg-count { grid-auto-columns: 1fr; gap: 6px; }
.seg-count span { height: 40px; font-size: 12px; border-radius: 10px; }

/* 下拉 */
.select-wrap { position: relative; margin-top: 8px; }
.select-wrap::after {
    content: "";
    position: absolute;
    right: 15px;
    top: 50%;
    width: 9px;
    height: 9px;
    border-right: 1.6px solid #8b97a8;
    border-bottom: 1.6px solid #8b97a8;
    transform: translateY(-70%) rotate(45deg);
    pointer-events: none;
}
.select { padding-right: 40px; }
.select:disabled { color: var(--muted-2); background: #f5f7fa; }

/* 图片上传 */
.upload-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 12px;
}
.upload-slot {
    position: relative;
    height: 0;
    padding-top: 100%;
    border: 1.5px dashed #c7d2e0;
    border-radius: 14px;
    background: #fbfcfe;
    overflow: hidden;
}
@supports (aspect-ratio: 1 / 1) {
    .upload-slot {
        height: auto;
        padding-top: 0;
        aspect-ratio: 1 / 1;
    }
}
.upload-slot.is-filled { border-style: solid; border-color: #cfdae8; }
.slot-input {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}
.slot-empty {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    text-align: center;
    color: var(--muted);
    padding: 10px;
}
.slot-empty svg { width: 26px; height: 26px; color: #91a4bf; }
.slot-empty b { font-size: 13px; color: #41546f; font-weight: 600; }
.slot-empty small { font-size: 11px; color: var(--muted-2); }
.slot-preview {
    position: absolute;
    inset: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}
.upload-slot.is-filled .slot-preview { display: block; }
.upload-slot.is-filled .slot-empty { display: none; }
.slot-badge {
    position: absolute;
    left: 8px;
    top: 8px;
    z-index: 4;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    display: none;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(17, 24, 39, .62);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
}
.upload-slot.is-filled .slot-badge { display: inline-flex; }
.slot-remove {
    position: absolute;
    right: 7px;
    top: 7px;
    z-index: 5;
    width: 26px;
    height: 26px;
    display: none;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .94);
    color: var(--danger);
    font-size: 18px;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(16, 24, 40, .18);
    cursor: pointer;
}
.upload-slot.is-filled .slot-remove { display: flex; }

.form-tip {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin: 2px 2px 0;
    padding: 12px 14px;
    border-radius: 12px;
    background: #eef5ff;
    color: #365a86;
    font-size: 12px;
    line-height: 1.6;
}
.tip-icon {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    margin-top: 1px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--brand);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
}

/* 底部提交栏 */
.submit-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    width: 100%;
    max-width: 640px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, .94);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}
.submit-meta { min-width: 0; }
.submit-meta b { display: block; font-size: 13px; color: #253858; }
.submit-meta span { display: block; font-size: 11px; color: var(--muted-2); margin-top: 1px; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 44px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 11px;
    background: #fff;
    color: var(--ink);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform .12s ease, box-shadow .18s ease, background .18s ease;
    white-space: nowrap;
}
.btn:active { transform: scale(.985); }
.btn-primary {
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    color: #fff;
    border: 0;
    box-shadow: 0 9px 20px rgba(11, 79, 156, .26);
}
.btn-primary:hover { box-shadow: 0 11px 24px rgba(11, 79, 156, .32); }
.btn-primary:disabled { opacity: .65; box-shadow: none; cursor: not-allowed; }
.btn-block { width: 100%; }
.submit-bar .btn { min-width: 138px; height: 46px; border-radius: 12px; }

.page-bottom-space { height: calc(86px + env(safe-area-inset-bottom)); }

/* 成功页 */
.success-view {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    overflow: auto;
    background:
        radial-gradient(700px 320px at 50% 0%, #e2eefb 0%, rgba(226, 238, 251, 0) 70%),
        var(--bg);
}
.success-view[hidden] { display: none; }
.success-card {
    width: 100%;
    max-width: 420px;
    padding: 34px 24px 24px;
    text-align: center;
    background: #fff;
    border-radius: 22px;
    box-shadow: 0 24px 60px rgba(16, 24, 40, .12);
}
.success-check svg { width: 68px; height: 68px; margin: 0 auto; }
.success-check circle {
    fill: #ecfdf3;
    stroke: #12b76a;
    stroke-width: 2.5;
    stroke-dasharray: 160;
    stroke-dashoffset: 160;
    animation: draw-circle .55s ease forwards;
}
.success-check path {
    fill: none;
    stroke: #12b76a;
    stroke-width: 3.2;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 40;
    stroke-dashoffset: 40;
    animation: draw-check .35s .45s ease forwards;
}
@keyframes draw-circle { to { stroke-dashoffset: 0; } }
@keyframes draw-check { to { stroke-dashoffset: 0; } }
.success-card h2 { margin: 14px 0 6px; font-size: 22px; letter-spacing: .5px; }
.success-desc { margin: 0; font-size: 13px; color: var(--muted); }
.success-seq {
    margin: 20px 0 10px;
    padding: 14px;
    border-radius: 14px;
    background: var(--brand-soft);
}
.success-seq span { display: block; font-size: 12px; color: #517099; }
.success-seq b { display: block; margin-top: 2px; font-size: 27px; color: var(--brand); letter-spacing: 1px; }
.success-time { margin: 0 0 18px; font-size: 12px; color: var(--muted-2); }
.success-note { margin: 14px 0 0; font-size: 11px; color: var(--muted-2); }

/* 上传遮罩 */
.upload-mask {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .55);
    backdrop-filter: blur(2px);
}
.upload-mask[hidden] { display: none; }
.upload-dialog {
    width: 220px;
    padding: 24px 20px;
    text-align: center;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .2);
}
.spinner {
    width: 36px;
    height: 36px;
    margin: 0 auto 12px;
    border: 3px solid #e5ebf3;
    border-top-color: var(--brand);
    border-radius: 50%;
    animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.upload-dialog b { display: block; font-size: 21px; color: var(--brand); }
.upload-dialog p { margin: 4px 0 0; font-size: 12px; color: var(--muted); }

.toast {
    position: fixed;
    left: 50%;
    bottom: 96px;
    z-index: 200;
    max-width: calc(100% - 40px);
    padding: 10px 16px;
    border-radius: 999px;
    background: rgba(17, 24, 39, .93);
    color: #fff;
    font-size: 13px;
    line-height: 1.5;
    text-align: center;
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, 14px);
    transition: opacity .2s ease, transform .2s ease;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.noscript {
    margin: 20px;
    padding: 16px;
    border-radius: 12px;
    background: var(--danger-soft);
    color: var(--danger);
    font-size: 14px;
}

/* ---------------- 登录 / 安装 ---------------- */

.auth-body {
    min-height: 100vh;
    background:
        radial-gradient(900px 420px at 12% 0%, #dbe9fb 0%, rgba(219, 233, 251, 0) 60%),
        radial-gradient(800px 420px at 100% 100%, #d9f3ee 0%, rgba(217, 243, 238, 0) 60%),
        #eef3fa;
}
.auth-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 18px;
}
.auth-card {
    width: 100%;
    max-width: 400px;
    padding: 30px 26px 26px;
    background: #fff;
    border: 1px solid rgba(227, 233, 242, .9);
    border-radius: 22px;
    box-shadow: 0 24px 60px rgba(16, 24, 40, .10);
}
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.brand-mark {
    flex: 0 0 auto;
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 13px;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    color: #fff;
    font-size: 21px;
    font-weight: 700;
    box-shadow: 0 8px 18px rgba(11, 79, 156, .25);
}
.auth-brand h1 { margin: 0; font-size: 19px; letter-spacing: .3px; }
.auth-brand p { margin: 3px 0 0; font-size: 12px; color: var(--muted); line-height: 1.45; }

.form-group { margin-top: 16px; }
.form-label { display: block; margin-bottom: 7px; font-size: 13px; font-weight: 600; color: #344054; }
.form-input {
    display: block;
    width: 100%;
    height: 46px;
    padding: 0 13px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: #fbfcfe;
    font-size: 14px;
    outline: none;
    transition: border-color .18s ease, box-shadow .18s ease;
    -webkit-appearance: none;
    appearance: none;
}
.form-input:focus { border-color: var(--brand); background: #fff; box-shadow: 0 0 0 4px rgba(11, 79, 156, .10); }
select.form-input {
    padding-right: 36px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4.5L6 8.5L10 4.5' fill='none' stroke='%238b97a8' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
}
textarea.form-input { height: auto; min-height: 90px; padding: 11px 13px; line-height: 1.6; }

.notice {
    margin: 14px 0;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 13px;
    line-height: 1.65;
    border: 1px solid transparent;
}
.notice p { margin: 0 0 6px; }
.notice p:last-child { margin-bottom: 0; }
.notice-ok { background: var(--ok-soft); color: var(--ok); border-color: #abefc6; }
.notice-error { background: var(--danger-soft); color: #b42318; border-color: #fecdca; }
.notice-warn { background: var(--warn-soft); color: var(--warn); border-color: #fedf89; }

.form-result { margin: 8px 0 18px; }
.form-result div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 0;
    border-bottom: 1px dashed var(--line);
    font-size: 13px;
}
.form-result div:last-child { border-bottom: 0; }
.form-result span { color: var(--muted); }
.form-result b { text-align: right; word-break: break-all; }
.auth-foot { margin: 16px 0 0; text-align: center; font-size: 12px; color: var(--muted-2); line-height: 1.6; }
.auth-card .btn { height: 46px; margin-top: 18px; }

/* ---------------- 管理后台 ---------------- */

.admin-body { background: #f4f7fb; }

.topbar {
    position: sticky;
    top: 0;
    z-index: 40;
    background: rgba(255, 255, 255, .96);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(10px);
}
.topbar-inner {
    max-width: none;
    margin: 0 auto;
    height: 62px;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.topbar .brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.topbar .brand-mark { width: 34px; height: 34px; border-radius: 10px; font-size: 16px; box-shadow: none; }
.brand-text { min-width: 0; }
.brand-text b { display: block; font-size: 15px; letter-spacing: .2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-text span { display: block; font-size: 11px; color: var(--muted); }
.topnav { display: flex; align-items: center; gap: 4px; }
.topnav a {
    padding: 8px 12px;
    border-radius: 9px;
    font-size: 13px;
    color: #475467;
    transition: background .16s ease, color .16s ease;
}
.topnav a:hover { background: #f3f6fa; }
.topnav a.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.topbar-user { display: flex; align-items: center; gap: 10px; min-width: 0; }
.avatar {
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    color: #fff;
    font-size: 13px;
    font-weight: 600;
}
.user-name { font-size: 13px; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.logout-btn {
    border: 1px solid var(--line);
    background: #fff;
    color: var(--muted);
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 8px;
    cursor: pointer;
}
.logout-btn:hover { color: var(--danger); border-color: #fecdca; }

.container { max-width: none; margin: 0 auto; padding: 22px 20px 60px; }

.page-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}
.page-head h1 { margin: 0; font-size: 22px; letter-spacing: .2px; }
.page-head p { margin: 5px 0 0; font-size: 13px; color: var(--muted); }

.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.stat-card {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 16px 18px;
    background: #fff;
    border: 1px solid rgba(227, 233, 242, .9);
    border-radius: 16px;
    box-shadow: 0 6px 18px rgba(16, 24, 40, .04);
}
.stat-icon {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--brand-soft);
    color: var(--brand);
}
.stat-icon svg { width: 22px; height: 22px; }
.stat-icon.tone-danger { background: var(--danger-soft); color: var(--danger); }
.stat-icon.tone-ok { background: var(--ok-soft); color: var(--ok); }
.stat-icon.tone-warn { background: var(--warn-soft); color: var(--warn); }
.stat-value { font-size: 24px; font-weight: 700; line-height: 1.2; letter-spacing: .3px; }
.stat-label { margin-top: 2px; font-size: 12px; color: var(--muted); }

.panel {
    margin-top: 16px;
    background: #fff;
    border: 1px solid rgba(227, 233, 242, .9);
    border-radius: 16px;
    box-shadow: 0 6px 18px rgba(16, 24, 40, .04);
    overflow: hidden;
}
.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 15px 18px;
    border-bottom: 1px solid #eef2f6;
}
.panel-head h2 { margin: 0; font-size: 16px; }
.panel-head .sub { font-size: 12px; color: var(--muted); }

.filter-form {
    display: grid;
    grid-template-columns: 2.2fr 1.1fr 1.2fr 0.9fr 1fr 1fr 1fr auto;
    gap: 10px;
    padding: 15px 18px;
    align-items: end;
    border-bottom: 1px solid #eef2f6;
    background: #fbfcfe;
}
.filter-item label { display: block; margin-bottom: 5px; font-size: 11px; color: var(--muted); }
.filter-item .form-input { height: 40px; font-size: 13px; border-radius: 9px; }
.filter-actions { display: flex; gap: 8px; }
.filter-actions .btn { height: 40px; padding: 0 14px; font-size: 13px; border-radius: 9px; }
.btn-outline { border: 1px solid var(--line); background: #fff; color: #344054; box-shadow: none; }
.btn-outline:hover { border-color: #c7d2e0; }
.btn-soft { border: 1px solid #bfd5f0; background: var(--brand-soft); color: var(--brand); box-shadow: none; }

.table-wrap { overflow-x: auto; }
.data-table { width: 100%; min-width: 1080px; border-collapse: collapse; }
.data-table th {
    padding: 11px 14px;
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    color: var(--muted);
    background: #f8fafc;
    white-space: nowrap;
    border-bottom: 1px solid #eef2f6;
}
.data-table td {
    padding: 12px 14px;
    font-size: 13px;
    border-bottom: 1px solid #f1f4f8;
    vertical-align: middle;
}
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover td { background: #fafcff; }
.data-table .badge { display: inline-block; max-width: 220px; overflow: hidden; text-overflow: ellipsis; vertical-align: middle; }
.data-table .nowrap { white-space: nowrap; }
.cell-strong { font-weight: 600; color: #253858; }
.cell-sub { margin-top: 2px; font-size: 11px; color: var(--muted-2); }
.cell-ellipsis { max-width: 210px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: 12px;
    line-height: 1.5;
    white-space: nowrap;
}
.badge-danger { background: var(--danger-soft); color: #b42318; }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-ok { background: var(--ok-soft); color: var(--ok); }
.badge-info { background: #eff8ff; color: #175cd3; }
.badge-muted { background: #f2f4f7; color: #475467; }
.badge-brand { background: var(--brand-soft); color: var(--brand); }
.badge-test { background: #f4f3ff; color: #5925dc; }

.link { font-size: 13px; color: var(--brand); font-weight: 500; }
.link:hover { text-decoration: underline; }
.link-danger { color: #b42318; }
button.link { background: none; border: 0; padding: 0; cursor: pointer; font: inherit; }
.table-actions { display: flex; align-items: center; gap: 12px; }
.table-actions form { margin: 0; }

.img-count { display: inline-flex; align-items: center; gap: 5px; color: var(--muted); font-size: 12px; }
.img-count svg { width: 14px; height: 14px; }

.pager {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 18px;
    border-top: 1px solid #eef2f6;
    flex-wrap: wrap;
}
.pager-info { font-size: 12px; color: var(--muted); }
.pager-links { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.pager-links a, .pager-links span {
    min-width: 32px;
    height: 32px;
    padding: 0 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    font-size: 12px;
    color: #475467;
}
.pager-links a:hover { border-color: #b9cae0; color: var(--brand); }
.pager-links .active { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager-links .disabled { color: #c3ccd9; background: #fafbfc; }

.empty-state { padding: 54px 20px; text-align: center; color: var(--muted); }
.empty-state svg { width: 54px; height: 54px; margin: 0 auto 12px; color: #c3cfdd; }
.empty-state b { display: block; font-size: 15px; color: #475467; margin-bottom: 4px; }
.empty-state p { margin: 0; font-size: 12px; }

/* 详情页 */
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.detail-card.span-2 { grid-column: 1 / -1; }
.detail-card {
    background: #fff;
    border: 1px solid rgba(227, 233, 242, .9);
    border-radius: 16px;
    padding: 18px 20px;
    box-shadow: 0 6px 18px rgba(16, 24, 40, .04);
}
.detail-card h2 {
    margin: 0 0 12px;
    padding-bottom: 10px;
    border-bottom: 1px dashed var(--line);
    font-size: 15px;
}
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 10px; padding: 9px 0; border-bottom: 1px dashed #eef2f6; }
.kv:last-child { border-bottom: 0; }
.kv dt { font-size: 12px; color: var(--muted); }
.kv dd { margin: 0; font-size: 13px; word-break: break-all; line-height: 1.6; }
.detail-images { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.detail-images a { display: block; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: #f8fafc; }
.detail-images img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.detail-images figcaption { padding: 6px 8px; font-size: 11px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.detail-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.btn-danger { background: #fff; border: 1px solid #fecdca; color: #b42318; box-shadow: none; }
.btn-danger:hover { background: #fff6f5; }
.muted { color: var(--muted); }
.mono { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; font-size: 12px; }

/* 响应式 */
@media (max-width: 1000px) {
    .stat-grid { grid-template-columns: repeat(2, 1fr); }
    .filter-form { grid-template-columns: 1fr 1fr; }
    .filter-actions { grid-column: span 2; }
    .detail-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
    .topnav { display: none; }
}

@media (max-width: 600px) {
    .container { padding: 16px 14px 48px; }
    .topbar-inner { padding: 0 14px; }
    .user-name { display: none; }
    .page-head { flex-direction: column; align-items: flex-start; }
    .stat-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .stat-card { padding: 13px 14px; gap: 10px; }
    .stat-icon { width: 38px; height: 38px; }
    .stat-value { font-size: 20px; }
    .filter-form { grid-template-columns: 1fr; }
    .filter-actions { grid-column: auto; }
    .detail-images { grid-template-columns: repeat(2, 1fr); }
    .kv { grid-template-columns: 104px 1fr; }
    .pager { justify-content: center; }
}

@media (max-width: 380px) {
    .grid-2 { grid-template-columns: 1fr; gap: 0; }
    .seg-count span { font-size: 11px; padding: 0 2px; }
    .hero h1 { font-size: 22px; }
}

@media (min-width: 720px) {
    .h5-shell { padding-top: 22px; }
    .hero { border-radius: 26px; }
    .submit-bar { bottom: 14px; border: 1px solid var(--line); border-radius: 16px; width: calc(100% - 28px); box-shadow: 0 14px 34px rgba(16, 24, 40, .12); }
    .page-bottom-space { height: 110px; }
}

@media (min-width: 480px) {
    .upload-grid { grid-template-columns: repeat(3, 1fr); }
}
