/* Valhalla Bound */
.vb { --vb-gold: #e0a83a; --vb-cyan: #00f0ff; --vb-ash: #8a97a3; --vb-frost: #e6f4ff; position: relative; max-width: 960px; margin: 1.5rem auto; outline: none; color: var(--vb-frost); font-family: system-ui, sans-serif; }
.vb-stage { position: relative; border: 1px solid rgba(0, 240, 255, 0.35); border-radius: 8px; overflow: hidden; background: #05070a; box-shadow: 0 0 24px rgba(0, 240, 255, 0.12); }
.vb-canvas { display: block; width: 100%; aspect-ratio: 320 / 200; image-rendering: pixelated; image-rendering: crisp-edges; touch-action: none; cursor: crosshair; }
.vb-hint { position: absolute; top: 0.6rem; left: 50%; transform: translateX(-50%); max-width: calc(100% - 1.5rem); padding: 0.35rem 0.8rem; border: 1px solid rgba(224, 168, 58, 0.5); border-radius: 6px; background: rgba(5, 7, 10, 0.85); color: var(--vb-gold); font-size: clamp(0.72rem, 2vw, 0.9rem); text-align: center; pointer-events: none; opacity: 0; transition: opacity 0.4s; }
.vb-hint.show { opacity: 1; }
.vb-overlay { position: absolute; inset: 0; display: none; flex-direction: column; align-items: center; justify-content: safe center; overflow: hidden; gap: 0.7rem; padding: 1rem; text-align: center; background: rgba(5, 7, 10, 0.78); }
.vb-overlay.show { display: flex; }
.vb-title { margin: 0; font-family: Georgia, 'Times New Roman', serif; font-size: clamp(1.3rem, 4vw, 2.2rem); color: var(--vb-frost); text-shadow: 0 0 10px rgba(0, 240, 255, 0.6); }
.vb-sub { margin: 0; max-width: 36rem; color: var(--vb-ash); font-size: clamp(0.8rem, 2.2vw, 1rem); }
.vb-keys { margin: 0; color: var(--vb-ash); font-family: monospace; font-size: 0.72rem; }
.vb-levels { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.5rem; width: min(100%, 30rem); flex: 0 1 auto; min-height: 3.5rem; overflow-y: auto; padding: 0.25rem 0.4rem 0.25rem 0.25rem; scrollbar-width: thin; scrollbar-color: rgba(224, 168, 58, 0.6) transparent; overscroll-behavior: contain; }
.vb-levels.vb-more { -webkit-mask-image: linear-gradient(to bottom, #000 80%, transparent); mask-image: linear-gradient(to bottom, #000 80%, transparent); }
.vb-levels::-webkit-scrollbar { width: 6px; }
.vb-levels::-webkit-scrollbar-thumb { background: rgba(224, 168, 58, 0.6); border-radius: 3px; }
.vb-title, .vb-sub, .vb-keys { flex: 0 0 auto; }
@media (max-width: 599px) { .vb-overlay { gap: 0.4rem; padding: 0.6rem; } .vb-sub { display: none; } .vb-keys { display: none; } .vb-level { padding: 0.35rem 0.5rem; } }
.vb-level { display: grid; grid-template-columns: 1.8rem 1fr; grid-template-rows: auto auto; align-items: center; gap: 0 0.5rem; padding: 0.5rem 0.7rem; border: 1px solid rgba(224, 168, 58, 0.5); border-radius: 6px; background: rgba(224, 168, 58, 0.06); color: var(--vb-frost); text-align: left; cursor: pointer; font: inherit; }
.vb-level:hover:not(:disabled), .vb-level:focus-visible { border-color: var(--vb-gold); box-shadow: 0 0 12px rgba(224, 168, 58, 0.35); }
.vb-level:disabled { opacity: 0.4; cursor: not-allowed; }
.vb-level { position: relative; }
.vb-level-n { grid-row: span 2; font-family: monospace; font-size: 1.2rem; color: var(--vb-gold); }
.vb-level-name { font-weight: 600; font-size: 0.9rem; }
.vb-level-best { font-family: monospace; font-size: 0.7rem; color: var(--vb-ash); }
.vb-row { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; }
.vb-hud { display: flex; justify-content: space-between; gap: 1rem; margin-top: 0.5rem; font-family: monospace; font-size: 0.78rem; color: var(--vb-ash); min-height: 1.2em; }
.vb-bar { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.5rem; align-items: stretch; }
.vb-skill { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 0.35rem; flex: 1 1 7.5rem; padding: 0.45rem 0.6rem; border: 1px solid rgba(0, 240, 255, 0.35); border-radius: 6px; background: rgba(5, 7, 10, 0.8); color: var(--vb-frost); font: inherit; font-size: 0.82rem; cursor: pointer; }
.vb-skill:hover:not(:disabled), .vb-skill:focus-visible { border-color: var(--vb-cyan); }
.vb-skill.sel { border-color: var(--vb-gold); background: rgba(224, 168, 58, 0.14); box-shadow: 0 0 12px rgba(224, 168, 58, 0.35); }
.vb-skill:disabled { opacity: 0.35; cursor: default; }
.vb-skill-rune { font-size: 1.15rem; color: var(--vb-gold); line-height: 1; }
.vb-skill-name { text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vb-skill-n { min-width: 1.4em; padding: 0 0.3em; border-radius: 999px; background: rgba(0, 240, 255, 0.12); color: var(--vb-cyan); font-family: monospace; text-align: center; }
.vb-ctl { display: flex; gap: 0.4rem; }
.vb-btn { min-width: 2.6rem; padding: 0.45rem 0.6rem; border: 1px solid rgba(0, 240, 255, 0.35); border-radius: 6px; background: rgba(5, 7, 10, 0.8); color: var(--vb-frost); font: inherit; cursor: pointer; }
.vb-btn:hover, .vb-btn:focus-visible { border-color: var(--vb-cyan); }
.vb-btn.on { border-color: var(--vb-gold); color: var(--vb-gold); }
.vb-btn.wide { padding: 0.55rem 1.1rem; }
.vb-btn.gold { border-color: var(--vb-gold); color: var(--vb-gold); }
@media (max-width: 599px) { .vb-skill { flex-basis: 30%; } .vb-skill-name { display: none; } .vb-ctl { flex: 1 1 100%; justify-content: center; } }
.vb a.vb-btn { display: inline-block; text-decoration: none; }
.vb-flag { margin: 0; color: var(--vb-frost); }
.vb-flag code { padding: 0.15rem 0.45rem; border: 1px solid var(--vb-gold); border-radius: 4px; color: var(--vb-gold); font-family: monospace; user-select: all; }
.vb-level-hidden { border-color: var(--vb-cyan); background: rgba(0, 240, 255, 0.08); }
.vb-level-hidden .vb-level-n { color: var(--vb-cyan); }
/* Full screen (0.10.5): real fullscreen where allowed, otherwise the game fills the window */
html.vb-noscroll, html.vb-noscroll body { overflow: hidden; }
.vb.vb-max { position: fixed; inset: 0; z-index: 2147483000; max-width: none; margin: 0; padding: max(0.5rem, env(safe-area-inset-top)) max(0.5rem, env(safe-area-inset-right)) max(0.5rem, env(safe-area-inset-bottom)) max(0.5rem, env(safe-area-inset-left)); background: #05070a; display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
.vb.vb-max .vb-stage { width: min(100%, calc((100dvh - 7.5rem) * 1.6)); margin: 0 auto; flex: 0 0 auto; }
.vb.vb-max .vb-hud, .vb.vb-max .vb-bar { width: min(100%, 60rem); margin-left: auto; margin-right: auto; }
.vb:fullscreen { width: 100%; height: 100%; }
@media (orientation: landscape) and (max-height: 520px) {
  .vb.vb-max { display: grid; grid-template-columns: minmax(0, 1fr) 9.5rem; grid-template-rows: auto 1fr; gap: 0.4rem 0.6rem; align-items: start; }
  .vb.vb-max .vb-stage { grid-row: 1 / span 2; width: min(100%, calc((100dvh - 1rem) * 1.6)); align-self: center; justify-self: center; }
  .vb.vb-max .vb-hud { grid-column: 2; margin: 0; width: auto; font-size: 0.68rem; }
  .vb.vb-max .vb-bar { grid-column: 2; margin: 0; width: auto; flex-direction: column; flex-wrap: nowrap; gap: 0.3rem; overflow-y: auto; max-height: calc(100dvh - 4rem); }
  .vb.vb-max .vb-skill { flex: 0 0 auto; padding: 0.3rem 0.5rem; }
  .vb.vb-max .vb-skill-name { display: inline; font-size: 0.75rem; }
  .vb.vb-max .vb-ctl { flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-start; }
  .vb.vb-max .vb-btn { min-width: 2.2rem; padding: 0.3rem 0.4rem; }
}
.vb-rotate { display: none; margin: 0.8rem 0 0; text-align: center; color: var(--vb-gold); font-size: 0.85rem; }
@media (orientation: portrait) and (max-width: 700px) { .vb.vb-max .vb-rotate { display: block; } }
.vb-medal { font-size: 0.9rem; line-height: 1; }
.vb-level .vb-medal { position: absolute; top: 0.45rem; right: 0.55rem; }
.vb-medal-bronze { color: #cd7f32; text-shadow: 0 0 6px rgba(205, 127, 50, 0.6); }
.vb-medal-silver { color: #d6dde4; text-shadow: 0 0 6px rgba(214, 221, 228, 0.6); }
.vb-medal-gold { color: #f2c14e; text-shadow: 0 0 8px rgba(242, 193, 78, 0.8); }
.vb-medal-line { margin: 0; color: var(--vb-frost); font-size: 0.95rem; }
.vb-btn:disabled { opacity: 0.35; cursor: default; }
