/* ============================================================
   RAPAT KOS DARURAT — satu stylesheet, tanpa framework.
   Palet: malam kos (indigo), lampu lorong (amber), tuyul (pink),
   gembok (mint). Semua aset visual CSS/emoji; mudah diganti.
   ============================================================ */

:root {
  --bg: #0b0918;
  --bg-2: #120d24;
  --card: rgba(255, 255, 255, 0.055);
  --card-solid: #17112c;
  --ink: #f7f0e6;
  --muted: #a89cc4;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.2);
  --amber: #ffc046;
  --amber-2: #ff8a3d;
  --mint: #4fe0c1;
  --pink: #ff6b9d;
  --violet: #9b7bff;
  --danger: #ff5c6c;
  --radius: 22px;
  --shadow: 0 26px 70px -34px rgba(0, 0, 0, 0.95);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --font-body: "Plus Jakarta Sans", ui-rounded, "Segoe UI", system-ui, -apple-system,
    sans-serif;
  --font-display: "Bebas Neue", "Arial Narrow", Impact, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  background:
    radial-gradient(1100px 620px at 12% -12%, rgba(155, 123, 255, 0.2), transparent 62%),
    radial-gradient(900px 520px at 108% 4%, rgba(255, 107, 157, 0.14), transparent 58%),
    radial-gradient(820px 640px at 50% 118%, rgba(79, 224, 193, 0.1), transparent 62%),
    var(--bg);
  background-attachment: fixed;
  overflow-x: hidden;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
  background-image: repeating-linear-gradient(
    115deg,
    transparent 0 38px,
    rgba(255, 255, 255, 0.012) 38px 39px
  );
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1,
h2,
h3 {
  line-height: 1.05;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(32px, 8vw, 52px);
  font-weight: 800;
}

h2 {
  font-size: clamp(20px, 4.6vw, 26px);
  font-weight: 800;
}

h3 {
  font-size: 17px;
  font-weight: 750;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

a {
  color: var(--amber);
}

::selection {
  background: rgba(255, 192, 70, 0.3);
}

.wrap {
  position: relative;
  z-index: 1;
  width: min(100%, 760px);
  margin: 0 auto;
  padding: 18px 16px calc(32px + var(--safe-b));
}

.muted {
  color: var(--muted);
}

.center {
  text-align: center;
}

.hint {
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.5;
}

.error-line {
  color: var(--danger);
}

.eyebrow {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------------------------------------------------------- */
/* Tombol & input                                             */
/* ---------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 13px 18px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.065);
  color: var(--ink);
  font-weight: 750;
  font-size: 15px;
  text-decoration: none;
  transition: transform 0.12s ease, background 0.2s ease, border-color 0.2s ease,
    filter 0.2s ease;
}

.btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn:active {
  transform: scale(0.985);
}

.btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}

.btn:focus-visible,
.avatar:focus-visible,
.action-card:focus-visible,
.area-card:focus-visible,
.vote-card:focus-visible,
.code-big:focus-visible,
.link-btn:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 2px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--amber) 0%, var(--amber-2) 100%);
  border: 0;
  color: #241300;
  box-shadow: 0 16px 40px -18px rgba(255, 154, 60, 0.85);
}

.btn-primary:hover {
  filter: brightness(1.05);
  background: linear-gradient(135deg, var(--amber) 0%, var(--amber-2) 100%);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
}

.btn-danger {
  border-color: rgba(255, 92, 108, 0.4);
  color: #ffb4bc;
}

.btn-big {
  width: 100%;
  min-height: 56px;
  font-size: 16px;
}

.btn-xl {
  width: 100%;
  min-height: 62px;
  font-size: 18px;
  border-radius: 18px;
}

.btn-block {
  width: 100%;
}

.btn-sm {
  min-height: 42px;
  padding: 9px 14px;
  font-size: 13px;
  border-radius: 12px;
}

.link-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 0;
  background: none;
  color: var(--amber);
  font-weight: 700;
  font-size: 13px;
  padding: 6px 4px;
  text-decoration: none;
}

.link-btn.subtle {
  color: var(--muted);
  margin: 10px auto 0;
  display: block;
}

.field {
  display: grid;
  gap: 7px;
  margin-bottom: 16px;
}

.field > span {
  font-size: 12px;
  font-weight: 750;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.field.compact {
  margin-bottom: 0;
}

input,
select {
  width: 100%;
  min-height: 50px;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #0e0a1f;
  color: var(--ink);
  font-size: 16px; /* mencegah zoom iOS */
  transition: border-color 0.2s, box-shadow 0.2s;
}

select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

input::placeholder {
  color: #6f6488;
}

input:focus,
select:focus {
  outline: 0;
  border-color: rgba(255, 192, 70, 0.65);
  box-shadow: 0 0 0 3px rgba(255, 192, 70, 0.13);
}

/* ---------------------------------------------------------- */
/* Kartu umum                                                 */
/* ---------------------------------------------------------- */

.panel {
  position: relative;
  margin-top: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.022));
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.section-head h2 {
  font-size: 19px;
}

.count {
  color: var(--amber);
  font-size: 14px;
  font-weight: 800;
}

.fold {
  padding: 0;
  overflow: hidden;
}

.fold summary {
  list-style: none;
  cursor: pointer;
  padding: 15px 18px;
  font-weight: 750;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

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

.fold summary::after {
  content: "+";
  margin-left: auto;
  color: var(--muted);
  font-weight: 700;
}

.fold[open] summary::after {
  content: "–";
}

.fold > .steps,
.fold > .note-list {
  padding: 0 18px 16px;
}

/* ---------------------------------------------------------- */
/* Beranda                                                    */
/* ---------------------------------------------------------- */

.hero {
  position: relative;
  padding: 28px 2px 4px;
  text-align: center;
}

.hero-moon {
  font-size: clamp(46px, 12vw, 70px);
  line-height: 1;
  margin-bottom: 12px;
  filter: drop-shadow(0 0 34px rgba(255, 192, 70, 0.4));
  animation: floatMoon 5.5s ease-in-out infinite;
}

@keyframes floatMoon {
  0%,
  100% {
    transform: translateY(0) rotate(-3deg);
  }
  50% {
    transform: translateY(-7px) rotate(3deg);
  }
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(58px, 17vw, 110px);
  font-weight: 400;
  letter-spacing: 0.015em;
  line-height: 0.86;
  margin: 10px 0 14px;
  text-shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
}

.hero h1 span {
  color: var(--amber);
  display: inline-block;
  position: relative;
}

.hero h1 span::after {
  content: "";
  position: absolute;
  left: 4%;
  right: 4%;
  bottom: 8%;
  height: 7px;
  background: rgba(255, 107, 157, 0.55);
  border-radius: 99px;
  transform: rotate(-1.5deg);
  z-index: -1;
}

.tagline {
  max-width: 46ch;
  margin: 0 auto;
  color: #c8bcdd;
  font-size: 14.5px;
  line-height: 1.6;
}

.tagline b {
  color: var(--ink);
}

.enter-panel {
  margin-top: 22px;
}

.avatar-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}

.avatar {
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  font-size: 23px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  transition: transform 0.12s, border-color 0.2s, background 0.2s;
}

.avatar:hover {
  background: rgba(255, 255, 255, 0.09);
}

.avatar.is-on {
  border-color: var(--amber);
  background: rgba(255, 192, 70, 0.16);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -10px rgba(255, 192, 70, 0.6);
}

.invite-banner {
  margin: 0 0 14px;
  padding: 11px 14px;
  border-radius: 12px;
  background: rgba(79, 224, 193, 0.12);
  border: 1px solid rgba(79, 224, 193, 0.3);
  color: #b8f6e7;
  font-size: 13.5px;
}

.invite-banner b {
  letter-spacing: 0.16em;
}

.or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
  color: var(--muted);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 700;
}

