@import url('https://fonts.googleapis.com/css2?family=Jura:wght@700&display=swap');

html {
    height: 100%;
}

body {
    font-family: "Jura", Arial, Helvetica, sans-serif;
    background-image: url('../../assets/normal/images/menu/background.png');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
    height: 100%;
    overflow: hidden;
}

canvas {
    position: fixed;
    top: 0;
    left: 0;
    padding: 0;
}

div#scopes {
    position: fixed;
    height: 10vh;
    top: 2vh;
    left: 50%;
    transform: translateX(-50%);
}

.scope {
    border-width: 0;
    border-radius: 50%;
    border-color: #7CFC00;
    opacity: 0.6;
    transition: all ease .5s;
}

.scope:hover {
    border-width: 2px;
    transition: all ease .5s;
}

div#menu {
    width: 100%;
    height: fit-content;
    overflow-y: scroll;
    clear: both;
    margin: auto;
}

div#menu:not(:is(.hidden)) {
    display: flex;
}

div#menu div.panel {
    height: 40vh;
    padding: 2vw;
    margin: 1vw;
    text-align: left;
    flex: 2;
}

div#menu div#connection.panel {
    text-align: center;
    flex: 1;
}

.hidden {
    display: none;
}

#server-error-panel {
    background-image: linear-gradient(to right, rgba(210, 0, 0, 0), rgba(210, 0, 0, 0.9), rgba(210, 0, 0, 0));
}

.error-div {
    background-color: rgba(0, 0, 0, 0.5);
    padding: 1vh;
}

#kill-feeds {
    position: inherit;
    text-align: center;
    font-size: 2vh;
    top: 13vh;
    right: 2.5vh;
    background-color: rgba(5, 5, 5, 0.5);
    border-radius: 5px;
}
.panel {
    position: relative;
    margin: auto;
    padding: 3vw;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 2vw;
    text-align: center;
    width: fit-content;
    color: #fff;
}

.ingame-panel {
    position: fixed;
    padding: 3vw;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 2vw;
    text-align: center;
    width: fit-content;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

:is(.panel, .ingame-panel) :is(.button, .input) {
    font-size: 1vw;
    padding: 1vw;
    border-radius: 1vw;
    margin: 2vw auto;
}

#reload-btn {
    position: relative;
    height: 30px;
    width: 30px;
    font-size: inherit;
    display: none;
    background-color: rgba(51, 51, 51, 0.5);
    pointer-events: all;
}
#menu-btn {
    position: relative;
    height: 30px;
    width: 30px;
    font-size: inherit;
    display: none;
    background-color: rgba(51, 51, 51, 0.5);
    pointer-events: all;
}
#hud {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    position: fixed;
    pointer-events: none;
    color: #fff;
}

#playercount {
    font-size: 5vh;
    position: relative;
    font-weight: bold;
}

#playercountcontainer {
    position: inherit;
    right: 2vh;
    top: 2vh;
    border-radius: 20%;
    border: solid 0.5vh black;
    width: 10vh;
    height: 10vh;
    vertical-align: middle;
    text-align: center;
    display: block;
    background-color: rgba(51, 51, 51, 0.5);
}

#alive {
    font-size: 3vh;
    display: block;
}

.weapon-index {
    font-size: 5vh;
    position: relative;
    font-weight: bold;
}

.weapon-name-container {
    width: 60%;
    position: relative;
    height: 100%;
    text-align: center;
    display: block;
}

.weapon-name {
    font-size: 3vh;
    display: block;
}

#weapon-container {
    position: relative;
    left: 84%;
    top: 33.5%;
    height: 30vh;
    width: 15vw;
    empty-cells: show;
}

.weapon-panel {
    position: relative;
    width: 100%;
    max-height: 25%;
    margin: 0;
    padding: 0;
    border-radius: 1vw;
    display: block;
    background-color: transparent;
    transition: all .2s ease;
    pointer-events: all;
    border: solid 0.5vh transparent;
}

.weapon-panel:hover {
    background-color: rgba(51, 51, 51, 0.5);
    transition: all .2s ease;
    cursor: pointer;
}

