/* ================= BASE ================= */

.pageWrapper {
    background-color: #fcfcfc;
    min-height: 100vh;
    padding: 0px;
    font-family: 'Poppins', sans-serif;
}

.mainContainer {
    max-width: 1200px;
    margin: 0 auto;
}

.card {
    background: #fff;
    /* border: 1px solid #bdbdbd; */


}

.card_upper {
    padding: 10px;
    border: 1px solid #bdbdbd;
    border-radius: 12px;
    margin-bottom: 10px;
}

.sectionTitle {
    text-align: center;
    font-size: 25px;
    font-weight: 600;
    margin-bottom: 15px;
}

/* ================= ASKING PRICE ================= */

.askingPriceBox {
    border: 1px solid #bdbdbd;
    border-radius: 8px;
    padding: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 10px;
    background: #f5f5f5;
    flex-wrap: wrap;
}

.askingPriceInput {
    width: 400px;
    border: 1px solid #bdbdbd;
    border-radius: 8px;
}

/* Border around the start adornment (C$) */
.askingPriceInput .MuiInputAdornment-root {
    border: 1px solid #bdbdbd;
    border-radius: 8px;
    padding: 0 10px;
    background: #f5f5f5;
    height: 100%;
    display: flex;
    align-items: center;
}

/* Match input height & radius */
.askingPriceInput .MuiOutlinedInput-root {
    border-radius: 8px;
    padding-left: 8px;
}

/* Remove double border between adornment & input */
.askingPriceInput .MuiOutlinedInput-root .MuiOutlinedInput-notchedOutline {
    border-left: none;
}

.askingPriceLabel {
    display: flex;
    align-items: center;
    gap: 10px;
}

.inputLabelBold {
    font-weight: 500 !important;
}

.fixedAdornment {
    min-width: 28px;
    /* SAME for %, C$, empty */
    display: inline-flex;
    justify-content: flex-start;
    font-weight: 500;
}

/* Make input a flex container */
.centerInput .MuiInputBase-root {
    display: flex;
    align-items: center;
}

/* Symbol (C$, %) keeps its natural position */
.centerInput .MuiInputAdornment-root {
    margin-right: 6px;
}

/* VALUE COLUMN — THIS controls alignment */
.centerInput input,
.centerInput .MuiSelect-select {
    text-align: left !important;
    padding-left: 0 !important;

    /* 👇 THIS creates the SAME START LINE */
    margin-left: 40px;

    /* Makes numbers visually stable */
    font-variant-numeric: tabular-nums;
}

.centerInput_noAdornment input,
.centerInput_noAdornment .MuiSelect-select {
    margin-left: 90px;
}

.frequencySelect .MuiSelect-select {
    margin-left: 0 !important;
    padding-left: 14px !important;
    /* Standard MUI padding */
}

.cell.bold {
    display: flex;
    justify-content: flex-start;
    /* keeps it visually centered */
    align-items: center;
    gap: 30px;
}


/* ================= TABLE ================= */