.or::before,
.or::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--line);
}

.join-row {
  display: flex;
  gap: 10px;
}

.join-row input {
  flex: 1;
  text-align: center;
  font-weight: 800;
  font-size: 22px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  padding-left: calc(14px + 0.32em);
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
}

.join-row .btn {
  flex: 0 0 auto;
  padding-inline: 22px;
}

.how {
  margin-top: 30px;
}

.how h2 {
  font-size: 21px;
  margin-bottom: 12px;
}

.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
  display: grid;
  gap: 9px;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding: 12px 14px 12px 46px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  color: #cfc5e0;
  font-size: 13.5px;
  line-height: 1.5;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 12px;
  top: 12px;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: rgba(255, 192, 70, 0.16);
  color: var(--amber);
  font-weight: 800;
  font-size: 12px;
}

.steps li b {
  color: var(--ink);
}

.steps.small {
  margin-top: 4px;
}

.role-samples {
  margin-top: 16px;
  display: grid;
  gap: 9px;
}

.role-sample {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}

.role-sample-icon {
  font-size: 26px;
  line-height: 1.1;
}

.role-sample b {
  font-size: 14px;
}

.role-sample p {
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.45;
  margin-top: 2px;
}

.role-sample.role-tuyul {
  border-color: rgba(255, 107, 157, 0.3);
  background: rgba(255, 107, 157, 0.06);
}

.role-sample.role-ibukos {
  border-color: rgba(255, 192, 70, 0.28);
  background: rgba(255, 192, 70, 0.05);
}

