:root {
    --main-color: white;
}

* {
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
    font-family: "Open Sans", sans-serif;
    box-sizing: border-box;
}

/* progress */

.scrollTop {
  position: fixed;
  bottom: 800px;
  Left: 40px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-size: 40px;
  background-position: center;
  background-repeat: no-repeat;
  cursor: pointer;
  z-index: 100;
  visibility: hidden;
  opacity: 0;
  transition: .5s;
  background: #070F2B;
}

.scrollTop.active {
  bottom: 40px;
  visibility: visible;
  opacity: 1;
}

.scrollTop i {
  color: #276690;
  font-size: 50px;
  margin-top: 2px;
  margin-left: 14px;
}

/* end progress */

/* header */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 8px 200px 3px 200px;
  background: #1a4059;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}
.nav,
.nav .nav-links {
  display: flex;
  align-items: left;
}
.nav {
  justify-content: space-between;
}
.nav .nav-links {
  overflow: scroll;
  position: fixed;
  top: 0;
  left: -100%;
  max-width: 280px;
  width: 100%;
  height: 100%;
  padding-top: 63px;
  flex-direction: column;
  background-color: #1d1e22;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: 0.4s;
}
.nav-links a {
  color: #fff;
  text-decoration: none;
  font-size: 1.05rem;
}
.nav-links .link-text {
  margin-left: 60px;
}
.nav li {
  border-top: .1px solid #3e3e3e;
  padding-top: 13px;
  min-height: 55px;
  list-style: none;
  background-color: #1d1e22;
  transition: .3s;
  cursor: pointer;
}
.last-item {
  border-bottom: .1px solid #3e3e3e;
}
.nav li:hover {
  background-color: #18191d;
}

/* color of calculators link */
.nav li:hover :nth-child(1) {
  color: #1a4059;
}
#selected-link {
  color: #1a4059;
}
.nav .logo {
  width: 180px;
}
.nav .nav-links a {
  transition: all 0.2s linear;
}

.nav .navOpenBtn,
.nav .navCloseBtn {
    display: block;
  }

  .nav.openNav .nav-links {
    left: 0;
  }
  .nav .navOpenBtn {
    margin-top: 7px;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
  }
  .nav .navCloseBtn {
    position: absolute;
    top: 20px;
    right: 20px;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
  }

/* responsive */
@media screen and (max-width: 1160px) {
  .nav {
    padding: 8px 100px 3px 100px;
  }
}
@media screen and (max-width: 950px) {
  .nav {
    padding: 8px 50px 3px 50px;
  }
}
@media screen and (max-width: 768px) {
  .nav {
    padding: 8px 20px 3px 20px;
  }
}

/* end header */

.text-calculator-container {
    display: flex;
    justify-content: center;
    flex-direction: row;
    margin-top: 50px;
    margin-bottom: 100px;
}

.calculator-container {
    display: flex;
    justify-content: center;
}

#calculator {
  margin-top: 80px;
    margin-left: 50px;
    padding-bottom: 30px;
    width: 500px;
    height: 367px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.pattern {
  display: flex;
  flex-direction: column;
  width: 2260px;
  height: 450px;
  background-image: url(../pattern1.png);
  background-attachment: fixed;
  margin-bottom: 50px;
  border-bottom-right-radius: 15px;
}

/* change the direction of the layout */

@media (max-width: 1052px) {
  .pattern {
    border-bottom-right-radius: 0;
    width: 100%;
  }
  .text-calculator-container {
      flex-direction: column;
      margin-bottom: 60px;
  }
  #calculator {
    margin-left: 0px;
  }
}

/* list of contents */

.list-title {
  color: #3a3939;
  font-size: 1.5rem;
  margin-bottom: 15px;
}

.list {
  padding: 0 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1600px;
  height: 450px;
}

ul {
  list-style-type: none;
}

.list li {
  padding: 7px 0;
}

.list a {
  font-size: 1.1rem;
  color: #2769ed;
  transition: 0.5s;
}

.list a:hover {
  color: #22209a;
}

