@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@300;400;600;800&display=swap');

:root {
    --main-color: #0275d8;
    --secundary-color: #5aaffa;
    --lighter-color: #e0e0e7;
    --light-color: #b0b0c0;
    --dark-color: #52505e;

    --font-smaller: 14px;
    --font-bigger: 20px;
}

* {
    margin: 0;
    padding: 0;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Nunito', sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.8;
    color: var(--dark-color);
    background: var(--main-color);
}

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

ul {
    list-style: none;
}

h1,
h2,
h3 {
    font-weight: 700;
    line-height: 1.25;
    margin: 0 0 0.5em;
}

h4 {
    color: var(--light-color)
}

img {
    max-width: 100%;
    vertical-align: middle;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2em;
}

.form-box {
    display: flex;
    flex-direction: column;
    margin-top: 1em;
    border: 8px solid var(--lighter-color);
    border-radius: 15px;
    background-color: #faf9ff;
}

/* ==> Progress*/
.form-box .progress {
    position: relative;
    padding: 1em;
}

.logo {
    padding: 40px 48px;
}

/* ==> Progress Steps*/
.progress ul.progress-steps {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 2em;
}

.progress ul.progress-steps li {
    position: relative;
    display: flex;
    align-items: center;
    margin-bottom: 2em;
}

.progress ul.progress-steps li>span {
    position: relative;
    width: 40px;
    height: 40px;
    font-size: var(--font-smaller);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1em;
    border-radius: 50%;
    background-color: var(--lighter-color);
    z-index: 1;
}

.progress ul.progress-steps li.active>span {
    color: white;
    background-color: var(--main-color);
    border: 4px solid var(--secundary-color);
    z-index: 1;
}

.progress ul.progress-steps li p span {
    font-size: var(--font-smaller);
    color: var(--light-color);
    display: none;
}

.progress ul li p {
    position: absolute;
    top: -2em;
    font-size: 12px;
}

/* ==> Form */
.form-box form {
    width: 100%;
    padding: 3em 1em;
    background-color: white;
    border-radius: 30px 30px 15px 15px;
}

form>div {
    max-width: 400px;
    margin: 0 auto;
}

form>div ol{
    max-width: 400px;
    padding: 1em;
}

form>div p {
    color: var(--light-color);
    margin-bottom: 2em;
}

form>div>div:not(.checkbox) {
    display: flex;
    flex-direction: column;
    margin-bottom: 1em;
}

form :where(input,select) {
    height: 40px;
    padding: 0 1em;
    border-radius: 7px;
    outline-color: var(--secundary-color);
    border: 1px solid var(--lighter-color);
    background-color: transparent;
    font-size: 16px;
}

form label {
    font-size: var(--font-bigger);
    margin-bottom: 0.5em;
    font-weight: 600;
}

form .grouping {
    display: flex;
}

form .grouping input {
    max-width: 70px;
    text-align: center;
    margin-right: 1em;
}

form .checkbox input {
    height: auto;
}

form > div:not(.btn-group){
    display: none;
    -webkit-animation: fadeIn .6s cubic-bezier(0.39, 0.575, 0.565, 1) both;
    animation: fadeIn .6s cubic-bezier(0.39, 0.575, 0.565, 1) both;
}

@keyFrames fadeIn{
    0% {
        opacity: 0;
        -webkit-transform: translateY(10%);
        transform: translateY(10%);
    }
    100% {
        opacity: 1;
        -webkit-transform: translateY(0);
        transform: translateY(0);
    }
}

form > div.active{
    display: block;
}

.forgot{
    color: var(--main-color);
}

/* ==> Button*/
/* We will hide form elements so we can see button styling*/


.btn-group {
    display: flex;
    flex-wrap: wrap;
    gap: 1em;
    margin-top: 2em;
}

