body {
  margin: 0;
  padding: 0;
  background: url(img/bg.png);
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  font-family: Roboto, Verdana, Helvetica, Sans-Serif;
}

.field-cell {
  position: absolute;
  box-sizing: border-box;
  cursor: pointer;
  color: #fff;
  font-weight: bold;
  border-radius: 4px;
  font-size: 1rem;
  border: 2px solid rgba(7, 41, 25, 0.2);
}

.cell-move {
  background-color: rgba(255, 254, 0, 0.3);
}

.cell-red {
  background-color: #cf6f00;
}

.player-card {
  position: absolute;
  pointer-events: none;
}

.player-picture {
  background-size: 50%;
  background-position: 50% 70%;
  position: absolute;
  background-repeat: no-repeat;
}

#fuzbal_game {
  background-color: #217220;
  position: relative;
  margin-left: auto;
  margin-right: auto;
  user-select: none;
  width: 100%;
  max-width: 1200px;
  height: 100vh;
  max-height: 1200px;
  -webkit-tap-highlight-color: transparent;
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

@media (max-width: 599px) {
  #fuzbal_game {
    width: auto;
    max-width: auto;
    height: auto;
    max-height: auto;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
  }
}

@media (min-width: 1200px) {
  #fuzbal_game {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
  }
}

#field_body {
  position: absolute;
  overflow: hidden;
}

#field_bg {
  position: absolute;
  background-image: url(img/field.png);
  background-size: cover;
}

#field_cells {
  position: absolute;
}

#field_players {
  position: absolute;
}

#sidepanel {
  position: absolute;
  background-color: gray;
  font-size: 0;
}

#ball {
  position: absolute;
  pointer-events: none;
}

#ball_picture {
  position: absolute;
  width: 40%;
  height: 40%;
  left: 50%;
  top: 50%;
  background-image: url(img/ball.png);
  background-size: contain;
  background-repeat: no-repeat;
  pointer-events: none;
  transform-origin: 50% 50%;
}

#svg_overlay {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  pointer-events: none;
}

#svg_overlay svg {
  width: 100%;
  height: auto;
}

.sidepanel-card {
  font-size: 1rem;
  box-sizing: border-box;
  padding: 0.5rem;
  position: relative;
  box-sizing: border-box;
  display: inline-block;
  background-color: white;
  width: 100%;
  overflow: hidden;
  vertical-align: bottom;
  text-align: center;
}

@media (max-width: 599px) {
  .sidepanel-card {
    width: 33.33%;
    height: 100%;
  }
}

@media (min-width: 600px) {
  .sidepanel-card {
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
  }
}

@media (max-width: 599px) {
  #player_info {
    font-size: 0.65rem;
    width: 45%;
  }
}

#actions_info {
  background-color: #277f31;
  color: #fff;
}

@media (max-width: 599px) {
  #actions_info {
    width: 30%;
  }
}

#match_info {
  background-color: #277f31;
  color: #fff;
  font-size: 1.5rem;
  font-weight: bold;
}

@media (max-width: 599px) {
  #match_info {
    padding: 0;
    padding-top: 0.5em;
    width: 25%;
  }
}

#time_info {
  font-size: 1rem;
  font-weight: normal;
  font-family: monospace;
}

#game_message {
  position: absolute;
  pointer-events: none;
  text-align: center;
  top: 50%;
  right: auto;
  bottom: auto;
  font-size: 1.25em;
  font-weight: bold;
  padding: 1em;
  background-color: #fafbfa;
  color: #277f31;
  width: 100%;
  transform: translate(-100%, -50%);
}

#status_messages {
  position: absolute;
  pointer-events: none;
  color: #fff;
  font-weight: bold;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
}

.status-message {
  background-color: rgba(39, 127, 49, 0.4);
  padding: 0.25em;
  border-radius: 1em;
  position: absolute;
  display: inline-block;
}

#player_info_picture {
  width: 64px;
  height: 64px;
  background-size: contain;
  background-repeat: no-repeat;
  display: inline-block;
}

@media (max-width: 599px) {
  #player_info_picture {
    width: 32px;
    height: 32px;
  }
}

#player_info_stats {
  display: inline-block;
  margin-top: 0.5em;
}

#player_info_name {
  font-style: italic;
  white-space: nowrap;
}

#actions_meter {
  font-size: 1.2rem;
  height: 1.5rem;
}

#spirit_meter {
  margin-top: 0.5em;
  font-weight: bold;
}

#main_menu_button {
  position: absolute;
  bottom: 0;
  right: 0;
}

#main_menu {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
}

#main_menu_container {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  border-radius: 0.5em;
  background-color: #fafbfa;
  padding: 1.5em;
  position: absolute;
}

#pointer_mask {
  position: absolute;
  background-color: rgba(255, 255, 255, 0.5);
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

.main-menu-element {
  background-color: green;
  color: #fafbfa;
  font-weight: bold;
  padding: 0.5em;
  padding-left: 1em;
  padding-right: 1em;
  user-select: none;
  cursor: pointer;
  border-radius: 0.25em;
  margin-bottom: 0.2em;
}

.main-menu-element:hover {
  opacity: 0.7;
}

#help_window {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  overflow-y: hidden;
}

#help_iframe {
  position: absolute;
  overflow-y: scroll;
}

#close_help {
  position: absolute;
  right: 0;
  top: 0;
  padding: 0.5em;
}
