:root {
    --bg-color: #090E15;
    --bg-button: #29090A;
    --clr-effect: #752B0E;
    --clr-text: #FFFFFF;
}

@font-face {
    font-family: 'Joystix';
    src: url('joystix-monospace.ttf') format('truetype');
}

@font-face {
    font-family: 'Alagard';
    src: url('alagard.ttf') format('truetype');
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Joystix', sans-serif;
    font-size: 1.1rem;
    /* text-shadow: 0 5px 0 var(--bg-color); */
}

body {
    margin: 0;
    padding: 0;
    color: rgba(255, 255, 255, 0.87);
    background-color: var(--bg-color);
}

#app {
    width: 100%;
    height: 100vh;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

#game-container {
    width: 100%;
    height: 100vh;
    overflow: hidden;
    position: relative;
}



/* #################################################
   ################## SCENE MULTIPLES ##############
   ################################################# */

.container {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-around;
    padding: 40px;
    background: var(--bg-color);
    border: 5px solid var(--clr-effect);
    gap: 20px;
}

.underline {
    text-decoration: underline;
}

.bold  {
    font-weight: bold;
}

/* #################################################
   ################## SCENE HOME PAGE ##############
   ################################################# */

form {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-around;
    background: var(--bg-color);
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    align-items: start;
    justify-content: space-around;
    background: var(--bg-color);
}

.form-group input {
    background: var(--bg-button);
    color: var(--clr-text);
    width: 100%;
    height: 48px;
    padding: 10px;
    font-size: 16px;
    border: 5px solid var(--clr-effect);
    cursor: pointer;
}

.main-title {
    color: var(--clr-text);
    font-size: 64px;
    text-align: center;
    text-shadow: 0 5px 0 var(--clr-effect);
}

.title {
    font-size: 24px;
}

.back {
    margin: 0;
    padding: 10px 13px;
    position: absolute;
    top: 5px;
    left: 5px;
}

#back-login, #back-register {
    padding: 10px;
    margin: 0;
}



/* #################################################
   ################## SCENE HUB ####################
   ################################################# */

/* ################## PROFIL ############## */

.no-trophee {
    filter: grayscale(100%);
}

.wrapper {
    display: flex;
    flex-direction: column;
    min-width: 1500px;

}

.container.inventory{
    flex-direction: row;
    gap: 20px;
    min-width: 1200px;
    min-height: 800px;
}

.vendeur-container {
    text-align: center;
    padding: 10px;
    min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
}

#vendre {
    height: 150px;
    background: url('/assets/boutique/marchand.png');
    background-position: center;
    background-size: contain;
    background-repeat: no-repeat;
    border: 1px solid wheat;
    border-radius: 30px;
}

.vendreHover {
    border: 3px solid gold;
}



/* ################## A PROPOS ############## */

.container.apropos {
    min-width: 1200px;
    min-height: 800px;
    a {
        color: #752b0e;
    }
}

hr {
    width: 100%;
}



/* ################## Classement ############## */

.container.classement {
    flex-direction: column;
    justify-content: start;
    gap: 20px;
    min-width: 1200px;
    min-height: 800px;
    h3 {
        margin-bottom: 30px;
    }
}

/* Basic table styles */
#tableau-classement {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 16px;
    font-family: 'Arial', sans-serif;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
    overflow: auto;
}

/* Table header styling */
#tableau-classement th {
    background-color: #75430a;
    color: white;
    text-align: left;
    padding: 12px;
}

/* Table row styling */
#tableau-classement td {
    padding: 12px;
    border-bottom: 1px solid #dddddd;
}

/* Alternate row colors */
#tableau-classement tr:nth-child(even) {
    background-color: #1d1d1d;
}

/* Hover effect for rows */
#tableau-classement tr:hover {
    background-color: #29090a;
    cursor: pointer;
}

/* Text alignment */
#tableau-classement td:nth-child(2),
#tableau-classement td:nth-child(5),
#tableau-classement td:nth-child(6) {
    text-align: center;
}

/* First column bold */
#tableau-classement td:first-child {
    font-weight: bold;
}

/* Add some spacing between table and surrounding content */
table {
    margin-top: 20px;
}

