/* Deal Seeker BRRRR live-parity presentation v16.
   Page-scoped to .ds-calc-brrrr. No shared-site rules. */

.ds-calc-brrrr {
  --b16-purple:#7657b5;
  --b16-teal:#26a596;
  --b16-blue:#5d98d0;
  --b16-gold:#dfad56;
  --b16-ink:#0f1b2d;
  --b16-muted:#526573;
  --b16-border:#cbdce3;
  --b16-surface:#ffffff;
  --b16-soft:#f5faf8;
  --b16-shadow:0 12px 28px rgba(19,46,48,.07);
}

html[data-theme="dark"] .ds-calc-brrrr {
  --b16-ink:#f7f4ec;
  --b16-muted:#cbc5b8;
  --b16-border:#514e42;
  --b16-surface:#24231c;
  --b16-soft:#2e2c24;
  --b16-shadow:0 12px 28px rgba(0,0,0,.22);
}

/* ---------- HERO LIVE FEEDBACK ---------- */
.ds-calc-brrrr .mc-intro-aside{
  position:relative;
  overflow:hidden;
  animation:none!important;
  background:linear-gradient(145deg,#fff 0%,#fbfdff 48%,#f7fbfa 100%);
  border-color:#c5d7de;
  box-shadow:0 10px 24px rgba(19,46,48,.09)!important;
}
.ds-calc-brrrr .mc-intro-aside::before,
.ds-calc-brrrr .mc-intro-aside::after{
  content:"";
  position:absolute;
  border-radius:50%;
  pointer-events:none;
  opacity:.65;
}
.ds-calc-brrrr .mc-intro-aside::before{
  width:150px;height:150px;right:-34px;top:-42px;
  background:radial-gradient(circle at center,rgba(142,186,232,.22),rgba(142,186,232,0) 70%);
}
.ds-calc-brrrr .mc-intro-aside::after{
  width:170px;height:170px;left:-55px;bottom:-90px;
  background:radial-gradient(circle at center,rgba(183,157,219,.12),rgba(183,157,219,0) 72%);
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-pill{
  position:relative;z-index:1;padding-left:30px;background:#eaf6f2;color:#174d3c;
  box-shadow:0 2px 8px rgba(19,46,48,.04);
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-pill::before{
  content:"";position:absolute;left:12px;top:50%;width:8px;height:8px;border-radius:50%;
  background:#18a878;transform:translateY(-50%);box-shadow:0 0 0 0 rgba(24,168,120,.35);
  animation:b16LivePulse 1.8s ease-out infinite;
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-grid{position:relative;z-index:1}
.ds-calc-brrrr .mc-intro-aside .mc-aside-grid span{
  position:relative;z-index:1;border:1px solid var(--card-border-rest,#d7e6e1);
  background:var(--card-bg-rest,#f3f8f6);color:var(--card-text-rest,#27584d);
  transition:background .25s ease,border-color .25s ease,box-shadow .25s ease,color .25s ease,transform .25s ease;
  animation:b16PhaseSignal 6.4s ease-in-out infinite;
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(1){
  --card-bg-rest:#f6f1fd;--card-border-rest:#e0d5f4;--card-text-rest:#6645a0;
  --card-bg-active:#eee5fc;--card-border-active:#bb9be7;--card-text-active:#533585;--card-shadow-active:rgba(109,78,173,.18);animation-delay:0s;
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(2){
  --card-bg-rest:#eefaf7;--card-border-rest:#cfeee4;--card-text-rest:#1f8677;
  --card-bg-active:#def7f2;--card-border-active:#71cdc0;--card-text-active:#156e62;--card-shadow-active:rgba(37,148,133,.18);animation-delay:1.6s;
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(3){
  --card-bg-rest:#eef5fe;--card-border-rest:#d1e2f7;--card-text-rest:#336eab;
  --card-bg-active:#e4f0fe;--card-border-active:#8fb8e7;--card-text-active:#285d95;--card-shadow-active:rgba(52,110,171,.16);animation-delay:3.2s;
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(4){
  --card-bg-rest:#fff7e9;--card-border-rest:#f4e1b8;--card-text-rest:#a4670b;
  --card-bg-active:#fff0d3;--card-border-active:#e7bc6d;--card-text-active:#925b07;--card-shadow-active:rgba(201,145,49,.18);animation-delay:4.8s;
}
.ds-calc-brrrr .mc-intro-aside .mc-aside-grid::after{
  content:"";position:absolute;left:0;right:0;bottom:-9px;height:4px;border-radius:999px;
  background:linear-gradient(90deg,var(--b16-purple) 0 25%,var(--b16-teal) 25% 50%,var(--b16-blue) 50% 75%,var(--b16-gold) 75% 100%);
  background-size:400% 100%;animation:b16ProgressSweep 6.4s linear infinite;opacity:.9;
}
.ds-calc-brrrr .mc-intro-aside p{position:relative;z-index:1}

@keyframes b16LivePulse{0%{box-shadow:0 0 0 0 rgba(24,168,120,.38)}70%{box-shadow:0 0 0 8px rgba(24,168,120,0)}100%{box-shadow:0 0 0 0 rgba(24,168,120,0)}}
@keyframes b16PhaseSignal{
  0%,12%,100%{background:var(--card-bg-rest);border-color:var(--card-border-rest);box-shadow:none;color:var(--card-text-rest);transform:translateY(0) scale(1)}
  18%,34%{background:var(--card-bg-active);border-color:var(--card-border-active);box-shadow:0 7px 16px var(--card-shadow-active);color:var(--card-text-active);transform:translateY(-1px) scale(1.01)}
  42%,100%{background:var(--card-bg-rest);border-color:var(--card-border-rest);box-shadow:none;color:var(--card-text-rest);transform:translateY(0) scale(1)}
}
@keyframes b16ProgressSweep{0%{background-position:100% 0}100%{background-position:0 0}}

html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside{background:linear-gradient(145deg,#242720 0%,#272823 48%,#21251f 100%);border-color:#4f5a55;box-shadow:0 10px 24px rgba(0,0,0,.22)!important}
html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside::before{background:radial-gradient(circle at center,rgba(93,152,208,.18),rgba(93,152,208,0) 70%)}
html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside::after{background:radial-gradient(circle at center,rgba(118,87,181,.14),rgba(118,87,181,0) 72%)}
html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside .mc-aside-pill{background:#2d372f;color:#d5f5e7;box-shadow:none}
html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(1){--card-bg-rest:#2f293a;--card-border-rest:#4f4268;--card-text-rest:#d8c8fb;--card-bg-active:#4b3a67;--card-border-active:#8b6bc7;--card-text-active:#f5ecff;--card-shadow-active:rgba(0,0,0,.20)}
html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(2){--card-bg-rest:#1f342f;--card-border-rest:#335850;--card-text-rest:#9ae8d9;--card-bg-active:#28554b;--card-border-active:#47a898;--card-text-active:#defcf4;--card-shadow-active:rgba(0,0,0,.20)}
html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(3){--card-bg-rest:#223241;--card-border-rest:#355272;--card-text-rest:#afd5fb;--card-bg-active:#2f4f71;--card-border-active:#6597d3;--card-text-active:#eef7ff;--card-shadow-active:rgba(0,0,0,.20)}
html[data-theme="dark"] .ds-calc-brrrr .mc-intro-aside .mc-aside-grid span:nth-child(4){--card-bg-rest:#3a2f1d;--card-border-rest:#635136;--card-text-rest:#f0d39d;--card-bg-active:#664b20;--card-border-active:#c4933e;--card-text-active:#fff5df;--card-shadow-active:rgba(0,0,0,.20)}

/* ---------- EXISTING TOPBAR, REFINED ---------- */
.ds-calc-brrrr #calcRoot > .calc-topbar{
  margin:0 0 14px!important;padding:16px 18px!important;border:1px solid var(--b16-border)!important;border-radius:16px!important;
  background:var(--b16-surface)!important;box-shadow:var(--b16-shadow)!important;
}
.ds-calc-brrrr #calcRoot > .calc-topbar h2{margin:2px 0 4px!important;font-size:22px!important;color:var(--b16-ink)!important}
.ds-calc-brrrr #calcRoot > .calc-topbar p{margin:0!important;color:var(--b16-muted)!important}

/* ---------- PHASE NAV ---------- */
.ds-calc-brrrr .brrrr-v16-phase-nav{
  margin:0 0 16px;padding:15px 17px 18px;border:1px solid var(--b16-border);border-radius:18px;background:var(--b16-surface);box-shadow:var(--b16-shadow)
}
.ds-calc-brrrr .brrrr-v16-phase-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.ds-calc-brrrr .brrrr-v16-step{
  position:relative;display:flex;align-items:center;gap:11px;min-width:0;min-height:72px;padding:12px;border:1px solid var(--b16-border);
  border-radius:13px;background:#fff;color:var(--b16-ink);text-align:left;transition:transform .16s ease,border-color .16s ease,box-shadow .16s ease,background .16s ease
}
.ds-calc-brrrr .brrrr-v16-step:hover{transform:translateY(-1px);box-shadow:0 7px 18px rgba(19,46,48,.07)}
.ds-calc-brrrr .brrrr-v16-step-num{width:44px;height:44px;flex:0 0 44px;display:grid;place-items:center;border-radius:13px;color:#fff;font-size:17px;font-weight:800;box-shadow:inset 0 0 0 4px rgba(255,255,255,.18)}
.ds-calc-brrrr .phase-buy .brrrr-v16-step-num{background:var(--b16-purple)}
.ds-calc-brrrr .phase-rehab .brrrr-v16-step-num{background:var(--b16-teal)}
.ds-calc-brrrr .phase-rent .brrrr-v16-step-num{background:var(--b16-blue)}
.ds-calc-brrrr .phase-refi .brrrr-v16-step-num{background:var(--b16-gold)}
.ds-calc-brrrr .brrrr-v16-step-copy{min-width:0;display:block}
.ds-calc-brrrr .brrrr-v16-step-title{display:block;font-size:14px;line-height:1.25;color:var(--b16-ink)}
.ds-calc-brrrr .brrrr-v16-step-sub{display:block;margin-top:3px;font-size:11px;line-height:1.25;color:var(--b16-muted);white-space:normal}
.ds-calc-brrrr .brrrr-v16-step-check{position:absolute;right:-5px;top:-7px;width:25px;height:25px;border-radius:50%;display:grid;place-items:center;background:#12836f;color:#fff;font-size:13px;font-weight:900;box-shadow:0 5px 12px rgba(18,131,111,.28);opacity:0;transform:scale(.65);transition:.2s ease}
.ds-calc-brrrr .brrrr-v16-step.is-reviewed .brrrr-v16-step-check{opacity:1;transform:scale(1)}
.ds-calc-brrrr .brrrr-v16-step.is-active.phase-buy{background:#faf7ff;border-color:#bda9df}
.ds-calc-brrrr .brrrr-v16-step.is-active.phase-rehab{background:#f1fbf8;border-color:#8bd5c8}
.ds-calc-brrrr .brrrr-v16-step.is-active.phase-rent{background:#f2f8fe;border-color:#9bc2e5}
.ds-calc-brrrr .brrrr-v16-step.is-active.phase-refi{background:#fff8eb;border-color:#ebc77e}
.ds-calc-brrrr .brrrr-v16-progress-track{height:7px;margin-top:14px;border-radius:999px;background:#edf2f1;overflow:hidden}
.ds-calc-brrrr .brrrr-v16-progress-fill{height:100%;width:25%;border-radius:999px;background:linear-gradient(90deg,#14856f,#39ad9b);transition:width .3s ease}

html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-step{background:#2b2a22;border-color:#555145;color:#f7f4ec}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-step-title{color:#f7f4ec}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-step-sub{color:#cfc9bd}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-step.is-active.phase-buy{background:#372e47;border-color:#7f6aa3}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-step.is-active.phase-rehab{background:#263c36;border-color:#4b927f}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-step.is-active.phase-rent{background:#293745;border-color:#587da1}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-step.is-active.phase-refi{background:#3b3120;border-color:#98753b}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-progress-track{background:#36342b}

/* ---------- XP / RANK ---------- */
.ds-calc-brrrr .brrrr-v16-xp{
  display:flex;align-items:center;gap:18px;margin:0 0 18px;padding:14px 18px;border:1px solid var(--b16-border);border-radius:18px;background:var(--b16-surface);box-shadow:var(--b16-shadow)
}
.ds-calc-brrrr .brrrr-v16-rank{display:flex;align-items:center;gap:12px;min-width:155px}
.ds-calc-brrrr .brrrr-v16-rank-icon{width:50px;height:50px;display:grid;place-items:center;border-radius:15px;background:linear-gradient(135deg,#158873,#28aa96);color:#fff;font-size:22px;box-shadow:0 7px 16px rgba(21,136,115,.19)}
.ds-calc-brrrr .brrrr-v16-rank-copy{display:flex;flex-direction:column}
.ds-calc-brrrr .brrrr-v16-rank-name{font-size:15px;line-height:1.2;color:var(--b16-ink)}
.ds-calc-brrrr .brrrr-v16-rank-sub{margin-top:3px;font-size:11px;font-weight:700;color:var(--b16-muted)}
.ds-calc-brrrr .brrrr-v16-xp-progress{flex:1;min-width:0}
.ds-calc-brrrr .brrrr-v16-xp-track{height:9px;border:1px solid #c8dcda;border-radius:999px;background:#edf5f3;overflow:hidden}
.ds-calc-brrrr .brrrr-v16-xp-fill{height:100%;width:0;border-radius:999px;background:linear-gradient(90deg,#158873,#33b3a0);transition:width .4s ease}
.ds-calc-brrrr .brrrr-v16-xp-labels{display:flex;justify-content:space-between;gap:12px;margin-top:6px;font-size:10.5px;font-weight:800;color:var(--b16-muted)}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-xp-track{border-color:#565246;background:#35332a}

/* ---------- MAIN WORKSPACE ---------- */
.ds-calc-brrrr .brrrr-v16-workspace{display:grid;grid-template-columns:minmax(0,1.75fr) minmax(360px,.72fr);gap:20px;align-items:start;margin-bottom:18px;overflow:visible!important}
.ds-calc-brrrr .brrrr-v16-form-column{min-width:0;overflow:visible!important}
.ds-calc-brrrr .brrrr-v16-rail{position:sticky;top:18px;display:grid;gap:14px;align-self:start;min-width:0;z-index:4}
.ds-calc-brrrr #calcForm{display:grid;gap:18px}

/* ---------- PHASE SHELLS ---------- */
.ds-calc-brrrr .brrrr-v16-phase{border:1px solid var(--b16-border);border-radius:18px;background:var(--b16-surface);box-shadow:var(--b16-shadow);overflow:hidden;scroll-margin-top:18px}
.ds-calc-brrrr .brrrr-v16-phase-head{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:13px;padding:18px 22px;border-bottom:1px solid var(--b16-border);background:var(--b16-surface)}
.ds-calc-brrrr .brrrr-v16-phase-icon{width:48px;height:48px;display:grid;place-items:center;border-radius:14px;color:#fff;font-size:18px;font-weight:800}
.ds-calc-brrrr .phase-buy .brrrr-v16-phase-icon{background:var(--b16-purple)}
.ds-calc-brrrr .phase-rehab .brrrr-v16-phase-icon{background:var(--b16-teal)}
.ds-calc-brrrr .phase-rent .brrrr-v16-phase-icon{background:var(--b16-blue)}
.ds-calc-brrrr .phase-refi .brrrr-v16-phase-icon{background:var(--b16-gold)}
.ds-calc-brrrr .brrrr-v16-phase-copy h2{margin:0!important;color:var(--b16-ink)!important;font-size:21px!important;line-height:1.2!important}
.ds-calc-brrrr .brrrr-v16-phase-copy p{margin:4px 0 0!important;color:var(--b16-muted)!important;font-size:12px!important}
.ds-calc-brrrr .brrrr-v16-phase-toggle{width:38px;height:38px;border:0;border-radius:10px;background:transparent;color:var(--b16-muted);font-size:18px;font-weight:800}
.ds-calc-brrrr .brrrr-v16-phase-toggle:hover{background:var(--b16-soft)}
.ds-calc-brrrr .brrrr-v16-phase.is-collapsed .brrrr-v16-phase-body{display:none}
.ds-calc-brrrr .brrrr-v16-phase-body{padding:0 22px 20px}

/* Flatten the engine-rendered cards inside each phase into one coherent phase card. */
.ds-calc-brrrr .brrrr-v16-phase-body > .calc-card{
  margin:0!important;padding:22px 0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important
}
.ds-calc-brrrr .brrrr-v16-phase-body > .calc-card + .calc-card{border-top:1px solid #e2eaed!important}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-phase-body > .calc-card + .calc-card{border-top-color:#4a473c!important}
.ds-calc-brrrr .brrrr-v16-phase-body > .calc-card h2{margin:0 0 5px!important;font-size:18px!important;color:var(--b16-ink)!important}
.ds-calc-brrrr .brrrr-v16-phase-body > .calc-card .card-sub{margin-bottom:18px!important;color:var(--b16-muted)!important}
.ds-calc-brrrr .brrrr-v16-phase-body .grid{gap:16px 20px!important}
.ds-calc-brrrr .brrrr-v16-phase-body .field label{font-weight:700!important;color:var(--b16-ink)!important}
.ds-calc-brrrr .brrrr-v16-phase-body input:not([type="checkbox"]),
.ds-calc-brrrr .brrrr-v16-phase-body select{border-radius:10px!important;min-height:46px!important}
.ds-calc-brrrr .brrrr-v16-phase-body input[type="number"]{-moz-appearance:textfield}
.ds-calc-brrrr .brrrr-v16-phase-body input[type="number"]::-webkit-inner-spin-button,
.ds-calc-brrrr .brrrr-v16-phase-body input[type="number"]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}

/* ---------- CAPITAL CARD ---------- */
.ds-calc-brrrr .brrrr-v16-capital{
  position:relative;overflow:hidden;padding:26px 26px 24px;border:1px solid #bad8d2;border-radius:19px;
  background:linear-gradient(145deg,#eff9f6 0%,#f8fbfa 66%,#eef7fb 100%);box-shadow:var(--b16-shadow)
}
.ds-calc-brrrr .brrrr-v16-capital::after{content:"";position:absolute;width:190px;height:190px;right:-78px;top:-92px;border-radius:50%;background:rgba(55,158,143,.08)}
.ds-calc-brrrr .brrrr-v16-capital-kicker{position:relative;z-index:1;font-size:11px;font-weight:800;letter-spacing:.13em;text-transform:uppercase;color:#45655e}
.ds-calc-brrrr .brrrr-v16-capital-value{position:relative;z-index:1;margin-top:4px;font-size:clamp(42px,4vw,58px);font-weight:800;line-height:1;letter-spacing:-.045em;color:#0f1b2d}
.ds-calc-brrrr .brrrr-v16-capital-sub{position:relative;z-index:1;margin-top:6px;font-size:12px;color:#59706b}
.ds-calc-brrrr .brrrr-v16-capital-stats{position:relative;z-index:1;display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:19px}
.ds-calc-brrrr .brrrr-v16-capital-stat{min-width:0;padding:13px 14px;border:1px solid #c9ddd8;border-radius:12px;background:rgba(255,255,255,.72)}
.ds-calc-brrrr .brrrr-v16-capital-stat small{display:block;font-size:9.5px;letter-spacing:.07em;text-transform:uppercase;color:#61716f}
.ds-calc-brrrr .brrrr-v16-capital-stat strong{display:block;margin-top:5px;font-size:19px;line-height:1.2;color:#0f1b2d;overflow-wrap:anywhere}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital{background:linear-gradient(145deg,#2a2a23,#24231c 65%,#222a2a);border-color:#5c594c}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital::after{background:rgba(86,176,153,.08)}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital-kicker{color:#b8d8ca}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital-value,html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital-stat strong{color:#f7f4ec}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital-sub,html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital-stat small{color:#d0cabc}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-capital-stat{background:#302f27;border-color:#5c584b}

/* ---------- LIVE SUMMARY STRIP ---------- */
.ds-calc-brrrr #calcStrip.brrrr-v16-summary{
  display:grid!important;grid-template-columns:1fr 1fr!important;grid-auto-flow:row!important;gap:12px!important;margin:0!important;padding:16px!important;
  border:1px solid var(--b16-border)!important;border-radius:18px!important;background:var(--b16-surface)!important;box-shadow:var(--b16-shadow)!important
}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell{min-width:0!important;width:auto!important;max-width:none!important;min-height:132px!important;padding:17px!important;border:1px solid #cbdde4!important;border-radius:14px!important;background:#eef7fb!important;overflow:hidden!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell:nth-of-type(2){background:#f3ecff!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell:nth-of-type(3){background:#eaf7f1!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell:nth-of-type(4){background:#fff4df!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary .vlabel{font-size:11px!important;line-height:1.25!important;font-weight:800!important;color:#203a50!important;text-transform:uppercase!important;letter-spacing:.02em!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary .vvalue{margin-top:14px!important;font-size:27px!important;line-height:1.05!important;font-weight:800!important;color:#10243a!important;overflow-wrap:anywhere}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary .vsub{margin-top:8px!important;font-size:11px!important;line-height:1.35!important;color:#425a69!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary .badge-row{display:grid!important;gap:8px!important;margin-top:12px!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary .badge{display:flex!important;align-items:center!important;justify-content:space-between!important;width:100%!important;min-height:36px!important;padding:7px 10px!important;border-radius:10px!important;white-space:normal!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary > .deal-verdict-row{grid-column:1/-1!important;margin:0!important;padding:14px 16px!important;border-radius:13px!important;min-height:auto!important}
.ds-calc-brrrr #calcStrip.brrrr-v16-summary .deal-verdict-title{font-weight:800!important}
html[data-theme="dark"] .ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell{background:#213642!important;border-color:#46606d!important}
html[data-theme="dark"] .ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell:nth-of-type(2){background:#342b49!important;border-color:#5c4d77!important}
html[data-theme="dark"] .ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell:nth-of-type(3){background:#263b34!important;border-color:#46665a!important}
html[data-theme="dark"] .ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell:nth-of-type(4){background:#44351e!important;border-color:#695431!important}
html[data-theme="dark"] .ds-calc-brrrr #calcStrip.brrrr-v16-summary :is(.vlabel,.vvalue){color:#f7f4ec!important}
html[data-theme="dark"] .ds-calc-brrrr #calcStrip.brrrr-v16-summary .vsub{color:#d3ccbf!important}

/* ---------- ACHIEVEMENTS ---------- */
.ds-calc-brrrr .brrrr-v16-achievements{border:1px solid var(--b16-border);border-radius:17px;background:var(--b16-surface);box-shadow:var(--b16-shadow);overflow:hidden}
.ds-calc-brrrr .brrrr-v16-achievements > summary{list-style:none;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:15px 17px;cursor:pointer;font-size:13px;font-weight:800;color:var(--b16-ink)}
.ds-calc-brrrr .brrrr-v16-achievements > summary::-webkit-details-marker{display:none}
.ds-calc-brrrr .brrrr-v16-achievements > summary::after{content:"＋";margin-left:auto;color:var(--b16-muted);font-size:17px}
.ds-calc-brrrr .brrrr-v16-achievements[open] > summary::after{content:"−"}
.ds-calc-brrrr .brrrr-v16-ach-count{margin-left:auto;padding:4px 8px;border-radius:999px;background:#eef6f4;color:#187664;font-size:10px}
.ds-calc-brrrr .brrrr-v16-ach-body{padding:0 15px 15px}
.ds-calc-brrrr .brrrr-v16-ach-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.ds-calc-brrrr .brrrr-v16-achievement{display:grid;grid-template-columns:auto 1fr;column-gap:8px;row-gap:2px;padding:10px;border:1px solid var(--b16-border);border-radius:12px;background:var(--b16-soft);opacity:.45;filter:grayscale(.85);transition:.2s ease}
.ds-calc-brrrr .brrrr-v16-achievement.is-unlocked{opacity:1;filter:none;border-color:#8acdb6;background:#eff8f4;box-shadow:0 5px 12px rgba(20,121,102,.08)}
.ds-calc-brrrr .brrrr-v16-ach-icon{grid-row:1/3;font-size:19px}
.ds-calc-brrrr .brrrr-v16-ach-name{font-size:10.5px;line-height:1.2;color:var(--b16-ink)}
.ds-calc-brrrr .brrrr-v16-ach-tip{font-size:9.5px;line-height:1.3;color:var(--b16-muted)}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-ach-count{background:#294039;color:#a4e5c5}
html[data-theme="dark"] .ds-calc-brrrr .brrrr-v16-achievement.is-unlocked{background:#263b34;border-color:#4c7c6a}

/* ---------- DETAILED RESULTS ---------- */
.ds-calc-brrrr .brrrr-v16-details{margin-top:18px}
.ds-calc-brrrr .brrrr-v16-details #calcResults{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.ds-calc-brrrr .brrrr-v16-details #calcResults > .calc-card{margin:0!important;border-radius:18px!important;box-shadow:var(--b16-shadow)!important}
.ds-calc-brrrr .brrrr-v16-details #calcResults > .brrrr-v16-primary-source{display:none!important}
.ds-calc-brrrr .brrrr-v16-details #calcResults > .ff-stress-card,
.ds-calc-brrrr .brrrr-v16-details #calcResults > .calc-card:last-child{grid-column:1/-1}

/* ---------- TOAST / MASTER CELEBRATION ---------- */
.ds-calc-brrrr .brrrr-v16-toast-layer{position:fixed;right:18px;bottom:18px;z-index:120;display:flex;flex-direction:column;gap:8px;pointer-events:none}
.brrrr-v16-toast-layer{position:fixed;right:18px;bottom:18px;z-index:120;display:flex;flex-direction:column;gap:8px;pointer-events:none}
.brrrr-v16-toast{display:flex;align-items:center;gap:9px;max-width:310px;padding:10px 12px;border:1px solid #cadce2;border-radius:12px;background:#fff;color:#0f1b2d;box-shadow:0 10px 24px rgba(15,27,45,.16);opacity:0;transform:translateY(8px);transition:.2s ease}
.brrrr-v16-toast.show{opacity:1;transform:translateY(0)}
.brrrr-v16-toast-icon{font-size:18px}.brrrr-v16-toast-text{font-size:12px;font-weight:700}.brrrr-v16-toast-xp{margin-left:auto;padding:3px 7px;border-radius:999px;background:#e7f5ef;color:#147966;font-size:10px;font-weight:800}
html[data-theme="dark"] .brrrr-v16-toast{background:#24231c;border-color:#514e42;color:#f7f4ec}
.brrrr-v16-confetti{position:fixed;inset:0;z-index:125;pointer-events:none;overflow:hidden}.brrrr-v16-confetti i{position:absolute;top:22vh;width:8px;height:12px;border-radius:2px;animation:b16Confetti var(--dur,1s) ease-out forwards}
@keyframes b16Confetti{0%{opacity:1;transform:translate(0,0) rotate(0)}100%{opacity:0;transform:translate(var(--dx),420px) rotate(var(--rot))}}

/* ---------- MOBILE / TABLET ---------- */
@media(max-width:1100px){
  .ds-calc-brrrr .brrrr-v16-workspace{grid-template-columns:1fr}
  .ds-calc-brrrr .brrrr-v16-rail{position:static;top:auto;z-index:auto}
  .ds-calc-brrrr .brrrr-v16-details #calcResults{grid-template-columns:1fr}
  .ds-calc-brrrr .brrrr-v16-details #calcResults > .ff-stress-card,.ds-calc-brrrr .brrrr-v16-details #calcResults > .calc-card:last-child{grid-column:auto}
}
@media(max-width:760px){
  .ds-calc-brrrr .brrrr-v16-phase-grid{grid-template-columns:1fr 1fr;gap:8px}
  .ds-calc-brrrr .brrrr-v16-step{min-height:62px;padding:9px}
  .ds-calc-brrrr .brrrr-v16-step-num{width:38px;height:38px;flex-basis:38px;border-radius:11px;font-size:15px}
  .ds-calc-brrrr .brrrr-v16-step-title{font-size:12.5px}
  .ds-calc-brrrr .brrrr-v16-step-sub{font-size:9.5px}
  .ds-calc-brrrr .brrrr-v16-xp{align-items:flex-start;flex-direction:column;gap:12px;padding:13px 14px}
  .ds-calc-brrrr .brrrr-v16-rank{min-width:0}
  .ds-calc-brrrr .brrrr-v16-xp-progress{width:100%}
  .ds-calc-brrrr .brrrr-v16-phase-head{padding:15px 14px;grid-template-columns:auto 1fr auto;gap:10px}
  .ds-calc-brrrr .brrrr-v16-phase-icon{width:42px;height:42px;border-radius:12px}
  .ds-calc-brrrr .brrrr-v16-phase-copy h2{font-size:18px!important}
  .ds-calc-brrrr .brrrr-v16-phase-copy p{font-size:10.5px!important}
  .ds-calc-brrrr .brrrr-v16-phase-body{padding:0 14px 14px}
  .ds-calc-brrrr .brrrr-v16-phase-body > .calc-card{padding:17px 0!important}
  .ds-calc-brrrr .brrrr-v16-phase-body .grid{grid-template-columns:1fr!important;gap:13px!important}
  .ds-calc-brrrr .brrrr-v16-capital{padding:21px 18px}
  .ds-calc-brrrr .brrrr-v16-capital-value{font-size:44px}
  .ds-calc-brrrr .brrrr-v16-capital-stats{gap:8px}
  .ds-calc-brrrr .brrrr-v16-capital-stat{padding:11px}
  .ds-calc-brrrr .brrrr-v16-capital-stat strong{font-size:16px}
  .ds-calc-brrrr #calcStrip.brrrr-v16-summary{padding:12px!important;gap:9px!important}
  .ds-calc-brrrr #calcStrip.brrrr-v16-summary > .vcell{min-height:118px!important;padding:13px!important}
  .ds-calc-brrrr #calcStrip.brrrr-v16-summary .vlabel{font-size:10px!important}
  .ds-calc-brrrr #calcStrip.brrrr-v16-summary .vvalue{font-size:22px!important}
  .ds-calc-brrrr .brrrr-v16-ach-grid{grid-template-columns:1fr}
}
@media(max-width:420px){
  .ds-calc-brrrr .brrrr-v16-phase-grid{grid-template-columns:1fr 1fr}
  .ds-calc-brrrr .brrrr-v16-step-sub{display:none}
  .ds-calc-brrrr .brrrr-v16-step{min-height:54px}
  .ds-calc-brrrr .brrrr-v16-capital-stats{grid-template-columns:1fr 1fr}
  .ds-calc-brrrr #calcStrip.brrrr-v16-summary{grid-template-columns:1fr 1fr!important}
}

@media(prefers-reduced-motion:reduce){
  .ds-calc-brrrr .mc-intro-aside .mc-aside-pill::before,
  .ds-calc-brrrr .mc-intro-aside .mc-aside-grid span,
  .ds-calc-brrrr .mc-intro-aside .mc-aside-grid::after,
  .brrrr-v16-confetti i{animation:none!important}
}

/* =========================================================
   v17 parity correction
   Purpose: make the production BRRRR presentation visually
   match the approved live-parity prototype while leaving the
   calculator engine and generated inputs untouched.
   ========================================================= */

/* Phase navigator: always light in LIGHT theme. The previous live
   build was inheriting a dark treatment that visually matched an
   older prototype instead of the approved version. */
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-phase-nav{
  background:#fff!important;
  border-color:#cbdce3!important;
  box-shadow:0 10px 24px rgba(19,46,48,.055)!important;
}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-step{
  background:#fff!important;
  border:1px solid #d3e1e6!important;
  color:#0f1b2d!important;
  box-shadow:none!important;
}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-step-title{color:#0f1b2d!important}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-step-sub{color:#536777!important}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-step.is-active.phase-buy{background:#faf7ff!important;border-color:#bda9df!important}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-step.is-active.phase-rehab{background:#f1fbf8!important;border-color:#8bd5c8!important}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-step.is-active.phase-rent{background:#f2f8fe!important;border-color:#9bc2e5!important}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-step.is-active.phase-refi{background:#fff8eb!important;border-color:#ebc77e!important}
html:not([data-theme="dark"]) body.ds-calc-brrrr .brrrr-v16-progress-track{background:#edf3f1!important}

/* Main proportions from the approved prototype. */
body.ds-calc-brrrr .brrrr-v16-workspace{
  grid-template-columns:minmax(0,1.62fr) minmax(350px,.78fr)!important;
  gap:20px!important;
}

/* Phase containers are the card. Engine-created section cards should
   no longer look like nested cards inside them. */
body.ds-calc-brrrr .brrrr-v16-phase{
  border-radius:18px!important;
  background:var(--b16-surface)!important;
  overflow:hidden!important;
}
body.ds-calc-brrrr .brrrr-v16-phase-body{
  padding:0 24px 18px!important;
  background:var(--b16-surface)!important;
}
body.ds-calc-brrrr .brrrr-v16-phase-body .card.ff-card.calc-card,
body.ds-calc-brrrr .brrrr-v16-phase-body .calc-card{
  margin:0!important;
  padding:21px 0!important;
  border:0!important;
  outline:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
}
body.ds-calc-brrrr .brrrr-v16-phase-body .card.ff-card.calc-card + .card.ff-card.calc-card,
body.ds-calc-brrrr .brrrr-v16-phase-body .calc-card + .calc-card{
  border-top:1px solid #e0e9ed!important;
}
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v16-phase-body .calc-card + .calc-card{
  border-top-color:#49463c!important;
}
/* The phase header already names the workflow step. Removing the large
   nested section headings is what makes the live page match the approved
   prototype instead of looking like one calculator embedded inside another. */
body.ds-calc-brrrr .brrrr-v16-phase-body .calc-card > h2,
body.ds-calc-brrrr .brrrr-v16-phase-body .calc-card > .card-sub{
  display:none!important;
}
body.ds-calc-brrrr .brrrr-v16-phase-body .grid{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:16px 24px!important;
}
body.ds-calc-brrrr .brrrr-v16-phase-body .field{min-width:0!important}
body.ds-calc-brrrr .brrrr-v16-phase-body .field label{
  margin-bottom:7px!important;
  font-size:13px!important;
  line-height:1.35!important;
}
body.ds-calc-brrrr .brrrr-v16-phase-body input:not([type="checkbox"]),
body.ds-calc-brrrr .brrrr-v16-phase-body select{
  min-height:48px!important;
  border-radius:10px!important;
  font-size:14px!important;
}
body.ds-calc-brrrr .brrrr-v16-phase-body .field .hint,
body.ds-calc-brrrr .brrrr-v16-phase-body .hint{
  font-size:11.5px!important;
  line-height:1.4!important;
}

/* The approved prototype shows Capital Recycled followed directly by the
   verdict. Keep the original summary strip alive in the DOM for production
   calculations/data binding, but not as a second competing visual panel. */
body.ds-calc-brrrr #calcStrip.brrrr-v16-summary{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  padding:0!important;
  margin:-1px!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  clip-path:inset(50%)!important;
  white-space:nowrap!important;
  border:0!important;
  box-shadow:none!important;
}
body.ds-calc-brrrr .brrrr-v17-verdict{
  display:grid;
  grid-template-columns:auto minmax(0,1fr);
  gap:12px 14px;
  align-items:start;
  padding:20px 20px;
  border:1px solid #91d4b8;
  border-radius:18px;
  background:#e8f4ed;
  box-shadow:0 10px 24px rgba(19,46,48,.06);
  color:#0f1b2d;
}
body.ds-calc-brrrr .brrrr-v17-verdict-icon{
  width:40px;height:40px;border-radius:12px;display:grid;place-items:center;
  background:#158873;color:#fff;font-size:20px;font-weight:900;
}
body.ds-calc-brrrr .brrrr-v17-verdict-copy{min-width:0;padding-top:2px}
body.ds-calc-brrrr .brrrr-v17-verdict-title{
  margin:0;font-size:15.5px;line-height:1.3;font-weight:800;color:#0f1b2d;
}
body.ds-calc-brrrr .brrrr-v17-verdict-reason{
  margin-top:8px;font-size:12px;line-height:1.55;color:#47665f;
}
body.ds-calc-brrrr .brrrr-v17-verdict.is-poor,
body.ds-calc-brrrr .brrrr-v17-verdict.is-weak,
body.ds-calc-brrrr .brrrr-v17-verdict.is-bad{
  border-color:#e0a390;background:#f8ebe6;
}
body.ds-calc-brrrr .brrrr-v17-verdict.is-poor .brrrr-v17-verdict-icon,
body.ds-calc-brrrr .brrrr-v17-verdict.is-weak .brrrr-v17-verdict-icon,
body.ds-calc-brrrr .brrrr-v17-verdict.is-bad .brrrr-v17-verdict-icon{background:#b75a40}
body.ds-calc-brrrr .brrrr-v17-verdict.is-poor .brrrr-v17-verdict-reason,
body.ds-calc-brrrr .brrrr-v17-verdict.is-weak .brrrr-v17-verdict-reason,
body.ds-calc-brrrr .brrrr-v17-verdict.is-bad .brrrr-v17-verdict-reason{color:#765044}
body.ds-calc-brrrr .brrrr-v17-verdict.is-loading,
body.ds-calc-brrrr .brrrr-v17-verdict.is-unavailable,
body.ds-calc-brrrr .brrrr-v17-verdict.is-incomplete{
  border-color:#cbdce3;background:#f4f8f7;
}
body.ds-calc-brrrr .brrrr-v17-verdict.is-loading .brrrr-v17-verdict-icon,
body.ds-calc-brrrr .brrrr-v17-verdict.is-unavailable .brrrr-v17-verdict-icon,
body.ds-calc-brrrr .brrrr-v17-verdict.is-incomplete .brrrr-v17-verdict-icon{background:#71818b}
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict{
  background:#263c34;border-color:#477764;color:#f7f4ec;
}
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict-title{color:#f7f4ec}
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict-reason{color:#d1d9d3}
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict.is-poor,
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict.is-weak,
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict.is-bad{background:#432c26;border-color:#7d5144}
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict.is-loading,
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict.is-unavailable,
html[data-theme="dark"] body.ds-calc-brrrr .brrrr-v17-verdict.is-incomplete{background:#2d2c25;border-color:#5a574b}

/* Capital card proportions closer to the approved reference. */
body.ds-calc-brrrr .brrrr-v16-capital{padding:27px 28px 25px!important}
body.ds-calc-brrrr .brrrr-v16-capital-value{font-size:clamp(44px,4vw,60px)!important}
body.ds-calc-brrrr .brrrr-v16-capital-stats{gap:11px!important}
body.ds-calc-brrrr .brrrr-v16-capital-stat{padding:14px 15px!important}

@media(max-width:1050px){
  body.ds-calc-brrrr .brrrr-v16-workspace{grid-template-columns:1fr!important}
  body.ds-calc-brrrr .brrrr-v16-rail{position:static!important}
}
@media(max-width:720px){
  body.ds-calc-brrrr .brrrr-v16-phase-body{padding:0 14px 14px!important}
  body.ds-calc-brrrr .brrrr-v16-phase-body .grid{grid-template-columns:1fr!important;gap:13px!important}
  body.ds-calc-brrrr .brrrr-v17-verdict{padding:16px!important}
}
