body{
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    background: linear-gradient(
        to bottom right, 
        rgb(245, 245, 245) 0%,
        whitesmoke 40%,  
        rgb(216, 217, 227) 75%,  
        rgb(117, 121, 145) 100%  
    );
    font-family: sans-serif;
}
  
#main.inactive {
overflow: hidden;
}

#subBody{
    box-sizing: border-box;
    margin: 30px auto;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
}


#leftside{
    display: flex;
    flex-direction:column;
    align-items: center;
    max-width: 680px;
    padding: 10px 20px;
    float: left;
    margin: 10px 15px;
    box-shadow: 0px 0px 8px rgb(33, 37, 74);
    border-radius: 15px;
    background-color: whitesmoke;

}

@media(min-width: 1290px){
    #leftside{
     max-width: 350px;
     }
 }

#topRow{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.topRowSub{
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 310px;
    margin: 0px 10px 10px 10px;
}

#calculateBox{
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 310px;
    margin: 5px 10px 10px 10px;
    /* position: sticky; */
    top: 15px;
    background-color: rgb(242, 242, 244);
    z-index: 2;
    box-shadow: 0px 0px 8px rgb(172, 171, 171);
    border-radius: 20px;
    padding: 0 5px;
    max-height: 450px;
}


#topRowSubB{
    justify-content: center;
}

#extraPmtWrapper{
    margin-bottom: 0;
}

#dpFiguresCont>*{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

#IRLoanLengthCont{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
}

.IRLoanLengthWrappers{
    display: block;
    margin: 0px 5px;
}

.dollarInput{
    align-items: center;
    text-align: center;
    font-size: 1.2rem;
    max-width: 200px;
    min-height: 25px;
    border-radius: 10px;
    padding: 1px;
    border: 1px solid black;
}

#dp{
    border-radius: 10px 0 0 10px;
    border-right: 2px solid black;
}

#ir, #dpercent{
    max-width: 100px;
    text-align: center;
    padding-right: 10px;
    font-size: 1.2rem;
    min-height: 25px;
    padding: 1px;
    border: 1px solid black;
}

#ir{
    border-radius: 10px;
}

#dpercent{
    border-radius: 0 10px 10px 0;
}

#loanAmtCont{
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    border-radius: 10px;
    background-color: rgb(232, 232, 232);
}

#loanDolla{
    font-size: 1.4rem;
    font-weight: bold;
    padding-right: 5px;
}

#loan{
    font-size: 1.3rem;
    align-items: center;
    text-align: center;
    min-height: 25px;
    padding: 2px 0;
}

#loan::before{
    display: var(--check-secondary);
}

.label{
   position: relative;
   font-size: 1.2rem;
   padding-top: 12px;
}

.extraCostLabel{
    position: relative;
    font-size: 1.2rem;
    padding-top: 8px;
 }

.dollars{
    position: relative;
    justify-content: center;
    align-items: center;
}

.dollars::before {
    content: "$";
    font-size: 1.25rem;
    font-weight: bold;
    color: black;
    left: 5px;
    top: 3px;
    position: absolute;
    display: inline-block;
    align-items: center;
    justify-content: center;
    margin-top: auto;
    margin-bottom: auto;
}

#loan::before{
    top:0px;
}

.percent {
    position: relative;
}

.dpercent {
    position: relative;
}

.percent::before {
    content: "%";
    font-size: 1.15rem;
    font-weight: bold;
    color: black;
    right: 7px;
    top: 2px;
    position: absolute;
    display: inline-block;
    align-items: center;
    justify-content: center;
    margin-top: auto;
    margin-bottom: auto;
}

.dpercent::before {
    content: "%";
    font-size: 1.3rem;
    font-weight: bold;
    color: black;
    right: 5px;
    top: 2px;
    position: absolute;
    display: inline-block;
    align-items: center;
    justify-content: center;
    margin-top: auto;
    margin-bottom: auto;
}