.selected {
    border: solid 0.5vh #7CFC00;
    background-color: rgba(51, 51, 51, 0.5);
}

.weapon-image-container {
    width: 40%;
    position: absolute;
    height: 100%;
    display: block;
    top: 0;
    right: 0;
}

.weapon-image {
    display: block;
    position: absolute;
    object-fit: cover;
    max-height: 100%;
    max-width: 100%;
    height: 90%;
}

.healing-count {
    font-size: 3vh;
    position: relative;
    font-weight: bold;
}

.healing-count-container {
    width: 50%;
    position: absolute;
    height: 4vh;
    text-align: center;
    display: block;
    top: 0;
    right: 0;
    line-height: 4vh;
}

#healing-container {
    position: inherit;
    top: 27vh;
    right: 2vh;
    height: 8vh;
    width: 7vw;
    empty-cells: show;
}

.healing-panel {
    position: relative;
    width: 100%;
    max-height: 25%;
    margin: 0;
    padding: 0;
    border-radius: 0.5vw;
    display: block;
    background-color: rgba(51, 51, 51, 0.5);
    transition: all .2s ease;
    pointer-events: all;
    border: solid 0.25vh transparent;
    opacity: 0.6;
}

.healing-panel.enabled:hover {
    border: solid 0.25vh #7CFC00;
    transition: all .2s ease;
    cursor: pointer;
}

.enabled {
    opacity: 0.9;
}

.healing-image-container {
    width: 50%;
    position: relative;
    height: 100%;
    display: block;
    height: 4vh;
}

.healing-image {
    display: block;
    position: absolute;
    object-fit: cover;
    max-height: 100%;
    max-width: 100%;
    height: 90%;
}

.button {
    padding: 2vh;
    width: 10vw;
    height: fit-content;
    background-color: rgb(34, 139, 34);
    transition: all .5s ease;
    color: #fff;
    border: none;
    border-radius: 1vh;
    cursor: pointer;
}

.button:hover {
    filter: brightness(80%);
}

.arrow {
    border: solid white;
    border-width: 0 5px 5px 0;
    display: inline-block;
    padding: 5px;
    cursor: pointer;
    transition: all .25s ease;
}

.arrow-down {
    transform: rotate(45deg);
    -webkit-transform: rotate(45deg);
}

.box {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    border-radius: 10px;
    display: none;
}

.box-selectable {
    padding: 2vh;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    border-radius: 1vh;
    display: none;
}

input[type="text"], input[type="password"] {
    position: relative;
    width: 80%;
    padding: 1vh;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    border-radius: 1vw;
    text-align: center;
    margin: 1vh;
}

.discord {
    padding: 1vh;
    background-color: rgba(0, 0, 0, 0.5);
    border: none;
    border-radius: 1vh;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.discord img {
    aspect-ratio: 1 / 1;
    height: 3vh;
}

.info {
    position: absolute;
    top: 50px;
    left: 50px;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    padding: 10px;
    cursor: pointer;
    border-radius: 10px;
    text-align: center;
    display: none;
}

.info-box {
    position: absolute;
    top: 50px;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    height: 100px;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    padding: 10px;
    cursor: pointer;
    border-radius: 10px;
    text-align: center;
    display: none;
}

.close {
    position: absolute;
    top: 1vw;
    right: 1vw;
    cursor: pointer;
}

.partner {
    position: absolute;
    top: 1vh;
    left: 5vh;
    background-color: rgba(0, 255, 0, 0.5);
    color: #fff;
    padding: 1vh;
    cursor: pointer;
    border-radius: 1vh;
    text-align: center;
}
.loadout {
    position: absolute;
    top: 1vh;
    left: 30vh;
    background-color: rgba(0, 255, 0, 0.5);
    color: #fff;
    padding: 1vh;
    cursor: pointer;
    border-radius: 1vh;
    text-align: center;
}

.partner-box {
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translate(-50%, 0);
    width: fit-content;
    height: 80vh;
    background-color: rgba(2, 48, 32);
    color: #fff;
    padding: 2vw;
    cursor: pointer;
    border-radius: 1vw;
    text-align: left;
    display: none;
    overflow-y: auto;

    /* Hide scroll bar (Edge, Firefox) */
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}

/* Hide scroll bar (Chrome, Safari) */
.partner-box::-webkit-scrollbar {
    display: none;
}

.overlays {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

.boxers {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: fit-content;
    height: 50vh;
    max-width: 60vw;
    background-color: #fff;
    padding: 2vw;
    z-index: 1000;
    overflow-y: auto;
    border-radius: 1vw;
    color: #fff;

    /* Hide scroll bar (Edge, Firefox) */
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}

/* Hide scroll bar (Chrome, Safari) */
.boxers::-webkit-scrollbar {
    display: none;
}

#loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    background-color: black;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading-text {
    font-size: 24px;
    color: white;
    display: flex;
    align-items: center;
}

.dot {
    animation: dots 1s infinite;
}

@keyframes dots {

    0%,
    20% {
        color: rgba(255, 255, 255, 0.2);
        text-shadow: none;
    }

    50% {
        color: white;
        text-shadow: 0 0 10px white;
    }
}

.zoom-out {
    animation: zoom 1s forwards;
}

@keyframes zoom {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(3);
        opacity: 0;
    }
}