.role-sample.role-warga {
  border-color: rgba(79, 224, 193, 0.24);
  background: rgba(79, 224, 193, 0.045);
}

.foot {
  margin-top: 30px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: space-between;
  color: var(--muted);
  font-size: 11.5px;
}

/* ---------------------------------------------------------- */
/* Lobby                                                      */
/* ---------------------------------------------------------- */

.lobby-head {
  text-align: center;
  padding: 6px 0 2px;
}

.lobby-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(44px, 12vw, 70px);
  letter-spacing: 0.02em;
  line-height: 0.95;
  margin: 6px 0 8px;
}

.lobby-title span {
  color: var(--amber);
}

.code-card {
  margin-top: 18px;
  padding: 18px 16px;
  text-align: center;
  border-radius: var(--radius);
  border: 1px dashed rgba(255, 192, 70, 0.4);
  background: radial-gradient(120% 120% at 50% 0%, rgba(255, 192, 70, 0.11), transparent 60%),
    rgba(255, 255, 255, 0.02);
}

.code-big {
  display: block;
  margin: 4px auto 2px;
  border: 0;
  background: none;
  color: var(--amber);
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: clamp(52px, 15vw, 76px);
  font-weight: 800;
  letter-spacing: 0.16em;
  line-height: 1.05;
  text-shadow: 0 0 40px rgba(255, 192, 70, 0.35);
  padding-left: 0.16em;
}

.code-actions {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 4px;
}

.player-grid {
  display: grid;
  gap: 8px;
}

.lobby-player {
  display: flex;
  align-items: center;
  gap: 8px;
}

.lobby-player .player-chip {
  flex: 1;
}

.player-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 8px 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.045);
}

.player-chip.is-off {
  opacity: 0.5;
}

.player-chip.is-empty {
  border-style: dashed;
  color: var(--muted);
  background: transparent;
}

.pc-avatar {
  font-size: 22px;
  width: 30px;
  text-align: center;
}

.pc-name {
  font-weight: 700;
  font-size: 14.5px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.pc-name i {
  font-style: normal;
  font-size: 9px;
  letter-spacing: 0.08em;
  padding: 2px 5px;
  border-radius: 5px;
  background: rgba(155, 123, 255, 0.18);
  color: #c9b7ff;
}

.pc-crown {
  margin-left: auto;
  font-size: 14px;
}

.pc-off {
  margin-left: auto;
  font-size: 10px;
  color: var(--muted);
}

.mini-x {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 12px;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
}

.settings-grid select {
  min-height: 44px;
  font-size: 14px;
  padding-left: 10px;
}

.lobby-cta {
  margin-top: 18px;
  text-align: center;
}

.lobby-cta .hint {
  margin-top: 9px;
}

.waiting-box {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 17px;
  border-radius: 16px;
  border: 1px dashed var(--line-strong);
  color: var(--muted);
  font-weight: 650;
  font-size: 14px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 0 0 rgba(79, 224, 193, 0.5);
  animation: pulse 1.8s infinite;
  flex: 0 0 8px;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(79, 224, 193, 0.45);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(79, 224, 193, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(79, 224, 193, 0);
  }
}

/* ---------------------------------------------------------- */
/* Header permainan                                           */
/* ---------------------------------------------------------- */

.game {
  padding-top: 0;
}

.conn-banner {
  margin: 0 -16px;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 650;
  background: rgba(255, 92, 108, 0.16);
  color: #ffc3c9;
  border-bottom: 1px solid rgba(255, 92, 108, 0.25);
}

.conn-banner.connecting {
  background: rgba(255, 192, 70, 0.13);
  color: #ffe0a1;
  border-color: rgba(255, 192, 70, 0.25);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  margin: 0 -16px;
  padding: 10px 14px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  background: rgba(11, 9, 24, 0.86);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.tb-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.brandmark {
  font-size: 18px;
}

.tb-room {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  border-radius: 9px;
  padding: 5px 9px;
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--ink);
}

.tb-mid {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-self: center;
}

.phase-name {
  font-size: 11.5px;
  font-weight: 750;
  color: var(--muted);
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.timer {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 15px;
  font-weight: 800;
  min-width: 46px;
  text-align: center;
  padding: 3px 7px;
  border-radius: 8px;
  background: rgba(255, 192, 70, 0.14);
  color: var(--amber);
  font-variant-numeric: tabular-nums;
}

.timer.is-low {
  background: rgba(255, 92, 108, 0.18);
  color: #ff9aa5;
  animation: tickPulse 1s ease-in-out infinite;
}

.timer.is-off {
  opacity: 0.45;
  background: transparent;
}

@keyframes tickPulse {
  50% {
    transform: scale(1.06);
  }
}

.tb-right {
  justify-self: end;
}

.coin-chip {
  font-size: 12px;
  font-weight: 800;
  padding: 5px 9px;
  border-radius: 9px;
  background: rgba(255, 192, 70, 0.1);
  border: 1px solid rgba(255, 192, 70, 0.2);
  color: #ffdd9c;
  white-space: nowrap;
}

.phasebar {
  height: 3px;
  margin: 0 -16px 12px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.phasebar i {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--violet), var(--amber));
  transition: width 0.25s linear;
}

.role-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px;
  margin-bottom: 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  font-size: 12px;
  color: var(--muted);
}

