:root {
  --color-ivory: #faf3e6;
  --color-ivory-soft: #f3e9d8;
  --color-navy: #1b2a41;
  --color-navy-deep: #101823;
  --color-copper: #b5652e;
  --color-copper-light: #d98a4f;
  --color-ink-muted: #5b6472;

  --font-display: "Playfair Display", Georgia, serif;
  --font-reading: "Source Serif 4", Georgia, serif;
  --font-ui: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;

  /* Used by the ebook reader's font-size control once that page exists. */
  --reading-font-size: 1.125rem;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--color-ivory);
  color: var(--color-navy);
  font-family: var(--font-ui);
  line-height: 1.6;
}

a {
  color: inherit;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(27, 42, 65, 0.1);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--color-navy);
}

.brand-mark {
  height: 32px;
  width: auto;
}

.brand-word {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
}

.site-nav {
  display: flex;
  gap: 1.5rem;
  font-weight: 500;
}

.site-nav a {
  text-decoration: none;
}

.site-nav a:hover {
  color: var(--color-copper);
}

main {
  max-width: 760px;
  margin: 0 auto;
  padding: 3rem 1.5rem 5rem;
}

.hero {
  text-align: center;
  padding: 1rem 0 3rem;
}

.hero-logo {
  max-width: 420px;
  width: 100%;
  height: auto;
  margin-bottom: 1.5rem;
}

.hero-copy {
  font-family: var(--font-reading);
  font-size: 1.05rem;
  color: var(--color-ink-muted);
  max-width: 46ch;
  margin: 0 auto 2rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 500;
  font-family: var(--font-ui);
}

.btn-primary {
  background: var(--color-navy);
  color: var(--color-ivory);
}

.btn-primary:hover {
  background: var(--color-navy-deep);
}

.btn-secondary {
  border: 1px solid var(--color-copper);
  color: var(--color-copper);
}

.btn-secondary:hover {
  background: var(--color-copper);
  color: var(--color-ivory);
}

.page-header h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  margin-bottom: 0.25rem;
}

.page-header p {
  color: var(--color-ink-muted);
}

.empty-state {
  margin-top: 2rem;
  padding: 2rem;
  background: var(--color-ivory-soft);
  border-radius: 6px;
  color: var(--color-ink-muted);
  text-align: center;
}

.site-footer {
  text-align: center;
  padding: 2rem 1.5rem;
  color: var(--color-ink-muted);
  font-size: 0.85rem;
  border-top: 1px solid rgba(27, 42, 65, 0.1);
}

.not-found {
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--color-ink-muted);
}

@media (max-width: 600px) {
  .site-header {
    flex-direction: column;
    gap: 0.75rem;
  }

  .site-nav {
    gap: 1rem;
  }
}

/* ---------- Reading content (posts, chapters) ---------- */

.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.post-list-item {
  padding: 1.5rem 0;
  border-bottom: 1px solid rgba(27, 42, 65, 0.1);
}

.post-list-item h2 {
  font-family: var(--font-display);
  margin: 0 0 0.25rem;
}

.post-date {
  color: var(--color-ink-muted);
  font-size: 0.85rem;
  margin: 0 0 0.5rem;
}

.post-summary {
  color: var(--color-ink-muted);
  margin: 0;
}

.book-latest-chapter a {
  color: var(--color-copper);
  text-decoration: none;
}

.book-latest-chapter a:hover {
  text-decoration: underline;
}

.related-book-note {
  font-style: italic;
  color: var(--color-copper);
}

.reading-content h1 {
  font-family: var(--font-display);
  font-size: 2.1rem;
}

.reading-body {
  font-family: var(--font-reading);
  font-size: var(--reading-font-size);
  line-height: 1.75;
}

.reading-body p {
  margin: 0 0 1.2em;
}

.reading-body h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.3;
  margin: 2.2rem 0 0.75rem;
}

.reading-body h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  line-height: 1.3;
  margin: 1.8rem 0 0.5rem;
}

.reading-body blockquote {
  margin: 1.75rem 0;
  padding: 0.25rem 1.5rem;
  border-left: 3px solid var(--color-copper);
  font-style: italic;
  color: var(--color-ink-muted);
}

.reading-body ul,
.reading-body ol {
  margin: 0 0 1.2em;
  padding-left: 1.5rem;
}

.reading-body li {
  margin-bottom: 0.4em;
}

.reading-body a {
  color: var(--color-copper);
}

.reading-body strong {
  color: var(--color-navy);
}

.reading-body hr {
  border: none;
  border-top: 1px solid rgba(27, 42, 65, 0.15);
  margin: 2.5rem 0;
}

.book-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 2rem;
}

.book-card {
  text-decoration: none;
  color: var(--color-navy);
}

.book-card h2 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  margin: 0.75rem 0 0.25rem;
}

.book-card p {
  color: var(--color-ink-muted);
  font-size: 0.9rem;
}

.book-cover-thumb {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 4px;
}

.book-detail-cover {
  max-width: 220px;
  width: 100%;
  height: auto;
  margin-bottom: 1.5rem;
}

.book-detail-description {
  font-family: var(--font-reading);
  color: var(--color-ink-muted);
}

.book-toc {
  padding-left: 1.25rem;
}

.book-toc li {
  margin-bottom: 0.4rem;
}

.book-progress-note {
  margin-top: 1.5rem;
  padding: 0.9rem 1.25rem;
  background: var(--color-ivory-soft);
  border-left: 3px solid var(--color-copper);
  border-radius: 4px;
  font-size: 0.9rem;
  color: var(--color-ink-muted);
}

.book-progress-label {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--color-copper);
  margin-right: 0.6rem;
}

.chapter-back {
  margin-bottom: 1rem;
}

.chapter-nav {
  display: flex;
  justify-content: space-between;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(27, 42, 65, 0.1);
}

.chapter-nav a {
  text-decoration: none;
  color: var(--color-copper);
}

/* ---------- Admin ---------- */

.admin-shell {
  display: flex;
  min-height: 100vh;
}

.admin-sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--color-navy);
  color: var(--color-ivory);
  padding: 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.admin-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-ivory);
  text-decoration: none;
  font-family: var(--font-display);
}

.admin-brand img {
  height: 24px;
  filter: invert(1) brightness(2);
}

.admin-sidebar nav {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.admin-sidebar nav a {
  color: var(--color-ivory);
  text-decoration: none;
  opacity: 0.85;
}

.admin-sidebar nav a:hover {
  opacity: 1;
  color: var(--color-copper-light);
}

.admin-signout {
  margin-top: auto;
  background: none;
  border: 1px solid rgba(250, 243, 230, 0.3);
  color: var(--color-ivory);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  font-family: var(--font-ui);
}

.admin-main {
  flex: 1;
  padding: 2.5rem 3rem;
  max-width: 900px;
}

.admin-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.preview-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.75rem 1rem;
  margin-bottom: 1.5rem;
  background: var(--color-ivory-soft);
  border: 1px solid var(--color-copper);
  border-radius: 8px;
}

.preview-banner > span:nth-of-type(2) {
  color: var(--color-ink-muted);
  font-size: 0.9rem;
}

.preview-banner .btn {
  margin-left: auto;
}

.preview-frame {
  border: 1px dashed var(--color-copper);
  border-radius: 8px;
  padding: 1.5rem 2rem;
  background: var(--color-ivory);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table th,
.admin-table td {
  text-align: left;
  padding: 0.6rem 0.5rem;
  border-bottom: 1px solid rgba(27, 42, 65, 0.1);
}

.badge {
  display: inline-block;
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-draft {
  background: var(--color-ivory-soft);
  color: var(--color-ink-muted);
}

.badge-published {
  background: var(--color-copper);
  color: var(--color-ivory);
}

.badge-skeptic {
  background: var(--color-navy);
  color: var(--color-ivory);
  margin-left: 0.4rem;
}

.badge-believer {
  background: var(--color-copper-light);
  color: var(--color-navy-deep);
  margin-left: 0.4rem;
}

.admin-form label.admin-checkbox {
  flex-direction: row;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.admin-form label.admin-checkbox input {
  margin-top: 0.25rem;
}

.admin-form label.admin-checkbox .hint {
  flex-basis: 100%;
  margin-left: 1.75rem;
}

.admin-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-width: 640px;
}

.admin-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background: #fff;
  border: 1px solid rgba(27, 42, 65, 0.1);
  border-radius: 10px;
  padding: 1.5rem 1.75rem;
}

.admin-section h2 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin: 0 0 0.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(27, 42, 65, 0.08);
}

.admin-form label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-weight: 500;
}

.admin-form input[type="text"],
.admin-form input[type="password"],
.admin-form input[type="file"],
.admin-form textarea,
.admin-form select {
  font-family: var(--font-ui);
  font-size: 1rem;
  padding: 0.6rem 0.7rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fff;
}

.admin-form input[type="text"]:focus,
.admin-form input[type="password"]:focus,
.admin-form textarea:focus,
.admin-form select:focus {
  outline: none;
  border-color: var(--color-copper);
  box-shadow: 0 0 0 3px rgba(181, 101, 46, 0.15);
}

.admin-body-field {
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.9rem;
}

.hint {
  font-weight: 400;
  color: var(--color-ink-muted);
  font-size: 0.85rem;
}

.admin-cover-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1.5rem;
}

.admin-cover-field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.admin-cover-label {
  font-weight: 500;
}

.admin-cover-frame {
  width: 100%;
  max-width: 160px;
  aspect-ratio: 2 / 3;
  border-radius: 6px;
  overflow: hidden;
  background: var(--color-ivory-soft);
  border: 1px solid rgba(27, 42, 65, 0.15);
}

.admin-cover-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.admin-cover-frame.is-empty {
  border-style: dashed;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-ink-muted);
  font-size: 0.8rem;
  text-align: center;
  padding: 0.75rem;
}

.admin-file-input {
  font-size: 0.85rem;
  max-width: 220px;
}

.admin-actions-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.admin-chapters {
  margin-top: 0.5rem;
}

.admin-chapter-list {
  list-style: decimal;
  padding-left: 1.25rem;
}

.admin-chapter-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(27, 42, 65, 0.08);
}

.chapter-actions {
  display: flex;
  gap: 0.6rem;
  align-items: center;
}

.inline-form {
  display: inline;
}

.inline-form button {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-navy);
  font-size: 0.95rem;
}

.admin-add-chapter,
.admin-import {
  margin-top: 1.5rem;
  padding: 1rem;
  background: var(--color-ivory-soft);
  border-radius: 6px;
}

.admin-cards {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.admin-card {
  display: block;
  padding: 1.5rem;
  background: var(--color-ivory-soft);
  border-radius: 8px;
  text-decoration: none;
  color: var(--color-navy);
  min-width: 220px;
}

.admin-card h2 {
  font-family: var(--font-display);
  margin: 0 0 0.4rem;
}

.admin-auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem;
  background: var(--color-ivory);
}

.admin-auth-card {
  width: 100%;
  max-width: 380px;
  background: #fff;
  border: 1px solid rgba(27, 42, 65, 0.1);
  border-radius: 12px;
  padding: 2.5rem 2rem;
  box-shadow: 0 24px 48px -28px rgba(16, 24, 35, 0.35);
  text-align: center;
}

.admin-auth-mark {
  height: 40px;
  width: auto;
  margin: 0 auto 1.25rem;
  display: block;
}

.admin-auth-card h1 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin: 0 0 1.5rem;
}

.admin-auth-card .admin-form {
  max-width: none;
  text-align: left;
  gap: 1rem;
}

.admin-auth-card .btn-primary {
  width: 100%;
  padding: 0.75rem;
  margin-top: 0.25rem;
}

.admin-auth-hint {
  margin-top: 1.25rem;
  font-size: 0.8rem;
  color: var(--color-ink-muted);
}

.admin-error {
  color: #a03e3e;
  background: rgba(160, 62, 62, 0.08);
  padding: 0.6rem 0.8rem;
  border-radius: 4px;
}