#volume-icon {
    position: fixed;
    top: 1vh;
    left: 1vh;
    width: 3vh;
    height: 3vh;
    background-image: url('https://cdn-icons-png.flaticon.com/512/3524/3524659.png');
    background-repeat: no-repeat;
    background-size: contain;
    cursor: pointer;
}

#volume-slider {
    display: none;
    position: fixed;
    top: 50px;
    left: 10px;
    width: 100px;
    height: 10px;
}

#volume-slider input[type="range"] {
    width: 100%;
    height: 10px;
    -webkit-appearance: none;
    background-color: #999;
    outline: none;
    opacity: 0.7;
    -webkit-transition: opacity 0.2s;
    transition: opacity 0.2s;
    border-radius: 5px;
}

#volume-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    background-color: #4CAF50;
    cursor: pointer;
    border-radius: 50%;
}

#volume-slider input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background-color: #4CAF50;
    cursor: pointer;
    border-radius: 50%;
}

.center {
    display: flex;
    justify-content: center;
    align-items: center;
    height: fit-content;
}

img {
    margin: auto;
    margin-top: 1px;
}

.overlay {
    position: fixed;
    top: 50%;
    right: 9%;
    transform: translate(0, -50%);
    width: 300px;
    height: 300px;
    z-index: -1;
    background-color: rgba(128, 128, 128, 0.5);
    border-radius: 5px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    font-family: sans-serif;
    font-size: 24px;
}

.overlay h1 {
    margin-top: 0;
}

.box {
    width: 300px;
    height: 300px;
    margin: auto;
    position: absolute;
    top: 50%;
    left: 27%;
    transform: translate(-50%, -50%);
    background-color: rgba(128, 128, 128, 0.5);
    border: 1px solid black;
    display: grid;
    z-index: -1;
}

h1 {
    text-align: left-to-right;
    margin-top: -5px;
    font-size: 24px;
}

p {
    text-align: central;
    margin-top: 15px;
    font-size: 20px;
    color: rgb(255, 255, 153);
}

c {
    text-align: left-to-right;
    margin-top: 5px;
    font-size: 15px;
    margin-top: -50px;
}

/*
#privacyBox {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    height: 500px;
    background-color: #add8e6;
    border-radius: 20px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: auto;
}
*/

#privacy-box {
    text-align: left;
    color: #000;
}

h1 {
    font-size: 28px;
    font-weight: bold;
    margin: 20px 0;
    text-align: center;
}

m {
    font-size: 16px;
    line-height: 1.5;
    margin: 20px 0;
}

button {
    background-color: #4caf50;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    margin: 10px;
    transition: all 0.2s ease-in-out;
}

button:hover {
    opacity: 0.8;
}

.button-decline {
    background-color: #f44336;
}

.button-close {
    background-color: #ff0000;
    color: #fff;
    padding: 1;
    position: absolute;
    top: 0;
    right: 0;
    border: none;
    border-top-right-radius: 4px;
    cursor: pointer;
    transition: all 0.5s ease-in-out
}