@media (max-width: 1052px) {
  .list {
    width: 100%;
    padding: 0;
  }
  ul {
    width: 500px
  }
}

@media (max-width: 530px) {
  .list a {
    font-size: 0.9rem;
  }
  ul {
    padding: 0 10px;
    width: 300px
  }
}

/* end list of contents */

/* radio */

#radio {
  display: flex;
  justify-content: center;
  margin-bottom: 30px;
  flex-direction: column;
  width: 500px;
}

input[type=radio] {
  --s: 1.1rem;     /* control the size */
  --c: #1B1A55; /* the active color */
  
  height: var(--s);
  aspect-ratio: 1;
  border: calc(var(--s)/8) solid #939393;
  padding: calc(var(--s)/8);
  background: 
     radial-gradient(farthest-side,var(--c) 94%,#0000) 
     50%/0 0 no-repeat content-box;
  border-radius: 50%;
  outline-offset: calc(var(--s)/10);
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  cursor: pointer;
  transition: .3s;
}

input[type=radio]:hover {
  border-color: #2f2dc4;
}

input[type=radio]:checked {
  border-color: var(--c);
  background-size: 100% 100%;
}

input[type=radio]:disabled {
  background: 
     linear-gradient(#939393 0 0) 
     50%/100% 20% no-repeat content-box;
  opacity: .5;
  cursor: not-allowed;
}

@media print {
  input[type=radio] {
    -webkit-appearance: auto;
    -moz-appearance: auto;
    appearance: auto;
    background: none;
  }
}

.single-radio {
  display: flex;
  justify-content: center;
}
.double-radios {
  display: flex;
  flex-direction: row;
  justify-content: center;
}

#radio label {
  display:inline-flex;
  align-items:center;
  gap:10px;
  margin-right:10px;
  cursor: pointer;
  font-size: 1.1rem;
  margin-bottom: 5px;
  color: #262626;
}

/* end radio */


.numbers-input {
    width: 250px;
    margin-right: 20px;
    box-sizing: border-box;
    font-size: 1.1rem;
    margin-left: 30px;
    vertical-align: baseline;
    line-height: 1.29;
    letter-spacing: .16px;
    border-radius: 0;
    outline: 2px solid transparent;
    outline-offset: -2px;
    height: 40px;
    border: none;
    border-bottom: 1px solid #8d8d8d;
    border-left: 2px solid #111;
    background-color: #f4f4f4;
    padding: 0 16px;
    color: #161616;
    transition: background-color 70ms cubic-bezier(.2,0,.38,.9),outline 70ms cubic-bezier(.2,0,.38,.9);  
    :focus{
        outline: 2px solid #0f62fe;
        outline-offset: -2px;
    }
}

.first-input {
    border-top: 1px solid #8d8d8d;
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
}

.last-input {
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
}

#result {
    text-align: center;
    font-size: 1.1rem;
    color: #262626;
}

.buttons {
    display: flex;
    justify-content: center;
    margin: 20px 0;
}

