@import url('https://fonts.googleapis.com/css2?family=Londrina+Solid:wght@900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Titillium+Web:wght@400;600&display=swap');
:root {
  font-size: 16px
}
body {
  margin: 0;
  overflow: hidden;
  font-family: 'Bebas';
  background: url(img/sky.jpg) center/cover;
  background-size: 100%;
  color: #fff;
  animation: zoom 7s alternate infinite
}
@keyframes zoom {
  0 {
    background-size: 100%
  }
  100% {
    background-size: 104%
  }
}
.stage {
  position: relative;
  width: 100vw;
  height: 100vh;
  background: #11111170;
  overflow: hidden;
  color: #fff
}
.gameover .stage {
  overflow: auto;
}
.mobile .instruzioni-mobili {
  font-size: 1.8rem;
  position: fixed;
  transform: none;
  background: url(img/sky.jpg) center / cover;
  inset: 0;
  padding: 2rem 4rem;
  z-index: 5555;
  overflow-y: auto;
}
.mobile .instruzioni-mobili .istruct {
  text-align: center;
  vertical-align: middle;
  border-bottom: 1px solid;
  margin-bottom: 0.8rem;
  padding-bottom: 1rem;
  margin-top: 18px;
}
.mobile .instruzioni-mobili .istruct:first-of-type > img:first-of-type {
  display: block;
  margin: auto
}
.alert-info {
  position: fixed;
  bottom: 0;
  background: #fff;
  color: red;
  text-align: center;
  left: 0;
  right: 0
}
.mobile .instruzioni-mobili .flex-c {
  display: block;
  max-width: 100%;
}
.mobile .nemici-spiega {
  display: block
}
.mobile .nemici-spiega {
  margin-top: .5rem
}
.mobile .nemici-spiega img {
  width: 75px
}
.mobile .instruzioni-mobili h3 {
  margin: 0
}
#player {
  position: absolute;
  width: 450px;
  height: 450px;
  background: url('img/player.gif') no-repeat center center;
  background-size: contain;
  left: calc(100% / 2.25);
  top: calc(100% / 2 - 225px);
  /*transition: all .3s ease;*/ /* Transizione animata per ogni modifica */
  /*  transition: .1s ease-in-out;*/
}
.enemy:after {
  content: "";
  position: absolute;
  inset: 0;
  display: block;
  animation: bigc 1s infinite alternate;
  z-index: 0;
  border-radius: 50%;
  border: 5px solid #fff;
  filter: blur(2px);
  scale: 0
}
.enemy:before {
  content: "";
  position: absolute;
  inset: 0;
  display: block;
  animation: bigcr 2s infinite alternate;
  z-index: 1;
  border-radius: 50%;
  border: 2px solid #f30026;
  filter: blur(2px);
  scale: 0;
}
@keyframes bigc {
  0 {
    scale: 0;
    filter: blur(2px);
  }
  100% {
    scale: 1;
    filter: blur(4px);
  }
}
@keyframes bigcr {
  0 {
    scale: 0;
    filter: blur(5px);
  }
  100% {
    scale: 1;
    filter: blur(2px);
  }
}
.very-friend.enemy:before {
  content: "+2";
  font-size: 1.5rem;
  border: 0;
  filter: none !important;
  position: absolute;
  right: -1.5rem;
  top: -1.5rem
}
.very-friend.enemy:after {
  border: 5px solid #41C832;
}
.bullet {
  /* transition: all .3s ease; */ /* Transizione animata per ogni modifica */
}
#player.reduce {
  width: 180px; /* Dimensioni ridotte */
  height: 180px;
  transition: all .1s ease-in-out;
}
#player.reduced {
  width: 180px; /* Dimensioni ridotte */
  height: 180px;
}
#player.moving {
  transition: left 1s ease, top 1s ease-in-out; /* Transizione fluida per l'animazione iniziale */
}
#player:before {
  content: "+2";
  opacity: 0;
  transition: opacity .3s easse-in-out;
  font-family: "Londrina Solid", serif;
  font-size: 3rem;
  color: yellow;
  position: absolute;
  right: -1rem;
  top: 0
}
#player.hit:before {
  opacity: 1;
}
#player.hit {
  animation: hit-effect 0.5s ease;
}
@keyframes hit-effect {
  0% {
    filter: brightness(1);
    transform: scale(1);
  }
  50% {
    filter: brightness(1.5);
    transform: scale(1.1);
  }
  100% {
    filter: brightness(1);
    transform: scale(1);
  }
}
.bullet {
  position: absolute;
  width: 20px;
  height: 20px;
  background: green;
  background-size: contain;
  border-radius: 50%;
}
.enemy {
  position: absolute;
  width: 80px;
  height: 80px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.timer, .score, .coupon {
  position: absolute;
  top: 15px;
  left: 20px;
  font-size: 35px;
  font-family: "Bebas Neue", serif;
}
.score {
  position: absolute;
  top: 15px;
  left: auto;
  right: 20px;
  font-size: 45px;
  font-family: 'Londrina Solid';
  text-transform: uppercase;
}
.complimenti strong {
  display: block;
  font-size: 2.95rem;
  margin: 0;
  line-height: 1;
  padding-bottom: 0
}
.complimenti {
  margin: 0;
  line-height: 1;
  padding-bottom: 0.4rem;
  font-size: 2.15rem;
  letter-spacing: 0.08rem;
}
.coupon .sib-form-block .sib-form-block {
  font-family: "Londrina Solid", serif !important;
  font-size: 2.5rem !important
}
.complimenti + p {
  font-size: 1.6rem;
  margin: .5rem;
  letter-spacing: 0.03rem;
}
.share {
  font-size: 1.825rem;
  letter-spacing: 0.023rem;
  font-weight: 400;
  margin-bottom: 7rem;
}
.share p {
  margin-bottom: .5rem;
  font-weight: 400;
  font-size: 1.6rem;
  line-height: 1.1;
  text-transform: uppercase;
}
.share p:last-of-type {
  margin: 0;
  font-size: 1.5rem;
}
.coupon #sib-container {
  border-radius: 50px !important;
  background: #18222c !important;
  border: 4px solid !important;
}
.coupon .sib-form .entry__choice {
  text-indent: 0
}
.coupon .sib-form__declaration p, .coupon #sib-container .form__entry label, .coupon #sib-container p {
  color: #fff !important;
  /* padding: 0 0 1rem 0; */
  /* text-align: left; */
  text-indent: 0 !important;
}
.coupon .sib-form .checkbox {
  position: absolute;
  left: -0.1rem;
}
.social {
  width: fit-content;
  width: -moz-fit-content;
  margin: auto;
  border: 2px solid #ffffff;
  border-radius: 15px;
  padding: .725rem 2rem;
  background: #00000063
}
.coupon .sib-form #sib-container .entry__error, .coupon .sib-form #sib-container .entry__error {
  background: #d9ed56 !important;
  color: #18222c !important;
  position: absolute;
  top: 79%;
  width: 100%;
  text-align: center !important;
  text-transform: uppercase;
  font-size: .852rem !important;
}
.coupon .sib-form .sib-divider-form-block > * {
  padding: 0;
  border: 0 !important
}
.coupon #sib-container .sib-input.sib-form-block {
  margin-bottom: 1rem
}
.social img {
  display: block;
  width: 47px;
  margin: 0 auto .5rem;
}
.social a, .social button {
  display: inline-block;
  font-size: 1.1rem;
  color: #fff;
  text-transform: none;
  text-decoration: none;
  margin: 0 .5rem;
}
.social button {
  background: transparent;
  box-shadow: none;
  border: none;
  font-family: "Bebas Neue", serif;
  margin: 0
}
.share strong {
  display: block;
  font-weight: 400;
  margin: 0;
}
.coupon {
  top: 3%;
  left: 50%;
  transform: translate(-50%, 0);
  text-align: center;
  display: none;
  font-size: 24px;
}
.game-over {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 137px;
  text-align: center;
  display: none;
  font-family: "Londrina Solid", serif;
}
#player-field {
  position: absolute;
  width: 32.33vw; /* Un terzo della larghezza dello stage */
  height: 100%; /* Copre tutta l'altezza dello stage */
  left: 0; /* Posizionato sul lato sinistro */
  /* background: rgba(255, 255, 255, 0.1); */ /* Semi-trasparente per visualizzare il limite */
}
/* Tipi di nemici */
.enemy.enemy-type-1 {
  background-image: url('img/enemy-1.gif')
}
.enemy.enemy-type-2 {
  background-image: url('img/enemy-2.gif')
}
.enemy.enemy-type-3 {
  background-image: url('img/enemy-3.gif');
}
#start-button {
  position: absolute;
  top: 50%;
  left: 42%;
  transform: translate(-50%, -50%);
  padding: 10px 20px;
  font-size: 42px;
  cursor: pointer;
  background-color: #4caf50;
  color: white;
  border: none;
  border-radius: 5px;
  display: block;
  font-family: "Londrina Solid", serif;
  text-transform: uppercase;
  z-index: 23;
}
#start-button.hidden, .hidden {
  display: none;
}
#info {
  width: 48%;
  position: absolute;
  left: 47%;
  top: 61%;
  transform: translateY(-50%);
  padding-left: 1rem;
}
#info strong {
  display: inline-block;
  text-align: center;
  /* border: 1px solid; */
  font-size: 1.6rem;
  border-right: 1px dashed;
}
#info strong:last-of-type {
  border: 0
}
#info img {
  max-width: 134px;
  display: block;
  display: block;
  margin: auto;
  width: 140px;
}
#info .istruct:last-of-type img {
  max-width: 100px;
  display: block;
  display: block;
  margin: auto;
  width: 140px;
}
#info .istruct:last-of-type {
  border: 0
}
[src="img/friend.png"] {
  display: none;
  width: 90px
}
#info img[alt="barra spaziatrice"] {
  max-width: 180px;
  width: 200px !important;
  margin-top: 1.125rem;
  margin-bottom: 1.4rem;
}
#close-info {
  position: fixed;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  width: 50px;
  right: 2rem;
  background: #fff;
  color: red;
  text-align: center;
  line-height: 1.7;
  font-size: 2rem
}
h1 small {
  display: block;
  font-size: 2.7rem;
  font-family: "Bebas Neue", serif;
  margin-top: 0.8rem;
  margin-bottom: 0.4rem;
}
h1 {
  font-family: "Londrina Solid", serif;
  text-transform: uppercase;
  font-size: 5.55rem;
  line-height: 0.85;
}
#info .instruzioni {
  padding: 0;
  margin-top: 0;
  /* border: 1px dashed; */
  text-align: left;
  font-family: "Titillium Web", serif;
  font-size: 1.4rem;
  font-weight: 400;
  line-height: 1.2;
  width: 90%;
  border: 3px solid #fff;
  padding-top: 1.5rem;
  position: relative;
  background: #0000007a;
}
#open-info {
  display: none
}
.instruzioni h3 {
  margin: 0 0 .5rem;
  text-align: center;
  position: absolute;
  left: 50%;
  text-transform: uppercase;
  top: -1rem;
  transform: translateX(-50%);
  font-size: 1.5rem;
  background: #fff;
  color: #000;
  padding: 0 .5rem;
}
.instruzioni p {
  margin: 0 0 1.2rem 0;
  font-size: 1.225rem;
  text-align: center;
  flex: 30%;
  max-width: 30%;
  width: 30%;
  padding: 0 1%;
  border-right: 1px solid;
}
span.nemici-spiega {
  margin-top: 1rem;
  display: block;
}
#info .nemici-spiega img {
  max-width: 66px;
  display: inline-block;
}
#info .instruzioni strong {
  FONT-WEIGHT: 400;
  BORDER: 0;
  font-size: 1rem;
  margin: 0 1rem;
  text-align: center;
}
#info .instruzioni strongimg {
  margin: auto;
  display: block
}
.stage .sib-form {
  padding: 0;
  border: 0;
  margin: 0;
  background-color: transparent !important;
}
.stage .sib-form .entry__label::after, .stage .sib-form .entry__label {
  display: none;
}
.stage .sib-form input {
  color: #000 !important;
  /* background: #ffffff; */
  opacity: 1;
}
.instruzioni-mobili {
  display: none;
}
.flex-c {
  display: flex;
  flex-wrap: wrap;
}
p.box-p {
  width: 50%;
  flex: 50%;
  max-width: 50%;
}
p.box-p img {
  display: block !important;
}
p.enemy-spiega:before {
  content: "I nemici";
  display: block
}
.enemy-spiega {
  padding-right: 1rem;
  border-right: 1px solid;
  margin-right: 1rem
}
.friend-spiega:before {
  content: "Gli amici";
  display: block
}
@media(max-width:1560px) {
  :root {
    font-size: 13px
  }
}
@media(max-width:1000px) {
  #player {
    position: absolute;
    width: 248px;
    height: 248px;
    top: calc(100% / 2 - 130px);
    left: 3%;
  }
  #info {
    top: 50%;
    left: 50%
  }
  .mobile .coupon {
    position: static;
    transform: none;
    margin-top: 4rem;
    padding: 1rem 2rem;
  }
  #player-field {
    width: 50%;
    height: 110%
  }
  h1 small {
    font-size: 1.9rem;
    font-weight: 400;
  }
  h1 {
    font-size: 3.25rem;
    line-height: 1;
    margin-bottom: 0;
  }
  #info strong img {
    max-width: 74px;
  }
  #info .instruzioni {
    padding: 0;
    display: none;
  }
  info .instruzioni strong {
    max-width: 45%
  }
  .enemy {
    width: 50px;
    height: 50px;
  }
  .game-over {
    font-size: 5rem;
    width: 100%;
  }
  .timer, .score, .coupon {
    font-size: 1.8rem
  }
  #start-button {
    font-size: 1.8rem;
    left: 36%;
  }
  .mobile #sib-container {
    max-width: 94% !important;
  }
  #player.reduced, #player.reduce {
    width: 130px;
    height: 125px;
  }
  .gameover #player{
    scale:0!important;
    transition:.3s
  } .gameover .bullet{
    display:none
  }
  #info {
    width: 50%;
    left: 45%;
    font-size: 3.525rem;
    top: 18%;
    transform: none;
  }
  .mobile #open-info {
    display: block;
    font-family: 'Londrina Solid';
    text-transform: uppercase;
  }
  #info h3 {
    background: #fff;
    color: red;
    font-size: 2rem;
    padding: 0 1rem;
    width: fit-content;
    margin: 0
  }
  body.mobile.gameover .stage {
    overflow-y: auto !important;
    padding: 2rem 0 5rem !important;
    margin-bottom: 5rem !important
  }
}
@media (orientation: portrait) {
  html {
    background-image: url(img/sky.jpg);
    background-size: auto 1000px !important;
    background-repeat: no-repeat;
    height: 100%;
  }
  body.mobile {
    background: none;
  }
  body.mobile.game-over .stage {
    overflow: auto !important
  }
  body.mobile:not(.gameover) > * {
    display: none;
  }
  body.mobile:not(.gameover)::before {
    content: "Ruota il dispositivo  per giocare.";
    display: block;
    text-align: center;
    top: 50%;
    font-size: 42px;
    padding: 20px 50px;
    word-spacing: .5rem;
    position: fixed;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    font-family: 'Londrina Solid';
    text-transform: uppercase;
  }
  body.mobile:not(.gameover)::after {
    content: "";
    width: 250px;
    height: 260px;
    display: block;
    background: url('img/player.gif') center/cover;
    position: absolute;
    bottom: 58%;
    left: 50%;
    transform: translateX(-50%);
    transform-origin: left center;
    animation: rotateg 2.5s infinite
  }
  .instruzioni-mobili {
    display: block
  }
  @keyframes rotateg {
    0 {
      rotate: 0
    }
    20% {
      rotate: 360deg
    }
    50% {
      rotate: 360deg;
      left: 53%
    }
    60% {
      rotate: 360deg;
      left: 48%
    }
    90% {
      rotate: 360deg;
      left: 53%
    }
    100% {
      rotate: +360deg;
      left: 50%
    }
  }
}