/* Bandera y Mundo: its own look on top of the shared Pop menu and HUD. */
:root {
  --bym-navy: #14245e;
  --bym-ink: #1a2350;
  --bym-blue: #2a6ee3;
  --bym-green: #2f9e3a;
}
body {
  background:
    radial-gradient(1px 1px at 12% 18%, #fff 50%, transparent 51%),
    radial-gradient(1.4px 1.4px at 78% 12%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 40% 70%, #fff 50%, transparent 51%),
    radial-gradient(1.2px 1.2px at 88% 64%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 22% 88%, #fff 50%, transparent 51%),
    radial-gradient(1.3px 1.3px at 60% 36%, #fff 50%, transparent 51%),
    linear-gradient(160deg, var(--c1), var(--c2));
}

/* ---------- Menu ---------- */
.pop-logo {
  width: 150px;
  height: 128px;
  font-size: 0;
}
.pop-logo svg.bym-logo {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 8px 10px rgba(5, 20, 70, 0.4));
  animation: pop-bob 2.4s ease-in-out infinite;
}
.pop-reto-row .pop-btn.bym-passbtn {
  padding-inline: 8px;
  font-size: 19px;
}
.bym-rec {
  display: block;
  font-size: 11px;
  font-weight: 800;
  color: #b07800;
  letter-spacing: 0;
}

/* ---------- Play screen ---------- */
.pop-play {
  background:
    url("fondo.svg") center bottom / 100% auto no-repeat,
    radial-gradient(90% 40% at 15% 8%, rgba(120, 190, 255, 0.35), transparent 70%),
    radial-gradient(80% 35% at 95% 30%, rgba(120, 190, 255, 0.22), transparent 70%),
    linear-gradient(180deg, #1846bd 0%, #2563d8 38%, #2a6ee3 70%, #1f5bd2 100%);
}
.pop-hud {
  gap: 7px;
  padding: 8px 10px 4px;
  padding-top: calc(8px + env(safe-area-inset-top, 0px));
  min-height: 62px;
}
.pop-icon {
  width: 46px;
  height: 46px;
  color: var(--bym-navy);
  background: linear-gradient(180deg, #ffffff 0%, #eef3ff 60%, #d9e4fb 100%);
  box-shadow:
    inset 0 2px 0 #fff,
    0 4px 0 #0f348f,
    0 7px 14px rgba(5, 20, 70, 0.35);
}
.pop-icon:active {
  transform: translateY(3px);
  box-shadow:
    inset 0 2px 0 #fff,
    0 1px 0 #0f348f;
}
.pop-icon svg {
  width: 24px;
  height: 24px;
}
.pop-hud .pop-icon:last-child {
  color: #fff;
  background: radial-gradient(circle at 50% 30%, #6fb2ff 0%, #2d7cf0 55%, #1a56d0 100%);
  box-shadow:
    inset 0 0 0 3px #fff,
    inset 0 -4px 0 rgba(0, 30, 120, 0.25),
    0 4px 0 #0f348f,
    0 7px 14px rgba(5, 20, 70, 0.35);
}
.pop-lvl {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  flex: 0 1 auto;
  font-size: 22px;
  text-shadow: 0 2px 0 rgba(5, 20, 70, 0.35);
}
.pop-lvl > span {
  min-width: 0;
  line-height: 1;
  overflow: hidden;
}
.pop-hud.bym-3 .pop-lvl {
  flex: 0 1 auto;
  max-width: 34%;
}
.pop-hud.bym-3 .pop-lvl b {
  overflow: hidden;
  text-overflow: ellipsis;
}
.pop-hud.bym-3 .pop-chips {
  flex: 1 1 0;
  min-width: 0;
}
.pop-lvl b {
  display: block;
  font-weight: 800;
}
.pop-lvl small {
  max-width: 150px;
  margin-top: 0;
  /* con line-height 1 y overflow hidden se cortaba la tilde de «África» */
  line-height: 1.25;
  font-size: 13px;
}
.bym-trophy {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M12 8H5v5c0 6 4 10 10 11M36 8h7v5c0 6-4 10-10 11' fill='none' stroke='%23f2a400' stroke-width='4' stroke-linecap='round'/%3E%3Cpath d='M12 5h24v12c0 8-5 14-12 14S12 25 12 17z' fill='%23ffc61a' stroke='%23e08f00' stroke-width='2'/%3E%3Cpath d='M17 8v9c0 4 2 8 5 9' fill='none' stroke='%23fff3a8' stroke-width='3' stroke-linecap='round'/%3E%3Cpath d='M21 31h6l1 6h-8z' fill='%23f2a400'/%3E%3Crect x='14' y='37' width='20' height='7' rx='2' fill='%23ffc61a' stroke='%23e08f00' stroke-width='2'/%3E%3C/svg%3E")
    center / contain no-repeat;
  filter: drop-shadow(0 2px 0 rgba(5, 20, 70, 0.35));
}
.bym-trophy.clock {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Ccircle cx='24' cy='27' r='17' fill='%23fff' stroke='%23ff5a6e' stroke-width='5'/%3E%3Crect x='19' y='3' width='10' height='6' rx='2' fill='%23ff5a6e'/%3E%3Cpath d='M24 16v11l7 5' fill='none' stroke='%231a2350' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E");
}
.pop-chips {
  gap: 6px;
  flex-wrap: wrap;
  flex-shrink: 0;
}
.pop-chip {
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 40px;
  padding: 2px 11px 2px 7px;
  border-radius: 999px;
  color: var(--bym-ink);
  font-size: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #f1f5ff 100%);
  box-shadow:
    inset 0 -3px 0 #d5e0f7,
    0 4px 0 #0f348f,
    0 7px 12px rgba(5, 20, 70, 0.3);
}
.bym-hi {
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  background: center / contain no-repeat;
}
.bym-hi.heart {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpath d='M16 28S3 20 3 11a6.5 6.5 0 0 1 13-2 6.5 6.5 0 0 1 13 2c0 9-13 17-13 17z' fill='%23f2243f' stroke='%23b8001f' stroke-width='1.5'/%3E%3Cpath d='M8 9.5a3.5 3.5 0 0 1 4-2.5' fill='none' stroke='%23ffb3bd' stroke-width='2.4' stroke-linecap='round'/%3E%3C/svg%3E");
}
.bym-hi.star {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 1.8l3 6.4 7 .8-5.2 4.8 1.4 6.9L12 17.3l-6.2 3.4 1.4-6.9L2 9l7-.8z' fill='%23ffc61a' stroke='%23e89400' stroke-width='1.4' stroke-linejoin='round'/%3E%3Cpath d='M12 4.5l2.1 4.6 4.6.5' fill='none' stroke='%23fff6b0' stroke-width='1.4' stroke-linecap='round'/%3E%3C/svg%3E");
}
.bym-hi.time {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Ccircle cx='24' cy='27' r='17' fill='%23fff' stroke='%23ff5a6e' stroke-width='5'/%3E%3Crect x='19' y='3' width='10' height='6' rx='2' fill='%23ff5a6e'/%3E%3Cpath d='M24 16v11l7 5' fill='none' stroke='%231a2350' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E");
}
.pop-overlay {
  background: rgba(8, 24, 80, 0.55);
}

/* ---------- Layout of the round ---------- */
.pop-dom.bym {
  justify-content: flex-start;
  gap: 9px;
  padding-top: 4px;
}

/* Question / answer card */
.bym-card {
  position: relative;
  width: min(560px, 100%);
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px 9px 9px;
  min-height: 72px;
  border-radius: 24px;
  color: var(--bym-ink);
  background: linear-gradient(180deg, #ffffff 0%, #f2f6ff 100%);
  box-shadow:
    inset 0 0 0 3px rgba(255, 255, 255, 0.9),
    inset 0 -4px 0 rgba(30, 80, 180, 0.12),
    0 5px 0 #113a9c,
    0 10px 22px rgba(5, 20, 70, 0.35);
}
.bym-card.pop {
  animation: bym-cardin 0.38s cubic-bezier(0.2, 1.5, 0.4, 1);
}
.bym-card.good {
  background: linear-gradient(180deg, #f2fff4 0%, #dcf8e2 100%);
  box-shadow:
    inset 0 0 0 3px #fff,
    inset 0 -4px 0 rgba(40, 150, 70, 0.14),
    0 0 0 3px rgba(140, 255, 160, 0.55),
    0 5px 0 #113a9c,
    0 10px 24px rgba(40, 200, 90, 0.35);
}
.bym-card.miss {
  background: linear-gradient(180deg, #fff9ec 0%, #ffecc9 100%);
  box-shadow:
    inset 0 0 0 3px #fff,
    inset 0 -4px 0 rgba(200, 120, 20, 0.14),
    0 0 0 3px rgba(255, 200, 110, 0.55),
    0 5px 0 #113a9c,
    0 10px 24px rgba(5, 20, 70, 0.35);
}
.bym-card.big {
  flex-direction: column;
  gap: 4px;
  padding: 10px 12px 10px;
  text-align: center;
}
.bym-ico {
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-size: 30px;
  background: radial-gradient(circle at 50% 28%, #7cc0ff 0%, #2f7de8 60%, #1d5ccc 100%);
  box-shadow:
    inset 0 0 0 3px rgba(255, 255, 255, 0.85),
    inset 0 -4px 0 rgba(0, 30, 120, 0.25),
    0 3px 0 rgba(17, 58, 156, 0.5);
}
/* the flag sits in a white frame like a sticker */
.bym-flag {
  flex: 0 0 auto;
  height: 52px;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  object-fit: cover;
  background: #eee;
  border: 3px solid #fff;
  box-shadow:
    0 0 0 1px rgba(20, 40, 100, 0.12),
    0 4px 0 rgba(17, 58, 156, 0.25),
    0 6px 12px rgba(5, 20, 70, 0.2);
}
.bym-card.good .bym-flag,
.bym-card.miss .bym-flag {
  height: 76px;
  border-width: 4px;
  border-radius: 12px;
  transform: rotate(-3deg);
}
.bym-card.big .bym-flag {
  height: clamp(70px, 16vh, 132px);
  border-width: 4px;
  border-radius: 12px;
}
.bym-txt {
  min-width: 0;
  flex: 1;
  line-height: 1.1;
}
.bym-txt small {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: #4a5a8c;
}
.bym-card.good .bym-txt small {
  color: var(--bym-green);
  font-size: 18px;
  font-weight: 800;
}
.bym-card.miss .bym-txt small {
  color: #c4620a;
  font-weight: 800;
}
.bym-txt b {
  display: block;
  font-size: clamp(22px, 6vw, 30px);
  font-weight: 800;
  color: var(--bym-ink);
  overflow-wrap: anywhere;
}
.bym-card.good .bym-txt b,
.bym-card.miss .bym-txt b {
  font-size: clamp(26px, 7.6vw, 38px);
  line-height: 1;
  margin-top: 1px;
}
.bym-card.good .bym-txt b.long,
.bym-card.miss .bym-txt b.long {
  font-size: clamp(21px, 5.8vw, 30px);
}
.bym-txt em {
  display: block;
  margin-top: 3px;
  font-style: normal;
  font-size: 14.5px;
  font-weight: 700;
  color: #2c8a3a;
}
.bym-card.miss .bym-txt em {
  color: #a8560c;
}
.bym-txt i {
  display: flex;
  gap: 6px;
  margin-top: 5px;
  padding-top: 5px;
  border-top: 2px dashed rgba(40, 140, 70, 0.22);
  font-style: normal;
  font-size: 13.5px;
  font-weight: 600;
  color: #2d3a66;
  line-height: 1.22;
}
.bym-card.miss .bym-txt i {
  border-top-color: rgba(200, 120, 20, 0.25);
}
.bym-txt i::before {
  content: "💡";
  flex: 0 0 auto;
  font-size: 16px;
  line-height: 1.1;
}
.bym-newstamp {
  display: inline-block;
  padding: 0 8px 0 4px;
  white-space: nowrap;
  border-radius: 999px;
  background: #e2ecff;
  color: #1d4fbf;
  box-shadow: inset 0 0 0 1.5px rgba(29, 79, 191, 0.25);
  animation: bym-thump 0.55s 0.2s cubic-bezier(0.3, 1.6, 0.5, 1) both;
}
/* the globe friend that cheers in the answer card */
.bym-mascot {
  position: absolute;
  right: 4px;
  top: 4px;
  width: 70px;
  height: 66px;
  pointer-events: none;
  animation: bym-wave 1.2s ease-in-out infinite alternate;
}
.bym-card.good .bym-txt,
.bym-card.miss .bym-txt {
  padding-right: 52px;
}
.bym-card.good .bym-txt i,
.bym-card.miss .bym-txt i {
  margin-right: -52px;
}
.bym-joker {
  position: absolute;
  top: -10px;
  right: -6px;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  padding: 0;
  font-size: 22px;
  background: radial-gradient(circle at 50% 30%, #fff38a, #ffd23f 55%, #f5a800);
  box-shadow:
    inset 0 0 0 3px #fff,
    0 4px 0 #b97400,
    0 6px 12px rgba(5, 20, 70, 0.3);
}
.bym-joker b {
  position: absolute;
  right: -3px;
  bottom: -3px;
  min-width: 20px;
  height: 20px;
  border-radius: 10px;
  background: var(--bym-navy);
  color: #fff;
  font-size: 12px;
  line-height: 20px;
  box-shadow: 0 0 0 2px #fff;
}
.bym-joker:active {
  transform: translateY(2px);
}

/* Progress */
.bym-barrow {
  width: min(560px, 100%);
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 800;
  font-size: 19px;
  text-shadow: 0 2px 0 rgba(5, 20, 70, 0.35);
}
.bym-bar {
  flex: 1;
  height: 16px;
  padding: 3px;
  border-radius: 99px;
  background: linear-gradient(180deg, #123c9e, #1b52c4);
  box-shadow:
    inset 0 2px 3px rgba(0, 10, 50, 0.45),
    0 1px 0 rgba(255, 255, 255, 0.35);
}
.bym-bar i {
  display: block;
  height: 100%;
  width: 0;
  min-width: 10px;
  border-radius: 99px;
  background: linear-gradient(180deg, #fff6a0 0%, #ffd83a 45%, #ffb300 100%);
  box-shadow:
    inset 0 -2px 0 rgba(180, 100, 0, 0.35),
    0 0 8px rgba(255, 220, 60, 0.7);
  transition: width 0.35s;
}

/* Map panel */
.bym-wrap {
  position: relative;
  flex: 1 1 auto;
  min-height: 120px;
  width: min(560px, 100%);
  border-radius: 26px;
  background:
    radial-gradient(1.2px 1.2px at 14% 22%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 82% 16%, #fff 50%, transparent 51%),
    radial-gradient(1.4px 1.4px at 70% 82%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 26% 74%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 48% 8%, #fff 50%, transparent 51%),
    radial-gradient(120% 90% at 50% 50%, #1f4fb8 0%, #102a78 70%, #0b1f5e 100%);
  box-shadow:
    0 5px 0 #113a9c,
    0 10px 22px rgba(5, 20, 70, 0.35);
}
.bym-wrap canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  touch-action: none;
  border-radius: 26px;
}
.bym-wrap canvas.bym-relief {
  pointer-events: none;
}
/* white frame drawn above the map (a border would shift the touch maths) */
.bym-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 26px;
  box-shadow:
    inset 0 0 0 3px rgba(255, 255, 255, 0.92),
    inset 0 0 0 4px rgba(20, 60, 150, 0.25),
    inset 0 0 18px rgba(5, 30, 90, 0.35);
  pointer-events: none;
}
.bym-compass {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 64px;
  height: 64px;
  z-index: 1;
  pointer-events: none;
  filter: drop-shadow(0 2px 2px rgba(5, 20, 70, 0.4));
}
.bym-zoom {
  position: absolute;
  right: 8px;
  bottom: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 2;
}
.bym-zoom button {
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 50%;
  padding: 0;
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
  color: var(--bym-navy);
  background: linear-gradient(180deg, #ffffff, #e3ebfd);
  box-shadow:
    0 4px 0 #0f348f,
    0 6px 12px rgba(5, 20, 70, 0.35);
}
.bym-zoom button:active {
  transform: translateY(3px);
  box-shadow: 0 1px 0 #0f348f;
}
.bym-tip {
  position: absolute;
  left: 50%;
  bottom: 10px;
  z-index: 1;
  transform: translateX(-50%);
  padding: 4px 14px;
  border-radius: 99px;
  background: rgba(10, 30, 90, 0.62);
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.35);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  pointer-events: none;
}

/* Answers */
.bym-opts {
  flex: 0 0 auto;
  width: min(560px, 100%);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.bym-opt {
  position: relative;
  border: 0;
  border-radius: 20px;
  padding: 8px 12px;
  min-height: 60px;
  color: var(--bym-ink);
  font-weight: 800;
  font-size: clamp(16px, 4.6vw, 21px);
  line-height: 1.08;
  background: linear-gradient(180deg, #ffffff 0%, #f6f9ff 55%, #e6eefc 100%);
  box-shadow:
    inset 0 2px 0 #fff,
    inset 0 -3px 0 rgba(40, 90, 190, 0.12),
    0 5px 0 #b5c6ea,
    0 9px 16px rgba(5, 20, 70, 0.3);
  transition: opacity 0.25s;
}
.bym-opt:active {
  transform: translateY(3px);
  box-shadow:
    inset 0 2px 0 #fff,
    0 2px 0 #b5c6ea;
}
.bym-opt.flag {
  padding: 7px;
  min-height: 0;
}
.bym-opt.flag img {
  display: block;
  height: clamp(54px, 11vh, 96px);
  max-width: 100%;
  margin: 0 auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 7px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.14);
}
.bym-opt.flag span {
  display: block;
  font-size: 13px;
  margin-top: 3px;
  min-height: 15px;
}
.bym-opt.ok,
.bym-opt.no {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.bym-opt.flag.ok,
.bym-opt.flag.no {
  display: block;
}
.bym-opt.ok {
  color: #0e3b12;
  background: linear-gradient(180deg, #b9ff8f 0%, #74ec4c 50%, #45d43a 100%);
  box-shadow:
    inset 0 0 0 3px rgba(255, 255, 255, 0.85),
    inset 0 -4px 0 rgba(20, 120, 20, 0.25),
    0 5px 0 #2a9a2a,
    0 0 0 3px rgba(150, 255, 120, 0.4),
    0 0 22px 4px rgba(120, 255, 100, 0.55);
}
.bym-opt.no {
  color: #5c0b1a;
  background: linear-gradient(180deg, #ffd0d6 0%, #ff97a6 55%, #ff7a8e 100%);
  box-shadow:
    inset 0 0 0 3px rgba(255, 255, 255, 0.8),
    inset 0 -4px 0 rgba(160, 20, 40, 0.2),
    0 5px 0 #c94459,
    0 9px 16px rgba(5, 20, 70, 0.3);
}
.bym-opt.ok::before,
.bym-opt.no::before {
  content: "";
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  background: center / contain no-repeat;
}
.bym-opt.ok::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ccircle cx='16' cy='16' r='14' fill='%23168f2e' stroke='%23fff' stroke-width='3'/%3E%3Cpath d='M9 16.5l4.5 4.5L23 11.5' fill='none' stroke='%23fff' stroke-width='4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.bym-opt.no::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Ccircle cx='16' cy='16' r='14' fill='%23d81f3c' stroke='%23fff' stroke-width='3'/%3E%3Cpath d='M11 11l10 10M21 11L11 21' fill='none' stroke='%23fff' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E");
}
.bym-opt.flag.ok::before,
.bym-opt.flag.no::before {
  position: absolute;
  top: -8px;
  left: -8px;
  z-index: 1;
}
.bym-opt.gone {
  opacity: 0.18;
  pointer-events: none;
}
.bym-next {
  position: relative;
  grid-column: 1 / -1;
  justify-self: center;
  width: min(100% - 64px, 440px);
  min-height: 58px;
  margin: 4px 0 2px;
  border: 0;
  border-radius: 999px;
  color: var(--bym-ink);
  font-weight: 800;
  font-size: 26px;
  background: linear-gradient(180deg, #fff59a 0%, #ffe03d 40%, #ffc21a 75%, #ffab00 100%);
  box-shadow:
    inset 0 3px 0 rgba(255, 255, 255, 0.75),
    inset 0 -4px 0 rgba(200, 110, 0, 0.3),
    0 6px 0 #c77700,
    0 10px 20px rgba(5, 20, 70, 0.35);
  animation: bym-in 0.35s;
}
.bym-next:active {
  transform: translateY(4px);
  box-shadow:
    inset 0 3px 0 rgba(255, 255, 255, 0.75),
    0 2px 0 #c77700;
}
/* little light rays on both sides of the button */
.bym-next::before,
.bym-next::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 22px;
  height: 34px;
  margin-top: -20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 34'%3E%3Cg stroke='%23fff6b0' stroke-width='4' stroke-linecap='round'%3E%3Cpath d='M14 3l-6 6M17 17H5M14 31l-6-6'/%3E%3C/g%3E%3C/svg%3E")
    center / contain no-repeat;
  animation: bym-twinkle 1.4s ease-in-out infinite;
}
.bym-next::before {
  left: -28px;
}
.bym-next::after {
  right: -28px;
  transform: scaleX(-1);
}

/* ---------- Passport ---------- */
.bym-pass {
  position: fixed;
  inset: 0;
  z-index: 20;
  overflow-y: auto;
  background: url("fondo.svg") center bottom / 100% auto no-repeat fixed, linear-gradient(170deg, #1846bd, #0f2f86);
  color: #fff;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 14px 30px;
  touch-action: pan-y;
  animation: pop-fade 0.2s;
}
.bym-pass header {
  position: sticky;
  top: -12px;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: -12px -14px 10px;
  padding: 12px 14px 10px;
  background: rgba(16, 48, 140, 0.92);
  box-shadow: 0 4px 14px rgba(5, 20, 70, 0.35);
  backdrop-filter: blur(6px);
}
.bym-pass h2 {
  margin: 0;
  font-size: 26px;
  line-height: 1.05;
  flex: 1;
}
.bym-pass h2 small {
  display: block;
  font-size: 14px;
  font-weight: 700;
  opacity: 0.85;
}
.bym-pass h3 {
  margin: 18px 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 19px;
}
.bym-pass h3 i {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 2px #fff;
}
.bym-pass h3 span {
  margin-left: auto;
  padding: 0 10px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.16);
  font-size: 14px;
}
.bym-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(98px, 1fr));
  gap: 10px;
}
/* postage stamps: white paper with a row of perforation holes all round */
.bym-stamp {
  border: 7px solid transparent;
  padding: 1px 2px 4px;
  text-align: center;
  line-height: 1.05;
  color: var(--bym-ink);
  background:
    linear-gradient(#fff, #fff) padding-box,
    radial-gradient(circle, #2050c0 1.7px, #fff 2.2px) 0 0 / 7px 7px round border-box;
  filter: drop-shadow(0 3px 0 rgba(5, 20, 70, 0.3));
  transform: rotate(-1.2deg);
}
.bym-stamp:nth-child(2n) {
  transform: rotate(1.4deg);
}
.bym-stamp:nth-child(3n) {
  transform: rotate(-0.4deg);
}
.bym-stamp img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 3px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
}
.bym-stamp b {
  display: block;
  margin-top: 4px;
  font-size: 13px;
}
.bym-stamp small {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  color: #5a6890;
}
.bym-stamp.off {
  border: 2px dashed rgba(255, 255, 255, 0.35);
  border-radius: 10px;
  padding: 6px 6px 7px;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.75);
  filter: none;
  transform: none;
}
.bym-stamp.off div {
  aspect-ratio: 4 / 3;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.08);
  display: grid;
  place-items: center;
  font-size: 24px;
}
.bym-stamp.off small {
  color: rgba(255, 255, 255, 0.6);
}
.bym-pass-reset {
  margin: 26px auto 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
}
.bym-pass-reset > .pop-btn.ghost {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 16px;
  min-height: 44px;
  box-shadow: none;
  border: 2px solid rgba(255, 255, 255, 0.3);
}
.bym-confirm {
  width: min(360px, 100%);
  padding: 14px 14px 12px;
  border-radius: 20px;
  background: #fff;
  color: var(--bym-ink);
  box-shadow: 0 6px 0 rgba(0, 0, 0, 0.25);
  animation: bym-in 0.3s cubic-bezier(0.2, 1.6, 0.4, 1);
}
.bym-confirm p {
  margin: 0 0 4px;
  font-size: 19px;
  font-weight: 800;
  line-height: 1.15;
}
.bym-confirm small {
  display: block;
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 600;
  color: #5a6890;
}
.bym-confirm .pop-row {
  margin: 0;
}
.bym-confirm .pop-btn.danger {
  background: #ff5a76;
  color: #fff;
}

/* ---------- Soft animations ---------- */
.bym-stamp.fresh {
  position: relative;
  animation: bym-thump 0.55s cubic-bezier(0.3, 1.6, 0.5, 1) both;
}
.bym-stamp.fresh::after {
  content: "";
  position: absolute;
  inset: -9px;
  border-radius: 12px;
  border: 3px solid rgba(255, 79, 123, 0.75);
  pointer-events: none;
  animation: bym-ink 0.7s ease-out both;
  animation-delay: inherit;
}
.bym-card.pop.good {
  animation: bym-bounce 0.5s cubic-bezier(0.3, 1.5, 0.5, 1);
}
.bym-card.pop.miss {
  animation: bym-shake 0.42s;
}
.bym-opts > .bym-opt {
  animation: bym-rise 0.32s ease-out both;
}
.bym-opts > .bym-opt:nth-child(2) {
  animation-delay: 0.05s;
}
.bym-opts > .bym-opt:nth-child(3) {
  animation-delay: 0.1s;
}
.bym-opts > .bym-opt:nth-child(4) {
  animation-delay: 0.15s;
}
.bym-opts > .bym-opt.ok {
  animation: bym-bounce 0.5s cubic-bezier(0.3, 1.5, 0.5, 1);
}
.bym-opts > .bym-opt.no {
  animation: bym-shake 0.42s;
}
@keyframes bym-in {
  from {
    transform: scale(0.85);
  }
}
@keyframes bym-cardin {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.94);
  }
}
@keyframes bym-rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}
@keyframes bym-bounce {
  0% {
    transform: scale(1);
  }
  35% {
    transform: scale(1.08);
  }
  65% {
    transform: scale(0.98);
  }
  100% {
    transform: scale(1);
  }
}
@keyframes bym-shake {
  20% {
    transform: translateX(-7px) rotate(-1deg);
  }
  40% {
    transform: translateX(6px) rotate(1deg);
  }
  60% {
    transform: translateX(-4px);
  }
  80% {
    transform: translateX(3px);
  }
}
@keyframes bym-thump {
  0% {
    opacity: 0;
    transform: scale(1.8) rotate(-14deg);
  }
  55% {
    opacity: 1;
    transform: scale(0.92) rotate(4deg);
  }
  100% {
    transform: scale(1) rotate(-2deg);
  }
}
@keyframes bym-ink {
  0% {
    opacity: 0;
    transform: scale(0.6);
  }
  40% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: scale(1.18);
  }
}
@keyframes bym-wave {
  from {
    transform: rotate(-4deg) translateY(0);
  }
  to {
    transform: rotate(4deg) translateY(-3px);
  }
}
@keyframes bym-twinkle {
  50% {
    opacity: 0.45;
  }
}

/* ---------- País del día ---------- */
.bym-daybtn {
  margin-top: 12px;
  flex-direction: column;
  gap: 0;
  width: min(340px, 100%);
  min-height: 62px;
  padding: 6px 20px 8px;
  background: linear-gradient(180deg, #6ff0c4, #1fc08a);
  line-height: 1.1;
  font-size: 22px;
  animation: pop-glow 2.2s ease-in-out infinite;
}
.bym-daybtn small {
  font-size: 14px;
  font-weight: 700;
  color: #11493a;
}
.bym-daybtn.done {
  animation: none;
  background: linear-gradient(180deg, #d9fff1, #9fe8cd);
}
.bym-day {
  user-select: none;
}
.bym-day header {
  margin-bottom: 8px;
}
.bym-day-racha {
  font-size: 20px;
  font-weight: 800;
  white-space: nowrap;
}
.bym-day-tries {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 0 auto 10px;
  max-width: 520px;
}
.bym-day-tries i {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-style: normal;
  font-size: 18px;
  background: rgba(255, 255, 255, 0.14);
  border: 2px solid rgba(255, 255, 255, 0.25);
}
.bym-day-tries span {
  margin-left: auto;
  font-weight: 800;
  font-size: 15px;
  opacity: 0.9;
}
.bym-day-vis {
  display: flex;
  gap: 10px;
  max-width: 520px;
  margin: 0 auto;
}
.bym-day-vis figure {
  margin: 0;
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, 0.18);
}
.bym-day-vis figcaption {
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  line-height: 1.1;
  opacity: 0.92;
}
.bym-day-flag {
  flex-grow: 1.35 !important;
}
.bym-day-flag canvas,
.bym-day-flag img {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
  object-fit: cover;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
}
.bym-day-globe canvas {
  width: 100%;
  max-width: 132px;
  aspect-ratio: 1;
}
.bym-day-vis figure.locked canvas {
  background: repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.07) 0 8px, rgba(255, 255, 255, 0.13) 8px 16px);
  border-radius: 12px;
}
.bym-day-globe.locked canvas {
  border-radius: 50%;
}
.bym-day-vis figure.new {
  animation: bym-bounce 0.5s cubic-bezier(0.3, 1.5, 0.5, 1);
}
.bym-day-clues {
  list-style: none;
  padding: 0;
  margin: 10px auto 0;
  max-width: 520px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.bym-day-clues li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px 6px 8px;
  border-radius: 16px;
  background: #fff;
  color: var(--bym-ink);
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.2);
}
.bym-day-clues li.locked {
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  box-shadow: none;
}
.bym-day-clues li.new {
  animation:
    bym-rise 0.4s ease-out,
    bym-bounce 0.5s 0.3s;
}
.bym-day-clues .e {
  font-size: 22px;
  width: 30px;
  text-align: center;
}
.bym-day-clues small {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  opacity: 0.75;
  line-height: 1.1;
}
.bym-day-clues b {
  display: block;
  font-size: 18px;
  line-height: 1.15;
}
.bym-day-word {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  padding-top: 2px;
}
.bym-day-word b {
  width: 19px;
  height: 24px;
  border-radius: 5px;
  background: #e6eeff;
  display: grid;
  place-items: center;
  font-size: 15px;
}
.bym-day-word b.on {
  background: #ffd23f;
}
.bym-day-word .gap {
  width: 8px;
}
.bym-day-play {
  max-width: 520px;
  margin: 12px auto 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bym-day-label {
  font-size: 19px;
  font-weight: 800;
}
.bym-day-search {
  position: relative;
}
.bym-day-search input {
  width: 100%;
  height: 54px;
  border: 0;
  border-radius: 18px;
  padding: 0 16px;
  font: inherit;
  font-size: 20px;
  font-weight: 700;
  color: var(--bym-ink);
  background: #fff;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.22);
  outline: none;
  user-select: text;
  -webkit-user-select: text;
}
.bym-day-search input:focus {
  box-shadow:
    0 4px 0 rgba(0, 0, 0, 0.22),
    0 0 0 3px #ffd23f;
}
.bym-day-search input.shake {
  animation: bym-shake 0.42s;
}
.bym-day-sug {
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.bym-day-sug:empty {
  display: none;
}
.bym-day-sug li {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 6px 12px;
  border-radius: 14px;
  background: #fff;
  color: var(--bym-ink);
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.18);
  animation: bym-rise 0.2s ease-out both;
}
.bym-day-sug li:active {
  transform: translateY(2px);
}
.bym-day-sug li.none {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  box-shadow: none;
  cursor: default;
  font-weight: 700;
}
.bym-day-sug img,
.bym-day-guesses img {
  width: 36px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
  flex: 0 0 auto;
}
.bym-day-more {
  align-self: center;
  font-size: 16px;
  min-height: 44px;
}
.bym-day-more small {
  font-size: 13px;
  font-weight: 700;
  opacity: 0.7;
}
.bym-day-guesses {
  list-style: none;
  padding: 0;
  margin: 14px auto 0;
  max-width: 520px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.bym-day-guesses li {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6px 10px 6px 8px;
  border-radius: 16px;
  background: #fff1d6;
  color: var(--bym-ink);
}
.bym-day-guesses li.new {
  animation:
    bym-rise 0.35s ease-out,
    bym-shake 0.42s 0.3s;
}
.bym-day-guesses li.skip {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}
.bym-day-guesses li.win {
  background: #c9ffd4;
}
.bym-day-guesses .n {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.12);
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 800;
  flex: 0 0 auto;
}
.bym-day-guesses .e {
  font-size: 20px;
}
.bym-day-guesses div {
  flex: 1;
  min-width: 0;
  line-height: 1.12;
}
.bym-day-guesses b {
  display: block;
  font-size: 17px;
}
.bym-day-guesses small {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: #4f5c86;
}
.bym-day-guesses .tags {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  flex: 0 0 auto;
}
.bym-day-guesses .arrow {
  font-size: 22px;
  line-height: 1;
}
.bym-day-guesses .cont {
  font-size: 11.5px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 99px;
  white-space: nowrap;
}
.bym-day-guesses .cont.yes {
  background: #7cf06b;
}
.bym-day-guesses .cont.no {
  background: #ffb3c0;
}
.bym-day-foot {
  max-width: 520px;
  margin: 16px auto 0;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  opacity: 0.75;
  line-height: 1.3;
}
.bym-day-result {
  max-width: 520px;
  margin: 0 auto 14px;
  padding: 14px 14px 12px;
  border-radius: 22px;
  background: #fff;
  color: var(--bym-ink);
  text-align: center;
  box-shadow: 0 6px 0 rgba(0, 0, 0, 0.25);
}
.bym-day-result.ok {
  background: linear-gradient(180deg, #e3ffe9, #fff 60%);
}
.bym-day-result.new {
  animation: bym-cardin 0.45s cubic-bezier(0.2, 1.5, 0.4, 1);
}
.bym-day-bigflag {
  height: 92px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 10px;
  border: 4px solid #fff;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.12),
    0 4px 0 rgba(0, 0, 0, 0.15);
}
.bym-day-result h3 {
  margin: 6px 0 0;
  font-size: 19px;
  color: #5a6890;
}
.bym-day-result .name {
  margin: 0;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.05;
}
.bym-day-result .cap {
  margin: 2px 0 0;
  font-size: 14px;
  font-weight: 700;
  color: #5a6890;
}
.bym-day-result .fact {
  margin: 8px 0 0;
  font-size: 14.5px;
  font-weight: 600;
  color: #2d3a66;
  line-height: 1.25;
}
.bym-day-stamp {
  display: inline-block;
  margin-top: 10px;
  padding: 4px 14px;
  border: 3px solid #ff4f7b;
  border-radius: 12px;
  color: #e0204f;
  font-size: 18px;
  font-weight: 800;
  transform: rotate(-3deg);
  animation: bym-thump 0.6s 0.35s cubic-bezier(0.3, 1.6, 0.5, 1) both;
}
.bym-day-card {
  margin: 12px auto 0;
  padding: 8px 10px;
  border-radius: 16px;
  background: #eef3ff;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.bym-day-card b {
  font-size: 15.5px;
}
.bym-day-card .grid {
  font-size: 24px;
  letter-spacing: 2px;
}
.bym-day-stats {
  display: flex;
  gap: 6px;
  margin-top: 10px;
}
.bym-day-stats span {
  flex: 1;
  padding: 6px 4px;
  border-radius: 14px;
  background: #fff6d6;
  font-size: 12px;
  font-weight: 700;
  color: #4f5c86;
  line-height: 1.1;
}
.bym-day-stats b {
  display: block;
  font-size: 22px;
  color: var(--bym-ink);
}
.bym-day-share {
  margin-top: 12px;
  font-size: 20px;
  padding: 8px 30px;
}
.bym-day-next {
  margin: 10px 0 0;
  font-size: 16px;
  font-weight: 800;
  color: #2d3a66;
}
.bym-day-next .pop-btn {
  margin-left: 6px;
  min-height: 40px;
  font-size: 16px;
}
.bym-day-toast {
  position: fixed;
  top: 40%;
  z-index: 30;
  font-size: 19px;
  max-width: calc(100vw - 32px);
  white-space: normal;
  text-align: center;
  animation-duration: 1.9s;
}
.bym-confetti {
  position: fixed;
  inset: 0;
  z-index: 40;
  pointer-events: none;
  overflow: hidden;
}
.bym-confetti i {
  position: absolute;
  top: -14px;
  width: 9px;
  height: 13px;
  border-radius: 2px;
  animation: bym-fall 2s ease-in both;
}
@keyframes bym-fall {
  to {
    transform: translate(var(--x), 105vh) rotate(720deg);
  }
}

/* ---------- Sizes ---------- */
@media (prefers-reduced-motion: reduce) {
  .bym-card,
  .bym-card.pop,
  .bym-opt,
  .bym-opts > .bym-opt,
  .bym-next,
  .bym-next::before,
  .bym-next::after,
  .bym-mascot,
  .pop-logo svg,
  .bym-stamp.fresh,
  .bym-stamp.fresh::after,
  .bym-newstamp,
  .bym-confirm,
  .bym-daybtn,
  .bym-day *,
  .bym-day-result.new {
    animation: none !important;
  }
}
@media (min-width: 700px) {
  .bym-opts {
    grid-template-columns: repeat(4, 1fr);
  }
}
@media (max-width: 380px) {
  .pop-lvl {
    font-size: 19px;
  }
  .bym-trophy {
    width: 28px;
    height: 28px;
  }
  .pop-lvl small {
    max-width: 96px;
  }
  .pop-chip {
    font-size: 18px;
    padding-right: 10px;
  }
  .bym-hi {
    width: 22px;
    height: 22px;
  }
}
@media (max-height: 640px) {
  .bym-card.good .bym-flag,
  .bym-card.miss .bym-flag {
    height: 58px;
  }
  .bym-compass {
    width: 48px;
    height: 48px;
  }
  .bym-mascot {
    width: 58px;
    height: 54px;
  }
}
@media (max-height: 560px) {
  .bym-card.big .bym-flag {
    height: 58px;
  }
  .bym-opt {
    min-height: 46px;
  }
  .bym-next {
    min-height: 46px;
    font-size: 21px;
  }
}
/* Phone on its side: globe on the left, answers on the right */
@media (orientation: landscape) and (max-height: 520px) {
  .pop-dom.bym {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(250px, 42%);
    grid-template-rows: auto auto minmax(0, 1fr);
    column-gap: 10px;
    row-gap: 6px;
    align-items: stretch;
    justify-items: stretch;
    padding-top: 0;
  }
  .bym-card {
    grid-column: 2;
    grid-row: 1;
    width: auto;
    min-height: 0;
    padding: 6px 10px 6px 6px;
  }
  .bym-card.big {
    flex-direction: row;
    text-align: left;
  }
  .bym-flag {
    height: 40px;
  }
  .bym-card.big .bym-flag,
  .bym-card.good .bym-flag,
  .bym-card.miss .bym-flag {
    height: 56px;
  }
  .bym-ico {
    width: 40px;
    height: 40px;
    font-size: 22px;
  }
  .bym-txt b,
  .bym-card.good .bym-txt b,
  .bym-card.miss .bym-txt b {
    font-size: 21px;
  }
  .bym-txt i {
    display: none;
  }
  .bym-mascot {
    display: none;
  }
  .bym-card.good .bym-txt,
  .bym-card.miss .bym-txt {
    padding-right: 0;
  }
  .bym-barrow {
    grid-column: 2;
    grid-row: 2;
    width: auto;
  }
  .bym-wrap {
    grid-column: 1;
    grid-row: 1 / 4;
    min-height: 0;
    width: auto;
  }
  .bym-compass {
    width: 44px;
    height: 44px;
  }
  .bym-opts {
    grid-column: 2;
    grid-row: 3;
    width: auto;
    align-content: start;
    grid-template-columns: 1fr 1fr;
  }
  .bym-opt {
    min-height: 44px;
  }
  .bym-opt.flag img {
    height: 50px;
  }
  .bym-next {
    min-height: 44px;
    font-size: 20px;
  }
  .bym-next::before,
  .bym-next::after {
    display: none;
  }
  .bym-joker {
    width: 38px;
    height: 38px;
    font-size: 17px;
    top: -4px;
    right: -4px;
  }
}
