html, body {
    height: 100%;
    margin: 0;
}

body {
    scrollbar-width: thin;
    background: linear-gradient(
        135deg,
        rgb(17, 17, 17) 0%,
        rgb(17, 17, 17) 55%,
        rgb(42, 38, 26) 100%
    );

    background-attachment: fixed;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    min-height: 100vh;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus,
select:-webkit-autofill,
select:-webkit-autofill:hover,
select:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0px 1000px transparent inset !important;
    -webkit-text-fill-color: white !important;
    transition: background-color 2147483647s ease;
}

.fixed {
    position: fixed;
}

.flex {
    display: flex !important;
}

.signout {
    display: none;
}

.events-btn {
    padding: 10px;
    color: white;
    background-color: rgb(45, 45, 45);
    border-radius: 12px;
    text-align: left;
    border-color: white;
}

.events-btn:disabled {
    color: grey;
    background-color: rgb(31, 31, 31);
}

.events-btn:disabled:hover {
    color: grey;
    background-color: rgb(31, 31, 31);
    border-color: white;
}

.font {
    font-family: "Plus Jakarta Sans", "Inter", sans-serif;
}

.events-card {
    min-width: 60vw;
}

.house-text * {
    padding: 0;
    margin: 0;
}

.house-text {
    gap: 0px;
}

.gradient {
    background-image: linear-gradient(
        315deg,
        rgb(42, 42, 42) 0%,
        rgb(42, 42, 42) 33.33%,
        rgb(43, 43, 43) 33.33%,
        rgb(43, 43, 43) 66.66%,
        rgb(44, 44, 44) 66.66%,
        rgb(44, 44, 44) 100%
    );
}

.student-overlay {
    position: fixed;
    box-sizing: border-box;
    top: 25vh;
    background-color: rgb(31, 31, 31);
    border-color: rgba(250, 173, 23, 1);
    box-shadow: 0px 0px 20px rgba(0,0,0,1);
    border-width: 1px;
    border-style: solid;
    border-radius: 16px;
    z-index: 1;
    transform: scale(0.8);
    opacity: 0;
    pointer-events: none;
    padding: 10px;
    transition: transform 0.1s ease, opacity 0.1s ease;
    will-change: transform, opacity;
    max-height: 55vh;
    width: 100%;
    left: 0;
}

.house-overlay {
    position: fixed;
    box-sizing: border-box;
    top: 25vh;
    background-color: rgb(31, 31, 31);
    border-color: rgba(250, 173, 23, 1);
    box-shadow: 0px 0px 20px rgba(0,0,0,1);
    border-width: 1px;
    border-style: solid;
    border-radius: 16px;
    z-index: 1;
    transform: scale(0.8);
    opacity: 0;
    pointer-events: none;
    padding: 10px;
    transition: transform 0.1s ease, opacity 0.1s ease;
    will-change: transform, opacity;
    max-height: 55vh;
    width: 100%;
    left: 0;
}

.event-overlay {
    position: fixed;
    top: 25vh;
    background-color: rgb(31, 31, 31);
    border-color: rgba(250, 173, 23, 1);
    box-shadow: 0px 0px 20px rgba(0,0,0,1);
    border-width: 1px;
    border-style: solid;
    border-radius: 16px;
    z-index: 1;
    transform: scale(0.8);
    opacity: 0;
    pointer-events: none;
    padding: 10px;
    transition: transform 0.1s ease, opacity 0.1s ease;
    will-change: transform, opacity;
    max-height: 55vh;
    width: 95%;
    left: 0;
}

