:root {
  --gamecube-color: #6545b2;
  --gamecube-red: #d60101;
  --gamecube-red-hover: #b40101;
  --gamecube-green: #4db849;
  --gamecube-green-hover: #40963d;
  --white-alt: #e4e4e4;
  --sharp-yellow: #fdcd0b;
  --sharp-yellow-hover: #dbaf00;
  --charcoal: #1a1a1a;
}

/* UNIVERSAL */

* {
  -webkit-box-sizing: inherit;
  box-sizing: inherit;
  margin: 0;
  line-height: 1.6;
}

html {
  width: 100vw;
}

body {
  padding: 0;
  font-weight: 300;
  font-family: "Lato", sans-serif;
  color: var(--charcoal);
  overflow-x: hidden;
  background-color: #f7f7f7;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

img {
  background-color: transparent;
}

input:-webkit-autofill,
input:-webkit-autofill:focus {
  transition:
    background-color 0s 600000s,
    color 0s 600000s !important;
}

.mobile__page {
  display: none;
}

.hidden {
  display: none;
}
.hidden__fade {
  opacity: 0;
}

.hidden__fade__slide {
  opacity: 0;
  transform: translateY(-1rem);
}

.zindex {
  z-index: 10;
}

.btn,
.btn:link,
.btn:visited {
  font-size: 1rem;
  font-family: inherit;
  font-weight: bold;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  text-transform: uppercase;
  display: inline-block;
  text-decoration: none;
  position: relative;
  border: none;
  cursor: pointer;
}

.btn__yellow {
  background-color: var(--sharp-yellow);
  /* margin-top: 0.75rem;
  margin-right: 0.5rem; */
}

.btn__yellow:hover {
  background-color: var(--sharp-yellow-hover);
}

.btn__red {
  background-color: var(--gamecube-red);
  color: white;
}
.btn__red:hover {
  background-color: #b40101;
}

.btn__green {
  background-color: var(--gamecube-green);
  color: white;
}

.btn__green:hover {
  background-color: var(--gamecube-green-hover);
}

.nav__items a {
  text-decoration: none;
  color: #1a1a1a;
}

.alert {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  color: #fff;
  font-size: 1.5rem;
  font-weight: 400;
  text-align: center;
  border-bottom-left-radius: 5px;
  border-bottom-right-radius: 5px;
  padding: 0.5rem 15rem;
  margin-top: 4px;
  white-space: nowrap;
  width: 100%;
}

.alert__success {
  background-color: var(--gamecube-green);
}
.alert__error {
  background-color: var(--gamecube-red);
}

/* HEADER */
.header {
  z-index: 19;
  max-width: 100vw;
  background-color: #f7f7f7;
  border-bottom: 1px solid var(--white-alt);
  border-top: 4px solid var(--gamecube-color);
  position: sticky;
  top: 0;
  margin-bottom: 1rem;
}

.header__logo img {
  height: 2.5rem;
  margin-top: 6px;
}

.nav__items {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 18vw 2px 18vw;
  height: 48px;
}

.header__text {
  display: flex;
  gap: 10px;
  align-items: center;
}

.logout__btn {
  cursor: pointer;
  background-color: var(--gamecube-red);
  padding: 0.25rem 0.5rem 0.25rem 0.5rem;
  border-radius: 6px;
  color: white;
}

.user__button {
  background-color: var(--sharp-yellow);
  padding: 0.25rem 0.5rem 0.25rem 0.5rem;
  border-radius: 6px;
  color: white;
}

.user__button:hover {
  background-color: var(--sharp-yellow-hover);
}

.logout__btn:hover {
  background-color: var(--gamecube-red-hover);
}
.margin__borders {
  margin: 0 18vw 0 18vw;
  border: solid var(--white-alt);
  border-width: 0 1px 0 1px;
}
.signup__btn {
  background-color: var(--sharp-yellow);
  font-size: 1rem;
  font-family: inherit;
  font-weight: bold;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  display: inline-block;
  text-decoration: none;
  position: relative;
  border: none;
  cursor: pointer;
}
.signup__btn:hover {
  background-color: var(--sharp-yellow-hover);
}

/* HOME PAGE */
.home__page {
  display: flex;
  flex-direction: column;
  margin-top: 4rem;
  margin-bottom: 2rem;
  gap: 20px;
}

.home__title {
  display: flex;
  justify-content: center;
  font-size: 58px;
}

.home__subtitle {
  display: flex;
  justify-content: center;
  font-size: 28px;
}

.character__select {
  display: grid;
  grid-template-columns: repeat(9, 1fr);
  row-gap: 12px;
  padding: 0 12rem 0 12rem;
  justify-content: center;
  position: relative;
}

.character__box {
  height: 62px;
  justify-self: center;
  cursor: pointer;
  transition: 0.1s;
  margin: 2px;
  border-radius: 6px;
}

.character__box:not(.fade) {
  pointer-events: none;
}

.character__box:hover {
  transition: 0.25s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.247);
  transform: scale(1.2);
}

