* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  user-select: none;
}

html,
body {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  overflow: hidden;
  background-color: #222222;
}

canvas {
  background-color: #000000;
  margin: 0.9em;
  image-rendering: pixelated;
  border-radius: 1.2em;
}

.pixel {
  font-family: 'Pixelify Sans', sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
}

#hud {
  position: absolute;
  margin: 2em 1em;
  max-width: 64em;
  width: 100%;
  display: flex;
  justify-content: space-around;
  align-items: baseline;
  height: 6em;
  color: #ffffff;
  border-radius: 1.2em;
  z-index: 2;
}

#content {
  display: flex;
  width: 100%;
  justify-content: center;
  display: none;
  position: relative;
}

.arcade_machine {
  display: none;
  width: 1053px;
  height: 605px;
  background-color: #ffffff;
  z-index: 1;
  border-radius: 2em;
  background-color: #000;
}

.observation {
  display: block;
  color: #ffffff;
  font-size: 5vw;
  font-weight: bold;
  margin: 1em;
}

span {
  position: absolute;
  animation: pulse 1.5s ease infinite;
}

#hud span {
  font-size: 1.5em;
  bottom: 2em;
}

/* GAME PAGE START */

.hud_time {
  width: 15%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 3em;
  font-family: system-ui, sans-serif;
  font-optical-sizing: auto;
  font-weight: 700;
  font-style: normal;
}

.hud_time-pulsing {
  animation: pulse 1s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.hud_fighter-1,
.hud_fighter-2 {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 0.75em;
  gap: 0.75em;
  position: relative;
}

.hud_fighter-1 {
  padding-left: 2em;
}

.hud_fighter-2 {
  padding-right: 2em;
}

.hud_fighter-1_round-count,
.hud_fighter-2_round-count {
  position: absolute;
  width: 1em;
  height: 1em;
  top: 0;
}

.hud_fighter-1_round-count_1,
.hud_fighter-1_round-count_2,
.hud_fighter-2_round-count_1,
.hud_fighter-2_round-count_2 {
  position: absolute;
  border: 2px solid #333333;
  width: 1em;
  height: 1em;
  top: -0.5em;
  outline: 1px solid #333333;
  transition: 0.5s;
}

.hud_fighter-1_round-count {
  right: 0;
  transform: skew(10deg);
}

.hud_fighter-1_round-count_1 {
  right: 1em;
}

.hud_fighter-1_round-count_2 {
  right: 2.5em;
}

.hud_fighter-2_round-count {
  left: 0;
  transform: skew(-10deg);
}

.hud_fighter-2_round-count_1 {
  left: 1em;
}

.hud_fighter-2_round-count_2 {
  left: 2.5em;
}

.hud_fighter-1_health-bar,
.hud_fighter-2_health-bar {
  width: 100%;
  height: 100%;
  position: relative;
  background-color: #333333;
  overflow: hidden;
  border: 4px solid #333333;
}

.hud_fighter-1_health-bar {
  transform: skew(10deg);
}

.hud_fighter-2_health-bar {
  transform: skew(-10deg);
}

.hud_fighter-1_health-bar::before,
.hud_fighter-2_health-bar::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0.1em;
  width: 99%;
  height: 100%;
}

.hud_fighter-1_health-bar::before {
  background-color: #340e0e;
}

.hud_fighter-2_health-bar::before {
  background-color: #121f3b;
}

.hud_fighter-1_health-bar_content,
.hud_fighter-2_health-bar_content {
  position: absolute;
  top: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  box-shadow: 0 0 12px rgb(255 255 255 / 50%) inset;
  transition: width 0.5s;
  border: 2px solid;
}

.hud_fighter-1_health-bar_content {
  right: 0;
  background-color: #d61561;
}

.hud_fighter-2_health-bar_content {
  left: 0;
  background-color: #0b70ba;
}

.hud_fighter-1_name,
.hud_fighter-2_name {
  font-size: 1.2em;
  text-transform: capitalize;
}

.hud_fighter-1_name {
  text-align: left;
  margin-left: 0.5em;
}