.table {
    border: 1px solid #bdbdbd;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

/* EACH ROW */
.tableRow {
    display: flex;
    /* min-height: 56px; */

}

.tableRow:first-child {
    border-top: none;
    padding-top: 10px;
}

.tableFooter {
    background-color: #f5f5f5;

}

/* Footer rows */
.footerRowTop,
.footerRowBottom {
    min-height: 56px;
}

/* Center values between the two rows */
.footerValueCell {
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateY(28px);
    /* half row height */
    font-weight: 500;
}

.tableFooter .labelCell {
    background: #f5f5f5;
}

/* Empty cells keep column structure */
.footerEmptyCell {
    background: transparent;
}

.footerRowBottom {
    border-top: none;

}

.totalRow {
    background: #fff;
}

/* Inner grey band */
.totalInner {
    display: flex;
    width: 100%;
    background: #f5f5f5;
    border-radius: 10px;
    margin: 10px;
    margin: 5px 10px;
    overflow: hidden;
    border: 1px solid #bdbdbd;
}

.footerRowInner {
    margin-bottom: 10px;
}

/* Ensure inner cells inherit background */
.totalInner .labelCell,
.totalInner .cell {
    background: #f5f5f5;
}

/* HEADER ROW */
.headerRow {
    background: #fff;
    font-weight: 600;
}

/* LABEL COLUMN */
.labelCell {
    width: 260px;
    color: #454545;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    font-size: 16px;
    background: #fff;

}

.labelCellTotal {
    padding-left: 10px;
}

.label_mortgagePayment {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 260px;

    padding-left: 5px;
}

.footerInnerStack {
    display: flex;
    align-items: center;
    width: 100%;
}

/* Left labels stack vertically */
.footerLeft {
    display: flex;
    flex-direction: column;
}

/* Each label row height */
.footerLabelRow {
    height: 56px;
    display: flex;
    align-items: center;
}

/* Values column */
.footerValues {
    display: flex;
    flex: 1;
}

/* THIS centers values between the two rows */
.footerValueCentered {
    flex: 1;
    display: flex;
    align-items: center;
    /* vertical center between rows */
    justify-content: center;
    font-weight: 600;
}




/* SCENARIO CELLS */
.cell {
    flex: 1;
    padding: 5px 10px;
    display: flex;
    align-items: center;
}



/* HEADER SCENARIO TEXT */
.headerCell {
    justify-content: center;
    font-size: 14px;
    color: #454545;
}

/* TOTAL ROW */
.totalRow {
    background: #fff;
}

/* HELPERS */
.bold {
    font-weight: 600;
}

.center {
    justify-content: center;
}

/* ICON */
.icon {
    font-size: 18px !important;
    color: #9e9e9e;
    margin-right: 8px;
}

/* GREY INPUT */
.greyBg .MuiOutlinedInput-root {
    background-color: #f5f5f5;
}

/* ================= FOOTER TABLE ================= */

.table+.table {
    margin-top: 24px;
}

/* Frequency dropdown – same as Amortization */
.frequencySelect {
    height: 36px;
    min-width: 140px;
    font-size: 14px;
    font-weight: 400;
    border: 1px solid #bdbdbd;
    /* NOT bold */
}

.frequencySelect .MuiOutlinedInput-root {
    height: 36px;
    border-radius: 6px;
}

.frequencySelect .MuiOutlinedInput-notchedOutline {
    border-color: #bdbdbd;
}

.frequencySelect .MuiSelect-select {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 32px;
    /* space for dropdown arrow */
}

/* Hover */
.frequencySelect:hover .MuiOutlinedInput-notchedOutline {
    border-color: #9e9e9e;
}



/* ================= LTT ================= */

.lttLayout {
    display: flex;
    gap: 32px;
    margin-top: 20px;
    align-items: flex-start;
}



.lttRow {
    flex: 1 1 200px;
    /* Grow, shrink, and base width of 200px */
    min-width: 150px;
    /* Prevents it from getting too narrow */
    max-width: 300px;
    /* Keeps it from getting too wide on desktop */
}

.lttTotalRow {
    flex: 1 1 100%;
    /* Take full width on mobile if needed */
    max-width: 400px;

}



.lttRight {
    flex: 1;
    background: #f5f5f5;
    border: 1px solid #bdbdbd;
    border-radius: 8px;
    padding: 16px;
}

.lttDivider {
    width: 1px;
    background: #bdbdbd;
}

/* TOTAL ROW WRAPPER */


.lttTotalBox {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: #f5f5f5;
    border: 1px solid #bdbdbd;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
}

/* LABEL LEFT */
.lttTotalBox span:first-child {
    white-space: nowrap;
    color: #454545;
}

/* VALUE RIGHT */
.lttTotalBox span:last-child {
    margin-left: auto;
    min-width: 70px;
    text-align: right;
}


/* ================= LEFT ROWS ================= */



/* SINGLE BORDER ROW */
.lttRowBox {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    border: 1px solid #bdbdbd;
    border-radius: 6px;
    background: #fff;
    width: 100%;
    box-sizing: border-box;
    /* Ensures padding doesn't add to width */
}

.lttLeft {
    display: flex;
    flex-wrap: wrap;
    /* Allows items to wrap on small screens */
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
}

.lttLeft_inner {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

.lttLabel {
    /* font-weight: 500; */
    color: #454545;
    font-size: 14px;
}

.lttValue {
    /* font-weight: 600; */
}





/* + / − stays in the middle */
.lttAction {
    font-size: 20px;
    font-weight: 600;
    color: #666;
    padding: 0 10px;
    border: 1px solid #b2b2b2;
    border-radius: 8px;
    background: #f5f5f5;
}





.lttValue {
    width: 60px;
    text-align: right;
    font-size: 14px;
}


.lttAction.minus {
    color: #D0191D;
}



/* ================= TOTAL ================= */

/* ================= LTT RIGHT PANEL ================= */

.lttRight {
    flex: 1;
    background: #f5f5f5;
    border: 1px solid #bdbdbd;
    border-radius: 8px;
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Each control row */
.lttControl {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Location row: label left, radios right */
.lttControl:first-child {
    justify-content: space-between;
}

/* Typography tweaks */
.lttControl .MuiTypography-root {
    font-size: 14px;
    white-space: nowrap;
    color: #454545;
}

/* Radio group inline spacing */
.lttControl .MuiRadioGroup-root {
    display: flex;
    gap: 12px;
}

/* Checkbox row aligns left */
.lttControl:last-child {
    justify-content: flex-start;
}

.mobileLocationRadioIcon {
    width: 28px;
    height: 28px;
    color: #d6d9df;
    stroke-width: 2;
}

.mobileLocationRadioIcon.checked {
    color: #e31b23;
    stroke-width: 2.5;
}

.mobileFtbCheckboxIcon {
    width: 34px;
    height: 34px;
    border: 2px solid #d6d9df;
    border-radius: 11px;
    background: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #e31b23;
}

.mobileFtbCheckboxIcon.checked {
    border-color: #e31b23;
}





/* Ensure input fills the cell */
.cell .MuiFormControl-root {
    width: 100%;
    height: 100%;
}

.cell .MuiOutlinedInput-root {
    height: 100%;
    border: 1px solid #bdbdbd !important;
}

.frequencyRow {
    display: flex;
    align-items: center;
    gap: 8px;
}

.totalField .MuiOutlinedInput-root {
    border: none !important;
}

.totalField .MuiInputBase-root {
    background: transparent;
}

/* Container that aligns with the scenario columns */
.totalRequired_Wrapper {
    display: flex;
    flex: 4;
    /* Matches the 4 scenario columns */
    justify-content: flex-start;
    /* Keeps it from stretching to 100% if not needed */
    padding: 4px 0;
}

/* The actual "box" with the background */
.totalRequired_Inner {
    display: flex;
    width: 100%;
    background-color: #f5f5f5;
    /* Light grey background like the footer */
    border-radius: 8px;
    /* Rounded corners */
    border: 1px solid #e0e0e0;
    /* Optional: light border for definition */
    padding: 8px 0;
    align-items: center;
}

/* Ensure the text fields inside the box look clean */
.totalRequired_Inner .totalField {
    flex: 1;
    display: flex;
    justify-content: center;
}

/* Remove the default border of the TextField inside this specific box 
   to make it look like flat text if desired */
.totalRequired_Inner .MuiOutlinedInput-notchedOutline {
    border: none;
}

/* Container for the values area only (excluding the label) */
.totalRequiredContent {
    flex: 4;
    /* Matches the space of the 4 scenario columns */
    display: flex;
    padding: 5px 0;
}

/* The actual card with the #f5f5f5 background */
.totalRequiredInnerCard {
    display: flex;
    width: 100%;
    background-color: #f5f5f5;
    /* Matches the payment box background */
    border: 1px solid #e0e0e0;
    /* Light border similar to image */
    border-radius: 8px;
    /* Rounded corners */
    padding: 10px 0;
    align-items: center;
}

/* Ensure the text fields inside the card look like flat text */
.totalRequiredInnerCard .totalField {
    flex: 1;
    display: flex;
    justify-content: center;
}

/* Hide the Material-UI input border inside this specific card */
.totalRequiredInnerCard .MuiOutlinedInput-notchedOutline {
    border: none !important;
}

/* Match the font style from your image */
.totalRequiredInnerCard input {
    font-weight: 600 !important;
    text-align: center !important;
    color: #4b4b4b;
    font-size: 14px;
}

/* Alignment fix for the label cell in this specific row */
.totalRequiredRow {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}



.lttEquationRowFlex {
    display: flex;
    align-items: center;
    gap: 8px;
}

.lttBox {
    flex: 1 1 0;
    min-width: 0;

    display: flex;
    justify-content: space-between;
    align-items: center;

    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    box-sizing: border-box;
}

.lttBox.total {
    background: #f7f7f7;
}


.lttOperator {
    flex: 0 0 24px;
    /* 👈 never grows, never shrinks */
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    color: #444;
}

.lttOperator.minus {
    color: #D0191D;
}

.lttBoxHeader {
    display: flex;
    align-items: center;
    gap: 6px;
}

.lttHelpIcon {
    font-size: 16px;
    cursor: pointer;
    color: #777;
}

.mobileCalcSectionTitle {
    display: none;
}

.mobileTotalInlineValue {
    display: none;
}

.mobileFrequencyTrigger,
.mobileFrequencySheetOverlay {
    display: none;
}

.calcInfoIcon {
    color: #6f7680;
    cursor: pointer;
    flex: 0 0 auto;
}

.calcInfoIcon:hover {
    color: #D0191D;
}




@media (max-width:1500px) {
    .labelCell {

        font-size: 14px;


    }


}


/* ================= RESPONSIVE ================= */

@media (max-width: 1199px) {
    .tableRow .cell:nth-child(5) {
        display: none;
    }

    .totalInner .totalField:nth-child(5),
    .footerValues .totalField:nth-child(4) {
        display: none !important;
    }

    .centerInput input,
    .centerInput .MuiSelect-select {

        margin-left: 10px;
    }

    .centerInput_noAdornment input,
    .centerInput_noAdornment .MuiSelect-select {
        margin-left: 55px;
    }

    .lttRow {
        flex: 1 1 45%;
        /* Show 2 per row on tablets */
    }

}

/* === LTT RESPONSIVE === */

@media (max-width: 899px) {

    .lttLayout {
        flex-direction: column;
        gap: 20px;
    }





    .centerInput input,
    .centerInput .MuiSelect-select {

        margin-left: 0px;
    }

    .centerInput_noAdornment input,
    .centerInput_noAdornment .MuiSelect-select {
        margin-left: 35px;
    }
}


@media (max-width: 768px) {


    .lttLayout {
        flex-direction: column;
    }

    .tableRow .cell:nth-child(4) {
        display: none;
    }

    .totalInner .totalField:nth-child(4),
    .footerValues .totalField:nth-child(3) {
        display: none !important;
    }

    .footerLeft .labelCell {
        white-space: normal;
        overflow: visible;
        height: auto;
    }

    .centerInput_noAdornment input,
    .centerInput_noAdornment .MuiSelect-select {
        margin-left: 15px;
    }

    .card_upper {
        padding: 10px;
        border: none;
        border-radius: 12px;
        margin-bottom: 10px;
    }

    .lttControl {
        display: flex;
        align-items: unset;
        gap: 8px;
        flex-direction: column;
    }


}

@media (max-width: 599px) {

    .payment_calculator_contaner,
    .norecent_payment_calculator_contaner {
        background: #fff !important;
        padding-bottom: 0 !important;
    }

    .payment_calculator_contaner_tab {
        padding: 0 !important;
        background: #fff !important;
    }

    .payment_calculator_contaner_tab_container {
        display: none !important;
    }

    .mortgageCalculatorRoot {
        width: 100%;
        background: #fff;
    }

    .table {
        padding-top: 5px;
    }

    .tableRow .cell:nth-child(3) {
        display: none;
    }

    .totalInner .totalField:nth-child(3),
    .footerValues .totalField:nth-child(2) {
        display: none !important;
    }

    .askingPriceInput {
        width: auto;
        flex: 1;
        max-width: 100%;
    }

    .frequencyRow {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .frequencyRow .MuiFormControl-root {
        width: 100%;
    }

    .card {
        padding: 10px 18px 118px;
        background: #fff;
    }

    .card_ltt {
        padding-bottom: 60px;
    }

    .headerRow .cell:nth-child(2) {
        display: none;
    }

    .card_upper {
        padding: 0;
        border: none;
        margin: 0;
    }

    .askingPriceBox {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 22px;
        padding: 18px 16px;
        margin: 5px 0 28px;
        background: #fbfbfc;
        border: 1px solid #edf0f4;
        border-radius: 18px;
    }

    .askingPriceLabel {
        width: 100%;
        gap: 12px;
        justify-content: space-between;
    }

    .askingPriceLabel .inputLabelBold {
        color: #111827;
        font-size: 18px;
        font-weight: 600 !important;
        white-space: nowrap;
    }

    .askingPriceInput {
        min-width: 0;
        height: 48px;
        border-color: #e2e5ea;
        border-radius: 14px;
        background: #fff;
    }

    .askingPriceInput .MuiOutlinedInput-root {
        height: 48px;
        border-radius: 14px;
        padding-left: 0;
        overflow: hidden;
    }

    .askingPriceInput .MuiOutlinedInput-root .MuiOutlinedInput-notchedOutline {
        border-left: 1px solid #e2e5ea;
        border-color: #e2e5ea;
    }

    .askingPriceInput .MuiInputAdornment-root {
        align-self: stretch;
        height: 48px;
        max-height: none;
        min-width: 54px;
        justify-content: center;
        align-items: center;
        border-width: 0 1px 0 0;
        border-color: #e2e5ea;
        border-radius: 0;
        color: #6b7280;
        background: #f7f8fa;
        font-size: 17px;
        font-weight: 600;
        line-height: 1;
        margin: 0;
        transform: none;
    }

    .askingPriceInput .MuiInputAdornment-root p,
    .askingPriceInput .MuiInputAdornment-root span {
        height: 100%;
        margin: 0;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        line-height: 1;
    }

    .askingPriceInput input {
        color: #111827;
        font-size: 16px;
        font-weight: 600;
        padding-left: 14px !important;
    }

    .askingPriceInput input::placeholder {
        color: #9aa1ac;
        opacity: 1;
    }

    .lttControl {
        width: 100%;
        gap: 14px;
    }

    .lttControl .MuiTypography-root {
        color: #111827;
        font-size: 16px;
        font-weight: 500 !important;
        white-space: normal;
    }

    .lttControl .MuiRadioGroup-root {
        width: 100%;
        gap: 22px;
        align-items: center;
    }

    .lttControl .MuiFormControlLabel-root {
        margin: 0;
        color: #374151;
    }

    .lttControl .MuiFormControlLabel-label {
        color: #374151;
        font-size: 16px;
        font-weight: 500;
    }

    .lttControl .MuiRadio-root,
    .lttControl .MuiCheckbox-root {
        padding: 0 8px 0 0;
    }


    .lttControl:not(.lttControl_responsive) {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .lttControl:not(.lttControl_responsive) .MuiCheckbox-root {
        width: auto;
        height: auto;
        padding: 0;
    }

    .mobileCalcSectionTitle {
        display: flex;
        align-items: center;
        gap: 10px;
        margin: 0 8px 14px;
    }

    .mobileCalcSectionTitle span {
        width: 4px;
        height: 24px;
        border-radius: 999px;
        background: #e31b23;
    }

    .mobileCalcSectionTitle h2 {
        margin: 0;
        color: #111827;
        font-size: 18px;
        font-weight: 700;
        letter-spacing: 0;
    }

    .mobileLttTitle {
        margin-top: 0;
    }

    .lttLeft {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 12px;
        margin-bottom: 34px;
        padding-bottom: 30px;
        border-bottom: 1px solid #e5e7eb;
    }

    .lttRow,
    .lttTotalRow {
        flex: none;
        width: 100%;
        max-width: none;
        min-width: 0;
    }

    .lttAction {
        display: none;
    }

    .lttRowBox,
    .lttTotalBox {
        min-height: 58px;
        padding: 0 18px;
        border: 1px solid #e4e7eb;
        border-radius: 14px;
        background: #fff;
    }

    .lttTotalBox {
        min-height: 70px;
        background: #fafbfc;
    }

    .lttLeft_inner {
        gap: 10px;
    }

    .lttLabel,
    .lttValue,
    .lttTotalBox span:first-child,
    .lttTotalBox span:last-child {
        color: #374151;
        font-size: 18px;
        font-weight: 500;
    }

    .lttValue {
        width: auto;
        min-width: 70px;
        font-weight: 700;
    }

    .lttTotalBox span:last-child {
        font-size: 21px;
        font-weight: 800;
    }

    .mobileMortgageTitle {
        margin: 0 8px 18px;
    }

    .mortgageCalcTable {
        display: flex;
        flex-direction: column;
        gap: 12px;
        padding: 22px 18px;
        border: 1px solid #e7eaee;
        border-radius: 18px;
        overflow: visible;
        background: #fff;
    }

    .mortgageCalcTable .headerRow {
        display: none;
    }

    .mortgageCalcTable .tableRow {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(145px, 48%);
        align-items: center;
        gap: 12px;
        min-height: auto;
    }

    .mortgageCalcTable .labelCell {
        width: auto;
        min-width: 0;
        padding: 0;
        color: #374151;
        background: transparent;
        font-size: 18px;
        line-height: 1.25;
        font-weight: 500;
    }

    .mortgageCalcTable .labelCell .calcInfoIcon,
    .lttLeft .calcInfoIcon {
        width: 18px;
        height: 18px;
        color: #6f7783;
    }

    .mortgageCalcTable .cell {
        display: flex;
        min-width: 0;
        padding: 0;
    }

    .mortgageCalcTable .cell .MuiFormControl-root,
    .mortgageCalcTable .cell .MuiInputBase-root {
        width: 100%;
    }

    .cell .MuiOutlinedInput-root,
    .mortgageCalcTable .MuiOutlinedInput-root {
        height: 54px;
        border: 1px solid #e2e5ea !important;
        border-radius: 14px !important;
        overflow: hidden;
        background: #fff;
        align-items: center;
        padding-left: 0 !important;
    }

    .greyBg .MuiOutlinedInput-root {
        background: #fafbfc !important;
    }

    .mortgageCalcTable .MuiOutlinedInput-notchedOutline {
        border: none !important;
    }

    .centerInput input,
    .centerInput .MuiSelect-select,
    .centerInput_noAdornment input,
    .centerInput_noAdornment .MuiSelect-select {
        margin-left: 0 !important;
        color: #111827;
        font-size: 18px !important;
        font-weight: 600 !important;
        padding-left: 0 !important;
    }

    .centerInput .MuiInputAdornment-root {
        align-self: center;
        min-width: 58px;
        height: 54px;
        max-height: none;
        margin: 0 14px 0 0;
        justify-content: flex-start;
        align-items: center;
        padding-left: 20px;
        background: #f7f8fa;
        border-right: 1px solid #e2e5ea;
        color: #6b7280;
        font-size: 18px;
        font-weight: 600;
        line-height: 1;
    }

    .centerInput .MuiInputAdornment-root .fixedAdornment {
        min-width: auto;
        height: 100%;
        display: inline-flex;
        align-items: center;
        justify-content: flex-start;
        line-height: 1;
    }

    .centerInput_noAdornment .MuiSelect-select {
        padding-left: 28px !important;
    }

    .downPaymentPercentRow {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) minmax(145px, 48%);
        align-items: center;
        gap: 12px;
    }

    .downPaymentPercentRow .labelCell {
        visibility: visible;
    }

    .downPaymentAmountRow .labelCell {
        visibility: hidden;
    }

    .downPaymentPercentRow .cell {
        width: 100%;
        min-width: 0;
    }

    .downPaymentAmountRow {
        margin-top: -2px;
    }

    .mortgageInsuranceRow {
        margin-top: 16px;
    }

    .totalMortgageRequiredRow {
        display: block !important;
        margin: 24px 0 12px;
    }

    .totalInner {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
        position: relative;
        width: 100%;
        min-height: 72px;
        margin: 0;
        padding: 16px 18px;
        background: #fafbfc;
        border: 1px solid #e4e7eb;
        border-radius: 14px;
        overflow: visible;
    }

    .totalInner .labelCell,
    .totalInner .cell {
        background: transparent;
    }

    .totalMortgageRequiredRow .labelCell {
        flex: 1 1 auto;
        max-width: none;
        color: #111827;
        font-size: 17px;
        line-height: 1.35;
        font-weight: 800 !important;
    }

    .totalMortgageRequiredRow .totalField .MuiOutlinedInput-root,
    .mortgagePaymentRow .totalField .MuiOutlinedInput-root {
        height: auto;
        min-height: 42px;
        border: none !important;
        background: transparent !important;
        padding: 0 !important;
        align-items: center;
    }

    .totalMortgageRequiredRow .centerInput .MuiInputAdornment-root,
    .mortgagePaymentRow .centerInput .MuiInputAdornment-root {
        min-width: auto;
        height: auto;
        margin-right: 6px;
        border: 0;
        background: transparent;
        color: #111827;
        font-weight: 800;
        align-self: center;
        align-items: center;
        line-height: 1;
        transform: none;
    }

    .totalMortgageRequiredRow .centerInput .MuiInputAdornment-root .fixedAdornment,
    .mortgagePaymentRow .centerInput .MuiInputAdornment-root .fixedAdornment {
        height: auto;
        align-items: center;
        line-height: 1;
    }

    .totalMortgageRequiredRow input,
    .mortgagePaymentRow input {
        color: #111827 !important;
        font-size: 21px !important;
        font-weight: 800 !important;
        text-align: left !important;
        width: auto !important;
        min-width: 18px;
    }

    .totalMortgageRequiredRow .totalField,
    .mortgagePaymentRow .totalField {
        display: none !important;
    }

    .totalMortgageRequiredRow .totalField .MuiFormControl-root,
    .mortgagePaymentRow .totalField .MuiFormControl-root {
        width: auto !important;
        min-width: 72px;
    }

    .totalMortgageRequiredRow .totalField .MuiInputBase-root,
    .mortgagePaymentRow .totalField .MuiInputBase-root {
        width: auto !important;
        display: inline-flex;
        justify-content: flex-end;
    }

    .amortizationRow,
    .mortgageRateRow {
        margin-top: 14px;
    }

    .amortizationRow .cell,
    .mortgageRateRow .cell {
        width: 100%;
        align-self: center;
    }

    .amortizationRow .MuiOutlinedInput-root,
    .mortgageRateRow .MuiOutlinedInput-root {
        height: 52px !important;
    }

    .mortgageRateRow .centerInput_noAdornment input {
        padding-left: 28px !important;
    }

    .mortgagePaymentRow {
        display: block !important;
        margin-top: 26px;
    }

    .mortgagePaymentRow .totalInner {
        min-height: 116px;
        background: #fafbfc;
        align-items: stretch;
    }

    .label_mortgagePayment {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: space-between;
        flex: 1 1 auto;
        min-width: 0;
        gap: 18px;
    }

    .label_mortgagePayment .bold {
        color: #111827;
        font-size: 18px;
        font-weight: 700;
    }

    .frequencySelect {
        width: 100%;
        min-width: 125px;
        max-width: 150px;
        height: 52px;
        border: 1px solid #e2e5ea;
        border-radius: 14px;
        background: #fff;
    }

    .frequencySelect .MuiOutlinedInput-root {
        height: 52px;
        border-radius: 14px;
    }

    .frequencySelect .MuiSelect-select {
        color: #111827;
        font-size: 18px !important;
        font-weight: 500 !important;
        padding-left: 20px !important;
    }

    .mobileFrequencyTrigger {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        width: 100%;
        min-width: 125px;
        max-width: 150px;
        height: 52px;
        padding: 0 18px;
        border: 1px solid #e2e5ea;
        border-radius: 14px;
        background: #fff;
        color: #111827;
        font-family: inherit;
        font-size: 16px;
        font-weight: 500;
        line-height: 1.2;
        text-align: left;
    }

    .mobileFrequencySheetOverlay {
        position: fixed;
        inset: 0;
        z-index: 1400;
        display: flex;
        align-items: flex-end;
        justify-content: center;
        background: rgba(17, 24, 39, 0.55);
    }

    .mobileFrequencySheet {
        width: 100%;
        min-height: 46vh;
        padding: 8px 12px max(28px, env(safe-area-inset-bottom));
        border-radius: 18px 18px 0 0;
        background: #fff;
        box-shadow: 0 -12px 36px rgba(15, 23, 42, 0.18);
        animation: mobileFrequencySheetUp 0.22s ease-out;
    }

    .mobileFrequencySheetHandle {
        width: 48px;
        height: 4px;
        margin: 0 auto 16px;
        border-radius: 999px;
        background: #eef0f3;
    }

    .mobileFrequencySheetHeader {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
        margin-bottom: 18px;
        padding: 0 2px;
    }

    .mobileFrequencySheetHeader h3 {
        margin: 0;
        color: #111827;
        font-size: 16px;
        line-height: 22px;
        font-weight: 700;
    }

    .mobileFrequencySheetClose {
        width: 34px;
        height: 34px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 0;
        border-radius: 50%;
        background: transparent;
        color: #6b7280;
    }

    .mobileFrequencySheetOptions {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .mobileFrequencySheetOption {
        min-height: 44px;
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 0 12px;
        border: 1px solid #edf0f4;
        border-radius: 12px;
        background: #fff;
        color: #111827;
        font-family: inherit;
        font-size: 15px;
        font-weight: 500;
        text-align: left;
    }

    .mobileFrequencySheetOption.active {
        border-color: #d0191d;
        color: #d0191d;
        width: 90%;
        margin: 0 auto;

    }

    .mobileFrequencySheetOption.active svg {
        color: #d0191d;
        flex: 0 0 auto;
    }

    @keyframes mobileFrequencySheetUp {
        from {
            transform: translateY(100%);
        }

        to {
            transform: translateY(0);
        }
    }

    .footerValues {
        justify-content: flex-end;
    }

    .footerValues .totalField {
        flex: 0 0 100%;
    }

    .mobileTotalInlineValue {
        display: inline-flex;
        align-items: center;
        justify-content: flex-end;
        margin-left: auto;
        color: #111827;
        font-size: 18px;
        font-weight: 800;
        line-height: 1;
        white-space: nowrap;
    }

    .mortgagePaymentRow .footerValues {
        position: static;
        align-self: center;
        display: flex !important;
        flex: 0 0 auto !important;
        width: auto;
    }

    .mortgagePaymentRow .footerValues .mobileTotalInlineValue {
        font-size: 18px;
    }

    .totalField .MuiInputBase-input {
        padding-right: 0px !important;
    }

    .mortgageRateRow .centerInput .MuiInputAdornment-positionEnd {
        align-self: center;
        width: auto;
        min-width: auto;
        height: auto;
        margin: 0 14px 0 auto;
        border: 0;
        background: transparent;
        color: #6b7280;
        font-size: 18px;
        line-height: 1;
    }

    .mortgageRateRow .centerInput .MuiInputAdornment-positionEnd p,
    .mortgageRateRow .centerInput .MuiInputAdornment-positionEnd span {
        height: auto;
        margin: 0;
        line-height: 1;
    }
}

@media (max-width: 420px) {


    .lttControl_responsive {
        flex-direction: column;
        align-items: self-start;
        gap: 8px;
    }
}

@media (max-width: 450px) {
    .lttControl:first-child {
        flex-direction: column;
        align-items: flex-start;
    }


}


@media (max-width: 399px) {
    .labelCell {
        width: 150px;

    }

    .askingPriceInput input {

        font-size: 14px;

    }

    .askingPriceLabel .inputLabelBold {

        font-size: 16px;

    }

    .mortgageCalcTable .labelCell {

        font-size: 16px;
        line-height: 1.25;
        font-weight: 500;
    }

    .lttRow {
        flex: 1 1 60%;
        /* Stack vertically on phones */
    }

    .lttRowBox {
        width: 100%;

    }

    .lttLabel,
    .lttValue,
    .lttTotalBox span:first-child,
    .lttTotalBox span:last-child {

        font-size: 16px;

    }

    .lttControl .MuiFormControlLabel-label {
        color: #374151;
        font-size: 16px;
        font-weight: 500;
    }

    .label_mortgagePayment .bold {

        font-size: 16px;
        font-weight: 700;
    }

    .lttControl .MuiFormControlLabel-label {
        font-size: 16px;

    }

    .centerInput input,
    .centerInput .MuiSelect-select,
    .centerInput_noAdornment input,
    .centerInput_noAdornment .MuiSelect-select {

        font-size: 16px !important;

    }

    .mobileTotalInlineValue {

        font-size: 16px;

    }

    .mortgagePaymentRow .footerValues .mobileTotalInlineValue {
        font-size: 16px;
    }
}

@media (max-width: 350px) {
    .lttControl .MuiRadioGroup-root {
        gap: 0px;
    }

    .mortgageCalcTable .labelCell {

        font-size: 14px;
        line-height: 1.25;
        font-weight: 500;
    }

    .lttLabel,
    .lttValue,
    .lttTotalBox span:first-child,
    .lttTotalBox span:last-child {

        font-size: 14px;

    }

    .label_mortgagePayment .bold {

        font-size: 14px;
        font-weight: 700;
    }

    .lttControl .MuiFormControlLabel-label {
        font-size: 14px;

    }

    .lttControl .MuiTypography-root {
        font-size: 14px;

    }

    .askingPriceInput input {

        font-size: 12px;

    }

    .centerInput input,
    .centerInput .MuiSelect-select,
    .centerInput_noAdornment input,
    .centerInput_noAdornment .MuiSelect-select {

        font-size: 14px !important;

    }

    .mobileTotalInlineValue {

        font-size: 14px;

    }

    .mortgagePaymentRow .footerValues .mobileTotalInlineValue {
        font-size: 14px;
    }
}