@import url('https://fonts.googleapis.com/css2?family=Nunito:ital,wght@0,200..1000;1,200..1000&display=swap');

/*
    Misc elements
*/
body {
    background-color: #30221d;
    background-image: url('../cdn/img/background.webp');
	background-position: unset;
    background-size: 100vw;
	background-repeat: repeat;
    text-align: center;
    font-family: "Nunito", sans-serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    font-size: large;
    color: white;
    padding: 12px 7.5%;
}
body.scroll-locked {
    overflow: hidden;
    scrollbar-gutter: stable;
}
a {
    color: white;
    text-decoration: none;
}
a:hover {
    text-decoration: underline;
}
button {
    padding: 16px;
    border-radius: 12px;
    border: 0;
    background-color: #3f2920;
    color: white;
    font-weight: 700;
    font-family: "Nunito", sans-serif;
    font-size: large;
    cursor: pointer;
    transition: all 0.1s;
    display: flex;
    align-items: center;
    gap: 4px;
}
button:hover {
    background-color: #52352a;
}
button:active {
    background-color: #724b3c;
}
header {
    background-color: #36241d59;
    backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 16px;
    text-align: left;
    display: flex;
    align-items: center;
  	justify-content: space-between;
}
header a:hover {
    text-decoration: none;
}
#header-btns {
    display: flex;
    flex-direction: row;
    gap: 6px;
    position: relative;
    right: 0;
    align-items: center;
    height: 100%;
}
#logo {
    display: block;
    transition: all 0.2s;
}
#logo:hover {
    filter: drop-shadow(0px 0px 3px #fff);
}
.bar {
    background-color: #36241d59;
    backdrop-filter: blur(8px);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    align-items: center;
  	justify-content: space-between;
}
#tabmenu {
    width: 100%;
    border-radius: 12px;
    display: flex;
    align-items: center;
  	justify-content: space-between;
    gap: 16px;
    overflow-x: scroll;
    scrollbar-width: none;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    @media (prefers-reduced-motion: no-preference) {
        scroll-behavior: smooth;
    }
}
.tab {
    width: 100%;
    min-width: 140px;
    text-align: center;
    display: inline;
    @media screen and (max-width: 590px) {
        min-width: 165px;
    }
}
.selected {
    background-color: #502f21;
}
#tableft {
    position: relative;
    left: 0;
    padding-right: 16px;
    display: none;
}
#tabright {
    position: relative;
    right: 0;
    padding-left: 16px;
    display: none;
}
.emptybtn {
    background: none;
    padding: 0;
    transition: none;
}
.emptybtn:hover {
    background: none;
}

.greenbtn {
    background-color: #00ab41;
}
.greenbtn:hover {
    background-color: #00c04b;
}
.greenbtn:active {
    background-color: #00c04b;
}
.redbtn {
    background-color: #d42901;
}
.redbtn:hover {
    background-color: #bd2401;
}
.redbtn:active {
    background-color: #a51f01;
}
.graybtn {
    background-color: #636363;
}
.graybtn:hover {
    background-color: #909090;
}
.graybtn:active {
    background-color: #b4b4b4;
}
#big {
    font-size: large;
}
#small {
    font-size: small;
}
#loading {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.2s ease-in-out;
    position:fixed;
    left: 50%;
    transform: translate(-50%, 0);
    top: 50vh;
}
#loading.show {
    opacity: 1;
}
/*old loader
.loader {
  border: 12px solid #3f2920;
  border-top: 12px solid #52352a;
  border-radius: 50%;
  width: 96px;
  height: 96px;
  min-width: 96px;
  min-height: 96px;
  animation: spin 2s linear infinite;
  margin-bottom: 20px;
}
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}*/
/*new loader, creds: https://cssloaders.github.io/ */
.loader {
    width: 84px;
    height: 84px;
    border: 5px solid #FFF;
    border-bottom-color: transparent;
    border-radius: 50%;
    margin-bottom: 10px;
    display: inline-block;
    box-sizing: border-box;
    animation: rotation 1s linear infinite;
}

@keyframes rotation {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
} 

#content {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
    opacity: 0;
    z-index: -1;
    position: relative;
    transition: opacity 0.2s ease-in-out;
    transition-duration: 0.2s; /*setting transition-duration for js*/
}
#content.show {
    opacity: 1;
}