.hud_fighter-2_name {
  text-align: right;
  margin-right: 0.5em;
}

.hud_fighter-1_block-bar,
.hud_fighter-2_block-bar {
  position: absolute;
  width: 5em;
  height: 0.75em;
  bottom: 1.75em;
  border: 2px solid #333333;
}

.hud_fighter-1_block-bar {
  right: 0.3em;
  transform: skew(10deg);
}

.hud_fighter-2_block-bar {
  left: 0.3em;
  transform: skew(-10deg);
}

.hud_fighter-1_block-bar_content,
.hud_fighter-2_block-bar_content {
  position: absolute;
  background-color: #cccccc;
  width: 0%;
  height: 100%;
}

.hud_fighter-1_block-bar_content {
  left: 0;
}

.hud_fighter-2_block-bar_content {
  right: 0;
}

#special-bar {
  position: absolute;
  margin: 1em;
  max-width: 64em;
  width: 100%;
  display: flex;
  top: 34em;
  z-index: 2;
}

.special-bar_fighter-1,
.special-bar_fighter-2 {
  width: 12em;
  height: 2em;
  position: absolute;
  background-color: #33333333;
  overflow: hidden;
  border: 4px solid #333333;
  bottom: 0;
}

.special-bar_fighter-1 {
  left: 2em;
  transform: skew(10deg);
}

.special-bar_fighter-2 {
  right: 2em;
  transform: skew(-10deg);
}

.special-bar_fighter-1::before,
.special-bar_fighter-2::before {
  content: '';
  position: absolute;
  top: 0;
  width: 100%;
  height: 100%;
}

.special-bar_fighter-1::before {
  background-color: #340e0e94;
}

.special-bar_fighter-2::before {
  background-color: #121f3b94;
}

.special-bar_fighter-1_content,
.special-bar_fighter-2_content {
  position: absolute;
  top: 0;
  width: 0%;
  height: 100%;
  z-index: 1;
  box-shadow: 0 0 12px rgb(0 0 0 / 50%) inset;
}

.special-bar_fighter-1_content {
  left: 0;
  background-color: #d61561;
}

.special-bar_fighter-2_content {
  right: 0;
  background-color: #0b70ba;
}

.special-bar_charged,
.block-bar_charged {
  animation: glow 0.75s ease infinite;
}

/* GAME PAGE END */

#hud.home_container,
#hud.intro_container {
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 36em;
  margin: 0.9em;
  text-transform: uppercase;
  z-index: 2;
}

#hud.home_container {
  background-image: url('../assets/pages/background.webp');
  background-size: cover;
  background-position: center;
}

#hud.intro_container {
  background-color: #222222;
}

#hud.intro_container p {
  font-size: 2.75em;
  margin: 0 2em 1em;
}

.home_container_title {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: absolute;
  margin-bottom: 5em;
}

.home_container_title h1 {
  font-size: 6em;
  text-shadow: -4px -4px 0 #000, 4px -4px 0 #000, -4px 4px 0 #000, 4px 4px 0 #000;
}

.home_container_title h2 {
  font-size: 3em;
  text-shadow: -2px -2px 0px #000, 2px -2px 0px #000, -2px 2px 0px #000, 2px 2px 0px #000;
}

.home_container_info {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 2em;
  position: absolute;
  bottom: 1em;
  width: 100%;
  text-shadow: -2px -2px 0px #000, 2px -2px 0px #000, -2px 2px 0px #000, 2px 2px 0px #000;
}

#hud .home_container_info span {
  font-size: 1em;
  bottom: 3em;
}

.home_container_info h3 {
  font-size: 1em;
}

/* animations */

@keyframes glow {
  0%,
  100% {
    filter: none;
  }

  50% {
    filter: brightness(1.5);
  }
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.5;
  }
}

@keyframes invert {
  0%,
  100% {
    filter: invert(0);
  }

  50% {
    filter: invert(1);
  }
}

/* media queries */

/* 1024x576 */
@media screen and (min-width: 64em) and (min-height: 36em) {
  .observation {
    display: none;
  }

  #content,
  .arcade_machine {
    display: flex;
  }
}
