.mef-portage {
  --mef-blue: #267df4;
  --mef-navy: #172033;
  --mef-muted: #64748b;
  padding: 72px 20px;
  color: var(--mef-navy);
  font-family: Poppins, Arial, sans-serif;
}

.mef-portage * { box-sizing: border-box; }
.mef-portage__shell { max-width: 1180px; margin: 0 auto; }
.mef-portage__layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.mef-portage__form, .mef-portage__result { border-radius: 22px; box-shadow: 0 18px 50px rgba(31, 54, 88, .12); }
.mef-portage__form { padding: 28px 28px 8px; border: 1px solid #e6edf7; background: #fff; }
.mef-portage__tabs { display: grid; grid-template-columns: repeat(3, 1fr); padding: 4px; border-radius: 14px; background: #edf3fb; }
.mef-portage__tabs button { min-height: 48px; padding: 8px 10px; border: 0; border-radius: 11px; background: transparent; color: #526078; font: 600 13px Poppins, Arial, sans-serif; cursor: pointer; }
.mef-portage__tabs button.is-active { background: var(--mef-blue); color: #fff; box-shadow: 0 5px 13px rgba(38, 125, 244, .28); }
.mef-portage__tabs button:focus-visible, .mef-portage__cta:focus-visible { outline: 3px solid rgba(38, 125, 244, .35); outline-offset: 3px; }
.mef-portage__field { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 18px; margin-top: 25px; }
.mef-portage__field[hidden] { display: none; }
.mef-portage__field label { align-self: center; margin: 0; color: #344054; font-size: 13px; font-weight: 600; }
.mef-portage__number { display: flex; align-items: center; min-width: 126px; overflow: hidden; border: 1px solid #d3deec; border-radius: 999px; background: #fff; box-shadow: 0 5px 14px rgba(31, 54, 88, .09); }
.mef-portage__number input { width: 82px; min-height: 42px; padding: 7px 2px 7px 14px; border: 0; outline: 0; background: transparent; color: var(--mef-navy); font: 600 16px Poppins, Arial, sans-serif; text-align: right; }
.mef-portage__number input[type="number"] { appearance: textfield; -moz-appearance: textfield; }
.mef-portage__number input[type="number"]::-webkit-inner-spin-button,
.mef-portage__number input[type="number"]::-webkit-outer-spin-button { margin: 0; -webkit-appearance: none; }
.mef-portage__number span { padding: 0 13px 0 5px; color: var(--mef-muted); font-size: 12px; white-space: nowrap; }
.mef-portage__range { grid-column: 1/-1; width: 100%; height: 5px; margin: 9px 0 0; border: 0; border-radius: 999px; background: #dfe7f1; accent-color: var(--mef-blue); cursor: pointer; }
.mef-portage__field small { grid-column: 1/-1; color: #7b879b; font-size: 10px; line-height: 1.5; }
.mef-portage__error { min-height: 20px; margin: 16px 0 0; color: #b42318; font-size: 12px; }
.mef-portage__result { display: flex; flex-direction: column; padding: 34px; background: linear-gradient(145deg, #15253c, #1e3859); color: #fff; }
.mef-portage__result-label { color: #b9c9df; font-size: 13px; letter-spacing: .05em; text-transform: uppercase; }
.mef-portage__net { display: block; margin-top: 4px; font-size: clamp(38px, 5vw, 57px); line-height: 1.08; }
.mef-portage__result-note { margin: 8px 0 24px; color: #c8d4e4; font-size: 11px; line-height: 1.5; }
.mef-portage__breakdown { margin: 0; border-top: 1px solid rgba(255, 255, 255, .18); }
.mef-portage__breakdown--main { margin-bottom: 14px; }
.mef-portage__breakdown--detail { margin-top: 8px; }
.mef-portage__breakdown div { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 10px 2px; border-bottom: 1px solid rgba(255, 255, 255, .14); }
.mef-portage__breakdown dt { color: #b9c9df; font-size: 11px; }
.mef-portage__breakdown dd { margin: 0; color: #fff; font-size: 13px; font-weight: 600; text-align: right; white-space: nowrap; }
.mef-portage__breakdown dd.is-deduction::before { content: "− "; }
.mef-portage__breakdown dd.is-addition::before { content: "+ "; }
.mef-portage__breakdown .is-total { padding-top: 12px; padding-bottom: 12px; }
.mef-portage__breakdown .is-total dt, .mef-portage__breakdown .is-total dd { color: #fff; font-weight: 700; }
.mef-portage__breakdown .is-grand-total { margin-top: 4px; padding: 14px 12px; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .1); }
.mef-portage__breakdown .is-grand-total dt, .mef-portage__breakdown .is-grand-total dd { color: #fff; font-size: 13px; font-weight: 700; }
.mef-portage__breakdown .is-grand-total dt small { display: block; margin-top: 4px; color: #b9c9df; font-size: 9px; font-weight: 400; line-height: 1.4; }
.mef-portage__accordion { color: #edf4ff; }
.mef-portage__accordion summary { position: relative; padding: 10px 24px 10px 0; color: #fff; font-size: 12px; font-weight: 700; cursor: pointer; list-style: none; }
.mef-portage__accordion summary::-webkit-details-marker { display: none; }
.mef-portage__accordion summary::after { content: "⌄"; position: absolute; top: 8px; right: 2px; color: #78b1ff; font-size: 16px; transition: transform .18s ease; }
.mef-portage__accordion[open] summary::after { transform: rotate(180deg); }
.mef-portage__accordion-open { display: none; }
.mef-portage__accordion[open] .mef-portage__accordion-closed { display: none; }
.mef-portage__accordion[open] .mef-portage__accordion-open { display: inline; }
.mef-portage__accordion summary:focus-visible { outline: 3px solid rgba(120, 177, 255, .45); outline-offset: 3px; }
.mef-portage__calculation-details { margin-bottom: 20px; border-top: 1px solid rgba(255, 255, 255, .18); border-bottom: 1px solid rgba(255, 255, 255, .18); }
.mef-portage__benefits { padding: 15px; border-radius: 16px; background: rgba(255, 255, 255, .08); }
.mef-portage__benefits-title { margin: 0 0 7px; color: #fff; font-size: 16px; font-weight: 600; line-height: 1.35; }
.mef-portage__benefits-summary { margin: 0; color: #c8d4e4; font-size: 10px; line-height: 1.5; }
.mef-portage__benefits-details { margin-top: 7px; }
.mef-portage__benefits-details[open] summary { margin-bottom: 8px; }
.mef-portage__benefits ul { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 20px; margin: 0; padding: 0; list-style: none; }
.mef-portage__benefits li { position: relative; padding-left: 20px; color: #edf4ff; font-size: 11px; line-height: 1.45; }
.mef-portage__benefits li::before { content: "✓"; position: absolute; left: 0; color: #78b1ff; font-weight: 800; }
.mef-portage__cta { display: block; margin-top: 20px; padding: 15px 18px; border-radius: 12px; background: #fff; color: #1b2b41 !important; text-align: center; text-decoration: none !important; font-size: 13px; font-weight: 700; }
.mef-portage__cta:hover { background: #eef5ff; }
.mef-portage [aria-busy="true"] .mef-portage__net { opacity: .55; }

@media (max-width: 900px) {
  .mef-portage { padding: 54px 16px; }
  .mef-portage__layout { grid-template-columns: 1fr; }
  .mef-portage__result { min-height: 0; }
  .mef-portage__cta { margin-top: 22px; }
}

@media (max-width: 540px) {
  .mef-portage__form, .mef-portage__result { padding: 20px; border-radius: 16px; }
  .mef-portage__form { padding-bottom: 8px; }
  .mef-portage__tabs button { font-size: 10px; }
  .mef-portage__field { grid-template-columns: 1fr; gap: 8px; }
  .mef-portage__number { width: 100%; }
  .mef-portage__number input { flex: 1; width: auto; text-align: left; }
  .mef-portage__range, .mef-portage__field small { grid-column: 1; }
  .mef-portage__benefits ul { grid-template-columns: 1fr; }
  .mef-portage__breakdown dt { font-size: 10px; }
  .mef-portage__breakdown dd { font-size: 11px; }
}
