*,
*::before,
*::after {
    font-family: "Eagle Lake", serif;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Imported Fonts */
.eagle-lake-regular {
    font-family: "Eagle Lake", serif;
    font-weight: 400;
    font-style: normal;
}

.medievalsharp-regular {
    font-family: "MedievalSharp", cursive;
    font-weight: 400;
    font-style: normal;
}

:root {
    /* - Fonts Setup - */
    --main-title-font-family: "MedievalSharp";
    --main-title-font-size: 2rem;
    --main-title-font-weight: bold;
    --main-title-font-color: #000;

    --form-item-title-font-family: "MedievalSharp";
    --form-item-title-font-size: 1.2rem;
    --form-item-title-font-weigth: bold;
    --form-item-title-font-color: #000;

    --value-big-font-family: "MedievalSharp";
    --value-big-font-size: 1.7rem;
    --value-big-font-weigth: bold;
    --value-big-font-color: ;

    --value-small-font-family: "MedievalSharp";
    --value-small-font-size: 1rem;
    --value-small-font-weigth: ;
    --value-small-font-color: ;

    --info-name-font-family: "MedievalSharp";
    --info-name-font-size: 0.9rem;
    --info-name-font-weigth: ;
    --info-name-font-color: ;

    --inputs-text-font-family: "MedievalSharp";
    --inputs-text-font-size: ;
    --inputs-text-font-weigth: ;
    --inputs-text-font-color: ;

    --inputs-num-font-family: "MedievalSharp";
    --inputs-num-font-size: ;
    --inputs-num-font-weigth: ;
    --inputs-num-font-color: ;

    --select-text-font-family: "MedievalSharp";
    --select-text-font-size: ;
    --select-text-font-weigth: ;
    --select-text-font-color: ;

    --buttons-font-family: "MedievalSharp";
    --buttons-font-size: ;
    --buttons-font-weigth: ;
    --buttons-font-color: ;

    /* - Containers  - */

    /* -- Body -- */
    --body-background-color: hsl(10 10% 10%);

    /* -- Header -- */
    --header-margin: 3rem auto 1rem;
    --header-padding: 1.5rem 1rem;
    --header-border: none;
    --header-border-radius: 0.6rem;
    --header-gap: 0.5rem;
    --header-background-color: #fff;

    /* -- Form Setup -- */
    --form-grid-template-column: 1fr 1fr;
    --form-margin: 1rem auto;
    --form-padding: 2rem 1.5rem;
    --form-border: none;
    --form-border-radius: 0.6rem;
    --form-gap: 1rem;
    --form-background-color: hsl(210 40% 30%);

    --form-item-padding: 1rem;
    --form-item-border: 0.2rem solid black;
    --form-item-border-radius: 0.5em;
    --form-item-background-color: hsl(0 100% 100%);

    --value-big-width: 3.2rem;
    --value-big-heigth: 2.8rem;

    --value-small-width: 2.5em;
    --value-small-heigth: 2em;

    /* --- Form Item - Name --- */
    --form-name-: ;

    /* --- Form Item - Status --- */
    --form-status-: ;

    /* --- Form Item - Armor --- */
    --form-armor-: ;

    /* --- Form Item - Effects --- */
    --form-effects-: ;

    /* --- Form Item - Weapons --- */
    --form-weapons-: ;

    /* --- Form Item - Skills --- */
    --form-skills-: ;

    /* --- Form Item - Attributes --- */
    --form-attributes-: ;

    /* --- Form Item - Inventory --- */
    --form-inventory-: ;

    /* --- Form Item - Description --- */
    --form-descriptions-: ;


    /* Dices */
    --dice-value-font-family: "MedievalSharp";

}

/* - Global Classes - */

.hidden {
    display: none !important;
}

.center {
    display: grid;
    align-content: center;

    text-align: center !important;
}

/* Disable Arrows in Num. Inputs */
.no-arrow::-webkit-outer-spin-button,
.no-arrow::-webkit-inner-spin-button {
    -webkit-appearance: none;
}

body {
    width: min(1000px, 90vw);
    margin: auto;

    background-color: var(--body-background-color);
}

/* - Header - */

.character-header {
    display: flex;
    flex-direction: column;
    justify-content: center;

    margin: var(--header-margin);
    padding: var(--header-padding);
    border: var(--header-border);
    border-radius: var(--header-border-radius);
    gap: var(--header-gap);
    background-color: var(--header-background-color);
}

.main-title {
    font-family: var(--main-title-font-family);
    font-size: var(--main-title-font-size);
    font-weight: var(--main-title-font-weight);
    color: var(--main-title-font-color);
}

/* -- Turn Controls -- DISABLED --

#turn-controls {
    display: none;
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap: 20px;
}

.turn-btn {
    padding: 8px 15px;
}

*/

/* - Form Setup - */

#form-character {
    display: grid;
    grid-template-columns: var(--form-grid-template-column);
    justify-content: center;
    overflow: hidden;
    width: 100%;

    margin: var(--form-margin);
    padding: var(--form-padding);
    gap: var(--form-gap);
    border: var(--form-border);
    border-radius: var(--form-border-radius);
    background-color: var(--form-background-color);
}

