/* Inner pages. Tokens, header, footer, buttons, sheets, bars, the estimate and
   the accordion all come from styles.css. */

.inner .site-header::before { opacity: 1; }
.inner main:focus { outline: none; }
.inner .sheet { padding-block: clamp(3rem, 6vw, 5rem) calc(clamp(3rem, 6vw, 5rem) + var(--sheet-radius)); }
.narrow { max-width: 52rem; }
.fine { color: var(--ink-soft); font-size: 0.875rem; }
.cross-link { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 2rem; }
.cross-link a:not(.button) { font-weight: 700; }

/* ---------- page opening ---------- */

.page-top {
  padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + clamp(2rem, 5vw, 4rem));
  padding-bottom: calc(var(--sheet-radius) + clamp(3rem, 6vw, 5.25rem));
  background: var(--green);
  color: #fff;
}
.page-top a { color: #fff; }
.page-top :focus-visible { outline-color: var(--yellow); }
.page-top h1 { max-width: 20ch; font-size: clamp(2.375rem, 5.4vw, 4.25rem); font-weight: 900; line-height: 1.03; letter-spacing: -0.035em; }
.page-lead { max-width: 40rem; margin-top: 1.1rem; color: var(--on-green-soft); font-size: clamp(1.125rem, 1.7vw, 1.3125rem); }
.page-note { max-width: 44rem; margin-top: 1rem; color: var(--on-green-soft); font-size: 0.9375rem; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 0 0.5rem; margin-bottom: 1.25rem; font-size: 0.875rem; }
.crumbs li { display: flex; align-items: center; gap: 0.5rem; min-height: 1.75rem; }
.crumbs li + li::before { content: "/"; color: var(--on-green-soft); opacity: 0.7; }
.crumbs a { display: inline-flex; align-items: center; min-height: 1.75rem; }
.crumbs [aria-current] { color: var(--on-green-soft); }

/* ---------- calculator ---------- */

.inner .page-estimate { padding-top: clamp(1.75rem, 4vw, 3rem); background: var(--base); color: var(--ink); }
.page-estimate .segments { background: var(--sand); box-shadow: inset 0 0 0 1px var(--rule); }
.page-estimate .segments input:focus-visible + span { outline-color: var(--green); }
.page-estimate .estimate-panel { border: 1px solid var(--rule); box-shadow: var(--shadow); }

/* onward links that close a table or a list, inside the same block */
.card-next { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 2.25rem; padding: 1.25rem 1.5rem; border-top: 1px solid var(--rule); background: var(--yellow-wash); color: var(--ink); }
.list-next { margin-top: 0.75rem; border: 0; border-radius: var(--radius); }
.list-next p { margin-right: auto; font-size: var(--card-title); font-weight: 800; line-height: 1.35; }
@media (max-width: 48rem) {
  .card-next { flex-direction: column; align-items: stretch; padding: 1.1rem; }
  .card-next .button { padding-inline: 0.75rem; font-size: 1rem; }
  .card-next .arrow-link { justify-content: center; text-align: center; }
}

/* ---------- seller pages ---------- */

.figures { overflow: hidden; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.figures dl { display: grid; grid-template-columns: 1fr 0.7fr 1.3fr; }
.figures dl > div { padding: 1.5rem 1.75rem; }
.figures dl > div + div { border-left: 1px solid var(--rule); }
.figures dt, .panel-facts dt { margin-bottom: 0.4rem; }
.figure { display: block; font-size: clamp(2.25rem, 4.5vw, 3.25rem); font-weight: 900; line-height: 1.05; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.figure-text { font-size: clamp(1.125rem, 2vw, 1.5rem); line-height: 1.25; letter-spacing: -0.01em; }
.figure-note { display: block; margin-top: 0.35rem; color: var(--ink-soft); font-size: 0.875rem; font-weight: 700; }
.figures-action { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.5rem; padding: 1.25rem 1.75rem; border-top: 1px solid var(--rule); background: var(--yellow-wash); }
.figures-action p { font-size: 0.9375rem; }
.figures-action .button-sun { background: var(--green); color: #fff; }

.detail-grid { display: grid; grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr); gap: 2rem 3.5rem; align-items: start; margin-top: 3.5rem; }
.fields { width: 100%; border-collapse: collapse; }
.fields caption { margin-bottom: 0.75rem; text-align: left; font-size: var(--h-sub); font-weight: 900; letter-spacing: -0.02em; }
.fields th, .fields td { padding: 0.9rem 0.25rem; border-top: 1px solid var(--rule); text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.fields th { width: 11rem; color: var(--ink-soft); font-size: 0.875rem; }
.aside { padding: 1.5rem; border-radius: var(--radius); background: var(--sand); }
.aside h2 { margin-bottom: 1rem; font-size: var(--card-title); font-weight: 800; }
.aside p { margin-top: 1.25rem; font-weight: 700; }

.chip-list { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip-list a { display: inline-flex; align-items: center; gap: 0.5rem; min-height: 2.75rem; padding: 0.4rem 1rem; border: 1px solid #d6cdb4; border-radius: 999px; background: var(--paper); color: var(--ink); font-size: 0.9375rem; font-weight: 600; text-decoration: none; transition: background-color 160ms ease, border-color 160ms ease; }
.chip-list a span:not(.visually-hidden) { color: var(--ink-soft); font-weight: 500; }

.inner .questions { background: var(--sand); }
.inner .guides + .questions, .inner .panels-sheet + .questions { background: var(--base); }
.inner .questions .qa summary::after { background-color: var(--paper); box-shadow: inset 0 0 0 1px var(--rule); }
.seller-note { max-width: 70ch; margin-top: 2.5rem; }
.inner .closing { background: var(--sand); }
.inner .closing > .wrap > p { max-width: 70ch; }

/* ---------- comparison pages ---------- */

.versus { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 0; overflow: hidden; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.versus th, .versus td { padding: 1rem 1.25rem; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.versus thead th { font-size: clamp(1.25rem, 2.6vw, 1.875rem); font-weight: 900; letter-spacing: -0.02em; line-height: 1.15; }
.versus thead td:first-child, .versus tbody th, .versus tfoot td:first-child { width: 22%; }
.versus thead th a { color: var(--green-deep); text-decoration-thickness: 2px; }
.versus tbody th { color: var(--ink-soft); font-size: 0.875rem; }
.versus tfoot td { border-bottom: 0; }
.versus-price { display: block; font-size: clamp(1.75rem, 4vw, 2.75rem); font-weight: 900; line-height: 1.05; letter-spacing: -0.025em; }
.versus-count { font-size: 1.75rem; font-weight: 900; }
.versus + .fine { margin-top: 1rem; }

.picker { display: flex; flex-wrap: wrap; align-items: end; gap: 1rem; padding: 1.5rem; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.picker label { display: grid; flex: 1 1 15rem; gap: 0.35rem; font-size: 0.875rem; font-weight: 700; }
.picker select, .field input[type="email"] { width: 100%; min-height: 3.25rem; padding: 0.6rem 0.9rem; border: 1.5px solid #bfb598; border-radius: 0.75rem; background: var(--paper); color: var(--ink); font: inherit; font-size: 1.0625rem; font-weight: 500; }
.picker-vs { padding-bottom: 0.9rem; font-weight: 900; color: var(--green); }
.picker .form-message { flex-basis: 100%; }
.picker .form-message:empty { display: none; }
.list-heading { margin-block: 3rem 1.25rem; font-size: 1.875rem; font-weight: 900; letter-spacing: -0.02em; }
.pair-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; align-items: start; }
.pair-group { padding: 1.5rem; border-radius: var(--radius); background: var(--sand); }
.pair-group h3 { margin-bottom: 0.9rem; font-size: 1.25rem; font-weight: 800; }
.pair-group h3 span { color: var(--ink-soft); font-weight: 500; }

/* ---------- pay-per-panel ---------- */

.panels-sheet { background: var(--sand) !important; }
.panel-list { display: grid; gap: 0.75rem; margin-top: 0.75rem; }
.panel-row { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, 2.6fr) auto; grid-template-areas: "who cost facts actions"; gap: 0.75rem 1.5rem; align-items: center; padding: 1.35rem 1.5rem; border-radius: var(--radius); background: var(--paper); box-shadow: 0 1px 2px rgb(0 0 0 / 0.08); overflow-wrap: break-word; }
/* Every part is placed by name, so nothing can inherit a place from another card. */
.panel-row > .s-who { grid-area: who; }
.panel-row > .s-cost { grid-area: cost; }
.panel-row > .panel-facts { grid-area: facts; }
.panel-row > .s-actions { grid-area: actions; }
.panel-row h2 { font-size: var(--card-title); font-weight: 900; letter-spacing: -0.015em; }
.panel-product { color: var(--ink-soft); font-size: 0.9375rem; }
.panel-facts { display: grid; grid-template-columns: 1fr 0.9fr 1.4fr; gap: 1rem; }

/* ---------- reading pages ---------- */

.prose p { max-width: 66ch; font-size: 1.125rem; line-height: 1.65; }
.prose > p + p, .prose section p + p { margin-top: 1.25rem; }
.prose section + section { margin-top: 3rem; }
.prose h2 { margin-bottom: 0.75rem; font-size: var(--h-sub); font-weight: 900; letter-spacing: -0.02em; }
.prose .button { margin-top: 1rem; }
.inner .article + .guides { background: var(--sand); }
.guides h2 + .section-head { margin: 0; }
.inner .guide-list h2 { font-size: var(--card-title); font-weight: 800; letter-spacing: -0.015em; }
.terms > div { display: grid; grid-template-columns: 11rem minmax(0, 1fr); gap: 0.25rem 1.5rem; padding-block: 0.8rem; border-top: 1px solid var(--rule); }
.terms dt { margin: 0; color: var(--green-deep); font-size: 1rem; }
.terms dd { font-size: 1rem; }
.source-list { columns: 2; gap: 2rem; margin-block: 0.75rem 1.25rem; }
.source-list li { padding-block: 0.2rem; overflow-wrap: anywhere; }

/* ---------- find a match ---------- */

.match-form { display: grid; gap: 1rem; justify-items: start; }
.match-count { color: var(--ink-soft); font-weight: 700; }
.match-form fieldset { width: 100%; min-width: 0; margin: 0; padding: 1.25rem 1.5rem 1.5rem; border: 2px solid transparent; border-radius: var(--radius); background: var(--paper); box-shadow: 0 1px 2px rgb(0 0 0 / 0.08); }
.match-form legend { float: left; width: 100%; margin-bottom: 0.9rem; padding: 0; font-size: 1.25rem; font-weight: 800; }
.match-form legend + * { clear: both; }
.match-form fieldset.is-missing { border-color: #a8321f; }
.choices { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.choices label { position: relative; display: flex; cursor: pointer; }
.choices input { position: absolute; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.choices span { display: flex; align-items: center; min-height: 3rem; padding: 0.5rem 1.25rem; border: 1.5px solid #bfb598; border-radius: 999px; font-weight: 600; line-height: 1.25; transition: background-color 160ms ease, border-color 160ms ease, transform 140ms var(--ease-out); }
.choices input:checked + span { border-color: var(--green); background: var(--green); color: #fff; font-weight: 700; }
.choices input:active + span { transform: scale(0.97); }
.choices input:focus-visible + span { outline: 3px solid var(--green); outline-offset: 3px; }
.match-results { margin-top: 3.5rem; scroll-margin-top: calc(var(--header) + 1rem); }
.match-results h2 { margin-bottom: 1.25rem; font-size: var(--h-sub); font-weight: 900; letter-spacing: -0.02em; scroll-margin-top: calc(var(--header) + 1rem); }
.match-results h2:focus { outline: none; }
.match-list { display: grid; gap: 0.75rem; margin-bottom: 1rem; }
.match-card { padding: 1.35rem 1.5rem; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.motion .match-card { animation: rise 520ms var(--ease-out) var(--d, 0ms) both; }
.match-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.25rem 1rem; }
.match-head h3 { font-size: var(--card-title); font-weight: 900; letter-spacing: -0.02em; }
.match-head h3 a { color: var(--green-deep); }
.match-yes { margin-top: 0.5rem; font-weight: 600; }
.match-no { margin-top: 0.35rem; color: var(--ink-soft); font-size: 0.9375rem; }
.signup-block { margin-top: 3rem; }

/* ---------- email sign-up ---------- */

.signup { display: grid; gap: 1.1rem; justify-items: start; padding: clamp(1.25rem, 3vw, 2rem); border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.field { display: grid; gap: 0.4rem; width: 100%; }
.field > label:not(.check) { font-weight: 700; }
.field input[aria-invalid="true"] { border-color: #a8321f; }
.field-error { color: #9c2a18; font-size: 0.9375rem; font-weight: 600; }
.field-error:empty { display: none; }
.check { display: flex; align-items: flex-start; gap: 0.75rem; min-height: 2.75rem; cursor: pointer; }
.check input { flex: none; width: 1.375rem; height: 1.375rem; margin: 0.15rem 0 0; accent-color: var(--green); }
.form-message { font-weight: 700; }
.form-message:empty { display: none; }
.form-message[data-kind="warn"] { padding: 0.75rem 1rem; border: 1px solid #b9a86a; border-radius: 0.75rem; background: var(--yellow-wash); }
.form-message[data-kind="ok"] { padding: 0.75rem 1rem; border: 1px solid var(--green); border-radius: 0.75rem; background: var(--on-green-soft); }
.button:disabled { opacity: 0.65; cursor: progress; }

@media (hover: hover) and (pointer: fine) {
  .chip-list a:hover { border-color: var(--green); background: var(--yellow-wash); }
  .choices input:not(:checked):hover + span { border-color: var(--green); background: var(--yellow-wash); }
  .page-top .crumbs a:hover { text-decoration-thickness: 2px; }
}

@media (max-width: 75rem) {
  .panel-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; grid-template-areas: "who cost actions" "facts facts facts"; }
  .panel-row > .panel-facts { padding-top: 0.9rem; border-top: 1px solid var(--rule); }
}

@media (max-width: 64rem) {
  .detail-grid { grid-template-columns: minmax(0, 1fr); }
  .page-photo { aspect-ratio: 16 / 9; }
}

@media (max-width: 48rem) {
  .figures dl { grid-template-columns: 1fr 1fr; }
  .figures dl > div { padding: 1.25rem; }
  .figures dl > div + div { border-left: 1px solid var(--rule); }
  .figures dl > div:last-child { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--rule); }
  .figures-action { padding: 1.25rem; }
  .figures-action .button { width: 100%; }
  .fields tr, .fields th, .fields td { display: block; width: 100%; }
  .fields th { padding-bottom: 0; }
  .fields td { padding-top: 0.2rem; border-top: 0; }

  /* Side by side stays side by side: each label sits above its two values. */
  .versus, .versus thead, .versus tbody, .versus tfoot { display: block; }
  .versus tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .versus thead td:first-child, .versus tfoot td:first-child { display: none; }
  .versus th, .versus td { padding: 0.75rem 0.9rem; }
  .versus tbody th { grid-column: 1 / -1; width: auto; padding-bottom: 0; border: 0; }
  .versus tfoot .button { width: 100%; padding-inline: 0.75rem; font-size: 0.875rem; }

  .picker-vs { display: none; }
  .pair-groups { grid-template-columns: minmax(0, 1fr); }
  .panel-row { grid-template-columns: minmax(0, 1fr); grid-template-areas: "who" "cost" "facts" "actions"; padding: 1.25rem; }
  .panel-row > .panel-facts { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.75rem 1rem; }
  .panel-facts > div:last-child { grid-column: 1 / -1; }
  .panel-row > .s-actions { grid-template-columns: minmax(0, 1fr); }
  .panel-row > .s-actions .button { width: 100%; }
  .terms > div { grid-template-columns: minmax(0, 1fr); }
  .source-list { columns: 1; }
  .match-form fieldset { padding: 1.1rem; }
  .choices label, .choices span { width: 100%; }
}

/* ---------- compare page ---------- */

.jump-links { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.75rem; }
.page-top .jump-links .button-sun { color: var(--ink); }
.button-ghost-light { border-color: rgb(255 255 255 / 0.75); background: transparent; color: #fff; }
.inner .compare { background: var(--sand); }
.compare, .sbs { scroll-margin-top: var(--header); }
.after-list { margin-top: 1.75rem; }

.inner .sbs { background: var(--base); }
.picker { margin-bottom: 2.5rem; }
.picker .swap { min-height: 3.25rem; }
.sbs-title { font-size: clamp(1.75rem, 3.6vw, 2.75rem); font-weight: 900; letter-spacing: -0.03em; }
.sbs-lead { max-width: 52rem; margin-block: 0.75rem 0.5rem; font-size: 1.25rem; font-weight: 600; }
.sbs-region { max-width: 52rem; margin-bottom: 0.5rem; color: var(--ink-soft); font-size: 0.9375rem; }
.sbs-region:empty { display: none; }
.sbs .versus { margin-top: 1.25rem; }
.versus-name { display: block; }
.versus-link { display: inline-flex; align-items: center; min-height: 2.75rem; font-size: 0.9375rem; font-weight: 700; letter-spacing: 0; text-decoration-thickness: 1px; }
.versus thead th .versus-link { color: var(--green); }
.versus .button { gap: 0.4rem; }
.sbs-years-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem; margin-top: 3.5rem; margin-bottom: 0.75rem; }
.sbs-years-head h3, .sbs-faq-title { font-size: var(--h-sub); font-weight: 900; letter-spacing: -0.02em; }
.sbs-years-head fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.segments-light { background: var(--sand); }
.segments.segments-light input:focus-visible + span { outline-color: var(--green); }
.years thead th { font-size: 1.25rem; }
.years thead .figure-note { font-weight: 700; letter-spacing: 0; }
.years-total { display: block; font-size: 1.75rem; font-weight: 900; letter-spacing: -0.02em; }
.years-basis { display: block; margin-top: 0.3rem; color: var(--ink-soft); font-size: 0.875rem; line-height: 1.4; }
.years .is-partial .years-total { color: var(--ink-soft); }
.sbs-faq-title { margin-top: 3.5rem; margin-bottom: 1rem; }
.sbs .qa h4 { margin: 0; font-size: 1.1875rem; font-weight: 800; }

/* The bar that follows you once something is ticked. */
.tray {
  position: fixed;
  z-index: 30;
  right: max(1rem, env(safe-area-inset-right, 0px));
  bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  left: max(1rem, env(safe-area-inset-left, 0px));
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 1.25rem;
  max-width: 48rem;
  margin-inline: auto;
  padding: 0.75rem 1.25rem;
  border-radius: 1.5rem;
  background: var(--green-deep);
  color: #fff;
  box-shadow: 0 18px 40px -16px rgb(0 0 0 / 0.55);
}
.motion .tray { animation: rise 320ms var(--ease-out) both; }
.tray p { font-weight: 700; }
.tray :focus-visible { outline-color: var(--yellow); }
.tray-clear { min-height: 2.75rem; padding: 0 0.25rem; border: 0; background: none; color: #fff; font-weight: 700; text-decoration: underline; text-underline-offset: 0.18em; }
.has-tray .site-footer { padding-bottom: 9rem; }

/* ---------- calculator rows and match results ---------- */

.estimate-link { display: inline-grid; min-height: 2.75rem; color: var(--ink); text-decoration: none; }
.estimate-name { text-decoration: underline; text-decoration-color: var(--rule); text-decoration-thickness: 2px; text-underline-offset: 0.18em; }
.estimate-more { color: var(--green); font-size: 0.8125rem; font-weight: 700; text-decoration: underline; text-underline-offset: 0.18em; }
.match-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.9rem; }
.match-next { margin-top: 1.5rem; }
.after-form { margin-top: 1.75rem; }

@media (max-width: 48rem) {
  .jump-links .button { width: 100%; }
  .picker .swap { width: 100%; }
  .years tbody th { color: var(--ink); font-size: 1rem; }
  .versus .button { white-space: normal; }
  .match-actions .button { flex: 1 1 8rem; }
}

/* ---------- compare page: side-by-side headings stay in view ---------- */

/* Not "hidden": that would stop the headings from pinning. Corners are rounded on the cells. */
.versus { overflow: visible; }
.versus thead th, .versus thead td { position: sticky; top: var(--header); z-index: 3; background: var(--paper); border-bottom: 2px solid var(--green); }
.versus thead tr > :first-child { border-radius: var(--radius) 0 0 0; }
.versus thead tr > :last-child { border-radius: 0 var(--radius) 0 0; }
.versus tfoot td { border-radius: 0 0 var(--radius) var(--radius); }
.versus tfoot .versus-view { display: none; }

.fold { margin-top: 3.5rem; }
.fold > summary { list-style: none; }
.fold > summary::-webkit-details-marker { display: none; }
.fold .sbs-years-head { margin-top: 0; justify-content: flex-end; }
.sbs-faq-title { margin: 0; }
.fold > summary h3 { margin-bottom: 1rem; }
.sbs-show { display: none; }
.phone-bar, .active-chip, .phone-only, .s-summary, .toggle-short { display: none; }
@media (min-width: 48.01rem) {
  .fold > summary { pointer-events: none; }
  /* heading and the state switch share one row, as before */
  .fold .sbs-years-head { position: relative; margin-top: -3.25rem; margin-bottom: 1rem; }
}

/* ---------- filter and sort panel ---------- */

.sheet-panel { display: none; }

@media (max-width: 48rem) {
  .inner .compare { padding-top: 1.25rem; }
  .compare .toolbar, .compare .sort-select, .compare #expand-all, .compare #reset-view, .compare .status { display: none; }

  /* One bar that stays under the header: no sideways strip to discover. */
  .phone-bar {
    position: sticky;
    top: calc(var(--header) + env(safe-area-inset-top, 0px));
    z-index: 6;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem 0.75rem;
    margin-inline: -0.5rem;
    padding: 0.6rem 0.5rem;
    background: var(--sand);
    box-shadow: 0 10px 14px -14px rgb(0 0 0 / 0.5);
  }
  .phone-bar .button svg { width: 1.2rem; height: 1.2rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
  .badge { display: inline-grid; place-items: center; min-width: 1.35rem; height: 1.35rem; border-radius: 999px; background: var(--yellow); color: var(--ink); font-size: 0.875rem; font-weight: 900; }
  .phone-count { font-size: 0.9375rem; font-weight: 700; text-align: right; }

  .compare .list-bar { min-height: 0; margin-top: 0.25rem; }
  .compare .list-tools { display: none; }
  .active-chip { display: inline-flex; align-items: center; gap: 0.6rem; min-height: 2.75rem; padding: 0.35rem 1rem; border: 0; border-radius: 999px; background: var(--yellow); font-size: 0.9375rem; font-weight: 800; }
  .active-chip svg { width: 0.9rem; height: 0.9rem; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
  .compare .legend { gap: 0.2rem 1rem; margin-block: 0.5rem 0.75rem; font-size: 0.875rem; }

  /* A shorter card: what is needed to compare, the rest one tap away. */
  .compare .seller { grid-template-areas: "who" "cost" "summary" "actions" "foot" "more"; row-gap: 0.6rem; padding: 1rem 1.1rem 0.5rem; scroll-margin-top: calc(var(--header) + 4.5rem); }
  .compare .s-who { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0 0.75rem; }
  .compare .s-checked { margin: 0; font-size: 0.875rem; }
  .compare .s-cost .basis, .compare .s-facts { display: none; }
  .compare .s-cost .bar { margin-bottom: 0; }
  .s-summary { grid-area: summary; display: block; font-size: 1rem; line-height: 1.4; }
  .compare .s-actions { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.6rem; }
  .compare .s-actions .button { padding-inline: 0.5rem; }
  .compare .s-foot { margin: 0; padding-top: 0.15rem; }
  .compare .details-toggle { font-size: 0.9375rem; }
  .compare .compare-check { font-size: 0.9375rem; }
  .toggle-long { display: none; }
  .toggle-short { display: inline; }
  .compare .s-more { margin-top: -0.6rem; }
  .compare .s-more dl { margin-top: 0; padding-top: 0.75rem; padding-bottom: 0.75rem; gap: 0.75rem; }
  .compare .phone-only { display: block; }
  .compare .sellers { gap: 0.6rem; scroll-margin-top: calc(var(--header) + 8.5rem); }
  .compare .s-who h3 a { display: inline-block; padding-block: 0.5rem; margin-block: -0.5rem; }
  #sbs-title { scroll-margin-top: calc(var(--header) + 0.75rem); }
  .compare .table-notes { gap: 0.75rem; margin-top: 1.25rem; }
  .compare .after-list { margin-top: 1rem; gap: 0.25rem 1.5rem; }
  .compare .after-list a { display: inline-flex; align-items: center; min-height: 2.75rem; }

  .sheet-panel[open] {
    position: fixed;
    inset: auto 0 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 100%;
    max-height: 90vh;
    max-height: 90dvh;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 1.5rem 1.5rem 0 0;
    background: var(--base);
    color: var(--ink);
    transition: transform 320ms cubic-bezier(0.32, 0.72, 0, 1);
  }
  .sheet-panel::backdrop { background: rgb(0 0 0 / 0.45); }
  .motion .sheet-panel[open] { animation: sheet-in 380ms cubic-bezier(0.32, 0.72, 0, 1) backwards; }
  /* While the finger is down the panel is the finger: no easing. */
  .sheet-panel.is-dragging { transition: none !important; }
  .sp-top { flex: none; padding: 0.5rem 1.1rem 0.5rem; touch-action: none; cursor: grab; -webkit-user-select: none; user-select: none; }
  .sp-grip { display: block; width: 2.75rem; height: 0.3rem; margin: 0 auto 0.4rem; border-radius: 999px; background: #c7bc9c; }
  .sp-title { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
  .sp-title h2 { font-size: 1.375rem; font-weight: 900; letter-spacing: -0.015em; }
  .sp-close { display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0; border: 0; border-radius: 999px; background: var(--paper); }
  .sp-close svg { width: 1.2rem; height: 1.2rem; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
  .sp-body { flex: 1 1 auto; min-height: 0; padding: 0 1.1rem 1rem; overflow-y: auto; overscroll-behavior: contain; }
  .sp-body fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
  .sp-body legend, .sp-sort { font-size: 1rem; font-weight: 800; }
  .sp-body legend { margin-bottom: 0.5rem; padding: 0; }
  .sp-option { position: relative; display: flex; align-items: center; gap: 0.75rem; min-height: 3rem; margin-bottom: 0.4rem; padding: 0.5rem 1rem; border: 1.5px solid var(--rule); border-radius: 0.9rem; background: var(--paper); font-weight: 600; cursor: pointer; }
  .sp-option input { width: 1.25rem; height: 1.25rem; margin: 0; accent-color: var(--green); }
  .sp-option span:first-of-type { flex: 1; line-height: 1.3; }
  .sp-option [data-count] { color: var(--ink-soft); font-variant-numeric: tabular-nums; }
  .sp-option:has(input:checked) { border-color: var(--green); background: var(--on-green-soft); }
  .sp-sort { display: grid; gap: 0.4rem; margin-top: 0.75rem; }
  .sp-sort select { width: 100%; min-height: 3rem; padding: 0.5rem 0.75rem; border: 1.5px solid #bfb598; border-radius: 0.75rem; background: var(--paper); font-size: 1rem; font-weight: 500; }
  .sp-foot { display: grid; flex: none; grid-template-columns: auto 1fr; gap: 0.75rem; padding: 0.75rem 1.1rem calc(0.75rem + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--rule); background: var(--base); }

  /* side by side on a phone */
  .picker { margin-bottom: 1.25rem; padding: 1.1rem; gap: 0.6rem; }
  .picker label { flex-basis: 100%; }
  .sbs-show { display: inline-flex; width: 100%; }
  .versus thead { position: sticky; top: calc(var(--header) + env(safe-area-inset-top, 0px)); z-index: 4; display: block; }
  .versus thead th { position: static; }
  .versus thead tr { background: var(--paper); border-radius: var(--radius) var(--radius) 0 0; border-bottom: 2px solid var(--green); box-shadow: 0 10px 14px -12px rgb(0 0 0 / 0.4); }
  .versus thead th { padding-block: 0.6rem; border: 0; font-size: 1.0625rem; }
  .versus thead .versus-link, .versus thead .figure-note { display: none; }
  .versus tfoot .versus-view { display: inline-flex; margin-top: 0.5rem; }
  .versus .long { display: none; }
  .versus th, .versus td { overflow-wrap: break-word; }
  .versus td { font-size: 0.9375rem; }
  .years-basis { font-size: 0.875rem; }

  .fold { margin-top: 1rem; border-top: 1px solid var(--rule); }
  .fold > summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 3.5rem; cursor: pointer; }
  .fold > summary h3 { margin: 0; font-size: 1.25rem; }
  .fold > summary::after { content: ""; flex: none; width: 0.6rem; height: 0.6rem; margin-right: 0.4rem; border: solid var(--green); border-width: 0 2.5px 2.5px 0; rotate: 45deg; }
  .fold[open] > summary::after { rotate: 225deg; }
  .fold .sbs-years-head { justify-content: flex-start; margin-bottom: 0.5rem; }

  /* nothing secondary below 14px on a phone */
  .price-tag, .basis, .s-checked, dt, .ov-who .ov-checked, .estimate-more, .figure-note, .chip-list a, .legend, .fine, .table-notes, .section-note, .crumbs ol, .teaser-card .price-tag { font-size: 0.875rem; }
}
@keyframes sheet-in { from { transform: translateY(100%); } to { transform: translateY(0); } }
@media (max-width: 22.5rem) {
  .phone-bar .button { padding-inline: 0.9rem; font-size: 0.9375rem; }
  .compare .seller { padding-inline: 0.9rem; }
  .compare .s-foot { column-gap: 0.5rem; }
  .compare .details-toggle, .compare .compare-check { font-size: 0.875rem; }
  .versus thead th { padding-inline: 0.75rem; font-size: 0.9375rem; }
}
@media (max-width: 22.5rem) {
  .page-top h1 { font-size: 2rem; }
  .versus td { padding-inline: 0.75rem; }
}

/* ---------- seller pages ---------- */
.fields .group th { width: auto; padding-top: 1.5rem; border-top: 0; color: var(--green-deep); font-size: 1.0625rem; font-weight: 900; }
.fields tbody:first-of-type .group th { padding-top: 0.25rem; }
.compare-with { display: none; }

@media (max-width: 48rem) {
  .inner .sheet { padding-block: 2.25rem calc(2.25rem + var(--sheet-radius)); }
  .long-name { display: none; }
  .js .compare-with { display: grid; gap: 0.6rem; }
  .js .aside .chip-list { display: none; }
  .compare-with select { width: 100%; min-height: 3.25rem; padding: 0.6rem 0.9rem; border: 1.5px solid #bfb598; border-radius: 0.75rem; background: var(--paper); color: var(--ink); font: inherit; font-size: 1.0625rem; font-weight: 600; }
  .compare-with .button { justify-content: center; }
  .aside > p { margin-top: 0.5rem; }
  .aside > p a, .crumbs li, .crumbs a { min-height: 2.75rem; }
  .aside > p a { display: inline-flex; align-items: center; }
  .crumbs a { min-width: 2.75rem; }
  .crumbs ol { margin-bottom: 0.5rem; }
}

/* ---------- page banners: a photograph that fades into the green ----------
   The words always sit on the solid part of the fade; the photograph shows where
   there are no words. Seller and legal pages use leaves only, never people. */

.banner { position: relative; isolation: isolate; overflow: hidden; background: var(--green-deep); }
.banner-media { position: absolute; inset: calc(var(--header) + env(safe-area-inset-top, 0px)) 0 0 30%; z-index: -1; overflow: hidden; }
.banner-media img { width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%); }
/* on wide screens the photograph itself fades in from its left edge, so there is no seam */
@media (min-width: 48.01rem) { .banner-media img { -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 20%); mask-image: linear-gradient(90deg, transparent 0, #000 20%); } }
.banner-media::after {
  content: "";
  position: absolute;
  inset: 0 0 -1px -2px;
  background:
    linear-gradient(90deg, var(--green-deep) 0%, var(--green-deep) 2px, rgb(43 74 20 / 0.92) 18%, rgb(43 74 20 / 0.78) 38%, rgb(43 74 20 / 0.4) 52%, rgb(43 74 20 / 0.06) 72%, rgb(43 74 20 / 0) 100%),
    linear-gradient(0deg, var(--green-deep) 0%, rgb(43 74 20 / 0.5) 14%, rgb(43 74 20 / 0) 36%);
}
.banner-photo, .banner-quiet { display: flex; align-items: center; min-height: clamp(29rem, 42vw, 37rem); }
.banner-quiet { min-height: clamp(26rem, 34vw, 31rem); }
.banner-photo > .wrap, .banner-quiet > .wrap { flex: none; }
.banner .page-top-copy { max-width: 40rem; }
.banner .page-lead { max-width: 35rem; }

/* leaves: quieter and lower */
.banner-quiet .banner-media { left: 52%; }
.banner-quiet .banner-media::after {
  background:
    linear-gradient(90deg, var(--green-deep) 0%, rgb(43 74 20 / 0.72) 45%, rgb(43 74 20 / 0.5) 100%),
    linear-gradient(0deg, var(--green-deep) 0%, rgb(43 74 20 / 0) 55%);
}

/* arrives once, gently; not at all with reduced motion */
.motion .banner-media img { animation: banner-in 900ms cubic-bezier(0.23, 1, 0.32, 1) both; }
@keyframes banner-in { from { opacity: 0.35; scale: 1.05; } to { opacity: 1; scale: 1; } }

@media (min-width: 48.01rem) and (max-width: 68rem) {
  .banner .page-top-copy { max-width: min(36rem, 62%); }
  .banner-media { left: 24%; }
  .banner-media::after {
    background:
      linear-gradient(90deg, var(--green-deep) 0%, rgb(43 74 20 / 0.94) 28%, rgb(43 74 20 / 0.82) 52%, rgb(43 74 20 / 0.3) 68%, rgb(43 74 20 / 0.04) 100%),
      linear-gradient(0deg, var(--green-deep) 0%, rgb(43 74 20 / 0) 34%);
  }
}

@media (max-width: 48rem) {
  .banner { padding-bottom: calc(var(--sheet-radius) + 2.25rem); }
  .banner-media { inset: calc(var(--header) + env(safe-area-inset-top, 0px)) 0 auto; height: 15rem; }
  .banner-media img { object-position: var(--pos-phone, 50% 50%); transform: scale(var(--zoom, 1)); transform-origin: var(--origin, 50% 50%); }
  .banner-media::after {
    inset: 0 0 -1px;
    background: linear-gradient(0deg, var(--green-deep) 0%, var(--green-deep) 8%, rgb(43 74 20 / 0.93) 28%, rgb(43 74 20 / 0.86) 35%, rgb(43 74 20 / 0.28) 55%, rgb(43 74 20 / 0) 74%);
  }
  .banner-photo { display: block; min-height: 0; padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 10.5rem); }
  .banner-quiet { display: block; min-height: 0; }
  .banner .page-top-copy { max-width: none; }
  /* the trail rides on the photograph, on its own dark chip */
  .banner-photo .crumbs { position: absolute; top: calc(var(--header) + env(safe-area-inset-top, 0px) + 0.6rem); left: 0.9rem; max-width: calc(100% - 1.8rem); border-radius: 999px; background: rgb(20 34 9 / 0.78); }
  .banner-photo .crumbs ol { margin: 0; padding: 0 0.9rem; flex-wrap: nowrap; overflow: hidden; white-space: nowrap; }
  .banner-photo .crumbs li[aria-current] { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; line-height: 2.75rem; }
  .banner-photo .crumbs li[aria-current]::before { margin-right: 0.5rem; }
  .banner-photo .crumbs [aria-current] { color: #fff; }
  .banner h1 { font-size: 2.125rem; }
  .banner .page-lead { margin-top: 0.75rem; font-size: 1.0625rem; line-height: 1.45; }
  .banner .page-note { margin-top: 0.6rem; font-size: 0.875rem; }
  .banner .jump-links { flex-wrap: nowrap; gap: 0.5rem; margin-top: 1rem; }
  .banner .jump-links .button { flex: 1 1 0; width: auto; min-width: 0; min-height: 3rem; padding-inline: 0.5rem; font-size: 0.9375rem; }

  /* leaves: no empty strip, just texture behind the words */
  .banner-quiet { padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 2rem); padding-bottom: calc(var(--sheet-radius) + 2.75rem); }
  .banner-quiet .banner-media { inset: 0; height: auto; opacity: 0.6; }
  .banner-quiet .banner-media::after { background: linear-gradient(0deg, var(--green-deep) 0%, rgb(43 74 20 / 0.86) 30%, rgb(43 74 20 / 0.74) 100%); }
}
@media (max-width: 22.5rem) {
  .banner h1 { font-size: 1.875rem; }
  .banner-photo { padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 8.5rem); }
  .banner-photo .banner-media { height: 13rem; }
}

@media (max-width: 48rem) { .banner .jump-links .cap::first-letter { text-transform: uppercase; } .banner .jump-links .cap { display: inline-block; } }

/* short screens: laptops, and phones held sideways */
@media (max-height: 50rem) and (min-width: 48.01rem) {
  .page-top.banner { padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 2rem); padding-bottom: calc(var(--sheet-radius) + 2.5rem); }
  .banner-photo, .banner-quiet { min-height: 27rem; }
  .banner h1 { font-size: 3rem; }
  .banner .page-lead { margin-top: 0.6rem; font-size: 1.125rem; }
  .banner .jump-links { margin-top: 1rem; }
  .banner .crumbs ol { margin-bottom: 0.4rem; }
}
@media (max-height: 30rem) {
  /* a phone held sideways: the page must start on the first screen */
  .page-top.banner, .banner-photo, .banner-quiet { min-height: 0; }
  .page-top.banner { padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 1rem); padding-bottom: calc(var(--sheet-radius) + 1rem); }
  .banner h1 { font-size: 2rem; }
  .banner .page-lead { margin-top: 0.4rem; font-size: 1rem; line-height: 1.4; }
  .banner .jump-links { margin-top: 0.6rem; }
  .banner .jump-links .button { min-height: 2.75rem; padding-block: 0.4rem; }
  .banner .page-note { margin-top: 0.4rem; }
}
@media (max-height: 30rem) and (max-width: 48rem) {
  .banner-photo { padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 4.5rem); }
  .banner-photo .banner-media { height: 9rem; }
}
/* without scripts there is nothing for the filter button to open */
html:not(.js) .phone-bar { display: none; }

/* headlines keep the line breaks they had before the photographs */
@media (min-width: 68.01rem) {
  .banner .page-top-copy { max-width: 46rem; }
  .banner h1 { max-width: none; }
}
/* the calculator: a low banner, so choices and totals stay on the first screen */
@media (min-width: 48.01rem) {
  .page-top.banner-low { min-height: 0; padding-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 2.5rem); padding-bottom: calc(var(--sheet-radius) + 3.25rem); }
  .banner-low h1 { font-size: clamp(2.25rem, 3.6vw, 3.25rem); }
  .banner-low .page-lead { margin-top: 0.6rem; font-size: 1.125rem; }
  .banner-low .page-lead { max-width: 40rem; }
  .banner-low .crumbs ol { margin-bottom: 0.4rem; }
}

/* in-page links land below the fixed header */
#match-form, .prose h2[id] { scroll-margin-top: calc(var(--header) + env(safe-area-inset-top, 0px) + 1rem); }
