:root{
    --primary: #E6312C;
    --secondary: #53aa4e;
}


body, html {
    height: 100%;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: poppins;
    overflow: hidden;
    -webkit-touch-callout: none;                /* prevent callout to copy image, etc when tap to hold */
-webkit-text-size-adjust: none;             /* prevent webkit from resizing text to fit */
-webkit-user-select: none;
}
*{
    font-family: poppins;
}

#joystickZone {
  position: absolute;
  width: 50%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: 100;
}
#nameplate{
    filter: brightness(1.3) drop-shadow(0px 5px 0px #999);

    width: 100%;
  padding-top: 20px;
  padding-bottom: 20px;

}

@media only screen and (max-height: 400px) {
    #nameplate {
      padding-top: 0px;
      padding-bottom: 5px;

    }
}

.container {
    text-align: center;
    animation: fadeIn 1s ease-in-out;
    background: linear-gradient(180deg, rgba(230, 230, 230, 1), rgba(230, 230, 230, 0));
    padding: 50px;
    width: min-content;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    filter: drop-shadow(5px 5px 1px rgba(255, 0, 0, 0.2));
  @media screen and (max-height: 600px), screen and (max-width: 400px) {
        padding: 20px;
    }
}

.toprightcount {
    position: fixed;
    top: 10px;
    right: 10px;
    z-index: 1000;
    color: #000000;
    font-size: 1.2em;
  @media screen and (max-height: 600px), screen and (max-width: 400px) {
        font-size: 0.8em;
    }
  font-weight: bold;
}


@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

h1 {
    color: #333;
    margin-bottom: 20px;
}

.title {
    font-size: min(max(5vw, 40px), 150px);
    font-weight: bold;
    color: #333;
    margin-bottom: 20px;
    margin-top: 0;

}

#footer {
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1em;
    color: #333;
    display: flex;
    gap: 25px;
  @media screen and (max-width: 600px) {
      font-size: 0.7em;
    gap: 10px;
  }
    a {
        color: #333;

    }
    a:hover {
        color: gray;
        text-decoration: underline;
    }
}

#nameInput {
    margin-bottom: 23px;
    padding: 10px;
    border-radius: 10px;
    font-size: 1.2em;
    border: 2px solid #bbbbbb;
    filter: drop-shadow(0px 5px 0px #999);
    @media screen and (max-height: 600px), screen and (max-width: 400px) {
        font-size: 0.6em;
    }



}

#playButton {
    padding: 10px 20px;
    border: none;
    border-radius: 10px;
    background-color: #007BFF;
    height: 100%;
    font-size: 1.2em;
    border: 2px solid #666;
    filter: drop-shadow(0px 5px 0px #999);
    color: white;
    cursor: pointer;
    transition: background 0.2s, padding 0.2s ease;
}

@media screen and (max-height: 600px), screen and (max-width: 400px) {
    #playButton {
        font-size: 0.6em;
    }
}


#playButton:hover {
    background-color: #218388;
    padding: 15px 20px;
}

@media screen and (max-height: 600px), screen and (max-width: 400px) {
    body, html {
        flex-direction: column;
    }
}

.row{
    display: flex;
    gap: 5px;
}

#gameGUI {
    width: 100%;
    height: 100%;
    z-index: 10;
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    visibility: hidden;
}

#score {
    text-align: center;
    font-weight: bold;
    font-size: 2em;
    margin: 4px;
    border-bottom: solid;
    border-right: solid 4px rgba(0, 0, 0, 0);
    border-left: solid 4px rgba(0, 0, 0, 0);
    width: max-content;
    text-shadow: 0px 4px 5px rgba(0, 0, 0, 0.3);
}

#time {
    font-weight: bold;
    color: #d5d5d5;
    font-size: 1.8em;
    text-shadow: 0px 2px 5px rgba(0, 0, 0, 0.3);
    margin: 4px;
}

#red {
    color: crimson;
}

#blue {
    color: blue;
}

#redFinal {
    color: crimson;
}

#blueFinal {
    color: blue;
}
.totalGoals{
    width: 100%;
  margin: 5px;
  font-size: 1.2em;
  @media screen and (max-height: 400px) {
    margin: 0;
    font-size: 1em;
  }
}

#matchInfo {
  position: absolute;
  left: 25%;
  height: 50%;
  background-color: rgba(243, 243, 243, 0.9); /* Semi-transparent background */
  width: 50%;
  top: 25%;
  border: 1px solid #ddd;
  border-radius: 20px;
  display: flex;
  z-index: 30;
  flex-direction: column;
  align-items: center;
  justify-content: center; /* Center items vertically */
  visibility: hidden;
  padding: 20px;
  box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.1);
  text-align: center; /* Center text */
}

#matchInfo hr {
  width: 80%;
  border-top: 1px solid darkgray;
  margin: 0;
  padding: 0;
}

#matchInfo h1 {
  font-size: 2em; /* Larger heading */
  margin-bottom: 20px; /* Add some space below the heading */
}

#matchInfo p {
  font-size: 1.2em; /* Larger paragraph text */
  margin-bottom: 10px; /* Add some space below each paragraph */
}

.leavebtn {
  background-color: #218388; /* Button color */
  color: #fff; /* Text color */
  border: none; /* Remove border */
  border-radius: 5px; /* Rounded corners */
  padding: 10px 20px; /* Padding */
  font-size: 1.2em; /* Larger font */
  cursor: pointer; /* Cursor on hover */
  margin-top: 20px; /* Space above the button */
}

.leavebtn:hover {
  background-color: #1a616a; /* Darker color on hover */
}

