* { box-sizing: border-box; }
body { margin: 0; color: #e8dcc4; font: 15px/1.7 "Microsoft YaHei", "PingFang SC", serif; min-height: 100vh;
  background: radial-gradient(ellipse at top, #2a2219 0%, #110e0a 70%); }
button, select, input, textarea { font: inherit; color: #e8dcc4; background: #2b241b; border: 1px solid #6b5636; border-radius: 4px; padding: 5px 12px; }
button { cursor: pointer; margin: 3px; }
button:hover, select:hover { background: #4a3b26; border-color: #c9a45c; }
button.on { background: #6b5636; color: #fff3d6; }
input, textarea, select { width: 100%; }
textarea { font-family: monospace; font-size: 12px; }
.panel { background: rgba(30, 25, 18, .92); border: 1px solid #5a4830; border-radius: 6px; padding: 14px; box-shadow: 0 0 20px #0008; }
.title-screen { text-align: center; padding-top: 16vh; }
.title-screen h1 { font-size: 42px; color: #e6c27a; letter-spacing: 6px; margin: 0; text-shadow: 0 0 18px #a8823c88; }
.title-screen .sub { color: #a8946e; letter-spacing: 4px; }
.whisper { color: #8d7d63; font-style: italic; margin: 40px 0; }
.title-screen button { padding: 10px 28px; font-size: 17px; display: block; margin: 10px auto; min-width: 240px; }
.create { max-width: 760px; margin: 30px auto; }
.create h2 { color: #e6c27a; margin-top: 0; }
.create label { display: block; margin: 8px 0; color: #c8b38a; }
.row { display: flex; gap: 12px; }
.row label { flex: 1; }
.btns { margin-top: 12px; }
.btns.small button { padding: 2px 10px; font-size: 13px; }
.game { display: flex; gap: 12px; padding: 12px; height: 100vh; }
.left { width: 430px; display: flex; flex-direction: column; }
.tabbody { flex: 1; overflow-y: auto; font-size: 14px; }
.right { flex: 1; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.log { flex: 1; overflow-y: auto; }
.log p { margin: 4px 0; padding: 3px 0; border-bottom: 1px dashed #3a3022; }
.log .t { color: #8d7d63; font-size: 12px; margin-right: 8px; }
.log .event { color: #f0d9a8; }
.log .hito { color: #b9a4e6; }
.log .death { color: #e67a6a; }
.actions .hint { color: #8d7d63; font-size: 13px; }
.cat { margin: 6px 0; display: flex; flex-wrap: wrap; align-items: center; }
.cat > span { color: #c9a45c; width: 44px; font-size: 13px; }
.cat select { width: auto; margin: 3px; }
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 10px; }
.kv1 div, .kv div { padding: 1px 0; }
.kv1 { margin-top: 8px; border-top: 1px solid #3a3022; padding-top: 6px; }
.bar { display: inline-block; width: 60px; height: 7px; background: #3a3022; border-radius: 4px; vertical-align: middle; }
.bar i { display: block; height: 100%; background: linear-gradient(90deg, #8a6b33, #e6c27a); border-radius: 4px; }
.npc { border-bottom: 1px solid #3a3022; padding: 6px 0; }
.npc.dead { opacity: .45; }
.dim { color: #8d7d63; font-size: 13px; }
.red { color: #e67a6a; }
h3 { color: #c9a45c; font-size: 15px; margin: 10px 0 4px; }
ul { padding-left: 20px; margin: 4px 0; }
.chron li { margin: 3px 0; }
.deathbox, .dreambox { text-align: center; }
.dreambox p { color: #b9a4e6; }
@media (max-width: 860px) { .game { flex-direction: column; height: auto; } .left { width: 100%; } .log { max-height: 50vh; } }

/* 返回小游戏列表（标题页左上角） */
.home-link {
  position: absolute; top: 16px; left: 16px; width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px; border: 1px solid #6b5636; background: #2b241b;
  color: #e8dcc4; text-decoration: none; font-size: 18px;
}
.home-link:hover { background: #4a3b26; border-color: #c9a45c; }
.home-link:focus-visible { outline: 2px solid #e6c27a; outline-offset: 2px; }
