.lctl {
    --lctl-ink: #12243a;
    --lctl-muted: #5d6d7f;
    --lctl-line: #dce4ec;
    --lctl-soft: #f7f9fc;
    --lctl-accent: #136f63;
    --lctl-accent-dark: #0d544b;
    --lctl-good: #157347;
    --lctl-warn: #9a4d00;
    color: var(--lctl-ink);
    font-family: inherit;
}

.lctl * { box-sizing: border-box; }

.lctl-shell {
    max-width: 980px;
    margin: 0 auto;
    border: 1px solid var(--lctl-line);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 18px 55px rgba(18, 36, 58, .08);
    overflow: hidden;
}

.lctl-hero {
    padding: 32px 34px 26px;
    background: linear-gradient(135deg, #f6fbfa 0%, #edf7f5 100%);
    border-bottom: 1px solid var(--lctl-line);
}

.lctl-eyebrow,
.lctl-kicker {
    display: inline-block;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--lctl-accent-dark);
}

.lctl-hero h2 {
    margin: 8px 0 10px;
    font-size: clamp(28px, 4.2vw, 42px);
    line-height: 1.12;
}

.lctl-hero p,
.lctl-info-card p,
.lctl-disclaimer p {
    margin: 0;
    line-height: 1.65;
}

.lctl-note {
    margin: 24px 34px 0;
    padding: 15px 17px;
    border-left: 4px solid var(--lctl-accent);
    background: #f2f8f7;
    border-radius: 10px;
    line-height: 1.6;
}

.lctl-form { padding: 28px 34px 12px; }

.lctl-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.lctl-field {
    display: block;
    padding: 18px;
    border: 1px solid var(--lctl-line);
    border-radius: 14px;
    background: #fff;
}

.lctl-field-wide { grid-column: 1 / -1; }

.lctl-label {
    display: block;
    margin-bottom: 9px;
    font-weight: 800;
    line-height: 1.35;
}

.lctl-label b { color: #b42318; }
.lctl-optional { color: var(--lctl-muted); font-weight: 600; font-size: 12px; }

.lctl-money-input {
    display: flex;
    align-items: center;
    min-height: 50px;
    border: 1px solid #bdc9d7;
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
}

.lctl-money-input > span {
    padding: 0 13px;
    font-weight: 800;
    color: #4e6177;
    border-right: 1px solid var(--lctl-line);
}

.lctl input {
    width: 100%;
    min-width: 0;
    padding: 13px 14px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--lctl-ink);
    font: inherit;
    font-size: 16px;
}

.lctl-money-input:focus-within {
    border-color: var(--lctl-accent);
    box-shadow: 0 0 0 3px rgba(19, 111, 99, .12);
}

.lctl-field small {
    display: block;
    margin-top: 8px;
    color: var(--lctl-muted);
    line-height: 1.45;
}

.lctl-error {
    display: block;
    min-height: 18px;
    margin-top: 5px;
    color: #b42318;
    font-size: 12px;
    font-style: normal;
    font-weight: 700;
}

.lctl-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 9px;
}

.lctl-quick button,
.lctl-secondary {
    appearance: none;
    border: 1px solid #b9c7d6;
    border-radius: 9px;
    background: #fff;
    color: var(--lctl-ink);
    font: inherit;
    font-weight: 750;
    cursor: pointer;
}

.lctl-quick button { padding: 7px 10px; font-size: 13px; }
.lctl-quick button:hover, .lctl-secondary:hover { background: var(--lctl-soft); }

.lctl-actions {
    display: flex;
    gap: 10px;
    padding-top: 18px;
}

.lctl-primary,
.lctl-secondary {
    min-height: 48px;
    padding: 0 18px;
}

.lctl-primary {
    flex: 1;
    border: 0;
    border-radius: 10px;
    background: var(--lctl-accent);
    color: #fff;
    font: inherit;
    font-weight: 850;
    cursor: pointer;
}

.lctl-primary:hover { background: var(--lctl-accent-dark); }