.character__box:active {
  transform: scale(1);
  border-radius: 4px;
}

.character__box:nth-last-child(8) {
  background-color: transparent;
  border: none;
  cursor: default;
  pointer-events: none;
}

.character__box:nth-last-child(12) {
  position: relative;
}

.character__box:nth-last-child(11) {
  display: none;
}

.zelda__box {
  position: absolute;
  right: -64px;
  top: -2px;
  transition: 0.75s;
}

.zelda__box:hover {
  transform: scale(1);
}

.character__icon {
  width: 62px;
  border-radius: 4px;
  opacity: 0;
}
.fade {
  opacity: 1;
  transition: 0.5s;
}

.fastFade {
  opacity: 1;
  transition: 0.35s;
  transform: translateY(0);
}

#upload__savestate {
  height: 96px;
  cursor: pointer;
  align-self: center;
  filter: drop-shadow(3px 3px 30px rgba(255, 196, 0, 0.7));
}

.upload__btn {
  text-decoration: none;
  font-size: 48px;
  color: var(--sharp-yellow);
  background-color: #20153b;
  padding: 0.5rem 1.5rem 0.5rem 1.5rem;
  border-radius: 200px;
  font-weight: bold;
  filter: drop-shadow(3px 3px 30px rgba(255, 196, 0, 0.7));
  margin-top: 1rem;
  transition: 0.25s;
}

.upload__btn:hover {
  color: #20153b;
  background-color: var(--sharp-yellow);
  transform: scale(1.1);
  transition: 0.25s;
}

.upload__btn:active {
  color: #20153b;
  background-color: var(--sharp-yellow);
  transform: scale(1);
  /* transition: 0.1s; */
}

.savestate__wrapper {
  align-self: center;
}

.remove__files {
  color: white;
  background-color: var(--gamecube-color);
  padding: 0px 8px 0px 8px;
  border-radius: 100px;
  position: absolute;
  right: 0;
  bottom: 11px;
  right: 2%;
  font-family: Arial, Helvetica, sans-serif;
  cursor: pointer;
}
.form__group {
  position: relative;
}
.form__group button {
  margin-right: 1rem;
}

.homepage__divider {
  border: none;
  height: 1px;
  background-color: var(--white-alt);
  margin: 0 12rem 0 12rem;
}
/* CHARACTER PAGE */

.character__page {
  border-bottom: solid 1px var(--white-alt);
  border-top: solid 1px var(--white-alt);
}

@-moz-document url-prefix() {
  .tableWrap {
    padding-right: 0.5rem;
  }
}

.tableWrap {
  max-height: 60vh;
  overflow: auto;
}

thead {
  background-color: var(--gamecube-color);
  color: white;
  position: sticky;
  top: 0;
}

th:last-child {
  padding-right: 0;
}

tbody > tr:nth-of-type(even) {
  background-color: var(--white-alt);
}

.savestate__table {
  margin: 0 auto;
  width: 100%;
}

.savestate__item a {
  text-decoration: none;
  /* background-color: var(--sharp-yellow); */
  border-radius: 6px;
  color: var(--gamecube-color);
  padding: 0.15rem;
}

.savestate__item a:hover {
  color: var(--sharp-yellow-hover);
}

.filter__group {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
  padding: 0.5rem;
}

.filter__group select {
  border-radius: 6px;
  padding: 0.1rem 0.1rem;
  background-color: rgb(250, 250, 250);
  border: 1px var(--charcoal) solid;
}