.rs-role b {
  color: var(--ink);
}

.role-strip.role-tuyul {
  border-color: rgba(255, 107, 157, 0.32);
  background: rgba(255, 107, 157, 0.07);
}

.role-strip.role-ibukos {
  border-color: rgba(255, 192, 70, 0.3);
  background: rgba(255, 192, 70, 0.06);
}

.role-strip.role-warga {
  border-color: rgba(79, 224, 193, 0.25);
  background: rgba(79, 224, 193, 0.05);
}

.rs-mid {
  font-weight: 650;
}

.rs-right {
  color: #ffd894;
  font-weight: 700;
  white-space: nowrap;
}

/* ---------------------------------------------------------- */
/* Kartu peran                                                */
/* ---------------------------------------------------------- */

.role-card {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.02));
  box-shadow: var(--shadow);
}

.role-card::before {
  content: "";
  position: absolute;
  inset: -40% -20% auto auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: var(--role-glow, rgba(79, 224, 193, 0.3));
  filter: blur(44px);
  opacity: 0.7;
  pointer-events: none;
}

.role-card.role-warga {
  --role-glow: rgba(79, 224, 193, 0.32);
  border-color: rgba(79, 224, 193, 0.3);
}

.role-card.role-ibukos {
  --role-glow: rgba(255, 192, 70, 0.32);
  border-color: rgba(255, 192, 70, 0.34);
}

.role-card.role-tuyul {
  --role-glow: rgba(255, 107, 157, 0.34);
  border-color: rgba(255, 107, 157, 0.36);
}

.role-big-icon {
  font-size: 50px;
  line-height: 1;
  flex: 0 0 auto;
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.5));
}

.role-copy {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.role-copy h2 {
  font-size: 25px;
  margin: 2px 0 4px;
}

.role-tagline {
  color: #ded4ee;
  font-size: 12.5px;
  line-height: 1.45;
}

.role-desc {
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.45;
  margin-top: 4px;
}

.stamp {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  font-size: 8.5px;
  font-weight: 900;
  letter-spacing: 0.16em;
  color: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 5px;
  padding: 3px 6px;
  transform: rotate(6deg);
}

.teammates {
  margin-top: 8px;
  font-size: 11.5px;
  padding: 7px 9px;
  border-radius: 8px;
  background: rgba(255, 107, 157, 0.12);
  border: 1px solid rgba(255, 107, 157, 0.25);
  color: #ffd3e1;
}

.teammates span {
  color: #f0a9c0;
}

.teammates b {
  color: #fff;
}

/* ---------------------------------------------------------- */
/* Aksi malam                                                 */
/* ---------------------------------------------------------- */

.action-panel {
  padding-bottom: 14px;
}

.action-list {
  display: grid;
  gap: 9px;
}

.action-card {
  display: flex;
  align-items: center;
  gap: 13px;
  width: 100%;
  text-align: left;
  padding: 13px;
  border-radius: 15px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  transition: border-color 0.2s, background 0.2s, transform 0.12s;
}

.action-card:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.07);
}

.action-card:active:not(:disabled) {
  transform: scale(0.99);
}

.action-card.is-on {
  border-color: var(--amber);
  background: rgba(255, 192, 70, 0.1);
  box-shadow: 0 0 0 1px rgba(255, 192, 70, 0.25) inset;
}

.action-card:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.ac-icon {
  font-size: 26px;
  width: 34px;
  text-align: center;
  flex: 0 0 34px;
}

.ac-body {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.ac-body b {
  font-size: 14.5px;
}

.ac-body small {
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.4;
}

.ac-body em {
  font-style: normal;
  color: #ffb3bd;
  font-size: 10.5px;
  margin-top: 2px;
}

.ac-check {
  margin-left: auto;
  color: var(--amber);
  font-size: 13px;
  position: relative;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  display: grid;
  place-items: center;
  flex: 0 0 20px;
}

.action-card.is-on .ac-check {
  border-color: var(--amber);
  background: var(--amber);
  color: #241300;
}

.area-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-top: 12px;
}