.admin-success {
  color: #2e6b4f;
  background: rgba(46, 107, 79, 0.08);
  padding: 0.6rem 0.8rem;
  border-radius: 4px;
}

.admin-empty {
  color: var(--color-ink-muted);
}

.admin-delete-form {
  margin-top: 2rem;
}

.btn-danger {
  background: none;
  border: 1px solid #a03e3e;
  color: #a03e3e;
  cursor: pointer;
}

.btn-danger:hover {
  background: #a03e3e;
  color: #fff;
}

@media (max-width: 720px) {
  .admin-shell {
    flex-direction: column;
  }

  .admin-sidebar {
    width: auto;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
  }

  .admin-sidebar nav {
    flex-direction: row;
  }

  .admin-signout {
    margin-top: 0;
    margin-left: auto;
  }

  .admin-main {
    padding: 1.5rem;
  }
}

/* ---------- Admin: Mystery Night teams ---------- */

.game-admin-team h2 {
  margin-bottom: 0.25rem;
}

.game-admin-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1rem;
}

.admin-form.game-admin-inline {
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  max-width: none;
}

.admin-form.game-admin-inline input[type="text"] {
  width: 14rem;
}

/* ---------- Mystery Night (private family game) ----------
   A dark "case room" with ivory dossier cards, built from the same
   palette and type as the rest of the site. Everything is prefixed
   game- so none of it can leak into the blog, books, or admin. */

.game-shell {
  --game-bg: #0d141e;
  --game-panel: #16212f;
  --game-line: rgba(250, 243, 230, 0.12);
  --game-text: #e9e1d2;
  --game-text-muted: #a8a294;
  --game-paper: #f6eddc;
  --game-paper-edge: #e4d6bc;
  --game-ok: #6fae8c;

  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(ellipse at 20% -10%, rgba(181, 101, 46, 0.18), transparent 55%),
    radial-gradient(ellipse at 110% 110%, rgba(27, 42, 65, 0.9), transparent 60%),
    var(--game-bg);
  color: var(--game-text);
  font-family: var(--font-ui);
}

.game-header {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--game-line);
  flex-wrap: wrap;
}

.game-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--game-text);
}

.game-brand img {
  height: 26px;
  filter: invert(1) sepia(0.4) brightness(1.6);
}

.game-brand-word {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.game-nav {
  display: flex;
  gap: 1.5rem;
}

.game-nav a {
  color: var(--game-text-muted);
  text-decoration: none;
  font-weight: 500;
  padding-bottom: 0.2rem;
  border-bottom: 2px solid transparent;
}

.game-nav a:hover,
.game-nav a.active {
  color: var(--game-text);
  border-bottom-color: var(--color-copper);
}

.game-who {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.9rem;
}

.game-who-name {
  font-weight: 600;
}

.game-who-team {
  color: var(--game-text-muted);
}

.game-who-team::before {
  content: "·";
  margin-right: 0.75rem;
}

.game-signout {
  background: none;
  border: 1px solid var(--game-line);
  color: var(--game-text-muted);
  padding: 0.35rem 0.8rem;
  border-radius: 4px;
  cursor: pointer;
  font-family: var(--font-ui);
}

.game-signout:hover {
  color: var(--game-text);
  border-color: var(--color-copper);
}

main.game-main {
  flex: 1;
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.game-footer {
  padding: 1.5rem;
  text-align: center;
  font-size: 0.8rem;
  border-top: 1px solid var(--game-line);
}

.game-footer a {
  color: var(--game-text-muted);
  text-decoration: none;
}

.game-shell h1,
.game-shell h2,
.game-shell h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
}

.game-eyebrow {
  margin: 0 0 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-copper-light);
}

.game-welcome h1 {
  font-size: 2.4rem;
  margin: 0 0 0.6rem;
}

.game-lede {
  max-width: 40rem;
  color: var(--game-text-muted);
  font-family: var(--font-reading);
  font-size: 1.1rem;
  margin: 0 0 2rem;
}

.game-section-title {
  font-size: 1.5rem;
  margin: 2.5rem 0 1rem;
}

.game-section-title small {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--game-text-muted);
  margin-left: 0.5rem;
}

.game-hint {
  display: block;
  font-size: 0.8rem;
  color: var(--game-text-muted);
  font-weight: 400;
}

.game-empty {
  color: var(--game-text-muted);
  font-style: italic;
}

/* Dossier: the ivory "paper" card used for case files and forms. */
.game-dossier {
  position: relative;
  background: linear-gradient(180deg, var(--game-paper), var(--color-ivory-soft));
  color: var(--color-navy);
  border-radius: 4px 10px 10px 10px;
  padding: 1.75rem 1.75rem 1.5rem;
  box-shadow:
    0 1px 0 var(--game-paper-edge),
    0 28px 50px -30px rgba(0, 0, 0, 0.8);
}

.game-dossier::before {
  content: "";
  position: absolute;
  top: -10px;
  left: 0;
  width: 38%;
  height: 12px;
  background: var(--game-paper);
  border-radius: 6px 6px 0 0;
}

.game-dossier h1,
.game-dossier h2,
.game-dossier h3 {
  color: var(--color-navy);
}

.game-narrow {
  max-width: 34rem;
  margin: 2rem auto;
}

/* Sign-in */
.game-login {
  display: flex;
  justify-content: center;
  padding-top: 2rem;
}

.game-login-card {
  width: 100%;
  max-width: 26rem;
}

.game-login-card h1 {
  font-size: 2rem;
  margin: 0 0 0.5rem;
}

.game-login-card .game-eyebrow {
  color: var(--color-copper);
}

.game-login-lede {
  color: var(--color-ink-muted);
  margin: 0 0 1.5rem;
}

.game-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.game-form label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.9rem;
}

.game-form input[type="text"],
.game-form input[type="password"] {
  font: inherit;
  font-weight: 400;
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fffdf8;
  color: var(--color-navy);
}

.game-form input:focus {
  outline: 2px solid var(--color-copper);
  outline-offset: 1px;
  border-color: transparent;
}

.game-dossier .game-hint {
  color: var(--color-ink-muted);
}

/* Buttons */
.game-btn {
  display: inline-block;
  padding: 0.7rem 1.3rem;
  border-radius: 4px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
}

.game-btn-primary {
  background: var(--color-navy);
  color: var(--color-ivory);
}

.game-btn-primary:hover {
  background: var(--color-copper);
}

.game-btn-ghost {
  background: none;
  border-color: var(--game-line);
  color: var(--game-text);
}

.game-btn-ghost:hover {
  border-color: var(--color-copper);
}

.game-btn-danger {
  background: none;
  border-color: rgba(214, 120, 110, 0.5);
  color: #e7a49b;
}

.game-btn-danger:hover {
  background: #a03e3e;
  border-color: #a03e3e;
  color: #fff;
}

/* Messages */
.game-error {
  color: #a03e3e;
  background: rgba(160, 62, 62, 0.1);
  padding: 0.6rem 0.8rem;
  border-radius: 4px;
}

.game-notice {
  background: rgba(181, 101, 46, 0.12);
  border-left: 3px solid var(--color-copper);
  padding: 0.6rem 0.8rem;
  border-radius: 0 4px 4px 0;
}

.game-shell > main > .game-error {
  background: rgba(214, 120, 110, 0.12);
  color: #f0b8b0;
}

/* Roster */
.game-roster h2 {
  font-size: 1.1rem;
  margin: 0 0 0.75rem;
}

.game-roster ul {
  list-style: none;
  padding: 0;
  margin: 0 0 0.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
}

.game-roster li {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.game-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 1px solid var(--game-text-muted);
  flex-shrink: 0;
}

.is-here .game-dot {
  background: var(--game-ok);
  border-color: var(--game-ok);
  box-shadow: 0 0 8px var(--game-ok);
}

.game-you {
  font-size: 0.75rem;
  color: var(--game-text-muted);
}

/* Case files grid */
.game-cases {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2.25rem 1.5rem;
  padding-top: 0.75rem;
}

.game-case {
  display: flex;
  flex-direction: column;
}

.game-case h3 {
  font-size: 1.45rem;
  margin: 0 0 0.5rem;
}

.game-case-setting {
  margin: 0 0 0.3rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-copper);
}

.game-case-tagline {
  font-family: var(--font-reading);
  margin: 0 0 0.75rem;
}

.game-case-meta {
  font-size: 0.8rem;
  color: var(--color-ink-muted);
  margin: 0 0 1rem;
}

.game-case-solved {
  font-size: 0.9rem;
  margin: 0 0 1rem;
}

.game-case.is-locked {
  opacity: 0.72;
}

.game-case-actions {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.game-stamp {
  align-self: flex-start;
  margin: auto 0 0;
  padding: 0.2rem 0.7rem;
  border: 2px solid var(--color-copper);
  color: var(--color-copper);
  border-radius: 3px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  transform: rotate(-4deg);
}

.game-start-form {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.game-start-form fieldset {
  border: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.game-start-form legend {
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}

.game-skill-option {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  padding: 0.5rem 0.6rem;
  border: 1px solid rgba(27, 42, 65, 0.15);
  border-radius: 6px;
  cursor: pointer;
}

.game-skill-option:has(input:checked) {
  border-color: var(--color-copper);
  background: rgba(181, 101, 46, 0.08);
}

.game-skill-option input {
  margin-top: 0.25rem;
  accent-color: var(--color-copper);
}

.game-skill-option strong {
  display: block;
  font-size: 0.9rem;
}

.game-skill-option small {
  display: block;
  color: var(--color-ink-muted);
  font-size: 0.78rem;
  line-height: 1.4;
}

/* Skill badges */
.game-badge {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 600;
}

.game-badge-stroll {
  background: #dfeee4;
  color: #2e6b4f;
}

.game-badge-pleasant {
  background: #f3e1cf;
  color: #8a4a1f;
}

.game-badge-taxing {
  background: #1b2a41;
  color: #f3c7a2;
}

/* Case room (lobby) */
.game-case-room {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 2rem;
  align-items: start;
  padding-top: 0.75rem;
}

.game-case-file h1 {
  font-size: 2rem;
  margin: 0 0 0.5rem;
}

.game-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2.5rem;
  margin: 1.25rem 0;
  padding: 1rem 0;
  border-top: 1px dashed rgba(27, 42, 65, 0.25);
  border-bottom: 1px dashed rgba(27, 42, 65, 0.25);
}

.game-facts dt {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-ink-muted);
}

.game-facts dd {
  margin: 0.2rem 0 0;
  font-weight: 500;
}

.game-seal {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  font-family: var(--font-reading);
}

.game-seal .game-stamp {
  margin: 0.2rem 0 0;
  flex-shrink: 0;
}

.game-seal p:last-child {
  margin: 0;
}

.game-roster-side {
  background: var(--game-panel);
  border: 1px solid var(--game-line);
  border-radius: 10px;
  padding: 1.25rem;
}

.game-roster-side ul {
  flex-direction: column;
  margin-bottom: 1rem;
}

.game-roster-side .game-btn {
  width: 100%;
}

.game-abandon {
  margin-top: 0.75rem;
}

.game-abandon .game-btn {
  width: 100%;
}

/* Players Board */
.game-board-episode {
  margin-bottom: 1rem;
}

.game-board-levels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem 1.25rem;
  padding-top: 0.75rem;
}

.game-board-level h3 {
  margin: 0 0 0.75rem;
}

.game-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.game-table th,
.game-table td {
  text-align: left;
  padding: 0.45rem 0.35rem;
  border-bottom: 1px solid rgba(27, 42, 65, 0.12);
}

.game-table th {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-ink-muted);
}

.game-table tr.is-mine td {
  background: rgba(181, 101, 46, 0.1);
  font-weight: 600;
}

@media (max-width: 760px) {
  .game-header {
    gap: 0.75rem 1.25rem;
  }

  .game-who {
    margin-left: 0;
    width: 100%;
  }

  .game-welcome h1 {
    font-size: 1.9rem;
  }

  .game-case-room {
    grid-template-columns: 1fr;
  }

  .game-dossier {
    padding: 1.4rem 1.25rem 1.25rem;
  }

  .game-seal {
    flex-direction: column;
  }
}

