@import url("https://fonts.googleapis.com/css2?family=Major+Mono+Display&family=Open+Sans:wght@400;500;700&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

/* =========== Root =========== */
:root {
  /* =========== Colors =========== */
  --website-background: #e5dbf6;
  /* #9400ff dark mode */
  --elements-background: #ffffff80;
  --text-color: #000000;
  --button-background: #ffffff00;
  --button-hover: #ffffff;
  --border-radius: 0.3rem;
  --box-shadow: #00000080;
  --box-shadowHover: 0 4px 8px 0 #ffffff00;
  --second-tone: #1100ff80;
  --scrollbar-color: #9500ff41 #ffffff80;

  /* =========== Fonts =========== */
  /*
        font-family: 'Major Mono Display', monospace;
        font-family: 'Open Sans', sans-serif;
    */
  --navbar-font-family: 'Major Mono Display', monospace;
  --logo-font-family: 'Major Mono Display', monospace;
  --h1h2-font-family: "Open Sans", sans-serif;
  --h1h2-font-weight: 700;
  --h3h4-font-family: "Open Sans", sans-serif;
  --h3h4-font-weight: 500;
  --all-font-family: "Open Sans", sans-serif;
  --all-font-weight: 400;
  --second-tone: ;
}

@media (prefers-color-scheme: dark) {
  :root {
    /* =========== Colors =========== */
    --website-background: #17191a;
    --elements-background: #181a1a80;
    --text-color: #ffffff;
    --button-background: #181a1a80;
    --button-hover: #ffffff30;
    --box-shadow: #000000;
    --box-shadowHover: 0 4px 8px 0 #0f1011;
    --second-tone: #1100ff;
    --icon-tone: #9400ff;
    --scrollbar-color: #9400ff #ffffff80;
  }
}

/* =========== Root end =========== */

html {
  background: var(--website-background);
  background-size: cover;
  scrollbar-color: var(--scrollbar-color);
}

a {
  text-decoration: none;
  color: var(--text-color);
}

/* =========== Fonts =========== */
h1,
h2 {
  font-family: var(--h1h2-font-family);
  font-weight: var(--h1h2-font-weight);
}

h3,
h4 {
  font-family: var(--h3h4-font-family);
  font-weight: var(--h3h4-font-weight);
}

h5,
h6,
small,
p {
  font-family: var(--all-font-family);
  font-weight: var(--all-font-weight);
}

/* =========== Fonts end =========== */

.icon-tone {
  color: var(--icon-tone);
}

/* ============= Navbar ============= */
.navbar {
  transition: all 0.7s ease-in-out;
  background: var(--elements-background);
  font-family: var(--navbar-font-family);
  position: fixed;
  color: var(--text-color);
  backdrop-filter: blur(10px);
  width: 100%;
  height: 60px;
  display: inline;
  display: grid;
  grid-template-columns: 1fr 0% 50% 0% 1fr;
  z-index: 100;
}

.nav_logo {
  font-family: var(--logo-font-family);
  font-size: 2rem;
  display: inline;
  float: left;
  padding: 10px 0 10px 10px;
  cursor: pointer;
}

.nav_list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.2rem;
  text-align: center;
  padding: 10px 0;
}

.nav_link {
  transition: all 0.3s ease;
  font-size: large;
  display: inline;
  padding: 10px;
}

.nav_link:hover {
  cursor: pointer;
  font-size: larger;
}

.nav_btns {
  float: right;
  padding: 12px 10px 0 0;
  display: inline;
}

.nav_btn,
.mobile_login-btn {
  background-color: var(--button-background);
  border-color: var(--button-background);
  border: solid;
  border-color: var(--icon-tone);
  color: var(--text-color);
  border-radius: var(--border-radius);
  backdrop-filter: blur(10px);
  float: right;
  padding: 6px 10PX;
  margin: 2px;
}

.icon-tone:hover,
.mobile_login-btn:hover {
  color: var(--text-color);
  border-color: var(--text-color);
}

.mobile_login-btn {
  padding: calc(2.2px);
}

.darkLight {
  padding: calc(2.5px) 5px;
}

#darkLight {
  width: 20px;
  cursor: pointer;
}

.search_btn {
  padding: calc(5.8px) 9px;
}

.nav_btn:hover,
.mobile_login-btn:hover {
  background: var(--button-hover);
  backdrop-filter: blur(10px);
  cursor: pointer;
}