.area-card {
  display: grid;
  gap: 2px;
  text-align: left;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.2s, background 0.2s;
}

.area-card:hover {
  background: rgba(255, 255, 255, 0.06);
}

.area-card.is-on {
  border-color: var(--mint);
  background: rgba(79, 224, 193, 0.1);
  box-shadow: 0 0 0 1px rgba(79, 224, 193, 0.28) inset;
}

.area-icon {
  font-size: 22px;
}

.area-card b {
  font-size: 13.5px;
}

.area-card small {
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.35;
}

.action-footer {
  margin-top: 13px;
  display: grid;
  gap: 4px;
}

.slot-hint {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  text-align: center;
}

.locked-action {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px;
  border-radius: 15px;
  border: 1px solid rgba(79, 224, 193, 0.3);
  background: rgba(79, 224, 193, 0.07);
}

.la-icon {
  font-size: 25px;
}

.locked-action > div {
  display: grid;
  gap: 1px;
}

.locked-action b {
  font-size: 14.5px;
}

.locked-action small {
  color: var(--muted);
  font-size: 11.5px;
}

.locked-action .btn {
  margin-left: auto;
}

.ghost-box {
  text-align: center;
  padding: 26px 18px;
}

.ghost-box h2 {
  margin-bottom: 8px;
}

.ghost-box p {
  color: var(--muted);
  font-size: 13.5px;
}

/* Catatan */

.notes {
  margin-top: 16px;
}

.note-list {
  margin: 0;
  list-style: none;
  display: grid;
  gap: 9px;
}

.note-list li {
  display: flex;
  gap: 9px;
  align-items: flex-start;
}

.note-round {
  flex: 0 0 auto;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--violet);
  background: rgba(155, 123, 255, 0.14);
  border-radius: 5px;
  padding: 3px 5px;
  margin-top: 1px;
}

.note-list p {
  font-size: 12.5px;
  color: #d4c9e6;
  line-height: 1.5;
}

/* ---------------------------------------------------------- */
/* Pagi                                                       */
/* ---------------------------------------------------------- */

.report-card {
  position: relative;
  overflow: hidden;
  padding: 22px 18px 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 192, 70, 0.32);
  background: linear-gradient(160deg, rgba(255, 192, 70, 0.14), rgba(255, 107, 157, 0.05) 60%),
    var(--card);
  box-shadow: var(--shadow);
}

.report-card h2 {
  margin: 10px 0 14px;
  font-size: 22px;
}

.report-lines {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.report-lines li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.report-lines li span {
  font-size: 17px;
  line-height: 1.2;
}

.report-lines p {
  font-size: 13.5px;
  line-height: 1.45;
  font-weight: 600;
}

.loot-bar {
  margin-top: 16px;
}

.loot-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  color: var(--muted);
  margin-bottom: 5px;
}

.loot-labels b {
  color: #ffdd9c;
}

.bar {
  height: 8px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.09);
  overflow: hidden;
}

.bar i {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--amber), var(--pink));
  transition: width 0.4s ease;
}

.bar.small {
  height: 6px;
}

.auto-note {
  margin-top: 16px;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

/* ---------------------------------------------------------- */
/* Rapat & chat                                               */
/* ---------------------------------------------------------- */

.morning-mini {
  margin-bottom: 12px;
  padding: 11px 13px;
  border-radius: 13px;
  border: 1px solid rgba(255, 192, 70, 0.22);
  background: rgba(255, 192, 70, 0.06);
}

.mm-label {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber);
}

.morning-mini ul {
  margin: 5px 0 0;
  padding-left: 16px;
  color: #ded2ec;
  font-size: 12px;
  line-height: 1.5;
}

.chat-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.16);
  overflow: hidden;
}

.chat-card .section-head {
  padding: 14px 16px 0;
  margin-bottom: 8px;
}

.chat-log {
  height: min(42vh, 330px);
  min-height: 190px;
  overflow-y: auto;
  padding: 4px 14px 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.18) transparent;
}

.chat-log::-webkit-scrollbar {
  width: 6px;
}

.chat-log::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
  border-radius: 9px;
}

.chat-empty {
  margin: auto;
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
  max-width: 30ch;
  line-height: 1.5;
}

.chat-row {
  display: flex;
  gap: 7px;
  align-items: flex-end;
  max-width: 88%;
}

.chat-row.own {
  margin-left: auto;
  flex-direction: row-reverse;
}

.chat-avatar {
  font-size: 17px;
  width: 24px;
  text-align: center;
  flex: 0 0 24px;
}

