
:root {
    --primary-color: #F29F05;
    --secondary-bg-color: rgba(0, 0, 0, 0.7);
    --th-bg-color: rgba(0, 30, 30, 0.7);
    --btn-bg-color: rgba(0, 0, 0,0.5);
    --btn-bg-color-hover: rgba(59, 59, 66, 0.232);
    /*--inventory-label: "Weight: 0/100";*/
    --inventory-label: "Inventory";
    --leaderboard-label: "Street Rank:";
}
/* Fonts */
@font-face {
    font-family: 'Pricedown BL';
    src: url('../font/pricedownbl.otf') format('opentype');
}

/* Base & Layout */
body {
    margin: 0;
    padding: 0;
    background-color: black;

}
.body-container {
    padding: 10px;
    height: 100vh;
    display: flex;
    flex-direction: column;
    background: #000 url('../img/neon_city_2.png') center center/cover;
    color: var(--primary-color);
    font-family: "Arial", sans-serif;
}

.no-select {
    user-select: none;
}

/* Containers */
.container {
    max-width: 100%;
    margin: 0 auto;
    text-align: center;
    background-color: var(--secondary-bg-color);
    padding: 10px;
    border: 2px solid var(--primary-color);
    border-radius: 5px;
}

/* Start Container */
#startContainer {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    max-width: 100%;
    width: 80vh;
    font-size: 2rem;
    min-width: 800px;
    border-radius: 15px;
    margin: auto auto;
}
#startContainer:hover {
    box-shadow: 0 0 10px var(--primary-color);
    transform: scale(1.1);
    cursor: pointer;
    animation: glowing 1s infinite alternate;
    

}

#startContainer > select {
    height:40px;
    width: 80px;
    font-size: 2rem;
    border: 2px solid var(--primary-color);
    background-color: black;
    color: var(--primary-color);
    text-align: center;
}
#startContainer > input {
    color: white;
    font-size: 1.8rem;
    background-color: black;
    font-weight: bold;
    text-align: center;

}
#startContainer > button {
    font-size: 1.8rem;
    padding: 10px;
    color: var(--primary-color);
    background-color: var(--secondary-bg-color);
    border: 2px solid var(--primary-color);
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s, text-shadow 0.3s;
}


main {

    display: flex;
    flex-wrap: wrap-reverse;
    align-items: center;
    justify-content: center;
    
    
}

/* Event Card */
#eventcard {
    display: none;
    position: relative;
    background: url('../img/eventcard_backs/4.png') no-repeat center center/cover;
    width: calc(180px + 1vw);
    height: calc(270px + 1vh);
    box-shadow: 0 0 50px var(--primary-color);
    transition: transform 0.3s ease, box-shadow 1s infinite alternate;
}


    
/* Event Card Interactions */
#eventcard:hover {
    transform: scale(1.1);

    cursor: pointer;
    animation: glowing 1s infinite alternate;
    
}
@keyframes glowing {
    0% {
        box-shadow: 0 0 50px var(--primary-color);
    }
    100% {
        box-shadow: 0 0 10px #ffffff, 0 0 30px #ffffff, 0 0 50px var(--primary-color), 0 0 70px var(--primary-color), 0 0 100px var(--primary-color);
    }
  }


.game-container {
    max-width: 100%;
    min-width: 500px;
    display: none;
}
#playerCityDisplay {
    min-height: 20px;
    font-size: 0.8rem;
    
}
#playerTurn {
    font-size: 1.5rem;
}

    table {
        width: 100%;
        border-collapse: collapse;
        background-color: rgba(0, 0, 0, .7);
    }

    th, td {
        border: 1px solid var(--primary-color);
        padding: 0.2rem 0.4rem;
        text-align: center;
        background-color: var(--table-bg-color);
    }

    th {
        background-color: var(--th-bg-color);
        cursor: pointer;
    }

    td {
    
        background-color: black;
        color: white;
    }

    button {
        margin-top: 10px;
        background-color: var(--btn-bg-color);
        color: var(--primary-color);
        border: 2px solid var(--primary-color);
        padding: 0.3rem 0.8rem;
        cursor: pointer;
        font-weight: bold;
        font-size: 1rem;
        transition: background-color 0.3s, text-shadow 0.3s;
    }

