:root {
  --bg: #0b0d12; --panel: #151924; --panel-2: #1c212e; --line: #2a3040;
  --text: #eceef3; --muted: #8e96aa; --accent: #f5b52e; --accent-ink: #231a05;
  --ok: #34d399; --warn: #f59e42; --bad: #f87171; --radius: 12px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--text); }
a { color: var(--accent); text-decoration: none; }
h1 { font-size: 20px; margin: 0 0 2px; }
h2 { font-size: 16px; margin: 0; }
.sub, .muted { color: var(--muted); }
.sub { font-size: 13px; }
.small { font-size: 13px; }
.mono { font-family: ui-monospace, Menlo, Consolas, monospace; }
.center { text-align: center; }

/* ---------- nút + ô nhập ---------- */
.btn { font: inherit; font-weight: 600; padding: 8px 16px; border-radius: 9px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); cursor: pointer; white-space: nowrap; display: inline-block; }
.btn:hover { border-color: #3d4559; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { background: #ffc64d; }
.btn.ghost { background: transparent; color: var(--muted); }
.btn.danger { color: var(--bad); }
.btn.small { padding: 4px 10px; font-size: 13px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .4; cursor: default; }
.link { background: none; border: 0; color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; }
.link:hover { color: var(--text); }
label { display: block; font-size: 13px; color: var(--muted); }
input, textarea, select { font: inherit; padding: 8px 11px; border: 1px solid var(--line); border-radius: 9px; width: 100%; margin-top: 5px; color: var(--text); background: var(--bg); }
input:focus, textarea:focus { outline: 2px solid rgba(245, 181, 46, .35); border-color: var(--accent); }
input[type=checkbox], input[type=radio] { width: auto; margin: 0; accent-color: var(--accent); }
.check { display: inline-flex; gap: 6px; align-items: center; }

.switch { position: relative; width: 40px; height: 22px; flex: none; display: inline-block; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; background: #39404f; border-radius: 999px; transition: .15s; }
.switch span::before { content: ""; position: absolute; width: 16px; height: 16px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .15s; }
.switch input:checked + span { background: var(--accent); }
.switch input:checked + span::before { transform: translateX(18px); }
.switch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- đầu trang ứng dụng ---------- */
.app-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px 32px; background: var(--panel); flex-wrap: wrap; }
.identity { display: flex; gap: 12px; align-items: center; }
.avatar { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--panel-2); border: 1px solid var(--accent); color: var(--accent); font-weight: 700; }
.identity-name { font-size: 18px; font-weight: 700; color: var(--accent); line-height: 1.25; }
.identity-meta { display: flex; gap: 12px; font-size: 13px; color: var(--muted); align-items: center; flex-wrap: wrap; }
.dot-label::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: currentColor; margin-right: 6px; }
.dot-label.ok { color: var(--ok); } .dot-label.warn { color: var(--warn); } .dot-label.muted { color: var(--muted); }
.head-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.pill { padding: 8px 14px; border: 1px solid var(--line); border-radius: 9px; font-size: 14px; }
.pill-label { color: var(--muted); }
.tabs { display: flex; gap: 4px; padding: 0 32px; background: var(--panel); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; overflow-x: auto; }
.tab { background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); font: inherit; padding: 12px 16px; cursor: pointer; white-space: nowrap; }
.tab:hover { color: var(--text); }
.tab.active { color: var(--text); font-weight: 600; border-bottom-color: var(--accent); }
.page { padding: 20px 32px 40px; max-width: 1400px; margin: 0 auto; }
.page section > h1 { margin-top: 2px; }
.page section > .sub { margin: 0 0 14px; }

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 16px; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.notice { padding: 11px 16px; border-radius: 10px; margin-bottom: 16px; font-size: 14px; border: 1px solid; }
.notice.warn { color: #fbc98a; border-color: rgba(245, 158, 66, .5); background: rgba(245, 158, 66, .08); }
.notice.ok { color: #86efac; border-color: rgba(52, 211, 153, .5); background: rgba(52, 211, 153, .08); }
.notice.bad { color: #fca5a5; border-color: rgba(248, 113, 113, .5); background: rgba(248, 113, 113, .08); }
.empty { color: var(--muted); text-align: center; padding: 44px 12px; font-size: 14px; }

/* ---------- tổng quan ---------- */
.metrics, .tiles { display: grid; grid-template-columns: repeat(4, 1fr); }
.metrics.five { grid-template-columns: repeat(5, 1fr); }
.metric { padding: 14px 18px; border-left: 1px solid var(--line); min-width: 0; }
.metric:first-child { border-left: 0; }
.metric-label { font-size: 13px; color: var(--muted); }
.metric-value { font-size: 24px; font-weight: 700; line-height: 1.3; }
.metric-note { font-size: 12.5px; color: var(--muted); }
.columns { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.logs { height: 420px; overflow-y: auto; padding: 12px 18px; font: 12.5px/1.7 ui-monospace, Menlo, Consolas, monospace; }
.logs .t { color: var(--muted); margin-right: 10px; }
.logs .ERROR { color: var(--bad); } .logs .WARNING { color: var(--warn); }
.auto-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 14px 18px; }
.auto-card { background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 11px 13px; }
.auto-card.on { border-color: rgba(245, 181, 46, .45); }
.auto-name { font-weight: 600; font-size: 14.5px; }
.auto-state { font-size: 13px; color: var(--muted); }
.auto-card.working .auto-state { color: var(--ok); }
.facts { display: grid; grid-template-columns: 130px 1fr; gap: 6px 12px; margin: 0; padding: 12px 18px 16px; border-top: 1px solid var(--line); font-size: 14px; }
.facts dt { color: var(--muted); } .facts dd { margin: 0; word-break: break-word; }

/* ---------- cấu hình ---------- */
.config { display: grid; grid-template-columns: 280px minmax(0, 760px) 240px; gap: 16px; align-items: start; }
.side { padding: 12px; position: sticky; top: 62px; }
.side-item { width: 100%; text-align: left; background: var(--panel-2); border: 1px solid var(--line); color: var(--text); font: inherit; font-weight: 600; padding: 10px 12px; border-radius: 9px; cursor: pointer; }
.side-item.active { border-color: var(--accent); color: var(--accent); }
.search { margin: 10px 0 4px; }
.side-group { display: flex; justify-content: space-between; font-size: 12px; letter-spacing: .05em; color: var(--muted); padding: 14px 4px 6px; border-top: 1px solid var(--line); margin-top: 10px; text-transform: uppercase; }
.side-feature { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 4px; border-radius: 7px; }
.side-feature button { background: none; border: 0; color: var(--text); font: inherit; font-size: 14.5px; cursor: pointer; text-align: left; flex: 1; padding: 0; }
.side-feature.active button { color: var(--accent); font-weight: 600; }
.editor { position: relative; }
#editor-body { padding: 18px; }
.editor-title { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 2px; }
.section-label { font-size: 12px; letter-spacing: .06em; color: var(--muted); text-transform: uppercase; margin: 18px 0 8px; }
.setting-box { border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); }
.setting { padding: 14px 16px; border-top: 1px solid var(--line); }
.setting:first-child { border-top: 0; }
.setting-row { display: flex; justify-content: space-between; gap: 18px; align-items: flex-start; }
.setting-name { font-weight: 600; font-size: 14.5px; }
.setting-desc { color: var(--muted); font-size: 13px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.chip { background: var(--panel); border: 1px solid var(--line); color: var(--text); font: inherit; font-size: 14px; padding: 7px 14px; border-radius: 8px; cursor: pointer; }
.chip.active { border-color: var(--accent); color: var(--accent); background: rgba(245, 181, 46, .08); }
.progress { background: var(--bg); height: 6px; border-radius: 3px; overflow: hidden; margin-top: 8px; }
.progress div { height: 100%; background: var(--accent); }
.usage { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); margin-top: 10px; }
.usage strong { color: var(--text); }
.fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px 14px; }
.choices { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 8px; }
.choices label { display: inline-flex; align-items: center; gap: 6px; color: var(--text); font-size: 14px; }
.savebar { position: sticky; bottom: 0; display: flex; justify-content: space-between; align-items: center; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--panel); border-radius: 0 0 var(--radius) var(--radius); }

