/* Rent vs Own — page-specific styling.
   Every colour here resolves through a brand.css custom property so that
   scripts/recolor.py remaps it for a partner build along with everything else.
   Do not write a literal hex in this file. */

/* ---------- assumptions drawer ----------
   Fifteen inputs is too many to show at once, and hiding the interesting ones
   is worse. The six that decide the answer stay visible; the rest live here,
   open to anyone who wants to argue with the defaults. */
.adv{
  margin-top:18px;border-top:1px solid var(--line);padding-top:16px;
}
.adv summary{
  cursor:pointer;list-style:none;font-family:'Manrope',sans-serif;
  font-size:.84rem;font-weight:700;color:var(--franklin-deep);
  display:flex;align-items:baseline;gap:7px;flex-wrap:wrap;
}
.adv summary::-webkit-details-marker{display:none}
.adv summary::before{
  content:"";width:0;height:0;flex:none;align-self:center;
  border-left:5px solid currentColor;border-top:4px solid transparent;
  border-bottom:4px solid transparent;transition:transform .18s ease;
}
.adv[open] summary::before{transform:rotate(90deg)}
.adv summary span{font-weight:400;font-size:.78rem;color:var(--muted-2)}
.adv summary:focus-visible{outline:2px solid var(--franklin);outline-offset:3px;border-radius:4px}
.adv-in{padding-top:14px}
@media (prefers-reduced-motion:reduce){.adv summary::before{transition:none}}

.field-hint{
  display:block;margin-top:5px;font-size:.75rem;line-height:1.45;color:var(--muted-2);
}

