.lobby .tagline { margin-top: .5rem; max-width: 42ch; color: var(--ink); text-wrap: pretty }
.lobby-layout { display: grid; grid-template-columns: minmax(0,1fr) minmax(15rem,20rem); align-items: start; gap: clamp(1.25rem,3vw,3rem); margin-top: 1.75rem }
.room-feed { min-width: 0 }
.room-heading,.room-filters,.room-foot,.room-tabs { display: flex; align-items: center }
.room-heading,.room-filters,.room-foot { justify-content: space-between; gap: .7rem 1rem }
.room-heading { padding-bottom: .75rem; border-bottom: 1px solid var(--edge) }
.room-heading button { color: var(--muted); font-size: 1rem }
.room-filters { flex-wrap: wrap; padding-block: .9rem }
.room-tabs { border: 1px solid var(--edge) }
.room-tabs button { border: 0; min-height: 2.45rem; padding: .35rem .85rem; color: var(--muted); background: var(--paper) }
.room-tabs button + button { border-left: 1px solid var(--rule) }
.room-tabs [aria-pressed=true] { color: var(--accent-ink); background: var(--tint); box-shadow: inset 0 -2px var(--accent) }
.room-filters select { min-height: 2.45rem; max-width: 100%; font-size: 1rem }
.room-table { border: 1px solid var(--rule); background: var(--paper) }
.room-table table { width: 100%; border-collapse: collapse; text-align: left; font-variant-numeric: tabular-nums }
.room-table th,.room-table td { padding: .75rem .9rem; border-bottom: 1px solid var(--rule); line-height: 1.4 }
.room-table thead { background: var(--soft); color: var(--muted); font-size: .94rem }
.room-table thead th { font-weight: 500 }
.room-table tbody th { font-size: 1.05rem; font-weight: 600 }
.room-table tbody tr:last-child > * { border-bottom: 0 }
.room-table tbody tr:focus-within,.room-table tbody tr:hover { background: var(--base) }
.room-table .in-battle { color: var(--accent-ink) }
.room-table .waiting { color: #b6d3b1 }
.room-table button { font: 600 .96rem/1.3 Consolas,monospace; letter-spacing: .04em; color: var(--accent-ink); min-height: 2.3rem; user-select: all }
.room-empty { padding: 2.6rem 1rem; text-align: center; color: var(--muted) }
.room-foot { align-items: baseline; flex-wrap: wrap; margin-top: .6rem; min-height: 1.5rem; color: var(--muted); font-size: .94rem; font-variant-numeric: tabular-nums }
[data-room-feedback] { color: var(--accent-ink); user-select: text }
.lobby-aside { background: var(--paper); border: 1px solid var(--rule); border-top: 2px solid var(--edge); padding: 1rem 1.2rem }
.join-steps { padding-left: 1.4rem; margin: .8rem 0 1.1rem }
.join-steps li { padding: .2rem 0 .2rem .2rem; color: var(--ink) }
.join-steps li::marker { color: var(--accent); font-variant-numeric: tabular-nums }
.get-game { display: inline-flex; min-height: 2.5rem; align-items: center; color: var(--accent-ink); padding: .35rem .9rem; background: var(--tint); border: 1px solid var(--edge) }
.lobby-links { display: flex; flex-wrap: wrap; gap: .35rem 1rem; margin-top: 1.15rem; border-top: 1px solid var(--rule); padding-top: .85rem; color: var(--muted); font-size: .95rem }
.lobby-links a:hover,.get-game:hover { text-decoration: underline; text-underline-offset: .22em }
@media(max-width:880px) { .lobby-layout { grid-template-columns: 1fr } .lobby-aside { max-width: 42rem } }
@media(max-width:600px) {
  .lobby-layout { margin-top: 1.2rem }
  .room-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%) }
  .room-table table,.room-table tbody { display: block }
  .room-table tbody tr { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: .3rem .8rem; padding: .8rem .9rem; border-bottom: 1px solid var(--rule) }
  .room-table tbody tr:last-child { border: 0 }
  .room-table tbody th,.room-table tbody td { padding: 0; border: 0; align-self: center }
  .room-table tbody th { grid-column: 1; grid-row: 1 }
  .room-table td:nth-child(2) { grid-column: 1; grid-row: 2; font-size: .95rem; color: var(--muted) }
  .room-table td:nth-child(3) { grid-column: 1; grid-row: 3; color: var(--muted); font-size: .94rem }
  .room-table td:nth-child(3)::before { content: attr(data-label) " "; }
  .room-table td:nth-child(4) { grid-column: 2; grid-row: 1; text-align: right }
  .room-table td:last-child { grid-column: 2; grid-row: 2/4; text-align: right }
  .room-tabs button { padding-inline: .62rem }
}