@-moz-document url-prefix() {
  .filter__group select {
    padding-left: 0.4rem;
  }
}

.btn__fg {
  font-size: 12px;
  padding: 0.25rem 0.55rem;
  background-color: var(--sharp-yellow);
  color: var(--charcoal);
}

.btn__fg:hover {
  background-color: var(--sharp-yellow-hover);
}

.page__btns {
  display: flex;
  justify-content: flex-end;
  bottom: 0;
  background-color: var(--gamecube-color);
}

.page__btn {
  cursor: pointer;
  margin-right: 1.5rem;
  margin-bottom: 0.25rem;
  color: white;
}

.page__btn:hover {
  color: var(--sharp-yellow);
}

.page__counter {
  margin-right: 1.5rem;
  color: white;
}

.unactive {
  pointer-events: none;
  color: #b4b4b4;
}

.unactive__btn {
  pointer-events: none;
  color: var(--charcoal);
  background-color: grey;
}

.icon {
  width: 20px;
  margin-top: 6px;
  fill: var(--gamecube-color);
  cursor: pointer;
}
.icon:hover {
  fill: var(--sharp-yellow-hover);
}

.icon:active {
  transform: scale(1.1);
}

.icon:last-child {
  margin-left: 0.25rem;
}

.report__btn {
  cursor: pointer;
  fill: var(--sharp-yellow-hover);
}
.icon__group {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 24px;
  overflow: hidden;
}
.no__character {
  margin-top: 4rem;
}

/* Character Page Dialog */

/* LOG IN FORM */
.form__section {
  gap: 14px;
  width: fit-content;
  margin: 0 auto;
  margin-top: 2rem;
  background-color: var(--gamecube-color);
  padding: 1.5rem 4rem 1.5rem 4rem;
  border-radius: 8px;
  color: white;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.288);
}

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

  gap: 22px;
}

.heading__secondary {
  margin-bottom: 1rem;
  font-size: 2rem;
}

.form__input {
  display: block;
  font-family: inherit;
  color: inherit;
  padding: 0.5rem 1.5rem;
  border: none;
  width: 100%;
  background-color: #f2f2f2;
  color: var(--charcoal);
  border-top: 3px solid transparent;
  border-bottom: 3px solid transparent;
  box-sizing: border-box;
  font-size: 1rem;
  border-radius: 8px;
}

.form__label {
  display: block;
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.form__group {
  color: white;
}

.login__btn__group a:visited {
  text-decoration: none;
  color: white;
}

/* Upload Savestate Form */

.upload__savestate__page .form__section {
  padding: 2.5rem 4rem;
}

.upload__savestate__page .form {
  gap: 2px;
}
.select__box {
  font-size: 14px;
  border: none;
  border-radius: 8px;
  padding: 0.5rem;
  background-color: white;
  width: 100%;
}

#savestate__title {
  border-radius: 6px;
  border: none;
  resize: none;
  padding: 0.5rem;
  font-size: 16px;
  font-family: inherit;
  width: 100%;
}

#savestate__description {
  border-radius: 6px;
  border: none;
  resize: none;
  padding: 0.5rem;
  font-size: 16px;
  font-family: inherit;
  width: 100%;
}

#file {
  margin-bottom: 0.5rem;
}

/* Share Savestate Page */

.share__savestate__page {
  margin: 0 auto;
  width: fit-content;
  justify-content: center;
  margin-top: 4rem;
  color: white;
}

.share__box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: var(--gamecube-color);
  padding: 3rem;
  border-radius: 8px;
}

/*  FOOTER */
.footer__wrap {
  margin-top: 4rem;
  border-top: solid 1px var(--white-alt);
  background-color: var(--gamecube-color);
  flex-grow: 1;
  color: white;
}

