/* ABSURD! online play — light & fun. Standalone: does NOT use the dark site styles. */
:root {
  --cream: #f7f3e8;
  --cream-deep: #efe8d5;
  --ink: #3a3428;
  --ink-soft: #6b6252;
  --blue: #2f4d7a;    /* situation */
  --green: #2e5d43;   /* interpretation */
  --red: #8a3535;     /* emotion */
  --gold: #b98a2f;
  --card-bg: #fffdf6;
  --radius: 14px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: Georgia, 'Times New Roman', serif;
  line-height: 1.5;
  min-height: 100vh;
}

.topbar {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  padding: 1rem 1.5rem;
  border-bottom: 2px solid var(--cream-deep);
}
.brand {
  font-weight: bold;
  font-size: 1.3rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: 0.04em;
}
.brand .mark { color: var(--gold); }
.tagline { color: var(--ink-soft); font-style: italic; }

.wrap {
  max-width: 640px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

.screen h1 { font-size: 2.2rem; margin: 0.5rem 0; }
.screen h2 { font-size: 1.7rem; margin: 0.5rem 0 1rem; }
.screen h3 { font-size: 1.2rem; margin: 1.5rem 0 0.75rem; }
.lede { font-size: 1.1rem; color: var(--ink-soft); font-style: italic; }
.hint { color: var(--ink-soft); font-size: 0.95rem; font-style: italic; }
.error { color: var(--red); font-style: italic; }

.steam-cup { text-align: center; margin: 1rem 0 0; }

.field { display: block; margin: 1.5rem 0; }
.field span { display: block; font-style: italic; color: var(--ink-soft); margin-bottom: 0.4rem; }
.field input, .join-code input {
  font-family: inherit;
  font-size: 1.1rem;
  padding: 0.6rem 0.9rem;
  border: 2px solid var(--cream-deep);
  border-radius: var(--radius);
  background: var(--card-bg);
  color: var(--ink);
  width: 100%;
  max-width: 320px;
}
.field input:focus, .join-code input:focus { outline: 2px solid var(--gold); border-color: var(--gold); }

.btn-row { display: flex; gap: 0.75rem; flex-wrap: wrap; margin: 1.25rem 0; }
.btn {
  font-family: inherit;
  font-size: 1rem;
  padding: 0.65rem 1.4rem;
  border-radius: 999px;
  border: 2px solid var(--ink);
  background: var(--ink);
  color: var(--cream);
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}
.btn:hover { opacity: 0.88; }
.btn:disabled { opacity: 0.4; cursor: default; }
.btn:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.btn.big { font-size: 1.15rem; padding: 0.8rem 1.8rem; }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.small { font-size: 0.9rem; padding: 0.4rem 1rem; }

.join-code {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 2px dashed var(--cream-deep);
  flex-wrap: wrap;
}
.join-code input { max-width: 130px; text-transform: uppercase; }
.join-code span { font-style: italic; color: var(--ink-soft); }

.code-box {
  background: var(--card-bg);
  border: 2px dashed var(--gold);
  border-radius: var(--radius);
  padding: 0.9rem 1.2rem;
  margin: 1rem 0;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}
.code-box strong {
  font-size: 1.5rem;
  letter-spacing: 0.2em;
  color: var(--blue);
}

.players { list-style: none; padding: 0; margin: 1rem 0; }
.players li {
  background: var(--card-bg);
  border: 2px solid var(--cream-deep);
  border-radius: var(--radius);
  padding: 0.6rem 1rem;
  margin-bottom: 0.5rem;
  font-size: 1.05rem;
}
.players li.you { border-color: var(--gold); }
.players li .host-tag {
  font-size: 0.8rem;
  font-style: italic;
  color: var(--ink-soft);
  margin-left: 0.5rem;
}

.turn-banner {
  text-align: center;
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

/* Cards — echo the physical deck: cream, double border, serif, colored type */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 1.5rem 1.75rem;
  margin: 1rem 0;
  position: relative;
  border: 2px solid;
}
.card::after {
  content: '';
  position: absolute;
  inset: 5px;
  border: 1px solid;
  border-radius: 9px;
  pointer-events: none;
}
.card.situation { border-color: var(--blue); }
.card.situation::after { border-color: var(--blue); opacity: 0.45; }
.card.interpretation { border-color: var(--green); }
.card.interpretation::after { border-color: var(--green); opacity: 0.45; }
.card.emotion { border-color: var(--red); }
.card.emotion::after { border-color: var(--red); opacity: 0.45; }
.card.waiting-card { border-color: var(--cream-deep); }
.card.waiting-card::after { border-color: var(--cream-deep); }

.card-type {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.85rem;
  font-weight: bold;
  margin: 0 0 0.75rem;
}
.situation .card-type { color: var(--blue); }
.interpretation .card-type { color: var(--green); }
.emotion .card-type { color: var(--red); }
.waiting-card .card-type { color: var(--ink-soft); }

.card-text {
  font-style: italic;
  font-size: 1.25rem;
  line-height: 1.6;
  margin: 0;
  text-align: center;
  overflow-wrap: break-word;
}
.situation .card-text { color: var(--blue); }
.interpretation .card-text { color: var(--green); }
.emotion .card-text { color: var(--red); }

.step-tag {
  font-size: 0.8rem;
  font-weight: normal;
  font-style: italic;
  color: var(--ink-soft);
}

.options { display: grid; gap: 0.6rem; margin: 0.75rem 0 1.5rem; }
.option {
  font-family: inherit;
  text-align: left;
  background: var(--card-bg);
  border: 2px solid var(--cream-deep);
  border-radius: var(--radius);
  padding: 0.8rem 1.1rem;
  min-height: 48px;
  font-size: 1.02rem;
  font-style: italic;
  color: var(--ink);
  cursor: pointer;
  line-height: 1.5;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}
.option:hover { border-color: var(--gold); }
.option:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.option.selected { border-color: var(--ink); background: #fff; box-shadow: 0 2px 0 var(--ink); }
#interp-options .option.selected { border-color: var(--green); box-shadow: 0 2px 0 var(--green); }
#emotion-options .option.selected { border-color: var(--red); box-shadow: 0 2px 0 var(--red); }

.rounds { display: grid; gap: 1rem; margin: 1rem 0; }
.round {
  background: var(--card-bg);
  border: 2px solid var(--cream-deep);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
}
.round .who { font-weight: bold; margin-bottom: 0.4rem; }
.round .bits { font-style: italic; color: var(--ink-soft); line-height: 1.7; }
.round .bits b.s { color: var(--blue); font-style: normal; }
.round .bits b.i { color: var(--green); font-style: normal; }
.round .bits b.e { color: var(--red); font-style: normal; }
.round.votable { cursor: pointer; }
.round.votable:hover { border-color: var(--gold); }
.round.voted { border-color: var(--gold); background: #fff; }
.round.own { opacity: 0.55; }
.round.winning { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(185,138,47,.25); }

.winner-card {
  background: var(--card-bg);
  border: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  margin: 1.5rem 0;
}
.winner-card .card-type { color: var(--gold); }
.winner-card h2 { font-size: 2rem; margin: 0.25rem 0 1rem; }
.winner-card .card-text { color: var(--ink); }

.foot {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--ink-soft);
  font-size: 0.9rem;
  font-style: italic;
  border-top: 2px solid var(--cream-deep);
}

@media (max-width: 520px) {
  .screen h1 { font-size: 1.8rem; }
  .card { padding: 1.25rem 1.25rem; }
  .card-text { font-size: 1.1rem; }
  .btn.big { width: 100%; text-align: center; }
  .options { gap: 0.75rem; }
  .wrap { padding: 1.5rem 1rem 3rem; }
  .field input { font-size: 16px; } /* stops iOS auto-zoom on focus */
}

/* ---- drop-in table additions ---- */
.solo-note {
  display: inline-block;
  font-style: italic;
  font-size: 0.9rem;
  color: var(--ink-soft);
  background: var(--cream-deep);
  border-radius: 999px;
  padding: 0.25rem 0.9rem;
  margin: 0.25rem 0 0;
}

.judge-banner {
  background: var(--card-bg);
  border: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 1.5rem 1.75rem;
  margin: 1.5rem 0;
  text-align: center;
}
.judge-banner .card-type { color: var(--gold); }
.judge-banner p { margin: 0.4rem 0; font-size: 1.1rem; }
.judge-banner .btn-row { justify-content: center; margin-bottom: 0; }

.played-head { margin-top: 2rem; }

.foot a { color: var(--blue); }