/* ---------- Mystery Night: live case room (build 2) ---------- */

.game-casebar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 2rem;
  padding-bottom: 1.25rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--game-line);
}

.game-casebar h1 {
  font-size: 2rem;
  margin: 0;
}

.game-casebar-title .game-case-setting {
  color: var(--color-copper-light);
}

.game-casebar-meta {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  flex-wrap: wrap;
}

.game-clock {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  font-variant-numeric: tabular-nums;
}

.game-clock-time {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.game-clock-penalty {
  color: #f0b8b0;
  font-size: 0.9rem;
  font-weight: 600;
}

.game-clock.is-paused .game-clock-time {
  opacity: 0.5;
}

.game-room {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 2rem;
  align-items: start;
}

.game-room-main {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding-top: 0.75rem;
}

.game-room-side {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.game-panel {
  background: var(--game-panel);
  border: 1px solid var(--game-line);
  border-radius: 10px;
  padding: 1.1rem 1.2rem;
}

.game-panel h2 {
  font-size: 1.05rem;
  margin: 0 0 0.6rem;
}

.game-role p {
  margin: 0.3rem 0;
  font-family: var(--font-reading);
}

.game-role strong {
  display: block;
  color: var(--color-copper-light);
  font-family: var(--font-ui);
}

.game-roles {
  display: block;
  color: var(--game-text-muted);
  font-size: 0.75rem;
}

.game-btn-big {
  font-size: 1.05rem;
  padding: 0.9rem 2rem;
  margin-top: 1.25rem;
}

.game-btn-quiet {
  background: none;
  border-color: rgba(27, 42, 65, 0.25);
  color: var(--color-navy);
}

.game-btn-quiet:hover {
  border-color: var(--color-copper);
  color: var(--color-copper);
}

.game-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.game-waiting {
  margin: 1.25rem 0 0;
  font-style: italic;
  color: var(--color-ink-muted);
}

.game-paused {
  text-align: center;
  padding: 3rem 1.75rem;
}

.game-paused .game-stamp {
  margin: 0 auto 1rem;
  align-self: center;
  display: inline-block;
}

.game-closed h2 {
  font-size: 1.8rem;
  margin: 0.75rem 0 0.25rem;
}

.game-closed .game-stamp {
  margin: 0;
}

.game-stamp-solved {
  border-color: #2e6b4f;
  color: #2e6b4f;
}

.game-intro {
  background: var(--game-panel);
  border: 1px solid var(--game-line);
  border-radius: 10px;
  padding: 0.9rem 1.2rem;
  font-family: var(--font-reading);
}

.game-intro summary {
  cursor: pointer;
  font-family: var(--font-ui);
  font-weight: 600;
}

/* Puzzles */
.game-puzzle-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.game-puzzle h3 {
  font-size: 1.4rem;
  margin: 0 0 0.6rem;
}

.game-puzzle-head .game-stamp {
  margin: 0;
}

.game-puzzle-prompt,
.game-puzzle-result {
  font-family: var(--font-reading);
}

.game-puzzle.is-solved {
  opacity: 0.85;
}

.game-puzzle-by {
  font-size: 0.8rem;
  color: var(--color-ink-muted);
}

.game-guidance {
  border-left: 3px solid #2e6b4f;
  background: rgba(46, 107, 79, 0.08);
  padding: 0.5rem 0.8rem;
  margin: 0 0 1rem;
  font-size: 0.92rem;
}

.game-guidance p {
  margin: 0;
}

.game-answer {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.game-answer input {
  flex: 1;
  min-width: 12rem;
  font: inherit;
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fffdf8;
  color: var(--color-navy);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.game-feedback {
  margin: 0.75rem 0 0;
  color: #a03e3e;
  font-weight: 500;
}

.game-feedback.is-ok {
  color: #2e6b4f;
}

/* Combination lock */
.game-lock {
  display: flex;
  gap: 0.75rem;
  margin: 0.5rem 0 1rem;
}

.game-lock-wheel {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: linear-gradient(180deg, #2a3546, #141c27 50%, #2a3546);
  border-radius: 8px;
  padding: 0.25rem;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.4), 0 6px 14px -8px rgba(0, 0, 0, 0.6);
}

.game-lock-turn {
  background: none;
  border: none;
  color: var(--color-copper-light);
  font-size: 0.9rem;
  padding: 0.35rem 0.9rem;
  cursor: pointer;
}

.game-lock-symbol {
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--color-ivory);
  min-width: 2.5rem;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

/* Ordering */
.game-order {
  padding-left: 1.4rem;
  margin: 0.5rem 0 1rem;
}

.game-order li {
  padding: 0.45rem 0.25rem;
  border-bottom: 1px dashed rgba(27, 42, 65, 0.2);
}

.game-order li span:first-child {
  display: inline-block;
  min-width: 70%;
}

.game-order-moves {
  float: right;
}

.game-order-moves button {
  background: none;
  border: 1px solid rgba(27, 42, 65, 0.2);
  border-radius: 4px;
  margin-left: 0.25rem;
  cursor: pointer;
  color: var(--color-navy);
}

/* Deduction grid */
.game-grid-wrap {
  overflow-x: auto;
  margin: 0.5rem 0 1rem;
}

.game-grid {
  border-collapse: collapse;
}

.game-grid th,
.game-grid td {
  border: 1px solid rgba(27, 42, 65, 0.25);
  padding: 0;
  text-align: center;
  font-size: 0.85rem;
}

.game-grid th {
  padding: 0.4rem 0.6rem;
  background: rgba(27, 42, 65, 0.05);
}

.game-grid-cell {
  width: 3rem;
  height: 2.6rem;
  border: none;
  background: transparent;
  font-size: 1.1rem;
  cursor: pointer;
  color: var(--color-navy);
}

.game-grid-cell.mark-x {
  color: #a03e3e;
  background: rgba(160, 62, 62, 0.06);
}

.game-grid-cell.mark-o {
  color: #2e6b4f;
  background: rgba(46, 107, 79, 0.1);
}

.game-grid-answer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  margin-bottom: 1rem;
}

.game-grid-answer label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.game-grid-answer select {
  font: inherit;
  font-weight: 400;
  padding: 0.4rem 0.5rem;
  border-radius: 4px;
  border: 1px solid rgba(27, 42, 65, 0.25);
  background: #fffdf8;
}

/* Hints */
.game-hints {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(27, 42, 65, 0.25);
}

.game-hint-line {
  margin: 0 0 0.6rem;
  font-family: var(--font-reading);
}

.game-hint-line span {
  display: inline-block;
  margin-right: 0.4rem;
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-copper);
}

.game-hint-confirm {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}

/* Notebook documents */
.game-notebook .game-hint {
  margin: -0.25rem 0 0.9rem;
}

.game-doc {
  background: var(--game-paper);
  color: var(--color-navy);
  border-radius: 4px;
  padding: 0.9rem 1rem;
  margin-bottom: 0.9rem;
  font-family: var(--font-reading);
  font-size: 0.95rem;
  box-shadow: 0 10px 24px -18px rgba(0, 0, 0, 0.9);
}

.game-doc h4 {
  margin: 0 0 0.5rem;
  font-family: var(--font-ui);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-ink-muted);
}

.game-doc-body p {
  margin: 0 0 0.5rem;
}

.game-doc-body p:last-child {
  margin-bottom: 0;
}

.game-doc-letter {
  background:
    repeating-linear-gradient(180deg, transparent 0 1.55rem, rgba(27, 42, 65, 0.06) 1.55rem 1.6rem),
    var(--game-paper);
  font-style: italic;
}

.game-doc-note {
  background: #f3e3a8;
  transform: rotate(-0.6deg);
}

.game-doc-telegram {
  background: #efe6cf;
  font-family: "Courier New", Courier, monospace;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-top: 4px solid #7a5b2e;
}

.game-doc-card {
  background: #fffdf8;
  border: 1px solid rgba(27, 42, 65, 0.2);
}

.game-doc-ledger {
  background:
    linear-gradient(90deg, transparent 2.2rem, rgba(160, 62, 62, 0.35) 2.2rem 2.3rem, transparent 2.3rem),
    repeating-linear-gradient(180deg, transparent 0 1.55rem, rgba(27, 90, 140, 0.15) 1.55rem 1.6rem),
    #f7f3e6;
  padding-left: 2.8rem;
}

.game-doc-photo {
  padding: 0.6rem 0.6rem 0.9rem;
  background: #fffdf8;
}

.game-doc-image img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 2px;
  margin-bottom: 0.6rem;
}

/* Activity feed */
.game-feed ul {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 18rem;
  overflow-y: auto;
  font-size: 0.85rem;
}

.game-feed li {
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--game-line);
  color: var(--game-text-muted);
}

.game-feed time {
  display: inline-block;
  min-width: 3rem;
  font-variant-numeric: tabular-nums;
  color: var(--color-copper-light);
}

.game-feed strong {
  color: var(--game-text);
}

.game-confirm p {
  margin: 0 0 0.6rem;
  font-size: 0.9rem;
}

.game-confirm .game-btn {
  width: 100%;
  margin-bottom: 0.5rem;
}

.game-roster-side .game-btn {
  margin-top: 0.5rem;
}

/* Admin: hint penalty grid */
.game-penalty-grid input[type="number"] {
  width: 5rem;
  font: inherit;
  padding: 0.35rem 0.4rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
}

.admin-error-inline {
  color: #a03e3e;
}

@media (max-width: 900px) {
  .game-room {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .game-lock-symbol {
    font-size: 1.6rem;
    min-width: 2rem;
  }

  .game-casebar h1 {
    font-size: 1.6rem;
  }
}

/* ---------- Mystery Night: roles and the dial safe (build 3) ---------- */

.game-btn-small {
  padding: 0.4rem 0.8rem;
  font-size: 0.85rem;
}

.game-role-assign {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px dashed rgba(27, 42, 65, 0.25);
}

.game-role-assign h3 {
  font-size: 1.15rem;
  margin: 0 0 0.25rem;
}

.game-role-list {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.game-role-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0.7rem;
  border: 1px solid rgba(27, 42, 65, 0.15);
  border-radius: 6px;
}

.game-role-list strong {
  display: block;
}

.game-role-list small {
  display: block;
  color: var(--color-ink-muted);
  font-size: 0.8rem;
}

.game-role-list select {
  font: inherit;
  padding: 0.35rem 0.5rem;
  border-radius: 4px;
  border: 1px solid rgba(27, 42, 65, 0.25);
  background: #fffdf8;
  min-width: 8rem;
}

.game-role-owner {
  font-weight: 600;
  white-space: nowrap;
}

/* In the dark side panel during the case */
.game-role-assign-side {
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--game-line);
}

.game-role-assign-side summary {
  cursor: pointer;
  font-weight: 600;
}

.game-role-assign-side .game-role-list li {
  border-color: var(--game-line);
}

.game-role-assign-side .game-role-list small {
  color: var(--game-text-muted);
}

.game-role-assign-side .game-btn-quiet {
  color: var(--game-text);
  border-color: var(--game-line);
}

/* Dial safe */
.game-dial-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  margin: 0.5rem 0 1rem;
}

.game-dial {
  width: 220px;
  height: 220px;
  flex-shrink: 0;
}

.game-dial-rim {
  fill: #141c27;
  stroke: #b5652e;
  stroke-width: 3;
}

.game-dial-face {
  fill: #232f40;
}

.game-dial-tick {
  stroke: #c9c1b0;
  stroke-width: 1.2;
}

.game-dial-tick.major {
  stroke: #f6eddc;
  stroke-width: 2.2;
}

.game-dial-num {
  fill: #f6eddc;
  font-family: var(--font-display);
  font-size: 15px;
  text-anchor: middle;
  dominant-baseline: middle;
}