.lctl-results {
    margin: 16px 34px 28px;
    padding: 24px;
    border: 1px solid #cfe2df;
    border-radius: 18px;
    background: linear-gradient(180deg, #fcfefd 0%, #f4f9f8 100%);
}

.lctl-result-top {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: flex-start;
}

.lctl-result-top h3 {
    margin: 5px 0 4px;
    font-size: clamp(34px, 6vw, 50px);
    line-height: 1;
    color: var(--lctl-good);
}

.lctl-result-top p {
    margin: 8px 0 0;
    color: var(--lctl-muted);
    max-width: 650px;
    line-height: 1.55;
}

.lctl-result-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.lctl-small { min-height: 38px; padding: 0 12px; font-size: 13px; }

.lctl-payoff-track {
    margin: 22px 0 18px;
    padding: 16px;
    border: 1px solid var(--lctl-line);
    border-radius: 13px;
    background: #fff;
}

.lctl-payoff-track-head,
.lctl-track-labels {
    display: flex;
    justify-content: space-between;
    gap: 14px;
}

.lctl-payoff-track-head { align-items: center; margin-bottom: 10px; }
.lctl-payoff-track-head span { font-weight: 800; }
.lctl-payoff-track-head strong { color: var(--lctl-accent-dark); }

.lctl-track {
    height: 13px;
    border-radius: 999px;
    background: #e9eef3;
    overflow: hidden;
}

.lctl-track > span {
    display: block;
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, #1c8677, #4aa594);
    transition: width .25s ease;
}

.lctl-track-labels {
    margin-top: 9px;
    color: var(--lctl-muted);
    font-size: 12px;
}

.lctl-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.lctl-metric {
    padding: 15px;
    border: 1px solid var(--lctl-line);
    border-radius: 12px;
    background: #fff;
}

.lctl-metric span { display: block; min-height: 34px; color: var(--lctl-muted); font-size: 12px; line-height: 1.35; }
.lctl-metric strong { display: block; margin-top: 5px; font-size: 18px; word-break: break-word; }
.lctl-metric.lctl-good strong { color: var(--lctl-good); }
.lctl-metric.lctl-warn strong { color: var(--lctl-warn); }

.lctl-breakdown {
    margin-top: 18px;
    padding: 18px;
    border: 1px solid var(--lctl-line);
    border-radius: 14px;
    background: #fff;
}

.lctl-breakdown h4 { margin: 0 0 11px; font-size: 18px; }
.lctl-breakdown ul { list-style: none; margin: 0; padding: 0; }
.lctl-breakdown li {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding: 10px 0;
    border-bottom: 1px dashed #dce4ed;
}
.lctl-breakdown li:last-child { border-bottom: 0; }
.lctl-breakdown li span { color: var(--lctl-muted); }
.lctl-breakdown li strong { text-align: right; }
.lctl-breakdown .lctl-total { font-size: 16px; }
.lctl-breakdown .lctl-total span, .lctl-breakdown .lctl-total strong { color: var(--lctl-ink); font-weight: 850; }
.lctl-equity-note { margin: 12px 0 0; color: var(--lctl-muted); line-height: 1.55; }

.lctl-method {
    margin-top: 15px;
    padding: 14px 16px;
    border-radius: 11px;
    background: #eef7f5;
    line-height: 1.55;
    font-size: 14px;
}

.lctl-info-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    padding: 0 34px 26px;
}

.lctl-info-card {
    padding: 17px;
    border: 1px solid var(--lctl-line);
    border-radius: 13px;
    background: #fff;
}

.lctl-info-card strong { display: block; margin-bottom: 6px; }
.lctl-info-card p { color: var(--lctl-muted); font-size: 14px; }

.lctl-disclaimer {
    margin: 0 34px 34px;
    padding: 18px;
    border: 1px solid #ead7bd;
    border-radius: 14px;
    background: #fffaf2;
}

.lctl-disclaimer strong { display: block; margin-bottom: 6px; color: #72420a; }
.lctl-disclaimer p { color: #5f4b33; font-size: 13px; }

@media (max-width: 760px) {
    .lctl-shell { border-radius: 16px; }
    .lctl-hero { padding: 24px 18px 20px; }
    .lctl-note { margin: 18px 18px 0; }
    .lctl-form { padding: 20px 18px 10px; }
    .lctl-fields { grid-template-columns: 1fr; }
    .lctl-field-wide { grid-column: auto; }
    .lctl-actions { flex-direction: column; }
    .lctl-primary, .lctl-secondary { width: 100%; }
    .lctl-results { margin: 14px 18px 22px; padding: 18px; }
    .lctl-result-top { flex-direction: column; }
    .lctl-result-actions { width: 100%; }
    .lctl-result-actions .lctl-secondary { width: auto; flex: 1; }
    .lctl-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .lctl-info-grid { grid-template-columns: 1fr; padding: 0 18px 22px; }
    .lctl-disclaimer { margin: 0 18px 22px; }
}

@media (max-width: 480px) {
    .lctl-metrics { grid-template-columns: 1fr; }
    .lctl-result-actions { flex-direction: column; }
    .lctl-result-actions .lctl-secondary { width: 100%; }
    .lctl-breakdown li { align-items: flex-start; }
    .lctl-breakdown li span { max-width: 60%; }
    .lctl-track-labels { flex-direction: column; gap: 4px; }
}

@media (prefers-reduced-motion: reduce) {
    .lctl-track > span { transition: none; }
}

@media print {
    .lctl-form,
    .lctl-actions,
    .lctl-result-actions,
    .lctl-info-grid,
    .lctl-disclaimer,
    .lctl-note { display: none !important; }
    .lctl-shell, .lctl-results { border: 0; box-shadow: none; margin: 0; padding: 0; }
    .lctl-results[hidden] { display: none !important; }
}