.optionClicker{
    content: '';
    float: right;
    position: relative;
    height: 8px;
    width: 8px;
    background-color: whitesmoke;
    border-left: 3px solid rgb(3, 3, 73);
    border-bottom: 3px solid rgb(3, 3, 73);
    transform: rotate(-45deg);
    right: -8px;
    top: 4px;
    transition: transform 1s;
}

.optionTitle{
    font-size: 18px;
    font-weight: bold;
    text-align: right;
    margin-right: 15px;
    position: relative;
}

.extraWrapper{
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    box-shadow: 0px 0px 8px rgb(172, 171, 171);
    border-radius: 20px;
    padding: 10px 5px;
    margin: 5px 0 7px 0;
    background-color: rgb(242, 242, 244);
}

#extraCostTitleCont, #extraPmtTitleCont{
    width: 100%;
    cursor: pointer;
    display: flex;
    justify-content: center;
    pointer-events: auto;
}

#extraCostCont{
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

#extraCostCont.inactive{
    height: 0;
    opacity: 0;
    animation: 1s linear closeCost;
}

#extraCostCont.active  {
    height: 320px;
    opacity: 1;
    animation: 1.3s linear openCost;
}

@keyframes openCost {
    0% {
      height: 0;
      opacity: 0;
    }
    50% {
      height: 320px;
      opacity: 0;
    }
    100% {
        height: 320px;
        opacity: 1;
    }
  }

@keyframes closeCost {
    0% {
        opacity: .7;
        height: 320px;
    }
    20%{
        height: 320px
    }
    40% {
        opacity: 0;
    }
    100% {
        height: 0px;
    }
  }

#extraPmtCont.active  {
    height: 450px;
    opacity: 1;
    animation: 1.3s linear open;
}

#extraPmtCont.inactive{
    height: 0;
    opacity: 0;
    animation: 1s linear close;
}

@keyframes open {
    0% {
      height: 0;
      opacity: 0;
    }
    50% {
      height: 450px;
      opacity: 0;
    }
    100% {
        height: 450px;
        opacity: 1;
    }
  }

@keyframes close {
    0% {
        opacity: .7;
        height: 450px;
    }
    20%{
        height: 450px
    }
    40% {
        opacity: 0;
    }
    100% {
        height: 0px;
    }
  }

.extraPmtTitle{
    font-size: 18px;
    font-weight: bold;
    margin-top: 5px;
}

.extraPmtInput{
    display: flex;
    flex-direction: column;
    align-items: end;
    margin: 0 0 5px auto; 
    width: 200px;
}

.datewrap, .amountWrap{
    display: flex;
    flex-wrap: wrap;
    margin: 5px 0;
}

.datewrap{
    margin: 0;
}

.extraPmtSeperator{
    border-top: 2.5px solid rgb(112, 128, 144);
    margin: 10px 0;
}

.start-endDate, .amount {
    width: 80px;
    text-align: right;
    margin: auto 0px;
    padding-right: 5px;
}

#loanHeader, #monthHeader,.EPmonthHeader, #yearHeader, .EPyearHeader{
    height: 25px;
    width:120px;
    position: relative;
    border: 1px solid black;
}

#loanHeader{
    border-radius: 10px;
}

#monthHeader, .EPmonthHeader{
    border-radius: 10px 0 0 10px;
}

#yearHeader, .EPyearHeader{
    border-radius: 0 10px 10px 0;;
}

#yearHeader, .EPyearHeader{
    height: 25px;
    width: 80px;
    position: relative;
    border: 1px solid black;
}

.dropdownHeader:hover{
    cursor: pointer;
}

#monthHeaderText,.EPmonthHeaderText, #loanHeaderText, #yearHeaderText, .EPyearHeaderText{
    position: absolute;
    font-size: 1.1rem;
    top: 3px;
    text-align: center;
    width: 80%;
}

.clicker{
    content: '';
    position: absolute;
    height: 8px;
    width: 8px;
    background-color: whitesmoke;
    border-left: 3px solid rgb(3, 3, 73);
    border-bottom: 3px solid rgb(3, 3, 73);
    right: 10px;
    top: 7px;
    transform: rotate(-45deg);
    transition: transform 1s;
}