.form-column {
    display: flex;
    flex-direction: column;

    gap: 1rem;
}

.form-item {
    padding: var(--form-item-padding);
    border: var(--form-item-border);
    border-radius: var(--form-item-border-radius);
    background-color: var(--form-item-background-color);
}

.item-title {
    grid-column: 1 / -1;

    margin-bottom: 0;
    font-family: var(--form-item-title-font-family);
    font-size: var(--form-item-title-font-size);
    font-weight: var(--form-item-title-font-weigth);
    color: var(--form-item-title-font-color);
}

.item {
    display: grid;
    justify-content: center;
    justify-items: center;
    align-content: center;
    align-items: center;
    border: 1px solid black;
    border-radius: 0.3rem;
    gap: 0.5rem;

    padding: 0.5em;
}

.containers {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.container-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0 0.6rem 0;
    border-bottom: 1px solid black;
}

.container-subitem {
    display: grid;
    grid-template-columns: minmax(1fr 9rem) auto auto auto;
    grid-auto-flow: column;
    justify-content: space-between;
    padding: 0.6rem;
    gap: 0.3rem;
}

.container-item .item-description {
    width: 90%;
    resize: none;
    padding: 0.4rem;
}

.info-text {
    font-family: var(--info-name-font-family);
    font-size: var(--info-name-font-size);
    font-weight: var(--info-name-font-weight);
    color: var(--info-name-font-color);
}

.value-big {
    font-family: var(--value-big-font-family);
    font-size: var(--value-big-font-size);
    font-weight: var(--value-big-font-weigth);
    color: var(--value-big-font-color);

    width: var(--value-big-width);
    height: var(--value-big-heigth);

    border: 0.1rem solid #bbb;
    border-radius: 0.2rem;
}

.value-small {
    font-family: var(--value-small-font-family);
    font-size: var(--value-small-font-size);
    font-weight: var(--value-small-font-weigth);
    color: var(--value-small-font-color);

    width: var(--value-small-width);
    height: var(--value-small-heigth);
}

.item-name {
    font-family: var(--inputs-text-font-family);
    padding: 0.4rem;
}

.select-option {
    font-family: var(--select-text-font-family);
}

.item-description,
.armor-description {
    font-family: var(--inputs-text-font-family);
    height: 6rem;
    grid-row: 2;
    padding: 0.3rem 0 0.7rem 0;
}

.action-btn,
.roll-btn {
    font-family: var(--buttons-font-family);
    font-weight: 600;
    padding: 0.4rem 1rem;
    border: 0.15rem solid #000;
    border-radius: 0.2rem;
    background-color: hsl(40 80% 70%);
    color: #000;
    cursor: pointer;
}

.action-btn:hover {
    background-color: hsl(40 80% 90%);
}

.add-item-btn {
    display: block;
    margin: auto;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    border: 1px solid #0007;
    background-color: #fff;
}

.add-item-btn:hover {
    background-color: #eee;
}

.expand-btn {
    display: block;
    margin: auto;
    width: 1.5rem;
    height: 1.5rem;
    font-size: 1rem;
    border: 1px solid #0009;
    border-radius: 0.2rem;
    background-color: #fff;
    cursor: pointer;
}

.expand-btn:hover {
    background-color: #eee;
}

/* -- Char Name -- */

.form-item.name {
    grid-column: 1 / -1;
}


.name-input {
    width: 100%;
    grid-column: 1 / -1;

    border: none;
    border-bottom: 1px solid black;
    border-radius: 0;
    padding: 0.6rem 0.5rem;
    font-size: 1.7rem;
    font-family: var(--inputs-text-font-family);
    font-weight: bold;
}

.name-input:active,
.name-input:focus,
.name-input:hover {
    border: none;
    border-bottom: 1px solid black;
}

/* -- Char Status -- */

.form-item.status {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5em;
}

.form-item.status .item {
    align-content: space-around;
}