/* Optional: Add a subtle transition for hover effect */
#tableau-classement tr {
    transition: background-color 0.2s ease;
}

.hub-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

/* ################## Inventaire ############## */

.inventory-slot {
    background: url("assets/inventory/inventory-empty.png");
    width: 90px;
    height: 90px;
}

.slot-equipe {
    background: url("assets/inventory/invisible.png");
    height: 90px;
    width: 90px;
}


.drage {
    /* background-size: contain; */
    background-repeat: no-repeat;
    height: 70px;
    background-position: center;
    position: relative;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70px;
    height: 70px;
    padding: 5px;
    border-radius: 5px;
}

.inventory-item {
    cursor: pointer;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.hover-element {
    position: relative;
    display: inline-block;
    padding: 10px 20px;
    background-color: #4CAF50;
    color: white;
    cursor: pointer;
    border-radius: 5px;
}

/* The popup box (hidden by default) */
.popup {
    display: none;
    position: absolute;
    top: 100%; /* Position above the hover element */
    left: 50%;
    transform: translateX(-50%);
    background-color: #29090a;
    color: white;
    padding: 20px;
    border-radius: 13px;
    border: 3px solid #752b0e;
    white-space: nowrap;
    z-index: 1000;
    h2 {
        text-decoration: underline;
    }
    h2, .des {
        text-align: center;
    }
}

/* Show the popup when hovering over the parent element */
.inventory-slot:hover .popup, .slot-equipe:hover  .popup, .trophee:hover .popup, .item:hover .popup {
    display: block;
}

/* ################## Autres ############## */


#quitter-button {
    margin-left: auto;
    margin-right: 5px;
}

.profil-gauche {
    display: flex;
    flex-direction: column;
    align-items: start;
    justify-content: space-between;
    gap: 20px;
    border: 5px solid var(--clr-effect);
    padding: 20px;
    width: 65%;
    height: 100%;
}

.profil-droit {
    display: flex;
    flex-direction: column;
    align-items: start;
    justify-content: space-between;
    gap: 20px;
    border: 5px solid var(--clr-effect);
    padding: 20px;
    width: 35%;
    height: 100%;
}

.profil-droit .badges {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    justify-items: center;
    gap: 20px;
    width: 100%;
}

.badges img {
    width: 60px;
}

.badges {
    position: relative;
}

.profil-droit-bottom {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.profil-droit h2 {
    width: 100%;
    text-align: center;
}

.profil-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    width: 100%;
}

.stats {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.hub-container .main-title {
    font-size: 42px;
}

.character-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

#enregistrer
{
    margin-top: 500px;
    position: absolute;
    top: 70px;
}

.character-container>*:not(#sheet) {
    position: absolute;
}

.item-inventory {
    background: blue;
}

.item-equiped {
    background: var(--bg-color);
    z-index: 10;
}

.item-inventory,
.slot-equipment-default,
.item-equiped {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70px;
    height: 70px;
    padding: 5px;
    border-radius: 5px;
    background-repeat: no-repeat;
    background-position: center;
}

#character {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    height: 300px;
}

#Casque {
    top: 80px;
    left: 70px;
}

#Armure {
    top: 190px;
    left: 40px;
}

#Arme {
    top: 290px;
    right: 50px;
}

#Seconde_main {
    top: 300px;
    left: 50px;
}

#Anneau {
    top: 400px;
    left: 125px;
}

#Botte {
    top: 400px;
    right: 110px;
}

.inventory-container {
    border: 5px solid var(--clr-effect);
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: end;
    justify-content: space-between;
    height: 100%;
}

.chest-items {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 5px;
    overflow: auto;
    height: 600px;
}

.chest-items .item {
    position: relative;
}

#chest {
    overflow: visible;
}

.pesos {
    position: relative;
}

#pesos {
    position: absolute;
    top: 47%;
    right: 25px;
    transform: translateY(-50%);
}

.buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.buttons.hub {
    flex-direction: row;
}

.button {
    background: var(--bg-button);
    color: var(--clr-text);
    font-size: 16px;
    outline: 5px solid var(--clr-effect);
    padding: 10px 20px;
    margin: 10px;
    cursor: pointer;
}