.game-dial-knob {
  fill: #b5652e;
  stroke: #7a4019;
  stroke-width: 3;
}

.game-dial-marker {
  fill: #d98a4f;
}

.game-dial-controls {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.6rem;
}

.game-dial-reading {
  margin: 0;
  font-family: var(--font-display);
  font-size: 2.2rem;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.game-dial-turns {
  display: flex;
  gap: 0.35rem;
}

.game-dial-turns button {
  font: inherit;
  font-size: 0.85rem;
  padding: 0.4rem 0.6rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fffdf8;
  color: var(--color-navy);
  cursor: pointer;
}

.game-dial-set {
  display: flex;
  gap: 0.4rem;
  margin: 0;
}

.game-dial-set span {
  min-width: 2.4rem;
  padding: 0.3rem 0.4rem;
  text-align: center;
  border: 1px dashed rgba(27, 42, 65, 0.3);
  border-radius: 4px;
  font-variant-numeric: tabular-nums;
}

.game-dial-set span.is-set {
  border-style: solid;
  border-color: var(--color-copper);
  font-weight: 700;
}

.game-dial-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Images on puzzles and the case intro */
.game-figure {
  margin: 0 0 1rem;
}

.game-figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
}

.game-intro .game-figure {
  margin-top: 0.75rem;
}

/* ---------- Mystery Night: phone layout and new clues (build 4) ---------- */

.game-tabs {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  gap: 0.25rem;
  margin: 0 -1rem 1.25rem;
  padding: 0.5rem 1rem;
  background: rgba(13, 20, 30, 0.96);
  border-bottom: 1px solid var(--game-line);
  backdrop-filter: blur(6px);
}

.game-tabs button {
  flex: 1;
  position: relative;
  padding: 0.65rem 0.5rem;
  border: 1px solid transparent;
  border-radius: 6px;
  background: none;
  color: var(--game-text-muted);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.game-tabs button.is-active {
  background: var(--game-panel);
  border-color: var(--game-line);
  color: var(--game-text);
}

.game-tab-badge {
  display: inline-block;
  min-width: 1.3rem;
  margin-left: 0.35rem;
  padding: 0.05rem 0.4rem;
  border-radius: 999px;
  background: var(--color-copper);
  color: #fff;
  font-size: 0.75rem;
  line-height: 1.3;
}

.game-room-compact {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.game-tab-panel {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.game-new-clue {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-copper);
  border-radius: 8px;
  background: rgba(181, 101, 46, 0.15);
  color: var(--game-text);
  font: inherit;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.game-new {
  display: inline-block;
  padding: 0.05rem 0.45rem;
  border-radius: 3px;
  background: var(--color-copper);
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.game-doc.is-new {
  box-shadow: 0 0 0 2px var(--color-copper), 0 10px 24px -18px rgba(0, 0, 0, 0.9);
}

.game-doc-head,
.game-doc-toggle {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.5rem;
}

.game-doc-head h4,
.game-doc-toggle h4 {
  margin: 0;
  flex: 1;
}

.game-doc-toggle {
  width: 100%;
  padding: 0;
  border: none;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.game-doc.is-folded .game-doc-toggle {
  margin-bottom: 0;
}

.game-doc-chevron {
  color: var(--color-ink-muted);
}

.game-puzzle.is-folded {
  padding: 0.9rem 1.25rem;
}

.game-puzzle-fold {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0;
  border: none;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.game-puzzle-fold h3 {
  margin: 0;
  font-size: 1.1rem;
}

.game-puzzle-fold .game-stamp {
  margin: 0;
  font-size: 0.65rem;
}

@media (max-width: 560px) {
  main.game-main {
    padding: 1.25rem 1rem 3rem;
  }

  .game-dossier {
    padding: 1.2rem 1rem 1.1rem;
  }

  .game-casebar {
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
  }

  .game-clock-time {
    font-size: 1.6rem;
  }
}

/* ---------- Live connection status and errors ---------- */

.game-connecting {
  margin: 0 0 1.25rem;
  padding: 0.7rem 1rem;
  border-radius: 8px;
  border: 1px solid var(--game-line);
  background: var(--game-panel);
  color: var(--game-text);
}

/* After 12 seconds without a live connection, swap the message.
   (max-height, unlike display, animates reliably in every browser.) */
.game-connecting {
  animation: game-connecting-slow 0s 12s forwards;
}

.game-connecting > span {
  display: block;
  overflow: hidden;
}

.game-connecting .game-connecting-now {
  max-height: 10em;
  animation: game-collapse 0s 12s forwards;
}

.game-connecting .game-connecting-slow {
  max-height: 0;
  animation: game-expand 0s 12s forwards;
}

@keyframes game-connecting-slow {
  to { border-color: #d6786e; }
}

@keyframes game-collapse {
  to { max-height: 0; }
}

@keyframes game-expand {
  to { max-height: 10em; }
}

#blazor-error-ui {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  padding: 0.8rem 1.25rem;
  background: #a03e3e;
  color: #fff;
  font-family: var(--font-ui);
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.35);
}

#blazor-error-ui a {
  color: #fff;
  font-weight: 700;
  margin-left: 0.5rem;
}

#blazor-error-ui .blazor-error-detail {
  display: block;
  font-size: 0.85rem;
  opacity: 0.9;
}

/* ---------- Mystery Night: relaxed scoring ---------- */

.game-score {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  font-variant-numeric: tabular-nums;
}

.game-score-points {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
}

.game-score-label {
  color: var(--game-text-muted);
  font-size: 0.85rem;
}

.game-badge-timed {
  background: #3a1f12;
  color: #f3c7a2;
  border: 1px solid var(--color-copper);
}

.game-timed-option {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  padding: 0.55rem 0.6rem;
  border: 1px dashed rgba(27, 42, 65, 0.3);
  border-radius: 6px;
  cursor: pointer;
}

.game-timed-option:has(input:checked) {
  border-style: solid;
  border-color: var(--color-copper);
  background: rgba(181, 101, 46, 0.08);
}

.game-timed-option input {
  margin-top: 0.25rem;
  accent-color: var(--color-copper);
}

.game-timed-option strong {
  display: block;
  font-size: 0.9rem;
}

.game-timed-option small {
  display: block;
  color: var(--color-ink-muted);
  font-size: 0.78rem;
  line-height: 1.4;
}

.game-closed-title {
  margin: 0.9rem 0 0;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-copper);
}

.game-closed-title + h2 {
  margin-top: 0.2rem;
}

.game-board-mode {
  margin: 1.5rem 0 0.25rem;
  font-size: 1.05rem;
  color: var(--game-text-muted);
}

.game-board-mode:first-of-type {
  margin-top: 0.5rem;
}

.game-settings-mode {
  margin: 1.25rem 0 0.4rem;
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: 600;
}

.game-settings-scroll {
  overflow-x: auto;
}

.game-penalty-grid th {
  font-size: 0.8rem;
}

/* ===== Missions: places, the scene, things, the casebook, the report ===== */
.game-places ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.game-places li {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 9rem;
}

.game-place-go,
.game-place-name {
  font: inherit;
  font-weight: 600;
  text-align: left;
  padding: 0.55rem 0.8rem;
  border-radius: 6px;
  border: 1px solid var(--game-line);
  background: none;
  color: var(--game-text);
}

.game-place-go {
  cursor: pointer;
}

.game-place-go:hover:not(:disabled) {
  border-color: var(--color-copper);
}

.game-place-go:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.game-places li.is-here .game-place-name {
  border-color: var(--color-copper);
  background: rgba(181, 101, 46, 0.18);
}

.game-place-go small,
.game-place-name small {
  display: block;
  font-weight: 400;
  font-size: 0.72rem;
  color: var(--game-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.game-places li.is-locked .game-place-go {
  border-style: dashed;
}

.game-place-who {
  font-size: 0.78rem;
  color: var(--color-copper-light);
  padding-left: 0.2rem;
}

.game-scene-label {
  margin: 0;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-ink-muted);
}

.game-scene h2 {
  font-size: 1.7rem;
  margin: 0.1rem 0 0.75rem;
}

.game-scene-text,
.game-thing-text,
.game-done-result,
.game-report-body {
  font-family: var(--font-reading);
}

.game-thing-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.game-thing h3 {
  font-size: 1.3rem;
  margin: 0 0 0.5rem;
}

.game-thing-kind {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-copper);
}

.game-done {
  list-style: none;
  margin: 0.75rem 0;
  padding: 0;
  border-left: 3px solid var(--game-paper-edge);
}

.game-done li {
  padding: 0.4rem 0 0.4rem 0.8rem;
}

.game-done-head {
  margin: 0;
  font-size: 0.9rem;
}

.game-done-head small {
  color: var(--color-ink-muted);
  margin-left: 0.4rem;
}

.game-done-result p {
  margin: 0.3rem 0;
}

.game-found {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  color: #2e6b4f;
}

.game-action {
  margin: 0.5rem 0.5rem 0 0;
}

.game-blocked {
  margin: 0.3rem 0 0;
  font-size: 0.85rem;
}

.game-thing .game-puzzle {
  margin-top: 1rem;
  box-shadow: inset 0 0 0 1px var(--game-paper-edge);
}

.game-thing .game-puzzle::before {
  display: none;
}

.game-pick {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.5rem;
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px dashed var(--game-paper-edge);
}

.game-pick label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  flex: 1;
  min-width: 12rem;
  font-size: 0.85rem;
  font-weight: 600;
}

.game-pick select,
.game-report-question select,
.game-report-question input {
  font: inherit;
  font-weight: 400;
  padding: 0.55rem 0.6rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fffdf8;
  color: var(--color-navy);
}

.game-report summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 1.15rem;
}

.game-report-question {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin: 0.9rem 0;
  font-family: var(--font-ui);
  font-weight: 600;
}

.game-report-confirm p {
  margin: 0 0 0.6rem;
}

.game-report-confirm .game-btn {
  margin-right: 0.5rem;
}

.game-casebook h3 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-copper-light);
  margin: 1rem 0 0.4rem;
}

.game-leads,
.game-items {
  list-style: none;
  margin: 0;
  padding: 0;
}

.game-leads li,
.game-items li {
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--game-line);
  font-family: var(--font-reading);
}

.game-leads small,
.game-items small {
  display: block;
  color: var(--game-text-muted);
  font-family: var(--font-ui);
  font-size: 0.72rem;
}

.game-items li > div {
  font-size: 0.9rem;
  color: var(--game-text-muted);
}

.game-items li.is-spent strong {
  text-decoration: line-through;
  opacity: 0.7;
}

.game-feed-detail summary {
  cursor: pointer;
  font-size: 0.78rem;
  color: var(--color-copper-light);
}

.game-feed-detail div {
  color: var(--game-text);
  font-family: var(--font-reading);
}

.game-feed-detail .game-found {
  color: var(--game-ok);
}

/* ===== Lamplight Investigations: the agency look ===== */
.game-shell {
  --lamp-glow: #f2b45c;
  --font-typed: "Special Elite", "Courier New", Courier, monospace;
  --font-hand: "Caveat", "Segoe Print", "Bradley Hand", cursive;
  background:
    radial-gradient(ellipse at 18% -12%, rgba(242, 180, 92, 0.2), transparent 55%),
    radial-gradient(ellipse at 110% 110%, rgba(27, 42, 65, 0.9), transparent 60%),
    var(--game-bg);
}

.game-brand-lamp {
  width: 22px;
  height: 30px;
  filter: drop-shadow(0 0 6px rgba(242, 180, 92, 0.55));
}

.game-lamp-glass {
  fill: rgba(242, 180, 92, 0.18);
  stroke: var(--lamp-glow);
  stroke-width: 1.2;
}

.game-lamp-flame {
  fill: var(--lamp-glow);
}

.game-lamp-base {
  fill: var(--color-copper-light);
}

.game-brand-word {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 1.1rem;
  color: var(--lamp-glow);
}

.game-brand-word small {
  font-family: var(--font-ui);
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  color: var(--game-text-muted);
  margin-left: 0.35rem;
}

