/* Hide arrows on number input */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
input[type=number] {
    -moz-appearance: textfield; /* Firefox */
}
#mobile-progress {
  display: none;
}
#calculator {
  display: block;
  position: relative;
  width: 100%;
  scroll-behavior: smooth;
}
#calculator #calculations,
#calculator #results,
#calculator #form {
  width: 50%;
  top: 0;
}
/* Left hand side calculator */
#calculator #calculations {
  padding-left: 10px;
  padding-right: 10%;
}
#calculator #calculations h2 {
  max-width: 350px;
  margin-bottom: 40px;
}

#calculator .underlined-title {
  display: inline;
  padding-bottom: 10px;
  background: linear-gradient(to right, transparent, transparent), linear-gradient(to right, #FD70A6, #FD70A6, #FD70A6);
  background-size: 100% 0.14em, 0 0.14em;
  background-position: 100% 100%, 0 85%;
  background-repeat: no-repeat;
}

#calculator .underlined-title.in-view {
  background-size: 0 0.14em, 100% 0.14em;
}


#calculator #calculations p {
  max-width: 500px;
}
@-moz-document url-prefix() {
  #calculator #calculations p {
    margin-bottom: 19px;
  }  
}
#calculator #calculations form {
  background-color: #fff;
  border: none;
  padding: 0;
  /* margin-top: -25px; */
}
#calculator #calculations form label {
  color: #000;
  margin-top: 10px;
}
#calculator #calculations form input {
  margin-bottom: 20px;
}
#calculator #calculations form label,
#calculator #calculations form input{
  /* float: left;
  clear: both; */
  padding: 8px 0 12px;
}

/* #calculateButton {
  border: 2px solid #242424;
  border-radius: 25px;
  padding: 8px 30px 10px;
  cursor: pointer;
  transition: background 0.3s;
} */


/* @-moz-document url-prefix() {
    #calculateButton {
      padding: 12px 30px 8px; 
    }
  } 
*/
  
/* #calculateButton:hover {
  background: #242424;
  color: #fff;
} */


.accident-rate-wrap {
  position: relative;
}
.accident-rate-wrap section.use-average {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  right: 0;
  display: flex;
  flex-direction: row;
  gap: 16px;
}

@supports (font: -apple-system-body) and (-webkit-appearance: none) {
      .accident-rate-wrap section.use-average {
        top: 50%;
        transform: translateY(-50%);      
        }

        .accident-rate-wrap section.use-average input {
          margin-top: 8px;
        }

        .accident-rate-wrap section.use-average p {
          margin-top: 8px;
        }

}
.accident-rate-wrap section.use-average p { 
  font-size: 14px;
  float: left;
}
/* Range slider styles */
.range-wrap {
  position: relative;
  margin: 0 auto 2rem;
}
.slider-container {
  position: relative;
  width: 100%; /* Adjust to your needs */
}
.slider {
  width: 100%; /* Adjust to your needs */
}
.slider-value {
  position: absolute;
  bottom: 0px; 
  left: 50%;
  transform: translateX(-50%);
  padding: 2px 5px; 
  font-size: 13px;
  color: #FD70A6;
  font-weight: 700;
}

@-moz-document url-prefix() {
  .slider-value {
    bottom: 0px; /* Firefox-specific positioning */
  }
}
/*********** Baseline, reset styles ***********/
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  cursor: pointer;
  width: 100%;
  margin-top: 25px;
  margin-bottom: 20px;
}

/* Removes default focus */
input[type="range"]:focus {
  outline: none;
}

/******** Chrome, Safari, Opera and Edge Chromium styles ********/
/* slider track */
input[type="range"]::-webkit-slider-runnable-track {
  background-color: #000000;
  border-radius: 0.5rem;
  height: 0.5rem;
}

/* slider thumb */
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; /* Override default look */
  appearance: none;
  margin-top: -8px; /* Centers thumb on the track */
  background-color: #fd70a6;
  border-radius: 1rem;
  height: 1.5rem;
  width: 1.5rem;
  box-shadow: none;
}

/*********** Firefox styles ***********/
/* slider track */
input[type="range"]::-moz-range-track {
  background-color: #000000;
  border-radius: 0.5rem;
  height: 0.5rem;
}

/* slider thumb */
input[type="range"]::-moz-range-thumb {
  background-color: #fd70a6;
  border: none; /*Removes extra border that FF applies*/
  border-radius: 1rem;
  height: 1.5rem;
  width: 1.5rem;
}