.health {
    width: 4rem;
    height: 3rem;

    font-size: 2.3rem;
}

div.value-big {
    border: 0.1rem solid #bbb;
    background-color: #fff;
}

.calc-pv-container {
    grid-column: 1 / -1;
    justify-self: center;
    display: flex;
    flex-direction: row;
    gap: 0.5rem;
}


/* Health Color Change */
.dying {
    color: hsl(350 50% 40%);
    ;
}

.injuried {
    color: hsl(20 50% 50%);
}

.hurt {
    color: hsl(60 60% 50%);
}

.ok {
    color: hsl(100 45% 50%);
}

.full {
    color: hsl(160 45% 50%);
}

.overheal {
    color: hsl(200 45% 50%);
}

/* -- Char Icon -- */
#character-icon {
    display: grid;
    justify-items: center;
    align-items: center;
    gap: 1em;
    border: 1px solid black;
}

.avatar {
    width: 7em;
    height: 7em;
    border: 1px solid orange;
}

/* -- Char Armor -- */

.armor-description {
    width: 90%;
    resize: none;
    padding: 0.4rem;
}

/* -- Char Attributes -- */
.form-item.attributes {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.roll {
    cursor: pointer;
}

/* --- Att Setup --- */

.att-container {
    width: 16rem;
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    text-align: center;
    border: 1px solid black;
    border-radius: 0.3rem;
    background-color: #fff;
    padding: 2rem;
    margin: 0 auto;
}

.att-list {
    display: grid;
    justify-content: center;
    gap: 0.5rem;
}

.att-item {
    display: grid;
    grid-template-columns: 7rem 1fr;
    align-items: center;
    gap: 1.5rem;
    border: 1px solid black;
    padding: 0.5rem 1rem;
}

.att-input {
    width: 2.5rem;
    height: 2.5rem;
    text-align: center;
    font-size: 1rem;
}

/* -- Char Effects -- */
.form-item.effects {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* -- Char Weapons -- */
.form-item.weapons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* -- Char Skills -- */
.form-item.skills {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* -- Char Inventory -- */
.form-item.inventory {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* -- Char Description -- */

.description-value {
    font-family: var(--inputs-text-font-family);
    display: block;
    width: 95%;
    height: 200px;
    flex-wrap: wrap;
    margin: 10px auto;
    resize: none;
    padding: 5px;
}


/* - Dice Roll - */

.black-bg {
    position: fixed;
    top: 0;
    left: 0;
    display: grid;
    justify-content: center;
    align-content: center;
    width: 100%;
    height: 100%;
    margin: 0 auto;
    background-color: #000a;
}

.dice-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
    padding: 1.5rem 2rem;
    margin: auto;
    background-color: white;
    border: 1px solid black;
    border-radius: 0.3rem;
}

.dices-icon {
    display: flex;
    flex-direction: row;
    gap: 10px;
    justify-content: center;
    margin: 0 auto;
}

.dice-image {
    display: grid;
    width: 70px;
    height: 70px;
    justify-items: center;
    align-items: center;
    text-align: center;
    font-weight: bold;
    font-family: var(--dice-value-font-family);
    font-size: 2rem;
    border: 0.15rem solid #000;
    border-radius: 0.3rem;
}

.dice-value {
    font-family: var(--dice-value-font-family);
}

.dice-message {
    font-family: var(--dice-value-font-family);
}

.dice-result {
    font-family: var(--dice-value-font-family);
    font-size: 2rem;
    text-align: center;
}

.disaster {
    color: hsl(350 50% 40%);
}

.low {
    color: hsl(0 50% 50%);
}

.normal {
    color: hsl(80 50% 50%);
}

.high {
    color: hsl(150 50% 50%);
}

.extreme {
    color: hsl(250 50% 50%);
}

/* Account Configuration */

#auth-panel {
    display: flex;
    flex-direction: column;
    background-color: #fff;
    padding: 2rem;
    gap: 1rem;
    border-radius: 0.5rem;
    margin: 1rem 0 0 0;
}

#auth-form {
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    gap: 0.5rem;
}

#auth-form .item-name {
    height: 1.6rem;
}

#user-panel {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    background-color: #fff;
    border-radius: 0.5rem;
    padding: 2rem;
    font-family: "MedievalSharp";
    gap: 1rem;
    margin: 1rem 0 0 0;
}

#user-panel p {
    font-weight: bold;
}

@media screen and (max-width: 750px) {
    :root {
        --form-grid-template-column: 1fr;
    }
}

@media screen and (max-width: 1200px) {}