.footer__group {
  margin: 0 18vw 0 18vw;
  padding: 0.7rem 0 2rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer__link {
  text-decoration: none;
}

.report__bug {
  cursor: pointer;
}
.footer__link:visited {
  text-decoration: none;
  color: white;
}

.footer__text {
  font-size: 0.9rem;
  color: white;
}

.footer__text:hover {
  color: var(--sharp-yellow);
}

.footer__text__title {
  font-size: 1.3rem;
}

.created__by:hover {
  color: white;
}

/* ACCOUNT PAGE */

.side-nav {
  list-style: none;
}

.side-nav a:link,
.side-nav a:visited {
  padding: 1rem 4rem;
  display: flex;
  align-items: center;
  color: #fff;
  font-size: 1rem;
  text-transform: uppercase;
  font-weight: 400;
  text-decoration: none;
}

.side-nav svg {
  height: 1.9rem;
  width: 1.9rem;
  fill: #f7f7f7;
  margin-right: 2rem;
}
.account__form__section {
  gap: 14px;
  width: fit-content;
  margin: 0 auto;
  margin-top: 2rem;
  background-color: var(--gamecube-color);
  padding: 2.5rem 4rem 2.5rem 4rem;
  border-radius: 8px;
  color: white;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.288);
}

.password__header {
  margin-bottom: 1rem;
}

.form__user__data {
  width: 30rem;
}

/* DELETE ACCOUNT */
.delete__account__form {
  display: flex;
  flex-direction: column;
  width: fit-content;
  margin: 0 auto;
}
.delete__account__form {
  background-color: var(--gamecube-color);
  padding: 3rem;
  border-radius: 8px;
  margin-top: 2rem;
  color: white;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.288);
}

/* Errors */
.error {
  position: absolute;
  top: 35%;
  left: 50%;
  -webkit-transform: translate(-50%, -50%);
  transform: translate(-50%, -50%);
  width: 100rem;
  text-align: center;
}
.error__title {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
  margin-bottom: 1rem;
}
.error__emoji {
  font-size: 3.75rem;
  margin-left: 1rem;
}
.error__msg {
  font-size: 2.5rem;
  font-weight: 700;
  max-width: 50rem;
  margin: 0 auto;
}

.mismatch__page {
  padding: 1rem;
}

/* Dialogs */
.report__dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: none;
  border-radius: 10px;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.288);
  padding: 3.5rem;
  background-image: linear-gradient(to right top, #6545b2, #6c4eb3, #7256b5, #795fb6, #7f67b7);
  color: white;
  font-size: 24px;
}

.close__icon {
  fill: white;
  position: absolute;
  width: 32px;
  height: 32px;
  top: 4%;
  left: 4%;
  cursor: pointer;
  border-radius: 100px;
  padding: 0.5rem;
}

.close__icon:hover {
  background-color: #1a1a1a1a;
}

.update__dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: none;
  border-radius: 10px;
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.288);
  padding: 3.5rem;
  background-image: linear-gradient(to right top, #6545b2, #6c4eb3, #7256b5, #795fb6, #7f67b7);
}

/* NO SAVESTATES PAGE */
.no__savestates__section {
  font-size: 26px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.no__savestates__title {
  padding: 2rem 4rem 0 4rem;
  font-size: 32px;
}
.loader {
  width: 300px;
}

.upload__first {
  text-decoration: none;
  color: var(--charcoal);
}

.upload__first:hover {
  color: var(--sharp-yellow);
}

/* MEDIA QUERIES */

@media (max-width: 1740px) {
  .margin__borders {
    margin: 0 14vw;
  }
  .share__savestate__page {
    margin: 0 auto;
    width: fit-content;
    justify-content: center;
    margin-top: 3rem;
    color: white;
  }
  .footer__group {
    margin: 0 14vw;
  }
  .nav__items {
    padding: 2px 14vw;
  }
  .home__page {
    margin-top: 2rem;
    margin-bottom: 1rem;
  }
  .home__title {
    font-size: 44px;
  }

  .character__icon {
    width: 52px;
    height: 52px;
  }

  .character__box {
    width: 52px;
    height: 52px;
  }
  .upload__btn {
    font-size: 36px;
  }
  .zelda__box {
    position: absolute;
    right: -52px;
    top: -2px;
    transition: 0.75s;
  }
}

@media (max-width: 500px) {
  .footer__wrap {
    display: none;
  }
  header {
    display: none;
  }
  .margin__borders {
    display: none;
  }
  footer {
    display: none;
  }
  body {
    background-color: var(--gamecube-color);
  }
  .mobile__page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
  }
}