button:hover {
    background-color: var(--btn-bg-color-hover);
    text-shadow: 0 0 4px var(--primary-color);
}




    #player-container .container {
        width: 70vw;
        max-width: 250px;
        margin: 0.5rem; /* Spacing between containers */
        height: auto; /* Set to auto for better scaling */
        text-align: center;
        background-color: var(--secondary-bg-color);
        padding: 10px;
        border: 2px solid var(--primary-color);
        border-radius: 5px;
    }
    #marketBoard {
        /* */
        display: flex;
        justify-content: center;
        gap: 15px;
        align-items: center;
        padding: 10px;
           
    }




    /* Addon day 2 */
    label {
        display: block;
        margin-top: 5px;
    }

    #startCash {
        margin-top: 5px;
        padding: 3px;
        color: var(--primary-color);
        background-color: var(--secondary-bg-color);
        border: 2px solid var(--primary-color);
    }

    .player-cash-display {
        font-size: 1.8rem;
        margin-top: 10px;
        font-weight: bold;
    }


    .buy-btn, .sell-btn {
        margin-right: 3px;
        border-radius: 20%;
        background-color: black;
        color: rgba(255,255,255,0.9)
        
    }


    /* Player Inventory Styling */

    .player-picture {

        width: 25%;
        aspect-ratio: 1/1;
        border-radius: 5px;
        margin-bottom: 10px;
        border: 2px solid var(--primary-color);
        box-shadow: 0 0 10px var(--primary-color);
    }

    #player-container {
        display: flex;
        flex-wrap: wrap;
        justify-content: space-around; /* Distributes player containers evenly */
        margin-top: 30px; /* Provide some space from the game board */
        border-top: 2px dashed var(--primary-color); /* Dashed line to distinguish sections */
        padding-top: 10px; /* Padding at the top */

       
    }

    #player-container .container {
        background-color: rgba(0, 0, 0, 0.8); /* Make it slightly darker for contrast */
        position: relative; /* Set to relative to allow pseudo elements */
        transition: transform 0.3s, box-shadow 0.3s; /* Smooth hover effect */
       
    }

    #player-container .container:hover {
        transform: translateY(-5px); /* Lift the container a bit on hover */
        box-shadow: 0 5px 15px var(--primary-color);/* Add a shadow to make it pop out */
        transform: scale(1.2); /* Set to 1 to allow scaling on hover */
        
    }

    #player-container .container::before {
        content: var(--inventory-label);
        display: block;
        position: absolute;
        top: -20px; /* Position it above the container */
        left: 50%;
        transform: translateX(-50%); /* Center it */
        background-color: var(--primary-color);
        color: #000; /* Black text */
        padding: 2px 8px;
        border-radius: 5px;
        font-weight: bold;
    }

    .player-name-label {
        font-size: 1.8rem;
        font-weight: bold;
        margin-bottom: 5px; /* Space between name and the rest */
    }

    .player-name-input {
        margin-bottom: 5px; /* Space after the input field */
    }
    .player-name-input input {
        animation: glowing 0.6s infinite; /* Animation to create the flickering effect */
    }
    

    .player-cash-display {
        font-size: 2.2rem;
        color: white;
        background-color: rgba(0, 0, 0, 0.7); /* A background to distinguish from the rest */
        padding: 3px 8px;
        margin-bottom: 5px;
        border-radius: 5px;
    }

    .player-inventory {
        display: flex;
        flex-direction: column; /* Stack drug types vertically */
        align-items: center; /* Center them */
        border-top: 1px solid var(--primary-color); /* Separate name and cash from drugs */
        padding-top: 5px; /* Padding for the top */
        margin-top: 5px; /* Margin at the top */
        font-size: 1.5rem;
    }

    .buy-btn, .sell-btn {
        margin: 3px; /* Space around the buttons */
        padding: 3px 8px; /* Bigger buttons are easier to click */
        font-size: 0.8rem; /* Clearer labels */
    }

    /* Improve visibility of input field and its placeholder */
    .player-name-field {
        background-color: rgba(0, 0, 0, 0.7);
        color: var(--primary-color);
        border: 2px solid var(--primary-color);
        border-radius: 5px;
        padding: 3px 8px;
    }

    .player-name-field::placeholder {
        color: rgba(255, 255, 255, 1); /* Slightly faded placeholder */
    }

    /* Debug styles */
    .cash-variables {
        margin-top: 5px;
        padding: 3px;
        color: var(--primary-color);
        background-color: var(--secondary-bg-color);
        border: 2px solid var(--primary-color);
    }
    .debug-container {
        display: none;
        border: 2px solid var(--primary-color);
        background-color: black;
        padding: 20px;
        margin-top:20px;
    }
    .debug-container > p {
        color: white;
        font-weight: bold;
        font-size: 1.2rem;
        

    }

