/*  ===========
    Variables
    ===========  */

:root {
  /* colors */
  --light-grey: #f5f5f3;
  --red: #0f5132;
  --dark-brown: #212015;

  /* font sizes */
  --fs-400: 1.4rem;
  --fs-500: 1.6rem;
  --fs-600: clamp(3.2rem, 4vw, 6rem);
}

@media (min-width: 600px) {
  :root {
    --fs-400: 1.6rem;
    --fs-500: 1.8rem;
  }
}

/*  ===========
    Reset
    ===========  */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
}

img {
  max-width: 100%;
  display: block;
}

h1,
p,
ul {
  margin: 0;
  padding: 0;
}

ul {
  list-style: none;
}

a {
  color: inherit;
  text-decoration: none;
}

/*  ===========
    Layout
    ===========  */

body {
  margin: 0;
  font-family:'Times New Roman', Times, serif;
  font-size: var(--fs-400);
  font-weight: 400;
  background: var(--light-grey);
  color: var(--dark-brown);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-decoration: bold;
}

.container {
  max-width: 180rem;
  margin: 0 auto;
  padding: 0 3rem;
}

@media (min-width: 600px) {
  .container {
    padding: 0 4rem;
  }
}

/*  ===========
    Components
    ===========  */

.primary-button,
.secondary-button {
  min-height: 3em;
  padding: 1em 2.5em;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
}

.primary-button {
  color: var(--light-grey);
  background: var(--red);
}

.secondary-button {
  gap: 1.2rem;
}

.secondary-button img {
  height: 1.8rem;
}

/*  ===========
    Header
    ===========  */

nav {
  height: 10rem;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo,
.mobile-nav,
li {
  cursor: pointer;
}

.primary-nav,
.login-nav {
  display: none;
}

.logo,
.primary-nav,
.login-nav,
.mobile-nav {
  opacity: 0;
  transform: translateY(2rem);
  animation: returnToOrigin 0.3s ease-out forwards;
}

.logo {
  color: var(--red);
  font-weight: 700;
  animation-delay: 0.5s;
}

.mobile-nav {
  height: 1.4rem;
  animation-delay: 0.6s;
}

.primary-nav {
  animation-delay: 0.6s;
}

.login-nav {
  animation-delay: 0.7s;
}

@media (min-width: 600px) {
  .mobile-nav {
    height: 1.6rem;
  }
}

@media (min-width: 900px) {
  nav {
    height: 12rem;
  }

  .mobile-nav {
    display: none;
  }

  .login-nav,
  .primary-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 3.5rem;
  }
}

/*  ===========
    Main
    ===========  */

main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  padding: 0 3rem;
}

.main-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1.8rem;
}

.main-image,
.main-content h1,
.main-content p,
.main-button {
  opacity: 0;
  animation: returnToOrigin 0.5s ease-out forwards;
}

.main-content h1,
.main-content p {
  transform: translateY(2rem);
}

.main-image {
  max-width: 45rem;
  opacity: 0;
  transform: scale(1.1);
  animation-delay: 1s;
}

.main-content h1 {
  max-width: 40rem;
  text-transform: uppercase;
  font-size: var(--fs-600);
  font-weight: 500;
  line-height: 1;
  animation-delay: 1.1s;
}

.main-content span {
  color: var(--red);
}

.main-content p {
  max-width: 30rem;
  line-height: 1.6;
  animation-delay: 1.2s;
}

.main-buttons {
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.4rem;
}

.main-button:nth-child(1) {
  transform: translateX(-2rem);
  animation-delay: 1.3s;
}

.main-button:nth-child(2) {
  transform: translateX(2rem);
  animation-delay: 1.4s;
}

@media (min-width: 600px) {
  .main-content {
    gap: 2.4rem;
  }

  .main-content h1 {
    max-width: 40rem;
  }

  .main-content p {
    max-width: 35rem;
  }
}

@media (min-width: 900px) {
  main {
    max-width: 140rem;
    margin: 0 auto;
    padding: 0 4rem;
    flex-direction: row;
    justify-content: space-between;
  }

  .main-content {
    width: 50%;
    align-items: flex-start;
    text-align: start;
    gap: 4rem;
  }

  .main-content h1 {
    max-width: 100%;
    animation-delay: 1s;
  }

  .main-content p {
    max-width: 65%;
    animation-delay: 1.1s;
  }

  .main-image {
    width: 50%;
    order: 2;
    max-width: 60rem;
    animation-delay: 1s;
  }

  .main-buttons {
    width: 100%;
    flex-direction: row;
    justify-content: flex-start;
  }

  .main-button:nth-child(1) {
    transform: translateY(2rem);
    animation-delay: 1.2s;
  }

  .main-button:nth-child(2) {
    transform: translateY(2rem);
    animation-delay: 1.3s;
  }
}

/*  ===========
    Footer
    ===========  */

footer {
  width: 100%;
  height: 14rem;
  margin-bottom: 6rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-evenly;
}

.footer-links,
.footer-socials {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 4rem;
  opacity: 0;
  transform: translateY(2rem);
  animation: returnToOrigin 0.3s ease-out forwards;
}

.footer-links {
  text-align: center;
  animation-delay: 1.7s;
}

.footer-socials {
  animation-delay: 1.6s;
}

.footer-socials img {
  height: 1.6rem;
}

@media (min-width: 900px) {
  footer {
    height: 10rem;
    flex-direction: row;
    justify-content: space-between;
  }

  .footer-socials {
    order: 2;
    animation-delay: 1.7s;
  }

  .footer-socials img {
    height: 1.8rem;
  }

  .footer-links {
    animation-delay: 1.6s;
  }
}

/*  ===========
    Animations
    ===========  */

@keyframes returnToOrigin {
  to {
    transform: translate(0);
    opacity: 1;
  }
}
