/* ===== 主题变量：改配色只动这里 ===== */
:root {
  --bg: #0f0f14;
  --bg-panel: #1a1a24;
  --text: #e8e8ee;
  --text-dim: #9a9aac;
  --accent: #e10600;        /* F1 红 */
  --accent-2: #f7d354;      /* 领奖台金 */
  --border: #2c2c3a;
  --radius: 10px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== 顶栏 ===== */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-bottom: 3px solid var(--accent);
  background: var(--bg-panel);
  position: sticky;
  top: 0;
}
.logo { font-size: 22px; font-weight: 800; letter-spacing: 1px; font-style: italic; }
.logo span { color: var(--accent); }

.tabs { display: flex; gap: 8px; }
.tab {
  background: transparent;
  color: var(--text-dim);
  border: 1px solid var(--border);
  padding: 8px 18px;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 15px;
  transition: all .15s;
}
.tab:hover { color: var(--text); border-color: var(--accent); }
.tab.active { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 600; }

/* ===== 视图与面板 ===== */
.view { flex: 1; padding: 24px; max-width: 1100px; margin: 0 auto; width: 100%; }
.hidden { display: none; }

.panel {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 20px;
  overflow-x: auto;
}
.panel h2 {
  font-size: 16px;
  color: var(--text-dim);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.standings-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 800px) { .standings-row { grid-template-columns: 1fr; } }

/* ===== 表格 ===== */
table { width: 100%; border-collapse: collapse; font-size: 14px; }
td, th { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--border); }
tr:last-child td { border-bottom: none; }
td.pos { width: 36px; color: var(--text-dim); }
tr.top-3 td.pos { color: var(--accent-2); font-weight: 700; }
td.pts { text-align: right; font-weight: 700; }
td.team { color: var(--text-dim); font-size: 13px; }
td:first-child { text-align: center; }

/* ===== Todo ===== */
.todo-panel { max-width: 560px; margin: 0 auto; }
#todo-form { display: flex; gap: 10px; margin-bottom: 14px; }
#todo-input {
  flex: 1;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 10px 14px;
  font-size: 15px;
  outline: none;
}
#todo-input:focus { border-color: var(--accent); }
#todo-form button {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 10px 20px;
  font-size: 15px;
  cursor: pointer;
}
#todo-list { list-style: none; }
.todo-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 4px;
  border-bottom: 1px solid var(--border);
}
.todo-item:last-child { border-bottom: none; }
.todo-item input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--accent); cursor: pointer; }
.todo-item .text { flex: 1; }
.todo-item.done .text { text-decoration: line-through; color: var(--text-dim); }
.todo-item .del {
  background: none; border: none; color: var(--text-dim);
  cursor: pointer; font-size: 16px; padding: 2px 6px;
}
.todo-item .del:hover { color: var(--accent); }
.empty { color: var(--text-dim); text-align: center; padding: 20px 0; font-size: 14px; }

.foot {
  text-align: center;
  color: var(--text-dim);
  font-size: 12px;
  padding: 16px;
}
