/* NORMALIZE.CSS v8.0.1 */

html{line-height:1.15;-webkit-text-size-adjust:100%}body{margin:0}main{display:block}h1{font-size:2em;margin:.67em 0}hr{box-sizing:content-box;height:0;overflow:visible}pre{font-family:monospace,monospace;font-size:1em}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}

/* BASE */

* {
    box-sizing: border-box;
}

body {
    font-family: 'Lato', sans-serif;
    font-size: 16px;
    line-height: 1.4;
    color: #404040;
    min-height: 100vh;
    display: flex;
    flex-wrap: wrap;
    flex-direction: column;
    justify-content: space-between;
}

.wrap {
    max-width: 1180px;
    padding: 0 20px;
    margin: 0 auto;
}

a {
    color: #404040;
    outline: none;
}

.flex {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    width: 100%;
}

.flex_2 > * {
    width: 49%;
}

.flex_3 > * {
    width: 32%;
}

.btn {
    padding: 0.5em 1em;
    background: #69bcac;
    color: #fff;
    display: inline-block;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
}

/* HEADER */

header {
    border-bottom: 1px solid #e9e9e9;
    padding: 0.75em 20px;
}

header img {
    max-width: 300px;
    vertical-align: middle;
}

header a {
    text-decoration: none;
}

h1 {
    display: none;
}

/* FOOTER */

footer a {
    text-decoration: none;
    color: #fff;
}

footer a:hover {
    text-decoration: underline;
}

#footer_top {
    font-size: 14px;
    padding: 1em 20px;
    background: #f9f9f9;
}

#footer_bottom {
    color: #fff;
    padding: 1em 20px;
    background: #1a1a1a;
    font-size: 10px;
}

#footer_bottom p {
    margin: 0;
}

/* MAIN */

#title {
    position: relative;
    text-align: center;
    padding: 7em 20px;
    box-shadow: inset 0 0 8px rgba(0,0,0,0.15);
    background: transparent url('../img/header.jpg') no-repeat center center / cover;
}

#title::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.5);
}

#title h2 {
    position: relative;
}

#calculator_form {
    padding: 20px;
    background: #f9f9f9;
    border: 1px solid#ccc;
    border-top: none;
    text-align: right;
}

#calculator_form .flex {
    text-align: left;
}

#calculator {
    position: relative;
    padding: 4em 0;
}

#calculator.loading #calculator_form {
    display: none;
}

@-webkit-keyframes loader {
    to {transform: rotate(360deg);}
}

@keyframes loader {
    to {transform: rotate(360deg);}
}

#calculator_loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #f9f9f9;
    transition: 0.2s height ease-in-out;
    justify-content: center;
    display: flex;
    flex-wrap: wrap;
    flex-direction: column;
    text-align: center;
    display: none;
    z-index: 1;
}

#calculator.loading #calculator_loading {
    display: flex;
}

#calculator_loading span {
    font-weight: bold;
    min-height: 20px;
    position: relative;
    margin-bottom: 0.5em;
}

#calculator_loading span:not(:first-child):not(:nth-child(2)) {
    display: none;
}

.loader {
    margin-bottom: 1em !important;
}
   
.loader:before {
    content: '';
    box-sizing: border-box;
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin-top: -15px;
    margin-left: -15px;
    border-radius: 50%;
    border: 2px solid #ccc;
    border-top-color: #69bcac;
    animation: loader .6s linear infinite;
}

form label {
    margin: 0.75em 0;
    display: block;
    font-weight: 600;
}

form input, form select {
    border: 1px solid #ccc;
    border-radius: 1px;
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.075);
    width: 100%;
    padding: 0.5em 0.75em;
    transition: 0.2s box-shadow ease-in-out;
    outline: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: #fff;
}

form input:focus, form select:focus {
    border-color: #3139f2;
}

.form_deposit .input_wrap-right, #calculator:not(.active) .form_deposit.active .input_wrap-left, .form_payment input[name="MonthlyPayment"], #calculator.active .form_payment label[for="PurchasePrice"], .form_payment label[for="MonthlyPayment"], #calculator.active .form_payment input[name="PurchasePrice"] {
    display: none;
}

#calculator:not(.active) .form_deposit.active .input_wrap-right, #calculator.active .form_payment input[name="MonthlyPayment"], #calculator.active .form_payment label[for="MonthlyPayment"] {
    display: block;
}

form input[type="submit"] {
    min-width: 170px;
    background: rgba(255,102,51,1) url('../img/calc.svg') no-repeat 10px center / 20px 20px;
    border: none;
    color: #fff;
    cursor: pointer;
    margin-top: 1em;
    max-width: 150px;
    font-weight: bold;
    text-transform: uppercase;
    padding-left: 2em;
    padding-top: 0.75em;
    padding-bottom: 0.75em;
}

form input[type="submit"]:hover {
    background-color: rgba(224,76,26,1);
}

.input_wrap {
    position: relative;
}

.input_wrap span {
    width: 40px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    padding-left: 15px;
}

.input_wrap-left span {
    left: 0;
}

.input_wrap-right span {
    right: 0;
}

.input_wrap-left input {
    padding-left: 40px;
}

