/*! VOCAB 5000® · © 2020–2026 E-Learning English Limited, registered in England and Wales no. 12031486. VOCAB 5000 is a registered trade mark of E-Learning English Limited, UK trade mark no. UK00004191491. All rights reserved. Licensed for use by the named institution only — not to be copied, adapted, re-uploaded or used for teaching elsewhere without written permission. Requests: info@e-learningenglish.com */
/* The Vocab Challenge quiz at the top of the page. Colours, shapes and type
   follow Peter's design; the layout reflows for tablets and phones. */
.wm {
  --wm-accent: #F5B82E;
  --wm-cond: "Barlow Condensed", "Arial Narrow", system-ui, sans-serif;
  margin: 24px 0 8px;
  border-radius: 18px;
  background: #0B1240;
  color: #fff;
  font-family: "Barlow", system-ui, sans-serif;
  position: relative;
  overflow: hidden;
  scroll-margin-top: 110px;
}
.wm *, .wm *::before, .wm *::after { box-sizing: border-box; }
.wm p { margin: 0; }
.wm button { font-family: inherit; }
.wm button:disabled { cursor: default; }
.wm button:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.wm-stage { min-height: 560px; display: flex; flex-direction: column; }

@keyframes dcRiseA{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:none}}
@keyframes dcRiseB{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:none}}
@keyframes dcPopA{0%{opacity:0;transform:scale(0.6)}70%{transform:scale(1.08)}100%{opacity:1;transform:scale(1)}}
@keyframes dcPopB{0%{opacity:0;transform:scale(0.6)}70%{transform:scale(1.08)}100%{opacity:1;transform:scale(1)}}
@keyframes dcPulse{0%,100%{filter:brightness(1)}50%{filter:brightness(1.35)}}
@keyframes dcFlash{0%,100%{filter:brightness(1)}50%{filter:brightness(1.9)}}
@keyframes dcShake{0%,100%{transform:translateX(0)}20%{transform:translateX(-12px)}40%{transform:translateX(10px)}60%{transform:translateX(-7px)}80%{transform:translateX(4px)}}
@keyframes dcGrow{from{transform:scaleY(0)}to{transform:scaleY(1)}}
@keyframes dcFade{from{opacity:0}to{opacity:1}}
@keyframes dcFall{from{transform:translateY(0) rotate(0deg)}to{transform:translateY(820px) rotate(720deg)}}
@keyframes dcGlow{0%,100%{box-shadow:0 0 0 0 rgba(245,184,46,0)}50%{box-shadow:0 0 36px 6px rgba(245,184,46,0.45)}}