#game-title{

        text-align: center;
        font-size: 8em;
        color: white;
        text-shadow: 0 0 3px var(--primary-color);
        text-shadow: 10px 10px 12px black;
        margin-bottom: 10px;
        font-family: 'Pricedown BL', monospace;
        margin-top: 0px;
        margin-bottom: 3vh;
  
    }

    
#game-interface {
  /**/
}

.hightlight-city {
    font-weight: bold;
    font-size: 2rem;
}

.notactive-city {
 opacity: 0.0;

}
/* MEDIA QUERIES */

@media screen and (min-width: 1824px) {
    #eventcard {
        left: 5vw;
    }
}
/* Media queries for larger screens */
@media screen and (min-width: 768px) {
    h1 {
        font-size: 1.5rem;
    }

    th {
        font-size: 1.5rem;
    }

    td, button {
        font-size: 1.2rem;
        
    }
}


@media screen and (max-width: 768px) {
    #startContainer {
        width: 80vw; /* Skaleres ned */
        height: 80vh; /* Skaleres ned */
        font-size: 1.5rem; /* Skaleres ned */
    }

    body {
        padding: 0; /* Fjernet padding */
    }

    #eventcard {
        width: calc(150px + 2vw); /* Skaleres ned */
        height: calc(250px + 2vh); /* Skaleres ned */
    }

    .game-container {
        padding: 5px; /* Tilføjet */
    }

    h1, th, td, button {
        font-size: 1rem; /* Skaleres ned */
    }
    #marketBoard {
        flex-wrap: wrap;
    }
}

@media screen and (min-width: 769px) and (max-width: 1024px) {
    /* ... Tilføj regler for tablets ... */
}

@media screen and (min-width: 1025px) {
    /* ... Tilføj regler for store skærme ... */
}
@media screen and (max-width: 1540px) {
    /* ... Tilføj regler for store skærme ... */
    .leaderboard-container {
        order: -1;
        margin-top: 40px;
    }
    .leaderboard-container::before {
        font-size: 0.8rem;
    }

}



.debug-content {
    display: none;
    overflow: hidden;
    transition: max-height 0.2s ease-out;
    color: white;
  }
.debug-toggle {
    text-align: center;
    color: black;
    user-select: none;
}

.eventcard-popup {
    display: none;
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
  }
  
  .eventcard-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    
    /* Applying similar styles as your #eventcard */
    background-color: black;
    width: calc(180px + 5vw);
    height: calc(270px + 5vh);
    box-shadow: 0 0 50px var(--primary-color);
    border-radius: 8px;
    transition: transform 0.3s ease, box-shadow 1s infinite alternate;
    
    /* Adding content padding and other styling */
    padding: 20px;
    text-align: center;
  }

  .eventcard-content p {
    display: inline;
    overflow: hidden;
    white-space: wrap;
    border-right: 2px solid;
    animation: cursorBlink 1s infinite;
  }
  
  @keyframes cursorBlink {
    0%, 100% {
      border-color: transparent;
    }
    50% {
      border-color: black;
    }
  }
 
.leaderboard-container {
    display: none;
    align-self: flex-end;
    width:17%;
    position: relative;
    min-width: 200px;
    order: 0;
    
}

.leaderboard-container::before {
    content: var(--leaderboard-label);
    display: block;
    position: absolute;
    top: -20px; /* Position it above the container */
    left: 50%;
    transform: translateX(-50%); /* Center it */
    background-color: var(--primary-color);
    color: #000; /* Black text */
    padding: 2px 8px;
    border-radius: 5px;
    font-weight: bold;
}
.leaderboard {
    display: flex;
    flex-direction: column;
    margin-right: 10px;
    justify-self: flex-start;
    


}