.open {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.card {
    box-sizing: border-box;
    box-shadow: 0px 0px 20px rgba(0,0,0,1);
    border-color: rgba(250, 173, 23, 0.7);
    border-style: solid;
    border-radius: 30px;
    background-color: rgba(42, 42, 42, 0.8);
    border-width: 1px;
    padding: 10px;
}

.signout-hide {
    display: none;
}

.leaderboard-card {
    margin-top: 8px;
    border-style: none;
    border-radius: 16px;
    padding: 12px 16px;
    box-shadow: 0 0 0;
    background-color: rgb(25, 25, 25);
}

.row {
    display: flex;
    flex-direction: column;
}

.column {
    display: flex;
    flex-direction: column;
}

footer {
    color: white;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
}

footer * {
    color: white;
}

.full-width {
    width: 100%;
}

.no-margin-top {
    margin-top: 0;
}

.text-centered {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.centered {
    justify-content: center;
    align-items: center;
}

.vcentered {
    align-items: center;
}

.hcentered {
    align-items: center;
}

.gap {
    gap: 30px;
}

.small-gap {
    gap: 15px;
}

.psmall-gap {
    gap: 10px;
}

.xsmall-gap {
    gap: 3px;
}

.xlarge-gap {
    gap: 100px;
}

.lightgrey {
    color: lightgrey;
}

.font-20 {
    font-size: 20px;
}

.leaderboard {
    min-height: 30vh;
}

.flex1 {
    flex: 1;
}

.tab {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    cursor: pointer;
    position: relative;
    border-bottom: 2px solid gray;
    font-weight: bold;
}

.tab.active {
    border-bottom: 2px solid grey;
    color: rgba(250, 173, 23, 1);
}

.tab:hover {
    background-color: #222;
}

.tab::after {
    content: "";
    position: absolute;
    bottom: -2px;
    left: 0;
    height: 2px;
    width: 0;
    background-color: rgba(250, 173, 23, 1);
}

.tab.active::after {
    width: 100%;
}

.hidden {
    display: none;
}

.leaderboard-student {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.space-between {
    justify-content: space-between;
}

hr {
    border-top: 1px solid rgb(60, 60, 60);
    width: 100%;
}

.bold {
    font-weight: bold;
}

.svg {
    user-select: none;
    width: 1em;
    flex-shrink: 0;
    fill: currentcolor;
    opacity: 0.7;
}

table, th, td {
    border: 1px solid rgba(250, 173, 23, 1);
    border-collapse: collapse;
    padding: 5px;
}

.scrollable {
    overflow-y: auto;
    overflow-x: hidden;
}

.portal-panel {
    width: 100%;
    height: 100%;
    overflow: hidden;
    overflow-y: auto;
}

.page-gap {
    gap: 10px;
}

.leaderboard-place {
    border-radius: 8px;
    background-color: rgb(65, 65, 65);
    padding-left: 8px;
    padding-right: 8px;
    padding-top: 2px;
    padding-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: unset;
    font-size: 0.85rem;
}

.unselectable {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

nav {
    display: flex;
    text-align: left;
    color: rgb(255, 255, 255);
    font-weight: 400;
    font-size: 1rem;
    box-sizing: border-box;
    border-radius: 20px;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
    top: 20px;
    padding: 10px;
    padding-left: 20px;
    gap: 20px;
    align-items: center;
    border-style: solid;
    border-color: rgb(60, 60, 60);
    border-radius: 20px;
    border-width: 2px;
    backdrop-filter: blur(4px);
    flex-direction: row;
    min-width: 65vw;
    z-index: 1;
    justify-content: space-between;
}

nav * {
    font-size: 20px;
    text-decoration: none;
    color: white;
    border-radius: 10px;
    padding: 5px;
}

nav span {
    font-size: 25px;
    display: block;
}

.nav-content {
    display: none;
}

.nav-content.show {
    display: flex;
    position: fixed;
    min-width: 40vw;
    top: 80px;
    background-color: rgba(25, 25, 25, 0.9);
    padding: 12px;
    border-color: rgb(60, 60, 60);
    border-radius: 20px;
    border-width: 2px;
    border-style: solid;
    text-align: left;
    flex-direction: column;
    gap: 10px;
}

main {
    padding: 2rem;
    text-align: left;
    color: rgb(255, 255, 255);
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.5;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
    margin-top: 80px;
}

.small-card-collection {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 10px;
}

.profile-card-collection {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    grid-auto-rows: 1fr;
    gap: 10px;
}

.small-card {
    width: 100%;
    text-align: left;
    padding-left: 25px;
    border-radius: 30px;
}

.small-card * {
    margin: 0;
}

.house-img {
    max-width: 150px;
}

.house-display {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    background-color: rgb(25, 25, 25);
    border-radius: 16px;
    padding: 16px;
    width: 65vw;
    max-width: 65vw;
}

.leaderboard-podium {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
}

.podium-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    gap: 20px;
    width: 100%;
}

.podium-avatar {
    border-radius: 50%;
    width: 50px;
    height: 50px;
    color: rgb(17, 17, 17);
    margin-right: 0;
    font-size: 1.2rem;
}

.podium-name {
    font-size: 1rem;
}

.podium-place {
    position: absolute;
    right: 16px;
    top: 8px;
}

.podium-points {
    margin-top: 16px;
    border-radius: 20px;
    padding: 6px;
    text-align: center;
}

select {
    padding: 5px;
    background-color: rgba(25, 25, 25, 0);
    border-color: rgb(75, 75, 75);
    border-style: solid !important;
    color: white;
    border-style: none;
    border-radius: 12px;
    margin-top: 5px;
    transition: border-color 0.3s ease;
}

select:open {
    border-color: rgba(250, 173, 23, 1);
}

.student-btn {
    padding: 6px;
    color: white;
    background-color: rgb(45, 45, 45);
    border-radius: 12px;
    text-align: left;
    width: 60px;
}

.student-btn input {
    background-color: lightgrey;
    border-radius: 8px;
    border: none;
}

.house-gap {
    gap: 10px;
}

nav .hamburger {
    display: block;
}

.login-button {
    background-image: linear-gradient(45deg, rgb(226, 150, 0) 0%, rgb(250, 173, 23) 100%);
    align-items: center;
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 15px;
    letter-spacing: 0.3px;
    line-height: 26.25px;
    padding: 12px 24px;
    width: 300px;
}

.login-button:active {
    background: rgb(204, 136, 0);
}

.login-button.loading {
    background: url("/static/gif/loading.gif?t=1") right center / 60px 60px no-repeat,
                        rgb(204, 136, 0);
}

form textarea {
    border: 1.5px solid #9e9e9e;
    background-color: rgba(255, 255, 255, 0.05);
    inset: 0;
    text-align: left;
    color: white;
    border-radius: 8px;
    font-size: 1.2rem;
    padding: 12px;
    width: 100%;
    max-width: 276px;
    height: 80px;
    transition: border-color border-radius 0.2s;
}

form textarea:not(:placeholder-shown), form textarea:focus {
    border-color: rgba(250, 173, 23, 1);
    border-width: 2px;
}

form input[type=date] {
    border: 1.5px solid #9e9e9e;
    background-color: rgba(255, 255, 255, 0.05);
    inset: 0;
    text-align: left;
    color: white;
    border-radius: 8px;
    font-size: 1.2rem;
    padding: 12px;
    width: 100%;
    max-width: 276px;
    transition: border-color border-radius 0.2s;
}

form input[type=date]:valid, form input[type=date]:focus {
    border-color: rgba(250, 173, 23, 1);
    border-width: 2px;
}

.text-field {
    position: relative;
    width: 300px;
    font-family: "Plus Jakarta Sans", "Inter", sans-serif;
}

.text-field input {
    width: 100%;
    padding: 16px 14px;
    font-size: 16px;
    border: none;
    outline: none;
    background: transparent;
    color: white;
}

.text-field fieldset {
    display: flex;
    text-align: left;
    position: absolute;
    inset: 0;
    border: 1.5px solid #9e9e9e;
    border-radius: 8px;
    pointer-events: none;
    background-color: rgba(255, 255, 255, 0.05);
    transition: border-color border-radius 0.2s;
}

.text-field fieldset legend {
    display: none;
    line-height: 12px;
    white-space: nowrap;
    overflow: hidden;
    transition: max-width 0.2s ease;
    padding: 0 4px;
    margin: 0;
    height: 0;
    line-height: 0;
    font-size: 0;
    border: 0;
}

.text-field label {
    position: absolute;
    padding: 0 4px;
    left: 14px;
    top: 50%;
    transform: translateY(-55%) scale(1);
    transform-origin: top left;
    font-size: 16px;
    color: #757575;
    pointer-events: none;
    transition: transform 0.2s ease, color 0.2s ease;
    background: transparent;
}

.text-field:focus-within label,
.text-field input:not(:placeholder-shown) + label {
    left: 16px;
    transform: translateY(-143%) scale(0.75);
    color: rgba(250, 173, 23, 1);
}

.text-field:focus-within fieldset legend,
.text-field input:not(:placeholder-shown) ~ fieldset legend {
    max-width: 100%;
    display: block;
    font-size: 12px;
}

.text-field:focus-within fieldset,
.text-field input:not(:placeholder-shown) ~ fieldset {
    border-color: rgba(250, 173, 23, 1);
    border-width: 2px;
}

.login-card {
    padding: 24px;
}

.profile-card {
    display: flex;
    align-items: center;
    flex-direction: column;
    max-height: 230px;
    min-width: 80vw;
    border-style: none;
}

.profile-avatar {
    border-radius: 50%;
    border-style: solid;
    border-color: rgba(255, 255, 255, 0.3);
    font-size: 2rem;
    background-color: rgba(255, 255, 255, 0.2);
    min-width: 80px;
    min-height: 80px;
    max-width: 80px;
    max-height: 80px;
    color: white;
}

.profile-info {
    position: relative;
    top: -20px;
}

.profile-name {
    font-size: 2rem;
}

.profile-details {
    font-size: 1.25rem;
}

select:hover {
    border-color: rgb(255, 255, 255);
}

.h1 {
    font-size: 2em;
}

select:open {
    border-color: rgba(250, 173, 23, 1);
}

.profile-small-card {
    padding: 10px;
}

.portal-box {
    min-width: 90vw;
    max-width: 90vw;
}

.flex-start {
    align-items: flex-start;
}

.student-info {
    font-size: 0.8rem;
    color: rgb(186, 186, 186);
}

.point-reason {
    padding: 8px;
    width: 120px;
}

.portal-points-text {
    display: flex;
    flex-direction: column;
}

.loadmore {
    margin-top: 8px;
}

.doc-content {
    max-width: 80vw;
}

.live-feed {
    max-height: 45vh;
}

.h3 {
    font-size: 1.17em;
    font-weight: bold;
}

@media screen and (min-width: 860px) {
    body {
        background: url("/static/images/wc.ico") top 20px right 20px / 125px 226px no-repeat,
        linear-gradient(
            135deg,
            rgb(17, 17, 17) 0%,
            rgb(17, 17, 17) 55%,
            rgb(42, 38, 26) 100%
        );

        background-attachment: fixed;
    }

    .doc-content {
        max-width: 624px;
    }

    .signout-hide {
        display: block;
        opacity: 0;
        pointer-events: none;
    }
    
    .portal-box {
        min-width: 0vw;
        max-width: 100vw;
    }

    .portal-section {
        max-height: 75vh;
        height: 75vh;
    }

    .hoverable {
        transition:
            transform 0.3s ease,
            box-shadow 0.3s ease
    }

    .hoverable:hover {
        transform: translate(0, -4px);
        box-shadow: 0px 10px 15px rgba(0,0,0,1);
    }

    .hoverable-up-left:hover {
        transform: translate(0, -2px);
        box-shadow: 8px 8px 8px rgba(0,0,0,1);
    }

    .yellow-hoverable:hover {
        transform: translate(0, -4px);
        box-shadow: 0px 10px 25px rgb(250, 173, 23, 0.2);
    }

    .cyan-hoverable:hover {
        transform: translate(0, -4px);
        box-shadow: 0px 10px 25px rgba(0, 255, 255, 0.2);
    }

    .lightgreen-hoverable:hover {
        transform: translate(0, -4px);
        box-shadow: 0px 10px 25px rgba(144, 238, 144, 0.2);
    }

    .leaderboard-hoverable {
        border-radius: 12px;
        transition: 
            background-color 0.3s ease,
            box-shadow 0.3s ease;
    }

    .leaderboard-hoverable:hover {
        background-color: rgba(250, 173, 23, 0.05);
        box-shadow: 0 0 0 6px rgba(250, 173, 23, 0.05);
    }

    .podium-gold:hover {
        box-shadow: 0px 4px 20px rgba(255, 193, 7, 0.3);
    }

    .podium-silver:hover {
        box-shadow: 0px 4px 20px rgba(192, 192, 192, 0.3);
    }

    .podium-bronze:hover {
        box-shadow: 0px 4px 20px rgba(134, 96, 61, 0.3);
    }

    nav *:hover:not(.nav-content):not(.house-text):not(.house-text *) {
        background-color: rgba(255, 255, 255, 0.05);
        color: rgba(250, 173, 23, 1);
        transform: translate(0, -2px);
    }

    nav .house-text:hover {
        background-color: rgba(255, 255, 255, 0.05);
        color: rgba(250, 173, 23, 1);
        transform: translate(0, -2px);
    }

    nav .house-text:hover > .nav-title {
        color: rgba(250, 173, 23, 1);
    }

    .signout {
        position: absolute;
        right: 20px;
    }

    .event-overlay {
        width: 35vw;
        left: 32.5vw;
    }

    .student-overlay {
        width: 35vw;
        left: 32.5vw;
    }

    .house-overlay {
        width: 35vw;
        left: 32.5vw;
    }

    .profile-small-card {
        padding: 40px;
        gap: 10px;
        justify-content: center;
        align-items: center;
    }

    .profile-card-collection {
        display: grid;
        grid-template-columns: repeat(3, 3fr);
        gap: 30px;
    }

    .house-img {
        width: 10vw;
        max-width: 200px;
    }

    .house-gap {
        gap: 30px;
    }

    .small-card-collection {
        display: grid;
        grid-template-columns: repeat(1, 1fr);
        gap: 30px;
    }

    .card {
        padding: 20px;
    }

    .podium-points {
        padding: 6px;
        border-radius: 30px;
    }

    .podium-name {
        font-size: 1.3rem;
    }

    .podium-place {
        top: 16px;
    }

    .podium-avatar {
        width: 55px;
        height: 55px;
        font-size: 1.3rem;
    }

    .house-display {
        display: block;
        background-color: transparent;
        width: 10vw;
        max-width: 200px;
    }

    nav {
        justify-content: unset;
        flex: 1 1 65vw;
        min-width: 65vw;
        max-width: 80vw;
        flex-direction: row;
    }

    nav * {
        flex-shrink: 0;
        transition:
            transform 0.3s ease
    }

    nav .hamburger {
        display: none;
    }

    .nav-content {
        display: flex;
        flex-direction: row;
        flex-shrink: 0;
        gap: 20px;
    }

    nav span {
        font-size: 25px;
    }

    main {
        flex: 1 1 60vw;
        max-width: 80vw;
        margin-top: 80px;
    }

    .small-card {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        max-width: 250px;
        min-height: 150px;
        padding: 0;
        flex: 0 1 250px;
    }

    .podium-card {
        display: block;
        max-width: 300px;
        flex: 0 1 300px;
    }

    .podium-margin-bottom {
        margin-bottom: 8px;
    }

    .row {
        display: flex;
        flex-direction: row;
    }

    .profile-card {
        display: flex;
        min-width: 60vw;
        align-items: center;
    }

    .profile-avatar {
        font-size: 2.5rem;
        min-width: 100px;
        min-height: 100px;
        max-width: 100px;
        max-height: 100px;
    }

    .profile-info {
        position: static;
        top: 0;
    }

    .profile-name {
        font-size: 2.5rem;
    }

    .profile-details {
        font-size: 1.25rem;
    }

    .page-gap {
        gap: 28px;
    }

    .large-card {
        min-width: 66.8vw;
    }
    
    .login-card {
        padding: 40px;
    }

    .student-btn {
        width: fit-content;
    }

    .point-reason {
        width: 300px;
    }

    .point-input {
        padding: 8px;
    }

    .portal-points-text {
        display: block;
    }

    .portal-tab {
        max-width: 198px;
        flex-shrink: 1;
    }
}

@media screen and (min-width: 1921px) {
    main {
        max-width: 1536px !important;
    }

    nav {
        min-width: 1248px !important;
    }
}