﻿:root {
    --bg: #edf1f5;
    --bg-soft: #f3fbf6;
    --bg-soft-2: #eef5ef;
    --card: #ffffff;
    --border: #e6e7eb;
    --border-soft: #ececef;
    --text: #1f2328;
    --sub: #6b7280;
    --sub-2: #8a8f98;
    --green: #2fa66a;
    --green-dark: #278c59;
    --green-soft: #eaf8f0;
    --green-soft-2: #f4fbf7;
    --green-line: #cfe9da;
    --red: #e53935;
    --orange: #f59e0b;
    --shadow: 0 8px 24px rgba(20, 24, 32, 0.06);
    --shadow-soft: 0 4px 14px rgba(20, 24, 32, 0.04);
    --radius: 4px;
    --radius-sm: 4px;
    --shell-accent: #2fa66a;
    --shell-accent-soft: #eaf8f0;
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--text);
    background: #edf1f5;
    background-color: var(--bg);
    -webkit-font-smoothing: antialiased;
    padding-bottom: calc(92px + env(safe-area-inset-bottom));
}

a {
    color: inherit;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
}

button,
input,
select,
textarea {
    font: inherit;
}

.site-app-header {
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    z-index: 90;
    width: 100%;
    background: rgba(255, 255, 255, .92);
    border-bottom: 1px solid rgba(229, 231, 235, .88);
    box-shadow: 0 8px 24px rgba(15, 23, 42, .06);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.site-app-header-inner {
    max-width: 760px;
    min-height: 62px;
    margin: 0 auto;
    padding: calc(env(safe-area-inset-top, 0px) + 10px) 14px 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.site-app-logo {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
}

.site-app-logo-box {
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    border-radius: 999px;
    overflow: hidden;
    background: #eff6ff;
    border: 1px solid #dbeafe;
}

.site-app-logo-box img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.site-app-logo-text {
    min-width: 0;
    display: block;
}

.site-app-logo-text strong,
.site-app-logo-text small {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.site-app-logo-text strong {
    color: var(--text);
    font-size: 16px;
    line-height: 1.1;
    font-weight: 900;
}

.site-app-logo-text small {
    margin-top: 3px;
    color: var(--sub);
    font-size: 11px;
    line-height: 1.35;
}

.site-app-header-actions {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.site-app-header-action {
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border-radius: var(--radius);
    border: 1px solid #cfe9da;
    background: #f5fbf7;
    color: var(--green-dark);
    font-size: 13px;
    font-weight: 800;
}

.wrap {
    width: 100%;
    max-width: 760px;
    margin: 0 auto;
    padding: 12px 12px 18px;
}

/* 顶部主卡 */
.hero {
    margin-bottom: 14px;
}

.hero-inner {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* 白色筛选卡 */
.filter-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-soft);
    padding: 10px 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.day-control {
    display: grid;
    padding: 8px 0 0;
    border-top: 1px solid #eef1f2;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.filter-label {
    font-size: 12px;
    color: var(--sub);
    font-weight: 700;
    line-height: 1.2;
}

/* tabs */
.tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.tabs::-webkit-scrollbar {
    display: none;
}

@media (min-width: 768px) {
    .tabs {
        scrollbar-width: auto;
        scrollbar-color: rgba(31,35,40,.28) rgba(31,35,40,.08);
    }

    .tabs::-webkit-scrollbar {
        display: block;
        height: 10px;
    }

    .tabs::-webkit-scrollbar-track {
        background: rgba(31,35,40,.08);
        border-radius: 999px;
    }

    .tabs::-webkit-scrollbar-thumb {
        background: rgba(31,35,40,.28);
        border-radius: 999px;
    }

    .tabs::-webkit-scrollbar-thumb:hover {
        background: rgba(31,35,40,.38);
    }
}

.tab {
    flex: 0 0 auto;
    min-width: 104px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: #fafafb;
    padding: 10px 10px;
    cursor: pointer;
    user-select: none;
    transition: .18s ease;
}

.tab:hover {
    background: #f7faf8;
    border-color: #dce8e0;
}

.tab.active {
    background: var(--green-soft);
    border-color: #bfe1cd;
    box-shadow: 0 4px 10px rgba(47,166,106,.10);
}

.tab .d {
    font-weight: 800;
    font-size: 13px;
    color: var(--text);
    white-space: nowrap;
}

.tab .s {
    margin-top: 6px;
    color: var(--sub);
    font-size: 12px;
    line-height: 1.2;
}

.tab.active .d {
    color: var(--green-dark);
}

.tab.active .s {
    color: #4f7d63;
}

.tool-action,
.action-btn {
    appearance: none;
    height: 40px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: .18s ease;
}

.tool-action {
    height: 30px;
    padding: 0 10px;
    border-color: #e6e7eb;
    background: #fafafb;
    color: #4f5d68;
    font-size: 12px;
}

.tool-action:hover {
    border-color: #dfe7e3;
    background: #fbfcfc;
    color: var(--green-dark);
}

.action-btn:hover {
    background: #f8f9fb;
}

.action-btn.primary {
    background: var(--green);
    border-color: var(--green);
    color: #fff;
}

.action-btn.primary:hover {
    background: var(--green-dark);
    border-color: var(--green-dark);
}

.day-insight {
    padding: 9px 10px;
    border: 1px solid #d8e2ec;
    border-radius: var(--radius);
    background: #f4f8fb;
    color: #31485f;
    line-height: 1.45;
}

.day-insight.strong {
    border-color: #f0c7c2;
    background: #fff5f4;
}

.day-insight.weak {
    border-color: #e2e4e8;
    background: #f6f7f9;
}

.day-insight.pending {
    border-color: #d8e2ec;
    background: #f4f8fb;
}

.day-insight-title {
    margin-bottom: 7px;
    color: #263f58;
    font-size: 11px;
    font-weight: 500;
}

.day-hit-line {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 12px;
}

.day-hit-item {
    min-width: 0;
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
}

.day-hit-label {
    color: #667789;
    font-size: 10px;
    font-weight: 400;
    white-space: nowrap;
}

.day-hit-value {
    color: #1f354a;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
}

.day-hit-value.strong {
    color: #d93025;
}

.day-hit-value.weak,
.day-hit-value.pending {
    color: #8a8f98;
}

.confidence-filter {
    display: flex;
    flex: 1 1 auto;
    min-width: 0;
    gap: 0;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 1px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.list-filter-bar {
    margin-top: 10px;
    margin-bottom: -6px;
    padding: 0 2px;
}

.confidence-row {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.confidence-label {
    flex: 0 0 auto;
    color: #4f5d68;
    font-size: 12px;
    font-weight: 900;
}

.list-export-action {
    flex: 0 0 auto;
    margin-left: 2px;
    white-space: nowrap;
}

.confidence-filter::-webkit-scrollbar {
    display: none;
}

.confidence-btn {
    flex: 0 0 auto;
    min-width: 0;
    height: 30px;
    padding: 0 11px;
    border: 1px solid #dfe5ea;
    border-right: 0;
    background: #fff;
    color: #52616f;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
}

.confidence-btn:first-child {
    border-radius: var(--radius) 0 0 var(--radius);
}

.confidence-btn:last-child {
    border-right: 1px solid #dfe5ea;
    border-radius: 0 var(--radius) var(--radius) 0;
}

.confidence-btn.active {
    border-color: #55789a;
    background: #55789a;
    color: #fff;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.12);
}

/* 列表 */
.list {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.match {
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: #fff;
    box-shadow: var(--shadow-soft);
    overflow: hidden;
    position: relative;
}

.match.good {
    border-color: red;
    box-shadow: 0 8px 18px rgba(217,48,37,.10);
}

.match.confidence-strong {
    border-left: 4px solid #d93025;
}

.match.confidence-steady {
    border-left: 4px solid #2fa66a;
}

.match.confidence-watch {
    border-left: 4px solid #f59e0b;
}

.match:active {
    transform: scale(.996);
}

.match-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 12px 10px;
}

.left {
    min-width: 0;
    flex: 1;
}

.topline {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.jid {
    letter-spacing: .2px;
    font-size: 12px;
    color: var(--sub);
    font-weight: 700;
}

.date {
    color: var(--sub);
    font-size: 12px;
}

.league {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text);
    font-size: 12.5px;
    font-weight: 800;
}

.l-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    box-shadow: 0 0 0 4px rgba(47,166,106,.08);
    flex: 0 0 auto;
}

.teams {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
}

.teams .vs {
    padding: 4px 8px;
    border-radius: var(--radius);
    background: #f7f8fa;
    color: var(--sub);
    font-size: 12px;
    font-weight: 700;
    flex: 0 0 auto;
}

.teams .t {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.teams .t.away {
    text-align: right;
}

.status {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    margin-left: auto;
}

.match-state,
.confidence-pill {
    display: inline-flex;
    align-items: center;
    min-height: 20px;
    padding: 0 7px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
}

.match-state.future {
    background: #edf7f0;
    color: #278c59;
}

.match-state.live {
    background: #fff1f0;
    color: #d93025;
}

.match-state.waitReview {
    background: #fff5df;
    color: #b76e00;
}

.match-state.reviewed {
    background: #f1f3f5;
    color: #5d6672;
}

.confidence-pill.strong {
    background: #fff1f0;
    color: #d93025;
}

.confidence-pill.steady {
    background: #eaf8f0;
    color: #278c59;
}

.confidence-pill.watch {
    background: #fff7e8;
    color: #b76e00;
}

.analysis-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: auto;
    padding: 0;
    border: none;
    background: transparent;
    color: #278c59;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.3;
    text-decoration: none;
    white-space: nowrap;
    position: relative;
}

.analysis-link-icon {
    width: 10px;
    height: 10px;
    flex: 0 0 auto;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
    transform: translateY(0.5px);
}

.analysis-link:hover {
    color: #1f6f46;
    text-decoration: underline;
}

.badge {
    font-size: 11px;
    padding: 4px 9px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--sub);
    white-space: nowrap;
    font-weight: 800;
}

.badge.hit {
    border-color: #f2b8b5;
    background: #fff1f0;
    color: #d93025;
}

.badge.miss {
    border-color: #e5e7eb;
    background: #f7f7f8;
    color: #6b7280;
}

.badge.pending {
    border-color: #f7ddb1;
    background: #fff5df;
    color: #b76e00;
}

/* 推荐区域 */
.recommend {
    margin: 0 12px 12px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    background: linear-gradient(180deg, #fbfcfc 0%, #f8fbf9 100%);
    border-radius: var(--radius);
    border: 1px solid #edf0f1;
}

.recommend-line {
    flex: 1;
    font-size: 12px;
    color: var(--text);
    line-height: 1.5;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 3px;
}

.recommend-main {
    flex: 1;
    min-width: 0;
}

.reason-line {
    margin-top: 5px;
    color: #5f6b76;
    font-size: 12px;
    line-height: 1.55;
}

.topline .badge {
    padding: 0;
    border: none;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
}

.forecast {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    min-height: 24px;
    padding: 0 4px;
    border-radius: 4px;
    background: #fff;
    border: 1px solid #e8ebee;
    font-size: 12px;
    font-weight: 600;
    color: var(--text);
}

.forecast-focus {
    width: 11px;
    height: 11px;
    flex: 0 0 auto;
    fill: #d93025;
}

.shoted {
    color: #d93025 !important;
    border-color: #f2b8b5 !important;
    background: #fff1f0 !important;
    font-weight: 800;
}

.fullscore {
    font-weight: 800;
    color: var(--text);
}

.halfscore {
    margin-left: 4px;
    color: var(--sub);
    font-size: 12px;
    font-weight: 600;
}

/* 命中比赛整卡淡绿色 */

.match.good .teams .vs {
    background: #edf7f0;
}

.match.good .jid,
.match.good .date {
    color: #4f7d63;
}

/* 空状态 */
.empty {
    text-align: center;
    color: var(--sub);
    font-size: 13px;
    padding: 18px 12px;
    border: 1px dashed var(--border);
    border-radius: var(--radius);
    background: rgba(255,255,255,.72);
}

/* footer */
.site-footer {
    margin-top: 22px;
    padding: 16px 10px 20px;
    text-align: center;
    font-size: 12px;
    color: var(--sub);
}

.law-note {
    margin-bottom: 10px;
    color: var(--red);
    font-weight: 700;
}

.footer-inner {
    max-width: 760px;
    margin: 0 auto;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    line-height: 1.8;
}

.footer-links a {
    color: var(--sub);
    padding: 2px 4px;
}

.footer-links a:hover {
    color: var(--text);
}

.footer-links .sep {
    color: #c4c7cc;
}

.footer-meta {
    margin-top: 8px;
    font-size: 11px;
    line-height: 1.6;
}

.footer-meta .slogan {
    margin-top: 2px;
    color: var(--sub-2);
}

/* 回到顶部 */
#backToTop {
    position: fixed;
    right: 18px;
    bottom: calc(88px + env(safe-area-inset-bottom));
    width: 42px;
    height: 42px;
    line-height: 42px;
    text-align: center;
    border-radius: 50%;
    cursor: pointer;
    user-select: none;
    background: #fff;
    border: 1px solid #cfe9da;
    color: var(--green);
    box-shadow: 0 8px 20px rgba(20,24,32,.10);
    font-size: 18px;
    font-weight: 700;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: opacity 0.28s ease, transform 0.28s ease;
}

#backToTop.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* 导出弹窗 */
.export-modal {
    position: fixed;
    inset: 0;
    z-index: 10020;
}

.export-mask {
    position: absolute;
    inset: 0;
    background: rgba(31,35,40,.22);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.export-panel {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: min(760px, calc(100vw - 20px));
    max-height: calc(100vh - 20px);
    overflow: auto;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: #fff;
    box-shadow: 0 18px 48px rgba(20,24,32,.12);
}

.export-header,
.export-footer {
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.export-header {
    border-bottom: 1px solid var(--border);
}

.export-footer {
    border-top: 1px solid var(--border);
    justify-content: flex-end;
}

.export-footer .action-btn {
    min-width: 116px;
    height: 42px;
    padding: 0 20px;
}

.export-title {
    font-size: 16px;
    font-weight: 800;
    color: var(--text);
}

.export-close {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--sub);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.export-body {
    padding: 16px;
}

.export-section + .export-section {
    margin-top: 18px;
}

.export-label {
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
}

.template-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
}

.template-item {
    border: 1px solid var(--border);
    background: #fff;
    border-radius: var(--radius);
    padding: 8px;
    cursor: pointer;
    transition: .18s ease;
}

.template-item:hover {
    border-color: #cfe9da;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(47,166,106,.06);
}

.template-item.active {
    border-color: #bfe1cd;
    box-shadow: 0 0 0 1px rgba(47,166,106,.08), 0 8px 18px rgba(47,166,106,.08);
    background: #f7fdf9;
}

.template-preview {
    width: 100%;
    aspect-ratio: 9 / 16;
    border-radius: var(--radius);
    overflow: hidden;
    background: #f6f4ef;
    border: 1px solid #ebe5d8;
    position: relative;
}

.template-preview::before {
    content: "";
    position: absolute;
    inset: 10px;
    border: 1px solid rgba(112, 84, 48, 0.14);
}

.template-sheet {
    position: absolute;
    inset: 0;
    padding: 14px 12px 12px;
}

.template-head {
    height: 32%;
    border-radius: 4px;
    position: relative;
}

.template-head::after {
    content: "";
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 10px;
    height: 16px;
    border-radius: 2px;
    background: rgba(255,255,255,.45);
}

.template-body {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.template-line {
    height: 32px;
    border-radius: 3px;
}

.template-line.short {
    width: 68%;
}

.template-ledger {
    background:
        linear-gradient(rgba(145, 110, 63, 0.07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(145, 110, 63, 0.06) 1px, transparent 1px),
        linear-gradient(180deg, #f6efdf 0%, #ede3ce 100%);
    background-size: 100% 24px, 24px 100%, 100% 100%;
}

.template-ledger .template-head {
    background: linear-gradient(180deg, #efe1c5 0%, #e4d0ad 100%);
}

.template-ledger .template-line {
    background: rgba(130, 97, 60, 0.12);
}

.template-scroll {
    background: linear-gradient(180deg, #f0e3c9 0%, #e1cfab 100%);
}

.template-scroll .template-head {
    background: linear-gradient(180deg, #ecdab8 0%, #dfc69b 100%);
}

.template-scroll .template-head::before,
.template-scroll .template-head::after {
    box-shadow: 0 -4px 0 rgba(130, 88, 45, 0.55), 0 4px 0 rgba(130, 88, 45, 0.55);
}

.template-scroll .template-line {
    background: rgba(114, 82, 49, 0.13);
    border-left: 4px solid rgba(154, 115, 70, 0.42);
}

.template-pine {
    background: linear-gradient(180deg, #f3f1e4 0%, #e8e3d2 100%);
}

.template-pine .template-head {
    background: linear-gradient(180deg, #e8e4d5 0%, #d8d4bf 100%);
}

.template-pine .template-line {
    background: rgba(94, 108, 81, 0.14);
}

.template-thumb {
    width: 100%;
    aspect-ratio: 9 / 16;
    object-fit: cover;
    display: block;
    border-radius: var(--radius);
    background: #f7f7f8;
}

.template-name {
    margin-top: 8px;
    font-size: 12px;
    font-weight: 700;
    color: var(--text);
}

.template-desc {
    margin-top: 4px;
    font-size: 11px;
    line-height: 1.5;
    color: var(--sub);
}

.wechat-input {
    width: 100%;
    height: 42px;
    padding: 0 12px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: #fff;
    color: var(--text);
    outline: none;
    font-size: 14px;
}

.wechat-input::placeholder {
    color: #a0a6ad;
}

.export-tip {
    font-size: 12px;
    line-height: 1.7;
    color: var(--sub);
}

.poster-sandbox {
    position: fixed;
    left: -20000px;
    top: 0;
    width: 1080px;
    min-height: 10px;
    opacity: 0;
    pointer-events: none;
    z-index: -1;
    background: #fff;
}

.app-tabbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 95;
    width: 100%;
    background: rgba(255, 255, 255, .96);
    border-top: 1px solid rgba(229, 231, 235, .95);
    box-shadow: 0 -12px 30px rgba(15, 23, 42, .10);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.app-tabbar-inner {
    max-width: 760px;
    margin: 0 auto;
    padding: 6px 10px calc(6px + env(safe-area-inset-bottom, 0px));
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
}

.app-tab {
    min-width: 0;
    min-height: 52px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    border-radius: var(--radius);
    color: #6b7280;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
    transition: background .16s ease, color .16s ease;
}

.app-tab svg {
    width: 23px;
    height: 23px;
    display: block;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
}

.app-tab span {
    max-width: 100%;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.app-tab:hover {
    color: var(--shell-accent);
    background: var(--shell-accent-soft);
}

.app-tab.active {
    color: var(--shell-accent);
    background: var(--shell-accent-soft);
}

.poster-render-root {
    width: 1080px;
    background: #fff;
    overflow: hidden;
}

.poster-qrcode-img {
    display: block;
    width: 100%;
    height: 100%;
}

@media (min-width: 721px) {
    .wrap {
        padding: 16px 16px 22px;
    }
}

@media (max-width: 640px) {
    body {
        padding-bottom: calc(86px + env(safe-area-inset-bottom));
    }

    .site-app-header-inner {
        min-height: 56px;
        padding: calc(env(safe-area-inset-top, 0px) + 8px) 10px 8px;
    }

    .site-app-logo-box {
        width: 38px;
        height: 38px;
    }

    .wrap {
        padding: 10px 10px 16px;
    }

    .filter-card {
        padding: 10px;
        gap: 10px;
    }

    .match-header {
        gap: 10px;
    }

    .right {
        max-width: 40%;
    }

    .recommend-line {
        font-size: 12px;
    }

    .action-btn {
        text-align: center;
    }

    .tab {
        min-width: 96px;
    }

    .export-panel {
        width: calc(100vw - 14px);
    }

    .export-footer .action-btn {
        flex: 1 1 0;
        min-width: 0;
    }

    .template-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    #backToTop {
        right: 12px;
        bottom: calc(80px + env(safe-area-inset-bottom));
    }

    .app-tabbar-inner {
        padding: 5px 6px calc(5px + env(safe-area-inset-bottom, 0px));
        gap: 2px;
    }

    .app-tab {
        min-height: 50px;
    }
}

/* footer compact mobile override */
@media (max-width: 640px) {
    .site-footer {
        padding: 12px 8px calc(14px + env(safe-area-inset-bottom));
    }

    .law-note {
        margin-bottom: 6px !important;
        font-size: 11px;
        line-height: 1.25;
        white-space: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .footer-inner {
        max-width: 100%;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .footer-links {
        justify-content: flex-start;
        flex-wrap: nowrap;
        gap: 4px;
        width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        white-space: nowrap;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        line-height: 1.4;
        padding-bottom: 1px;
    }

    .footer-links a,
    .footer-links .sep {
        flex: 0 0 auto;
    }

    .footer-links a {
        padding: 1px 2px;
        font-size: 11px;
    }

    .footer-meta {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-wrap: nowrap;
        width: 100%;
        margin-top: 0;
        white-space: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        line-height: 1.3;
        font-size: 11px;
    }

    .footer-meta > div {
        flex: 0 0 auto;
    }

    .footer-meta .slogan {
        margin-top: 0;
        font-size: 10px;
    }

    .law-note::-webkit-scrollbar,
    .footer-links::-webkit-scrollbar,
    .footer-meta::-webkit-scrollbar {
        display: none;
    }

    .login-footer {
        padding: 0 8px calc(env(safe-area-inset-bottom) + 14px);
    }

    .login-footer .footer-links {
        justify-content: flex-start;
        flex-wrap: nowrap;
        gap: 4px;
        width: 100%;
        overflow-x: auto;
        overflow-y: hidden;
        white-space: nowrap;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
        font-size: 11px;
        line-height: 1.4;
    }

    .login-footer .footer-links a,
    .login-footer .sep {
        flex: 0 0 auto;
    }

    .login-footer .footer-note {
        margin-top: 6px;
        font-size: 11px;
        line-height: 1.25;
        white-space: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .login-footer .footer-links::-webkit-scrollbar,
    .login-footer .footer-note::-webkit-scrollbar {
        display: none;
    }
}

