@import url('https://fonts.googleapis.com/css2?family=Pixelify+Sans:wght@400..700&display=swap');

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    transition: all 0.3s ease;
    font-family: 'Pixelify Sans';
    font-size: 1.5em;
    scroll-behavior: smooth;
}

body {
    background: #f5f5f0;
    padding: 2rem;
    color: #FFFFFF;
    background-image: url('images/background.jpg');
}

table:not(dialog table) {
    width: 100%;
    border-collapse: collapse;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 16px;
}

.wrapper {
    overflow-x: auto;
}

img {
    object-fit: contain;
}

thead {
    background-color: white;
}

th:not(dialog th) {
    padding: 10px 14px;
    text-align: center;
    font-size: 11px;
    font-weight: 500;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid rgba(0,0,0,0.07);
    white-space: nowrap;
    
}

th.sorted-column {
    font-weight: 700;
    color: #000000;
}

table th {
    cursor: pointer;
}

table th:last-of-type, table th:nth-child(3) {
    cursor: default;
}
th:first-child {
    border-top-left-radius: 16px;
}
th:last-child {
    border-top-right-radius: 16px;
}

td:not(dialog td) {
    padding: 10px 14px;
    font-size: 25px;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    vertical-align: middle;
    text-align: center;
}
td:last-child:not(dialog td) {
    display: flex;
    justify-content: center;
}

tr:last-child td {
    border-bottom: none;
}

tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.75);
    color: #000000;
    background-size: 40px 40px;
    cursor: pointer;
}

img {
    display: block;
    border-radius: 4px;
}

/* POPUP */

dialog {
    display: flex;
    flex-direction: column;
    align-items: center;
    border: solid 3px transparent;
    outline: none;
    border-radius: 12px;
    padding: 1em;
    background-origin: border-box;
    background-clip: padding-box, border-box;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
}
::-webkit-scrollbar {
    width: 0;
}

dialog::backdrop {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(1px);
}

dialog ul {
    display: flex;
    align-items: center;
    gap: 0.5em;
}

dialog li {
    margin: 0; padding: 0;
    display: flex;
}
dialog > ul > li:last-child > ul {
    display: flex;
    flex-direction: column;
    align-items: start;
    gap: 10pt;
}

dialog figure {
    display: flex;
    flex-direction: column;
    gap: 15pt;
    align-items: center;
    justify-content: space-between;
}
dialog figcaption:not(ul.types figcaption) {
    font-size: 20pt;
    font-weight: bold;
    color: white;
}
dialog img {
    height: 250pt;
}

dialog th, td {
    font-size: 20pt;
    color: white;
    padding: 0 1em 0.25em 1em;
}

dialog ul.types {
    display: flex;
    flex-direction: row;
    gap: 10pt;
}
dialog ul.types figure {
    border: 3px solid;
    border-radius: 16px;
    display: flex;
    flex-direction: row;
    padding-right: 10pt;
    gap: 5pt;
}
dialog ul.types figure img {
    height: 35pt;
}
dialog ul.types figure figcaption {
    font-size: 15pt;
    font-weight: bold;
}

dialog table.stats td {
    text-align: center;
}

dialog li.move figure {
    border: 3px solid;
    border-radius: 16px;
    display: flex;
    flex-direction: row;
    padding-right: 10pt;
    gap: 5pt;
}
dialog li.move figure img {
    height: 35pt;
}
dialog li.move table {
    min-width: 100px;
}
dialog li.move th, td {
    text-align: left;
    font-size: 15pt;
    padding: 0;
    white-space: nowrap;
}

ul.horizontal {
    max-width: 300px;
    overflow-x: auto;
}

/* RESPONSIVE */
@media screen and (orientation: portrait) {
    dialog {
        overflow-y: auto;
        max-height: 90vh;
    }
    dialog > ul {
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    dialog > ul > li:last-child > ul {
        align-items: center;
    }
    ::-webkit-scrollbar {
        width: auto;
    }
}

/* BUTTONS */
#btn {
        display: flex;
        justify-content: center;
        align-items: center;
        margin: 20px 0px;
        position: fixed;
        bottom: 10px;
        left: 50%;
        transform: translate(-50%);
        background-color: #FFFFFF;
        padding: 10px 10px;
        border-radius: 8px;
    }

button {
    color: #FFFFFF;
    padding: 10px 20px;
    margin: 0 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    background-color: #054d35;
    border: solid 2px #05573b ;
}

button:hover {
    background-color: #05573b;
    border-color: #054d35;
}

#page-info {
    font-size: 16px;
    color: #000000;
}

select {
    padding: 10px;
    border-radius: 4px;
    border: 1px solid #ccc;
    font-size: 14px;
    margin-bottom: 20px;

}

#search {
    padding: 10px;
    border-radius: 4px;
    border: 1px solid #ccc;
    font-size: 14px;
    width: 200px;
    margin-bottom: 20px;
}

.table-types {
    display: flex;

    gap: 6px;
    align-items: center;
    justify-content: center;
}

.table-types figure {
    display: flex;
    align-items: center;
    border: solid 2px;
    border-radius: 8px;
    padding: 0.05em 0.4em;
    gap: 5pt;
}

.table-types figure img {
    height: 20pt;
}

.table-types figure figcaption {
    font-size: 12pt;
}
