@import url("https://fonts.googleapis.com/css?family=Josefin+Sans:300,400,600&display=swap");

/* Colors */

/* Primary */
:root {
  --Desaturated-Red: hsl(0, 36%, 70%);
  --Soft-Red: hsl(0, 93%, 68%);
}

/* Neutral */
:root {
  --Dark-Grayish-Red: hsl(0, 6%, 24%);
}

/* Gradients */
:root {
  --Gradient-1: linear-gradient(135deg, hsl(0, 0%, 100%), hsl(0, 100%, 98%));
  --Gradient-2: linear-gradient(135deg, hsl(0, 80%, 86%), hsl(0, 74%, 74%));
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  border: none;
}

body {
  background-image: var(--Gradient-1);
  font-family: "Josefin Sans", sans-serif;
}

.container {
  display: flex;
  min-height: 100vh;
}

.logo {
  margin: 60px 0;
  width: 200px;
}

.bg-mobile {
  display: none;
}

h1 {
  color: var(--Dark-Grayish-Red);
  font-size: 60px;
  letter-spacing: 10px;
  text-transform: uppercase;
  margin-bottom: 25px;
  margin-top: 10px;
  line-height: 1.1;
  transform: translateX(-100%);
  animation: comeinLeft 0.5s ease forwards;
}

h1 span {
  color: var(--Desaturated-Red);
  font-weight: 200;
}

p {
  color: var(--Desaturated-Red);
  line-height: 26px;
  transform: translateX(100%);
  opacity: 0;
  animation: comeinRight 0.5s ease forwards;
}

.left-sec {
  background-image: url("../images/bg-pattern-desktop.svg");
  background-size: cover;
  background-position: center center;
  padding: 0 40px 40px;
  width: 60%;
}

.left-sec__content {
  margin: 0 auto;
  max-width: 450px;
}

.rigth-sec {
  width: 40%;
}

.bg-img {
  background-image: url("../images/hero-desktop.jpg");
  background-size: cover;
  background-position: center center;
}

form {
  position: relative;
  margin-top: 25px;
  transform: translateX(-100%);
  animation: comeinLeft 0.5s ease forwards;
}

input {
  background-color: transparent;
  border: 1px solid var(--Desaturated-Red);
  padding: 15px 30px;
  border-radius: 50px;
  width: 100%;
  height: 55px;
  font-size: 16px;
}

input:focus {
  outline: none;
  border-width: 2px;
  box-shadow: 0px 0px 10px hsla(0, 36%, 70%, 0.5);
}

input::placeholder {
  color: var(--Desaturated-Red);
}

form.error input {
  border: 2px solid var(--Soft-Red);
}

button {
  position: absolute;
  top: 0;
  right: 0;
  background-image: var(--Gradient-2);
  padding: 15px;
  border-radius: 50px;
  width: 100px;
  height: 55px;
  box-shadow: 2px 5px 10px hsla(0, 36%, 70%, 0.5);
  transition: opacity 0.2s ease;
  cursor: pointer;
}

button:hover {
  opacity: 0.6;
}

.error-icon {
  display: none;
  position: absolute;
  top: 15px;
  right: 110px;
}

form.error .error-icon {
  display: block;
}

small {
  display: none;
  margin-top: 15px;
  margin-left: 30px;
  color: var(--Soft-Red);
}

form.error small {
  display: block;
}

/* //////// Animations //////////// */

@keyframes comeinLeft {
  to {
    transform: translateX(0);
  }
}

@keyframes comeinRight {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@media screen and (max-width: 600px) {
  .logo {
    margin: 30px 0;
    width: 100px;
  }

  h1 {
    font-size: 40px;
  }

  .bg-mobile {
    display: block;
    margin: 0 -40px;
    width: calc(100% + 80px);
  }

  .left-sec {
    width: 100%;
  }

  .rigth-sec {
    display: none;
  }
}
