/* The device pages' styling (optimize.html, cover.html): the optimizer's report and the health cover check. Served from this site; nothing loads from anyone else. */
:root {
  --blue: #1f3dff; --blue-ink: #1a2fc4; --blue-soft: #eef0ff; --blue-line: #c9cffc;
  --ink: #0b1020; --ink2: #2a3040; --sub: #5b6070; --faint: #8a8f9c; --line: #e3e5ec; --line2: #d3d6df;
  --bg: #f4f5f8; --card: #ffffff; --green: #11733f; --green-soft: #e8f6ee; --red: #b42318; --red-soft: #fdecea;
  --amber: #8a5a00; --amber-soft: #fff6e0;
  --display: "Inter Tight", "Inter", system-ui, sans-serif; --text: "Inter", system-ui, sans-serif;
  --radius: 16px; color-scheme: light;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.55 var(--text); -webkit-font-smoothing: antialiased; }
.wrap { max-width: 760px; margin: 0 auto; padding: 0 16px 64px; }
[hidden] { display: none !important; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--blue-line); outline-offset: 2px; }

/* header and steps */
header.top { display: flex; justify-content: space-between; align-items: center; padding: 22px 0 8px; gap: 1rem; }
.brand { font: 800 19px/1 var(--display); letter-spacing: -.02em; display: flex; align-items: center; gap: .5rem; }
a.brand { color: inherit; text-decoration: none; }
a.brand:hover i { background: var(--blue-ink); }
.brand i { width: 22px; height: 22px; border-radius: 6px; background: var(--blue); display: inline-block; position: relative; }
.brand i::after { content: ""; position: absolute; inset: 6px 5px; border-top: 2px solid #fff; border-bottom: 2px solid #fff; }
.promise { font-size: 13px; color: var(--sub); }
.steps-nav { display: flex; margin: 18px 0 22px; }
.steps-nav span { flex: 1; display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--faint); }
.steps-nav span::before { content: ""; height: 4px; border-radius: 4px; background: var(--line2); margin-right: 6px; }
.steps-nav span.on, .steps-nav span.done { color: var(--ink); }
.steps-nav span.on::before, .steps-nav span.done::before { background: var(--blue); }
.steps-nav span.on { font-weight: 600; }