.leaderboard-entry {
    display: flex;
    flex-direction: row;
    gap:10px;
    
}
.player-picture-leaderboard{
    width: 15%;
    aspect-ratio: 1/1;
    border-radius: 5px;
    margin-bottom: 10px;
    border: 2px solid var(--primary-color);

}
/* Prepared to implement a story element later */
.story {
    display: flex;
    flex-direction: column;
    margin-top: 50px;
    font-size: 0.8rem;
    background-color: black;
    color: white;
    padding: 20px;
    border: 5px solid rgba(255, 255, 255, 0.226);
    border-radius: 5px;
    

}
.story h3 {
    font-size: 2rem;
    text-decoration: underline;
}

.drug-lord-title {
    color: gold;
   
    text-shadow: 0 0 10px red, 0 0 20px orange, 0 0 30px yellow, 0 0 40px gold, 0 0 50px gold, 0 0 60px gold, 0 0 70px gold, 0 0 80px gold; /* Multiple shadows for the glowing effect */
    animation: glowtext 2s infinite; /* Animation to create the flickering effect */
}

@keyframes glowtext{
    0%, 100% {
        text-shadow: 0 0 5px red, 0 0 10px orange, 0 0 15px yellow, 0 0 20px gold;
    }
    50% {
        text-shadow: none; /* No shadow at the midpoint of the animation for the flickering effect */
    }
}

.casino-container {
    display: flex;
    justify-content: center;

    margin: 0 auto;
    scale: 1;
    margin: 10px;
    padding: 20px;
    border-radius: 5px;
    background-color: var(--secondary-bg-color);
    font-size: 2rem;
    color: var(--primary-color);
}
.casino-container button {
    margin: 10px;
    padding: 10px;
    font-size: 1.5rem;
    color: white;
}

#battleContainer {
    scale: 1;
    display: flex;
    border: 2px solid var(--primary-color);
    justify-content: space-between;
    font-size: 2rem;
    border-radius: 15px;
    color: var(--primary-color);
    text-align: center;
   
}

.battleContainer-players {
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.battleContainer-players h2 {
    font-family: "Pricedown BL", sans-serif;
    font-size: 3rem;
}
.battleContainer-players > button {
    margin: 35px;
    padding: 10px;
    font-size: 1.5rem;
    animation: glowing 1s infinite alternate;
}

.battleContainer-players > button:hover {
    background-color: var(--btn-bg-color-hover);
    text-shadow: 0 0 4px var(--primary-color);
}

.battleContainer-players > select {
    font-size: 1.5rem;
    border: 2px solid var(--primary-color);
    background-color: black;
    color: var(--primary-color);
    text-align: center;
    border-radius: 15px;
}

.battle-player-picture {
    background-image: url("../img/characters/1.png");
    background-position: center;
    background-size: cover;
    width: 20%;
    aspect-ratio: 1/1;
    border-radius: 5px;
    margin-bottom: 10px;
    border: 2px solid var(--primary-color);
    box-shadow: 0 0 10px var(--primary-color);
    margin: 2%;
}

.battle-player-picture:nth-child(1) {
    background-image: url("../img/characters/2.png");
}


#player1Image::before, #player2Image::before {
    display: block;
    width: 50%;
    position: relative;
    top: -20px; /* Position it above the container */
    left: 50%;
    transform: translateX(-50%); /* Center it */
    background-color: var(--primary-color);
    color: #000; /* Black text */
    padding: 2px 8px;
    border-radius: 5px;
    font-weight: bold;
    font-size: 1.5rem;
    border: 2px solid black;
    box-shadow: 0 0 10px black;
}

#player1Image::before {
    content: "DEFENDER";
}
#player2Image::before {
    content: "ATTACKER";
}

