.hud {
  position: absolute;
  z-index: 20;
  inset: clamp(10px, 2vw, 24px) clamp(10px, 2vw, 24px) auto;
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}

.hud-pill,
.icon-button {
  border: 1px solid rgba(255, 255, 255, 0.88);
  background: rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--soft-shadow);
}

.hud-pill {
  min-width: clamp(76px, 9vw, 126px);
  min-height: clamp(42px, 5vw, 62px);
  display: grid;
  align-content: center;
  padding: 7px 16px;
  border-radius: 18px;
}

.hud-label {
  display: block;
  color: var(--muted);
  font-size: clamp(8px, 0.8vw, 11px);
  font-weight: 800;
  letter-spacing: 0.14em;
}

.hud-pill strong {
  font-size: clamp(18px, 2.2vw, 32px);
  line-height: 1;
}

.hud-pill--stars {
  min-width: 82px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hud-star {
  color: #e8ab00;
  font-size: clamp(20px, 2.3vw, 34px);
  text-shadow: 0 3px 0 rgba(255, 255, 255, 0.6);
}

.hud-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
  pointer-events: auto;
}

.icon-button {
  width: clamp(42px, 5vw, 62px);
  height: clamp(42px, 5vw, 62px);
  border-radius: 18px;
  cursor: pointer;
  font-size: clamp(17px, 2vw, 27px);
}

.screen {
  position: absolute;
  z-index: 30;
  inset: 0;
  display: grid;
  place-items: center;
  padding: clamp(16px, 3vw, 42px);
  text-align: center;
}

.screen--menu {
  background:
    radial-gradient(circle at 50% 33%, rgba(255, 255, 255, 0.85), transparent 27%),
    linear-gradient(90deg, rgba(255, 245, 251, 0.84), rgba(255, 255, 255, 0.3));
}

.brand-mark {
  width: clamp(62px, 8vw, 106px);
  height: clamp(62px, 8vw, 106px);
  margin-bottom: 6px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--soft-shadow);
  font-size: clamp(34px, 4.6vw, 62px);
}

.eyebrow {
  margin: 0;
  color: var(--pink-700);
  font-size: clamp(10px, 1vw, 14px);
  font-weight: 900;
  letter-spacing: 0.2em;
}

.screen h1 {
  margin: -3px 0 0;
  color: var(--pink-700);
  font-size: clamp(68px, 10vw, 144px);
  line-height: 0.88;
  letter-spacing: -0.065em;
  text-shadow:
    0 5px 0 rgba(255, 255, 255, 0.85),
    0 16px 34px rgba(163, 52, 109, 0.18);
}

.tagline {
  margin: 12px 0 16px;
  color: var(--ink);
  font-size: clamp(14px, 1.8vw, 25px);
  font-weight: 750;
}

.menu-record {
  margin-bottom: 18px;
  display: grid;
  gap: 2px;
}

.menu-record span {
  color: var(--muted);
  font-size: clamp(9px, 0.8vw, 11px);
  font-weight: 800;
  letter-spacing: 0.12em;
}

.menu-record strong {
  font-size: clamp(18px, 2.1vw, 28px);
}

.primary-button,
.secondary-button {
  width: min(330px, 74vw);
  min-height: clamp(48px, 5.5vw, 66px);
  border-radius: 999px;
  cursor: pointer;
  font-weight: 900;
  letter-spacing: 0.08em;
  transition:
    transform 130ms ease,
    box-shadow 130ms ease,
    filter 130ms ease;
}

.primary-button {
  border: 0;
  background: linear-gradient(180deg, #ff85bd, #e84b97);
  color: var(--white);
  box-shadow:
    0 9px 0 #b93676,
    0 18px 28px rgba(177, 54, 116, 0.24);
}

.primary-button:hover,
.secondary-button:hover,
.icon-button:hover,
.text-button:hover {
  filter: brightness(1.03);
}

.primary-button:active,
.secondary-button:active,
.icon-button:active,
.text-button:active {
  transform: translateY(3px) scale(0.99);
}

.primary-button:active {
  box-shadow:
    0 5px 0 #b93676,
    0 12px 22px rgba(177, 54, 116, 0.2);
}

.primary-button--small {
  width: min(260px, 68vw);
}

.secondary-button {
  margin-top: 15px;
  border: 2px solid rgba(200, 63, 130, 0.2);
  background: rgba(255, 255, 255, 0.78);
  color: var(--pink-700);
  box-shadow: 0 10px 26px rgba(108, 46, 79, 0.1);
}


.secondary-action-row {
  width: min(330px, 74vw);
  margin: 15px auto 0;
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 8px;
}

.secondary-button--compact {
  width: 100%;
  min-height: 50px;
  margin-top: 0;
  padding-inline: 10px;
  font-size: clamp(10px, 1vw, 13px);
}

.text-button {
  margin-top: 13px;
  padding: 8px 14px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--pink-900);
  cursor: pointer;
  font-size: clamp(9px, 0.8vw, 11px);
  font-weight: 850;
  letter-spacing: 0.1em;
}

