/* ============================================================
   鎺掗槦鍙彿绯荤粺 路 鏀垮姟鏈嶅姟澶у巺瑙嗚瑙勮寖
   绾紙鍏氬缓/鏀垮姟锛?+ 钃濓紙鏁堢巼/鍙俊锛?+ 閲戯紙搴勯噸锛? 鏆栫櫧搴?   ============================================================ */
:root {
    --primary: #1d4ed8;
    --primary-2: #2f6fed;
    --primary-dark: #17389e;
    --primary-soft: #e8efff;
    --gov-red: #c8102e;
    --gov-red-2: #e04a3f;
    --gold: #c9971c;
    --gold-2: #e7b34b;
    --success: #16a34a;
    --warning: #d97706;
    --danger: #dc2626;
    --ink: #17233d;
    --ink-2: #5b6785;
    --ink-3: #939db5;
    --line: #e3e8f4;
    --bg: #f4f6fb;
    --bg-warm: #fbf9f4;
    --surface: #ffffff;
    --r-sm: 10px;
    --r-md: 16px;
    --r-lg: 22px;
    --shadow: 0 4px 16px rgba(23, 35, 61, .07);
    --shadow-lg: 0 16px 40px rgba(23, 35, 61, .14);
    --fs-1: 17px;
    --fs-2: 21px;
    --fs-3: 30px;
    --fs-4: 48px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font: var(--fs-1)/1.65 "Microsoft YaHei", "PingFang SC", system-ui, -apple-system, sans-serif;
    -webkit-tap-highlight-color: transparent;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-image:
        radial-gradient(900px 380px at 8% -10%, rgba(29, 78, 216, .10), transparent 70%),
        radial-gradient(760px 320px at 96% 0%, rgba(200, 16, 46, .07), transparent 70%);
    background-repeat: no-repeat;
}

a { color: var(--primary); text-decoration: none; }

/* ---------- 椤堕儴锛氱孩鑹查グ鏉?+ 娣辫摑娓愬彉 + 寰芥爣 ---------- */
.top-ribbon {
    height: 6px;
    background: linear-gradient(90deg, var(--gov-red) 0%, #e04a3f 28%, var(--gold-2) 62%, var(--primary) 100%);
}

.app-header {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px 44px 20px;
    background: linear-gradient(115deg, #0f2b6b 0%, #17389e 45%, #1d4ed8 100%);
    color: #fff;
    border-bottom: 4px solid var(--gold-2);
    box-shadow: 0 6px 22px rgba(15, 43, 107, .22);
}
.app-header::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, .10) 1px, transparent 1px);
    background-size: 22px 22px;
    opacity: .5;
    pointer-events: none;
}