.player-gender-select{

    background-color: black;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    border-radius: 5px;
    margin: 5px;
}
/* Bank modal */
.modal {
    display: none;
    position: fixed;
    font-weight: bold;
    z-index: 999;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
    font-size: 1.5rem;

  }
  
  .modal-content {
    background-image: url("../img/bank/background.png");
    background-size: cover;
    background-position: center;
    margin: 15% auto;
    padding: 30px;
    width: 20%;

    background-color: black;
    border: 2px solid var(--primary-color);
    border-radius: 15px;
  }

  .modal-content h2 {
    display: none;
    font-family: "Pricedown BL", sans-serif;
    text-decoration: underline;
    font-size: 4rem;
    text-align: center;
    color: white;

  }
  .modal-content p {
    text-shadow: 2px 2px black;
    font-size: 3rem;
    text-align: center;
    background-color: rgba(0, 0, 0, 0.692);
    border-radius: 15px;
    
    
  }
  .modal button {
    margin: 5px;
    padding: 5px;
    font-size: 1rem;

  }

  .modal button:hover {
    background-color: var(--btn-bg-color-hover);
    text-shadow: 0 0 4px var(--primary-color);
  }

  .modal input {
    margin: 5px;
    padding: 5px;
    font-size: 1rem;
    background-color: black;
    color: white;
    border: 1px solid var(--primary-color);
    border-radius: 5px;
    width: 10vw;
  }

  .modal input::placeholder {
    color: rgba(255, 255, 255, 0.63);
  }

  .close {
    color: black;
    float: right;
    font-size: 2.5rem;
 
  }



  #end-game-graph {

 
    margin: 0 auto;
    width:40%;
    height: 40%;


  }
#dayDisplay {
    font-size: 2rem;

    color: var(--primary-color);
    text-shadow: 0 0 10px black;
    margin: 10px;
    text-align: center;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    padding: 5px;
    box-shadow: 0 0 10px var(--primary-color);
}
.current-player {
    transform: scale(1.1);
  
    animation: glowing-small 1.5s infinite reverse;

}

@keyframes glowing-small {
    0% {
        box-shadow: 0 0 15px #51ff00;
    }
    100% {
        box-shadow: 0 0 15px #51ff00, 0 0 40px var(--primary-color);
    }
  }

  .end-game-button {
    font-size: 1rem;
    padding: 10px;
    color: var(--primary-color);
    background-color: var(--secondary-bg-color);
    border: 2px solid var(--primary-color);
    border-radius: 25px;
    cursor: pointer;
    transition: background-color 2s, text-shadow 2s;
    margin: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
  }

  .rules {
    position: absolute;
    left: 0;
    top: 0;
    width: 50px;
    height: 50px;
    padding: 10px;
    font-family: "PriceDown BL", sans-serif;
    font-size: 2rem;
    cursor:pointer;
  }

  .rules:hover {
    color: white;
    text-shadow: 0 0 10px var(--primary-color);
    user-select: none;
    
  }

  /* Specific styling for Big presentation screen */

  #game-title {
    font-size: 8em!important;
    margin-bottom: 8vh!important;
  }
  
/* Rules Container 1 
#rules-container {
    display: none;
    position: fixed;
    left: 5%;
    top: 5%;
    width: 90%;
    height: 90%;
    z-index: 100;
    background-color: var(--secondary-bg-color);
    border: 2px solid var(--primary-color);
    border-radius: 5px;
    padding: 10px;
    overflow-y: auto;

  }
  
  #rules-button {
    cursor: pointer;
    animation: glowing 1s infinite alternate;
  }
  
  #rules-container h2,
  #rules-container p {
    color: var(--primary-color);
  }
  */

  /* Rules Container 2 */
  #rules-container {
    display: none;
    position: fixed;
    left: 5%;
    top: 5%;
    width: 50%;
    height: 50%;
    background-color: rgba(15, 15, 15, 1);
    color: var(--primary-color);
    overflow-y: scroll;
    border: 2px solid var(--primary-color);
    border-radius: 10px;
    padding: 20px;
  }
  
  #rules-container li {
    color: white;
    margin-left: 5%;
    padding: 0.2rem;
  }

  #rules-container h3 {
    font-family: "Pricedown BL", sans-serif;
    font-size: 4rem;
    text-align: center;
    color: white; 
  }

  #rules-container h4 {
    font-family: "Pricedown BL", sans-serif;
    font-size: 2.5rem;
    color: var(--primary-color);
    border-bottom: 1px solid var(--primary-color);
  }

  .glowtext {
   scale: 1.3;
    animation: glowtext 2s infinite;
  }

.news-container {
    display: inline-flex;
    background-color: var(--secondary-bg-color);
    text-shadow: 0 0 15px black;
    color: var(--primary-color);
}

.news {
    font-size: 20px;
   
}