#easteregg {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position:fixed;
    left: 50%;
    transform: translate(-50%, 0);
    top: 256px;
}

#snackbar {
    transition: opacity 0.2s ease-in-out;
    opacity: 0;
    max-width: 90%;
    background-color: #30221d;
    color: #fff;
    text-align: center;
    border-radius: 8px;
    padding: 20px;
    position: fixed;
    left: 50%;
    transform: translate(-50%, 0);
    bottom: 32px;
    z-index: -1;
    font-size: x-large;
}
#snackbar.show {
    opacity: 1;
}

.screenshot {
    width: 24%;
    text-align: left;
    border-radius: 10px;
    background-color: #36241d;
    transition: box-shadow 0.1s ease;
}
.screenshot.hovered {
    box-shadow: 0 0 5px #FFF;
}
.ssinfo-screenshot {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: #231915;
	background-position: center;
	background-repeat: no-repeat;
    background-size: 100%;
    cursor: pointer;
    border-radius: 10px 10px 0 0;
}
.screenshotinfo {
    display: flex;
    align-items: flex-start;
}
.ssinfo-left {
    padding-top: 10px;
    padding-left: 10px;
}
.ssinfo-right {
    padding-left: 8px;
    padding-top: 12px;
    min-width: 0;
    flex: 1;
}
.ssinfo-avatar {
    border-radius: 32px;
}
.ssinfo-header {
    display: flex;
    align-items: center;
    gap: 6px;
    width: calc(100% - 10px);
    min-width: 0;
}
.ssinfo-username {
    flex: 0 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: block;
}
.ssinfo-date {
    font-size: 12px;
    white-space: nowrap;
    flex-shrink: 0;
}
.ssinfo-desc {
    display: block;
    min-width: 0;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
}
.ss-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    gap: 8px;
    padding: 8px 0;
}
.ss-actions button {
    padding: 8px;
    min-width: 40px;
    min-height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.pagination {
    width: 100%;
}
#pages {
    display: flex;
    flex-direction: row;
    gap: 4px;
}
#pages button {
    padding: 12px;
}

.closebtn {
    font-family: 'Courier New', Courier, monospace;
    font-size: 4em;
    position: absolute;
    top: 0;
    right: 15px;
    cursor: pointer;
    transition: all 0.1s;
}
.closebtn:hover {
    text-shadow: 0 0 5px #fafafa;
}
/*Modals*/
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #00000059;
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.2s ease-in-out;
}

/*Screenshot modal*/
#ssmodal {
    opacity: 0;
    z-index: -1;
}
#ssmodal.open {
    opacity: 1;
}
#ssmodal-inner {
    scrollbar-width: thin;
    scrollbar-color: #5e4137 #30221d59;
    padding: 20px;
    background-color: #30221d63;
    backdrop-filter: blur(8px);
    border-radius: 16px;
    max-height: 90vh;
    text-align: left;
    overflow-y: auto;
    overscroll-behavior: contain;
    @media screen and (orientation: portrait) { /* it fucks up without this for some reason??? */
        width: calc(100vw - 80px);
    }
}
#ssmodal-sscontainer {
    text-align: center;
    display: flex;
    position: relative;
}
#ssmodal-loading {
    position: absolute;
    background-color: #2f1e18;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transition: opacity 0.2s ease-in-out;
    opacity: 0;
    z-index: -1;
}
#ssmodal-loading.show {
    opacity: 1;
}
@media screen and (orientation: landscape) {
    #ssmodal-screenshot {
        width: auto;
        height: auto;
        max-width: calc(100vw - 186px);
    }
    #ssmodal-inner {
        max-width: calc(100vw - 186px);
    }
}
@media screen and (orientation: portrait) {
    #ssmodal-screenshot {
        width: calc(100vw - 80px);
        height: auto;
    }
}
#ssmodal-avatar {
    border-radius: 32px;
}
#ssmodal-date {
    font-size: 12px;
}
#ssmodal-desc {
    display: block;
    min-width: 0;
    min-height: 0;
    white-space: wrap;
    overflow-wrap: break-word;
}
#ssmodal-left {
    float: left;
    padding-top: 16px;
}
#ssmodal-right {
    padding-left: 58px;
    padding-top: 18px;
}