.result-buttons {
  --border: 2.1px;    /* the border width */
  --slant:0px;   /* control the slanted corners */
  --color: #1B1A55; /* the color */
  
  margin: 0 5px;
  border-radius: 20px;
  font-size: 18px;
    padding: 0.4em 0.9em;
    border: none;
    cursor: pointer;
    color: var(--color);
    background: 
       linear-gradient(to bottom left,var(--color)  50%,#0000 50.1%) top right,
       linear-gradient(to top   right,var(--color)  50%,#0000 50.1%) bottom left;
    background-size: calc(var(--slant) + 1.3*var(--border)) calc(var(--slant) + 1.3*var(--border));
    background-repeat: no-repeat;
    box-shadow:
      0 0 0 200px inset var(--s,#0000),
      0 0 0 var(--border) inset var(--color);
    clip-path: 
        polygon(0 0, calc(100% - var(--slant)) 0, 100% var(--slant),
                100% 100%, var(--slant) 100%,0 calc(100% - var(--slant))
               );
    transition: color var(--t,0.3s), background-size 0.3s;
  }
  button:focus-visible {
    outline-offset: calc(-1*var(--border));
    outline: var(--border) solid #000c;
    clip-path: none;
    background-size: 0 0;
  }
  button:hover,
  button:active{
    background-size: 100% 100%;
    color: #fff;
    --t: 0.2s 0.1s;
  }
button:active {
    --s: #0005;
    transition: none;
}

.inputs label {
  color: #262626;
  font-size: 1.1rem;
}

/* .text */
.text {
  margin: 50px 50px 100px;
}

@media (max-width: 600px) {
.text {
  margin-left: 30px;
margin-right: 30px;
}
}

.text h3 {
  color: #3a3939;
  margin: 12px 0;
  font-size: 1.5rem;
}

.text h4 {
  color: #3a3939;
  font-size: 1.3rem;
  margin: 12px 0;
}

.text p {
  font-size: 1.1rem;
  line-height: 30px;
  color: #4d4f4f;
}

/* video */

.video-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  background-image: url(../pattern1.jpg);
  background-attachment: fixed;
  padding: 70px 0;
  margin-bottom: 150px;
}

.video-container .title {
  display: flex;
  justify-content: left;
}

.video-container .title h1 {
  margin-bottom: 50px;
  font-size: 2rem;
  color: #262626;
}

iframe {
  border-radius: 10px;
}

@media (max-width:700px) {
  .video-container {
    padding: 60px 0;
    margin-bottom: 170px;
  }

  iframe {
    width: 400px;
    height: 225px;
  }
}

@media (max-width:520px) {
  .video-container {
    padding: 50px 0;
  }

  iframe {
    width: 285.714px;
    height: 182.142px;
  }
}

/* end video */

/* calculators cards */

#other-calculators .title {
  display: flex;
  justify-content: left;
}

#other-calculators .title h1 {
  margin-bottom: 50px;
  margin-left: 80px;
  font-size: 2rem;
  color: #262626;
}

#other-calculators {
  padding: 80px 0;
  background-color: #1a4059;
}

#other-calculators a {
  text-decoration: none;
}

#other-calculators .wrapper {
  display: flex;
  justify-content: center;
  flex-direction: row;
  align-items: center;
}

#other-calculators .double-calculators {
  display: flex;
  flex-direction: row;
}

#other-calculators .single-calculator {
  border-radius: 8px;
  margin: 0 10px;
  position: relative;
  width: 290px;
  height: 320px;
  background: #fff;
  padding: 20px 35px 0 35px;
  transition: .5s;
  overflow: hidden;
  margin-bottom: 30px;
  text-align: left;
  box-shadow: rgba(0, 0, 0, 0.35) 0px 5px 15px;
}

#other-calculators .single-calculator p {
  color: #4d4f4f;
  font-size: 1rem;
  line-height: 28px;
}

#other-calculators .single-calculator h3 {
  font-size: 1.56rem;
  margin: 20px 0;
  letter-spacing: 1px;
  color: #3a3939;
}

#other-calculators .single-calculator span {
  position: absolute;
  top: 0;
  left: -120%;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  transition: .7s;
  transform: skewX(10deg);
}

#other-calculators .single-calculator:hover span {
  left: 120%;
}

@media (max-width:1240px) {
  #other-calculators .wrapper {
      flex-direction: column;
    }
    
    #other-calculators .single-calculator {
      width: 330px;
      height: 300px;
    }

    #other-calculators .single-calculator h3 {
      margin: 23px 0;
    }
}

@media (max-width:700px) {
  #other-calculators .double-calculators {
      flex-direction: column;
    }
    
    #other-calculators .single-calculator {
      padding-top: 20px;
      width: 340px;
      height: 200px;
      padding: 0 25px;
    }

    #other-calculators .single-calculator h3 {
      margin: 20px 0 15px 0;
    }

    #other-calculators .title h1 {
      margin-left: 50px;
    }

    #other-calculators .single-calculator p {
      line-height: 25px;
    }
}

