/* Pirates Gold Game Mode */
.pg-game-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(200,150,80,.28);
  border-radius: 999px;
  background: rgba(18,12,8,.48);
  color: #ead9b5;
  backdrop-filter: blur(16px) saturate(130%);
  -webkit-backdrop-filter: blur(16px) saturate(130%);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: .76rem;
  cursor: pointer;
}
.pg-game-toggle.is-active {
  color: #111;
  background: linear-gradient(180deg, #e5c98b, #b98a45);
}
body.pg-game-mode {
  overflow: hidden !important;
}
body.pg-game-mode .pg-map-stage {
  height: 100vh !important;
  min-height: 100vh !important;
}

body.pg-game-mode .pg-map-bg img {
    height: auto;
}
body.pg-game-mode .pg-map-stage {
    overflow: hidden;
}
body.pg-game-mode {
    overflow: hidden !important;
}

body.pg-game-mode .pg-home-shell {
    min-height: auto;
    overflow: hidden;
}
body.pg-game-mode .pg-scene {
    min-height: auto;
    overflow: hidden;
}
body.pg-game-mode .site-footer {
	display: none;
}	

body.pg-game-mode .pg-map-overlay {
  height: 100vh !important;
}
body.pg-game-mode .pg-route-svg,
body.pg-game-mode .pg-island,
body.pg-game-mode .pg-treasure,
body.pg-game-mode .pg-decor--octopus,
body.pg-game-mode .pg-decor--whale,
body.pg-game-mode .pg-decor--small-ship,
body.pg-game-mode .pg-decor--lantern{
  display: none !important;
}
.pg-scoreboard {
  display: none;
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(200,150,80,.22);
  background: rgba(18,12,8,.34);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: #ead9b5;
}
body.pg-game-mode .pg-scoreboard {
  display: block;
}
body.pg-game-mode .pg-route-nav,
body.pg-game-mode .pg-left-sidebar__compass {
  display: none !important;
}
.pg-scoreboard h2 {
  margin: 0 0 14px;
  color: #f5e6c7;
  text-transform: uppercase;
  line-height: 1;
}
.pg-scoreboard__row {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 7px 0;
  border-bottom: 1px solid rgba(200,150,80,.12);
}
.pg-scoreboard__hint {
  margin-top: 14px;
  color: rgba(234,217,181,.72);
  font-size: .84rem;
  line-height: 1.4;
}
.pg-game-layer {
  position: fixed;
  inset: 72px 0 0;
  z-index: 27;
  pointer-events: auto;
  overflow: hidden;
}
.pg-game-object {
  position: absolute;
  left: 0;
  top: 0;
  width: 90px;
  height: 90px;
  transform: translate(-50%, -50%);
  pointer-events: none;
  will-change: transform, opacity;
  filter: drop-shadow(0 12px 18px rgba(0,0,0,.32));
}
.pg-game-object img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.pg-game-object--collect {
  filter: drop-shadow(0 0 14px rgba(231,180,83,.6));
}
.pg-game-object--ghost {
  width: 150px;
  height: 110px;
  opacity: .7;
  mix-blend-mode: screen;
  filter: blur(.25px) drop-shadow(0 0 18px rgba(160,240,220,.45));
}
.pg-game-flash {
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  background: rgba(255,255,255,.15);
  opacity: 0;
}
body.pg-game-mode .pg-ship {
  z-index: 45 !important;
}
@media (max-width: 900px) {
  .pg-game-toggle { font-size: .6rem; padding: 0 5px; }
  .pg-game-object { width: 72px; height: 72px; }
  .pg-game-object--ghost { width: 120px; height: 88px; }
}

@media (max-width: 768px) {
  .pg-game-object {
    width: 52px !important;
    height: 52px !important;
  }

  .pg-game-object--ghost {
    width: 88px !important;
    height: 64px !important;
  }

  body.pg-game-mode .pg-ship {
    width: 76px !important;
  }
}

@media (max-width: 768px) {
  .pg-game-layer {
    inset: 72px 0 0 0;
    width: 100vw;
    height: calc(100vh - 72px);
  }

  body.pg-game-mode .pg-map-stage,
  body.pg-game-mode .pg-map-overlay {
    width: 100vw !important;
    height: 100vh !important;
    min-height: 100vh !important;
    overflow: hidden;
  }
}

.pg-game-hud {
  position: fixed;
  top: 84px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 80;
  display: none;
  align-items: center;
  gap: 18px;
  padding: 10px 16px;
  border: 1px solid rgba(200,150,80,.25);
  border-radius: 999px;
  background: rgba(18,12,8,.48);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  color: #ead9b5;
  box-shadow: 0 12px 34px rgba(0,0,0,.35);
}

body.pg-game-mode .pg-game-hud {
  display: flex;
}

.pg-game-hud__item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  white-space: nowrap;
}

