/* Tools › Working from Home (#wfh). Colours come from styles.css's tokens, so light and dark both work. */
.wfh-panel { margin-bottom: 16px; }
.wfh-form { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); align-items: end; margin-bottom: 12px; }
.wfh-form label { display: grid; gap: 4px; font-size: 12.5px; color: var(--muted); }
.wfh-form input[type=number], .wfh-costs input[type=number] { font: 13px var(--font); color: var(--ink); background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; min-height: 36px; width: 100%; box-sizing: border-box; }
.wfh-h { font-size: 15px; margin: 14px 0 4px; }
.wfh-costs td, .wfh-costs th { text-align: left; }
.wfh-costs td input[type=text] { width: 100%; box-sizing: border-box; min-width: 7rem; }
.wfh-costs small { display: block; color: var(--amber); font-size: 11.5px; margin-top: 2px; }
.wfh-options { margin-top: 14px; display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); margin-top: 8px; }
.wfh-opt { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; background: var(--panel); }
.wfh-opt.wfh-best { border-color: var(--green); background: var(--green-soft); }
.wfh-opt h3 { margin: 0 0 2px; font-size: 14px; }
.wfh-claim { font: 700 26px var(--font); margin: 2px 0 8px; }
.wfh-badge { display: inline-block; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 99px; background: var(--green); color: #fff; margin-left: 6px; vertical-align: middle; }
.wfh-work { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 13px; }
.wfh-work li { display: flex; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); padding-top: 6px; }
.wfh-work small { display: block; color: var(--muted); font-size: 11.5px; }
.wfh-work b { white-space: nowrap; }
#wfh-assume { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 4px; font-size: 13px; }
#wfh-params table td:nth-child(2) { text-align: right; }
.wfh-unv { color: var(--amber); font-size: 12px; font-weight: 600; }
.wfh-costs + * , .wfh-panel .table-wrap + p { margin-bottom: 14px; }
/* On a phone each cost becomes a small card instead of a table that scrolls sideways. */
@media (max-width: 640px) {
  .wfh-panel .table-wrap { margin: 0; overflow: visible; }
  .wfh-costs thead { display: none; }
  .wfh-costs, .wfh-costs tbody { display: block; width: 100%; }
  .wfh-costs tr { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px 10px; align-items: end; border-top: 1px solid var(--line); padding: 10px 0; }
  .wfh-costs td { display: block; padding: 0; border: 0; }
  .wfh-costs td:first-child { grid-column: 1 / -1; font-weight: 600; }
  .wfh-costs td[data-label]::before { content: attr(data-label); display: block; font-size: 11.5px; color: var(--muted); margin-bottom: 3px; }
  .wfh-costs td input[type=text] { min-width: 0; }
}