/* ---------- break-even panel ---------- */
.be{
  margin-top:20px;background:rgba(255,255,255,.10);border:1px solid rgba(255,255,255,.16);
  border-radius:14px;padding:14px 14px 10px;
}
.be-h{
  display:flex;justify-content:space-between;align-items:baseline;gap:10px;
  font-family:'Manrope',sans-serif;font-size:.72rem;font-weight:700;
  letter-spacing:.12em;text-transform:uppercase;color:rgba(255,255,255,.62);
}
.be-h em{font-style:normal;font-size:.98rem;letter-spacing:0;text-transform:none;color:#fff}
.be-note{margin:6px 0 10px;font-size:.78rem;line-height:1.45;color:rgba(255,255,255,.72)}

#chart{width:100%;height:auto;display:block;overflow:visible}
.c-grid{stroke:rgba(255,255,255,.16);stroke-width:1}
.c-axis{fill:rgba(255,255,255,.55);font-family:'Manrope',sans-serif;font-size:10px}
.c-rent{fill:none;stroke:rgba(255,255,255,.66);stroke-width:2;stroke-dasharray:5 4;
  stroke-linecap:round;stroke-linejoin:round}
.c-own{fill:none;stroke:#fff;stroke-width:2.6;stroke-linecap:round;stroke-linejoin:round}
.c-own-fill{fill:rgba(255,255,255,.13);stroke:none}
.c-be{stroke:rgba(255,255,255,.5);stroke-width:1;stroke-dasharray:3 3}
.c-dot{fill:#fff;stroke:var(--franklin-deep);stroke-width:2}

.c-legend{
  display:flex;gap:16px;flex-wrap:wrap;margin-top:8px;
  font-size:.74rem;color:rgba(255,255,255,.72);
}
.c-legend span{display:inline-flex;align-items:center;gap:6px}
.c-legend i{width:16px;height:0;border-top:2.6px solid #fff;border-radius:2px}
.c-legend .k-rent{border-top:2px dashed rgba(255,255,255,.7)}

/* The headline flips meaning depending on who wins, so it is worth making the
   losing case visually distinct rather than printing a negative number in the
   same triumphant style. */
.result[data-winner="rent"] .bignum{color:var(--gold-tint)}
.result[data-winner="rent"] .c-own{stroke:rgba(255,255,255,.66);stroke-width:2;stroke-dasharray:5 4}
.result[data-winner="rent"] .c-rent{stroke:#fff;stroke-width:2.6;stroke-dasharray:none}
.result[data-winner="rent"] .c-own-fill{fill:rgba(255,255,255,.06)}

@media (max-width:560px){
  .be{padding:12px 11px 9px}
  .c-legend{gap:12px;font-size:.71rem}
}

/* The annual figure beside the monthly one. A $563/mo line reads as rounding;
   the same number as $6,750 a year is what a buyer recognises from their
   return, and it is the whole reason the deduction is worth modelling. */
.row.sub #m-tax-yr{font-style:normal;opacity:.72;font-size:.94em}

/* A dead heat is not a small number, it is a different kind of answer, so it
   gets a different treatment rather than a tiny dollar figure set in the same
   triumphant display size. */
.result[data-winner="tie"] .bignum{font-size:1.85rem;line-height:1.2;letter-spacing:-.02em}
.result[data-winner="tie"] .c-own,
.result[data-winner="tie"] .c-rent{stroke:rgba(255,255,255,.82);stroke-width:2.2;stroke-dasharray:none}
.result[data-winner="tie"] .c-own-fill{fill:rgba(255,255,255,.08)}
@media (max-width:560px){.result[data-winner="tie"] .bignum{font-size:1.55rem}}

/* The two bottom lines are the comparison. Everything above them is working,
   so they get weight the intermediate rows do not. */
.row.tot{
  padding:12px 0;border-bottom:1px solid rgba(255,255,255,.22);
  border-top:1px solid rgba(255,255,255,.22);
}
.row.tot span{font-family:'Manrope',sans-serif;font-weight:700;color:#fff;font-size:.9rem}
.row.tot b{font-size:1.06rem;font-weight:800;color:#fff}

/* When the difference is spent, the return slider still governs the down
   payment, so it stays usable -- but it matters less, and saying so visually
   is more honest than leaving it looking equally load-bearing. */
.field.dim{opacity:.55}
.field.dim:focus-within{opacity:1}

/* ---------- simplified summary ----------
   The panel was twenty-two rows: every intermediate figure in the model, laid
   out like a settlement statement. That is the right amount of detail to audit
   the maths and the wrong amount to answer a question. Most people want two
   numbers -- what it costs a month, and what they end up with -- and get lost
   before they reach either.

   So the summary is now seven rows, and the full reconciliation moved into a
   disclosure below it. Nothing was deleted: anyone who wants to check the
   working still can, and both columns still add up on their own. */
.bd-h{
  font-family:'Manrope',sans-serif;font-size:.66rem;font-weight:700;
  letter-spacing:.14em;text-transform:uppercase;color:rgba(255,255,255,.5);
  margin:20px 0 4px;padding-top:14px;border-top:1px solid rgba(255,255,255,.14);
}
.breakdown > .bd-h:first-child{margin-top:6px;padding-top:0;border-top:0}

.bd-more{margin-top:14px}
.bd-more summary{
  cursor:pointer;list-style:none;display:inline-flex;align-items:center;gap:7px;
  font-family:'Manrope',sans-serif;font-size:.8rem;font-weight:700;
  color:rgba(255,255,255,.78);padding:8px 0;
}
.bd-more summary::-webkit-details-marker{display:none}
.bd-more summary::before{
  content:"";width:0;height:0;flex:none;
  border-left:5px solid currentColor;border-top:4px solid transparent;
  border-bottom:4px solid transparent;transition:transform .18s ease;
}
.bd-more[open] summary::before{transform:rotate(90deg)}
.bd-more summary:hover{color:#fff}
.bd-more summary:focus-visible{outline:2px solid rgba(255,255,255,.7);outline-offset:3px;border-radius:5px}
.bd-detail{margin-top:2px}
@media (prefers-reduced-motion:reduce){.bd-more summary::before{transition:none}}

/* The heading carries what three deleted rows used to say. */
.bd-h em{font-style:normal;text-transform:none;letter-spacing:0;opacity:.8;font-weight:400}
