/* 「有空」样式：与整站（首页/游戏厅）对齐——奶油底 + 墨黑 + 砖红点缀；
   绿色仅保留给「有空/可选中」的语义色 */
* { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  /* 整站通用色（同 home / games） */
  --bg: #faf9f7;
  --ink: #1a1a1a;
  --muted: #8a8a8a;
  --line: #e5e2dd;
  --accent: #b3342a;
  --accent-dark: #93291f;
  /* 「有空」语义绿：仅用于可约/已勾选/最佳时段 */
  --green: #27ae60;
  --green-dark: #1e874b;
  --green-tint: #e9f7ef;
  --green-mid: #a9dfbf;
  --orange: #e67e22;
  --orange-tint: #fdf2e3;
  --disabled: #f0eee9;
}
body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", "Segoe UI", sans-serif;
  color: var(--ink); background: var(--bg); line-height: 1.6;
  max-width: 720px; margin: 0 auto; padding: 24px 16px 64px;
}
h1 { font-size: 22px; margin-bottom: 8px; letter-spacing: .5px; }
h2 { font-size: 15px; margin: 28px 0 12px; color: var(--muted); font-weight: 600; letter-spacing: 1px; }
.muted { color: var(--muted); font-size: 14px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 18px; margin-bottom: 12px;
}
input[type=text], input[type=password], input[type=date], textarea {
  width: 100%; padding: 11px 13px; border: 1.5px solid var(--line); border-radius: 8px;
  font-size: 16px; font-family: inherit; margin-bottom: 10px; background: #fff;
  color: var(--ink); outline: none; transition: border-color .15s;
}
input:focus, textarea:focus { border-color: var(--accent); }
textarea { resize: vertical; min-height: 60px; }
button, .btn {
  display: inline-block; padding: 11px 22px; border: none; border-radius: 8px;
  background: var(--ink); color: #fff; font-size: 16px; cursor: pointer;
  text-decoration: none; text-align: center; font-family: inherit;
  transition: background .15s;
}
button:hover { background: #000; }
button:active { opacity: .85; }
button.secondary { background: var(--disabled); color: var(--ink); }
button.secondary:hover { background: var(--line); }
button.danger { background: var(--accent); }
button.danger:hover { background: var(--accent-dark); }
button.block { width: 100%; }
button:disabled { background: #c9c4bc; cursor: default; }
.error { color: var(--accent); font-size: 14px; margin-bottom: 10px; }
.success { color: var(--green); font-size: 14px; margin-bottom: 10px; }

/* 事件列表 */
.event-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.event-row .info { flex: 1; min-width: 0; }
.event-row .title { font-weight: 600; }
.event-row .sub { font-size: 13px; color: var(--muted); }
.event-row .btn, .event-row button { padding: 8px 14px; font-size: 14px; }

/* 打勾表格 */
.grid-wrap {
  overflow-x: auto; -webkit-overflow-scrolling: touch;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px;
}
table.pick-grid { border-collapse: separate; border-spacing: 4px; }
table.pick-grid th, table.pick-grid td {
  min-width: 58px; height: 46px; text-align: center; vertical-align: middle;
  border-radius: 8px; font-size: 14px;
}
table.pick-grid thead th { background: var(--bg); padding: 6px 4px; height: auto; }
table.pick-grid thead th .d { font-weight: 700; font-size: 15px; }
table.pick-grid thead th .w { font-size: 12px; color: var(--muted); font-weight: 400; }
table.pick-grid thead th.wk { background: var(--orange-tint); }
table.pick-grid thead th.wk .w { color: var(--orange); font-weight: 600; }
table.pick-grid .slot-label {
  position: sticky; left: 0; z-index: 1; background: #fff;
  min-width: 52px; font-size: 13px; color: var(--muted); font-weight: 600;
}
table.pick-grid td.cell { cursor: pointer; background: var(--bg); user-select: none; -webkit-tap-highlight-color: transparent; }
table.pick-grid td.cell:hover { background: var(--green-tint); }
table.pick-grid td.cell.on { background: var(--green); color: #fff; font-weight: 700; }
table.pick-grid td.cell.partial { background: var(--green-mid); color: #fff; font-weight: 700; }
table.pick-grid td.cell.na { background: var(--disabled); color: #c3c0b8; cursor: default; }
.hint { font-size: 13px; color: var(--muted); margin: 8px 2px 0; }

/* 结果网格 */
table.grid { border-collapse: separate; border-spacing: 3px; font-size: 13px; }
table.grid th, table.grid td { padding: 7px 10px; text-align: center; white-space: nowrap; border-radius: 6px; }
table.grid thead th { background: var(--bg); font-weight: 600; line-height: 1.4; }
table.grid thead th.best { background: var(--green-tint); color: var(--green-dark); }
table.grid tbody th { position: sticky; left: 0; background: #fff; text-align: left; font-weight: 600; }
table.grid td { background: var(--bg); color: #c3c0b8; }
table.grid td.yes { background: var(--green-tint); color: var(--green); font-weight: 700; }
table.grid td.yes.best { background: var(--green); color: #fff; }
.best-banner {
  background: var(--green-tint); border-radius: 12px;
  padding: 14px 18px; margin-bottom: 14px; border-left: 4px solid var(--green);
}
.best-banner .t { font-weight: 700; color: var(--green-dark); margin-bottom: 4px; }

/* 结果热力图（复用 pick-grid 骨架） */
table.heat td.hcell { font-weight: 600; cursor: pointer; }
table.heat td.h0 { background: var(--bg); color: #c3c0b8; cursor: default; }
table.heat td.h1 { background: #e9f7ef; color: var(--green-dark); }
table.heat td.h2 { background: #b7e4cd; color: var(--green-dark); }
table.heat td.h3 { background: #6fc795; color: #fff; }
table.heat td.hbest { background: var(--green); color: #fff; }
.who-line {
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  padding: 10px 14px; margin-top: 10px; font-size: 14px;
}
