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

html, body {
    padding: 0;
    margin: 0;    
    background: #0B070D;
    display: flex;
    flex-direction: column;
    align-items: center;
    color:#FEFAEB;
    font-family: 'MedievalSharp', cursive;
}

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

img{
    max-width: 100%;
    object-fit: contain;
    object-position: 50% 50%;
}

.character-card {
    height:10rem;
    max-height:70vh;
    margin:.6rem;
    width:80vw;
    max-width: 99vw;
    padding: 1vh 1vw;
    font-size: 1.6rem;
    color: #FEFAEB;
    border-radius: 14px;
    position: relative;
    background: #231d24;
    text-align: center;
    border: 0.08rem solid #000721;
    box-shadow: inset 0px 0px 6px 2px rgba(100,100,100,0.2),
                0px 0px 10px rgba(117,182,214,0.2);
}

.name {
    margin: 1vh 0;
    width:100%;
    letter-spacing: 0.08em;
    font-size: 90%;
}

.avatar {
    width: auto;
    max-width:100%;
    height: 20vw;
    max-height:45%;
    border: 2px solid #000721;
    opacity: 0.8;
    border-radius: 10px;
    background-color: #1C2B36;
}

.health {
    font-size:1.1rem;
    font-weight: normal;
    width:90%;
    text-align: left;
    margin: 1vh 5%;
    color:#ccc;
    letter-spacing: 0.03em
}

.health b {
    font-weight: bold;
    color:#FEFAEB;
}

.health-bar-outer {
    background: #171217;
    height: 1vh;
    width:90%;
    margin: 0 5%;
    border-radius: 2px;
}

.health-bar-outer .health-bar-inner {
    background: #466d34;
    height: 100%;
    border-radius: 2px;
}

.health-bar-outer .health-bar-inner.danger {
    background:#f00;
}

.dice-container {
    width:100%;
    height: 20%;
    position: absolute;
    bottom:0;
    left:0px;
    right:0;
    background: #151F28;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: .5rem;
    border-bottom-left-radius: 14px;
    border-bottom-right-radius: 14px;
}

.dice, .placeholder-dice{
    height:5.5vh;
    width:5.5vh;
    background: #FEFAEB;   
    border-radius: 5px;
    border:1px solid #666;
    color:#000721;
    text-align: center;
    line-height: 6vh;
}

.dice-container .placeholder-dice{
    background-color: transparent;
}

button {
    font-family: 'MedievalSharp', cursive;
    background-color: #FAA00F;
    border: 2px solid #f00;
    outline: none;
    padding-left:5vw;
    padding-right:5vw;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    color:#f00;
    height:9vh;
    box-shadow: 0px 6px 10px -4px rgba(0,0,0,0.4);
}

button:focus { outline: 0 }

a {
    margin-top: .1rem;
    font-family: 'MedievalSharp', cursive;
    background-color: #fcc02a;
    border: 2px solid #963404;
    outline: none;
    padding:1rem;
    padding-left:5vw;
    padding-right:5vw;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    color:#963404;
    box-shadow: 0px 6px 10px -4px rgba(0,0,0,0.4);
    align-items: center;
}

.end-game{
    margin-top: 25%;
    text-align: center;
}

.end-emoji{
    font-size: 80px;
}

@media only screen and (min-width:550px){
    main {
         flex-direction: row;
         margin:.2rem;
         justify-content: center;
         width:86vw;
         gap: 2rem;
     } 
 
     .character-card {
         border: 0.2rem solid #000721;
         height:60vw;
         min-height: 300px;
         width:37vw;
     }
 
     .name {
         margin: 2vh 0;
         font-size: 100%;
     }
 
     .avatar {
         width: 65vw;
     }
     
     .health {
        margin: 2vh 5%;
    }

    .dice-container {
        height: 20%;
        border-bottom-left-radius: 3px;
        border-bottom-right-radius: 3px;
    }

    .dice-container .dice, .dice-container .placeholder-dice{
        height:8vh;
        width:8vh;
        line-height: 8.5vh;
    }

    button {
        margin-top: .1rem;
    }

}