/* The agency office, at the top of the case files */
.game-hero {
  position: relative;
  margin: -1rem 0 2rem;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 30px 60px -35px rgba(0, 0, 0, 0.9);
}

.game-hero img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 7;
  object-fit: cover;
  object-position: 50% 60%;
}

.game-hero-text {
  position: absolute;
  inset: auto 0 0 0;
  padding: 3rem 2rem 1.5rem;
  background: linear-gradient(180deg, transparent, rgba(8, 12, 18, 0.88));
  text-align: center;
}

.game-hero-name {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 3.4rem);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--lamp-glow);
  text-shadow: 0 0 24px rgba(242, 180, 92, 0.35);
}

.game-hero-sub {
  margin: 0.1rem 0 0.6rem;
  font-size: 0.8rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--game-text);
}

.game-hero-tag {
  margin: 0;
  font-family: var(--font-reading);
  font-style: italic;
  color: var(--game-text-muted);
}

.game-case-kind {
  display: inline-block;
  margin: 0 0 0.4rem;
  padding: 0.1rem 0.5rem;
  border: 1px solid var(--color-copper);
  border-radius: 3px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-copper);
}

/* Sign-in: the office behind the card */
.game-login {
  position: relative;
  padding: 3rem 1rem;
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(8, 12, 18, 0.55), rgba(8, 12, 18, 0.85)),
    url("/game-assets/lamplight/agency-office.jpg") center / cover;
}

/* The briefing: agency paper on the desk */
.game-briefing {
  padding: clamp(1rem, 5vw, 3.5rem) clamp(0.75rem, 4vw, 3rem);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(8, 12, 18, 0.25), rgba(8, 12, 18, 0.5)),
    url("/game-assets/lamplight/briefing-desk.jpg") center / cover;
  box-shadow: 0 30px 60px -35px rgba(0, 0, 0, 0.9);
}

.game-letter {
  max-width: 38rem;
  margin: 0 auto;
  padding: 2rem clamp(1.25rem, 4vw, 2.5rem) 1.75rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.35), transparent 30%),
    #f4ead6;
  color: #2a2620;
  border-radius: 2px;
  transform: rotate(-0.6deg);
  box-shadow:
    0 1px 0 #e0d2b6,
    0 24px 40px -20px rgba(0, 0, 0, 0.75);
}

.game-letter-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding-bottom: 0.6rem;
  margin-bottom: 1rem;
  border-bottom: 2px solid #2a2620;
  font-family: var(--font-typed);
}

.game-letter-agency {
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.85rem;
}

.game-letter-kind {
  font-size: 0.75rem;
  color: #8a3b2a;
  border: 1.5px solid #8a3b2a;
  padding: 0.05rem 0.45rem;
  transform: rotate(-3deg);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.game-letter h2 {
  margin: 0;
  font-size: 1.8rem;
  color: #2a2620;
}

.game-letter-setting,
.game-letter-tagline {
  margin: 0.2rem 0 1rem;
  font-family: var(--font-typed);
  font-size: 0.85rem;
  color: #5d554a;
}

.game-letter-tagline {
  font-size: 1rem;
  color: #2a2620;
}

.game-letter-body,
.game-letter > p {
  font-family: var(--font-reading);
  line-height: 1.6;
}

.game-letter .game-role-assign h3,
.game-letter .game-waiting {
  color: #2a2620;
}

.game-letter .game-hint {
  color: #6a6256;
}

.game-briefing-fold > summary {
  cursor: pointer;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--lamp-glow);
}

/* Writing laid over images */
.game-image {
  position: relative;
  container-type: inline-size;
}

.game-overlay {
  position: absolute;
  font-size: calc(var(--overlay-size, 1) * 2.4cqw);
  line-height: 1.2;
  transform-origin: left top;
  pointer-events: none;
  white-space: pre-line;
}

.game-overlay-type {
  font-family: var(--font-typed);
  color: #23201b;
}

.game-overlay-hand {
  font-family: var(--font-hand);
  font-size: calc(var(--overlay-size, 1) * 3.2cqw);
  color: #1f2a5a;
}

.game-overlay-label {
  font-family: var(--font-reading);
  font-weight: 600;
  color: #2b241b;
  background: rgba(244, 234, 214, 0.92);
  padding: 0.1em 0.4em;
  border-radius: 2px;
}

.game-overlay-plate {
  font-family: var(--font-ui);
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #1b2a41;
  background: #f1efe6;
  border: 0.12em solid #1b2a41;
  border-radius: 0.25em;
  padding: 0.05em 0.35em;
}

.game-overlay-stamp {
  font-family: var(--font-typed);
  text-transform: uppercase;
  color: #8a3b2a;
  border: 0.12em solid #8a3b2a;
  padding: 0.05em 0.35em;
  opacity: 0.85;
}

.game-overlay-sign {
  font-family: var(--font-display);
  font-weight: 600;
  color: #f4ead6;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

/* The mission room */
.game-scene.has-image {
  padding-top: 0;
  overflow: hidden;
}

.game-scene.has-image::before {
  display: none;
}

.game-scene-image {
  margin: 0 -1.75rem 1.25rem;
}

.game-scene-image img {
  border-radius: 4px 10px 0 0;
  max-height: 26rem;
  object-fit: cover;
}

.game-things {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr));
  gap: 1.75rem 1.25rem;
}

.game-thing {
  padding: 1.25rem 1.25rem 1.1rem;
}

.game-thing.has-lock,
.game-thing.is-person {
  grid-column: 1 / -1;
}

.game-thing-image img {
  max-height: 14rem;
  object-fit: cover;
}

.game-item-image {
  float: right;
  width: 4.5rem;
  margin: 0 0 0.4rem 0.6rem;
}

.game-item-image img {
  border-radius: 4px;
}

.game-items li::after {
  content: "";
  display: block;
  clear: both;
}

.game-places {
  border-color: rgba(242, 180, 92, 0.25);
}

.game-places li.is-here .game-place-name {
  box-shadow: 0 0 18px -6px rgba(242, 180, 92, 0.6);
}

@media (max-width: 760px) {
  .game-hero img {
    aspect-ratio: 4 / 3;
  }

  .game-scene-image {
    margin: 0 -1.25rem 1rem;
  }
}

/* ===== Missions: story clock, messages, the office ===== */
.game-badge-extra {
  border-color: rgba(242, 180, 92, 0.5);
  color: var(--lamp-glow);
}

.game-story-time {
  font-family: var(--font-typed);
  font-size: 1.05rem;
  color: var(--lamp-glow);
  padding: 0.2rem 0.6rem;
  border: 1px solid rgba(242, 180, 92, 0.35);
  border-radius: 4px;
}

.game-telegram {
  background: #efe3c4;
  color: #2a2620;
  border-left: 4px solid #8a3b2a;
  border-radius: 2px;
  padding: 0.9rem 1.2rem;
  font-family: var(--font-typed);
  box-shadow: 0 14px 30px -18px rgba(0, 0, 0, 0.8);
  transform: rotate(-0.4deg);
}

.game-telegram-head {
  margin: 0 0 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.85rem;
  color: #8a3b2a;
}

.game-telegram p {
  margin: 0.3rem 0;
}

.game-office h2 {
  color: var(--lamp-glow);
}

.game-office-said {
  margin: 0 0 0.6rem;
  padding-left: 1.2rem;
  font-family: var(--font-reading);
}

.game-office-said li {
  margin: 0.35rem 0;
}

.game-messages {
  list-style: none;
  margin: 0;
  padding: 0;
}

.game-messages li {
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--game-line);
  font-family: var(--font-reading);
  font-size: 0.92rem;
}

.game-messages strong {
  display: block;
  font-family: var(--font-typed);
  font-weight: 400;
  color: var(--lamp-glow);
}

/* Spacing between inline names and their tags (whitespace between elements isn't kept). */
.game-feed strong,
.game-done-head strong {
  margin-right: 0.35em;
}

.game-you,
.game-new {
  margin-left: 0.4em;
}

/* The page heading takes focus after navigation for screen readers; no ring for that. */
.game-shell h1:focus {
  outline: none;
}

.game-overlay-uv {
  font-family: var(--font-hand);
  font-size: calc(var(--overlay-size, 1) * 3.2cqw);
  font-weight: 700;
  color: #f3eaff;
  text-shadow: 0 0 0.25em #b77cff, 0 0 0.6em #8a3cff, 0 0 1.2em #6a1fff;
}

/* ===== Missions: breakthroughs, side quests, stamps, endings ===== */
.game-breakthrough {
  position: relative;
  padding: 1.25rem 1.5rem;
  border-radius: 10px;
  background:
    radial-gradient(ellipse at 15% 0%, rgba(242, 180, 92, 0.35), transparent 60%),
    #2a1a10;
  border: 2px solid var(--lamp-glow);
  box-shadow: 0 0 40px -10px rgba(242, 180, 92, 0.7);
  animation: game-breakthrough-in 0.6s ease-out;
}

@keyframes game-breakthrough-in {
  from { transform: scale(0.96); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.game-breakthrough-head {
  margin: 0 0 0.3rem;
  font-family: var(--font-typed);
  font-size: 0.9rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--lamp-glow);
}

.game-breakthrough-text {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--game-text);
}

.game-breakthrough-by {
  margin: 0.4rem 0 0;
  font-size: 0.8rem;
  color: var(--game-text-muted);
}

.game-leads li.is-breakthrough {
  border-left: 3px solid var(--lamp-glow);
  padding-left: 0.6rem;
  font-weight: 600;
}

.game-client-questions {
  margin: 0;
  padding-left: 1.2rem;
  font-family: var(--font-reading);
  font-size: 0.92rem;
}

.game-client-questions li {
  margin: 0.25rem 0;
}

.game-letter-questions {
  margin-top: 1.25rem;
  padding-top: 0.9rem;
  border-top: 1px dashed #b9a98a;
}

.game-letter-questions h3 {
  margin: 0 0 0.4rem;
  font-family: var(--font-typed);
  font-size: 0.9rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #8a3b2a;
}

.game-letter-questions ol {
  margin: 0;
  padding-left: 1.3rem;
  font-family: var(--font-reading);
}

.game-sidequests h2 {
  margin: 0 0 0.3rem;
}

.game-sidequest {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--game-paper-edge);
}

.game-sidequest-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.game-sidequest h3 {
  margin: 0 0 0.4rem;
  font-size: 1.2rem;
}

.game-sidequest-bonus {
  font-size: 0.75rem;
  font-weight: 700;
  color: #2e6b4f;
  border: 1px solid #2e6b4f;
  border-radius: 3px;
  padding: 0.05rem 0.45rem;
  white-space: nowrap;
}

.game-sidequest-intro,
.game-sidequest-result {
  font-family: var(--font-reading);
}

.game-sidequest .game-puzzle {
  margin-top: 0.75rem;
  box-shadow: inset 0 0 0 1px var(--game-paper-edge);
}

.game-sidequest .game-puzzle::before {
  display: none;
}

.game-doc {
  position: relative;
}

.game-doc-stamp {
  position: absolute;
  top: 38%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-14deg);
  padding: 0.15rem 0.9rem;
  border: 4px solid #a3262a;
  border-radius: 6px;
  color: #a3262a;
  font-family: var(--font-typed);
  font-size: 2rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0.85;
  pointer-events: none;
  mix-blend-mode: multiply;
  z-index: 2;
}

.game-ending {
  margin: 1rem 0;
  padding: 1rem 1.2rem;
  background: rgba(46, 107, 79, 0.08);
  border-left: 3px solid #2e6b4f;
  font-family: var(--font-reading);
}

.game-ending h3 {
  margin: 0 0 0.4rem;
}

.game-closed-bonus {
  color: #2e6b4f;
  font-weight: 600;
}

.game-board-team summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.game-board-team summary::-webkit-details-marker {
  display: none;
}

.game-board-team summary::after {
  content: " ▸";
  color: var(--color-copper);
  font-size: 0.8em;
}