.button-close:hover {
    opacity: 0.7;
    transform: scale(1.1);
}

a {
    text-decoration: none;
    color: bisque;
}

a:hover {
    text-decoration: underline;
}

.top-right-stuff {
    position: absolute;
    top: 1vh;
    right: 1vh;
    display: flex;
}

img#logo {
    max-width: 50%;
}

div#menu div.panel#account {
    text-align: center;
}

.flex {
    display: flex;
}
.joystick-container {
    position: fixed;
    left: 25%;
    bottom: 24%;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border-color: black;
    background-image: url('/assets/normal/images/game/JoystickYep.png');
    background-size: 50% 50%;
    background-size: cover;
    background-color: rgba(51, 51, 51, 0.5);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    display: none;
}

.joystick-handle {
    position: absolute;
    left: 25px;
    top: 25px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #fff;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
    background-color: rgba(52, 52, 52, 0.6);
    cursor: pointer;
    display: none;
}
.aimjoystick-container {
    position: fixed;
    right: 25%;
    bottom: 24%;
    transform: translateX(-50%);
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border-color: black;
    background-image: url('/assets/normal/images/game/JoystickYep.png');
    background-size: 50% 50%;
    background-size: cover;
    background-color: rgba(51, 51, 51, 0.5);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    display: none;
}
.aimjoystick-handle {
    position: absolute;
    left: 25px;
    top: 25px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #fff;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
    background-color: rgba(52, 52, 52, 0.6);
    cursor: pointer;
    display: none;
}

/* Live online player count on the menu */
.online-count {
    margin: 1vh auto;
    font-size: 1.1vw;
    font-weight: bold;
    color: #80B251;
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.6);
}

/* Survival leaderboard on the menu */
.leaderboard {
    list-style: none;
    margin: 0;
    padding: 0;
    counter-reset: lb;
}

.leaderboard li {
    counter-increment: lb;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1vw;
    padding: 0.5vh 0.6vw;
    border-radius: 0.5vw;
    margin-bottom: 0.4vh;
    background-color: rgba(255, 255, 255, 0.06);
}

.leaderboard li::before {
    content: counter(lb) ".";
    margin-right: 0.6vw;
    color: #80B251;
    font-weight: bold;
}

.leaderboard .lb-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.leaderboard .lb-time {
    color: #ccc;
    font-size: 0.9em;
    white-space: nowrap;
}

/* ============================================================
   Menu polish — cohesive layout, clean panels & login form.
   Appended last so these win the cascade over earlier rules.
   ============================================================ */
#menu:not(.hidden) {
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: center;
    gap: 1.5vw;
    padding: 5vh 2vw 2vh;
    box-sizing: border-box;
}

div#menu div.panel {
    height: auto;
    max-height: 80vh;
    overflow-y: auto;
    min-width: 220px;
    max-width: 340px;
    flex: 1 1 280px;
    margin: 0;
    padding: 1.6vw;
    background-color: rgba(12, 18, 12, 0.82);
    border: 1px solid rgba(128, 178, 81, 0.35);
    border-radius: 14px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    color: #fff;
    text-align: center;
}

div#menu div#connection.panel {
    flex: 1 1 280px;
}

#menu .panel h1 {
    font-size: 1.5vw;
    margin: 0 0 1vh;
    color: #80B251;
}

#menu .panel p {
    margin: 0.4vh 0;
    opacity: 0.85;
}

/* Login / connection inputs */
#menu input[type="text"], #menu input[type="password"] {
    width: 100%;
    box-sizing: border-box;
    padding: 1.1vh 1vh;
    margin: 0.6vh 0;
    background-color: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: #fff;
    text-align: center;
    font-size: 0.95vw;
    transition: border-color 0.15s, background-color 0.15s;
}

#menu input[type="text"]:focus, #menu input[type="password"]:focus {
    outline: none;
    border-color: #80B251;
    background-color: rgba(0, 0, 0, 0.6);
}

#menu input::placeholder { color: rgba(255, 255, 255, 0.5); }

