.loan-calculator {
    max-width: var(--lc-max, 100%);
    width: 100%;
    margin: 20px auto;
    padding: var(--lc-pad, 20px);
    background: var(--lc-bg, #f9f9f9);
    border-radius: var(--lc-radius, 8px);
    border: var(--lc-border-w, 0) solid var(--lc-border, transparent);
    text-align: center;
    box-sizing: border-box;
    position: relative;
    color: var(--lc-text, #333);
    font-family: var(--lc-font, inherit);
}

.loan-calculator.lc-shadow {
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.04);
}

.loan-calculator.lc-align-left { text-align: left; }
.loan-calculator.lc-align-right { text-align: right; }

.loan-calculator *,
.loan-calculator *::before,
.loan-calculator *::after { box-sizing: border-box; }

.lc-eyebrow {
    margin: 0 0 6px;
    font-size: 12px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--lc-accent, #409744);
}

.lc-title {
    margin: 0 0 8px;
    font-size: var(--lc-title, 26px);
    line-height: 1.2;
    color: var(--lc-heading, #333);
}

.lc-intro {
    font-size: var(--lc-body, 13px);
    margin: 0 0 20px;
    color: var(--lc-intro, #333);
}

.lc-kicker {
    margin: 0 0 4px;
    font-size: var(--lc-label-size, 14px);
    font-weight: var(--lc-label-weight, 600);
    letter-spacing: 0.02em;
    color: var(--lc-label-color, #5c6570);
}

.lc-value {
    margin: 0 0 12px;
    font-size: var(--lc-value-size, 32px);
    font-weight: 700;
    line-height: 1.1;
    color: var(--lc-heading, #333);
}

.lc-figure { margin: 0; }

.lc-section { margin-bottom: 22px; }

.loan-calculator.lc-labels-beside .lc-figure {
    display: flex;
    align-items: baseline;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 12px;
}

.loan-calculator.lc-labels-beside .lc-figure .lc-kicker,
.loan-calculator.lc-labels-beside .lc-figure .lc-value {
    margin: 0 0 12px;
}

.loan-calculator.lc-align-left.lc-labels-beside .lc-figure { justify-content: flex-start; }
.loan-calculator.lc-align-right.lc-labels-beside .lc-figure { justify-content: flex-end; }

.lc-slider {
    width: 100%;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    background: var(--lc-track, #ddd);
    border-radius: 999px;
    outline: none;
}

.lc-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 28px;
    height: 28px;
    background: var(--lc-accent, #409744);
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.lc-slider::-moz-range-thumb {
    width: 28px;
    height: 28px;
    background: var(--lc-accent, #409744);
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.lc-slider:focus-visible {
    outline: 2px solid var(--lc-accent, #409744);
    outline-offset: 4px;
}

.lc-details {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin: 8px 0 22px;
    gap: 12px;
}

.lc-detail {
    flex: 1;
    min-width: 120px;
    margin: 0;
    padding: 12px 8px;
    position: relative;
}

.lc-detail-estimate {
    background: #fff;
    border-radius: 8px;
}

.lc-minor {
    margin: 0;
    font-size: var(--lc-figure-size, 18px);
    font-weight: 600;
    color: var(--lc-text, #333);
}

.lc-repay {
    margin: 0;
    font-size: var(--lc-repay-size, 28px);
    font-weight: 700;
    line-height: 1.1;
    color: var(--lc-accent, #409744);
}

.lc-apply {
    display: inline-block;
    min-height: 52px;
    padding: 14px 28px;
    background: var(--lc-button, #409744);
    color: var(--lc-button-text, #fff);
    border: none;
    border-radius: var(--lc-btn-radius, 5px);
    cursor: pointer;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.01em;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.loan-calculator.lc-btn-full .lc-apply { width: 100%; }

.lc-apply:hover {
    box-shadow: inset 0 0 0 999px rgba(255, 255, 255, 0.16);
}

.loan-calculator.lc-btn-shadow-faint .lc-apply:hover {
    box-shadow: inset 0 0 0 999px rgba(255, 255, 255, 0.16), 0 3px 8px rgba(0, 0, 0, 0.08);
}

.loan-calculator.lc-btn-shadow-soft .lc-apply:hover {
    box-shadow: inset 0 0 0 999px rgba(255, 255, 255, 0.16), 0 6px 14px rgba(0, 0, 0, 0.12);
}

.loan-calculator.lc-btn-lift .lc-apply:hover {
    transform: translateY(-2px);
}

.loan-calculator.lc-btn-lift .lc-apply:active {
    transform: translateY(0);
}
.lc-apply:focus-visible {
    outline: 2px solid var(--lc-heading, #333);
    outline-offset: 3px;
}

.lc-help {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 18px;
    height: 18px;
    background: transparent;
    color: var(--lc-label-color, #5c6570);
    border-radius: 50%;
    border: 1px solid currentColor;
    font-size: 12px;
    font-weight: 700;
    margin-left: 4px;
    cursor: pointer;
    vertical-align: middle;
    padding: 0;
    line-height: 1;
}

.lc-help:hover,
.lc-help[aria-expanded="true"] {
    background: var(--lc-accent, #409744);
    border-color: var(--lc-accent, #409744);
    color: #fff;
}

.lc-popover {
    position: fixed;
    z-index: 100000;
    width: min(380px, calc(100vw - 16px));
    max-height: calc(100vh - 16px);
    padding: 0;
    margin: 0;
    text-align: left;
    background: #fff;
    color: #333;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
    overflow: auto;
    box-sizing: border-box;
}

.lc-popover[hidden] { display: none !important; }

.lc-popover-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    position: sticky;
    top: 0;
    z-index: 1;
    padding: 12px 14px;
    background: #fff;
    color: #222;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.3;
    border-bottom: 1px solid #eee;
}

.lc-popover-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    min-width: 28px;
    margin: 0;
    border: 0;
    border-radius: 50%;
    background: #f2f2f2;
    color: #222;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    box-shadow: none;
}

.lc-popover-close:hover { background: #e6e6e6; }

.lc-popover-slot { padding: 4px 16px 14px; }

.lc-tip-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    font-size: 14px;
    color: var(--lc-text, #333);
}

.lc-tip-row strong {
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.lc-tip-note {
    margin: 0;
    padding: 6px 0 6px 10px;
    border-left: 2px solid var(--lc-accent, #409744);
    font-size: 13px;
    line-height: 1.4;
    color: var(--lc-label-color, #5c6570);
}

.lc-disclosure {
    margin: 14px 0 0;
    font-size: var(--lc-body, 12px);
    line-height: 1.4;
    color: var(--lc-intro, #333);
}

@media (max-width: 600px) {
    .lc-details {
        flex-direction: column;
        align-items: center;
    }
    .lc-detail {
        width: 100%;
        margin: 10px 0;
    }
    .loan-calculator.lc-align-left .lc-details,
    .loan-calculator.lc-align-right .lc-details { align-items: stretch; }
    .lc-apply { width: 100%; }
}