.bubble-wrap {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.chat-name {
  font-size: 10px;
  color: var(--muted);
  font-weight: 700;
  padding-left: 3px;
}

.bubble {
  padding: 8px 11px;
  border-radius: 13px 13px 13px 4px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 13px;
  line-height: 1.42;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.chat-row.own .bubble {
  background: linear-gradient(135deg, rgba(255, 192, 70, 0.92), rgba(255, 138, 61, 0.92));
  color: #241300;
  border-radius: 13px 13px 4px 13px;
  font-weight: 600;
}

.chat-form {
  display: flex;
  gap: 8px;
  padding: 9px;
  border-top: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.22);
}

.chat-form input {
  min-height: 44px;
  padding: 10px 13px;
  border-radius: 12px;
  font-size: 15px;
}

.btn-send {
  flex: 0 0 48px;
  min-height: 44px;
  padding: 0;
  font-size: 17px;
  border-radius: 12px;
}

.ready-row {
  margin-top: 12px;
  display: grid;
  gap: 10px;
}

.ready-count {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  font-size: 12px;
  color: var(--muted);
}

/* ---------------------------------------------------------- */
/* Voting                                                     */
/* ---------------------------------------------------------- */

.vote-panel p {
  margin-bottom: 12px;
}

.vote-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin: 4px 0 12px;
}

.vote-card {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 5px;
  padding: 14px 8px 12px;
  border-radius: 15px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  transition: border-color 0.2s, background 0.2s, transform 0.12s;
}

.vote-card:hover {
  background: rgba(255, 255, 255, 0.07);
}

.vote-card:active {
  transform: scale(0.985);
}

.vote-card.is-on {
  border-color: var(--pink);
  background: rgba(255, 107, 157, 0.13);
  box-shadow: 0 0 0 1px rgba(255, 107, 157, 0.3) inset;
}

.vote-avatar {
  font-size: 30px;
  line-height: 1.1;
}

.vote-name {
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.vote-mark {
  position: absolute;
  top: 7px;
  right: 8px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-weight: 900;
  background: var(--pink);
  color: #2b0714;
}

.skip-btn {
  color: var(--muted);
}

.skip-btn.is-on {
  border-color: var(--muted);
  color: var(--ink);
}

/* ---------------------------------------------------------- */
/* Hasil & akhir                                              */
/* ---------------------------------------------------------- */

.reveal-card {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 26px 18px 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.02));
  box-shadow: var(--shadow);
}

.reveal-card.role-tuyul {
  border-color: rgba(255, 107, 157, 0.45);
  background: radial-gradient(120% 100% at 50% 0%, rgba(255, 107, 157, 0.24), transparent 65%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
}

.reveal-card.role-warga {
  border-color: rgba(79, 224, 193, 0.4);
  background: radial-gradient(120% 100% at 50% 0%, rgba(79, 224, 193, 0.18), transparent 65%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
}

.reveal-card.role-ibukos {
  border-color: rgba(255, 192, 70, 0.4);
  background: radial-gradient(120% 100% at 50% 0%, rgba(255, 192, 70, 0.16), transparent 65%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
}

.reveal-card.tie {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.035);
}

.reveal-avatar {
  font-size: 58px;
  line-height: 1;
  margin: 10px 0 6px;
}

.reveal-card h2 {
  font-size: 30px;
}

.reveal-role {
  margin-top: 5px;
  color: #e7dcf5;
  font-size: 14px;
}

.reveal-role b {
  color: var(--ink);
}

.reveal-card.tie h2 {
  font-size: 27px;
  margin: 8px 0 4px;
}

.reveal-card.tie p:last-child {
  color: var(--muted);
  font-size: 13px;
}

.reveal-wrap .panel {
  margin-top: 13px;
}

.tally {
  display: grid;
  gap: 9px;
}

.tally-row {
  display: grid;
  grid-template-columns: minmax(90px, 1.1fr) 1.6fr 22px;
  align-items: center;
  gap: 9px;
}

.tally-name {
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tally-row b {
  font-size: 12px;
  text-align: right;
  color: var(--amber);
}

.winner-card {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 30px 18px 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
}

.winner-card.win-warga {
  background: radial-gradient(120% 110% at 50% 0%, rgba(79, 224, 193, 0.28), transparent 62%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.015));
  border-color: rgba(79, 224, 193, 0.4);
}

.winner-card.win-tuyul {
  background: radial-gradient(120% 110% at 50% 0%, rgba(255, 107, 157, 0.28), transparent 62%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.015));
  border-color: rgba(255, 107, 157, 0.4);
}

.winner-icon {
  font-size: 58px;
  line-height: 1;
  margin: 8px 0 4px;
}

.winner-card h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(46px, 12vw, 70px);
  letter-spacing: 0.02em;
  line-height: 0.95;
  margin: 4px 0 8px;
}

.winner-card p:last-child {
  color: #ded4ec;
  font-size: 13px;
  max-width: 36ch;
  margin: 0 auto;
  line-height: 1.5;
}