.hall-id { display: flex; align-items: center; gap: 16px; position: relative; z-index: 1; }
.hall-badge {
    width: 54px; height: 54px; border-radius: 50%;
    display: grid; place-items: center;
    background: radial-gradient(circle at 30% 25%, #ffd97a, var(--gold) 70%);
    color: #4a2c00;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .55), 0 4px 12px rgba(0, 0, 0, .25);
}
.hall-badge svg { width: 30px; height: 30px; }
.hall-name { font-size: 26px; font-weight: 800; letter-spacing: 2px; line-height: 1.2; }
.hall-slogan {
    font-size: 14px; letter-spacing: 6px; color: #ffe6a8; margin-top: 4px;
}
.header-meta { text-align: right; position: relative; z-index: 1; font-size: 14px; color: #d6e2ff; line-height: 1.9; }
.header-meta b { color: #fff; font-weight: 700; }
.header-meta .dot-live {
    display: inline-block; width: 8px; height: 8px; border-radius: 50%;
    background: #4ade80; margin-right: 6px; box-shadow: 0 0 0 3px rgba(74, 222, 128, .25);
}

/* ---------- 姝ラ鏉?---------- */
.steps {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 26px 16px 8px;
    flex-wrap: wrap;
}
.step {
    display: flex; align-items: center; gap: 10px;
    padding: 8px 18px 8px 8px;
    border-radius: 999px;
    color: var(--ink-3); font-size: 15px;
    background: transparent;
}
.step .dot {
    width: 34px; height: 34px; border-radius: 50%;
    background: #e6eaf4; color: var(--ink-2);
    display: grid; place-items: center;
    font-weight: 800; font-size: 15px;
}
.step.done { color: var(--primary); background: var(--primary-soft); }
.step.done .dot { background: #fff; color: var(--primary); box-shadow: inset 0 0 0 2px var(--primary); }
.step.active {
    color: #fff;
    background: linear-gradient(120deg, var(--gov-red), var(--gov-red-2) 60%, var(--gold-2));
    box-shadow: 0 6px 18px rgba(200, 16, 46, .28);
    font-weight: 700;
}
.step.active .dot { background: rgba(255, 255, 255, .22); color: #fff; }
.step-sep { color: #cfd6e6; }

/* ---------- 涓诲尯 ---------- */
.app-main { flex: 1; width: 100%; max-width: 1200px; margin: 0 auto; padding: 12px 24px 56px; }

.page-head { text-align: center; margin: 6px 0 26px; }
.page-title {
    font-size: var(--fs-3); font-weight: 800; letter-spacing: 1px;
    margin: 0 0 8px; color: var(--ink);
}
.page-title::after {
    content: ""; display: block; width: 76px; height: 5px; margin: 14px auto 0;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--gov-red), var(--gold-2));
}
.page-sub { color: var(--ink-2); margin: 0; font-size: 17px; }

/* ---------- 鍗＄墖 ---------- */
.grid-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 22px;
}
.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    box-shadow: var(--shadow);
    padding: 26px;
}
.choice-card {
    position: relative;
    display: flex; flex-direction: column; gap: 14px;
    min-height: 228px; justify-content: space-between;
    overflow: hidden;
    transition: transform .18s, box-shadow .18s, border-color .18s;
}
.choice-card::before {
    content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px;
    background: linear-gradient(180deg, var(--primary), var(--primary-2));
}
.choice-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: #cfdaf5; }
.choice-card .card-head { display: flex; align-items: center; gap: 14px; }
.choice-card .card-title { font-size: var(--fs-2); font-weight: 800; }
.choice-card .card-desc { color: var(--ink-2); font-size: 15px; min-height: 44px; }
.card-meta { color: var(--ink-2); font-size: 14px; }

/* 鍥炬爣纾佽创锛氬ぇ鍙枫€佸僵鑹层€佸垎鑹?*/
.icon-tile {
    flex: none;
    width: 64px; height: 64px; border-radius: 18px;
    display: grid; place-items: center;
    color: #fff;
    box-shadow: 0 8px 18px rgba(23, 35, 61, .18);
}
.icon-tile svg { width: 36px; height: 36px; }
.tile-blue   { background: linear-gradient(135deg, #3b76f6, #1d4ed8); }
.tile-red    { background: linear-gradient(135deg, #e2564a, #c8102e); }
.tile-gold   { background: linear-gradient(135deg, #edc264, #c9971c); color: #4a2c00; }
.tile-teal   { background: linear-gradient(135deg, #2fb8b1, #0f7f7a); }
.tile-green  { background: linear-gradient(135deg, #48b97a, #1f7a4d); }
.tile-purple { background: linear-gradient(135deg, #8b6cf6, #5a3fd6); }

/* 鍗＄墖搴忓彿 */
.card-index {
    position: absolute; right: 18px; top: 14px;
    font-size: 42px; font-weight: 800; line-height: 1;
    color: rgba(29, 78, 216, .08);
    font-variant-numeric: tabular-nums;
}

/* ---------- 鎸夐挳 ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    min-height: 56px; padding: 0 30px;
    border: 1px solid transparent; border-radius: var(--r-sm);
    background: linear-gradient(120deg, var(--primary-2), var(--primary));
    color: #fff; font-size: 18px; font-family: inherit; font-weight: 600;
    cursor: pointer; touch-action: manipulation;
    box-shadow: 0 6px 16px rgba(29, 78, 216, .28);
    transition: transform .12s, box-shadow .15s, filter .15s;
}
.btn svg { width: 22px; height: 22px; }
.btn:hover { filter: brightness(1.06); box-shadow: 0 10px 22px rgba(29, 78, 216, .34); }
.btn:active { transform: scale(.98); }
.btn:focus-visible { outline: 3px solid #93c5fd; outline-offset: 2px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; box-shadow: none; }
.btn.block { width: 100%; }
.btn.lg { min-height: 66px; font-size: 21px; border-radius: 12px; }
.btn.ghost {
    background: #fff; color: var(--gov-red);
    border: 1.5px solid rgba(200, 16, 46, .5);
    box-shadow: 0 4px 12px rgba(200, 16, 46, .10);
}
.btn.ghost:hover { background: #fff5f5; }
.btn.gold {
    background: linear-gradient(120deg, var(--gold-2), var(--gold));
    color: #4a2c00; box-shadow: 0 6px 16px rgba(201, 151, 28, .30);
}

/* ---------- 鐘舵€佹爣绛?---------- */
.tag { display: inline-flex; align-items: center; gap: 6px; padding: 3px 12px; border-radius: 999px; font-size: 14px; font-weight: 600; }
.tag.waiting { background: #eef2f9; color: #4b5563; }
.tag.processing { background: #dbeafe; color: #1d4ed8; }
.tag.completed { background: #dcfce7; color: #15803d; }
.tag.skipped { background: #fef3c7; color: #b45309; }
.tag.expired { background: #e5e7eb; color: #4b5563; }
.tag.priority { background: linear-gradient(120deg, #ffe6a8, #ffd166); color: #7a4b00; }

/* ---------- 搴曟爮 ---------- */
.app-footer {
    background: linear-gradient(115deg, #0f2b6b, #17389e);
    color: #c9d7f7;
    padding: 16px 24px;
    font-size: 14px;
    text-align: center;
    border-top: 4px solid var(--gold-2);
}
.app-footer b { color: #fff; }
.app-footer .sep { margin: 0 10px; color: rgba(255, 255, 255, .35); }

/* ---------- 閫氱敤琛ㄥ崟 ---------- */
.field { margin-bottom: 20px; }
.field label { display: flex; align-items: center; gap: 8px; font-size: 15px; color: var(--ink-2); margin-bottom: 8px; }
.field input, .field select {
    width: 100%; min-height: 58px; padding: 0 18px;
    font-size: 19px; font-family: inherit; color: var(--ink);
    background: #fff; border: 1.5px solid #d5ddec; border-radius: var(--r-sm); outline: none;
}
.field input:focus, .field select:focus { border-color: var(--primary); box-shadow: 0 0 0 4px #dbeafe; }

@media (max-width: 720px) {
    .app-header { padding: 14px 18px 16px; flex-wrap: wrap; }
    .hall-name { font-size: 20px; }
    .hall-slogan { letter-spacing: 3px; }
    .header-meta { text-align: left; font-size: 13px; }
    .app-main { padding: 8px 14px 40px; }
    .page-title { font-size: 24px; }
    .grid-cards { grid-template-columns: 1fr; }
    .step { padding: 6px 12px 6px 6px; font-size: 13px; }
    .step .dot { width: 28px; height: 28px; font-size: 13px; }
}

/* ---------- 灏忓彿鍥炬爣纾佽创 & 鍖哄潡鏍囬 ---------- */
.icon-tile.tile-sm { width: 48px; height: 48px; border-radius: 14px; box-shadow: 0 4px 10px rgba(23,35,61,.14); }
.icon-tile.tile-sm svg { width: 26px; height: 26px; }
.section-title {
    display: flex; align-items: center; gap: 12px;
    font-size: 20px; font-weight: 800; margin: 30px 0 16px;
}
.section-title::before {
    content: ""; width: 6px; height: 24px; border-radius: 3px;
    background: linear-gradient(180deg, var(--gov-red), var(--gold-2));
}
.queue-chips { display: flex; flex-wrap: wrap; gap: 12px; }
.queue-chip {
    display: inline-flex; align-items: center; gap: 8px;
    background: #fff; border: 1px solid var(--line); border-radius: 999px;
    padding: 9px 18px; font-size: 15px; color: var(--ink-2);
    box-shadow: var(--shadow);
}
.queue-chip::before {
    content: ""; width: 8px; height: 8px; border-radius: 50%;
    background: var(--primary-2);
}
.queue-chip b { color: var(--gov-red); font-size: 17px; font-variant-numeric: tabular-nums; }

/* ---------- 鍗＄墖鍐呮暟鍊煎己璋?---------- */
.card-meta b { color: var(--gov-red); font-size: 19px; font-variant-numeric: tabular-nums; }

/* ---------- 鍗＄墖宸︿晶寮鸿皟鑹茶窡闅忓浘鏍囩璐?---------- */
.choice-card.accent-blue::before   { background: linear-gradient(180deg, #3b76f6, #1d4ed8); }
.choice-card.accent-red::before    { background: linear-gradient(180deg, #e2564a, #c8102e); }
.choice-card.accent-teal::before   { background: linear-gradient(180deg, #2fb8b1, #0f7f7a); }
.choice-card.accent-gold::before   { background: linear-gradient(180deg, #edc264, #c9971c); }
.choice-card.accent-green::before  { background: linear-gradient(180deg, #48b97a, #1f7a4d); }
.choice-card.accent-purple::before { background: linear-gradient(180deg, #8b6cf6, #5a3fd6); }

/* ---------- 鍔炰簨鎻愮ず鏉?---------- */
.tips-band { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 30px; }
.tip-item {
    flex: 1; min-width: 250px;
    display: flex; align-items: center; gap: 14px;
    background: #fff; border: 1px solid var(--line); border-radius: var(--r-md);
    padding: 16px 18px; box-shadow: var(--shadow);
}
.tip-item .icon-tile { width: 46px; height: 46px; border-radius: 13px; box-shadow: none; }
.tip-item .icon-tile svg { width: 24px; height: 24px; }
.tip-item .tip-title { font-weight: 700; font-size: 16px; color: var(--ink); }
.tip-item .tip-desc { font-size: 13px; color: var(--ink-2); margin-top: 2px; }

/* ---------- 通用小按钮 / 表格（窗口端与后台共用） ---------- */
.btn-sm { min-height: 34px; padding: 0 14px; font-size: 14px; border-radius: 8px; box-shadow: none; gap: 5px; }
.btn-sm svg { width: 15px; height: 15px; }
.btn-line { background: #fff; color: var(--ink); border: 1px solid #d5ddec; box-shadow: none; }
.btn-line:hover { background: #f5f8ff; filter: none; }
.btn-danger-line { background: #fff; color: var(--danger); border: 1px solid #f0b4b4; box-shadow: none; }
.btn-danger-line:hover { background: #fff3f3; filter: none; }

.table-wrap { overflow-x: auto; }
table.a-table { width: 100%; border-collapse: collapse; font-size: 14px; }
table.a-table th, table.a-table td {
    padding: 9px 12px; border-bottom: 1px solid var(--line);
    text-align: left; white-space: nowrap;
}
table.a-table th { background: #f7f9fd; color: var(--ink-2); font-weight: 600; }
table.a-table tbody tr:hover { background: #f8faff; }
table.a-table td.wrap { white-space: normal; }
.a-empty { text-align: center; color: var(--ink-3); padding: 28px 0; }