.menu-note {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: clamp(10px, 1.05vw, 14px);
  font-weight: 650;
}

.screen--panel {
  background: rgba(76, 30, 55, 0.16);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.panel {
  width: min(520px, 88%);
  max-height: 90%;
  overflow: auto;
  padding: clamp(22px, 4vw, 46px);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: clamp(22px, 3vw, 36px);
  background: rgba(255, 250, 253, 0.95);
  box-shadow: var(--shadow);
}

.panel h2 {
  margin: 8px 0 20px;
  color: var(--ink);
  font-size: clamp(24px, 3.5vw, 44px);
  line-height: 1.04;
}

.instruction-card {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 10px 0;
  padding: 14px 18px;
  border: 1px solid rgba(200, 63, 130, 0.11);
  border-radius: 20px;
  background: var(--white);
  text-align: left;
}

.instruction-card strong {
  color: var(--pink-700);
  font-size: 12px;
  letter-spacing: 0.12em;
}

.instruction-card p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.instruction-icon {
  width: 48px;
  flex: 0 0 48px;
  font-size: 34px;
}

.panel-tip {
  margin: 18px 0 22px;
  color: var(--muted);
  font-size: 14px;
}

.pause-icon,
.game-over-icon {
  font-size: clamp(42px, 6vw, 72px);
}

.record-badge {
  width: fit-content;
  margin: -8px auto 16px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--yellow);
  color: #704e00;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.1em;
  box-shadow: 0 8px 18px rgba(170, 121, 0, 0.16);
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 0 0 24px;
}

.result-grid div {
  padding: 15px 8px;
  border: 1px solid rgba(200, 63, 130, 0.11);
  border-radius: 18px;
  background: var(--white);
}

.result-grid span {
  display: block;
  color: var(--muted);
  font-size: clamp(8px, 0.8vw, 10px);
  font-weight: 850;
  letter-spacing: 0.1em;
}

.result-grid strong {
  display: block;
  margin-top: 3px;
  color: var(--pink-700);
  font-size: clamp(20px, 2.8vw, 34px);
}

.ready-overlay {
  position: absolute;
  z-index: 25;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.ready-overlay strong {
  padding: 16px 28px;
  border: 1px solid rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--pink-700);
  font-size: clamp(26px, 5vw, 66px);
  line-height: 1;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.orientation-hint {
  display: none;
}

.toast {
  position: absolute;
  z-index: 80;
  left: 50%;
  bottom: clamp(14px, 3vw, 30px);
  transform: translateX(-50%);
  width: max-content;
  max-width: min(88%, 620px);
  padding: 11px 18px;
  border: 1px solid rgba(255, 255, 255, 0.88);
  border-radius: 999px;
  background: rgba(71, 40, 58, 0.9);
  color: white;
  box-shadow: var(--soft-shadow);
  font-size: clamp(11px, 1.2vw, 14px);
  font-weight: 700;
  text-align: center;
}

@media (orientation: portrait) and (max-width: 820px) {
  body:not(.character-selection-active) .orientation-hint { display: none !important; }

  body.character-selection-active .orientation-hint,
  body.character-selection-active .orientation-hint.orientation-hint--dismissed,
  body.character-selection-active .orientation-hint:not(.orientation-hint--dismissed) {
    position: absolute;
    z-index: 95;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 28px 22px;
    border: 0;
    border-radius: 0;
    background:
      radial-gradient(circle at 50% 30%, rgba(255, 255, 255, 0.18), transparent 34%),
      linear-gradient(180deg, rgba(71, 40, 58, 0.96), rgba(143, 36, 95, 0.96));
    color: white;
    box-shadow: none;
    text-align: center;
  }

  .orientation-hint > span {
    font-size: 58px;
    line-height: 1;
  }

  .orientation-hint strong,
  .orientation-hint small {
    display: block;
  }

  .orientation-hint strong {
    font-size: 24px;
    line-height: 1.08;
    font-weight: 950;
  }

  .orientation-hint small {
    max-width: 280px;
    margin: 7px auto 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 14px;
    font-weight: 750;
  }

  .orientation-links {
    display: grid;
    gap: 10px;
    width: min(310px, 92%);
    margin-top: 8px;
  }

  .orientation-links a {
    display: block;
    padding: 12px 14px;
    border: 2px solid rgba(255, 255, 255, 0.92);
    border-radius: 999px;
    background: #f86fb0;
    color: #ffffff;
    font-size: 14px;
    font-weight: 950;
    text-decoration: none;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.24);
  }

  .orientation-links a:nth-child(2) {
    background: #31b928;
  }

  .orientation-hint button {
    display: none;
  }

  .mobile-project-links {
    display: none !important;
  }
}

@media (orientation: landscape) {
  .orientation-links {
    display: none;
  }
}

