* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-image: url("../../assets/background.jpg");
    background-size: cover;
    background-repeat: repeat-x;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    height: 90%;
    width: 90%;
    margin: auto;
    min-height: 100vh;
    position: relative;
    padding: 10vmin;
}

#container {
    display: grid;
    grid-template-columns: 1fr 0.5fr 1fr 0.5fr 1fr;
    grid-template-rows: 1fr 0.4fr 1fr 0.4fr 1fr;
    gap: 18px;
    width: calc(100% - 25vw);
    align-items: center;
    margin-left: 8%;
}



.card {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 5px solid #333;
    border-radius: 8px;
    transition: transform 0.3s ease;
    cursor: pointer;
    background-size: auto;
    user-select: none;
}

.cardBlank {
    opacity: 60%;
}

#cardContainer {
    position: fixed;
    bottom: 0;
    right: 6vw;
    z-index: 10;

    display: flex;
    flex-direction: column;
    width: 7%;
    min-width: 30px;
    gap: 5%;
}

.cardHeap {
    border: 5px solid #333;
    border-radius: 8px;
    background-size: auto;
    cursor: pointer;
    width: 100%;
    height: 100%;
}

.card:hover {
    transform: scale(1.2);
}

#sidebar {
    width: 6vw;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
    height: 100vh;
    position: fixed;
    top: 0;
    right: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    gap: 2%;
    overflow-y: auto;
}


.junction {
    border: 5px dotted #333;
    border-radius: 4px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: auto;
    user-select: none;
}


.junction-vertical {
    width: 70%;
    margin: 0 auto;
    flex-direction: column;
    max-height: 30vh;
    overflow-y: auto;
    gap: 2%
}


.junction-horizontal {
    height: 60%;
    margin: auto 0;
    flex-direction: row;
    max-width: 30vw;
    overflow-x: auto;
    gap: 2%;
}

.junction-horizontal > img {
    width: 25%;
    flex-shrink: 0;
}

.junction.hidden {
    visibility: hidden
}

.assets {
    width: 100%;
    min-width: 30px;
    user-select: none;
    cursor: pointer;
}

.subasset{
    width: 15%;
    min-width: 10px;
    user-select: none;
}

.notification {
  position: fixed;
  font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
  font-size: large;
  bottom: 20px;
  left: 20px;
  background-color: #333;
  color: white;
  padding: 15px 20px;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  max-width: 30vw;
  z-index: 1000;
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  text-align: center;
}


.notification .progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 5px;
  background-color: #4caf50;
  transition: width 7s linear;
}


.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgb(0,0,0);
    background-color: rgba(0,0,0,0.4);
    align-items: center;
}

.modal-image {
    border: 5px solid #333;
    border-radius: 8px;
    max-width: 25%;
    max-height: 25%;
}


.modal-content {
    padding: 20px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: 5vh;
}

#modal-exchange {
    font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
    font-size: 20px;
    display: none;
    position: fixed;
    z-index: 1;
    left: 50%;
    top: 50%;
    width: 40%;
    height: 40%;
    overflow: auto;
    align-items: center;
    justify-content: center;
    transform: translate(-50%, -50%);
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    background-color: rgba(51, 51, 51, 0.8);
    transition: opacity 0.3s ease, transform 0.3s ease;
    color: white;
    opacity: 85;
}

#modal-exchange p {
    text-decoration: underline;
    text-underline-offset: 4px;
    text-decoration-thickness: 2px;
}
#modal-exchange-content{
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-left: 2%;
}
#exchange-input{
    width: 20%;
}
#dice-selector {
    margin-top: 5%;
    margin-bottom: 2%;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 2%;
    justify-content: center;
}
#exchange-line {
    margin-bottom: 5%;
    margin-top: 5%;
    align-items: center;
    justify-content: center;
    display: flex;
    flex-direction: row;
    gap: 5%;
}

#exchange-validate {
    background-color: #4caf50;
    color: white;
    border: none;
    padding: 2px 4px;
    font-size: 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: 20%;
    height: 10%;
}

#exchange-validate:hover {
    background-color: #218838;
}

.close {
    color: #aaa;
    float: right;
    font-size: 40px;
    font-weight: bold;
}

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


@media (max-width: 768px) {
    body {
        flex-direction: column;
        justify-content: center;
        padding: 10px;
    }

    #container {
        width: 90%;
        margin-right: 3vw;
    }

    .sidebar {
        width: 10vw;
        margin-top: 20px;
        position: static;
    }
}

.red-filter {
    filter: sepia(1) saturate(10) hue-rotate(-50deg) brightness(0.6) contrast(1.5);
}

nav {
    z-index: 10;
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: row;
    gap: 1%;
    align-items: center;
    width: fit-content;
    margin-left: 1%;

}

.slider-container {
    display: flex;
    text-align: center;
    width: fit-content;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.slider-container > img {
    width: 1rem;
}

.slider {
    width: 65%;
    cursor: pointer;
}

.icons {
    width: 2%;
    color: white;
    box-sizing: content-box;
    cursor: pointer;
}

.icons-style{
    background-color: #333;
    color: white;
    padding: 1px 1px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

#modal-rules {
    font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
    font-size: 20px;
    position: fixed;
    z-index: 1;
    left: 50%;
    top: 50%;
    width: 50%;
    height: 50%;
    overflow: auto;
    transform: translate(-50%, -50%);
    padding: 15px 20px;
    border-radius: 5px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    background-color: rgba(106, 111, 122, 0.8);
    transition: opacity 0.3s ease, transform 0.3s ease;
    color: whitesmoke;

}
#modal-rules-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-left: 2%;
}

#header_rules {
    display: flex;
}

.language-selector {
    display: flex;
    gap: 20px;
    font-size: 2.5em;
    cursor: pointer;
    user-select: none;
}

.language-selector span {
    transition: transform 0.2s, opacity 0.2s;
}

.language-selector span:hover {
    transform: scale(1.2);
    opacity: 0.8;
}

h3 {
    margin: 1% 0 2% 0;
}

b {
    color: #333333;
}

#modal-rules-footer {
    display: flex;
    flex-direction: column;
}


.credits {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 0.7em;
    color: #ddd;
}

.credits img {
    height: 25px;
    margin: 2px;
}

.credits a {
    color: #ddd;
    text-decoration: none;
    border-bottom: 1px solid rgba(255,255,255,0.4);
    transition: all 0.2s ease;
}

#gamebox {
    display: flex;
    flex-direction: column;
    position: fixed;
    bottom: 0;
    left: 0;
    z-index: 1000;
    margin-left: 1%;
    align-items: center;
}

#gamebox img {
    width: 7vw;
    transition: transform 0.3s ease;
}

#gamebox img:hover {
    transform: scale(1.1);
}

#buy-me {
    font-family: 'Bangers', sans-serif;
    font-size: 0.9rem;
    text-transform: uppercase;
    color: #F4F4F4;
    background-color: #C39455;
    padding: 0.3rem 0.8rem;
    display: inline-block;
    text-align: center;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 10px;
    text-decoration: none;
}

#buy-me:hover {
    background-color: #D40000;
    color: #FFFFFF;
    transform: scale(1.05);
}

#buy-me:active {
    background-color: #FF3C00;
}