#monthOptsContainer,.EPmonthOptsContainer{
    width:158px;
    height: 0px;
    background-color: whitesmoke;
    position: absolute;
    margin-left: auto;
    margin-right: auto;
    transition: height .8s linear;
    z-index: 1;
    transform: translateX(-36px);
}

#loanOptsContainer{
    width:158px;
    height: 0px;
    background-color: whitesmoke;
    position: absolute;
    margin-left: auto;
    margin-right: auto;
    transition: height .6s linear;
    z-index: 1;
    text-align: left;
    transform: translateX(-40px);
}

#monthOptsContainer > *,.EPmonthOptsContainer > *,#loanOptsContainer > *{
    padding: 4px 2px;
    color: black;
    float: left;
    position: relative;
}

#monthOptsContainer > *:hover,.EPmonthOptsContainer > *:hover,#loanOptsContainer > *:hover {
    color: white!important;
    background-color: #26708f;
    cursor: pointer;
}

.monthOption, .lloption{
    font-size: .9rem;
    min-width: 75px;
    display: none;
    transition: opacity 1s;
}

#yearOptsContainer, .EPyearOptsContainer{
    width:160px;
    height: 0px;
    background-color: whitesmoke;
    position: absolute;
    margin-left: auto;
    margin-right: auto;
    transition: height .6s linear;
    overflow-x: hidden;
    overflow-y: auto;
    z-index: 1;
    transform: translateX(-80px);
}

#yearOptsContainer > *, .EPyearOptsContainer > *{
    padding: 5px 5px;
    float: left;
    position: relative;
    font-size: 1rem;
    display: none;
    transition: opacity .6s;
}

#yearOptsContainer > *:hover, .EPyearOptsContainer > *:hover{
    color: white!important;
    background-color: #26708f;
    cursor: pointer;
}

#yearOptsContainer::-webkit-scrollbar, .EPyearOptsContainer::-webkit-scrollbar {
    width: 1em;
  }
   
  #yearOptsContainer::-webkit-scrollbar-track, .EPyearOptsContainer::-webkit-scrollbar-track {
    box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
  }
   
  #yearOptsContainer::-webkit-scrollbar-thumb, .EPyearOptsContainer::-webkit-scrollbar-thumb {
    background-color: darkgrey;
    outline: 1px solid slategrey;
    border-radius: 10px;
  }

#CalcClearBox{
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
}

#button{
    margin: 10px 5px 10px 0;
    padding: 5.5px;
    font-size: 20px;
    min-width: 120px;
    background-color: rgb(17, 138, 47);
    color: white;
    cursor: pointer;
    border-radius: 20px;
    border: 3px solid rgb(119, 218, 149);
    font-weight: bold;
    text-align: center;
}

#button:hover{
    background-color: rgb(119, 218, 149);
    border: 3px solid rgb(17, 138, 47);
    color: black;
    text-decoration: underline;
}


#clear{
    margin: 10px 0 10px 5px;
    padding: 5.5px;
    font-size: 20px;
    min-width: 120px;
    background-color: rgb(53, 53, 75);
    color: white;
    cursor: pointer;
    border-radius: 20px;
    border: 3px solid rgb(27, 165, 230);
    font-weight: bold;
    text-align: center;
}

#clear:hover{
    background-color: rgb(27, 165, 230);
    border: 3px solid rgb(53, 53, 75);
    color: black;
    text-decoration: underline;
}

#outputContainer{
    display: -moz-box;
    display: -ms-flexbox;
    display: -webkit-flex;
    display: flex;
    flex-direction: column;
    position: relative;
    min-width: 350px;
    max-width: 840px;
    padding: 10px;
    margin: 10px 15px;
    box-sizing: border-box;
    box-shadow: 0px 0px 8px rgb(13, 8, 70);
    border-radius: 15px;
    overflow: auto;
    background-color: whitesmoke;
}

/* @media(max-width: 840px){
    #outputcontainer{
     max-width: 100%;
     }
 } */

