/* General Styles */
body {
  background: linear-gradient(45deg, transparent 49%, #dedede 49% 51%, transparent 51%),
    linear-gradient(-45deg, transparent 49%, #dedede 49% 51%, transparent 51%);
  background-size: 3em 3em;
  background-color: #ffffff;
}

img {
  max-width: 100%;
}

/* Anime Character Overlay */
.chara-overlay {
  width: 40%;
  position: fixed;
  bottom: 0;
  z-index: 1000;
  pointer-events: none;
  filter: grayscale(0.35);
}

.chara-overlay.left {
  left: -20%;
}

.chara-overlay.right {
  right: -20%;
}

/* Hint Item Accordion */
.hint-item img {
  max-width: 250px;
  object-fit: contain;
}

/* Bootstrap Class Overrides */
.container {
  max-width: 800px !important;
}

.h1,
.h2,
.h3,
.h4,
.h5,
.h6,
p {
  margin: 0;
}

/* Responsive */
@media (max-width: 1150px) {
  .chara-overlay {
    display: none;
  }
}

/* Map Overlay  */
#map-overlay {
  width: 100%;
  height: 100vh;
  height: 100dvh;
  background: radial-gradient(ellipse at center, #3b88c3 0%, #1a3c64 100%);
  box-shadow: inset 0 0 80px rgba(0, 0, 0, 0.3);
  position: fixed;
  top: 0;
  z-index: 1000;
}

#map-overlay svg {
  width: 100%;
  height: 100%;
  display: block;
  filter: drop-shadow(0 0 4px rgba(0, 0, 0, 0.5));
}

#map-overlay svg path {
  fill: #7fc37b;
  stroke: #5e5e5e;
  stroke-width: 0.3;
}

.highlighted {
  fill: #ffd166 !important;
  stroke: #ff8800;
  stroke-width: 0.5;
  filter: drop-shadow(0 0 8px rgba(255, 209, 102, 0.8));
}

@keyframes pingFlash {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
  100% {
    opacity: 1;
  }
}

/* States  */

body:not(.on-mobile) #gameplay,
body:not(.on-mobile) #map-overlay,
body:not(.on-mobile) .chara-overlay {
  transition: opacity 500ms ease-in-out;
}

body:not(.on-mobile) #map-overlay svg path {
  transition: fill 0.3s ease;
}

body.game-state-on-landing #gameplay,
body.game-state-on-landing .chara-overlay,
body.game-state-on-started #map-overlay,
body:not(.game-state-on-started) #gameplay,
body.game-state-on-started #map-overlay,
body.game-state-on-relanding #gameplay,
body.game-state-on-relanding .chara-overlay,
body:not(.game-state-on-started) .btn-close {
  opacity: 0;
  pointer-events: none;
}

body.game-state-on-landing #map-overlay svg {
  animation: pingFlash 1000ms ease-in-out 2;
  transform-origin: center;
}

body.game-state-on-started #gameplay,
body.game-state-on-relanding #map-overlay {
  opacity: 1;
}

body.game-state-on-landing,
body.game-state-on-relanding {
  overflow: hidden;
}

button > img {
  pointer-events: none;
}

body.game-state-on-started .lang-switcher-btn {
  pointer-events: none;
  opacity: 0.5;
}