/* Form styles */
#calculator #form {
  position: absolute;
  left: 150%;
  top: 54px;
  transition: 0.5s ease-out;
  /* transition-delay: 0.8s; */
  height: auto;
  min-width: 300px;
  background: #242424;
  clip-path: polygon(50% 0%, 100% 0, 100% 90%, 90% 100%, 0 100%, 0 0);
  min-height: 700px;
}
#calculator #form.show {
  left: 50%;
}
#calculator #form.show.complete {
  left: 150%;
}
/* Results Styles */
#calculator #results {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  /* max-height: 576px; */
  padding-top: 58px;
  transition: filter 0.5s ease-in;
  position: absolute;
  left: 50%;
  filter: blur(0px);
  background: #fff;
}
#calculator #results.hide {
  filter: blur(4px);
  pointer-events: none;
}
#calculator #results.hide.no-blur {
  filter: blur(0px);
  pointer-events: all;
}


#calculator #results div {
  background-color: #CACACA;
  width: 48.5%;
  /* max-height: 357px; */
  color: #242424;
  padding: 80px 30px;
  position: relative;
}
#calculator #results div#total,
#calculator #results div#cost {
  background-image: url('https://www.ax-uk.com/hubfs/Calculators/total-icon.svg');
  background-repeat: no-repeat;
  background-position: 90% 8%;
}
#calculator #results div#cost {
  background-image: url('https://www.ax-uk.com/hubfs/Calculators/cost-icon.svg');
}
#calculator #results div:before {
  border-left: 60px solid #CACACA;
  border-bottom: 60px solid #fff;
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  width: 0;
}
#calculator #results div#cost:before {
  border-left: 80px solid #252525;
}
#calculator #results div p.question {
  font-size: 136px;
  font-weight: 900;
  line-height: 0.8em;
  transition: font-size 0.3s;
}
@-moz-document url-prefix() {
   #calculator #results div p.question {
    line-height: 1em;
   }
}
#calculator #results div p.question.result-text {
  font-size: 42px;
}
#calculator #results div p.description-text {
  font-size: 14px;
  line-height: 1.3em;
  opacity: 0;
  transition: opacity 0.3s;
}
#calculator #results div p.description-text.reveal {
  opacity: 1;
}
#calculator #results div#cost {
  background-color: #242424;
}
#calculator #results div#cost h4,
#calculator #results div#cost p {
  color: #fff;
  margin-top: 0px;
}
#calculator #results div#savings {
  width: 99.5%;
  max-height: 190px;
  padding-top: 50px;
  display: flex;
}
#calculator #results div#savings section {
  width: 50%;
}
#calculator #results div#savings section.description-wrap {
  padding-left: 5%;
  padding-top: 5px;
}
#calculator #results div#savings p.question {
  font-size: 45px;
}

#calculator #results message#submission-message {
  /* position: absolute;
  left: 5px;
  bottom: -100px;
  */
  width: 100%;
  opacity: 0;
  pointer-events: none;
  transition: 0.3s ease-in-out;
}

#calculator #results.mobile-final message#submission-message {
  pointer-events: all;
}


#calculator #results.mobile-final message#submission-message{
  opacity: 1;
}

#calculator #results.mobile-final .mobile-only-cta{
  display: none;
}

#calculator #results message#submission-message.display {
  opacity: 1;
  pointer-events: all;
}


#calculator #results p.contact-me {
  border: 2px solid #242424;
  color: #fff;
  font-weight: bold;
  border-radius: 25px;
  padding: 8px 30px;
  cursor: pointer;
  background: #242424;
  transition: background 0.3s;
  display: inline-block;
}
#calculator #results p.contact-me:hover {
  background: #fff;
  color: #242424;
}
#calculator #results p.contact-me.hide {
  display: none;
  pointer-events: none;
}
#calculator #results p.contact-me-thanks {
  color: #FD70A6;
  display: none;
  opacity: 0;
  transition: opacity 0.3s;
  margin-top: 30px; 
}
#calculator #results p.contact-me-thanks.reveal {
  opacity: 1;
  display: block;
}
/* Details form styles */
#calculator #form form {
  height: 626px;
  background: none;
  border-radius: 0;
  padding-top: 100px;
  padding-left: 60px;
  padding-right: 60px;
  position: relative;

}
#calculator #form form.hide {
  display: none;
  pointer-events: none;
}

/* #calculator #form:before {
  border-bottom: 60px solid #fff;
  border-left: 80px solid #242424;
  bottom: 0;
  content: "";
  position: absolute;
  right: 0;
  width: 0;
} */


#calculator #form form label {
  font-size: 14px;
}
#calculator #form form .legal-consent-container {
  margin-top: 30px;
  margin-bottom: 60px;
  margin-left: 2px;
}
#calculator #form form .legal-consent-container .hs-richtext p {
  color: #fff;
  line-height: 1.3em;
}
#calculator #form form .legal-consent-container .hs-richtext a {
  color: #fff;
  text-decoration: underline;
}

