/* The game shell stays compact so the world gets the window, not the chrome. */
.game-page {
  --ink: #d6dfd0;
  --muted: #a0af9e;
  --line: #35463c;
  background: #111c18;
  color: var(--ink);
  color-scheme: dark;
}
#gameApp { height: 100dvh; display: flex; flex-direction: column; }
.header {
  height: 56px;
  flex: 0 0 56px;
  padding: 0 16px;
  gap: 20px;
  background: #15231d;
  border-color: var(--line);
}
.brand { color: #e0e4d3; gap: 9px; }
.brand svg { width: 28px; height: 32px; stroke: #b1c19f; }
.brand div { font-size: 19px; letter-spacing: 2px; }
.brand span { display: none; }
.topnav { gap: 22px; margin-left: auto; }
.topnav button { color: var(--muted); }
.topnav .selected { color: #e0e6d6; }
.topnav .selected:after { background: #b4bc85; height: 2px; }
.realm { margin-left: auto; }
.realm span, .realm button { color: var(--muted); }
.header > .wallet-button, .header > .menu-button {
  background: #23362a !important;
  color: #dfd9b9 !important;
  border-color: #526246 !important;
  margin-left: 0;
  min-height: 32px;
  padding: 7px 11px !important;
}
.layout {
  width: 100%; max-width: none; flex: 1; min-height: 0;
  grid-template-columns: minmax(0, 1fr) 270px;
  gap: 12px; padding: 8px 12px 0;
}
.play-column { display: flex; flex-direction: column; min-height: 0; }
.worldbar { flex: 0 0 30px; height: 30px; padding: 0 2px 8px; color: var(--muted); }
.worldbar strong { color: #c0ceb7; }
.world-tools { display: flex; align-items: center; gap: 20px; }
.world-tools button { color: #c8d3bc; min-height: 25px; }
.world-tools button span { margin-left: 5px; }
#expandWorld { color: #dec995; }
.world-frame {
  flex: 1; height: auto; min-height: 0;
  border: 2px solid #465746; border-radius: 2px;
  box-shadow: none; background: #1b3029;
}
#world { filter: brightness(.78) saturate(.86); }
.player-hud { top: 12px; left: 12px; padding: 8px; background: #14231eed; border-color: #84927466; }
.minimap-wrap { top: 12px; right: 12px; width: 130px; background: #192a23; }
#minimap { height: 90px; filter: brightness(.85); }
.minimap-wrap b { display: none; }
.actionbar { background: #14251ff2; border-color: #7b8a6577; }
.actionbar button { background: #334538; }
.chat-panel { flex-shrink: 0; margin-top: 6px; background: #17251e; border-color: var(--line); }
.chat-head { height: 27px; border-color: var(--line); }
.chat-head button, #chatForm button { color: #a9b99e; }
.chat-head button.active { color: #e0dfc2; }
.chat-head button.active:after { background: #b1b67d; }
.chat-head > span { color: #8fa083; }
.chat-messages { height: 42px; padding: 2px 12px; scrollbar-color: #4a6149 transparent; }
.chat-message { line-height: 19px; }
.chat-message time { color: #82977f; }
.chat-message b { color: #c1cb9b; }
.chat-message span { color: #b9c7ae; }
.chat-message.system span { color: #9ba992; }
.chat-message.system b { color: #c9b47e; }
#chatForm { height: 29px; border-color: var(--line); }
#chatInput { color: #d8e0ca; }
#chatInput::placeholder { color: #93a48b; }
.footer { height: 24px; flex: 0 0 24px; color: #95a68c; }
.footer button, .footer kbd { color: #b2c0a6; border-color: #445640; }
.sidebar { padding-top: 30px; min-height: 0; overflow-y: auto; scrollbar-width: thin; scrollbar-color: #4a6149 transparent; padding-bottom: 12px; }
.quest-card { padding: 16px 14px 0; background: #1c2c23; border-color: #3f4d39; }
.quest-card:before { background: #a89460; }
.eyebrow, .eyebrow > span:last-child { color: #a4b095; }
.quest-card h2 { color: #e4dfc3; font-size: 21px; margin: 12px 0 8px; }
.quest-card > p { color: #a9b49c; margin-bottom: 12px; }
.objective { color: #c1cbb4; margin: 10px 0; }
.objective i { border-color: #718363; }
.objective b { color: #a9b59b; }
.objective.done { color: #bfcc96; }
.quest-bottom { height: 36px; margin-top: 12px; border-color: #3d4c36; color: #c4ba93; }
.quest-bottom b { color: #e0c98c; }
.quest-bottom button { color: #afbd9e; }
.side-tabs { margin-top: 12px; height: 34px; border-color: var(--line); }
.side-tabs button { color: #a0b093; }
.side-tabs button.active { color: #e0dfbe; }
.side-tabs button.active:after { background: #b0b67f; }
.side-tabs small { background: #34462e; color: #c3ceaf; }
.side-content { min-height: 0; padding-top: 12px; }
.section-heading, .section-heading > span:last-child { color: #9bad90; }
.section-heading { margin-bottom: 10px; }
.inventory-grid { gap: 4px; }
.item-slot { background: #1b2a20; border-color: #344731; }
.item-slot.filled { background: #2c3d2a; border-color: #62714b; }
.item-slot b { color: #e0cf90; }
.wallet { color: #a7b69b; border-color: var(--line); margin-top: 8px; }
.wallet > b, .wallet small { color: #dac38b; }
.equipment { padding-top: 10px; }
.equipment span, .equipment > small { color: #a4b393; }
.equipment strong { color: #d1dbc0; }
.backpack-tip, .people-card, .side-foot { display: none; }
.skill-row, .agent-row { border-color: var(--line); }
.skill-row p, .agent-row span, .agent-row small { color: #a2b295; }
.skill-row b, .agent-row strong { color: #d0daba; }
.skill-track { background: #334530; }
.live-label { color: #becb92 !important; }
dialog { background: #1b2c23; border-color: #62724f; color: #e0e4cf; box-shadow: 0 25px 90px #08100dcc; }
.modal-heading, .modal-stat, .key-row { border-color: #3c5039; color: #b3c0a4; }
#modalBody p, #modalBody .modal-note, .settings-row, .map-legend { color: #b2c0a3; }
.modal-stat b, .key-row kbd { color: #dddfbb; }
.secondary { color: #d1dabc; border-color: #65764f; }
.settings-row select, .agent-badge { background: #2a3e2a; color: #d4dfbe; border-color: #63724c; }
.toast { background: #233627f2; color: #eee2b9; border-color: #a18c58; }
.world-expanded .layout { grid-template-columns: minmax(0, 1fr); padding-bottom: 8px; }
.world-expanded .sidebar, .world-expanded .chat-panel, .world-expanded .footer { display: none; }
@media (max-width: 1100px) {
  .header { gap: 12px; }
  .realm > div { display: none; }
  .realm button { margin-left: 0; }
  .layout { grid-template-columns: minmax(0, 1fr) 240px; gap: 8px; padding: 6px 8px 0; }
  .topnav { gap: 14px; }
  .brand div { font-size: 17px; }
}
@media (max-width: 760px) {
  #gameApp { height: auto; min-height: 100dvh; }
  .header { height: 52px; flex-basis: 52px; padding: 0 10px; gap: 6px; }
  .header > .wallet-button { margin-left: auto; }
  .header > .menu-button { margin-left: 0; }
  .header .brand div { font-size: 15px; letter-spacing: 1px; }
  .header .brand svg { width: 23px; }
  .layout { display: block; padding: 5px 6px 0; }
  .play-column { height: calc(100dvh - 57px); min-height: 420px; }
  .worldbar { font-size: 7px; }
  .worldbar > div:first-child { font-size: 0; }
  .worldbar .live-dot, .worldbar .slash { display: none; }
  .worldbar strong { font-size: 10px; }
  .world-tools { gap: 14px; }
  .world-tools button { font-size: 9px; }
  .world-frame { min-height: 0; }
  .player-hud { top: 10px; left: 8px; }
  .minimap-wrap { width: 90px; top: 10px; right: 8px; }
  #minimap { height: 62px; }
  .sidebar { overflow: visible; padding-top: 12px; }
  .sidebar.mobile-panel { display: flex; }
  .chat-head { height: 26px; }
  .chat-head button { font-size: 10px; }
  .chat-messages { height: 38px; }
  #chatInput { font-size: 11px; }
  .world-expanded .sidebar { display: none; }
  .world-expanded .play-column { height: calc(100dvh - 65px); }
}