.pg-game-hud__value {
  color: #f5d27a;
  font-weight: 700;
}

.pg-game-lives {
  display: flex;
  gap: 4px;
}

.pg-game-life {
  width: 22px;
  height: 22px;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.45));
}

@media (max-width: 768px) {
  .pg-game-hud {
    top: 76px;
    gap: 10px;
    padding: 8px 10px;
    max-width: calc(100vw - 16px);
  }

  .pg-game-hud__item {
    font-size: .68rem;
    letter-spacing: .04em;
  }

  .pg-game-life {
    width: 18px;
    height: 18px;
  }
}

body.pg-game-mode .pg-game-layer {
  pointer-events: auto;
  touch-action: none;
}

.pg-splash-particle {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(220, 245, 255, .75);
  pointer-events: none;
  z-index: 90;
  filter: blur(.4px);
}

.pg-game-over {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(8px);
}

body.pg-game-over-active .pg-game-over {
  display: flex;
}

.pg-game-over__card {
  width: min(420px, calc(100vw - 32px));
  padding: 28px;
  border: 1px solid rgba(200,150,80,.28);
  background: rgba(18,12,8,.78);
  backdrop-filter: blur(22px) saturate(140%);
  color: #ead9b5;
  text-align: center;
  box-shadow: 0 24px 60px rgba(0,0,0,.55);
}

.pg-game-over__card h2 {
  margin: 0 0 12px;
  color: #f5d27a;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.pg-game-over__score {
  font-size: 2rem;
  color: #fff0bd;
  margin: 12px 0 22px;
}

.pg-game-over__button {
  border: 1px solid rgba(200,150,80,.35);
  background: linear-gradient(180deg, #e5c98b, #b98a45);
  color: #160d06;
  padding: 12px 18px;
  text-transform: uppercase;
  letter-spacing: .08em;
  cursor: pointer;
}

@media (max-width: 768px) {
  .site-header__inner {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    padding: 0 8px;
  }

  .site-branding {
    flex: 1 1 auto;
    min-width: 0;
  }

  .site-branding span {
    font-size: 1rem;
    white-space: nowrap;
  }

  .site-branding img {
    width: 58px;
    height: auto;
  }

  .pg-game-toggle {
    order: 20;
    flex: 0 0 auto;
    min-height: 32px;
    height: 32px;
    max-width: 78px;
    padding: 0 8px;
    font-size: 0;
    line-height: 1;
    border-radius: 999px;
    z-index: 5;
  }

  .pg-game-toggle::after {
    content: "Game";
    font-size: 10px;
    letter-spacing: .06em;
  }

  .pg-game-toggle.is-active::after {
    content: "Exit";
  }

  .site-mini-cart {
    order: 30;
    flex: 0 0 auto;
    margin-left: 2px;
    z-index: 6;
  }

  .site-menu-toggle {
    order: 40;
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
    margin-left: 2px;
    z-index: 10;
  }

  .site-nav {
    order: 50;
  }
} 

.pg-game-over__actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.pg-game-over__button--secondary {
  background: rgba(18,12,8,.45);
  color: #ead9b5;
}
.pg-game-sound-toggle {
  border: 1px solid rgba(200,150,80,.25);
  background: rgba(18,12,8,.42);
  color: #ead9b5;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: .72rem;
  text-transform: uppercase;
  cursor: pointer;
}