/* ---- start ---- */
.wm-start, .wm-end {
  flex: 1; padding: 56px 32px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 24px; text-align: center; position: relative;
}
.wm-badge {
  width: 132px; height: 132px; border-radius: 50%; border: 3px solid var(--wm-accent);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--wm-cond); font-weight: 700; font-size: 44px; color: var(--wm-accent);
  animation: dcGlow 2.4s ease-in-out infinite;
}
.wm-titles { display: flex; flex-direction: column; gap: 8px; }
.wm-kicker {
  font-family: var(--wm-cond); font-weight: 600; font-size: 22px;
  letter-spacing: 0.24em; text-transform: uppercase; color: #AEB8EC;
}
.wm .wm-h1 {
  margin: 0; font-family: var(--wm-cond); font-weight: 700; font-size: 96px;
  line-height: 0.95; letter-spacing: 0.01em; color: #fff;
}
.wm-intro { max-width: 640px; font-size: 20px; line-height: 1.5; color: #D5DBF7; }
.wm-big {
  min-height: 60px; padding: 0 52px; border: none; border-radius: 30px;
  background: var(--wm-accent); color: #141414;
  font-family: var(--wm-cond) !important; font-weight: 700; font-size: 26px;
  letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
}
.wm-big:hover { filter: brightness(1.08); }
.wm-start .wm-big { margin-top: 8px; }
.wm-skip {
  background: none; border: none; color: #AEB8EC; font-size: 18px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; text-decoration: underline; text-underline-offset: 3px;
  padding: 8px 12px;
}
.wm-skip svg { width: 18px; height: 18px; }
.wm-skip:hover { color: #fff; }

/* ---- play ---- */
.wm-play { flex: 1; padding: 28px; display: flex; gap: 28px; }
.wm-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.wm-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.wm-lifelines, .wm-tools { display: flex; gap: 12px; flex-wrap: wrap; }
.wm-pill {
  min-width: 104px; height: 56px; padding: 0 18px; border-radius: 28px;
  border: 2px solid #8C9BD9; background: #16206B; color: #fff;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--wm-cond) !important; font-weight: 600; font-size: 20px; cursor: pointer;
  transition: opacity 0.4s;
}
.wm-life[data-life="fifty"] { font-weight: 700; font-size: 24px; }
.wm-life.used { opacity: 0.35; text-decoration: line-through; }
.wm-life:disabled:not(.used) { opacity: 1; }
.wm-walk { background: transparent; color: #D5DBF7; padding: 0 22px; }
.wm-walk:disabled { opacity: 0.4; }
.wm-round {
  width: 56px; height: 56px; border-radius: 28px; border: 2px solid #8C9BD9;
  background: transparent; color: #D5DBF7; display: flex; align-items: center; justify-content: center; cursor: pointer;
}

.wm-panel {
  height: 190px; border-radius: 16px; background: #111A55; border: 1px solid #2A3685;
  display: flex; align-items: center; justify-content: center; padding: 20px 28px;
}
.wm-label {
  font-family: var(--wm-cond); font-weight: 600; font-size: 16px; letter-spacing: 0.16em;
  text-transform: uppercase; color: #AEB8EC;
}
.wm-idle { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; }
.wm-idle .wm-label { font-size: 18px; }
.wm-prize { font-family: var(--wm-cond); font-weight: 700; font-size: 64px; line-height: 1; color: var(--wm-accent); }
.wm-status { font-size: 17px; color: #D5DBF7; }
.wm-poll { display: flex; flex-direction: column; align-items: center; gap: 8px; animation: dcFade 0.4s ease both; }
.wm-bars { display: flex; align-items: flex-end; gap: 28px; height: 130px; }
.wm-bar { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; height: 130px; width: 52px; }
.wm-pct { font-size: 15px; font-weight: 600; animation: dcFade 0.3s ease 1.4s both; }
.wm-bar-fill { width: 40px; border-radius: 4px 4px 0 0; background: var(--wm-accent); transform-origin: bottom; animation: dcGrow 1.4s cubic-bezier(.2,.8,.2,1) both; }
.wm-bar-letter { font-family: var(--wm-cond); font-weight: 700; font-size: 18px; color: #D5DBF7; }
.wm-friend { display: flex; align-items: center; gap: 22px; max-width: 680px; animation: dcFade 0.5s ease both; }
.wm-friend-icon {
  flex: none; width: 72px; height: 72px; border-radius: 50%; background: #16206B;
  border: 2px solid var(--wm-accent); display: flex; align-items: center; justify-content: center;
  color: var(--wm-accent); animation: dcGlow 1.6s ease-in-out 2;
}
.wm-friend > div:last-child { display: flex; flex-direction: column; gap: 6px; }
.wm-friend-text { font-size: 22px; line-height: 1.4; font-style: italic; }

.wm-q-edge, .wm-q { clip-path: polygon(3% 0, 97% 0, 100% 50%, 97% 100%, 3% 100%, 0 50%); }
.wm-q-edge { background: #8C9BD9; padding: 2px; }
.wm-q {
  min-height: 116px; padding: 18px 64px; background: #16206B;
  display: flex; align-items: center; justify-content: center; text-align: center;
}
.wm-q p { font-size: 28px; font-weight: 500; line-height: 1.3; }

.wm-answers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 24px; }
.wm-a-edge, .wm-a { clip-path: polygon(5% 0, 95% 0, 100% 50%, 95% 100%, 5% 100%, 0 50%); }
.wm-a-edge { --bg: #16206B; --fg: #fff; --lt: var(--wm-accent); background: #8C9BD9; padding: 2px; transition: opacity 0.5s ease; }
.wm-a {
  width: 100%; min-height: 60px; border: none; padding: 8px 40px;
  background: var(--bg); color: var(--fg);
  display: flex; align-items: center; gap: 14px; font-size: 22px; font-weight: 500; text-align: left;
  line-height: 1.2; cursor: pointer; transition: background 0.2s ease, color 0.2s ease;
}
.wm-a:focus-visible { outline: none; background: #24359E; }
.wm-letter { font-family: var(--wm-cond); font-weight: 700; font-size: 24px; color: var(--lt); }
.wm-a-edge.lit { background: var(--wm-accent); --bg: #24359E; }
.wm-a-edge.sel { background: #FFD9B0; --bg: #F28C28; --fg: #141414; --lt: #141414; }
.wm-a-edge.right { background: #9BE3B1; --bg: #1F7A3A; --fg: #fff; --lt: #fff; }
.wm-a-edge.wrong { background: #F2A49F; --bg: #B3261E; --fg: #fff; --lt: #fff; }
.wm-a-edge.gone { opacity: 0.18; }
.wm-a-edge.gone .wm-a, .wm-a:disabled { cursor: default; }

.wm-actions { display: flex; justify-content: center; gap: 16px; min-height: 56px; }
.wm-final {
  height: 56px; padding: 0 44px; border: none; border-radius: 28px; background: #F28C28; color: #141414;
  font-family: var(--wm-cond) !important; font-weight: 700; font-size: 24px; letter-spacing: 0.05em;
  text-transform: uppercase; cursor: pointer; animation: dcFade 0.25s ease both;
}
.wm-locking {
  align-self: center; font-family: var(--wm-cond); font-weight: 600; font-size: 24px; letter-spacing: 0.08em;
  text-transform: uppercase; color: #F28C28; animation: dcPulse 0.7s ease-in-out infinite;
}
.wm-next { min-height: 56px; padding: 0 44px; font-size: 24px; letter-spacing: 0.05em; animation: dcFade 0.3s ease 0.8s both; }
.wm-hint { align-self: center; font-size: 17px; color: #AEB8EC; }

.wm-ladder {
  list-style: none; margin: 0; flex: none; width: 250px; border-radius: 16px; background: #111A55;
  border: 1px solid #2A3685; padding: 16px 12px; display: flex; flex-direction: column; gap: 3px;
}
.wm-rung {
  height: 37px; padding: 0 16px; border-radius: 20px; color: #C7CEF2;
  display: flex; align-items: center; gap: 14px; font-family: var(--wm-cond); font-size: 22px; font-weight: 500;
  transition: background 0.4s ease, color 0.4s ease;
}
.wm-rung.safe { color: #fff; font-weight: 700; }
.wm-rung.past { color: #7F8AC4; }
.wm-rung.now { background: #F28C28; color: #141414; font-weight: 700; }
.wm-rung.won { background: #1F7A3A; color: #fff; font-weight: 700; animation: dcFlash 0.3s steps(2) 5; }
.wm-rung.lost { background: #B3261E; color: #fff; font-weight: 700; }
.wm-num { width: 26px; text-align: right; opacity: 0.8; }

/* ---- end ---- */
.wm-confetti { position: absolute; top: -24px; border-radius: 2px; pointer-events: none; }
.wm-end-kicker {
  font-family: var(--wm-cond); font-weight: 600; font-size: 24px; letter-spacing: 0.22em;
  text-transform: uppercase; color: #AEB8EC; animation: dcFade 0.6s ease both;
}
.wm-end-amount {
  font-family: var(--wm-cond); font-weight: 700; font-size: 132px; line-height: 1; color: var(--wm-accent);
  animation: dcPopA 0.9s cubic-bezier(.2,.8,.2,1) 0.3s both;
}
.wm-end-msg { max-width: 680px; font-size: 22px; line-height: 1.5; color: #D5DBF7; animation: dcFade 0.6s ease 0.9s both; }
.wm-end-btns {
  display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; margin-top: 12px;
  position: relative; animation: dcFade 0.6s ease 1.2s both;
}
.wm-again { background: transparent; color: var(--wm-accent); border: 2px solid var(--wm-accent); }
.wm-big svg { width: 24px; height: 24px; }

/* ---- smaller screens ---- */
@media (max-width: 980px) {
  .wm-play { flex-direction: column; padding: 20px; gap: 20px; }
  /* The ladder becomes a single row of the last few rungs, under the game. */
  .wm-ladder { width: auto; flex-direction: row; overflow-x: auto; padding: 10px; gap: 6px; }
  .wm-rung { order: var(--i); flex: none; height: 36px; padding: 0 12px; gap: 6px; font-size: 18px; }
  .wm-num { width: auto; }
}
@media (max-width: 700px) {
  .wm { margin-top: 16px; border-radius: 14px; }
  .wm-stage { min-height: 0; }
  .wm-start, .wm-end { padding: 36px 18px; gap: 18px; }
  .wm-badge { width: 96px; height: 96px; font-size: 32px; }
  .wm-kicker { font-size: 16px; }
  .wm .wm-h1 { font-size: 56px; }
  .wm-intro { font-size: 18px; }
  .wm-big { font-size: 22px; padding: 0 32px; min-height: 56px; }
  .wm-play { padding: 14px; gap: 14px; }
  .wm-main { gap: 14px; }
  .wm-top { gap: 8px; }
  .wm-lifelines, .wm-tools { gap: 8px; }
  .wm-pill { min-width: 0; height: 48px; padding: 0 14px; font-size: 18px; }
  .wm-life[data-life="fifty"] { font-size: 20px; }
  .wm-round { width: 48px; height: 48px; }
  .wm-panel { height: 150px; padding: 12px; }
  .wm-prize { font-size: 48px; }
  .wm-status { font-size: 16px; }
  .wm-bars { gap: 16px; height: 100px; }
  .wm-bar { height: 100px; width: 40px; }
  .wm-bar-fill { max-height: 70px; width: 30px; }
  .wm-friend { gap: 12px; }
  .wm-friend-icon { width: 52px; height: 52px; }
  .wm-friend-icon svg { width: 24px; height: 24px; }
  .wm-friend-text { font-size: 18px; }
  .wm-q-edge, .wm-q { clip-path: polygon(4% 0, 96% 0, 100% 50%, 96% 100%, 4% 100%, 0 50%); }
  .wm-q { min-height: 90px; padding: 14px 30px; }
  .wm-q p { font-size: 21px; }
  .wm-answers { grid-template-columns: 1fr; gap: 10px; }
  .wm-a { font-size: 19px; padding: 8px 30px; min-height: 54px; }
  .wm-a-edge, .wm-a { clip-path: polygon(4% 0, 96% 0, 100% 50%, 96% 100%, 4% 100%, 0 50%); }
  .wm-letter { font-size: 21px; }
  .wm-final, .wm-next { font-size: 21px; padding: 0 30px; }
  .wm-end-amount { font-size: 80px; }
  .wm-end-msg { font-size: 18px; }
}
@media (max-width: 420px) {
  .wm-walk span { font-size: 17px; }
  .wm-tools { width: 100%; }
  .wm-walk { flex: 1; }
}
#after-quiz { scroll-margin-top: 120px; }
@media (max-width: 700px) {
  .wm-end-btns .wm-big { letter-spacing: 0.03em; }
}

/* v42: logo watermark and winner's disclaimer. */
.wm-watermark {
  /* v43: small, semi-transparent logo in the bottom-left corner on every screen. */
  position: absolute; left: 16px; bottom: 14px; width: 40px; height: 40px; object-fit: contain;
  opacity: 0.7; pointer-events: none; user-select: none; z-index: 2;
  filter: drop-shadow(0 0 1.5px rgba(255, 255, 255, 0.7)); /* so the navy cap shows on the navy game */
}
@media (max-width: 980px) {
  .wm-play { padding-bottom: 64px; }
}
@media (max-width: 700px) {
  .wm-watermark { width: 32px; height: 32px; left: 12px; bottom: 10px; }
  .wm-play { padding-bottom: 50px; }
}
.wm-stage { position: relative; z-index: 1; }
.wm-disclaimer {
  max-width: 620px; margin-top: 8px; font-size: 14px; line-height: 1.5; color: #8C9BD9;
  position: relative; animation: dcFade 0.6s ease 1.4s both;
}

/* v44: full-screen gold fireworks and confetti when a learner reaches the top. */
.vc-celebrate {
  position: fixed; inset: 0; z-index: 200; cursor: pointer;
  background: radial-gradient(ellipse at center, rgba(14, 51, 82, 0.72), rgba(4, 16, 30, 0.9));
  animation: dcFade 0.4s ease both;
}
.vc-celebrate canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.vc-celebrate.vc-out { opacity: 0; transition: opacity 0.6s ease; }
.vc-banner {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); text-align: center;
  font-family: "Lexend", system-ui, sans-serif; pointer-events: none; width: 90%;
}
.vc-banner p { margin: 0; }
.vc-kicker { color: #fff; font-size: clamp(22px, 4vw, 40px); font-weight: 700; animation: dcFade 0.6s ease 0.2s both; }
.vc-score {
  font-size: clamp(54px, 11vw, 130px); font-weight: 700; line-height: 1.1;
  background: linear-gradient(180deg, #FFF4C2 0%, #FFD54A 45%, #E6A817 70%, #FFE58A 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 18px rgba(255, 213, 74, 0.55));
  animation: dcPopA 1s cubic-bezier(.2,.8,.2,1) 0.4s both, vcShine 2.4s ease-in-out 1.4s infinite;
}
.vc-tap { color: #b5d3ec; font-size: 16px; margin-top: 10px !important; animation: dcFade 0.6s ease 2.5s both; }
@keyframes vcShine { 0%,100% { filter: drop-shadow(0 0 14px rgba(255,213,74,0.45)); } 50% { filter: drop-shadow(0 0 30px rgba(255,213,74,0.9)); } }
.wm-end-amount.gold {
  background: linear-gradient(180deg, #FFF4C2 0%, #FFD54A 45%, #E6A817 70%, #FFE58A 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* v47: keep the helpers, sound and stop buttons on one row, as in the original. */
@media (min-width: 981px) {
  .wm-top { flex-wrap: nowrap; gap: 10px; }
  .wm-lifelines, .wm-tools { flex-wrap: nowrap; gap: 10px; }
  .wm-top .wm-pill { min-width: 0; padding: 0 14px; font-size: 19px; white-space: nowrap; }
  .wm-life[data-life="fifty"] { font-size: 19px; }
  .wm-walk { padding: 0 16px; }
}
@media (min-width: 981px) and (max-width: 1120px) {
  .wm-top, .wm-lifelines, .wm-tools { gap: 6px; }
  .wm-top .wm-pill { padding: 0 10px; font-size: 17px; gap: 6px; }
  .wm-life[data-life="fifty"] { font-size: 17px; }
  .wm-top .wm-pill svg { width: 18px; height: 18px; }
  .wm-round { width: 48px; }
}

/* "points" after each ladder amount (Peter) */
.wm-unit { font-size: 0.75em; font-weight: 500; opacity: 0.85; }

/* v20 (Peter): on short screens (an IOMAD frame, a laptop) the game is made
   more compact so the whole question, answers and ladder fit on the screen. */
@media (min-width: 981px) and (max-height: 860px) {
  .wm-stage { min-height: 0; }
  .wm-play { padding: 18px 22px; gap: 20px; }
  .wm-main { gap: 12px; }
  .wm-top .wm-pill, .wm-round { height: 46px; }
  .wm-round { width: 46px; }
  .wm-panel { height: 120px; padding: 12px 20px; }
  .wm-prize { font-size: 46px; }
  .wm-bars, .wm-bar { height: 80px; }
  .wm-friend-text { font-size: 19px; }
  .wm-q { min-height: 80px; padding: 12px 56px; }
  .wm-q p { font-size: 24px; }
  .wm-answers { gap: 10px 20px; }
  .wm-a { min-height: 50px; font-size: 20px; }
  .wm-next { min-height: 48px; }
  .wm-ladder { padding: 10px; gap: 2px; width: 230px; }
  .wm-rung { height: 28px; font-size: 19px; }
}

/* v23: "Your best" on the start screen. */
.wm-best { font-size: 19px; font-weight: 600; color: var(--wm-accent); }

/* v24: Continue button on the start screen. */
.wm-continue { background: var(--wm-accent); color: #141414; }

/* Unit 59 v9 (Peter): when the answer next to it takes two lines, the button
   fills the whole box (no light strip at the bottom). */
.wm-a-edge { display: flex; }
.wm-a-edge > .wm-a { flex: 1 1 auto; min-height: 100%; }