.reveal-grid {
  display: grid;
  gap: 8px;
}

.reveal-player {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
}

.reveal-player.is-you {
  border-color: rgba(255, 192, 70, 0.4);
  background: rgba(255, 192, 70, 0.07);
}

.reveal-player.role-tuyul {
  border-color: rgba(255, 107, 157, 0.32);
  background: rgba(255, 107, 157, 0.065);
}

.reveal-player.role-ibukos {
  border-color: rgba(255, 192, 70, 0.26);
}

.rp-avatar {
  font-size: 22px;
  width: 28px;
  text-align: center;
}

.rp-body {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.rp-body b {
  font-size: 13.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rp-body small {
  color: var(--muted);
  font-size: 10.5px;
}

.rp-coins {
  margin-left: auto;
  font-size: 11.5px;
  font-weight: 800;
  color: #ffdd9c;
  white-space: nowrap;
}

/* ---------------------------------------------------------- */
/* Toast                                                      */
/* ---------------------------------------------------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(22px + var(--safe-b));
  transform: translate(-50%, 18px);
  z-index: 100;
  max-width: min(92vw, 420px);
  padding: 11px 16px;
  border-radius: 12px;
  background: #241a3d;
  border: 1px solid var(--line-strong);
  box-shadow: 0 18px 50px -14px rgba(0, 0, 0, 0.85);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s, transform 0.22s;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ---------------------------------------------------------- */
/* Mode TV                                                    */
/* ---------------------------------------------------------- */

body.tv-mode {
  background:
    radial-gradient(1400px 800px at 50% -20%, rgba(155, 123, 255, 0.22), transparent 60%),
    radial-gradient(1000px 600px at 0% 100%, rgba(255, 107, 157, 0.1), transparent 60%),
    #090713;
}

.tv-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: clamp(16px, 2.6vw, 36px);
}

.tv-top {
  display: flex;
  align-items: center;
  gap: 18px;
  padding-bottom: clamp(12px, 2vw, 22px);
  border-bottom: 1px solid var(--line);
}

.tv-brand {
  font-family: var(--font-display);
  font-size: clamp(20px, 2.2vw, 32px);
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.tv-brand span {
  color: var(--amber);
}

.tv-center {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 auto;
  min-width: 0;
}

.tv-code,
.tv-phase {
  font-size: clamp(12px, 1.2vw, 17px);
  font-weight: 750;
  color: var(--muted);
  white-space: nowrap;
}

.tv-code {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  letter-spacing: 0.16em;
  color: var(--ink);
  padding: 6px 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
}

.tv-clock .timer {
  font-size: clamp(20px, 2.4vw, 34px);
  padding: 6px 13px;
  border-radius: 11px;
}

.tv-stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(18px, 3vw, 44px) 0;
}

.tv-shell h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(52px, 8vw, 128px);
  line-height: 0.9;
  letter-spacing: 0.02em;
  margin: 6px 0 10px;
}

.tv-sub {
  color: var(--muted);
  font-size: clamp(14px, 1.5vw, 22px);
  line-height: 1.5;
  max-width: 46ch;
}

.tv-hint {
  margin-top: clamp(12px, 2vw, 24px);
  color: var(--muted);
  font-size: clamp(12px, 1.2vw, 16px);
}

.tv-lobby {
  text-align: center;
}

.tv-big-code {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: clamp(76px, 15vw, 220px);
  font-weight: 800;
  letter-spacing: 0.14em;
  line-height: 1;
  color: var(--amber);
  text-shadow: 0 0 70px rgba(255, 192, 70, 0.35);
  padding-left: 0.14em;
  margin: 8px 0;
}

.tv-url {
  font-size: clamp(16px, 1.8vw, 26px);
  color: #ded4ec;
  font-weight: 650;
}