#summaryCont{
    display: -webkit-box;
    display: -moz-box;
    display: -ms-flexbox;
    display: -webkit-flex;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 350px;
    max-width: 840px;
    margin: 0;
    box-sizing: border-box;
    margin-bottom: 10px;
}

#summaryContTitle{
    font-size: 28px;
    font-weight:500;
    margin-bottom: 5px;
}

#titleDivider{
    height: 2px;
    width: 100%;
    margin: 3px 0 6px 0;
    background-color: rgb(34, 46, 117);
}

#summarySubCont{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.summarySubTitle{
    font-size: 1.1rem;
}

.subTitleDivider{
    height: 1px;
    width: 100%;
    margin: 2px 0px 0px;
    background-color: darkgray;
}

.summarySubFigure{
    font-size: 1.29rem;
    font-weight: bold;
    margin-top: 5px;
    display: flex;
    height: 50px;
    align-items: center;
    justify-content: center;
    position: relative;
}

.summarySubFigure.active::after{
    content: "";
    width: 0;
    height: 50px;
    position: absolute;
    top: 0;
    left: 0;
    animation: updateFigs .7s linear;
}

@keyframes updateFigs {
    0% {
      width: 0;
      background-color: whitesmoke;
    }
    50% {
      width:100%;
      background-color: rgb(191, 194, 196);
    }
    100% {
       width: 0%;
       background-color: white;
    }
  }

.summarySubContSub{
    display: flex;
}

.summarySubSubCont{
    position: relative;
    width: 155px;
    min-height: 55px;
    text-align: center;
    box-shadow: 0px 0px 8px lightgray;
    border-radius: 10px;
    margin: 5px;
    padding: 5px;
}

.summarySwish{
    position: absolute;
    overflow: hidden;
    width: 0;
    background-color: red;
    transition: width 5s linear;
}

.summarySwish.active{
    width: 100%;
}


#tabHeaderCont{
    display: block; 
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 10px;
}

#tabheader{
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    margin: 0;
    max-height: 40px;
}

.tabHeaderLines{
    height: 5px;
    width: 120px;
    background-color: rgb(17, 17, 139);
    margin: 6px 0 0 0;
    transition: transform .5s;
}

.tabs{
    padding: 5px;
    margin: 5px;
    width: 110px;
    text-align: center;
    font-size: 1.4rem;
    box-shadow: 0 0 5px rgb(21, 21, 97);
    border-radius: 10px;
    border: 1px solid rgb(17, 17, 139);
}

#tabCharts, #tabValue, #tabCost, #tabSchedule{
    color: black;
}

.tabs:hover{
    cursor: pointer;
    transform: scale(1.05);
}

.subTabs:hover{
    cursor: pointer;
    font-weight: bolder;
}

#tabSubHeaderCont {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    width:210px;
    height: 0px;
    margin-left: auto;
    margin-right: auto;
 
    /* padding: 5px; */
    transition: height .5s linear;
    z-index: 1;
    overflow: hidden;
}

#tabSubHeader{
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
}

.subTabs{
    display: flex;
    justify-content: center;
    padding: 5px;
    width: 90px;
    font-size: 1.4rem;
    height: 40px;
    align-items: center;
    text-align: center;
      /* box-shadow: 0 0 5px rgb(21, 21, 97);
    border-radius: 10px;
    border: 1px solid rgb(17, 17, 139); */
}

.subTabHeaderLines{
    height: 2px;
    width: 106px;
    background-color: rgb(17, 17, 139);
    margin-top: 0;
    transition: transform .5s;
}

#subTabDivider{
    width: 2px;
    background-color: rgb(17, 17, 139);
}

#canvascontainer,#canvascontainer2{
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    margin: 10px 0 0 0;
    min-height: 450px;
    max-height: 100vh;
}

#mortgageCanvasCont{
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 350px;
    margin: 10px 0 0 0;
}

.charts{
    display: flex;
    margin: 0;
}

#mortgageChart{
    max-width: 95%;
}

