/* Master of Magic multiplayer lounge — dark stone + gold, plain CSS.
   [MP-STYLE] 2026-11-26: restyled to the game's own art direction (Dan:
   "make the wait room match the artistic style of the game") — obsidian
   stone, framed stone-and-gold panels, gold serif display lettering like
   the main menu. Presentation only: same selectors, same layout. */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: #0a0705;
  background: radial-gradient(1200px 620px at 50% -80px, #251b0f 0%, #14100b 55%, #0a0705 100%) fixed, #0a0705;
  color: #e8ddc8;
  font: 15px/1.5 Georgia, "Times New Roman", serif;
  min-height: 100vh;
}
.hidden { display: none !important; }
h1 {
  color: #eec25e; margin: 0; font-size: 30px; letter-spacing: 1.5px;
  font-variant: small-caps; font-weight: bold;
  text-shadow: 0 2px 0 #000, 0 0 14px rgba(224, 168, 60, 0.30);
}
h2 {
  color: #e0a83c; margin: 0 0 10px; font-size: 19px;
  font-variant: small-caps; letter-spacing: 1.2px;
  text-shadow: 0 1px 0 #000, 0 0 10px rgba(224, 168, 60, 0.22);
  border-bottom: 1px solid #57471f; padding-bottom: 4px;
  box-shadow: 0 1px 0 rgba(244, 205, 106, 0.12);
}
h3 {
  color: #d8a93b; margin: 14px 0 6px; font-size: 16px;
  font-variant: small-caps; letter-spacing: 1px;
  text-shadow: 0 1px 0 #000;
}
header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px;
  background: linear-gradient(180deg, #211a0f 0%, #100d0a 100%);
  border-bottom: 2px solid #8a743a;
  box-shadow: 0 1px 0 #060403, 0 3px 14px rgba(0, 0, 0, 0.6);
}
main {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px; padding: 16px 20px; max-width: 1200px; margin: 0 auto;
}
.panel {
  background: linear-gradient(180deg, #251c10 0%, #1a130a 55%, #140e07 100%);
  border: 1px solid #8a743a; border-radius: 6px;
  box-shadow: inset 0 0 0 1px #060403, inset 0 0 0 3px #171208,
    inset 0 0 0 4px #463512, inset 0 1px 0 rgba(244, 205, 106, 0.14),
    0 3px 14px rgba(0, 0, 0, 0.5);
  padding: 14px 16px;
}
button {
  background: linear-gradient(180deg, #5d4a20 0%, #3a2d13 100%);
  color: #ffe9a8; border: 1px solid #8a743a;
  border-radius: 4px; padding: 5px 12px; font: inherit; cursor: pointer;
  text-shadow: 0 1px 0 #000;
  box-shadow: inset 0 1px 0 rgba(244, 205, 106, 0.25), 0 1px 3px rgba(0, 0, 0, 0.5);
}
button:hover {
  background: linear-gradient(180deg, #6f5726 0%, #473718 100%);
  box-shadow: inset 0 1px 0 rgba(244, 205, 106, 0.35), 0 0 8px rgba(224, 168, 60, 0.35);
}
button.gold {
  background: linear-gradient(180deg, #b98c2a 0%, #8a6a1f 100%);
  color: #fff8e6; border-color: #eec25e; font-weight: bold;
}
button.gold:hover {
  background: linear-gradient(180deg, #cfa53a 0%, #a37e24 100%);
  box-shadow: inset 0 1px 0 rgba(255, 248, 230, 0.4), 0 0 10px rgba(224, 168, 60, 0.45);
}
button:disabled { opacity: 0.45; cursor: default; }
input, select {
  background: #0d0a06; color: #e8ddc8; border: 1px solid #57471f;
  border-radius: 4px; padding: 6px 8px; font: inherit; width: 100%;
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.7);
}
input:focus, select:focus {
  outline: none; border-color: #c9a227;
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.7), 0 0 6px rgba(201, 162, 39, 0.35);
}
label { display: block; margin: 10px 0; }
.error { color: #e07a5f; min-height: 1.2em; }
.muted { color: #b3a284; }
.note { color: #b3a284; font-size: 13px; text-align: center; }

/* login */
.login-panel { max-width: 380px; margin: 10vh auto 0; text-align: left; }
.login-panel h1, .login-panel .subtitle { text-align: center; }
.login-panel .subtitle { color: #cdb277; margin-top: 2px; }
.login-panel button { width: 100%; margin-top: 6px; padding: 9px; }

/* players */
.players, .games { list-style: none; margin: 0; padding: 0; }
.players li, .games li {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 4px; border-bottom: 1px solid #33270f;
}
.players li:last-child, .games li:last-child { border-bottom: none; }
.dot { width: 10px; height: 10px; border-radius: 50%; flex: 0 0 auto; }
.dot.online { background: #7bc47f; }
.dot.in-game { background: #d8a93b; }
.dot.offline { background: #5a5148; }
.player-name { font-weight: bold; }
.player-status { color: #b3a284; font-size: 13px; margin-left: auto; text-align: right; }
.players .challenge-btn { margin-left: 8px; }

/* challenge form + cards */
.challenge-form {
  background: #120d07; border: 1px solid #57471f; border-radius: 6px;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6);
  padding: 10px 12px; margin: 8px 0;
}
.challenge-form .row { display: flex; gap: 10px; flex-wrap: wrap; }
.challenge-form label { flex: 1 1 120px; margin: 4px 0; font-size: 13px; }
.challenge-form .actions { margin-top: 8px; display: flex; gap: 8px; }
.card {
  background: linear-gradient(180deg, #251c10 0%, #1a130a 55%, #140e07 100%);
  border: 1px solid #8a743a; border-radius: 6px;
  box-shadow: inset 0 0 0 1px #060403, inset 0 0 0 3px #171208,
    inset 0 0 0 4px #463512, inset 0 1px 0 rgba(244, 205, 106, 0.14),
    0 3px 14px rgba(0, 0, 0, 0.5);
  padding: 10px 12px; margin: 8px 0;
}
.card .setup { color: #cdb277; font-size: 13px; }
.card .actions { margin-top: 8px; display: flex; gap: 8px; }
.card.declined { opacity: 0.75; border-color: #5a3b2e; }

/* games */
.games li { cursor: pointer; }
.games li:hover { background: rgba(224, 168, 60, 0.07); }
.games .setup { color: #cdb277; font-size: 13px; display: block; }
.games .when { color: #b3a284; font-size: 13px; margin-left: auto; text-align: right; }

/* chat */
.chat-log {
  height: 260px; overflow-y: auto; background: #0d0a06;
  border: 1px solid #57471f; border-radius: 4px; padding: 8px 10px;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.7);
}
.chat-log p { margin: 3px 0; }
.chat-log .who { color: #eec25e; font-weight: bold; }
.chat-log .when { color: #6f6350; font-size: 12px; margin-left: 6px; }
.chat-form { display: flex; gap: 8px; margin-top: 8px; }
.chat-form input { flex: 1 1 auto; }

/* match placeholder */
.match-panel { text-align: center; }
.big-note {
  font-size: 22px; color: #eec25e; margin: 18px 0 8px;
  font-variant: small-caps; letter-spacing: 1px;
  text-shadow: 0 1px 0 #000, 0 0 10px rgba(224, 168, 60, 0.25);
}

/* toast */
.toast {
  position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%);
  background: linear-gradient(180deg, #3a2d13 0%, #2c2210 100%);
  border: 1px solid #e0a83c; color: #fff8e6;
  padding: 10px 18px; border-radius: 6px; z-index: 50; max-width: 90vw;
  text-align: center; box-shadow: 0 4px 18px rgba(0, 0, 0, 0.6);
}
.me-box { display: flex; align-items: center; gap: 12px; }

/* [MP-CUSTOM] wizard customization form in the tables list — same inset
   stone panel treatment as .challenge-form, gold small-caps headings. */
.wiz-form {
  background: #120d07; border: 1px solid #57471f; border-radius: 6px;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6);
  padding: 10px 12px; margin: 10px 0 4px; flex-basis: 100%;
}
.wiz-title {
  color: #d8a93b; font-variant: small-caps; letter-spacing: 1px;
  font-size: 16px; text-shadow: 0 1px 0 #000; margin-bottom: 4px;
}
.wiz-sub { color: #cdb277; font-variant: small-caps; letter-spacing: 0.6px; margin: 6px 0 2px; }
.wiz-status { color: #b3a284; font-size: 13px; margin-bottom: 6px; }
.wiz-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.wiz-row label { flex: 1 1 140px; margin: 4px 0; font-size: 13px; }
.wiz-row button { margin: 4px 0; }
.wiz-books { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.wiz-books .wiz-sub { flex-basis: 100%; }
.wiz-books label { flex: 0 1 86px; margin: 4px 0; font-size: 13px; }
.wiz-retorts { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 2px 12px; }
.wiz-retorts .wiz-sub { grid-column: 1 / -1; }
.wiz-retort { display: flex; align-items: baseline; gap: 4px; margin: 2px 0; font-size: 13px; }
.wiz-retort input { width: auto; flex: 0 0 auto; }
.wiz-picks { color: #ffe9a8; margin-top: 8px; }
.wiz-actions { margin-top: 8px; display: flex; gap: 8px; flex-wrap: wrap; }
.wiz-form .err { color: #ff9d8a; min-height: 1.2em; }