.tv-players {
  margin-top: clamp(18px, 3vw, 34px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: clamp(8px, 1vw, 14px);
}

.tv-player {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: clamp(8px, 1vw, 14px);
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  min-width: 0;
}

.tv-player.is-out {
  opacity: 0.42;
  text-decoration: line-through;
}

.tv-player.is-off {
  opacity: 0.5;
}

.tvp-avatar {
  font-size: clamp(20px, 2vw, 30px);
  flex: 0 0 auto;
}

.tvp-name {
  font-size: clamp(12px, 1.2vw, 17px);
  font-weight: 700;
  display: grid;
  gap: 0;
  min-width: 0;
  text-align: left;
}

.tvp-name i {
  font-style: normal;
  color: var(--muted);
  font-size: 0.72em;
  font-weight: 600;
}

.tvp-done {
  margin-left: auto;
  color: var(--mint);
  font-weight: 900;
}

.tvp-out {
  margin-left: auto;
  font-size: 0.65em;
  color: var(--pink);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.tv-night,
.tv-morning,
.tv-vote,
.tv-reveal,
.tv-end {
  text-align: center;
}

.tv-moon {
  font-size: clamp(60px, 9vw, 130px);
  line-height: 1;
  padding-bottom: 8px;
  filter: drop-shadow(0 0 60px rgba(255, 192, 70, 0.45));
  animation: floatMoon 6s ease-in-out infinite;
}

.tv-report {
  list-style: none;
  margin: clamp(14px, 2.4vw, 28px) auto 0;
  padding: 0;
  max-width: 980px;
  display: grid;
  gap: 10px;
}

.tv-report li {
  padding: clamp(10px, 1.4vw, 18px) clamp(14px, 2vw, 24px);
  border-radius: 16px;
  border: 1px solid rgba(255, 192, 70, 0.25);
  background: rgba(255, 192, 70, 0.08);
  font-size: clamp(16px, 2vw, 30px);
  font-weight: 650;
  text-align: left;
}

.tv-discuss {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: clamp(14px, 2vw, 28px);
  align-items: stretch;
  width: 100%;
}

.tv-chat {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.tv-chat-log {
  margin-top: 12px;
  display: grid;
  gap: 10px;
  max-height: 54vh;
  overflow-y: auto;
  align-content: start;
}

.tv-chat-row {
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  font-size: clamp(13px, 1.35vw, 20px);
  line-height: 1.4;
  text-align: left;
}

.tv-chat-row b {
  color: var(--amber);
  margin-right: 8px;
}

.tv-side {
  border-left: 1px solid var(--line);
  padding-left: clamp(12px, 2vw, 24px);
}

.tv-side-title {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
  text-align: left;
}

.tv-side .tv-players {
  margin-top: 0;
  grid-template-columns: 1fr;
}

.tv-expelled-avatar {
  font-size: clamp(64px, 9vw, 140px);
  line-height: 1;
  margin-top: 10px;
}

.tv-role-flip {
  font-size: clamp(18px, 2.2vw, 34px);
  color: var(--muted);
}

.tv-role-flip b {
  color: var(--pink);
}

.tv-end.win-warga .tv-players {
  margin-top: 26px;
}

.tv-end.win-tuyul h1 {
  color: var(--pink);
}

.tv-prompt {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 88vh;
  text-align: center;
}

.tv-prompt h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(46px, 8vw, 96px);
  margin: 8px 0;
}

.tv-prompt h1 span {
  color: var(--amber);
}

.tv-code-row {
  display: flex;
  gap: 10px;
  max-width: 430px;
  margin: 22px auto 8px;
}

.tv-code-row input {
  text-align: center;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
}

.tv-prompt .hint {
  max-width: 46ch;
  margin: 8px auto;
}

/* ---------------------------------------------------------- */
/* Desktop                                                    */
/* ---------------------------------------------------------- */

@media (min-width: 900px) {
  .home {
    max-width: 1040px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 410px;
    column-gap: 34px;
    align-items: start;
  }

  .home .hero {
    grid-column: 1;
    text-align: left;
    padding-top: 78px;
  }

  .home .hero-moon {
    position: absolute;
    top: 8px;
    right: 20px;
    font-size: 52px;
    opacity: 0.8;
  }

  .home .hero .tagline {
    margin: 0;
  }

  .home .enter-panel {
    grid-column: 2;
    margin-top: 42px;
  }

  .home .how,
  .home .foot {
    grid-column: 1 / -1;
  }

  .how {
    margin-top: 40px;
  }

  .role-samples {
    grid-template-columns: repeat(3, 1fr);
  }

  .role-sample {
    flex-direction: column;
    gap: 8px;
  }

  .game {
    max-width: 720px;
  }
}

@media (max-width: 420px) {
  .wrap {
    padding-left: 13px;
    padding-right: 13px;
  }

  .topbar,
  .conn-banner,
  .phasebar {
    margin-left: -13px;
    margin-right: -13px;
  }

  .avatar-grid {
    grid-template-columns: repeat(6, 1fr);
    gap: 6px;
  }

  .avatar {
    font-size: 20px;
    border-radius: 11px;
  }

  .role-card {
    gap: 12px;
    padding: 16px 14px;
  }

  .role-big-icon {
    font-size: 40px;
  }

  .role-copy h2 {
    font-size: 22px;
  }

  .settings-grid {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
  }

  .settings-grid select {
    font-size: 12.5px;
    padding-left: 8px;
    padding-right: 24px;
  }

  .foot {
    flex-direction: column;
  }

  .code-big {
    font-size: 52px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