.title-switch { display: inline-flex; align-items: center; gap: 10px; }
.field-label { font-size: 14px; font-weight: 600; margin-bottom: 6px; }
.field-wide { grid-column: 1 / -1; }
.fields.two { grid-template-columns: 1fr 1fr; }
.field-span { grid-column: 1 / -1; max-width: calc(50% - 7px); }
.chip-hint { margin-top: 6px; }
.input-unit { display: flex; align-items: center; background: var(--bg); border: 1px solid var(--line); border-radius: 9px; }
.input-unit input { border: 0; margin: 0; background: transparent; min-width: 0; }
.input-unit span { color: var(--muted); font-size: 13px; padding: 0 12px; }
.field .setting-desc { margin-top: 5px; }
.is-soon .chip, .is-soon .input-unit, .is-soon .switch { opacity: .45; }
.is-soon .chip { cursor: not-allowed; }
.soon { font-size: 11px; font-weight: 600; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 1px 7px; margin-left: 4px; }
.status-side { padding: 16px; position: sticky; top: 62px; }
.status-list { display: grid; grid-template-columns: 1fr auto; gap: 9px 10px; margin: 12px 0 0; font-size: 14px; }
.status-list dt { color: var(--muted); }
.status-list dd { margin: 0; font-weight: 600; text-align: right; }