.input_wrap-right input {
    padding-right: 40px;
}

.form_deposit {
    padding-right: 80px;
    position: relative;
}

#calculator.active .form_deposit-wrap {
    display: none;
}

#calculator.active .form_payment {
    width: 100%;
}

.form_deposit-switch {
    position: absolute;
    bottom: 0;
    right: 0;
    height: 100%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    background:#d9d9d9;
    width: 80px;
    cursor: pointer;
}

#calculator.active .form_deposit-switch {
    display: none;
}

.form_deposit-switch span {
    width: 50%;
    border: 1px solid#d9d9d9;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    user-select: none;
}

.form_deposit-switch span:first-child {
    border-left: none;
    border-right: none;
}

.form_deposit .form_deposit-switch span strong {
    position: relative;
    font-weight: 400;
    z-index: 1;
}

.form_deposit-switch span::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 100%;
    background: #f9f9f9;
    display: block;
    transition: 0.2s width ease-in-out;
}

.form_deposit-switch span:last-child::after {
    width: 0;
    right: auto;
    left: 0;
}

.form_deposit.active .form_deposit-switch span:first-child::after {
    width: 0;
}

.form_deposit.active .form_deposit-switch span:last-child::after {
    width: 100%;
}

#calculator.active .form_deposit-float {
    display: block;
}

#calculator.active .form_deposit-perc {
    display: none;
}

.form_results {
    text-align: center;
    padding: 20px 0px;
    font-weight: bold;
    margin-bottom: 2em;
    margin-top: 2em;
    justify-content: center;
}

.form_results > div:first-child {
    width: 100%;
    margin-bottom: 2em;
}

.form_results > div:first-child > span {
    font-size: 60px;
    color: #ff6633;
}

.form_results > div:first-child label span:not(:last-child), .form_results > div:first-child > span span:not(.active) {
    display: none;
}

.form_results-switch span.active {
    background: #ff6633;
    color: #fff;
}

.form_results label {
    width: 100%;
    display: block;
    padding: 0.25em 0;
    font-size: 14px;
}

.form_results > div > span {
    display: inline-block;
    font-size: 36px;
    display: block;
}

.form_results-switch span:not(.active):hover {
    background: 
    #d8d8d8;
}

.form_results > div {
    margin: 0 2em;
}

.form_results-switch {
    border-radius: 20px;
    overflow: hidden;
    display: inline-block;
    margin-top: 1em;
}

.form_results-switch span {
    padding: 0.5em 1em;
    background: #f1f1f1;
    display: inline-block;
    cursor: pointer;
}

#form_switch-wrap {
    position: relative;
}

#form_switch {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

#form_switch span {
    background: #d8d8d8;
    user-select: none;
    transition: 0.2s background ease-in-out;
    padding: 1em;
    font-size: 14px;
    font-weight: bold;
    display: inline-block;
    cursor: pointer;
    border: 1px solid#ccc;
    border-bottom: none !important;
    width: 50%;
    text-align: center;
}

#form_switch span:hover {
    background: #f1f1f1;
}

#calculator.active #form_switch span:last-child, #calculator:not(.active) #form_switch span:first-child {
    background: #f9f9f9;
}

#form_switch span:last-child {
    border-left: none;
}

#form_switch + div {
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    height: 100%;
    z-index: 1;
}

#calculator.active #form_switch + div {
    left: auto;
    right: 0;
}

.disclaimer {
    font-size: 10px;
}

.form_table {
    width: 100%;
    border: 1px solid #ccc;
    border-spacing: 0;
    margin-top: 4em;
    font-size: 14px;
}

.form_table tbody tr:nth-child(2n+1) {
    background: #f9f9f9;
}

.form_table td:not(:nth-child(1)), .form_table th:not(:nth-child(1)) {
    width: 30%;
    text-align: left;
    padding: 0.5em 1em;
}

.form_table td:nth-child(1), .form_table th:nth-child(1) {
    width: 10%;
    text-align: left;
    padding: 0.5em 1em;
}

.form_table td:not(:last-child), .form_table th:not(:last-child) {
    border-right: 1px solid #ccc;
}

.form_table tr td {
    border-top: 1px solid #ccc;
}


/* RESPONSIVE */

@media screen and (max-width: 767px) {

    .form_results > div {
        margin: 0;
    }

    .form_table td, .form_table th {
        padding: 0.5em !important;
        font-size: 12px !important;
    }

    .form_table td:first-child, .form_table th:first-child {
        display: none;
    }

    body {
        font-size: 14px;
    }

    header {
        border: none;
        padding-top: 1.5em;
    }

    header a {
        display: block;
        text-align: center;
    }

    header img {
        max-width: 280px;
    }

    #title {
        display: none;
    }

    #calculator {
        padding: 1em 0 2em 0;
    }

    #form_switch span {
        padding: 0.5em 1em;
        font-size: 12px;
    }

    #calculator .flex > div {
        width: 100%;
    }

    form input[type="submit"] {
        max-width: 100%;
    }

    #footer_top {
        font-size: 12px;
    }

}

@media screen and (max-width: 374px) {

    #form_switch span {
        padding: 0.5em 2em;
    }

}