@media (max-height: 600px) and (orientation: landscape) {
  .brand-mark {
    width: 50px;
    height: 50px;
    font-size: 28px;
  }

  .screen h1 {
    font-size: 62px;
  }

  .tagline {
    margin: 5px 0 7px;
    font-size: 13px;
  }

  .menu-record {
    margin-bottom: 8px;
  }

  .primary-button,
  .secondary-button {
    min-height: 40px;
  }

  .secondary-button {
    margin-top: 8px;
  }

  
.secondary-action-row {
  width: min(330px, 74vw);
  margin: 15px auto 0;
  display: grid;
  grid-template-columns: 0.75fr 1.25fr;
  gap: 8px;
}

.secondary-button--compact {
  width: 100%;
  min-height: 50px;
  margin-top: 0;
  padding-inline: 10px;
  font-size: clamp(10px, 1vw, 13px);
}

.text-button {
    margin-top: 7px;
    padding-top: 5px;
    padding-bottom: 5px;
  }

  .menu-note {
    margin-top: 7px;
  }

  .panel {
    padding: 18px 24px;
  }

  .panel h2 {
    margin-bottom: 10px;
    font-size: 27px;
  }

  .instruction-card {
    padding: 8px 14px;
  }

  .result-grid {
    margin-bottom: 12px;
  }
}

/* v0.2.0 — Tela oficial de seleção de personagens */
.character-select-screen {
  display: block;
  padding: 0;
  text-align: initial;
  background: url("../assets/images/ui/screen-character-select.webp") center / 100% 100% no-repeat;
}

.character-select-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.selected-marker {
  position: absolute;
  z-index: 35;
  width: 5.45%;
  aspect-ratio: 1 / 1;
  background: url("../assets/images/ui/marker-selected.webp") center / contain no-repeat;
  transform: translateZ(0);
  pointer-events: none;
  filter: drop-shadow(0 7px 9px rgba(101, 24, 78, 0.26));
  transition: left 160ms ease, top 160ms ease, transform 160ms ease;
}

.menu-stars {
  position: absolute;
  z-index: 34;
  top: 4.25%;
  right: 3.7%;
  min-width: 17.2%;
  height: 8.3%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5.5%;
  padding-inline: 2.2% 1.1%;
  border: 0.22vw solid rgba(255, 255, 255, 0.96);
  border-radius: 999px;
  background: linear-gradient(180deg, #6d54dc, #4e31a7);
  box-shadow: 0 0.65vw 0 rgba(49, 26, 122, 0.28), 0 1.2vw 2vw rgba(49, 26, 122, 0.18);
  color: #fff;
  font-weight: 950;
  font-size: clamp(16px, 2.35vw, 42px);
  line-height: 1;
  text-shadow: 0 0.22vw 0 rgba(44, 22, 96, 0.4);
}

.menu-stars-icon {
  color: #ffd55a;
  font-size: 1.08em;
  text-shadow: 0 0.16vw 0 #bd761f, 0 0.26vw 0.6vw rgba(0, 0, 0, 0.18);
}

.menu-stars-plus {
  width: 20%;
  aspect-ratio: 1 / 1;
  display: grid;
  place-items: center;
  margin-right: -3.5%;
  border: 0.22vw solid rgba(255, 255, 255, 0.96);
  border-radius: 50%;
  background: linear-gradient(180deg, #ff72b0, #e53689);
  box-shadow: 0 0.36vw 0 #bd2d75;
  font-size: 1.05em;
}

.character-hitboxes {
  position: absolute;
  inset: 0;
  z-index: 36;
}

.player-badge {
  position: absolute;
  z-index: 38;
  left: 11.2%;
  top: 4.45%;
  min-width: 19%;
  max-width: 28%;
  min-height: 7.1%;
  display: flex;
  align-items: center;
  gap: 0.65vw;
  padding: 0.55vw 0.85vw;
  border: 0.2vw solid rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 227, 244, 0.94));
  box-shadow: 0 0.55vw 0 rgba(194, 61, 134, 0.2), 0 1vw 1.8vw rgba(119, 39, 92, 0.18);
  color: #803576;
  font-weight: 900;
  pointer-events: auto;
}

.player-badge span {
  font-size: clamp(8px, 0.75vw, 12px);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.78;
}

.player-badge strong {
  max-width: 9vw;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: clamp(12px, 1.2vw, 20px);
}

