.arcade-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.arcade-tabs .games-button { display: inline-flex; align-items: center; gap: 8px; min-height: 46px; padding: 5px 12px 5px 6px; }
.arcade-game-art { display: block; flex: 0 0 34px; width: 34px; height: 34px; }
.arcade-tabs button[aria-pressed="true"] {
  border-color: var(--theme-accent, #c291f6);
  background: var(--theme-tint, #37204d);
}
.games-wrap #arcade-ttt[hidden], .tanks[hidden], .tanks [hidden] { display: none; }
.games-wrap:has(> .tanks:not([hidden])) { width: min(100%, 1280px); }
.tanks { display: grid; gap: 16px; min-width: 0; }
.tanks-heading {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: clamp(18px, 2.4vw, 30px); border: 1px solid #304665; border-radius: 20px; color: #f3f8ff;
  background: radial-gradient(ellipse at 100% 30%, #203957, transparent 64%), #12182b;
}
.tanks .tanks-heading .games-kicker { color: #8aebea; }
.tanks-heading h3 { margin: 4px 0; font-size: clamp(25px, 3vw, 38px); line-height: 1.1; }
.tanks-heading p:last-child { margin: 8px 0 0; color: #c4d3eb; font-size: 16px; }
.tanks-emblem { flex: 0 0 clamp(48px, 6vw, 72px); color: #8aebea; transform: rotate(22deg); }
.tanks-emblem svg { display: block; width: 100%; }
.tanks-entry { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.tanks-entry .games-card { padding: clamp(17px, 2.4vw, 30px); }
.tanks-entry .games-card h3 { font-size: clamp(19px, 2.2vw, 26px); }
.tanks-entry form { display: grid; grid-template-rows: auto 1fr auto auto auto; gap: 8px; min-width: 0; }
.tanks-entry .games-muted { margin-top: 0; font-size: 15px; }
.tanks-entry label { font-size: 14px; font-weight: 700; }
.tanks-entry select, .tanks-room select {
  width: 100%; min-width: 0; min-height: 44px; padding: 8px 12px; box-sizing: border-box;
  border: 1px solid var(--theme-border, #59496e); border-radius: 10px;
  background: var(--theme-surface, #21192f); color: var(--theme-text, #f8f3ff); font: inherit;
}
.tanks-entry .games-button { justify-self: start; margin-top: 4px; min-height: 46px; }
.tanks-entry select { min-height: 48px; }
.tanks button:focus-visible, .tanks input:focus-visible, .tanks select:focus-visible, .arcade-tabs button:focus-visible {
  outline: 2px solid var(--theme-accent, #c291f6); outline-offset: 2px;
}
.tanks-room { display: grid; gap: 10px; width: min(100%, 920px); justify-self: center; }
@media (min-width: 701px) {
  .tanks-room { width: min(100%, 920px, max(740px, calc((100dvh - 250px) * 1.2857))); }
}
.tanks-room-top, .tanks-round-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tanks-room-top > strong { margin-right: auto; }
.tanks-room-invites { padding: 10px; border: 1px solid var(--theme-border, #59496e); border-radius: 10px; }
#tanks-invite { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.tanks-invitations { display: grid; gap: 6px; padding: 0; margin: 8px 0 0; list-style: none; }
.tanks-invitations:empty { display: none; }
.tanks-invitations li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; }
.tanks-invitations li > span { flex: 1 1 110px; overflow-wrap: anywhere; }
.tanks-invitations .games-button { min-height: 36px; padding: 5px 8px; font-size: 12px; }
.tanks-room .tanks-team-choice { width: auto; min-height: 32px; padding: 2px 4px; font-size: 12px; }
.tanks-roster { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 0; }
.tanks-roster li {
  display: flex; align-items: center; gap: 6px; max-width: 100%; min-width: 0; padding: 6px 9px;
  background: var(--theme-surface, #21192f); border: 1px solid var(--theme-border, #59496e); border-radius: 9px; font-size: 12px;
}
.tanks-roster li[data-offline] { opacity: .63; }
.tanks-roster li > span:nth-child(2) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tanks-roster .tanks-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--tank-color); box-shadow: 0 0 0 1px #454f66; flex: none; }
.tanks-roster small { white-space: nowrap; color: var(--theme-muted, #bdb1cf); }
.tanks-round-bar { justify-content: space-between; min-height: 35px; }
.tanks-round-bar p { margin: 0; color: var(--theme-muted, #bdb1cf); font-size: 13px; }
.tanks-field { position: relative; overflow: hidden; border: 1px solid #405c7b; border-radius: 12px; background: #101829; isolation: isolate; }
.tanks-field canvas { display: block; width: 100%; height: auto; aspect-ratio: 9 / 7; }
.tanks-connection {
  position: absolute; z-index: 1; inset: 9px 9px auto; width: fit-content; max-width: calc(100% - 18px);
  margin: 0 auto; padding: 6px 10px; border: 1px solid #83714d; border-radius: 8px;
  color: #fff0c4; background: #282132; font-size: 12px; text-align: center; pointer-events: none;
}
.tanks-overlay {
  position: absolute; display: grid; place-content: center; justify-items: center; gap: 8px; inset: 0;
  padding: 15px; text-align: center; color: #effaff; background: #0b1121ba; pointer-events: none;
}
.tanks-overlay strong { font-size: clamp(20px, 4vw, 34px); line-height: 1.1; }
.tanks-overlay span { font-size: 13px; color: #c5d8ed; }
.tanks-keyboard { margin: 3px 0 0; text-align: center; color: var(--theme-muted, #bdb1cf); font-size: 12px; }
.tanks-keyboard kbd { display: inline-block; border: 1px solid var(--theme-border, #59496e); border-radius: 4px; padding: 1px 4px; }
.tanks-touch { display: none; align-items: end; justify-content: space-between; gap: 15px; padding-bottom: 3px; }
.tanks-pad { display: grid; grid-template-columns: repeat(3, 46px); grid-template-rows: repeat(2, 46px); gap: 4px; }
.tanks-pad button:first-child { grid-column: 2; }
.tanks-pad button:nth-child(2) { grid-column: 1; }
.tanks-touch button {
  touch-action: none; user-select: none; -webkit-user-select: none; color: #ecf9ff; background: #1f304a;
  border: 1px solid #435d7d; border-radius: 10px; font: 700 23px/1 system-ui, sans-serif; padding: 0;
}
.tanks-touch button[data-held] { background: #385b83; border-color: #a4f4f2; }
.tanks-touch .tanks-fire { width: 67px; height: 67px; border-radius: 50%; border-color: #ff84ac; color: #ffbfd3; background: #46243e; font-size: 33px; }
.tanks-touch .tanks-fire[data-held] { background: #75405e; }
.tanks-feedback:empty { display: none; }
@media (pointer: coarse), (max-width: 680px) {
  .tanks-touch { display: flex; }
  .tanks-keyboard { display: none; }
}
@media (max-width: 570px) {
  .tanks-heading { padding: 14px; }
  .tanks-emblem { flex-basis: 40px; }
  .tanks-entry { grid-template-columns: minmax(0, 1fr); }
  .tanks-room-top .games-button { min-height: 38px; padding-inline: 8px; }
}