.btn-group [class*="btn-"] {
    background-color: var(--main-color);
    color: white;
    padding: 1em 2.5em;
    border: 4px solid var(--secundary-color);
    border-radius: 30px;
    cursor: pointer;
    -webkit-transition: background-color .3s, border-color .3s ease-out;
    transition: background-color .3s, border-color .3s ease-out;
}

.btn-group [class*="btn-"]:disabled {
    background-color: var(--light-color);
    border-color: var(--lighter-color);
    cursor: text;
}

.btn-group [class*="btn-"]:hover:not(:disabled) {
    background-color: var(--dark-color);
    border-color: var(--light-color);
}

.btn-group .btn-submit,
.form-three.active ~ .btn-group .btn-next{
    display: none;
}

.form-three.active ~ .btn-group .btn-submit{
    display: block;
}

.form-three.active ~ .btn-group {
    justify-content: space-between;
}

::placeholder {
    color: var(--light-color);
}

#snackbar {
    visibility: hidden;
    min-width: 250px;
    margin-left: -125px;
    padding: 20px;
    background-color: #f44336;
    color: white;
    text-align: center;
    border-radius: 2px;
    position: fixed;
    z-index: 1;
    left: 50%;
    bottom: 30px;
    font-size: 17px;
    opacity: 1;
  }
  
  #snackbar.show {
    visibility: visible;
    -webkit-animation: fadein 0.5s, fadeout 0.5s 2.5s;
    animation: fadein 0.5s, fadeout 0.5s 2.5s;
  }


@media screen and (min-width: 768px) {
    .form-box {
        flex-direction: row;
    }

    .form-box .progress {
        flex: 1 0 35%;
        min-width: 300px;
        padding: 3em;
    }

    .logo {
        margin: -48 -48px 48px;
    }

    .progress ul.progress-steps {
        flex-direction: column;
        gap: 0;
    }

    .progress ul.progress-steps li:not(:last-child)::before {
        content: '';
        position: absolute;
        left: 20px;
        top: 30px;
        width: 2px;
        height: 65px;
        background-color: var(--lighter-color);
    }

    .form-box form {
        padding: 3em;
        border-radius: 0 15px 15px 0;
    }

    .progress ul li p {
        position: relative;
        top: auto;
        font-size: inherit;
    }

    .progress ul.progress-steps li p span {
        display: block;
    }
}

/*Snackbar*/
#snackbar {
    visibility: hidden;
    min-width: 250px;
    margin-left: -125px;
    padding: 20px;
    background-color: #f44336;
    color: white;
    text-align: center;
    border-radius: 2px;
    position: fixed;
    z-index: 1;
    left: 50%;
    bottom: 30px;
    font-size: 17px;
    opacity: 1;
  }
  
  #snackbar.show {
    visibility: visible;
    -webkit-animation: fadein 0.5s, fadeout 0.5s 2.5s;
    animation: fadein 0.5s, fadeout 0.5s 2.5s;
  }
  
  #successSnackbar {
    visibility: hidden;
    min-width: 250px;
    margin-left: -125px;
    padding: 20px;
    background-color: #04AA6D;
    color: white;
    text-align: center;
    border-radius: 2px;
    position: fixed;
    z-index: 1;
    left: 50%;
    bottom: 30px;
    font-size: 17px;
    opacity: 1;
  }
  
  #successSnackbar.show {
    visibility: visible;
    -webkit-animation: fadein 0.5s, fadeout 0.5s 2.5s;
    animation: fadein 0.5s, fadeout 0.5s 2.5s;
  }
  
  @-webkit-keyframes fadein {
    from {bottom: 0; opacity: 0;} 
    to {bottom: 30px; opacity: 1;}
  }
  
  @keyframes fadein {
    from {bottom: 0; opacity: 0;}
    to {bottom: 30px; opacity: 1;}
  }
  
  @-webkit-keyframes fadeout {
    from {bottom: 30px; opacity: 1;} 
    to {bottom: 0; opacity: 0;}
  }
  
  @keyframes fadeout {
    from {bottom: 30px; opacity: 1;}
    to {bottom: 0; opacity: 0;}
  }