/* Buttons inside menu panels */
.panel .button {
    font-size: 0.95vw;
    padding: 1.1vh 1.2vw;
    margin: 1vh auto;
    background-color: #80B251;
    color: #0c120c;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.15s, transform 0.05s;
}

.panel .button:hover { background-color: #93c763; }
.panel .button:active { transform: translateY(1px); }

#connection .button#connect {
    width: 100%;
    box-sizing: border-box;
    font-size: 1.2vw;
    padding: 1.4vh;
}

.flex {
    display: flex;
    gap: 0.6vw;
    justify-content: center;
}

.flex .button { flex: 1; }

/* X (Twitter) icon — small fixed button (was an unconstrained full-size SVG) */
.top-right-stuff {
    top: 1.5vh;
    right: 1.5vh;
    z-index: 10;
}

.discord {
    width: 44px;
    height: 44px;
    padding: 10px;
    box-sizing: border-box;
    background-color: rgba(12, 18, 12, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    transition: background-color 0.15s;
}

.discord:hover { background-color: rgba(128, 178, 81, 0.85); }
.discord svg { width: 100%; height: 100%; display: block; }

/* Change Loadout — clean top-left button */
.loadout {
    top: 1.5vh;
    left: 1.5vh;
    background-color: rgba(12, 18, 12, 0.82);
    border: 1px solid rgba(128, 178, 81, 0.45);
    color: #fff;
    padding: 1vh 1.2vw;
    border-radius: 10px;
    font-weight: bold;
    transition: background-color 0.15s;
}

.loadout:hover { background-color: rgba(128, 178, 81, 0.85); }

.online-count { font-size: 1vw; }

/* ============================================================
   In-game HUD polish — cleaner panels, unified GoKill accent.
   Layout/positions left intact so game logic keeps working.
   ============================================================ */
#hud { font-family: "Rajdhani", "Jura", sans-serif; }

#playercountcontainer {
  border: none;
  border-radius: 14px;
  background: rgba(11, 15, 11, 0.72);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4), inset 0 0 0 1px rgba(155, 226, 92, 0.25);
  padding: 0.6vh 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
#playercount { color: #9be25c; line-height: 1; }
#alive {
  font-size: 1.6vh;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(238, 243, 232, 0.75);
}

/* Move the weapon slots (1-4) down so they no longer overlap the healing/
   ammo items above them. The extra items keep their original spot. */
#weapon-container {
  top: 47%;
}

/* Weapon slots */
.weapon-panel {
  background: rgba(11, 15, 11, 0.6);
  border: solid 0.35vh transparent;
  border-radius: 0.8vw;
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
  margin-bottom: 0.6vh;
}
.weapon-panel:hover { background: rgba(111, 174, 58, 0.22); }
.weapon-index { color: rgba(238, 243, 232, 0.55); }
.weapon-name { letter-spacing: 0.02em; }
.selected {
  border: solid 0.35vh #9be25c;
  background: rgba(111, 174, 58, 0.28);
  box-shadow: 0 0 18px rgba(155, 226, 92, 0.35);
}

/* Healing items */
.healing-panel {
  background: rgba(11, 15, 11, 0.6);
  border-radius: 0.6vw;
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
}
.healing-panel.enabled:hover { border: solid 0.25vh #9be25c; }

/* Kill feed */
#kill-feeds {
  background: rgba(11, 15, 11, 0.6);
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
  padding: 0.4vh 0.8vh;
  border-radius: 8px;
}

/* Reload / menu round buttons */
#reload-btn, #menu-btn {
  background: rgba(11, 15, 11, 0.72);
  border-radius: 12px;
  box-shadow: inset 0 0 0 1px rgba(155, 226, 92, 0.25);
}
#reload-btn:hover, #menu-btn:hover { background: rgba(111, 174, 58, 0.3); }

/* In-game settings panel */
.ingame-panel {
  background: rgba(11, 15, 11, 0.85);
  border: 1px solid rgba(155, 226, 92, 0.25);
  border-radius: 16px;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.ingame-panel .button.purple {
  background: linear-gradient(135deg, #9be25c, #6fae3a);
  color: #0b0f0b;
  font-weight: 700;
}