#calculator #form form .hs-button, 
form input[type=submit] {
  color: #242424;
  border: 2px solid #fff;
  border-radius: 25px;
  font-weight: bold;
  padding: 14px 39px 17px;
  transition: all 0.3s;
}

.windows-os #calculator #form form .hs-button, 
.windows-os form input[type=submit] {
  padding: 16px 32px 13px!important;
}

#calculator #form .submitted-message{
  display: none!important;
}

#calculator #form form .hs-button:hover, form input[type=submit]:hover {
  background: #242424;
  color: #fff;
}
#calculator #form form input[type=text],
#calculator #form form input[type=email],
#calculator #form form input[type=tel] {
  background: #242424;
  color: #fff;
  border-bottom: 1px solid #fff;
  padding-left: 5px;
  font-size: 14px;
}
#calculator #form #loading {
  display: none;
  text-align: center;
  opacity: 0;
  padding: 100px 80px;
  transition: opacity 1s;
}
#calculator #form #loading h4 {
  color: #fff;
  margin-top: 10px;
}
#calculator #form #loading.reveal {
  display: block;
  opacity: 1;
}
@keyframes colorChange {
  0% { fill: #ffffff; }
  50% { fill: #FD70A6; }
  100% { fill: #ffffff; }
}
@keyframes colourFade {
    0%, 100% {
      opacity: 1;
    }
    25%, 75% {
      opacity: 0;
    }
}
.ellipsis {
  animation: colourFade 3s infinite;
}
.ellipsis:nth-child(2) {
  animation-delay: 1s; /* Delay for the second ellipsis */
}
.ellipsis:nth-child(3) {
  animation-delay: 2s; /* Delay for the third ellipsis */
}
#motor-assist-logo path {
  animation: colorChange 3s infinite;
}
/*
@media only screen and (min-width: 701px) and (max-width: 1200px) {
  #calculator {
    min-height: 975px;
  }
  #calculator #calculations h2 {
    font-size: 46px;
  }
  .accident-rate-wrap section.use-average {
    position: absolute;
    right: 0;
    top: 192px;
    width: 112px;
  }
  #calculator #results div {
    width: 100%;
  }
  #calculator #results div#cost, #calculator #results div#total {
    background-image: none;
  }
  #calculator #results div#cost, #calculator #results div#total, #calculator #results div#savings {
    height: 250px;
  }
  #calculator #results {
    padding-top: 0;
  }
  #calculator #results div {
    padding: 30px 30px;
  }
  #calculator #results div p.question {
    font-size: 45px;
  }
  #calculator #results div#savings {
    display: block;
  }  
  #calculator #results div#savings section {
    width: 100%;
  }
  #calculator #results div#savings {
    max-height: unset;
    padding-top: 28px;
    width: 100%;
  }
  #calculator #results div#savings section.description-wrap {
    padding-left: 0;
  }
  #calculator #form form {
    padding-top: 60px;
    padding-left: 40px;
    padding-right: 40px;
  }
  #calculator #results message#submission-message {
    bottom: -170px;
  }  
}
*/
@media only screen and (max-width: 820px) {

  #calculator {
    padding-top: 60px;
    margin-top: 20px;
    overflow-x: clip;
    overflow-y: visible;  
  }  

  #calculator #calculations h2 {
    max-width: 300px;
  }
  #mobile-progress {
    display: block;
    width: 100%;
    position: absolute;
    top: 0;
    z-index: 1000;
  }
  #mobile-progress p {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 0;
    padding-bottom: 0;
  }
  #mobile-progress progress {
    width: 100%;
    height: 2px;
    background: #CACACA;
    position: relative;
  }
  #mobile-progress progress:before {
    content: " ";
    position: absolute;
    width: 50%;
    height: 2px;
    background: #FD70A6;
    display: table-cell;
  }
  #mobile-progress.step2 progress:before {
    width: 100%;
  }
  #mobile-back {
    font-size: 14px;
    text-decoration: underline;
    float: right;
    margin-top: -40px;
    display: none;
  }
  #mobile-back.show {
    display: block;
  }

  #calculator #form{
    clip-path: polygon(50% 0%, 100% 0, 100% 95%, 90% 100%, 0 100%, 0 0);
  }

  #calculator #form #loading {
    padding: 20px 40px;
    min-height: 650px;
  }
  
  #calculator #form #loading svg {
    max-width: 75%;
  }
  #calculator #form #loading h4 {
    font-size: 0.9em;
  }
  #calculator #calculations, #calculator #form, #calculator #results {
    width: 100%;
  }
  #calculator #results {
    left: 150%;
    height: 0;
    overflow: hidden;
  }  
  #calculator #results div#cost:before {
    border-left: none;
  }

  #calculator #calculations{
    transition: 0.4s ease-in-out;
  }

  #calculator #calculations.hide-calc{
    opacity: 0;
    pointer-events: none;
  }

  #calculator #calculations h2 {
    margin-bottom: 20px;
  }
  #calculator #calculations p {
    /* margin-bottom: -40px; */
  }
  #calculator #calculations {
    padding-left: 0;
    padding-right: 0%;
  }
  #calculator #calculations form label {
    font-size: 14px;
    padding-bottom: 0;
  }
  #calculator #calculations form input {
    margin-bottom: 8px;
  }
  /* #calculator #form:before {
    border-bottom: 50px solid #fff;
    border-left: 60px solid #242424;
  } */
  /* #calculateButton {
    padding: 12px 30px 14px;
    width: 100%;
    text-align: center;
  } */

  /* .accident-rate-wrap section.use-average {
    top: 148px;
    width: 105px;
  } */

  .accident-rate-wrap section.use-average p {
    font-size: 12px;
    margin-bottom: 0px;
  }

  .accident-rate-wrap section.use-average input {
    margin-top: 3px;
  }

  #calculator #form{
    top: 80px;
    min-height: 0;
  }
  #calculator #form.show {
    left: 0;
    z-index: 2000;
    height: auto;
    min-height: 600px;
  }
  #calculator #form form {
    height: auto;
    padding: 60px 28px 60px 38px;
  }
  #calculator #form form .legal-consent-container .hs-richtext p {
    font-size: 10px;
  }
  #calculator #form form .hs-button, form input[type=submit] {
    width: 100%;
    position: relative;
    z-index: 100;
    background: #fff;
  }
  #calculator #form form input[type=email], #calculator #form form input[type=tel], #calculator #form form input[type=text] {
    padding-top: 6px;
    font-size: 16px;
  }
  #calculator #form form .legal-consent-container {
    margin-bottom: 40px;
    margin-left: 2px;
    margin-top: 15px;
  }
  #calculator #results.mobile-final {
    left: 0;
    transition: left 0.4s ease-in;
    padding-top: 60px;
    background: #fff;
    height: auto;
    overflow: auto;
  }
  #calculator #results.mobile-final.recalculate {
    left: 150%;
    transition: left 0.4s ease-in;
  }
  #calculator #results.mobile-final div,
  #calculator #results div#cost {
    width: 100%;
    background-color: #fff;
    color: #242424;
    padding: 0;
  }
  #calculator #results.mobile-final div:before {
    border-left: none;
    border-bottom: 1px solid #CACACA;
  }
  #calculator #results div#cost, #calculator #results div#total {
    background-image: none;
    border-bottom: 1px solid #CACACA;
  }
  #calculator #results div#cost h4, #calculator #results div#cost p {
    color: #242424;
  }
  #calculator #results div p.question.result-text {
    font-size: 36px;
  }
  #calculator #results div#savings {
    display: block;
    max-height: unset;
    padding-top: 0;
    width: 100%;
  }
  #calculator #results div#savings section {
    width: 100%;
  }
  #calculator #results div#savings section.description-wrap {
    padding-left: 0;
  }
  #calculator #results message#submission-message.display p:first-of-type {
    display: none;
  }
  #calculator #results p.contact-me {
    padding: 12px 58px 16px;
    text-align: center;
  }
  #calculator #results div h4 span {
    background: linear-gradient(90deg, transparent, transparent), linear-gradient(90deg, #fd70a6, #fd70a6, #fd70a6);
    background-position: 100% 100%, 0 96%;
    background-repeat: no-repeat;
    background-size: 0 .14em, 100% .14em;
  }
  .slider-value {
    bottom: -16px;
  }


  #calculator #results.mobile-final .mobile-only-cta{
    display: inline-flex;
    margin-bottom: 16px;
  }





}
@media only screen and (min-width: 768px) and (max-width: 820px) {

    #calculator #results a.cta_button {
      padding: 14px 32px 16px 32px!important;
    }
    
    #calculator #calculations h2 {
      max-width: 50%;
      margin-top: 20px;
      margin-bottom: 40px;
    }
    #calculator #calculations form {
      max-width: 100%;
    }
    #calculator #form.show {
      min-height: 750px;
    }
    #calculator #form form {
        padding: 140px 66px 60px 60px;
    }
    #calculator #results {
      max-height: unset;
      height: 750px;
    }

    #calculator #results.mobile-final .solid-cta{
      width: calc(100% - 4px);
    }
    
    #calculator #results a.cta_button {
      padding: 14px 0px 16px 0px!important;
    }

    #calculator #results message{
      max-width: 50%;
    }
}

@media only screen and (max-width: 767px){
  #calculator #results a.cta_button{
    width: calc(100% - 4px);
  }
}


/* 





*/