
/* ---------- Mode picker (3 cards) ---------- */
.mode-pick {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0 12px;
}
.mode-opt {
  position: relative;
  min-height: 150px;
  padding: 46px 13px 12px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 3px;
  text-align: left;
  color: #eef3ff;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 14px;
  background-color: #131822;
  background-size: cover;
  background-position: center;
  overflow: hidden;
  cursor: pointer;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}
.mode-opt::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border-top: 2px solid var(--accent, #53f2c8);
  opacity: .75;
  pointer-events: none;
}
.mode-opt:hover { transform: translateY(-2px); border-color: var(--accent, #53f2c8); }
.mode-opt.on {
  border-color: var(--accent, #53f2c8);
  box-shadow: 0 0 0 1px var(--accent, #53f2c8), 0 12px 28px rgba(0, 0, 0, .45);
}
.mode-opt.on::before {
  content: 'SELECTED';
  position: absolute;
  top: 10px;
  right: 11px;
  font-size: .58rem;
  letter-spacing: .16em;
  font-weight: 800;
  color: var(--accent, #53f2c8);
}
.mode-tag {
  position: absolute;
  top: 10px;
  left: 11px;
  font-size: .6rem;
  font-weight: 800;
  letter-spacing: .14em;
  padding: 3px 7px;
  border-radius: 5px;
  color: #071013;
  background: var(--accent, #53f2c8);
}
.mode-opt b { font-size: 1rem; line-height: 1.15; letter-spacing: .01em; text-shadow: 0 1px 8px rgba(0, 0, 0, .8); }
.mode-opt small { font-size: .72rem; line-height: 1.3; opacity: .92; text-shadow: 0 1px 6px rgba(0, 0, 0, .85); }
.mode-opt em { display: none; }

/* Readable centre callouts over bright maps */
#center-msg { text-shadow: 0 2px 12px #000, 0 0 34px rgba(0, 0, 0, .85); }
#sub-msg {
  color: #dce9f2;
  background: rgba(6, 10, 16, .58);
  padding: 4px 12px;
  border-radius: 999px;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, .08);
}

/* ---------- TDM score progress ---------- */
#tdm-bar {
  position: absolute;
  top: 58px;
  left: 50%;
  transform: translateX(-50%);
  width: min(360px, 52vw);
  height: 4px;
  border-radius: 3px;
  background: rgba(8, 12, 18, .72);
  overflow: hidden;
  pointer-events: none;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .08);
}
#tdm-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #53f2c8, #7ad8ff); transition: width .35s ease; }

/* Deathmatch modes have no abilities: hide the Q/E bar on desktop and phone. */
body.no-abilities #abilities { display: none !important; }

/* ---------- Respawn card ---------- */
#respawn {
  position: fixed;
  left: 50%;
  top: 58%;
  transform: translate(-50%, -50%);
  z-index: 6;
  width: min(360px, 84vw);
  padding: 20px 22px 18px;
  text-align: center;
  border: 1px solid rgba(255, 122, 200, .5);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(16, 20, 30, .92), rgba(10, 12, 18, .96));
  box-shadow: 0 24px 60px rgba(0, 0, 0, .55), inset 0 0 0 1px rgba(255, 255, 255, .04);
  backdrop-filter: blur(6px);
}
.resp-tag {
  font-size: .66rem;
  font-weight: 800;
  letter-spacing: .28em;
  color: #ff7ac8;
}
.resp-count {
  font-size: 3.1rem;
  font-weight: 900;
  line-height: 1;
  margin: 4px 0 8px;
  color: #fff;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 24px rgba(255, 122, 200, .55);
}
.resp-sub {
  font-size: .72rem;
  letter-spacing: .1em;
  color: rgba(238, 243, 255, .8);
}
.resp-sub b { color: #ffcf4a; }
.resp-tip {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  font-size: .7rem;
  line-height: 1.45;
  color: rgba(238, 243, 255, .55);
}

body[data-mode="tdm"] #slots button[data-slot="spike"],
body[data-mode="escalation"] #slots button[data-slot="spike"] { display: none; }
body[data-mode="tdm"] #squad-pick,
body[data-mode="tdm"] #bot-pick,
body[data-mode="escalation"] #squad-pick,
body[data-mode="escalation"] #bot-pick { display: none; }
body[data-mode="tdm"] #skill-pick::before,
body[data-mode="escalation"] #skill-pick::before {
  content: '5 v 5 is fixed for this mode · you + 4 squad mates vs 5 defenders';
  display: block;
  width: 100%;
  font-size: .68rem;
  letter-spacing: .1em;
  color: #53f2c8;
  margin-bottom: 4px;
}

@media (max-width: 760px) {
  .mode-pick { grid-template-columns: 1fr; gap: 8px; margin: 12px 0 8px; }
  .mode-opt { min-height: 104px; padding: 10px 12px; }
  .mode-opt b { font-size: 1rem; }
  .mode-opt em { display: none; }
  #respawn { top: 52%; padding: 14px 16px; }
  .resp-count { font-size: 2.4rem; }
  .resp-tip { display: none; }
}
@media (max-height: 520px) and (orientation: landscape) {
  .mode-pick { margin: 8px 0 6px; }
  .mode-opt { min-height: 82px; }
  .mode-opt em, .mode-opt small { display: none; }
  #respawn { top: 50%; width: min(300px, 60vw); padding: 10px 14px; }
  .resp-count { font-size: 2rem; margin: 2px 0 4px; }
  .resp-tip { display: none; }
}