.game-board-team[open] summary::after {
  content: " ▾";
}

.game-board-team span {
  display: block;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--color-ink-muted);
}

.game-overlay-print {
  font-family: var(--font-ui);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.1;
  color: #1d2f5e;
}

.game-overlay-engrave {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #3b2a12;
  text-shadow: 0 1px 0 rgba(255, 236, 190, 0.6);
}

/* Pictures open full screen on a click, writing and all, so small details can be read. */
.game-image {
  cursor: zoom-in;
}

.game-image.is-zoomed {
  position: fixed;
  z-index: 1000;
  top: 50%;
  left: 50%;
  width: min(96vw, 168vh);
  margin: 0;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 100vmax rgba(5, 8, 12, 0.88);
  cursor: zoom-out;
}

.game-image.is-zoomed img {
  max-height: none !important;
  object-fit: contain;
}

.game-thing.has-image {
  grid-column: 1 / -1;
}

.game-thing.has-image .game-thing-image img {
  max-height: 24rem;
}

.game-closed .game-stamp {
  display: inline-block;
}

/* ===== The field guide (How to Play) and the welcome card ===== */
.game-howto-card {
  margin: 0 0 2rem;
}

.game-howto-card summary {
  cursor: pointer;
  list-style: none;
}

.game-howto-card summary::-webkit-details-marker {
  display: none;
}

.game-howto-card summary .game-eyebrow {
  display: block;
  color: var(--color-copper);
}

.game-howto-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
}

.game-howto-title::after {
  content: " ▸";
  color: var(--color-copper);
  font-size: 0.8em;
}

.game-howto-card[open] .game-howto-title::after {
  content: " ▾";
}

.game-howto-steps {
  margin: 1rem 0 1.25rem;
  padding-left: 1.3rem;
  font-family: var(--font-reading);
  line-height: 1.55;
}

.game-howto-steps li {
  margin: 0.45rem 0;
}

.game-guide-hero {
  position: relative;
  margin: -1rem 0 1.5rem;
  border-radius: 12px;
  overflow: hidden;
}

.game-guide-hero img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 6;
  object-fit: cover;
}

.game-guide-hero-text {
  position: absolute;
  inset: auto 0 0 0;
  padding: 3rem 2rem 1.5rem;
  background: linear-gradient(180deg, transparent, rgba(8, 12, 18, 0.9));
}

.game-guide-hero-text h1 {
  margin: 0 0 0.3rem;
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  color: var(--lamp-glow);
}

.game-guide-hero-text p:last-child {
  margin: 0;
  color: var(--game-text);
  font-family: var(--font-reading);
}

.game-guide-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.6rem;
  margin: 0 0 2rem;
}

.game-guide-toc a {
  padding: 0.3rem 0.7rem;
  border: 1px solid var(--game-line);
  border-radius: 999px;
  color: var(--game-text-muted);
  text-decoration: none;
  font-size: 0.85rem;
}

.game-guide-toc a:hover {
  color: var(--game-text);
  border-color: var(--color-copper);
}

.game-guide {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 48rem;
}

.game-guide .game-dossier {
  font-family: var(--font-reading);
  line-height: 1.6;
  scroll-margin-top: 1.5rem;
}

.game-guide h2 {
  margin: 0 0 0.75rem;
  font-size: 1.5rem;
}

.game-guide li {
  margin: 0.35rem 0;
}

.game-guide-roles dt {
  font-family: var(--font-ui);
  font-weight: 700;
  color: var(--color-copper);
  margin-top: 0.6rem;
}

.game-guide-roles dd {
  margin: 0.1rem 0 0;
}

.game-guide-table-wrap {
  overflow-x: auto;
  margin: 1rem 0;
}

.game-guide-costs {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  min-width: 34rem;
}

.game-guide-costs th[scope="row"] {
  text-align: left;
  font-weight: 600;
}

.game-guide-costs td small {
  display: block;
  color: var(--color-ink-muted);
}

/* Show or hide the password while typing */
.game-password {
  position: relative;
  display: flex;
}

.game-password input {
  flex: 1;
  padding-right: 2.75rem !important;
}

.game-password-eye {
  position: absolute;
  right: 0.35rem;
  top: 50%;
  transform: translateY(-50%);
  width: 2.2rem;
  height: 2.2rem;
  display: grid;
  place-items: center;
  border: none;
  background: none;
  color: var(--color-ink-muted);
  cursor: pointer;
  border-radius: 4px;
}

.game-password-eye:hover,
.game-password-eye:focus-visible {
  color: var(--color-copper);
}

.game-password-eye svg {
  width: 1.3rem;
  height: 1.3rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.game-password-eye .game-eye-shut,
.game-password-eye.is-showing .game-eye-open {
  display: none;
}

.game-password-eye.is-showing .game-eye-shut {
  display: block;
}

.game-case-kind {
  align-self: flex-start;
}

/* International series: a ribbon across the card's top corner */
.game-sash {
  position: absolute;
  top: 0;
  right: 0;
  width: 150px;
  height: 150px;
  margin: 0;
  overflow: hidden;
  border-top-right-radius: 10px;
  pointer-events: none;
}

.game-sash span {
  position: absolute;
  top: 38px;
  right: -52px;
  width: 220px;
  padding: 0.32rem 0;
  transform: rotate(45deg);
  background: linear-gradient(180deg, #a3302e, #7e1f1f);
  color: var(--game-paper);
  text-align: center;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  box-shadow:
    inset 0 1px 0 rgba(246, 237, 220, 0.35),
    inset 0 -1px 0 rgba(0, 0, 0, 0.25),
    0 4px 10px -2px rgba(0, 0, 0, 0.45);
  outline: 1px dashed rgba(246, 237, 220, 0.45);
  outline-offset: -4px;
}

.game-case.is-international .game-case-setting,
.game-case.is-international h3 {
  padding-right: 3.5rem;
}

/* Folding sections on the case card (skill level, options) */
.game-fold {
  border: 1px solid rgba(27, 42, 65, 0.18);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.28);
}

.game-fold[open] {
  border-color: rgba(181, 101, 46, 0.55);
}

.game-fold > summary {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.15rem 0.45rem;
  padding: 0.65rem 2.75rem 0.65rem 0.8rem;
  position: relative;
  cursor: pointer;
  list-style: none;
}

.game-fold > summary::-webkit-details-marker {
  display: none;
}

.game-fold > summary:focus-visible {
  outline: 2px solid var(--color-copper);
  outline-offset: 2px;
  border-radius: 6px;
}

.game-fold-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-copper);
}

.game-fold-value {
  font-family: var(--font-reading);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--color-navy);
}

/* A brass button: plus when folded, minus when open. */
.game-fold-mark {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  width: 1.35rem;
  height: 1.35rem;
  margin-top: -0.675rem;
  border-radius: 50%;
  border: 1.5px solid var(--color-copper);
  background: radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.7), rgba(181, 101, 46, 0.12) 70%);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
  transition: transform 0.25s ease;
}

.game-fold-mark::before,
.game-fold-mark::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0.6rem;
  height: 2px;
  margin: -1px 0 0 -0.3rem;
  border-radius: 1px;
  background: var(--color-copper);
  transition: transform 0.25s ease;
}

.game-fold-mark::after {
  transform: rotate(90deg);
}

.game-fold[open] .game-fold-mark {
  transform: rotate(180deg);
}

.game-fold[open] .game-fold-mark::after {
  transform: rotate(0deg);
}

.game-fold > fieldset,
.game-fold-body {
  padding: 0 0.6rem 0.6rem;
}

.game-fold-body {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

/* Field notes: a page from the agency notebook, shown when a case closes */
.game-field-notes {
  position: relative;
  margin: 1.75rem 0 0;
  padding: 1.6rem 1.5rem 1.4rem 3.4rem;
  border-radius: 4px;
  color: #1f2c3f;
  background:
    linear-gradient(90deg, transparent 2.4rem, rgba(176, 58, 46, 0.45) 2.4rem, rgba(176, 58, 46, 0.45) calc(2.4rem + 1.5px), transparent calc(2.4rem + 1.5px)),
    repeating-linear-gradient(180deg, transparent 0, transparent 1.7rem, rgba(70, 110, 160, 0.12) 1.7rem, rgba(70, 110, 160, 0.12) calc(1.7rem + 1px)),
    #fbf7ec;
  box-shadow: 0 1px 0 #e7dcc4, 0 28px 50px -30px rgba(0, 0, 0, 0.8);
}

.game-field-notes-head {
  margin-bottom: 0.5rem;
}

.game-field-notes-kicker {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-copper);
}

.game-field-notes h2 {
  margin: 0;
  font-family: var(--font-hand);
  font-size: 2.3rem;
  font-weight: 700;
  line-height: 1.1;
  color: #23406b;
}

.game-field-notes-intro {
  font-family: var(--font-reading);
  font-style: italic;
  margin-bottom: 0.75rem;
}

.game-field-notes-list {
  margin: 0;
  padding-left: 1.1rem;
  font-family: var(--font-reading);
}

.game-field-notes-list li {
  margin: 0 0 1.1rem;
}

.game-field-notes-list li::marker {
  font-family: var(--font-hand);
  font-size: 1.25rem;
  font-weight: 700;
  color: #23406b;
}

.game-field-notes-list h3 {
  margin: 0 0 0.2rem;
  font-family: var(--font-hand);
  font-size: 1.45rem;
  font-weight: 700;
  color: #23406b;
}

.game-field-notes-list p {
  margin: 0 0 0.35rem;
}

.game-field-notes-source {
  font-family: var(--font-ui);
  font-size: 0.75rem;
  color: var(--color-ink-muted);
}

.game-field-notes-source a {
  color: var(--color-copper);
}

.game-field-notes-foot {
  margin: 0.5rem 0 0;
  font-family: var(--font-hand);
  font-size: 1.2rem;
  color: #23406b;
}

@media (max-width: 560px) {
  .game-field-notes {
    padding: 1.4rem 1rem 1.2rem 2.6rem;
    background:
      linear-gradient(90deg, transparent 1.7rem, rgba(176, 58, 46, 0.45) 1.7rem, rgba(176, 58, 46, 0.45) calc(1.7rem + 1.5px), transparent calc(1.7rem + 1.5px)),
      repeating-linear-gradient(180deg, transparent 0, transparent 1.7rem, rgba(70, 110, 160, 0.12) 1.7rem, rgba(70, 110, 160, 0.12) calc(1.7rem + 1px)),
      #fbf7ec;
  }
}

/* ---------- Christmas gift exchange (family page) ---------- */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.xmas-shell {
  --xmas-night: #0b1a24;
  --xmas-pine: #10301f;
  --xmas-gold: #d4b062;
  --xmas-gold-soft: #f3dfa6;
  --xmas-cream: #fbf5e6;
  --xmas-ink: #1d2a24;
  --xmas-berry: #8e2232;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2.5rem 16px 2rem;
  color: var(--xmas-cream);
  font-family: "Cormorant Garamond", Georgia, serif;
  background:
    radial-gradient(1.5px 1.5px at 12% 18%, rgba(255, 255, 255, 0.8), transparent 60%),
    radial-gradient(1px 1px at 28% 8%, rgba(255, 255, 255, 0.7), transparent 60%),
    radial-gradient(1.5px 1.5px at 72% 14%, rgba(255, 255, 255, 0.75), transparent 60%),
    radial-gradient(1px 1px at 86% 26%, rgba(255, 255, 255, 0.6), transparent 60%),
    radial-gradient(1px 1px at 58% 4%, rgba(255, 255, 255, 0.7), transparent 60%),
    radial-gradient(1px 1px at 40% 22%, rgba(255, 255, 255, 0.5), transparent 60%),
    radial-gradient(1.2px 1.2px at 92% 8%, rgba(255, 255, 255, 0.65), transparent 60%),
    radial-gradient(1px 1px at 6% 34%, rgba(255, 255, 255, 0.5), transparent 60%),
    radial-gradient(ellipse 60% 40% at 50% 0%, rgba(243, 215, 138, 0.18), transparent 70%),
    linear-gradient(180deg, var(--xmas-night) 0%, #0d2222 520px, var(--xmas-pine) 100%);
}

.xmas-header {
  text-align: center;
  max-width: 36rem;
}

.xmas-star {
  width: 104px;
  height: 104px;
  display: block;
  margin: 0 auto 0.5rem;
  filter: drop-shadow(0 0 18px rgba(243, 215, 138, 0.55));
}

.xmas-kicker {
  margin: 0;
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.8rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--xmas-gold);
}