.button.hub {
    margin: 0;
    border: none;
    outline: 5px solid var(--clr-effect);
    margin-left: 5px;
}

.button:hover {
    background: var(--clr-effect);
    outline: 5px solid white !important;
    z-index: 100;
}

.active-onglet {
    background: var(--clr-effect);
    outline: 5px solid white !important;
    z-index: 100;
}

.button.fight {
    width: fit-content;
    margin: 12px auto;
    font-size: 32px;
}

#bienvenue {
    margin: 30px;
}

.bar-xp {
    background: rgb(182, 150, 7);
    width: 0%;
    height: 10px;
    position: relative;
    transition: width .5s linear;
    animation-direction: reverse;

}

.labarrexp {
    margin-top: -20px;
}

#perso {
    width: 350px;
}

#texte-xp {
    text-align: center;
    margin-bottom: -30px;
}

#niveau {
    text-align: center;
}

/* #################################################
   ################## SCENE ARENA ##################
   ################################################# */

.container-victoire {
    margin-top: 0px;
}

.profil-victoire {
    width: 100% !important;
    align-items: center;
}

#attack-info {
    font-size: 1.5rem;
}

#victoire {
    font-size: 3.3em;
}

#persofin {
    width: 250px;
}

.objets-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 10px;
}

.objets-container #objets {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.objets-container h3 {
    font-size: 24px;
    text-align: center;
}

.objets-container #objets .inventory-item {
    position: initial;
    transform: none;
}

.ui-arena {
    display: grid;
    grid-template-columns: 1fr 8fr 1fr;
    grid-template-rows: 1fr 8fr 1fr;
    height: 100%;
    padding: 0;
}

#lui {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    grid-template-rows: repeat(8, 1fr);
    height: 100%;
    padding: 0;
}

.bar {
    box-sizing: border-box;
    width: 500px;
    height: 20px;
    padding: 5px;
    background: #000000;
    border-radius: 10px;
    position: relative;
    margin: 20px;
}

.bar-vie {
    background: rgb(170, 39, 18);
    width: 100%;
    height: 10px;
    position: relative;
    transition: width .5s linear;
}

.bar-mana {
    background: rgb(53, 111, 197);
    width: 0%;
    height: 10px;
    position: relative;
    transition: width .5s linear;
}

#p1 {
    grid-row: 1;
    grid-column: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

#p2 {
    grid-row: 1;
    grid-column: 8;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

#joueur1,
#joueur2 {
    font-size: 1.7rem;
    margin-top: 20px;
    text-align: center;
}

.hit {
    background: rgba(255, 255, 255, 0.6);
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 0px;

    transition: width .5s linear;
}



/* #################################################
   ################## SCENE BOUTIQUE ###############
   ################################################# */

.boutique-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.boutique-container .main-title {
    font-size: 42px;
    margin-bottom: 20px;
}

.container-boutique {
    display: flex;
    height: 630px;
}

#container-vendeur {
    height: 100%;
    width: 380px;
}

#vendeur {
    position: absolute;
    bottom: 5rem;
    width: 200px;
    margin-left: 60px;
}

#round-vendeur {
    border-radius: 50%;
    background-color: #252c36;
    width: 282px;
    height: 263px;
    position: absolute;
    bottom: 4rem;
    left: 5rem;
}

.empty-message {
    background-color: #ffffff;
    color: #000000;
    padding: 20px;
    text-shadow: none;
}

#boutique-items {
    background-color: #ffffff;
    padding: 20px;
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(3, 1fr);
    border-radius: 15px;
    overflow-y: auto;
    height: 100%;
    overflow: visible;
    min-width: 850px;    
}

#bg-sold-gold {
    position: absolute;
    bottom: 3rem;
    left: 5rem;
}

#gold-icon {
    position: absolute;
    bottom: 2.5rem;
    left: 2rem;
    width: 110px;
    height: 75px;
}

#gold {
    position: absolute;
    bottom: 4.2rem;
    left: 9rem;
    width: 170px;
    text-align: right;
}

.item {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 260px;
    height: 320px;
    background-color: #e4d8ca;
    border-radius: 15px;
    border: #574837 2px solid;
    position: relative;
}

