* { box-sizing: border-box; }
body { margin: 0; background: #0f1626; color: #e8edf7; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; }
.wrap { box-sizing: border-box; width: min(var(--page-max), calc(100% - var(--page-gutter))); margin: 0 auto; padding: 24px 0 60px; }
.page-head h1 { margin: 0 0 6px; font-size: 26px; background: linear-gradient(135deg,#f0d78c,#e8b84b); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.page-head p { margin: 0 0 18px; color: #8fa0bc; font-size: 13px; }
.tabs { display: flex; gap: 6px; border-bottom: 1px solid rgba(255,255,255,.1); margin-bottom: 18px; overflow-x: auto; }
.tabs a { color: #aab6cc; text-decoration: none; font-size: 14px; padding: 10px 16px; white-space: nowrap; border-bottom: 2px solid transparent; }
.tabs a.on { color: #ffd2a8; border-bottom-color: #ed9f64; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.filters input, .filters select { background: #182238; border: 1px solid rgba(255,255,255,.14); color: #e8edf7; border-radius: 8px; padding: 9px 12px; font-size: 13px; }
.filters input { flex: 1; min-width: 150px; }
.filters select { min-width: 180px; }
.btn { cursor: pointer; border-radius: 8px; padding: 9px 16px; font-size: 13px; border: 1px solid rgba(255,255,255,.16); background: rgba(255,255,255,.06); color: #e8edf7; }
.btn.primary { background: rgba(237,159,100,.2); border-color: rgba(237,159,100,.5); color: #ffd2a8; font-weight: 600; }
.btn:hover { filter: brightness(1.15); }
.muted { color: #8fa0bc; font-size: 12px; align-self: center; }
.list { display: grid; gap: 10px; }
.item { background: #182238; border: 1px solid rgba(255,255,255,.08); border-radius: 10px; padding: 13px 16px; cursor: pointer; transition: border-color .15s, transform .15s; }
.item:hover { border-color: rgba(237,159,100,.45); transform: translateY(-1px); }
.item .title { font-size: 15px; font-weight: 600; color: #f0d78c; }
.item .meta { color: #9fb0cc; font-size: 12px; margin-top: 6px; display: flex; flex-wrap: wrap; gap: 6px 16px; }
.item .meta b { color: #e8edf7; font-weight: 500; }
.row-rank { display: flex; align-items: center; gap: 14px; }
.row-rank .no { width: 34px; text-align: center; color: #ed9f64; font-weight: 700; }
.row-rank .nm { min-width: 100px; flex: 1; }
.row-rank .tag { color: #9fb0cc; font-size: 12px; }
.pager { text-align: center; margin-top: 18px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.empty { color: #8fa0bc; text-align: center; padding: 40px; }
.mask { position: fixed; inset: 0; display: none; align-items: center; justify-content: center; background: rgba(0,0,0,.72); z-index: 50; }
.mask.show { display: flex; }
.mask-card { background: #182238; border: 1px solid rgba(237,159,100,.3); border-radius: 16px; padding: 22px; width: 720px; max-width: 94vw; max-height: 86vh; overflow: auto; position: relative; }
.detail-close { position: absolute; right: 18px; top: 16px; }
.detail-card h2 { margin: 0 0 12px; font-size: 20px; color: #f0d78c; }
.detail-card h3 { margin: 18px 0 8px; font-size: 15px; color: #ffd2a8; }
.detail-card p { margin: 4px 0; font-size: 13px; line-height: 1.7; color: #c8d2e6; }
.detail-card .kv { display: grid; grid-template-columns: repeat(auto-fill,minmax(150px,1fr)); gap: 6px 14px; font-size: 13px; color: #9fb0cc; }
.detail-card .kv b { color: #e8edf7; font-weight: 500; }
.sgf-box { width: 100%; height: 300px; background: #0f1626; color: #9fb0cc; border: 1px solid rgba(255,255,255,.12); border-radius: 8px; padding: 10px; font-family: monospace; font-size: 11px; }
.replay-wrap { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-top: 14px; }
#replayBoard { width: 560px; max-width: 100%; height: auto; border-radius: 6px; box-shadow: 0 4px 18px rgba(0,0,0,.45); }
.replay-ctrl { display: flex; align-items: center; gap: 16px; }
.replay-ctrl .btn { min-width: 84px; }
.replay-ctrl #replayCount { min-width: 62px; text-align: center; font-variant-numeric: tabular-nums; font-size: 13px; }
.replay-ctrl .btn:disabled { opacity: .4; cursor: not-allowed; }
.toast { position: fixed; left: 50%; bottom: 30px; transform: translateX(-50%); display: none; background: rgba(20,30,48,.96); border: 1px solid rgba(237,159,100,.4); color: #ffd2a8; padding: 10px 18px; border-radius: 10px; font-size: 14px; z-index: 99; }
@media (max-width: 720px) { .wrap { padding: 18px 0 40px; } .filters input, .filters select { min-width: 100%; width: 100%; } .mask-card { padding: 16px; } }