.xmas-title {
  margin: 0.25rem 0 0;
  font-family: "Cinzel", Georgia, serif;
  font-weight: 600;
  font-size: clamp(2.2rem, 7vw, 3.4rem);
  letter-spacing: 0.06em;
  color: var(--xmas-gold-soft);
  text-shadow: 0 2px 18px rgba(212, 176, 98, 0.35);
}

/* Blazor focuses the heading after navigation; no box around the title. */
.xmas-title:focus {
  outline: none;
}

.xmas-subtitle {
  margin: 0.1rem 0 1.25rem;
  font-style: italic;
  font-size: 1.45rem;
  color: var(--xmas-cream);
}

.xmas-verse {
  margin: 0 auto;
  padding: 0.9rem 0 0;
  border-top: 1px solid rgba(212, 176, 98, 0.35);
  font-size: 1.2rem;
  font-style: italic;
  line-height: 1.5;
  color: rgba(251, 245, 230, 0.88);
}

.xmas-verse cite,
.xmas-footer cite {
  display: block;
  margin-top: 0.25rem;
  font-family: "Cinzel", Georgia, serif;
  font-style: normal;
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--xmas-gold);
}

.xmas-main {
  width: 100%;
  max-width: 40rem;
  margin-top: 2rem;
}

.xmas-card {
  position: relative;
  padding: 2rem 1.75rem 1.75rem;
  border-radius: 6px;
  color: var(--xmas-ink);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255, 255, 255, 0.7), transparent 60%),
    var(--xmas-cream);
  border: 1px solid var(--xmas-gold);
  outline: 1px solid rgba(212, 176, 98, 0.55);
  outline-offset: -8px;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.85);
}

.xmas-card h2 {
  margin: 0 0 0.35rem;
  text-align: center;
  font-family: "Cinzel", Georgia, serif;
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: 0.08em;
  color: var(--xmas-berry);
}

.xmas-card h2::after {
  content: "";
  display: block;
  width: 7rem;
  height: 10px;
  margin: 0.5rem auto 0;
  background:
    radial-gradient(circle, var(--xmas-gold) 2.5px, transparent 3px) center / 10px 10px no-repeat,
    linear-gradient(90deg, transparent, var(--xmas-gold) 30%, transparent 46%, transparent 54%, var(--xmas-gold) 70%, transparent) center / 100% 1px no-repeat;
}

.xmas-note {
  margin: 0.75rem 0 1.25rem;
  text-align: center;
  font-size: 1.2rem;
  font-style: italic;
  color: #43514a;
}

.xmas-error {
  margin: 0 0 1rem;
  text-align: center;
  font-size: 1.1rem;
  color: var(--xmas-berry);
}

.xmas-enter {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  max-width: 20rem;
  margin: 0 auto;
}

.xmas-enter label {
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #5b5236;
}

.xmas-password {
  display: flex;
  border: 1px solid #b9a26a;
  border-radius: 4px;
  background: #fffdf7;
}

.xmas-password:focus-within {
  outline: 2px solid var(--xmas-gold);
  outline-offset: 1px;
}

.xmas-password input {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  padding: 0.65rem 0.75rem;
  font-size: 1.05rem;
  font-family: var(--font-ui);
  color: var(--xmas-ink);
  outline: none;
}

.xmas-eye {
  border: none;
  background: transparent;
  padding: 0 0.7rem;
  cursor: pointer;
  color: #6f6440;
}

.xmas-eye svg {
  width: 1.3rem;
  height: 1.3rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
}

.xmas-eye .xmas-eye-slash {
  display: none;
}

.xmas-eye.is-showing .xmas-eye-slash {
  display: inline;
}

.xmas-btn {
  margin-top: 0.4rem;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--xmas-cream);
  background: linear-gradient(180deg, #a12a3b, var(--xmas-berry));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 6px 14px -6px rgba(142, 34, 50, 0.7);
}

.xmas-btn:hover {
  background: linear-gradient(180deg, #b13244, #9a2637);
}

.xmas-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.xmas-list li {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.25rem;
  border-bottom: 1px dashed rgba(185, 162, 106, 0.55);
  font-size: 1.2rem;
}

.xmas-list li:last-child {
  border-bottom: none;
}

.xmas-giver {
  text-align: right;
  font-weight: 600;
}

.xmas-recipient {
  font-weight: 600;
  color: var(--xmas-pine);
}

.xmas-list li.is-waiting .xmas-recipient {
  font-weight: 500;
  font-style: italic;
  color: #8a8770;
}

.xmas-for {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.xmas-gift svg {
  display: block;
  width: 1.5rem;
  height: 1.5rem;
  fill: rgba(142, 34, 50, 0.12);
  stroke: var(--xmas-berry);
  stroke-width: 1.4;
  stroke-linejoin: round;
}

.xmas-leave {
  margin-top: 1.25rem;
  text-align: center;
}

.xmas-leave button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: var(--font-ui);
  font-size: 0.8rem;
  color: #6f6a55;
  text-decoration: underline;
}

.xmas-footer {
  margin-top: auto;
  padding-top: 2.5rem;
  text-align: center;
  font-size: 1.1rem;
  font-style: italic;
  color: rgba(251, 245, 230, 0.8);
}

.xmas-footer p {
  margin: 0;
}

@media (max-width: 520px) {
  .xmas-card {
    padding: 1.6rem 1.1rem 1.4rem;
  }

  .xmas-list li {
    grid-template-columns: 1fr;
    gap: 0.1rem;
    text-align: center;
  }

  .xmas-giver {
    text-align: center;
  }

  .xmas-gift {
    display: none;
  }

  .xmas-for {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
    font-family: "Cinzel", Georgia, serif;
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--xmas-berry);
  }
}

/* Admin: Christmas drawing */
.c2026-draw {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem;
}

.c2026-actions {
  margin-top: 1rem;
  flex-wrap: wrap;
  justify-content: flex-start;
}

.c2026-inline {
  display: flex;
  gap: 0.4rem;
  align-items: center;
}

.c2026-inline select {
  max-width: 12rem;
}

.c2026-row-actions {
  white-space: nowrap;
}

.c2026-highlight td {
  background: rgba(212, 176, 98, 0.18);
}

/* Sign-in, step two: tap your name */
.game-who-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
  gap: 0.6rem;
  margin: 0 0 1.25rem;
}

.game-who-pick {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  padding: 0.75rem 0.85rem;
  border: 1px solid rgba(27, 42, 65, 0.2);
  border-radius: 6px;
  background: #fffdf8;
  color: var(--color-navy);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.game-who-pick span {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
}

.game-who-pick small {
  font-size: 0.72rem;
  color: var(--color-ink-muted);
}

.game-who-pick:hover,
.game-who-pick:focus-visible {
  border-color: var(--color-copper);
  box-shadow: 0 6px 16px -10px rgba(181, 101, 46, 0.8);
  transform: translateY(-1px);
  outline: none;
}

.game-who-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-copper);
}

.game-who-divider::before,
.game-who-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(181, 101, 46, 0.35);
}

.game-who-restart {
  margin: 1.25rem 0 0;
  font-size: 0.85rem;
  text-align: center;
}

/* Side quest payback: what a quest takes and what it gives back */
.game-sidequest-terms {
  margin: 0.4rem 0 0.6rem;
  padding: 0.35rem 0.6rem;
  border-left: 3px solid #2e6b4f;
  background: rgba(46, 107, 79, 0.08);
  font-size: 0.85rem;
  color: var(--color-navy);
}

.game-letter-note {
  margin: 0.9rem 0 0;
  padding-top: 0.6rem;
  border-top: 1px dashed rgba(27, 42, 65, 0.25);
  font-size: 0.92rem;
}

/* A period picture pinned to a field note, like a print tucked into a notebook */
.game-field-notes-picture {
  float: right;
  display: table;
  margin: 0.2rem 0 0.6rem 1rem;
  padding: 0.45rem 0.45rem 0.35rem;
  background: #fffdf6;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.18), 0 6px 14px -8px rgba(0, 0, 0, 0.45);
  transform: rotate(1.5deg);
}

.game-field-notes-list li:nth-child(even) .game-field-notes-picture {
  transform: rotate(-1.5deg);
}

.game-field-notes-picture img {
  display: block;
  width: auto;
  height: auto;
  max-width: min(16rem, 38vw);
  max-height: 12rem;
}

.game-field-notes-picture figcaption {
  display: table-caption;
  caption-side: bottom;
  padding: 0.3rem 0.45rem 0.35rem;
  background: #fffdf6;
  font-family: var(--font-ui);
  font-size: 0.65rem;
  line-height: 1.3;
  color: var(--color-ink-muted);
}

/* Clear the pinned picture without losing the note's number. */
.game-field-notes-list li.has-picture::after {
  content: "";
  display: block;
  clear: both;
}

@media (max-width: 560px) {
  .game-field-notes-picture {
    float: none;
    margin: 0.3rem auto 0.6rem;
    transform: none;
  }

  .game-field-notes-picture img {
    max-width: 100%;
    max-height: 16rem;
  }
}

/* ===== Agencies, sign-up, and the agency page ===== */
.game-nav-public {
  margin-left: 0;
}

.game-who a.game-signout {
  text-decoration: none;
}

.game-btn-copper {
  background: var(--color-copper);
  color: #fff;
}

.game-btn-copper:hover {
  background: var(--color-copper-light);
}

.game-btn-small {
  padding: 0.4rem 0.85rem;
  font-size: 0.85rem;
}

.game-btn-ghost-dark {
  background: none;
  border-color: rgba(27, 42, 65, 0.3);
  color: var(--color-navy);
}

.game-btn-ghost-dark:hover {
  border-color: var(--color-copper);
  color: var(--color-copper);
}

.game-btn.is-disabled {
  opacity: 0.55;
  cursor: default;
}

.game-btn.is-disabled:hover {
  background: var(--color-navy);
}

.game-form input[type="email"],
.game-form input[type="number"],
.game-form input[type="date"] {
  font: inherit;
  font-weight: 400;
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fffdf8;
  color: var(--color-navy);
}

.game-form label.game-check {
  flex-direction: row;
  align-items: flex-start;
  gap: 0.55rem;
  font-weight: 400;
}

.game-check input {
  margin-top: 0.3rem;
  accent-color: var(--color-copper);
}

.game-signup-card {
  max-width: 30rem;
}

.game-login-alt {
  margin: 1.25rem 0 0;
  font-size: 0.9rem;
  color: var(--color-ink-muted);
}

.game-login-alt a {
  color: var(--color-copper);
  font-weight: 600;
}

.game-login-team {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(27, 42, 65, 0.25);
}

.game-login-team > summary {
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-ink-muted);
}

.game-login-team[open] > summary {
  margin-bottom: 0.6rem;
}

.game-login-team .game-hint {
  margin-bottom: 0.9rem;
}

.game-notice-dark {
  color: var(--game-text);
  margin: 0 0 1.5rem;
}

.game-notice-dark a {
  color: var(--color-copper-light);
}

.game-case-lock {
  margin: auto 0 0.9rem;
  font-size: 0.9rem;
  color: var(--color-ink-muted);
}

.game-case-lock a {
  color: var(--color-copper);
}

.game-case-release {
  margin: 0 0 0.9rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #7e1f1f;
}

.game-case.is-preview {
  outline: 2px dashed rgba(181, 101, 46, 0.6);
  outline-offset: 4px;
}