/*Screenshot info modal*/
#ssinfomodal {
    opacity: 0;
    display: flex;
    z-index: -1;
}
#ssinfomodal.open {
    opacity: 1;
}
#ssinfomodal-inner {
    background-color: #30221d;
    padding: 20px;
    border-radius: 12px;
    width: 512px;
    text-align: center;
    overflow-y: auto;
    overscroll-behavior: contain;
}
#ssinfomodal-inner button {
    display: inline;
    margin-top: 16px;
}
#ssinfomodal-inner textarea {
    max-width: 508px;
    min-width: calc(100% - 4px); /*508 instead of 512 bc of padding*/
    height: 64px;
    border: none;
    resize: none;
}
#ssinfomodal-sscontainer {
    text-align: center;
    display: flex;
    position: relative;
    max-width: 512px;
}
#ssinfomodal-loading {
    position: absolute;
    background-color: #1e130f;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transition: opacity 0.2s ease-in-out;
    opacity: 0;
    z-index: -1;
}
#ssinfomodal-loading.show {
    opacity: 1;
}
#ssinfomodal-screenshot {
    width: 100%;
}
#ssinfomodal-title {
    font-size: 36px;
    font-weight: bold;
}
#ssinfomodal-content {
    margin-top: 16px;
    text-align: left;
}

/*Remove confirmation modal*/
#removemodal {
    opacity: 0;
    display: flex;
    z-index: -1;
}
#removemodal.open {
    opacity: 1;
}
#removemodal-inner {
    background-color: #30221d;
    padding: 20px;
    border-radius: 12px;
    max-width: 45%;
    overflow-y: auto;
    overscroll-behavior: contain;
}
#removemodal-inner button {
    display: inline;
    margin-top: 20px;
}
#removemodal-title {
    font-size: 36px;
    font-weight: bold;
}

/*Reporting modal*/
#reportmodal {
    opacity: 0;
    display: flex;
    z-index: -1;
}
#reportmodal.open {
    opacity: 1;
}
#reportmodal-inner {
    background-color: #30221d;
    padding: 20px;
    border-radius: 12px;
    max-width: 45%;
    overflow-y: auto;
    overscroll-behavior: contain;
}
#reportmodal-inner button {
    display: inline;
    margin-top: 20px;
}
#reportmodal-title {
    font-size: 36px;
    font-weight: bold;
}
#reportmodal a {
    text-decoration: underline;
}

/*Upload modal + elements inside*/
#uploadmodal {
    opacity: 0;
    display: flex;
    z-index: -1;
}
#uploadmodal.open {
    opacity: 1;
}
#uploadmodal-inner {
    background-color: #30221d;
    padding: 20px;
    border-radius: 12px;
    width: 512px;
    text-align: center;
    overflow-y: auto;
    overscroll-behavior: contain;
}
#uploadmodal-inner button {
    display: inline;
    margin-top: 16px;
}
#uploadmodal-inner textarea {
    max-width: 508px;
    min-width: calc(100% - 4px); /*508 instead of 512 bc of padding*/
    height: 64px;
    border: none;
    resize: none;
}
#uploadsubmit {
    padding: 16px;
    border-radius: 12px;
    border: 0;
    background-color: #3f2920;
    color: white;
    font-weight: 700;
    font-family: "Nunito", sans-serif;
    font-size: large;
    cursor: pointer;
    transition: all 0.1s;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 20px;
    transform: translate(-50%, 0);
    left: 50%;
    position: relative;
}
#uploadsubmit:hover {
    background-color: #52352a;
}
#uploadsubmit:active {
    background-color: #724b3c;
}
#uploadsubmit:disabled {
    background-color: #271914;
    color: #666;
    cursor: default;
}
#uploadmodal-title {
    font-size: 36px;
    font-weight: bold;
}
#uploadmodal-content {
    margin-top: 16px;
    text-align: left;
}
#fileupload {
    display: inline-block;
    border-radius: 12px;
    border: 0;
    background-color: #1e130f;
    color: white;
    font-weight: 700;
    font-family: "Nunito", sans-serif;
    font-size: large;
    cursor: pointer;
    width: calc(100% - 40px);
    height: 256px;
    padding: 20px;
    margin-bottom: 10px;
}
#fileupload-inner {
    width: calc(100% - 2px);
    height: calc(100% - 2px);
    border-radius: 4px;
    border: 2px dashed #fff;
    background-color: #1e130f;
    /*background-image: url("../cdn/img/screenshots/image10.webp");*/
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    flex-direction: column;
    transition: background-color 0.1s ease-in-out;
}
#fileupload-inner:hover {
    background-color: #2f1e18;
}
#fileupload-inner:active {
    background-color: #3a251e;
}
#fileupload-default {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    flex-direction: column;
}
#fileupload-img {
    display: none;
    align-items: center;
    justify-content: center;
    text-align: center;
    flex-direction: column;
    text-shadow: 0 0 10px #000;
}

