/* 历史开奖遵循参考图的高密度数据阅读方式：表格是主体，不使用卡片化容器。 */
.history-page { min-height: 100vh; padding: 0 0 48px; color: var(--history-color-text); background: #fff; }
.history-page-header { display: grid; grid-template-columns: 64px minmax(0, 1fr) 64px; align-items: center; height: 40px; color: #fff; background: var(--history-color-accent); }
.history-page-header h1 { margin: 0; overflow: hidden; font-size: 17px; font-weight: 700; line-height: 40px; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.history-header-link { min-height: 40px; padding: 0 10px; color: #fff; font-size: 14px; line-height: 40px; text-decoration: none; white-space: nowrap; }
.history-header-link:last-child { text-align: right; }
.history-results { margin: 0; }
.history-total { display: none; }
.history-table-wrap { overflow-x: auto; background: var(--history-color-surface); border: 0; border-radius: 0; }
.history-table { width: 100%; min-width: calc(var(--history-meta-column) + var(--history-vu-column) + (var(--history-number-column-min) * 5)); color: var(--history-color-text); table-layout: fixed; border-collapse: collapse; }
.history-table--7 { min-width: calc(var(--history-meta-column) + var(--history-vu-column) + (var(--history-number-column-min) * 7)); }
.history-meta-column { width: var(--history-meta-column); }
.history-vu-column { width: var(--history-vu-column); }
.history-table td { height: 42px; padding: 2px var(--history-space-cell-x); text-align: center; vertical-align: middle; border-right: var(--history-line-grid) solid var(--history-color-grid); border-bottom: var(--history-line-grid) solid var(--history-color-grid); }
.history-meta-cell { padding: 1px 2px !important; background: var(--history-color-muted-surface); border-left: var(--history-line-grid) solid var(--history-color-grid); border-right: var(--history-line-divider) solid var(--history-color-divider) !important; }
.history-meta-cell time, .history-meta-cell a { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.history-meta-cell time { color: var(--history-color-muted-text); font-size: 12px; font-style: italic; line-height: 16px; }
.history-meta-cell a { color: var(--history-color-muted-text); font-size: 11px; font-style: italic; font-weight: 700; line-height: 15px; text-decoration: none; }
.history-vu-cell { padding: 0 !important; color: var(--history-color-text); font-size: 23px; font-weight: 800; background: var(--history-color-muted-surface); border-right: var(--history-line-divider) solid var(--history-color-divider) !important; }
.history-number-cell { min-width: var(--history-number-column-min); font-size: 20px; font-weight: 700; line-height: 1.15; }
.history-number-cell--emphasis { color: var(--history-color-emphasis); }
.history-row--group-start td { border-top: var(--history-line-group) solid var(--history-color-group-grid); }
.history-empty { margin: 0; padding: 48px 16px; color: var(--history-color-muted-text); text-align: center; background: var(--history-color-surface); border: 1px solid var(--history-color-grid); }
.history-pagination { display: none; }

/* 底部视图栏固定在可视区，和参考图一样不打断连续表格的阅读节奏。 */
.history-toolbar { position: fixed; right: 0; bottom: 0; left: 0; z-index: 20; background: #f3f3f3; border-top: 1px solid #ddd; }
.history-view-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 5px 10px; }
.history-view-tab { display: grid; place-items: center; min-height: 32px; padding: 4px 2px; color: #666; font-size: 14px; font-weight: 500; text-decoration: none; background: #fff; border: 0; border-radius: 3px; }
.history-view-tab.is-active { color: #fff; background: var(--history-color-tab-active); }
.history-filter { display: none; }
.history-page a:focus-visible, .history-table-wrap:focus-visible { outline: 2px solid #fff; outline-offset: -3px; box-shadow: 0 0 0 3px var(--history-color-accent-strong); }

@media (min-width: 768px) {
    .history-page { max-width: 980px; margin: 0 auto; padding-bottom: 52px; box-shadow: 0 0 0 1px #eee; }
    .history-page-header { grid-template-columns: 88px minmax(0, 1fr) 88px; height: 48px; }
    .history-page-header h1 { font-size: 20px; line-height: 48px; }
    .history-header-link { min-height: 48px; font-size: 15px; line-height: 48px; }
    .history-table td { height: 48px; }
    .history-meta-cell time { font-size: 13px; line-height: 18px; }
    .history-meta-cell a { font-size: 12px; line-height: 16px; }
    .history-vu-cell { font-size: 26px; }
    .history-number-cell { font-size: 23px; }
    .history-toolbar { right: auto; left: 50%; width: min(980px, 100%); transform: translateX(-50%); }
}