/* cards */
.card { background: var(--card); border-radius: var(--radius); box-shadow: 0 1px 2px #0b10200d, 0 8px 24px #0b10200a; padding: 32px; margin-bottom: 16px; }
h1 { font: 800 2.15rem/1.12 var(--display); letter-spacing: -.025em; margin: 0 0 .6rem; }
h2 { font: 700 1.5rem/1.2 var(--display); letter-spacing: -.02em; margin: 0 0 .4rem; }
h3 { font: 600 1.05rem/1.35 var(--text); margin: 0; }
#intro h1 { text-wrap: balance; }
.cv-sub { font: 600 1.2rem/1.3 var(--display); letter-spacing: -.01em; color: var(--ink2); margin: 0 0 .7rem; }
.lede { font-size: 1.08rem; color: var(--ink2); margin: 0 0 1.4rem; max-width: 36em; }
.muted { color: var(--sub); }
.small { font-size: 14px; }
.ok { color: var(--green); }
.err { color: var(--red); }
p { margin: 0 0 .6rem; }

/* buttons */
.buttons { display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; margin-top: 1.4rem; }
.primary { background: var(--blue); color: #fff; border: 0; border-radius: 10px; padding: .8rem 1.3rem; font-weight: 600; font-size: 1rem; }
.primary:hover { background: var(--blue-ink); }
.primary:disabled { opacity: .55; cursor: default; }
.secondary { background: #fff; color: var(--ink); border: 1px solid var(--line2); border-radius: 10px; padding: .75rem 1.15rem; font-weight: 600; font-size: .95rem; }
.secondary:hover { border-color: var(--ink2); }
.link { background: none; border: 0; color: var(--blue); padding: .4rem .2rem; font-weight: 500; font-size: .95rem; }
.link:hover { text-decoration: underline; }

/* 1 · the return */
.drop { display: flex; flex-direction: column; align-items: center; gap: .45rem; text-align: center; cursor: pointer;
  border: 2px dashed var(--blue-line); background: #f8f9ff; border-radius: 14px; padding: 2.2rem 1rem; transition: background .15s, border-color .15s; }
.drop:hover, .drop.over { background: var(--blue-soft); border-color: var(--blue); }
.drop svg { width: 40px; height: 40px; color: var(--blue); }
.drop b { font-size: 1.08rem; }
.drop .fake { margin-top: .4rem; background: #fff; border: 1px solid var(--blue-line); color: var(--blue); border-radius: 8px; padding: .45rem .9rem; font-weight: 600; font-size: .92rem; }
.trust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 1.6rem; padding-top: 1.4rem; border-top: 1px solid var(--line); }
.trust div { font-size: 13.5px; color: var(--sub); line-height: 1.45; }
.trust b { display: block; color: var(--ink); font-size: 14px; margin-bottom: 2px; }
.read-list { margin: 1.2rem 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.read-list:empty { display: none; }
.read-list li { display: flex; gap: .7rem; align-items: flex-start; padding: .8rem 1rem; border: 1px solid var(--line); border-radius: 12px; overflow-wrap: anywhere; }
.read-list .dot { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 700; margin-top: 1px; }
.read-list .dot.ok { background: var(--green-soft); color: var(--green); }
.read-list .dot.err { background: var(--red-soft); color: var(--red); }
.read-list .dot.no { background: var(--line); color: var(--sub); }
.read-list small { display: block; color: var(--sub); font-size: 13.5px; margin-top: 1px; }

/* 2 · check */
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; margin-top: 1.2rem; }
.grid .wide { grid-column: 1 / -1; }
@media (max-width: 480px) { .grid { grid-template-columns: 1fr; } }
label.f { display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; font-weight: 500; color: var(--ink2); }
input, select { font: 400 .95rem var(--text); padding: .6rem .75rem; border: 1px solid var(--line2); border-radius: 10px; background: #fff; color: var(--ink); width: 100%; min-width: 0; }
input:focus, select:focus { border-color: var(--blue); outline: 3px solid var(--blue-soft); }
/* selects: the page's own chevron instead of the browser's, the same height as a text box; hover shows it is live */
select { appearance: none; -webkit-appearance: none; padding-right: 2.3rem; cursor: pointer; line-height: 1.3;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%235b6170' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat; background-position: right .8rem center; background-size: 14px; }
select:hover { border-color: var(--ink2); }
select:disabled { color: var(--sub); cursor: default; }
/* compact selects in tables and compact rows */
.hp-table select, .cv-read select, .hp-policy-inputs select, .hp-which select { padding: .4rem 1.9rem .4rem .55rem; font-size: .88rem; border-radius: 8px; background-position: right .5rem center; }
/* a select that reads as an action: no box, blue, the chevron beside the words */
select.ghost { width: auto; border: 0; background-color: transparent; color: var(--blue); font-weight: 600; font-size: .86rem; padding: .2rem 1.3rem .2rem 0; background-position: right .05rem center; border-radius: 6px; }
select.ghost:hover { background-color: var(--blue-soft); padding-left: .4rem; }
select.ghost:focus { outline: 2px solid var(--blue-soft); }
.callout { border-radius: 12px; padding: .8rem 1rem; font-size: 14.5px; margin: 1rem 0 0; }
.cv-again .buttons { margin-top: .6rem; gap: .5rem; }
.cv-again .primary { padding: .45rem .9rem; font-size: .9rem; border-radius: 8px; }
.cv-again .link { font-size: .9rem; }
.callout.warn { background: var(--amber-soft); color: var(--amber); }
.callout:empty { display: none; }
details.leaves { margin-top: 1.4rem; border: 1px solid var(--line); border-radius: 12px; }
details.leaves summary { cursor: pointer; padding: .9rem 1rem; font-weight: 600; font-size: 15px; list-style: none; display: flex; align-items: baseline; gap: .6rem; }
details.leaves summary::-webkit-details-marker { display: none; }
details.leaves summary span { flex: 1; font-weight: 400; color: var(--sub); font-size: 14px; }
details.leaves summary::after { content: "Show"; color: var(--blue); font-weight: 500; font-size: 14px; }
details.leaves[open] summary::after { content: "Hide"; }
.leaves-list { padding: 0 1rem .6rem; }
.leaves-list div { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.leaves-list div span:last-child { color: var(--sub); text-align: right; }
details.sent { margin-top: .6rem; } details.sent summary { cursor: pointer; color: var(--blue); font-size: 14px; }
details.sent pre { max-height: 18rem; overflow: auto; font-size: 11px; background: var(--soft, #f6f7f9); padding: .6rem; border-radius: 8px; white-space: pre-wrap; }

/* 3 · questions */
.q { padding: 1.1rem 0; border-top: 1px solid var(--line); }
.q:first-child { border-top: 0; padding-top: .4rem; }
/* the savings found so far, at the top of the questions, worked out again as answers come in */
.sofar { position: sticky; top: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  background: var(--card); margin: -6px -6px 14px; padding: 10px 6px 12px; border-bottom: 1px solid var(--line); }
.sofar .label { font-size: 13px; color: var(--sub); }
.sofar-total { font: 700 1.6rem/1.1 var(--display); color: var(--green); transition: color .3s; }
.sofar-total.none { color: var(--sub); font-size: 1.15rem; }
.sofar-side { display: flex; flex-direction: column; align-items: flex-end; text-align: right; gap: 2px; }
.sofar-delta { font-weight: 600; font-size: 14px; color: var(--green); min-height: 1.1em; }
.sofar-delta.down { color: var(--sub); }
.q > span { display: block; font-weight: 500; margin-bottom: .65rem; }
.q > small.where { display: block; color: var(--sub); font-size: 13.5px; margin: -.35rem 0 .65rem; }
.q input { max-width: 16rem; }
.q select { max-width: 26rem; }
.money { position: relative; max-width: 16rem; }
.money::before { content: "CHF"; position: absolute; left: .8rem; top: 50%; transform: translateY(-50%); color: var(--faint); font-size: .9rem; pointer-events: none; }
.money input { padding-left: 3.1rem; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pills button { border: 1px solid var(--line2); background: #fff; border-radius: 8px; padding: .5rem 1.1rem; font-size: .95rem; color: var(--ink); text-align: left; }
.pills button:hover { border-color: var(--ink2); }
.pills button[aria-pressed="true"] { background: var(--blue); border-color: var(--blue); color: #fff; }
#qitem .buttons { margin-top: 1rem; }

/* 4 · report */
.hero .label { font-size: 14px; color: var(--sub); font-weight: 500; }
.total { font: 800 3rem/1.05 var(--display); letter-spacing: -.03em; margin: .25rem 0 .55rem; }
.total.none { font-size: 1.7rem; letter-spacing: -.02em; }
.group { margin-top: 28px; }
.group > h2 { font: 700 1.02rem/1.3 var(--text); letter-spacing: 0; display: flex; align-items: center; flex-wrap: wrap; gap: .6rem; margin: 0 0 10px 4px; }
.group > h2 .chip { font: 500 12.5px var(--text); background: var(--blue-soft); color: var(--blue-ink); padding: 3px 9px; border-radius: 999px; letter-spacing: 0; }
.group > .hint { margin: -4px 0 10px 4px; font-size: 14px; color: var(--sub); }
.item { background: var(--card); border-radius: 14px; box-shadow: 0 1px 2px #0b10200d, 0 4px 16px #0b102008; padding: 20px 22px; margin-bottom: 10px; }
.item .head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: .45rem; }
.amount { flex: none; font: 700 .95rem var(--text); background: var(--green-soft); color: var(--green); padding: 4px 11px; border-radius: 999px; white-space: nowrap; }
.item.risk .amount { background: var(--red-soft); color: var(--red); }
.amount.zero { background: var(--line); color: var(--sub); font-weight: 500; }
.item p { color: var(--ink2); }
.years { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: .8rem 0 .3rem; }
.item.couple .part, .item.note .part { border-top: 1px solid var(--line); margin-top: .7rem; padding-top: .6rem; }
.item .part p { margin: .2rem 0; }
.item .part .part-amount { font-weight: 600; color: var(--green); font-size: 14.5px; }
details.fold { margin-bottom: 10px; }
details.fold > summary { cursor: pointer; list-style: none; background: var(--card); border-radius: 14px; padding: 14px 22px;
  box-shadow: 0 1px 2px #0b10200d; color: var(--ink2); font-size: 15px; }
details.fold > summary::after { content: "Show"; float: right; color: var(--blue); font-weight: 600; margin-left: 1rem; }
details.fold[open] > summary { margin-bottom: 10px; }
details.fold[open] > summary::after { content: "Hide"; }
details.fold > summary::-webkit-details-marker { display: none; }
@media print { details.fold > summary { display: none; } details.fold > * { display: block; } }
.item.notes .note-part + .note-part { border-top: 1px solid var(--line); margin-top: .7rem; padding-top: .6rem; }
.item.notes h4 { font-size: 15px; margin: 0 0 .2rem; }
.item.notes p { margin: .15rem 0; }
.item.notes .note-part .part { border: 0; margin-top: .3rem; padding-top: 0; }
.item.cover .part + .part { border-top: 1px solid var(--line); margin-top: .7rem; padding-top: .6rem; }
.item.cover .part .head { display: flex; justify-content: space-between; align-items: center; }
.item.pension.couple .part { border-top: 1px solid var(--line); margin-top: .7rem; padding-top: .6rem; }
.item .part .part-who { font-size: 12.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--sub); margin: 0 0 .25rem; }
.item .q-label { font-weight: 500; margin: .4rem 0 .5rem; }
.item .for { margin: .5rem 0 .7rem; }
.item .for > label { font-size: 14px; font-weight: 600; color: var(--ink2); display: flex; flex-direction: column; gap: 4px; }
.q .pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; max-width: 32rem; }
.q .pair label { font-size: 13.5px; color: var(--sub); display: flex; flex-direction: column; gap: 4px; }
.item.risk .part .part-amount, .item .part .part-amount.zero { color: var(--sub); font-weight: 500; }
.years div { background: #f7f8fa; border-radius: 10px; padding: .6rem .85rem; font-size: 13.5px; color: var(--sub); }
.years b { display: block; font: 700 1.15rem var(--display); color: var(--green); }
.years b.zero { color: var(--sub); font: 500 .95rem var(--text); }
.meta { margin-top: .7rem; padding-top: .7rem; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--sub); display: grid; gap: 3px; }
.meta b { color: var(--ink2); font-weight: 600; }
.item label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; color: var(--ink2); margin-top: .6rem; }
.item label input { max-width: 16rem; }
.item .buttons { margin-top: .8rem; }
.possible { padding: 15px 20px; }
.possible h3 { font-weight: 500; }
.possible p { margin: .3rem 0 0; font-size: 14px; color: var(--sub); }
.kept { margin: .8rem 0 0; font-size: 14px; color: var(--sub); }
.kept:empty { display: none; }

/* offers: Pillar 3a */
.item.offer { background: #f8f9ff; border: 1px solid var(--blue-line); box-shadow: none; margin-top: -2px; }
.offer h3 { font-size: 1rem; }
.offer [data-branch] p { margin: .3rem 0 .5rem; }
/* the pension buy-in: the certificate, read here; the plan */
.cert { margin: .3rem 0 .2rem; }
.cert-pick { display: inline-block; cursor: pointer; padding: .2rem 0; }
.item label.cert-pick { display: inline-block; color: var(--blue); font-weight: 500; margin-top: .3rem; }
.cert-said { margin: .2rem 0 0; }
.plan p { margin: .45rem 0; font-size: 15px; }
/* the pension section (pension-plan.md §5) */
.item.pension p { margin: .45rem 0; font-size: 15px; }
.item.pension .cert label { cursor: pointer; display: inline-block; padding: .2rem 0; }
.item.pension .q { margin: .5rem 0; }
.item.pension.invite { background: #f8f9ff; border: 1px solid var(--blue-line); box-shadow: none; }
details.kinds { margin-top: .4rem; }
details.kinds summary { cursor: pointer; color: var(--blue); font-weight: 500; font-size: 15px; padding: .3rem 0; }
.kind { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: .8rem 1rem; margin: .6rem 0; }
.kind.fits { border-color: var(--blue); }
.kind-head { display: flex; justify-content: space-between; align-items: center; gap: .6rem; flex-wrap: wrap; }
.kind p { margin: .25rem 0; font-size: 14.5px; }
.kind .warn { color: var(--amber); }
.kind dl { display: grid; grid-template-columns: max-content 1fr; gap: 2px 12px; margin: .4rem 0 0; font-size: 13.5px; }
.kind dt { color: var(--sub); }
.kind dd { margin: 0; color: var(--ink2); }
.kind .partners { font-size: 14px; }
.chip { font: 500 12.5px var(--text); background: var(--blue-soft); color: var(--blue-ink); padding: 3px 9px; border-radius: 999px; }

.item.cover .head { align-items: baseline; }
.item.cover .link { padding: 0; white-space: nowrap; }

/* saving the plan */
.savebox { background: #f8f9ff; border: 1px solid var(--blue-line); border-radius: 12px; padding: 1rem 1.1rem; margin: .8rem 0 .4rem; }
.savebox p { margin: .2rem 0 .6rem; font-size: 14.5px; color: var(--ink2); }
.savebox .row { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }
.savebox input { max-width: 18rem; }
.google { display: inline-flex; align-items: center; gap: .55rem; background: #fff; color: var(--ink); border: 1px solid var(--line2); border-radius: 10px; padding: .7rem 1.05rem; font-weight: 600; font-size: .95rem; text-decoration: none; }
.google:hover { border-color: var(--ink2); }
.google svg { width: 18px; height: 18px; }
.or { color: var(--sub); font-size: 14px; }
.done-tick { display: inline-flex; gap: .45rem; align-items: center; font-size: 14px; color: var(--sub); margin-top: .5rem; cursor: pointer; }
.done-tick input { width: auto; }
.item label.done-tick { flex-direction: row; align-items: center; margin-top: .6rem; font-weight: 400; color: var(--sub); }
.item.is-done h3 { text-decoration: line-through; color: var(--sub); }
.plan-list { display: grid; gap: 8px; margin-top: .8rem; }
.plan-list .pi { border: 1px solid var(--line); border-radius: 12px; padding: .7rem .9rem; display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; }
.plan-list .pi small { display: block; color: var(--sub); }

/* the checklist */
.checklist { padding: .9rem 0 .6rem; }
.checklist h3 { font-size: 1rem; margin-bottom: .6rem; }
.checklist .checklist { padding: .3rem 0 .2rem; }
details.checklist.more { padding: .4rem 0 .2rem; }
details.checklist.more summary { cursor: pointer; color: var(--blue); font-weight: 500; font-size: 15px; padding: .3rem 0; }
details.checklist.more[open] summary { margin-bottom: .3rem; }
.checklist .checklist h3 { font-size: .78rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--sub); margin: .5rem 0 .3rem; }
.tick-row { display: flex; gap: .7rem; align-items: flex-start; padding: .55rem .2rem; cursor: pointer; font-size: 15.5px; }
.tick-row input { width: 20px; height: 20px; flex: none; margin: .1rem 0 0; accent-color: var(--blue); }

/* what we understood */
.card.profile ul { margin: .6rem 0 0; padding-left: 1.1rem; display: grid; gap: .3rem; }
.card.profile li { color: var(--ink2); }
.card.profile.compact { box-shadow: none; border: 1px solid var(--line); padding: 18px 20px; margin: 0 0 1.4rem; }
.card.profile.compact h2 { font-size: 1.05rem; }
.profile-amort { margin-top: 1rem; display: flex; gap: .8rem; align-items: flex-end; flex-wrap: wrap; }
.profile-amort label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; color: var(--ink2); }

.card.compare ul { margin: .5rem 0 .6rem; padding-left: 1.1rem; display: grid; gap: .35rem; }
.card.compare li { color: var(--ink2); }

/* the health cover check's card: one sentence for this household, above "Keep your plan" */
.card.health { background: #f8f9ff; border: 1px solid var(--blue-line); box-shadow: none; }
.card.health .head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.card.health .label { font-size: 14px; color: var(--sub); font-weight: 500; }
.card.health h2 { font: 600 1.15rem/1.4 var(--text); margin: .35rem 0 .5rem; color: var(--ink); text-wrap: balance; }
.card.health .health-says { font: 400 1.05rem/1.55 var(--text); margin: .35rem 0 .5rem; color: var(--ink); }
.card.health .health-says b { font-weight: 700; }
.card.health .chip { background: var(--amber-soft); color: var(--amber); }
.card.health .buttons { margin-top: .9rem; }
.card.health .link { padding: 0; white-space: nowrap; }
.health-table { width: 100%; border-collapse: collapse; margin: 1rem 0 .4rem; font-size: 14.5px; font-variant-numeric: tabular-nums; }
.health-table th { text-align: left; font-weight: 600; color: var(--sub); padding: 4px 8px 6px 0; border-bottom: 1px solid var(--line); }
.health-table td { padding: 6px 8px 6px 0; border-bottom: 1px solid var(--line); color: var(--ink2); white-space: nowrap; }

/* the page behind "Check my cover" (src/health-page.js) */
#health h2 { margin-top: .6rem; }
.hp-top { display: flex; justify-content: space-between; align-items: baseline; gap: .1rem 1rem; flex-wrap: wrap; }
.hp-top .hp-tell { margin-left: auto; white-space: nowrap; text-decoration: none; font-size: .95rem; padding: .4rem .2rem; }
.hp-top .hp-tell:hover, .hp-top .hp-tell:focus-visible { text-decoration: underline; }
/* the page: steps as cards on the page's grey, each with a numbered head and its one figure; the page itself has no card */
.card.health.hp-page { background: transparent; border: 0; box-shadow: none; padding: 0; }
.hp-block { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 1.25rem 1.4rem 1.3rem; margin-top: 1rem; box-shadow: 0 1px 2px #0b10200a; }
.hp-block.hp-sub { margin-top: .5rem; border-style: dashed; }
.hp-block > h3 { margin: 0 0 .5rem; }
.hp-step-head { display: grid; grid-template-columns: auto 1fr auto; gap: .5rem 1rem; align-items: center; margin-bottom: 1rem; }
.hp-step-head:has(> .hp-step-t:first-child) { grid-template-columns: 1fr auto; }
.hp-num { width: 2.1rem; height: 2.1rem; border-radius: 50%; background: var(--ink); color: #fff; font: 700 .95rem/2.1rem var(--display); text-align: center; letter-spacing: -.02em; }
.hp-step-t { display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem .8rem; min-width: 0; }
.hp-step-t h3 { font: 700 1.35rem/1.2 var(--display); letter-spacing: -.015em; margin: 0; }
.hp-step-fig { text-align: right; font: 700 1.5rem/1.1 var(--display); letter-spacing: -.02em; color: var(--green); white-space: nowrap; }
.hp-step-fig.more { color: var(--red); }
.hp-step-fig small { display: block; font: 400 12.5px/1.4 var(--text); color: var(--sub); letter-spacing: 0; white-space: normal; max-width: 16rem; margin-left: auto; }
.hp-lead { color: var(--ink2); font-size: 15px; margin: -.3rem 0 1rem; }
.hp-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin: 1rem 0 .4rem; }
.hp-sum { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: .85rem 1rem; min-width: 0; }
.hp-sum .k { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--sub); }
.hp-sum .v { font: 700 1.45rem/1.2 var(--display); letter-spacing: -.02em; margin: .15rem 0; font-variant-numeric: tabular-nums; }
.hp-sum .v.good { color: var(--green); } .hp-sum .v.bad { color: var(--red); }
.hp-sum .s { font-size: 12.5px; color: var(--ink2); }
.hp-nav { position: sticky; top: 0; z-index: 5; display: flex; gap: .35rem; flex-wrap: wrap; padding: .6rem 0; background: var(--bg); }
.hp-nav a { font-size: 12.5px; padding: .3rem .75rem; border-radius: 8px; border: 1px solid var(--line); color: var(--ink2); text-decoration: none; background: #fff; }
.hp-nav a:hover { border-color: var(--ink2); } .hp-nav a.on { background: var(--ink); color: #fff; border-color: var(--ink); }
@media (max-width: 640px) { .hp-summary { grid-template-columns: 1fr; } .hp-step-head { grid-template-columns: auto 1fr; } .hp-step-fig { grid-column: 1 / -1; text-align: left; } .hp-step-fig small { margin-left: 0; } .hp-nav { display: none; } .hp-step-t .badge { white-space: normal; } .hp-table { display: block; overflow-x: auto; max-width: 100%; -webkit-overflow-scrolling: touch; } .hp-block, .hp-policy, .hp-cards { max-width: 100%; min-width: 0; } }
/* a phone: the step heads' badges wrap, Step 1's table scrolls sideways inside its panel instead of pushing the page wider */
@media print { .hp-nav { display: none; } }
.hp-table { width: 100%; border-collapse: collapse; margin-top: .8rem; font-size: 14.5px; font-variant-numeric: tabular-nums; }
.hp-table th { text-align: left; font-weight: 600; color: var(--sub); padding: 4px 8px 6px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.hp-table td { padding: 8px 8px 8px 0; border-bottom: 1px solid var(--line); color: var(--ink2); vertical-align: top; }
.hp-table input { padding: .45rem .6rem; font-size: .95rem; }
.hp-table .money { max-width: 9rem; }
.tscroll { overflow-x: auto; }
label.tick { display: inline-flex; align-items: center; gap: .4rem; font-size: 14px; color: var(--ink2); cursor: pointer; }
label.tick input { width: auto; accent-color: var(--blue); }
.hp-prefs { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; margin-top: 1rem; }
.hp-change { display: grid; grid-template-columns: 1fr auto; gap: .3rem 1rem; padding: .8rem 1rem; border: 1px solid var(--line); border-radius: 12px; margin-bottom: .6rem; background: #fff; }
.hp-what { font-weight: 600; }
.hp-amt { font-weight: 700; white-space: nowrap; color: var(--green); font-variant-numeric: tabular-nums; }
.hp-how { grid-column: 1 / -1; color: var(--ink2); font-size: 14.5px; display: flex; flex-wrap: wrap; gap: .35rem .7rem; align-items: center; }
.hp-how .chip { white-space: nowrap; max-width: 100%; }
@media (max-width: 640px) { .hp-how .chip { white-space: normal; } .hp-change, .hp-card { max-width: 100%; min-width: 0; overflow-wrap: anywhere; } }
.hp-how .chip { background: var(--line); color: var(--sub); }
.hp-how .chip.now { background: var(--amber-soft); color: var(--amber); }
.clause { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12.5px; color: var(--faint); }
.hp-eyebrow { font-size: 11.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--sub); margin-top: .8rem; }
.hp-letter { white-space: pre-wrap; font: 13px/1.5 ui-monospace, Menlo, Consolas, monospace; background: #f7f8fa; border-radius: 10px; padding: .9rem 1rem; margin: .4rem 0 .2rem; }
.badge { display: inline-block; border-radius: 999px; padding: 2px 10px; font-size: 12.5px; font-weight: 500; white-space: nowrap; }
.badge.ok { background: var(--green-soft); color: var(--green); } .badge.warn { background: var(--amber-soft); color: var(--amber); } .badge.decide { background: #fbf0dc; color: #9a5b0b; } .badge.plain { background: var(--line); color: var(--sub); }
.hp-cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); margin-top: .8rem; }
.hp-card { border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; background: #fff; display: grid; gap: .6rem; align-content: start; min-width: 0; }
.hp-card.here { background: #f8f9ff; border-color: var(--blue-line); }
.hp-card-top { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; flex-wrap: wrap; }
.hp-ins { font: 700 1.15rem/1.2 var(--display); }
.hp-fit { display: flex; align-items: center; gap: .5rem; }
.hp-meter { flex: 1; height: 6px; background: var(--line); border-radius: 999px; overflow: hidden; }
.hp-meter i { display: block; height: 100%; background: var(--ink); }
.hp-lines { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; font-size: 14px; }
.hp-lines li { display: grid; grid-template-columns: 12px 1fr; gap: .5rem; align-items: start; cursor: pointer; }
.hp-lines .dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 6px; }
.hp-lines .plus .dot { background: var(--green); } .hp-lines .minus .dot { background: var(--red); }
.hp-lines .ref { display: none; } .hp-lines li.open .ref { display: block; }
.hp-lines.hp-plain li { grid-template-columns: 1fr; cursor: default; } .hp-lines.hp-plain .clause { display: block; margin-top: .1rem; }
.hp-gotcha { display: grid; grid-template-columns: 28px 1fr; gap: .6rem; padding: .6rem 0; border-bottom: 1px solid var(--line); font-size: 14.5px; line-height: 1.5; color: var(--ink2); }
.hp-gotcha b { color: var(--ink); }
.hp-gotcha .clause { margin-top: .1rem; }
.hp-gotcha .n { font: 700 1.15rem/1.3 var(--display); color: var(--red); }
.hp-policies { margin-top: .6rem; }
.hp-policy { padding: .8rem 0; border-top: 1px solid var(--line); }
.hp-policy-head { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem 1rem; flex-wrap: wrap; }
.hp-policy-head label.tick { font-size: 15px; }
.hp-policy-head label.tick input { width: 18px; height: 18px; flex: none; }
.hp-policy-body { margin-top: .6rem; display: grid; gap: .6rem; }
.hp-policy-inputs { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 14rem); gap: .8rem 1rem; align-items: end; }
.hp-policy-inputs label.f { margin: 0; }
.hp-policy .money { max-width: 14rem; }
.hp-policy .money input { padding-left: 3.1rem; }
.hp-policy .rec { display: grid; gap: .25rem; }
/* Step 2: three boxes per product. The one held on the left with its details; one tier up and one tier down stacked on the right */
.hp-boxes { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: .7rem; margin-top: .6rem; align-items: stretch; width: 100%; max-width: 100%; }
.hp-boxes-side { display: grid; gap: .7rem; grid-auto-rows: 1fr; min-width: 0; max-width: 100%; }
.hp-box { border: 1px solid var(--line2); border-radius: 12px; padding: .8rem .95rem; background: #fff; display: flex; flex-direction: column; gap: .4rem; min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
/* WebKit sizes a grid or list inside a column flexbox from its content unless told otherwise: every child shrinks to the box */
.hp-box > * { min-width: 0; max-width: 100%; width: auto; flex-shrink: 1; }
.hp-box select, .hp-box input { max-width: 100%; }
.hp-box.hp-cur { background: #eef2fd; border-color: #b9c7f5; }
.hp-box-eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.hp-box.hp-cur .hp-box-eyebrow { color: var(--blue); }
.hp-box-name { font: 700 15.5px/1.25 var(--display); letter-spacing: -.01em; }
.hp-box-name small { display: block; font: 400 12.5px/1.4 var(--text); color: var(--sub); margin-top: 1px; }
.hp-box .hp-policy-inputs { grid-template-columns: minmax(0, 1fr); gap: .5rem; }
.hp-box .money { max-width: none; }
.hp-facts { display: grid; grid-template-columns: minmax(6.5rem, 9rem) minmax(0, 1fr); gap: .15rem .6rem; margin: .2rem 0 0; font-size: 13px; }
.hp-facts dt { color: var(--sub); min-width: 0; } .hp-facts dd { margin: 0; color: var(--ink2); min-width: 0; }
.hp-box .rec { margin-top: .5rem; }
.hp-dl { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; font-size: 13px; color: var(--ink2); }
.hp-dl li { display: grid; grid-template-columns: 1.15rem minmax(0, 1fr); gap: .35rem; align-items: start; min-width: 0; }
.hp-dl li > span { min-width: 0; }
.hp-dl li i { font-style: normal; font-weight: 700; text-align: center; border-radius: 4px; width: 16px; height: 16px; font-size: 12px; line-height: 16px; margin-top: 2px; }
.hp-dl li.plus i { background: var(--green-soft); color: var(--green); } .hp-dl li.minus i { background: var(--red-soft); color: var(--red); }
.hp-held { display: flex; flex-wrap: wrap; align-items: center; gap: .1rem .3rem; margin-bottom: .2rem; }
.hp-held > span { min-width: 0; }
.hp-held small { flex-basis: 100%; }
.hp-dl b { color: var(--ink); font-weight: 600; }
.hp-box-foot { margin-top: auto; display: grid; gap: .2rem; font-size: 12.5px; padding-top: .35rem; }
.hp-box-foot > :last-child { justify-self: end; }
.hp-box-foot a.link { white-space: nowrap; cursor: pointer; }
.hp-box-foot b.ok { white-space: nowrap; font-size: 13.5px; }
.hp-difftable h3 { font: 700 1.15rem/1.3 var(--display); margin: 0 0 .2rem; }
.hp-difftable table { width: 100%; border-collapse: collapse; font-size: 13.5px; margin-top: .7rem; }
.hp-difftable th, .hp-difftable td { text-align: left; vertical-align: top; padding: .4rem .5rem; border-top: 1px solid var(--line); }
.hp-difftable thead th { border-top: 0; color: var(--faint); font-size: 12px; font-weight: 600; }
.hp-difftable tbody th { font-weight: 600; color: var(--ink2); width: 9rem; }
.hp-difftable td.now { background: #eef2fd; } .hp-difftable td.adds { color: var(--green); } .hp-difftable td.loses { color: var(--red); }
.hp-difftable .buttons { margin-top: 1rem; }
@media (max-width: 640px) { .hp-boxes { grid-template-columns: 1fr; } .hp-boxes-side { grid-auto-rows: auto; } .hp-facts { display: block; } .hp-facts dt { display: inline; color: var(--ink); font-weight: 600; } .hp-facts dt::after { content: ": "; } .hp-facts dd { display: inline; } .hp-facts dd::after { content: ""; display: block; height: .2rem; } .hp-difftable tbody th { width: 6.5rem; } }
.hp-step { font-size: 13.5px; color: var(--ink2); margin-top: .4rem; padding: .5rem .7rem; background: #f7f8fa; border-radius: 10px; }
.hp-step .hp-eyebrow { display: block; margin: 0 0 .2rem; }
.hp-all { margin-top: .3rem; } .hp-all summary { cursor: pointer; color: var(--blue); font-weight: 500; } .hp-all ul { margin: .3rem 0 0; padding-left: 1.1rem; display: grid; gap: .2rem; }
.hp-there li { display: block; cursor: pointer; font-size: 13.5px; }
@media (max-width: 640px) { .hp-policy-inputs { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .hp-change { grid-template-columns: 1fr; } }

/* busy */
.busy { margin-top: 1rem; width: 100%; }
.busy p { margin: .5rem 0 0; color: var(--sub); font-size: .92rem; }
.busy .bar { height: 4px; background: var(--blue-soft); border-radius: 4px; overflow: hidden; position: relative; max-width: 22rem; }
.busy .bar i { position: absolute; top: 0; bottom: 0; width: 35%; background: var(--blue); border-radius: 4px; animation: slide 1.3s ease-in-out infinite; }
@keyframes slide { from { left: -35%; } to { left: 100%; } }

@media (max-width: 600px) {
  .card { padding: 22px 18px; }
  h1 { font-size: 1.75rem; }
  .total { font-size: 2.4rem; }
  .grid, .years { grid-template-columns: 1fr; }
  .trust { grid-template-columns: 1fr; gap: 10px; }
  .item { padding: 18px; }
  .item .head { flex-direction: column; gap: .45rem; }
  .promise, details.leaves summary span { display: none; }
}
@media print {
  body { background: #fff; }
  .steps-nav, .noprint, .promise { display: none !important; }
  .card, .item { box-shadow: none; border: 1px solid var(--line); break-inside: avoid; }
}

/* Step 3's verdicts: one sentence per insurer, the lines behind it under Why; the full cards fold below */
.hp-intent { margin: .8rem 0 .6rem; display: grid; gap: .5rem; }
.hp-q { font: 600 1.05rem/1.4 var(--text); color: var(--ink); }
.hp-intent .pills button { font-size: .9rem; padding: .4rem .9rem; }
.hp-stay { font-weight: 600; margin: .2rem 0 .8rem; }
.hp-verdict { border: 1px solid var(--line); border-radius: 12px; padding: .75rem 1rem; margin-bottom: .6rem; background: #fff; }
.hp-verdict-top { display: flex; justify-content: space-between; gap: .6rem; flex-wrap: wrap; align-items: baseline; margin-bottom: .2rem; }
.hp-verdict .clause.ref { display: block; margin-top: .15rem; }
.hp-why > summary { cursor: pointer; color: var(--blue); font-weight: 600; font-size: .9rem; margin-top: .4rem; list-style: none; }
.hp-why > summary::before { content: "▸ "; }
.hp-why[open] > summary::before { content: "▾ "; }
.hp-notfor-list { display: grid; gap: 2px; margin-top: .4rem; }
.hp-notfor-row { display: grid; grid-template-columns: minmax(7rem, 10rem) minmax(12rem, 16rem) 1fr; gap: .3rem 1rem; align-items: baseline; padding: .4rem .2rem; border-bottom: 1px solid var(--line); font-size: 14px; }
.hp-notfor-row .n { font-weight: 600; }
.hp-notfor-row .why { color: var(--ink2); }
.hp-notfor-row .amt { font-variant-numeric: tabular-nums; color: var(--green); font-weight: 600; }
.hp-notfor-row .amt.more { color: var(--red); }
.hp-notfor-note { margin-top: .5rem; }
@media (max-width: 640px) { .hp-notfor-row { grid-template-columns: 1fr; gap: .1rem; } }
.hp-here-lines li { display: block; padding: .15rem 0; cursor: default; }
.hp-allcards { margin-top: 1rem; }
.hp-whos { display: flex; flex-wrap: wrap; gap: .2rem 1rem; }
.hp-whos .tick { font-size: 14px; }
.hp-verdict.here { background: #f8f9ff; border-color: var(--blue-line); }
.hp-v-price { font-weight: 700; color: var(--green); margin: .1rem 0 .3rem; }
.hp-v-price.more { color: var(--red); }
.hp-moves { list-style: none; margin: 0 0 .4rem; padding: 0; display: grid; gap: .2rem; font-size: 14px; }
.hp-moves li { display: grid; grid-template-columns: auto auto 1fr auto; gap: .1rem .5rem; align-items: baseline; padding: .2rem 0; border-top: 1px solid var(--line); }
.hp-moves li:first-child { border-top: 0; }
.hp-moves .eff { grid-column: 1 / -1; padding-left: 0; }
.hp-moves .who { justify-self: end; white-space: nowrap; }
.hp-moves .from, .hp-moves .to { min-width: 0; overflow-wrap: anywhere; }
/* a narrow screen: the held product, the arrow and its equal flow as text and wrap; the people and the effect each on their own line */
@media (max-width: 640px) {
  .hp-moves li { display: flex; flex-wrap: wrap; gap: .05rem .35rem; }
  .hp-moves .who { flex-basis: 100%; justify-self: start; white-space: normal; }
  .hp-moves .eff { flex-basis: 100%; }
}
.hp-moves .from { color: var(--ink2); }
.hp-moves .arrow { color: var(--sub); }
.hp-moves .to { font-weight: 600; }
.hp-moves .eff { color: var(--ink2); }
.hp-moves .eff.bad { color: var(--red); }
.hp-moves .eff.good { color: var(--green); }
.hp-v-line { color: var(--ink2); font-size: 14px; }
/* the household block: values read from the policy stand as text with a quiet pencil; the doctor question under the
   table as a segmented control per person, a thin amber edge until answered */
.hp-val { display: inline; }
.hp-val .hp-edit { vertical-align: -1px; }
.hp-fixed { font-weight: 500; }
.hp-edit { border: 0; background: none; padding: 0 .1rem; color: var(--sub); cursor: pointer; line-height: 1; display: inline-flex; border-radius: 4px; }
.hp-edit:hover, .hp-edit:focus-visible { color: var(--blue); outline: none; background: var(--blue-soft); }
.hp-visits { margin: 1rem 0 .2rem; }
.hp-visits .hp-q { font-size: .98rem; }
.hp-visit { display: grid; grid-template-columns: minmax(8rem, 11rem) 1fr; gap: .3rem .8rem; align-items: center; padding: .35rem .6rem; margin: .2rem 0; border-left: 3px solid transparent; }
.hp-visit .n .badge { display: block; width: max-content; margin-top: .15rem; }
.hp-visit.open { border-left-color: var(--amber); background: #fffaf0; }
.hp-visit .n { font-weight: 600; font-size: 14.5px; }
.hp-visit .pills { gap: 4px; flex-wrap: nowrap; overflow-x: auto; }
.hp-visit .pills button { padding: .28rem .65rem; font-size: .84rem; }
.hp-visit .badge { font-size: 11.5px; }
@media (max-width: 560px) { .hp-visit { grid-template-columns: 1fr auto; } .hp-visit .pills { grid-column: 1 / -1; } }
/* a tier's or an equal's differences: a label and a short list per group, one cell a line */
.hp-diff { display: grid; grid-template-columns: 4.6rem 1fr; gap: .1rem .6rem; align-items: start; margin: .3rem 0; font-size: 13.5px; }
.hp-diff-k { font-weight: 700; font-size: 12px; letter-spacing: .04em; text-transform: uppercase; padding-top: .15rem; }
.hp-diff.adds .hp-diff-k { color: var(--green); } .hp-diff.changes .hp-diff-k { color: var(--ink2); } .hp-diff.loses .hp-diff-k { color: var(--red); }
.hp-diff ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; color: var(--ink2); }
.hp-diff li b { color: var(--ink); font-weight: 600; }
.hp-diff-more { grid-column: 2; }
.hp-moves-k { font-weight: 700; font-size: 12px; letter-spacing: .04em; text-transform: uppercase; color: var(--sub); margin: .4rem 0 .2rem; }
.hp-group { margin-top: .9rem; } .hp-group .hp-eyebrow { margin: 0 0 .4rem; }
.hp-outcome { background: var(--green-soft); border: 1px solid #cfe9d9; border-radius: 12px; padding: .9rem 1.1rem; margin: .4rem 0 .8rem; }
.hp-outcome .hp-eyebrow { margin: 0 0 .25rem; color: var(--green); }
.hp-outcome-say { font: 600 1.08rem/1.4 var(--text); color: var(--ink); margin-bottom: .2rem; }
.hp-step-fig:has(> small) { }
/* the detail: the two best fits side by side; the comparison popout */
.hp-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hp-cards.one { grid-template-columns: 1fr; margin-top: 0; }
@media (max-width: 640px) { .hp-pair { grid-template-columns: 1fr; } }
.hp-card-top .link.small { font-size: .82rem; padding: 0; white-space: nowrap; }
dialog.hp-dialog { border: 0; border-radius: 16px; padding: 0; width: min(920px, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); box-shadow: 0 24px 64px #0b102033; }
dialog.hp-dialog::backdrop { background: #0b102066; }
.hp-dialog-body { padding: 1.3rem 1.5rem 1.5rem; font-size: 14.5px; }
.hp-cmp-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: .8rem; }
.hp-cmp-head h3 { font: 700 1.3rem/1.2 var(--display); margin: 0; }
.hp-cmp-basic { background: var(--bg); border-radius: 12px; padding: .8rem 1rem; margin-bottom: 1rem; }
.hp-cmp-nums { display: flex; flex-wrap: wrap; gap: .4rem 1.4rem; align-items: baseline; margin-top: .3rem; }
.hp-cmp-nums b { font: 700 1.2rem/1.2 var(--display); }
.hp-cmp-nums .good { color: var(--green); font-weight: 600; } .hp-cmp-nums .bad { color: var(--red); font-weight: 600; }
.hp-cmp-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: .4rem 0 1rem; }
.hp-cmp-col .hp-ins { margin-bottom: .4rem; }
.hp-cmp-col .hp-lines .clause { display: block; }
.hp-cmp-prod { margin: .6rem 0 1rem; }
.hp-cmp { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.hp-cmp th, .hp-cmp td { text-align: left; vertical-align: top; padding: .4rem .5rem; border-bottom: 1px solid var(--line); }
.hp-cmp thead th { font-size: 12px; color: var(--sub); text-transform: uppercase; letter-spacing: .04em; }
.hp-cmp tbody th { font-weight: 600; width: 11rem; color: var(--ink2); }
.hp-cmp tr.diff td { background: #fffaf0; }
@media (max-width: 640px) { .hp-cmp-cols { grid-template-columns: 1fr; } .hp-cmp tbody th { width: 7rem; } }
.hp-notfor-row[data-hp-show] { cursor: pointer; }
.hp-notfor-row[data-hp-show]:hover { background: var(--blue-soft); }
.hp-notfor-row[aria-expanded="true"] { background: var(--blue-soft); }
.hp-notfor-open { padding: .5rem 0 .9rem; border-bottom: 1px solid var(--line); }
.hp-verdict-top .link.small { font-size: .82rem; padding: 0; white-space: nowrap; }
/* the page's title at the step titles' size; a value standing in for a control keeps its height */
.card.health.hp-page > h2 { font: 700 1.35rem/1.2 var(--display); letter-spacing: -.015em; color: var(--ink); margin: .2rem 0 .3rem; }
.hp-fixed-row { display: inline-flex; align-items: center; min-height: 2.5rem; font-size: 1rem; color: var(--ink); }
/* What if: scenario pills, their controls, and the result as a card of deltas */
.hp-scn-pills { margin: .4rem 0 .6rem; }
.hp-scn-controls { margin-top: .4rem; }
.hp-scn { margin-top: .9rem; background: var(--bg); border-radius: 12px; padding: .9rem 1.1rem; }
.hp-scn-top { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; flex-wrap: wrap; margin-bottom: .4rem; }
.hp-scn-top b { font: 700 1.05rem/1.3 var(--display); }
.hp-scn-fig { font: 700 1.3rem/1.1 var(--display); color: var(--green); white-space: nowrap; text-align: right; }
.hp-scn-fig.more { color: var(--red); }
.hp-scn-fig small { display: block; font: 400 12px/1.4 var(--text); color: var(--sub); }
.hp-scn-lines { margin: 0; padding-left: 1.1rem; display: grid; gap: .3rem; font-size: 14.5px; color: var(--ink2); }
.hp-close { display: grid; gap: 0; padding-top: .4rem; padding-bottom: .4rem; }
.hp-close-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .8rem 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.hp-close-row:last-child { border-bottom: 0; }
.hp-close-row > div > b { display: block; color: var(--ink); }
.hp-close-row > div > .muted { font-size: 13.5px; }
.hp-close-row .secondary { white-space: nowrap; text-decoration: none; padding: .55rem .95rem; font-size: .9rem; }
.hp-rate { display: flex; gap: .1rem; }
.hp-rate button { border: 0; background: none; font-size: 1.5rem; line-height: 1; color: #d99a1e; padding: .1rem .15rem; cursor: pointer; }
.hp-rate:hover button:not([disabled]) { color: #b57a0c; } .hp-rate button:not([disabled]):hover ~ button { color: var(--faint); }
.hp-rate button[disabled] { cursor: default; }
.hp-rate button[aria-pressed="true"] { transform: scale(1.1); }
.hp-tip h3 { font: 700 1.3rem/1.2 var(--display); margin: 0 0 .6rem; }
.hp-tip p { margin: .3rem 0; }
.hp-tip .buttons { margin-top: 1rem; }
.hp-tip .primary { text-decoration: none; display: inline-block; }
dialog.hp-dialog-small { width: min(460px, calc(100vw - 2rem)); }
@media (max-width: 640px) { .hp-close-row { flex-direction: column; align-items: flex-start; } }
.hp-who > div + div { margin-top: .45rem; padding-top: .45rem; border-top: 1px dashed var(--line); }
.hp-apply { display: flex; flex-wrap: wrap; gap: .2rem .7rem; align-items: center; margin-top: .35rem; font-size: 13px; }
.hp-apply .tick { font-size: 13px; }
.hp-table th:first-child { width: 13rem; }
.hp-table td select { width: auto; max-width: 100%; }
.hp-fit-tag { display: inline-flex; align-items: center; gap: .4rem; font-size: 13px; vertical-align: middle; }
.hp-fit-tag .hp-meter { width: 4.5rem; flex: none; }
.hp-fit-tag b { font-variant-numeric: tabular-nums; }
.hp-verdict-top .hp-fit-tag { margin-right: auto; }
.hp-cmp-col .hp-ins .hp-fit-tag { margin-left: .6rem; }
.hp-guard, .hp-guard * { -webkit-user-select: none; user-select: none; }
.hp-guard select, .hp-guard input { -webkit-user-select: auto; user-select: auto; }
.hp-pick .hp-how { align-items: center; } .hp-pick .hp-how .secondary { margin-left: auto; padding: .45rem .8rem; font-size: .88rem; }
/* the proofs and the three steps, as on the house page: an icon, three words, one short line */
.proofs { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin-top: 1.4rem; }
.proof { display: flex; gap: .7rem; align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: .8rem 1rem; }
.proof svg { width: 26px; height: 26px; flex: none; color: var(--blue); margin-top: .05rem; }
.proof b { display: block; font: 600 15px/1.25 var(--display); color: var(--ink); letter-spacing: -.01em; }
.proof span { display: block; font-size: 13px; line-height: 1.4; color: var(--sub); margin-top: .2rem; }
.steps3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin-top: 1.4rem; }
.step3 { text-align: center; color: var(--ink2); font-size: 14px; }
.step3 svg { width: 30px; height: 30px; color: var(--blue); display: block; margin: 0 auto .3rem; }
.step3 b { display: block; color: var(--ink); font: 600 14.5px/1.2 var(--display); }
.step3 .n { display: inline-block; width: 18px; height: 18px; border-radius: 50%; background: var(--ink); color: #fff; font: 700 10.5px/18px var(--text); margin-bottom: .35rem; }
@media (max-width: 640px) { .proofs, .steps3 { grid-template-columns: 1fr; } }
.hp-nav .hp-view { margin-left: auto; font-size: 12.5px; padding: .3rem .75rem; border-radius: 8px; border: 1px solid var(--line); color: var(--blue); background: #fff; cursor: pointer; }
.hp-nav .hp-view:hover { border-color: var(--blue); }
.hp-stepnav { display: flex; justify-content: space-between; align-items: center; gap: .8rem; margin-top: 1rem; flex-wrap: wrap; }
.hp-stepnav .link { padding: .4rem .2rem; }
.hp-foot-note { flex-basis: 100%; color: var(--ink2); font-size: 14px; }
.hp-stepnav .hp-doors { flex-basis: 100%; }
a.hp-sum-go { display: block; color: inherit; text-decoration: none; cursor: pointer; } a.hp-sum-go:hover { border-color: var(--ink2); }
/* the hub's doors at the end of What you have */
.hp-doors { margin-top: 1.2rem; }
.hp-door-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .7rem; }
.hp-door { text-align: left; border: 1px solid var(--line2); border-radius: 12px; padding: .9rem 1rem; background: #fff; cursor: pointer; display: grid; gap: .25rem; font: inherit; color: var(--ink); }
.hp-door:hover, .hp-door:focus-visible { border-color: var(--blue); outline: none; box-shadow: 0 0 0 3px var(--blue-soft); }
.hp-door b { font: 600 15.5px/1.3 var(--display); }
.hp-door span { color: var(--sub); font-size: 13.5px; line-height: 1.45; }
@media (max-width: 640px) { .hp-door-grid { grid-template-columns: 1fr; } }
.hp-stepnav:empty { display: none; }
.hp-stepnav .primary, .hp-stepnav .secondary { padding: .7rem 1.1rem; }
/* the check's page while the server draws it again (src/health-client.js) */
.hp-busy { opacity: .7; pointer-events: none; transition: opacity .15s; }

/* "Ask your policy" (src/ask.js): a floating button on the check, a dialog with the question box and the answer's cells;
   on a phone the dialog is a sheet from the bottom; the button steps aside while the stage foot is on screen */
.ask-fab { position: fixed; right: 16px; bottom: 16px; z-index: 6; display: inline-flex; align-items: center; gap: .45rem; padding: .65rem 1rem; border: 0; border-radius: 999px; background: var(--ink); color: #fff; font: 600 14px var(--text); box-shadow: 0 6px 20px #0b102040; cursor: pointer; transition: opacity .2s, transform .2s; }
.ask-fab:hover { background: #000; }
.ask-fab.aside { opacity: 0; pointer-events: none; transform: translateY(8px); }
@media print { .ask-fab { display: none; } }
.hp-dialog-body.ask { padding-top: 1rem; }
.ask-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.ask-head .hp-eyebrow { margin-top: 0; }
.ask-close { padding: .2rem .3rem; }
.hp-dialog-body.ask > p { margin: .4rem 0 .8rem; }
@media (max-width: 640px) {
  dialog.ask-dialog { width: 100vw; max-width: 100vw; max-height: 88vh; margin: auto 0 0; border-radius: 16px 16px 0 0; }
}
dialog.ask-dialog { overflow: auto; }
@media (max-width: 640px) {
  dialog.ask-dialog { overscroll-behavior: contain; }
}
.ask-form { display: flex; gap: .5rem; }
.ask-form input { flex: 1; }
.ask-form .primary { white-space: nowrap; }
.ask-cell { margin-top: 1rem; padding-top: .8rem; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
.ask-cond { margin: .2rem 0 0; } .ask-cond summary { cursor: pointer; color: var(--blue); font-size: 13.5px; }
.ask-cell h4 { margin: 0 0 .3rem; font-size: 1.02rem; }
.ask-cell p { margin: .3rem 0; }
.ask-rows, .ask-notes ul { margin: .3rem 0 0; padding-left: 1.1rem; display: grid; gap: .35rem; }
.ask-notes .hp-eyebrow { margin-top: .7rem; }
.ask-therapist { color: var(--ink2); }
.ask-foot { margin-top: 1rem; }
@media (max-width: 640px) { .ask-form { flex-direction: column; } }