#speedometer {
    font-weight: bold;
    font-size: 1.8em;
    @media screen and (max-height: 600px) {
        font-size: 0.9em;

    }
    bottom: 5px;
    left: 5px;
    margin: 0;
    position: absolute;
}

#countdown {
    visibility: hidden;
    position: absolute;
    margin: auto;
    font-size: 3em;
    top: 25%;
    transition: all 0.6s;
    text-shadow: 0px 0px 5px rgba(0, 0, 0, 0.8);
    pointer-events: none;
    -webkit-user-select: none; /* Safari */
    -ms-user-select: none; /* IE 10 and IE 11 */
    user-select: none; /* Standard syntax */
    font-weight: bold;
}

.controls {
    p {
        margin: 10px;
      @media screen and (max-height: 600px), screen and (max-width: 400px) {
            margin: 0px;
        }
    }
    label {
        font-size: 1.2em;
      @media screen and (max-height: 600px), screen and (max-width: 400px) {
            font-size: 0.6em;
        }
    }
}

#goal {
    position: absolute;
    bottom: 15%;
    font-size: 3em;
    transition: all 0.5s ease-in-out;
    width: 100%;
    text-align: center;
    left: -100%;
}



#mobile {
    position: absolute;
    z-index: 290;
    left: 1vw;
    width: 98%;
    height: 40vh;
    /* visibility: hidden; */
    pointer-events: none;
    gap: 5px 5px;
    color: white;
    bottom: 9.5vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    user-select: none;

}

    #mobile div {
        display: flex;
        gap: 4px;
    }

        #mobile div div {
            pointer-events: auto;
            background-color: rgba(0, 0, 0, 0.5);
            border-radius: 15px;
            aspect-ratio: 1/1;
            display: flex;
            justify-content: center;
            align-items: center;
            border: solid 1px #787878;
        }

.mobilesmall {
    height: 60%;
    align-self: flex-end;
    user-select: none;
}

.mobilebig {
    height: 80%;
    aspect-ratio: 1/1;
    user-select: none;
    display: flex;
    justify-content: center;
    align-items: center;
}

#forcelandscapemobile {
    width: 100%;
    height: 100%;
    position: fixed;
    z-index: 300;
    h1 {
    color: white;
    }
    background-color: black;
}

.boostBar {
    width: 15%;
    height: 20px;
    border: 1px solid black;
    position: absolute;
    border-radius: 5px;
    left: 5px;
    bottom: 10%;
    background: linear-gradient(90deg, #FF0000, #FFFF00, #00FF00);
}

#boostBarPercent{
    width: 50%;
    float: right;
    height: 100%;
    transition: width 300ms linear;
    background: black;
}

.lds-dual-ring {
    display: inline-block;
    width: 50px;
    height: 50px;
  }
  .lds-dual-ring:after {
    content: " ";
    display: block;
    width: 50px;
    height: 50px;
    margin: 2px;
    border-radius: 50%;
    border: 3px solid #fff;
    border-color: #fff transparent #fff transparent;
    animation: lds-dual-ring 1.2s linear infinite;
  }
  @keyframes lds-dual-ring {
    0% {
      transform: rotate(0deg);
    }
    100% {
      transform: rotate(360deg);
    }
  }




/* Skin shop */
/* Button styling */
.skins-btn {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 10;
  font-size: 1.5em;
  margin: 10px;
  padding: 10px 20px;
  background-color: rgb(255, 255, 255);
  color: black;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.5s;
}

.skins-btn:hover {
  background-color: #aaa;
}

  /* The Modal (background) */
  .modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 1; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgb(0,0,0); /* Fallback color */
    background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
  }

  /* Modal Content */
  .modal-content {
    background-color: rgba(255, 255, 255, 0.6);
    margin: 5% auto; /* 15% from the top and centered */
    padding: 20px;
    border: 1px solid #888;
    width: 80%; /* Could be more or less, depending on screen size */
  }

  /* The Close Button */
  .close {
    color: #000000;
    float: right;
    font-size: 28px;
    font-weight: bold;
  }

  .close:hover,
  .close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
  }

  #skins {
    font-family: 'Roboto', sans-serif;
    color: #333;
  }

  #skins h1 {
    font-size: 2em;
    font-weight: 500;
    text-align: center;
    color: #4a4a4a;
    margin-bottom: 1em;
  }

  #skins img {
    height: auto;
    max-width: 100%;
    vertical-align: middle;
  }

  #skins .card_image {
    background-color: #f5f5f5;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  #skins .btn {
    color: #fff;
    padding: 1em;
    font-size: 1em;
    text-transform: uppercase;
    border-radius: 4px;
    font-weight: 500;
    display: block;
    width: 100%;
    cursor: pointer;
    border: none;
    background: #007BFF;
    transition: background 0.3s ease;
  }

  #skins .btn:hover {
    background: #aaa;
  }

  #skins .cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    list-style: none;
    margin: 0;
    gap: 20px;
    padding: 0;
  }


  #skins .card {
    background: #fff;
    box-shadow: 0 2px 10px 0 rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 8px;
    width: 300px;
  }

  #skins .card_content {
    padding: 1em;
    text-align: center;
  }

  #skins .card_title {
    color: #333;
    font-size: 1.2em;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: capitalize;
    margin: 0px;
  }

  #skins .card_text {
    color: #666;
    font-size: 1em;
    line-height: 1.5;
    font-weight: 400;
  }

  #skins a {
    font-size: 1em;
    color: #007BFF;
    text-decoration: none;
  }

.bg {
    object-fit: contain;
    background-color: #464646;
    height: 100%;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: -1;
    filter: blur(5px);
    -webkit-filter: blur(5px);
    transition: all 0.5s ease;
}