/*Login modal*/
#loginmodal {
    opacity: 0;
    display: flex;
    z-index: -1;
}
#loginmodal.open {
    opacity: 1;
}
#loginmodal-inner {
    background-color: #30221d;
    padding: 20px;
    border-radius: 12px;
    max-width: 45%;
    overflow-y: auto;
    overscroll-behavior: contain;
}
#loginmodal-title {
    font-size: 36px;
    font-weight: bold;
}
#loginmodal-btn {
    margin-top: 20px;
}

/*Admin modal*/
#adminmodal {
    opacity: 0;
    display: flex;
    z-index: -1;
}
#adminmodal.open {
    opacity: 1;
}
#adminmodal-inner {
    background-color: #30221d;
    padding: 20px;
    border-radius: 12px;
    max-width: 45%;
    overflow-y: auto;
    overscroll-behavior: contain;
}
#adminmodal-title {
    font-size: 36px;
    font-weight: bold;
}
#adminmodal-content {
    text-align: left;
}
#adminmodal-desc {
    width: calc(100% - 4px);
    height: 72px;
}
#adminmodal-steamid {
    width: calc(100% - 4px);
    height: 17px;
}
#adminmodal-buttons {
    display: flex;
    flex-direction: row;
    gap: 6px;
}

/*Admin banning modal*/
#banmodal {
    opacity: 0;
    display: flex;
    z-index: -1;
}
#banmodal.open {
    opacity: 1;
}
#banmodal-inner {
    background-color: #30221d;
    padding: 20px;
    border-radius: 12px;
    max-width: 45%;
    overflow-y: auto;
    overscroll-behavior: contain;
}
#banmodal-title {
    font-size: 36px;
    font-weight: bold;
}
#banmodal-content {
    text-align: left;
}
#banmodal-content textarea {
    width: calc(100% - 4px);
    height: 72px;
}
#banmodal-buttons {
    display: flex;
    flex-direction: row;
    gap: 6px;
}
/*Media queries*/
@media screen and (max-width: 720px) {
    body {
        padding: 12px;
    }
    #removemodal-inner {
        max-width: calc(100vw - 186px);
    }
    #reportmodal-inner {
        max-width: calc(100vw - 186px);
    }
    #loginmodal-inner {
        max-width: calc(100vw - 186px);
    }
    #adminmodal-inner {
        max-width: calc(100vw - 186px);
    }
    #banmodal-inner {
        max-width: calc(100vw - 186px);
    }
}
@media screen and (max-width: 584px) {
    #ssinfomodal-inner {
        width: calc(100vw - 70px);
    }
    #uploadmodal-inner {
        width: calc(100vw - 70px);
    }
}
@media screen and (max-width: 510px) {
    #removemodal-inner {
        max-width: calc(100vw - 70px);
    }
    #reportmodal-inner {
        max-width: calc(100vw - 70px);
    }
    #loginmodal-inner {
        max-width: calc(100vw - 70px);
    }
    #adminmodal-inner {
        max-width: calc(100vw - 70px);
    }
    #banmodal-inner {
        max-width: calc(100vw - 70px);
    }
}
@media screen and (max-width: 1120px) {
    .screenshot {
        width: 32%;
    }
}
@media screen and (max-width: 848px) {
    .screenshot {
        width: 49%;
    }
}
@media screen and (max-width: 500px) {
    .screenshot {
        width: 100%;
    }
}
