/*=========GOOGLE FONTS===== */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@500;600&display=swap');

/* ========= VARIABLES CSS ========= */
:root {
    /*====== Colors ======= */
    /* Color mode HSL & RGB*/
    --first-color: hsl(79, 100%, 49%);
    --white-color: #fff;
    --black-color: #000;

    /*======Font and typography ====== */
    /* .5rem = 8px / 1rem = 16px ... */
    --body-font: 'Poppins', sans-serif;
    --normal-font-size: .938rem;
    --tiny-font-size: .563rem;
}

/*Responsive typography */
@media screen  and (min-width: 968px) {
    :root{
      --normal-font-size: 1rem;
  }   
}

/*========= BASE ========= */
* {
    padding: 0;
    margin: 0;
  box-sizing: border-box;
}

body {
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
    background: -webkit-linear-gradient(to bottom, #74ebd5, #acb6e5);
    background: linear-gradient(to bottom, #74ebd5, #acb6e5);
    font-size: 16px;
    line-height: 1;

}

/*=========== MODERN INPUT ======== */
header {
    width: 100%;
    height: 100px;
    display: flex;
    margin-top: 20px;
    align-items: center;
    justify-content: center;
   
}

header h1 {
    font-size: 45px;
}

.form {
    height: 80vh;
    display: grid;
    place-items: center;
    margin: 0 1.5rem;
    
}

.form_content {
  display: grid;
  align-items: center;
  justify-content: center;
  row-gap: 3.4rem;
 width: 30%;
  background-color: #ecedee;
  border-radius: 25px;
 
}

.form_input,
.form_label,
.form_submit {
    border: 0;
    outline: none;
    font-size: var(--normal-font-size);
    font-family: var(--body-font);
   
}

.form_box {
    top: 25px;
    width: 380px;
    height: 50px;
    position: relative;
    border-radius: 20px;

}

.form_shadow {
    position:absolute;
    width: 100%;
    height: 100%;
    background-color: var(--black-color);
    border-radius: 25px;
}

.form_input {
    border-radius: 25px;
    position: absolute;
    border: 2.5px solid var(--black-color);
    background-color: var(--white-color);
    width: 100%;
    height: 100%;
    z-index: 10;
    padding: 18px;
    transition: transform .3s;
}

.form_input::placeholder {
    transition: opacity .5s;
    
}

.form_label {
    z-index: 100;
    position: absolute;
    top: 16px;
    left: 20px;
    font-size: var(--tiny-font-size);
    font-weight: 600;
    transition: .2s;
    pointer-events: none;
    opacity: 0;
}

.form_button {
    border-radius: 25px;
    justify-self: flex-end;
    background-color: var(--black-color);
    margin-bottom: 30px;
}

.form_submit {
    width: 120px;
    height: 40px;
    border-radius: 24px;
    padding: .275rem 1rem;
    color: var(--black-color);
    background-color: var(--first-color);
    cursor: pointer;
    transition: transform .3;
}

.form_submit:hover {
    transform: translate(-6px, -6px);
    
}

/*Opaque placeholder */
.form_input:focus::placeholder {
    opacity: 0;
    transition: .3s;
}

/* Move input and sticky input up */
.form_input:focus,
.form_input:not(:placeholder-shown).form_input:not(:focus){
    transform: translate(-8px, -8px);
    padding: 28px 18px 18px;
    animation: input-animation .5s;
}

/* Move label and sticky label up */
.form_input:focus + .form_label,
.form_input:not(:placeholder-shown).form_input:not(:focus) + .form_label {
    opacity: 1;
    top: 2px;
    left: 12px;
    transition: .3s;
}

/* Input bounce animation */
@keyframes input-animation {
    0% {
        transform: translate(0);
    }
    40% {
        transform: translate(-9px, -9px);
    }
    60% {
        transform: translate(-7px, -7px);
    }
}

/*======= BREAKPOINTS ======== */
/* Form small devices */
@media screen and (max-width: 340px) {
    .form_content,
    .form_box {
        width: 100%;
    }
}

/* For large devices */
@media screen and (min-width: 968px) {
    .form_content {
      zoom: 1.1;
    }
}