.player-badge button {
  margin-left: auto;
  border: 0;
  border-radius: 999px;
  padding: 0.45vw 0.7vw;
  background: linear-gradient(180deg, #ff72b0, #e53689);
  color: #fff;
  box-shadow: 0 0.22vw 0 #bd2d75;
  cursor: pointer;
  font-weight: 950;
  font-size: clamp(8px, 0.72vw, 12px);
  line-height: 1;
  white-space: nowrap;
}

.character-hotspot,
.play-hotspot,
.back-hotspot,
.diagnostic-hotspot {
  position: absolute;
  border: 0;
  padding: 0;
  border-radius: 22px;
  background: transparent;
  cursor: pointer;
  color: transparent;
}

.character-hotspot {
  transform: translateZ(0);
}

.character-hotspot:focus-visible {
  outline: 4px solid rgba(255, 255, 255, 0.94);
  outline-offset: -4px;
}

.play-hotspot {
  z-index: 120;
  left: 72.9%;
  top: 89.7%;
  width: 24.1%;
  height: 8.9%;
  border-radius: 999px;
  pointer-events: auto;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.back-hotspot {
  z-index: 37;
  left: 2.55%;
  top: 4.1%;
  width: 7.7%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
}

.diagnostic-hotspot {
  z-index: 37;
  right: 1.5%;
  bottom: 1.2%;
  width: auto;
  height: auto;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.45);
  color: rgba(96, 35, 78, 0.72);
  font-size: 10px;
  font-weight: 800;
}

.menu-hidden-status {
  position: absolute;
  overflow: hidden;
  width: 1px;
  height: 1px;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (max-width: 860px) {
  .selected-marker {
    width: 6.1%;
  }

  .menu-stars {
    font-size: clamp(14px, 3vw, 30px);
  }

  .player-badge {
    left: 12%;
    min-width: 24%;
    max-width: 36%;
    padding: 0.7vw 1vw;
  }

  .player-badge strong {
    max-width: 12vw;
  }
}

/* v0.2.5 — cadastro e ranking */
.register-panel {
  width: min(520px, 92vw);
  max-height: 92dvh;
  overflow: auto;
}

.register-field {
  display: block;
  margin: 10px 0;
  text-align: left;
}

.register-field span {
  display: block;
  margin: 0 0 5px;
  color: #6d3078;
  font-weight: 900;
  font-size: 0.86rem;
}

.register-field input {
  width: 100%;
  box-sizing: border-box;
  border: 3px solid rgba(248, 111, 176, 0.45);
  border-radius: 18px;
  padding: 13px 15px;
  font: inherit;
  font-weight: 800;
  color: #6b246e;
  background: #fff;
  outline: none;
}

.register-field input:focus {
  border-color: #f74ea4;
  box-shadow: 0 0 0 4px rgba(247, 78, 164, 0.15);
}

.register-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 12px 0 16px;
  text-align: left;
  color: #6d3078;
  font-weight: 800;
  font-size: 0.9rem;
}

.register-consent input {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  accent-color: #f74ea4;
}

.ranking-status {
  margin: 12px 0 8px;
  color: #6d3078;
  font-weight: 900;
}

.ranking-preview {
  display: grid;
  gap: 6px;
  margin: 8px 0 14px;
  text-align: left;
}

.ranking-preview div {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 7px 10px;
  border-radius: 14px;
  background: rgba(255, 235, 249, 0.9);
  color: #6d3078;
  font-weight: 800;
}

.ranking-preview strong {
  color: #f3469d;
}

.ranking-preview b {
  color: #4c2591;
}

@media (max-width: 760px) and (orientation: landscape) {
  .register-panel {
    width: min(520px, 86vw);
    padding: 14px 18px;
  }

  .register-panel h2 {
    font-size: 1.3rem;
    margin: 4px 0;
  }

  .register-field {
    margin: 6px 0;
  }

  .register-field input {
    padding: 9px 12px;
    border-radius: 14px;
  }
}

/* v0.2.6 — cadastro validado */
.register-field input,
.register-field select {
  width: 100%;
  box-sizing: border-box;
  border: 3px solid rgba(248, 111, 176, 0.45);
  border-radius: 18px;
  padding: 13px 15px;
  font: inherit;
  font-weight: 800;
  color: #6b246e;
  background: #fff;
  outline: none;
}

.register-field input:focus,
.register-field select:focus {
  border-color: #f74ea4;
  box-shadow: 0 0 0 4px rgba(247, 78, 164, 0.15);
}

.field-hint {
  display: block;
  margin-top: 4px;
  color: #85558a;
  font-size: 0.75rem;
  font-weight: 700;
}

.other-city-fields {
  display: grid;
  grid-template-columns: 1fr 88px;
  gap: 10px;
}

.other-city-fields.is-hidden {
  display: none;
}

@media (max-width: 760px) and (orientation: landscape) {
  .register-field input,
  .register-field select {
    padding: 9px 12px;
    border-radius: 14px;
  }
}

/* v0.3.1 — Identidade visual do Mundo 1 */
.hud-world{display:flex;align-items:center;gap:8px;padding:8px 14px;border-radius:999px;background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(255,226,241,.94));border:3px solid rgba(255,255,255,.92);box-shadow:0 8px 18px rgba(102,47,112,.22);color:#7f2f86;font-size:13px;letter-spacing:.04em;white-space:nowrap}.hud-world span{font-size:18px}.hud-world strong{font-weight:900}@media(max-width:760px){.hud-world{padding:6px 10px;font-size:10px;gap:5px}.hud-world span{font-size:14px}}


/* v0.3.3 — Perfil do jogador e ranking completo */
.menu-gamification-actions { position:absolute; right:2.2%; bottom:2.4%; z-index:8; display:flex; gap:10px; }
.menu-gamification-actions button { border:2px solid rgba(255,255,255,.9); border-radius:999px; padding:10px 16px; background:linear-gradient(135deg,#ff4f9d,#db2f7f); color:#fff; font-weight:900; box-shadow:0 6px 18px rgba(109,21,70,.28); cursor:pointer; font-size:clamp(10px,1.15vw,15px); }
.menu-gamification-actions button:last-child { background:linear-gradient(135deg,#ffbd35,#f28a22); }
.profile-panel,.ranking-full-panel { width:min(720px,92vw); max-height:88vh; overflow:auto; }
.profile-avatar { width:82px;height:82px;border-radius:50%;display:grid;place-items:center;margin:0 auto 10px;font-size:40px;background:linear-gradient(145deg,#ffe1f0,#fff);box-shadow:0 10px 30px rgba(219,47,127,.2); }
.profile-stat-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:18px 0; }
.profile-stat-grid div { padding:14px;border-radius:18px;background:#fff5fa;border:1px solid #ffd0e4; }
.profile-stat-grid span { display:block;font-size:11px;font-weight:800;color:#a54b78; }
.profile-stat-grid strong { display:block;font-size:25px;color:#d82c7d; }
.profile-character { font-weight:800;color:#7a3b61; }
.full-ranking-list { display:grid;gap:8px;margin:14px 0 18px; }
.full-ranking-row { display:grid;grid-template-columns:58px minmax(120px,1fr) minmax(80px,.7fr) 90px;align-items:center;gap:8px;padding:10px 12px;border-radius:14px;background:#fff;border:1px solid #f3d6e4;text-align:left; }
.full-ranking-row strong { font-size:18px;text-align:center; }
.full-ranking-row span { font-weight:900;color:#6b3153;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
.full-ranking-row small { color:#967086;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
.full-ranking-row b { color:#d82c7d;text-align:right; }
.full-ranking-row.is-current-player { background:#fff1b8;border-color:#f7b733;box-shadow:0 0 0 2px rgba(247,183,51,.18); }
@media (max-width:760px){.menu-gamification-actions{right:1.5%;bottom:1.5%;gap:6px}.menu-gamification-actions button{padding:7px 10px;font-size:9px}.full-ranking-row{grid-template-columns:44px 1fr 70px}.full-ranking-row small{display:none}.profile-stat-grid{gap:8px}.profile-stat-grid div{padding:10px}}

/* v0.4.0 — Responsive UI hardening: protected interaction zones */
.character-select-screen { overflow: hidden; }
.play-hotspot { z-index: 60 !important; touch-action: manipulation; }
.menu-gamification-actions {
  right: 1.6% !important;
  top: 2.1% !important;
  bottom: auto !important;
  max-width: 28%;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.player-badge {
  left: 1.8% !important;
  top: 2.2% !important;
  bottom: auto !important;
  max-width: 25%;
}
.project-footer { position: relative; z-index: 2; }
.character-select-screen ~ * { pointer-events: auto; }

@media (max-width: 1024px) and (orientation: landscape) {
  .menu-gamification-actions { top: 1.2% !important; right: 1.2% !important; gap: 5px; max-width: 34%; }
  .menu-gamification-actions button { padding: 6px 9px !important; font-size: 8.5px !important; }
  .player-badge { left: 1.2% !important; top: 1.2% !important; max-width: 28%; padding: 5px 8px !important; }
  .player-badge span { display: none; }
  .player-badge strong { font-size: 10px !important; }
  .player-badge button { font-size: 8px !important; padding: 4px 7px !important; }
  .project-footer { display: none !important; }
  .mobile-project-links { display: flex !important; position: fixed; left: env(safe-area-inset-left, 0); right: env(safe-area-inset-right, 0); bottom: env(safe-area-inset-bottom, 0); z-index: 80; justify-content: center; gap: 8px; padding: 5px 8px; pointer-events: none; }
  .mobile-project-links a { pointer-events: auto; font-size: 9px !important; padding: 5px 9px !important; border-radius: 999px; }
}

@media (max-width: 760px) and (orientation: landscape) {
  .menu-gamification-actions { max-width: 31%; }
  .menu-gamification-actions button { font-size: 7.5px !important; padding: 5px 7px !important; }
  .player-badge { max-width: 24%; }
}


/* v0.4.1 — Runtime fix + collision-free responsive control zones */
.player-badge {
  left: 12.8% !important;
  top: 1.8% !important;
  bottom: auto !important;
  max-width: 18% !important;
  z-index: 72 !important;
  white-space: nowrap;
}
.menu-gamification-actions {
  right: 17.5% !important;
  top: 1.8% !important;
  bottom: auto !important;
  max-width: 18% !important;
  flex-wrap: nowrap !important;
  z-index: 72 !important;
}
.menu-gamification-actions button {
  padding: 8px 11px !important;
  font-size: clamp(9px, .82vw, 12px) !important;
  white-space: nowrap;
}
.menu-stars { z-index: 75 !important; }
.play-hotspot { z-index: 90 !important; }
.back-hotspot { z-index: 90 !important; }
.character-hitboxes { z-index: 30 !important; }
.selected-marker { z-index: 45 !important; pointer-events: none !important; }

@media (max-width: 1024px) and (orientation: landscape) {
  .app-shell {
    gap: 4px !important;
    align-content: center;
    padding-top: max(4px, env(safe-area-inset-top)) !important;
    padding-bottom: max(4px, env(safe-area-inset-bottom)) !important;
  }
  .game-card {
    width: min(1280px, calc(100vw - 8px), calc((100dvh - 42px) * 16 / 9)) !important;
  }
  .player-badge {
    left: 12.2% !important;
    top: 1.0% !important;
    max-width: 18.5% !important;
    padding: 4px 6px !important;
    gap: 4px !important;
  }
  .player-badge span { display: none !important; }
  .player-badge strong {
    max-width: 70px;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 9px !important;
  }
  .player-badge button {
    width: 28px !important;
    min-width: 28px !important;
    height: 28px !important;
    padding: 0 !important;
    font-size: 0 !important;
    border-radius: 50% !important;
  }
  .player-badge button::after { content: "↻"; font-size: 16px; line-height: 1; }

  .menu-gamification-actions {
    right: 17.3% !important;
    top: .9% !important;
    max-width: none !important;
    gap: 5px !important;
  }
  .menu-gamification-actions button {
    width: 34px !important;
    min-width: 34px !important;
    height: 34px !important;
    padding: 0 !important;
    font-size: 0 !important;
    border-radius: 50% !important;
  }
  .menu-gamification-actions button:first-child::after { content: "👤"; font-size: 16px; }
  .menu-gamification-actions button:last-child::after { content: "🏆"; font-size: 16px; }

  .project-footer { display: none !important; }
  .mobile-project-links {
    display: flex !important;
    position: static !important;
    width: min(760px, calc(100vw - 12px));
    min-height: 28px;
    justify-content: center;
    gap: 6px;
    padding: 0 !important;
    pointer-events: auto !important;
    z-index: 2 !important;
  }
  .mobile-project-links a {
    flex: 1 1 0;
    max-width: 360px;
    min-height: 26px !important;
    padding: 4px 8px !important;
    border-radius: 999px !important;
    font-size: 8px !important;
    line-height: 1.05;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

@media (max-width: 760px) and (orientation: landscape) {
  .game-card {
    width: min(1280px, calc(100vw - 6px), calc((100dvh - 38px) * 16 / 9)) !important;
  }
  .player-badge { left: 11.8% !important; max-width: 17.5% !important; }
  .player-badge strong { max-width: 52px; font-size: 8px !important; }
  .player-badge button { width: 25px !important; min-width: 25px !important; height: 25px !important; }
  .menu-gamification-actions { right: 17.0% !important; }
  .menu-gamification-actions button { width: 30px !important; min-width: 30px !important; height: 30px !important; }
  .mobile-project-links a { font-size: 7px !important; }
}

/* v0.5.0 — Premium Experience */
.premium-intro,
.premium-home {
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 18%, rgba(255,255,255,.95), transparent 24%),
    radial-gradient(circle at 82% 18%, rgba(255,220,241,.95), transparent 30%),
    linear-gradient(145deg, #fff8fc 0%, #ffd7ea 48%, #f6b7dd 100%);
}

.premium-intro::before,
.premium-home::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .55;
  background-image: radial-gradient(circle, rgba(255,255,255,.95) 0 2px, transparent 3px);
  background-size: 72px 72px;
  animation: sparkleDrift 12s linear infinite;
}

.intro-skip {
  position: absolute;
  z-index: 4;
  top: max(16px, env(safe-area-inset-top));
  right: max(16px, env(safe-area-inset-right));
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 999px;
  padding: 9px 15px;
  background: rgba(143,36,95,.72);
  color: #fff;
  font-weight: 900;
  letter-spacing: .12em;
  cursor: pointer;
}

.intro-copy {
  position: relative;
  z-index: 2;
  width: min(58%, 650px);
  margin-right: 28%;
  animation: introCopy 900ms ease both;
}

.intro-seal { font-size: clamp(48px, 7vw, 92px); }
.intro-copy > p { margin: 4px 0; color: var(--pink-900); font-weight: 950; letter-spacing: .18em; }
.intro-copy h1,
.home-brand h1 { margin: 5px 0; color: #9e2867; font-size: clamp(52px, 8vw, 112px); line-height: .82; letter-spacing: -.06em; }
.intro-copy h1 strong,
.home-brand h1 strong { color: #f04f9c; font-weight: 950; }
.intro-copy blockquote { margin: 24px auto 0; max-width: 520px; color: #63374f; font-size: clamp(15px, 1.8vw, 24px); font-weight: 750; line-height: 1.35; }
.intro-jubinha { position: absolute; z-index: 2; right: 7%; bottom: -4%; height: 88%; object-fit: contain; filter: drop-shadow(0 24px 28px rgba(105,35,72,.24)); animation: jubinhaEnter 1.2s .25s cubic-bezier(.2,.9,.2,1) both; }

.home-content { position: relative; z-index: 2; width: 100%; height: 100%; display: grid; grid-template-columns: 1.1fr .7fr .9fr; align-items: center; gap: clamp(12px, 3vw, 38px); padding: clamp(22px, 4vw, 58px); }
.home-brand { text-align: left; }
.home-kicker { color: var(--pink-900); font-size: clamp(10px, 1.2vw, 16px); font-weight: 950; letter-spacing: .2em; }
.home-brand p { margin: 18px 0 0; max-width: 460px; color: #63374f; font-size: clamp(14px, 1.55vw, 21px); font-weight: 700; line-height: 1.35; }
.home-jubinha { width: 100%; max-height: 82%; object-fit: contain; filter: drop-shadow(0 24px 24px rgba(105,35,72,.22)); animation: gentleFloat 3.2s ease-in-out infinite; }
.home-actions { display: grid; gap: 10px; }
.home-button { min-height: clamp(44px, 5vw, 62px); padding: 10px 18px; border: 2px solid rgba(255,255,255,.92); border-radius: 18px; background: linear-gradient(180deg, rgba(255,255,255,.96), rgba(255,235,246,.94)); color: var(--pink-900); box-shadow: 0 8px 0 rgba(177,54,116,.16), 0 14px 24px rgba(104,35,73,.12); cursor: pointer; font-weight: 950; letter-spacing: .06em; text-align: left; transition: transform .14s ease, filter .14s ease; }
.home-button:hover { transform: translateY(-2px); filter: brightness(1.03); }
.home-button--primary { background: linear-gradient(180deg, #ff86be, #e84b97); color: white; box-shadow: 0 8px 0 #b93676, 0 18px 28px rgba(177,54,116,.22); font-size: 1.1em; }

.credits-avatar { width: 88px; height: 88px; display: grid; place-items: center; margin: 8px auto 12px; border-radius: 50%; background: linear-gradient(145deg,#ff86be,#b93676); color:#fff; font-size: 28px; font-weight: 950; box-shadow: var(--soft-shadow); }
.credits-panel a { display: inline-block; margin: 4px 0 18px; color: var(--pink-700); font-weight: 900; }
.credits-institute { padding: 13px; border-radius: 16px; background: var(--pink-100); font-weight: 750; }
.setting-row { display:flex; justify-content:space-between; align-items:center; gap:20px; margin:10px 0; padding:16px 18px; border-radius:18px; background:#fff; border:1px solid rgba(200,63,130,.12); font-weight:850; text-align:left; }
.setting-row input { width:24px; height:24px; accent-color:var(--pink-600); }
.purpose-copy { max-height: 220px; overflow:auto; padding: 14px 16px; border-radius:18px; background:#fff; color:#68475a; text-align:left; line-height:1.45; }
.purpose-copy p { margin: 0 0 10px; }
.reduced-effects .premium-intro::before,
.reduced-effects .premium-home::before,
.reduced-effects .home-jubinha { animation: none !important; }

@keyframes sparkleDrift { to { background-position: 72px 72px; } }
@keyframes jubinhaEnter { from { opacity:0; transform:translateX(90px) scale(.94); } to { opacity:1; transform:none; } }
@keyframes introCopy { from { opacity:0; transform:translateY(20px); } to { opacity:1; transform:none; } }
@keyframes gentleFloat { 50% { transform:translateY(-10px) rotate(-.5deg); } }

@media (max-width: 920px) and (orientation: landscape) {
  .home-content { grid-template-columns: 1fr .55fr .95fr; padding: 18px 28px; gap: 16px; }
  .home-brand p { margin-top: 8px; }
  .home-actions { gap: 6px; }
  .home-button { min-height: 38px; padding: 7px 12px; border-radius: 14px; font-size: 11px; }
}

@media (orientation: portrait) and (max-width: 820px) {
  .intro-copy { width: 90%; margin: -40% 0 0; }
  .intro-jubinha { right: 16%; height: 54%; bottom: 0; }
  .home-content { grid-template-columns: 1fr; grid-template-rows: auto minmax(150px, .75fr) auto; gap: 6px; padding: max(18px,env(safe-area-inset-top)) 18px max(18px,env(safe-area-inset-bottom)); }
  .home-brand { text-align:center; }
  .home-brand h1 { font-size: clamp(44px, 15vw, 76px); }
  .home-brand p { margin: 8px auto 0; font-size: 13px; }
  .home-jubinha { max-height: 100%; margin:auto; }
  .home-actions { grid-template-columns: 1fr 1fr; width:100%; gap:7px; }
  .home-button { min-height: 48px; padding:8px 10px; border-radius:14px; font-size:10px; text-align:center; }
  .home-button--primary { grid-column: 1 / -1; }
}


/* v0.5.1 hotfixes */
.panel { position: relative; }
.panel-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 5;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(192, 58, 126, .18);
  border-radius: 999px;
  background: rgba(255,255,255,.9);
  color: var(--pink-800);
  font-size: 28px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(104,35,73,.1);
}
.panel-close:hover { filter: brightness(1.02); }
.floating-sound-button {
  position: absolute;
  z-index: 45;
  top: max(14px, env(safe-area-inset-top));
  right: max(14px, env(safe-area-inset-right));
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.9);
  background: rgba(143,36,95,.86);
  color: #fff;
  font-size: 24px;
  box-shadow: 0 12px 28px rgba(104,35,73,.22);
  cursor: pointer;
}
.floating-sound-button.is-muted { background: rgba(108, 88, 99, .84); }
.intro-split {
  position: absolute;
  z-index: 2;
  right: 4%;
  bottom: 0;
  width: min(38vw, 520px);
  height: min(86%, 700px);
  display: grid;
  place-items: end center;
  filter: drop-shadow(0 24px 30px rgba(105,35,72,.24));
}
.intro-split::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 46%, rgba(255,255,255,0) 0 31%, rgba(252, 210, 231, .95) 32% 42%, rgba(247, 188, 220, .92) 43% 100%);
  clip-path: polygon(47% 0%, 56% 8%, 72% 6%, 66% 20%, 84% 27%, 73% 38%, 92% 50%, 74% 60%, 84% 76%, 66% 79%, 60% 100%, 47% 88%, 34% 100%, 28% 79%, 10% 76%, 20% 61%, 0% 50%, 20% 39%, 11% 25%, 30% 22%, 35% 8%);
  opacity: .9;
}
.intro-split::after {
  content: "";
  position: absolute;
  inset: 15% 12% 12%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, rgba(255,255,255,.18), rgba(255,255,255,0) 62%);
  mix-blend-mode: screen;
}
.intro-jubinha { position: absolute; z-index: 2; left: 50%; bottom: 2%; width: auto; height: 90%; max-width: 120%; transform: translateX(-46%); object-fit: contain; animation: jubinhaEnter 1.15s .22s cubic-bezier(.2,.9,.2,1) both; }
@media (orientation: portrait) and (max-width: 820px) {
  .intro-copy { width: calc(100% - 24px); margin: 0 auto; padding-top: 54px; }
  .intro-copy h1 { font-size: clamp(42px, 13vw, 68px); }
  .intro-copy blockquote { margin-top: 10px; font-size: 14px; }
  .intro-split { right: 50%; transform: translateX(50%); bottom: 0; width: min(78vw, 350px); height: min(47vh, 380px); }
  .intro-jubinha { height: 96%; transform: translateX(-48%); }
  .intro-skip, .floating-sound-button { top: max(10px, env(safe-area-inset-top)); }
  .floating-sound-button { right: max(72px, calc(env(safe-area-inset-right) + 56px)); }
}


/* v0.5.2 art integration */
.credits-verse {
  margin: 10px 0 6px;
  color: var(--pink-800);
  font-weight: 900;
  letter-spacing: .08em;
}
.intro-split {
  position: absolute;
  z-index: 2;
  right: 4%;
  bottom: 0;
  width: min(40vw, 560px);
  height: min(86%, 720px);
  display: grid;
  place-items: end center;
  filter: drop-shadow(0 24px 30px rgba(105,35,72,.22));
}
.intro-split::before,
.intro-split::after { content: none !important; }
.intro-split-art {
  width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
  animation: jubinhaEnter 1.15s .22s cubic-bezier(.2,.9,.2,1) both, gentleFloat 4s 1.5s ease-in-out infinite;
}
.poses-showcase {
  margin: 14px 0 18px;
  padding: 14px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,.98), rgba(255,243,249,.98));
  border: 1px solid rgba(228, 97, 156, .24);
  box-shadow: 0 0 0 3px rgba(255,255,255,.7), 0 0 34px rgba(244, 98, 160, .18), 0 18px 30px rgba(104,35,73,.12);
}
.poses-showcase-title {
  margin: 0 0 10px;
  color: var(--pink-700);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.poses-showcase img {
  width: 100%;
  display: block;
  border-radius: 16px;
  box-shadow: 0 0 0 1px rgba(239, 145, 187, .25), 0 10px 24px rgba(130, 52, 87, .12), 0 0 36px rgba(255, 148, 204, .16);
}
@media (orientation: portrait) and (max-width: 820px) {
  .intro-copy { width: calc(100% - 28px); margin: 0 auto; padding-top: 56px; }
  .intro-split { right: 50%; transform: translateX(50%); bottom: 0; width: min(82vw, 390px); height: min(44vh, 360px); }
  .intro-split-art { width: 100%; max-height: 100%; }
}