.item .bg-text {
    background-color: #f4e8db;
    padding: 10px;
    width: calc(100% - 1rem);
    margin: 0.5rem;
    text-align: center;
    font-size: 15px;
    border-radius: 7px;
    text-shadow: -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000,
        2px 2px 0 #000;
}

.item .price {
    width: calc(100% - 1rem);
    margin: 0.5rem;
    justify-content: center;
    display: flex;
    gap: 1rem;
    align-items: center;
}

.item .price div {
    text-shadow: -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000,
        2px 2px 0 #000;
}

.item .minia-item {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin-top: -25px;
}

.item .minia-item .bg-minia-item {
    background-color: #f4e8db;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    z-index: 1;
    margin-top: -90px;
}

.item .minia-item img {
    z-index: 2;
    width: 190px;
    height: 190px;
}

.item .number-item {
    margin-top: -25px;
    text-shadow: -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000,
        2px 2px 0 #000;
    z-index: 3;
}

.item .rupture {
    position: relative;
    top: -40%;
    left: -2.5%;
    margin-top: -5rem;
    text-align: center;
    z-index: 4;
    background: #5d322f;
    padding: 15px;
    font-size: 25px;
    width: 105%;
    border-radius: 10px;
    text-shadow: -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000,
        2px 2px 0 #000;
    transform: rotate(4deg);
}

#menu {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    text-align: center;
    position: absolute;
    top: 10rem;
    left: -0.7rem;
    width: 440px;
}

#menu div {
    cursor: pointer;
    width: 100%;
    font-size: 20px;
    text-shadow: -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000,
        2px 2px 0 #000;
}

#menu .actif {
    padding: 25px 0;
    border-radius: 15px;
    background-color: #24b517;
    border: #000000 3px solid;
}



/* CLASSEMENT */

.container-classement {
    background-color: #e8e8e0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    border-radius: 15px;
    overflow-y: auto;
    padding: 30px;
    max-height: 700px;
    width: 100%;
  }
  .container-info {
    display: flex;
    background-color: #ced0c8;
    width: 100%;
    gap: 1rem;
    align-items: center;
    padding: 10px;
    border-radius: 15px;
    justify-content: space-between;
  }
  .container-info * {
    text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000,
      1px 1px 0 #000;
  }
  
  .container-level {
    position: relative;
  }
  .container-level img {
    width: 40px;
    height: 40px;
  }
  .container-level .level {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    font-size: 14px;
  }
  .muted {
    font-size: 11px;
    color: #3d3e3d;
    text-shadow: none;
  }
  .rank {
    padding: 5px;
    border-radius: 5px;
  }
  .rank-gold {
    background-color: #f8d000;
    border: 2px solid rgb(255, 255, 255);
  }
  .rank-silver {
    background-color: #c0c0c0;
    border: 2px solid rgb(255, 255, 255);
  }
  .rank-bronze {
    background-color: #cd7f32;
    border: 2px solid rgb(255, 255, 255);
  }
  .left-info,
  .right-info {
    display: flex;
    gap: 2rem;
    align-items: center;
  }
  .container-xp {
    position: relative;
    padding: 5px 40px 5px 10px;
    border-radius: 5px;
    background-color: #78936e;
    border: 2px solid rgb(255, 255, 255);
  }
  .container-xp img {
    position: absolute;
    width: 40px;
    height: 40px;
    right: -10px;
    top: -5px;
  }
  .stats {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
  }



/* #################################################
   ################## SCENE Personnages ###############
   ################################################# */

#selection {
    width: 35%;
    height: 100%;
    overflow-y: auto;
}

#charactercreation {
    width: 1200px;
    height: 800px;
}

.character {
    display: flex;
    width: 100%;
    background: #ffffff30;
    border: 3px solid #29090a;
    cursor: pointer;
    &:hover {
        background: white;
        color: black;
    }
}

.selected {
    background: #ffffff93;
    border: 3px solid #752b0e ;
}

.apercu {
    width: 150px;
}

.details {
    display: flex;
    flex-direction: column;
}

#creation {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 20px;
    border: 5px solid var(--clr-effect);
    padding: 20px;
    width: 65%;
    height: 100%;
}

.apercucreer {
    width: 350px;
}

#retour {
    margin: 12px auto;
    font-size: 32px;
}