@media screen and (max-width: 768px) {
  .nav_links {
    visibility: hidden;
  }

  .nav_btn {
    display: none;
  }
}

/* ============= Navbar end ============= */

/*################################### */

main {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.container {
  position: relative;
  max-width: 430px;
  width: 100%;
  background: var(--elements-background);
  border-radius: 10px;
  box-shadow: 0 5px 10px #0000001a;
  overflow: hidden;
  margin: 0 20px;
}

.container .forms {
  display: flex;
  align-items: center;
  height: 440px;
  width: 200%;
  transition: height 0.2s ease;
}

.container .form {
  width: 50%;
  padding: 30px;
  background-color: var(--elements-background);
  transition: margin-left 0.18s ease;
}

.container.active .login {
  margin-left: -50%;
  opacity: 0;
  transition: margin-left 0.18s ease, opacity 0.15s ease;
}

.container .signup {
  opacity: 0;
  transition: opacity 0.09s ease;
}

.container.active .signup {
  opacity: 1;
  transition: opacity 0.2s ease;
}

.container.active .forms {
  height: 600px;
}

.container .form .title {
  position: relative;
  color: var(--text-color);
  font-size: 27px;
  font-weight: 600;
}

.form .title::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 30px;
  background-color: var(--second-tone);
  border-radius: 25px;
}

.form .input-field {
  position: relative;
  height: 50px;
  width: 100%;
  margin-top: 30px;
}

.input-field input {
  position: absolute;
  height: 100%;
  width: 100%;
  padding: 0 35px;
  border: none;
  outline: none;
  font-size: 16px;
  border-bottom: 2px solid #cccccc;
  border-top: 2px solid transparent;
  border-radius: 5px;
  transition: all 0.2s ease;
}

.input-field input:is(:focus, :valid) {
  border-bottom-color:var(--second-tone);
}

.input-field i {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #999999;
  font-size: 23px;
  transition: all 0.2s ease;
}

.input-field input:is(:focus, :valid)~i {
  color: var(--second-tone);
}

.input-field i.icon {
  left: 0;
}

.input-field i.showHidePw {
  right: 0;
  cursor: pointer;
  padding: 10px;
}

.form .checkbox-text {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 20px;
}

.checkbox-text .checkbox-content {
  display: flex;
  align-items: center;
}

.checkbox-content input {
  margin-right: 10px;
  accent-color: var(--second-tone);
}

.form .text {
  color: var(--text-color);
  font-size: 14px;
}

.form a.text {
  color: var(--second-tone);
  text-decoration: none;
}

.form a:hover {
  text-decoration: underline;
}

.form .button {
  margin-top: 35px;
}

.form .button input {
  color: var(--text-color);
  font-size: 17px;
  font-weight: 500;
  border: solid;
  letter-spacing: 1px;
  border-radius: 6px;
  background-color: var(--elements-background);
  cursor: pointer;
  transition: all 0.3s ease;
}

.button input:hover {
  background-color: var(--second-tone);
  backdrop-filter: blur(10px);
}

.form .login-signup {
  margin-top: 30px;
  text-align: center;
}

/* =========== Mobile navbar =========== */
nav.mobile_nav {
  box-shadow: 0 4px 8px 0 var(--box-shadow);
  display: flex;
  position: fixed;
  color: var(--text-color);
  bottom: 0;
  font-family: "Open Sans", sans-serif;
  font-weight: 500;
  width: 100%;
  padding: 0.5rem 0;
  background: var(--elements-background);
  backdrop-filter: blur(10px);
  z-index: 100;
  margin: 0 auto;
}

.mobile_nav {
  transition: all 0.5s ease-in-out;
}

nav.mobile_nav ul {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  margin: 0;
  justify-self: center;
  vertical-align: middle;
}

nav.mobile_nav ul li {

  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 0.7rem;
  flex-grow: 1;
  margin: 0;
}

nav.mobile_nav ul li a {
  color: var(--text-color);
  font-size: inherit;
}

nav.mobile_nav ul li a svg {
  width: 24px;
  height: 24px;
  display: block;
  margin: 0 auto;
}

.s-size {
  font-size: 24px;
  display: block;
  margin-left: 3px;
}

.menu {
  margin-left: 5px;
}

.random {
  margin-left: 10px;
}

.account {
  width: 24px;
  height: 24px;
  display: block;
  margin: 0 auto;
  cursor: pointer;
  color: var(--text-color);
}

@media screen and (min-width: 768px) {
  nav.mobile_nav {
    display: none;
  }
}