/* end calculators cards */  

@media (max-width:600px) {
  #radio .double-radios {
    flex-direction: column;
    align-items: center;
  }
  .numbers-input {
    width: 200px;
    height: 35px;
    margin-right: 15px;
    font-size: 1rem;
  }
  #radio label {
    font-size: 1rem;
  }
  .inputs label {
    font-size: 1rem;
  }
  #result {
    font-size: 1rem;
  }
  p {
    font-size: 1rem;
  }
  h3 {
    font-size: 1.3rem;
  }
  h4 {
    font-size: 1.2rem;
  }
  #other-calculators .title h1 {
    font-size: 1.7rem;
  }
}


/* footer */

footer {
  padding: 70px 0;
  position: relative;
  width: 100%;
  height: auto;
  background: #111;
  display: flex;
  flex-direction: column;
  align-items: center;
}

footer .logo {
  width: 230px;
  margin-bottom: 60px;
}

.copyrightText {
    width: 100%;
    background: #181818;
    color: #999;
    text-align: center;
    padding: 10px 0;
}


.footer-link {
    display: flex;
    align-items: center;
}

.footer-link a {
    font-size: 27px;
    background-image: linear-gradient(to right, #2b95db, #2b95db 50%, #26638b 50%);
    background-size: 200% 100%;
    background-position: -100%;
    display: inline-block;
    padding: 5px 0;
    position: relative;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: all 0.3s ease-in-out;
}

.footer-link a:before {
    content: "";
    background: #2b95db;
    display: block;
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 0;
    height: 3px;
    transition: all 0.3s ease-in-out;
}

.footer-link a:hover {
    background-position: 0;
}

.footer-link a:hover::before {
    width: 100%;
}

.footer-aboutus {
    width: 400px;
    margin: 0 90px;
}

footer h2 {
    margin-bottom: 30px;
}

footer h1, h2{
    color: white;
}

footer p {
    color: #999;
}

.fa-envelope {
    color: white;
    margin-right: 5px;
    margin-top: 5px;
}

.gmail {
    display: flex;
    align-items: center;
    flex-direction: row;
}

.gmail a {
    text-decoration: none;
    color: #999;
    transition: .3s;
}

.gmail a:hover {
    color: white;
}

.footer-container {
    display: flex;
    justify-content: center;
}

@media (max-width: 1170px) {
    footer .footer-container {
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }
    .footer-aboutus {
        margin: 50px 0;
        width: 80%;
        text-align: center;
    }
    .footer-contactus {
        text-align: center;
    }
}

@media (max-width: 500px) {
  #calculator {
    width: 100%;
  }
  #radio {
    width: 100%;
  }
}

@media (max-width: 430px) {
  .numbers-input {
    width: 180px;
  }
  #radio label {
    font-size: 0.93rem;
  }
  .inputs label {
    font-size: 0.93rem;
  }
  .result-buttons {
    --border: 2px;
    font-size: 17.2px;
  }
  #other-calculators .title h1 {
    font-size: 1.6rem;
    margin-left: 30px;
  }
  #other-calculators .single-calculator {
    width: 300px;
    height: 235px;
    padding: 0 25px;
}
.nav .logo {
  width: 160px;
}
.nav .navOpenBtn {
  margin-top: 5px;
}
}

@media (max-width: 400px) {
  .numbers-input {
    width: 160px;
  }
  #radio label {
    font-size: 0.9rem;
  }
  .inputs label {
    font-size: 0.9rem;
  }
}

@media (max-width: 375px) {
  .numbers-input {
    width: 140px;
  }
  .inputs label {
    font-size: 0.85rem;
  }
  #other-calculators .title h1 {
    margin-left: 15px;
  }
}
@media (max-width: 340px) {
  .numbers-input {
    margin-left: 15px;
  }
}

@media (max-width: 400px) {
  .footer-link a {
    font-size: 23px;
  }
  footer .logo {
    width: 210px;
    margin-bottom: 50px;
  }
}

/* end footer */