.game-seat-pick {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin: 0 0 0.6rem;
  font-size: 0.85rem;
}

.game-seat-pick select {
  font: inherit;
  padding: 0.35rem;
}

.game-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.game-agency-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.25rem 1.5rem;
  margin: 1rem 0 2.25rem;
}

.game-agency-card h2,
.game-agency-squad h2 {
  font-size: 1.4rem;
  margin: 0 0 0.6rem;
}

.game-agency-card .game-btn {
  margin-top: 0.5rem;
}

.game-agency-offer {
  margin: 1rem 0 0;
  padding: 0.9rem 1rem;
  background: rgba(181, 101, 46, 0.08);
  border-left: 3px solid var(--color-copper);
  border-radius: 0 6px 6px 0;
}

.game-agency-offer p {
  margin: 0 0 0.4rem;
}

.game-agency-billing {
  margin-top: 1rem;
}

.game-agency-list {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
}

.game-agency-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid rgba(27, 42, 65, 0.1);
}

.game-agency-list small {
  color: var(--color-ink-muted);
}

.game-agency-squad {
  margin: 0 0 2.25rem;
}

.game-agency-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.game-agency-head .game-hint {
  max-width: 24rem;
  margin: 0;
}

.game-agency-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.game-agency-table th {
  text-align: left;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-ink-muted);
  padding: 0.4rem 0.5rem;
  border-bottom: 1px solid rgba(27, 42, 65, 0.2);
}

.game-agency-table td {
  padding: 0.55rem 0.5rem;
  border-bottom: 1px solid rgba(27, 42, 65, 0.1);
  vertical-align: middle;
}

.game-agency-actions > div {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  flex-wrap: wrap;
}

.game-link-btn {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  font-size: 0.85rem;
  color: var(--color-copper);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.game-link-danger {
  color: #a03e3e;
}

.game-agency-invite {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px dashed rgba(27, 42, 65, 0.25);
}

.game-agency-invite h3 {
  margin: 0 0 0.3rem;
  font-size: 1.15rem;
}

.game-copy {
  display: flex;
  gap: 0.5rem;
  margin: 0.75rem 0 1rem;
}

.game-copy input {
  flex: 1;
  min-width: 0;
  font: inherit;
  font-size: 0.9rem;
  padding: 0.6rem 0.7rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fffdf8;
  color: var(--color-navy);
}

.game-agency-buttons {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.game-agency-leave {
  margin-top: 1.25rem;
}

@media (max-width: 560px) {
  .game-agency-table thead {
    display: none;
  }

  .game-agency-table tr {
    display: grid;
    grid-template-columns: 1fr auto;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(27, 42, 65, 0.1);
  }

  .game-agency-table td {
    border: none;
    padding: 0.15rem 0;
  }

  .game-agency-table td:nth-child(3) {
    color: var(--color-ink-muted);
    font-size: 0.85rem;
  }

  .game-agency-actions {
    grid-column: 1 / -1;
  }

  .game-agency-actions > div {
    justify-content: flex-start;
  }

  .game-copy {
    flex-direction: column;
  }
}

/* ===== The Lamplight page (public) ===== */
.lamp-hero {
  position: relative;
  margin: -1rem 0 3rem;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 30px 60px -35px rgba(0, 0, 0, 0.9);
}

.lamp-hero img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 8;
  object-fit: cover;
  object-position: 50% 55%;
}

.lamp-hero-text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 2.5rem;
  background: linear-gradient(90deg, rgba(8, 12, 18, 0.92) 0%, rgba(8, 12, 18, 0.7) 45%, rgba(8, 12, 18, 0.1) 80%);
}

.lamp-hero-text h1 {
  max-width: 34rem;
  margin: 0 0 0.9rem;
  font-size: clamp(1.7rem, 3.6vw, 2.7rem);
  color: var(--game-text);
}

.lamp-hero-lede {
  max-width: 32rem;
  margin: 0 0 1.25rem;
  font-family: var(--font-reading);
  font-size: 1.1rem;
  color: var(--game-text-muted);
}

.lamp-cta {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.lamp-section {
  margin: 0 0 4rem;
}

.lamp-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin: 0 0 1.25rem;
}

.lamp-lede {
  max-width: 44rem;
  font-family: var(--font-reading);
  font-size: 1.1rem;
  color: var(--game-text-muted);
}

.lamp-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.lamp-steps li {
  padding: 1.25rem;
  background: var(--game-panel);
  border: 1px solid var(--game-line);
  border-radius: 10px;
}

.lamp-steps h3 {
  margin: 0.6rem 0 0.4rem;
  font-size: 1.15rem;
}

.lamp-steps p {
  margin: 0;
  color: var(--game-text-muted);
  font-size: 0.95rem;
}

.lamp-step-num {
  display: inline-grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  border: 2px solid var(--lamp-glow);
  color: var(--lamp-glow);
  font-weight: 700;
}

.lamp-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem 2rem;
}

.lamp-tile {
  padding: 0.25rem 0 0.25rem 1rem;
  border-left: 2px solid var(--color-copper);
}

.lamp-tile h3 {
  margin: 0 0 0.3rem;
  font-size: 1.1rem;
  color: var(--lamp-glow);
}

.lamp-tile p {
  margin: 0;
  color: var(--game-text-muted);
}

.lamp-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  gap: 2rem;
  align-items: center;
}

.lamp-split img {
  width: 100%;
  border-radius: 10px;
  box-shadow: 0 24px 50px -30px rgba(0, 0, 0, 0.9);
}

.lamp-split p {
  color: var(--game-text-muted);
  font-family: var(--font-reading);
  font-size: 1.05rem;
}

.lamp-coming {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 2.25rem 1.5rem;
  padding-top: 0.75rem;
}

.lamp-coming-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.3rem;
}

.lamp-coming-card.is-international .game-case-setting,
.lamp-coming-card.is-international h3 {
  padding-right: 3.5rem;
}

.lamp-founding {
  display: inline-block;
  margin: 0 0 1.75rem;
  padding: 0.6rem 0.9rem;
  border: 1px dashed rgba(242, 180, 92, 0.6);
  border-radius: 6px;
  color: var(--game-text);
}

.lamp-founding strong {
  color: var(--lamp-glow);
}

.lamp-plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 2.25rem 1.25rem;
  padding-top: 0.75rem;
}

.lamp-plan {
  display: flex;
  flex-direction: column;
  text-align: center;
}

.lamp-plan.is-best {
  outline: 2px solid var(--color-copper);
  outline-offset: 3px;
}

.lamp-plan h3 {
  margin: 0 0 0.5rem;
  font-size: 1.3rem;
}

.lamp-plan-save {
  align-self: center;
  margin: 0 0 0.5rem;
  padding: 0.1rem 0.6rem;
  border-radius: 999px;
  background: rgba(181, 101, 46, 0.15);
  color: var(--color-copper);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.lamp-plan-price {
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: baseline;
  gap: 0.5rem;
}

.lamp-plan-now {
  font-family: var(--font-display);
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--color-navy);
}

.lamp-plan-was {
  color: var(--color-ink-muted);
}

.lamp-plan-billed {
  margin: 0;
  color: var(--color-ink-muted);
  font-size: 0.9rem;
}

.lamp-plan-case {
  margin: 0.6rem 0 1.25rem;
  font-size: 0.85rem;
}

.lamp-plan .game-btn {
  margin-top: auto;
}

.lamp-plan-free {
  margin-top: 0.6rem;
  font-size: 0.85rem;
  color: var(--color-copper);
  font-weight: 600;
}

.lamp-plan-note {
  margin-top: 1.5rem;
  max-width: 44rem;
}

.lamp-plan-note a {
  color: var(--color-copper-light);
}

.lamp-extras {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.25rem 1.5rem;
}

.lamp-extra h3 {
  margin: 0 0 0.5rem;
  font-size: 1.3rem;
}

.lamp-faq {
  max-width: 46rem;
}

.lamp-faq details {
  border-bottom: 1px solid var(--game-line);
  padding: 0.9rem 0;
}

.lamp-faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 1.05rem;
}

.lamp-faq p {
  margin: 0.6rem 0 0;
  color: var(--game-text-muted);
}

.lamp-final {
  text-align: center;
  padding: 2.5rem 1rem;
  border: 1px solid var(--game-line);
  border-radius: 12px;
  background: radial-gradient(ellipse at 50% 0%, rgba(242, 180, 92, 0.12), transparent 65%);
}

.lamp-final p {
  color: var(--game-text-muted);
  margin: 0 0 1.25rem;
}

.lamp-terms {
  max-width: 46rem;
  margin: 0 auto;
}

.lamp-terms h1 {
  margin: 0 0 1rem;
}

.lamp-terms h2 {
  font-size: 1.2rem;
  margin: 1.75rem 0 0.5rem;
}

.lamp-terms li {
  margin-bottom: 0.4rem;
}

@media (max-width: 760px) {
  /* On phones the words set the height and the picture fills in behind them. */
  .lamp-hero img {
    position: absolute;
    inset: 0;
    height: 100%;
    aspect-ratio: auto;
  }

  .lamp-hero-text {
    position: relative;
    padding: 14rem 1.5rem 1.5rem;
    background: linear-gradient(180deg, rgba(8, 12, 18, 0.05) 0%, rgba(8, 12, 18, 0.8) 38%, rgba(8, 12, 18, 0.95) 100%);
  }

  .lamp-split {
    grid-template-columns: 1fr;
  }
}

/* ===== Admin: Lamplight ===== */
.admin-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
  margin: 0 0 1.5rem;
}

.admin-tile {
  display: flex;
  flex-direction: column;
  padding: 0.8rem 1rem;
  background: #fff;
  border: 1px solid rgba(27, 42, 65, 0.12);
  border-radius: 8px;
}

.admin-tile-num {
  font-family: var(--font-display);
  font-size: 1.8rem;
  line-height: 1.1;
}

.admin-tile-label {
  font-size: 0.8rem;
  color: var(--color-ink-muted);
}

.admin-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1.5rem 0 1rem;
}

.admin-filter a {
  padding: 0.25rem 0.75rem;
  border: 1px solid rgba(27, 42, 65, 0.2);
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.85rem;
}

.admin-filter a.is-active {
  background: var(--color-navy);
  color: var(--color-ivory);
  border-color: var(--color-navy);
}

.admin-badge {
  display: inline-block;
  vertical-align: middle;
  margin-left: 0.5rem;
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  font-family: var(--font-ui);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  background: rgba(27, 42, 65, 0.08);
}

.admin-badge-member {
  background: rgba(111, 174, 140, 0.25);
}

.admin-badge-comp {
  background: rgba(181, 101, 46, 0.18);
}

.admin-badge-tester {
  background: rgba(70, 110, 180, 0.18);
}

.admin-form.game-admin-access {
  max-width: none;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem 1rem;
  margin: 1rem 0;
}

.game-admin-access label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.85rem;
}

.game-admin-note {
  flex: 1;
  min-width: 14rem;
}

.admin-sidebar nav a.admin-subnav {
  padding-left: 0.9rem;
  font-size: 0.9rem;
}

.game-calendar small {
  display: block;
}

.admin-table tr.is-empty td,
.admin-table tr.is-warning td {
  background: rgba(160, 62, 62, 0.06);
}

/* Blazor moves focus to the page title after navigating; no box around it. */
h1:focus {
  outline: none;
}

.admin-form.game-calendar-form {
  max-width: none;
}

.admin-form input[type="number"],
.admin-form input[type="date"] {
  font: inherit;
  padding: 0.55rem 0.7rem;
  border: 1px solid rgba(27, 42, 65, 0.25);
  border-radius: 4px;
  background: #fff;
  max-width: 12rem;
}

.game-calendar input[type="date"] {
  max-width: 10rem;
}

.game-calendar input[type="text"] {
  max-width: 6rem;
}

.lamp-plan-save.is-plain {
  background: rgba(27, 42, 65, 0.07);
  color: var(--color-ink-muted);
}