.segment { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; background: var(--bg); border-radius: 10px; padding: 4px; }
.segment button { background: none; border: 0; color: var(--muted); font: inherit; font-weight: 600; padding: 10px; border-radius: 8px; cursor: pointer; }
.segment button.active { background: var(--panel-2); color: var(--text); }
.dot-chip { display: inline-flex; align-items: center; gap: 7px; }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.dot-green { background: #4ade80; } .dot-red { background: #f87171; } .dot-yellow { background: #facc15; }
.team-head { display: flex; justify-content: space-between; align-items: center; }
.team-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin-top: 4px; }
.team-card { position: relative; background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 8px 8px 10px; color: var(--text); font: inherit; cursor: pointer; text-align: center; overflow: hidden; }
.team-card:hover { border-color: #4a5268; }
.team-card.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.team-card.empty { border-style: dashed; }
.team-card img, .team-blank { width: 100%; aspect-ratio: 7 / 8; object-fit: cover; object-position: top; border-radius: 6px; display: block; background: var(--bg); }
.team-check { position: absolute; top: 12px; right: 12px; width: 22px; height: 22px; line-height: 22px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-size: 13px; font-weight: 700; z-index: 1; }
.team-name { font-weight: 700; font-size: 14px; margin-top: 7px; }
.team-troops { font-size: 13px; }
.team-status { font-size: 12px; color: var(--muted); }
@media (max-width: 640px) { .team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- thống kê ---------- */
.tiles .metric:nth-child(n) { border-left: 1px solid var(--line); }
.tiles .metric:first-child { border-left: 0; }
.metric-value.hl { color: var(--accent); }
.chart-panel { padding: 16px 18px; }
.chart { display: flex; align-items: flex-end; gap: 2px; height: 200px; margin-top: 14px; border-bottom: 1px solid var(--line); }
.bar-col { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; min-width: 0; cursor: default; }
.bar-col:hover .bar { filter: brightness(1.2); }
.bar-value { font-size: 12.5px; font-weight: 600; margin-bottom: 4px; }
.bar { width: min(64%, 110px); background: #bf8312; border-radius: 4px 4px 0 0; min-height: 2px; }
.chart-labels { display: flex; gap: 2px; margin-top: 6px; }
.chart-labels span { flex: 1; text-align: center; font-size: 12.5px; color: var(--muted); }
.table-view { padding: 12px 18px; }
.table-view summary { cursor: pointer; font-weight: 600; font-size: 14px; }
.tooltip { position: fixed; z-index: 20; pointer-events: none; background: #05070a; border: 1px solid var(--line); border-radius: 7px; padding: 6px 10px; font-size: 13px; white-space: nowrap; }

/* ---------- bảng + lịch sử ---------- */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 9px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { color: var(--muted); font-weight: 600; font-size: 12.5px; text-transform: uppercase; letter-spacing: .03em; }
tr:last-child td { border-bottom: 0; }
.history-day { padding: 0; }
.history-day summary { display: flex; justify-content: space-between; align-items: center; padding: 12px 18px; cursor: pointer; font-weight: 600; list-style: none; }
.history-day summary::-webkit-details-marker { display: none; }
.history-tags { display: flex; gap: 8px; }
.tag { font-size: 12.5px; font-weight: 500; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 2px 10px; }
.history-day .table-wrap { padding: 0 18px 8px; }

.switcher select { width: auto; margin: 0; padding: 2px 8px; font-weight: 700; color: var(--accent); background: var(--panel-2); }
.modal { position: fixed; inset: 0; background: rgba(0, 0, 0, .6); display: grid; place-items: center; z-index: 25; padding: 16px; }
.modal-card { width: 100%; max-width: 440px; margin: 0; }
.modal-card .choices { margin: 12px 0 16px; }
.row.end { justify-content: flex-end; }

.game-card { padding: 18px; max-width: 640px; }
.game-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px; align-items: end; }
.note { margin: 14px 0 0; }
.inline-link { color: var(--accent); font-size: 14px; text-decoration: underline; padding: 0; }
@media (max-width: 640px) { .game-form { grid-template-columns: 1fr; } }

/* ---------- đăng nhập + admin ---------- */
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 14px 24px; background: var(--panel); border-bottom: 1px solid var(--line); }
.topbar a { color: var(--muted); margin-left: 14px; }
.topbar .brand { color: var(--accent); font-weight: 700; margin: 0; font-size: 17px; }
.container { max-width: 1080px; margin: 20px auto; padding: 0 16px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.auth-card { max-width: 420px; margin: 70px auto; }
.auth-card label { margin: 16px 0; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat-num { font-size: 26px; font-weight: 700; }
.row { display: flex; gap: 10px; align-items: flex-end; }
.row.wrap { flex-wrap: wrap; }
.row input { width: auto; }
.grow { flex: 1; min-width: 200px; }
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; background: var(--panel-2); color: var(--muted); }
.badge.ok { color: var(--ok); } .badge.warn { color: var(--warn); } .badge.bad { color: var(--bad); }
.alert { padding: 10px 12px; border-radius: 8px; margin: 12px 0; }
.alert.bad { background: rgba(248, 113, 113, .1); color: #fca5a5; }
.alert.ok { background: rgba(52, 211, 153, .1); color: #86efac; }
.actions { white-space: nowrap; }
form.inline { display: inline-flex; gap: 4px; align-items: center; margin: 0 2px; }
.days-input { width: 64px !important; padding: 4px 6px; margin: 0; }
.note-input { padding: 4px 6px; margin: 0; min-width: 140px; border-color: transparent; background: transparent; }
.note-input:hover, .note-input:focus { border-color: var(--line); }
.keys-out { margin-top: 8px; }
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: #05070a; border: 1px solid var(--line); color: var(--text); padding: 10px 18px; border-radius: 8px; z-index: 30; }
.toast.bad { border-color: var(--bad); color: #fca5a5; }

@media (max-width: 1240px) { .config { grid-template-columns: 240px minmax(0, 1fr); } .status-side { grid-column: 2; position: static; } }
@media (max-width: 900px) {
  .app-head, .tabs { padding-left: 16px; padding-right: 16px; }
  .page { padding: 16px 16px 32px; }
  .columns, .config { grid-template-columns: minmax(0, 1fr); }
  .status-side { position: static; }
  .side { position: static; }
  .metrics, .metrics.five, .tiles, .stats { grid-template-columns: 1fr 1fr; }
  .metric:nth-child(3) { border-left: 0; }
  .metric:nth-child(n+3) { border-top: 1px solid var(--line); }
}

.node-list { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.node-row + .node-row { border-top: 1px solid var(--line); }
.node-head { width: 100%; display: flex; justify-content: space-between; align-items: center; background: none; border: 0; color: var(--text); font: inherit; text-align: left; padding: 11px 16px; cursor: pointer; }
.node-head:hover { background: var(--panel-2); }
.node-name { font-weight: 700; font-size: 14px; }
.node-chevron { color: var(--muted); font-size: 16px; }
.node-body { padding: 4px 16px 16px; }
.node-gap { margin-top: 16px; }
.res-chip { display: inline-flex; align-items: center; gap: 7px; }
.res-chip img { width: 20px; height: 20px; object-fit: contain; }
.res-chip:disabled { opacity: .5; cursor: not-allowed; }
.level-grid { display: flex; flex-wrap: wrap; gap: 6px; }
.level-btn { width: 46px; height: 46px; background: var(--panel); border: 1px solid var(--line); border-radius: 9px; color: var(--text); font: inherit; font-weight: 600; cursor: pointer; }
.level-btn.active { border-color: var(--accent); color: var(--accent); background: rgba(245, 181, 46, .08); }
.btn-outline { display: block; background: none; border: 1px solid var(--line); border-radius: 8px; color: var(--text); font: inherit; font-size: 13px; font-weight: 600; padding: 8px 13px; cursor: pointer; }
.btn-outline:hover { border-color: var(--accent); }
.limit-controls { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.limit-input { width: 96px; margin: 0; }
.limit-sep, .limit-unit { color: var(--muted); font-size: 13px; }
.is-soon .limit-input { opacity: .45; }
.side-teams { display: grid; gap: 8px; margin-top: 14px; }
.side-team { display: flex; align-items: center; gap: 12px; background: var(--panel-2); border: 1px solid var(--line); border-radius: 9px; padding: 8px 12px; }
.side-team-no { font-weight: 700; color: var(--muted); }
.side-team-state { font-size: 14px; font-weight: 600; }
@media (max-width: 640px) { .setting-row { flex-wrap: wrap; } .limit-input { width: 76px; } }

.switch.locked { opacity: .4; }
.switch.locked input { cursor: not-allowed; }
.feature-summary { margin-top: 14px; padding: 12px 16px; border: 1px solid rgba(245, 181, 46, .4); background: rgba(245, 181, 46, .07); border-radius: 10px; font-size: 14px; line-height: 1.5; }
.segment-inline { display: inline-grid; grid-auto-flow: column; grid-template-columns: none; }
.segment-inline button { padding: 8px 14px; }
.range-inputs { display: flex; align-items: center; gap: 8px; }
.range-inputs input { margin: 0; }
.advanced { margin-top: 18px; border: 1px solid var(--line); border-radius: 10px; padding: 12px 16px; }
.advanced summary { display: flex; justify-content: space-between; align-items: center; font-weight: 600; font-size: 14px; cursor: pointer; }
.side-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.side-tile { background: var(--panel-2); border: 1px solid var(--line); border-radius: 9px; padding: 9px 11px; }
.side-tile strong { display: block; font-size: 17px; }
.side-tile span { font-size: 12px; color: var(--muted); }

.res-hint { margin-bottom: 10px; }
.res-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
.res-card { background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.res-card.on { border-color: var(--accent); }
.res-card-head { display: flex; align-items: center; gap: 9px; margin-bottom: 4px; }
.res-card-head img { width: 24px; height: 24px; object-fit: contain; }
.res-card-head .node-name { flex: 1; }
.res-need { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.res-need span { white-space: nowrap; }
.res-need input { margin: 0; }
@media (max-width: 640px) { .res-cards { grid-template-columns: 1fr; } }

.chip-order { display: inline-block; width: 18px; height: 18px; line-height: 18px; text-align: center; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-size: 12px; font-weight: 700; }
.card-label { margin-top: 10px; margin-bottom: 4px; }
.card-input { margin: 0; }
.tier-chips { margin-top: 4px; gap: 5px; }
.tier-chips .chip { padding: 5px 9px; font-size: 13px; }

.feature-note { margin-top: 14px; padding: 12px 16px; border: 1px solid var(--line); background: var(--panel-2); border-radius: 10px; font-size: 14px; }

.reserve-card { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px 18px; }
.res-icon { width: 18px; height: 18px; object-fit: contain; vertical-align: -3px; margin-right: 6px; }
.march-list { display: grid; gap: 8px; padding: 12px 18px 16px; }
.auto-off { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; padding-top: 4px; }
.soon-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.soon-card { padding: 14px 18px; }
.subtabs { display: flex; gap: 6px; margin-bottom: 14px; }
.subtab { background: none; border: 0; color: var(--muted); font: inherit; font-weight: 600; padding: 7px 13px; border-radius: 8px; cursor: pointer; }
.subtab.active { background: var(--panel-2); color: var(--text); }
.info-card { padding: 16px 18px; }
.info-card .status-list { margin-top: 12px; }
.status-list dd.wait { color: var(--muted); font-weight: 400; }
.army-grid { margin-top: 12px; }
.army-grid .team-card { cursor: default; }
.steps { margin: 14px 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: 10px; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 30px 1fr; column-gap: 8px; font-size: 14px; }
.steps li::before { content: counter(step); grid-row: span 2; width: 26px; height: 26px; line-height: 26px; text-align: center; border-radius: 50%; background: var(--panel-2); border: 1px solid var(--line); color: var(--muted); font-weight: 700; }
.steps li span { color: var(--muted); font-size: 13px; }
@media (max-width: 900px) { .soon-grid { grid-template-columns: minmax(0, 1fr); } .reserve-card { flex-wrap: wrap; } }

.general-account { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 14px; padding: 12px 16px; background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; font-size: 14px; }
.chip-tag { margin-left: 6px; font-size: 11px; color: var(--muted); }
.limit-input.short { width: 64px; }
.rest-list { display: grid; gap: 8px; margin-top: 12px; }
.rest-row { display: flex; align-items: center; gap: 8px; }
.rest-row input { width: 72px; margin: 0; }
.rest-list .btn-outline { justify-self: start; }
.break-grid { display: grid; gap: 12px; margin-top: 12px; }
.break-grid .chips { margin-top: 5px; }
.team-choice > .team-card { width: 100%; }
.recall-control { margin-top: 8px; }
.recall-btn { width: 100%; }
.recall-result { margin-top: 6px; overflow-wrap: anywhere; }