#tableContainer{
    position: relative;
    margin-top: 15px;
}

#topTableOverlay{
    position: absolute;
    top: -20px;
    left: 0;
    height: 20px;
    width: 100%;
    text-align: center;
    background-color: whitesmoke;
    color: whitesmoke;
    z-index: 5;
}

table{
    position: relative;
    margin: 0 auto 5px auto;
    border-collapse: collapse;
    display: inline-flex;
    flex-direction: column;
    align-items: center;  
    max-width: 100%;
}

tbody{
    width: 100%;
    text-align: center;
    align-items: center;
    position: relative;
    display: block;
    height: 700px;
    max-height: 70vh;
    overflow: auto;
    margin: 0 auto;
}

#headerRow{
    height: 95px;
}

th{
    position: sticky;
    top: 0;
    padding: 2px 8px 40px 8px;
    width: 16.7%;
    font-size: 1.2rem;
    background-color: rgb(3, 3, 73);
    color: white;
    z-index: 2;
    border-right: 3px inset rgb(149, 146, 146);
    border-left: 3px inset rgb(149, 146, 146);
    box-shadow:
        inset 0 -3px 0 rgb(149, 146, 146),   /* bottom */
        inset 0 3px 0 rgb(149, 146, 146);    /* top */
}

#headerRow th:first-child{
    z-index: 3;
}

#allButtons{
    position: absolute;
    left: 0;
    bottom:0; 
    background-color: rgb(3, 3, 73);
    padding: 2px 0px;
    border-top: 2px solid whitesmoke;
    border-bottom: 2px solid whitesmoke;
    height: 38px;
    min-height: 38px;
}

#firstHeaderHalf{
    position: absolute;
    right: 0;
    bottom:0;
    background-color: rgb(3, 3, 73);
    padding: 2px 0px;
    border-top: 2px solid whitesmoke;
    border-bottom: 2px solid whitesmoke;
    height: 38px;
    min-height: 38px;
}

#allButtons button{
    margin: 3px 0 3px 10px;
    float: left;
    padding: 2px 10px;
    border-radius: 5px;
    font-size: 15px;
    font-weight: bold;
    border-radius: 20px;
    color: whitesmoke;
}

#expandAll{
    background-color: rgb(17, 138, 47);
    border: 1px solid rgb(119, 218, 149);
}

#collapseAll{
    background-color: rgb(53, 53, 75);
    border: 1px solid rgb(27, 165, 230);
}

#allButtons button:active{
    scale: .9;
}

.scheduleRows:nth-child(even){
    background-color: rgb(230, 225, 225);
}

tr{
    width: 100%;
    align-items: center;
}

tr td:nth-child(1){
    text-align: right;
    padding-right: 5px;
    border-left: 1px inset rgb(149, 146, 146);
    border-right: 1px inset rgb(149, 146, 146);
}

table th:nth-child(1) {
    text-align: end;
}

td{
    padding-top: 5px;
    padding-bottom: 5px;
    font-size: 1.2rem;
}

button:hover{
    cursor: pointer;
}

.groupHeader td{
    text-align: center;
    font-size: 20px;
    background-color: rgb(238, 238, 238);
}

.groupHeader td:nth-child(1){
    position: relative;
    display: flex;
    min-width: 100px;
    justify-content: end;
}

.toggleButton {
    position: absolute;
    top: 12px;
    left: 15px;
    border-radius: 20%;
    height: 12px;
    width: 12px;
    padding: 7px;
    border-bottom: 3px solid rgb(3,3,73);
    border-right: 3px solid rgb(3,3,73);
    transform: rotateX(90deg);
    transition: all .5s ease;
}

.toggleButton:hover{
    cursor: pointer;
}
    
#rowz:hover>th,#rowz:hover>td{
    background-color: black;
    color: white;
}

#scheduleDisclaimer{
    display: none;
    font-size: 14px; 
    font-style: italic;
    color: #333; 
    margin-top: 0;
}

#scheduleDisclaimer.active{
    display: block;
}