:root {
  --bg: #f6f5f2; --panel: #ffffff; --ink: #1c1d1f; --muted: #62666d; --line: #dcdad4;
  --accent: #1f5fa8; --accent-ink: #ffffff; --base-col: #eef3fa;
  --best: #e3f3e6; --best-ink: #1c6b2e; --worst: #fbe9e6; --worst-ink: #a23a26;
  --yours: #fff8e1; --yours-line: #e6cf86;
  --radius: 10px; --ease: 220ms cubic-bezier(.2, .7, .2, 1);
  --brand: #ef5c27; --brand-ink: #ffffff;
  --font-body: Lato, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-head: Oswald, "Arial Narrow", Lato, -apple-system, "Segoe UI", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15171a; --panel: #1e2125; --ink: #ecedee; --muted: #a1a6ae; --line: #33373d;
    --accent: #7db3ee; --accent-ink: #10202f; --base-col: #222b36;
    --best: #1d3323; --best-ink: #8fd49f; --worst: #3a221e; --worst-ink: #f0a394;
    --yours: #2c2718; --yours-line: #6b5a23;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.45 var(--font-body); }
h1, h2, h3, h4, .tabs a, .btn, .brand-word, .specs thead th strong { font-family: var(--font-head); letter-spacing: .01em; }
h1 { text-transform: uppercase; font-weight: 700; }
a { color: var(--accent); text-underline-offset: 2px; transition: color var(--ease), background-color var(--ease), border-color var(--ease); }
h1 { font-size: 1.55rem; line-height: 1.2; margin: 0 0 .4rem; text-wrap: balance; }
h2 { font-size: 1.15rem; margin: 2rem 0 .7rem; }
h3 { font-size: 1rem; margin: 1rem 0 .4rem; }
h4 { font-size: .9rem; margin: 0 0 .3rem; }
.count { font-weight: 400; font-size: .8rem; color: var(--muted); margin-left: .4rem; }
.muted { color: var(--muted); } .small { font-size: .82rem; }
main { max-width: 1280px; margin: 0 auto; padding: 16px 16px 48px; }
footer { max-width: 1280px; margin: 0 auto; padding: 16px; color: var(--muted); font-size: .8rem; border-top: 1px solid var(--line); }
footer .who { display: block; margin-top: 4px; }

.top { position: sticky; top: 0; z-index: 20; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding: 10px 16px; background: var(--panel); border-bottom: 1px solid var(--line); }
.top .brand { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; }
.brand-logo img { display: block; height: 34px; width: auto; }
.brand-word { font-weight: 700; font-size: 1.3rem; text-transform: uppercase; letter-spacing: .06em; color: var(--brand); border-left: 2px solid var(--line); padding-left: 9px; line-height: 1.1; }
.top nav { display: flex; gap: 14px; font-size: .9rem; }
.top { row-gap: 10px; }
.search { position: relative; flex: 1 1 260px; order: 3; }
@media (min-width: 720px) { .search { order: 0; max-width: 520px; } .top nav { margin-left: auto; } }
.search input { width: 100%; font: inherit; font-size: 1.05rem; padding: 11px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); transition: border-color var(--ease), box-shadow var(--ease); }
.search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }
.results { position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 10px 30px rgba(0, 0, 0, .14); max-height: 60vh; overflow: auto; opacity: 0; transform: translateY(-4px); transition: opacity var(--ease), transform var(--ease); }
.results.open { opacity: 1; transform: none; }
.results a { display: flex; justify-content: space-between; gap: 12px; padding: 11px 14px; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line); }
.results a:last-child { border-bottom: 0; }
.results a:hover, .results a.active { background: var(--base-col); }
.results small { color: var(--muted); text-align: right; }
.results .hint { padding: 10px 14px; color: var(--muted); font-size: .85rem; }

.hero { padding: 12px 0 4px; }
.lede { color: var(--muted); max-width: 62ch; margin: .2rem 0 0; }
.page-head { padding: 6px 0 10px; }
.crumb { margin: 0 0 4px; color: var(--muted); font-size: .82rem; text-transform: none; }
.config { margin: 0; color: var(--muted); font-size: .88rem; max-width: 90ch; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0; }
.btn { display: inline-flex; align-items: center; font-family: var(--font-head); font-size: .9rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; padding: 9px 16px; border-radius: 4px; border: 1px solid var(--brand); background: var(--brand); color: var(--brand-ink); text-decoration: none; cursor: pointer; transition: opacity var(--ease), background-color var(--ease); }
.btn:hover { opacity: .88; }
.btn.ghost { background: transparent; color: var(--brand); }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--accent); text-decoration: underline; cursor: pointer; }
.notice { background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 0 var(--radius) var(--radius) 0; padding: 12px 14px; max-width: 70ch; }

.brand-group { margin: 0 0 12px; }
.sub-label { margin: 8px 0 4px; font-size: .78rem; color: var(--muted); text-transform: capitalize; }
.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips a { display: flex; flex-direction: column; padding: 8px 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 600; }
.chips a:hover { border-color: var(--accent); }
.chips a small { font-weight: 400; color: var(--muted); font-size: .74rem; }
.chips a.pending { font-weight: 400; color: var(--muted); background: transparent; }

.scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
table { border-collapse: collapse; width: 100%; }
.specs th, .specs td { padding: 9px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.specs tbody tr:last-child > * { border-bottom: 0; }
.specs thead th { font-weight: 400; font-size: .82rem; color: var(--muted); background: var(--panel); min-width: 132px; }
.specs thead th strong { display: block; font-size: 1rem; color: var(--ink); }
.specs thead th a { color: inherit; text-decoration: none; }
.specs thead th.base, .specs td:nth-child(2) { background: var(--base-col); }
.specs .spec-col { width: 190px; min-width: 150px; font-weight: 600; font-size: .9rem; position: sticky; left: 0; background: var(--panel); z-index: 1; }
.specs .spec-col small { display: block; font-weight: 400; color: var(--muted); font-size: .72rem; }
.specs.wide { table-layout: fixed; min-width: 760px; }
.cell .val { display: block; font-variant-numeric: tabular-nums; font-weight: 600; }
.cell .val.text { font-weight: 500; font-size: .88rem; }
.specs.priority .cell .val { font-size: 1.22rem; }
.specs.priority .cell .val.text { font-size: 1rem; }
.cell .sub, .cell .diff { display: block; font-size: .74rem; color: var(--muted); }
.cell .basis { font-style: italic; }
.cell .diff { margin-top: 2px; font-variant-numeric: tabular-nums; }
.cell .diff.nobasis { font-style: italic; }
.cell.np span, td.np { color: var(--muted); font-size: .82rem; font-style: italic; }
.cell.best { background: var(--best) !important; } .cell.best .val { color: var(--best-ink); }
.cell.worst { background: var(--worst) !important; } .cell.worst .val { color: var(--worst-ink); }
.tag { display: inline-block; font-size: .64rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 1px 5px; border-radius: 4px; margin-top: 2px; }
.best-tag { color: var(--best-ink); border: 1px solid currentColor; } .worst-tag { color: var(--worst-ink); border: 1px solid currentColor; }
.col-meta { display: flex; flex-direction: column; gap: 3px; margin-top: 4px; font-size: .72rem; color: var(--muted); }
.override select { font: inherit; font-size: .74rem; max-width: 100%; padding: 2px 4px; border-radius: 6px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); }
details.more, .card details { margin-top: 12px; }
summary { cursor: pointer; font-weight: 600; padding: 10px 2px; color: var(--accent); }
details > .scroll, details > table { animation: reveal var(--ease); }
@keyframes reveal { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.missing { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 6px; font-size: .88rem; color: var(--muted); }
.missing strong { color: var(--ink); }

.yours { background: var(--yours); border: 1px solid var(--yours-line); border-radius: var(--radius); }
.yours h2 { margin-top: 12px; }
.yours .scroll { border-color: var(--yours-line); }

.pricing .cell .val { font-size: 1rem; }
.note { display: block; margin-top: 10px; font-size: .86rem; font-weight: 600; }
.note textarea { display: block; width: 100%; margin-top: 4px; font: inherit; font-weight: 400; padding: 9px 10px; border-radius: 8px; border: 1px solid var(--yours-line); background: var(--panel); color: var(--ink); resize: vertical; }
.saved { color: var(--muted); font-weight: 400; min-height: 1em; display: inline-block; transition: opacity var(--ease); }
.grid-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px 14px; align-items: end; }
.grid-form label { font-size: .82rem; font-weight: 600; display: flex; flex-direction: column; gap: 4px; }
.grid-form label.span { grid-column: 1 / -1; }
.grid-form label.check { flex-direction: row; align-items: center; gap: 8px; padding-bottom: 9px; }
.grid-form input:not([type=checkbox]) { font: inherit; padding: 9px 10px; border-radius: 8px; border: 1px solid var(--yours-line); background: var(--panel); color: var(--ink); }
.form-foot { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; }
.fuel { padding-left: 18px; }

.points { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 4px 14px 12px; margin: 12px 0; }
.points-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.points ul { margin: 0; padding-left: 18px; font-size: .9rem; }
.points li { margin-bottom: 4px; }
.points li small { color: var(--muted); font-style: italic; }
.adv h4 { color: var(--best-ink); } .weak h4 { color: var(--worst-ink); }

.detail th, .detail td { padding: 8px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.detail th { font-size: .88rem; min-width: 150px; }
.detail tr.variant td, .detail tr.variant th { border-top: 0; }
.detail .basis { font-style: italic; color: var(--muted); font-size: .8rem; }
.detail .cond { color: var(--muted); font-size: .76rem; }

/* Phone: one competitor at a time, swipe sideways. */
.narrow-only { display: none; }
@media (max-width: 899px) {
  .wide-only { display: none; }
  .narrow-only { display: block; }
  .pager { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; -webkit-overflow-scrolling: touch; margin: 0 -16px; padding: 4px 16px 12px; scrollbar-width: none; }
  .pager::-webkit-scrollbar { display: none; }
  .card { flex: 0 0 100%; scroll-snap-align: center; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 10px 12px; min-width: 0; }
  .card header h3 { margin: 2px 2px 0; font-size: 1.1rem; }
  .card .col-meta { margin: 2px 2px 8px; }
  .card .specs th, .card .specs td { padding: 8px 8px; }
  .card .specs .spec-col { width: 34%; min-width: 0; position: static; font-size: .82rem; }
  .card .specs thead th { min-width: 0; }
  .card .points { border: 0; padding: 0; margin-top: 8px; }
  .pager-dots { display: flex; justify-content: center; gap: 6px; margin: 10px 0 6px; }
  .pager-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--line); transition: background-color var(--ease), transform var(--ease); }
  .pager-dots i.on { background: var(--accent); transform: scale(1.3); }
  h1 { font-size: 1.3rem; }
}

/* One page shell for every machine: header, photo, tabs */
.head-row { display: flex; align-items: center; gap: 14px; }
.head-photo { width: 132px; height: 92px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); flex: none; }
.head-text { min-width: 0; }
.sub-title { margin: 0; color: var(--muted); font-size: .92rem; }
.crumb { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.tabs { display: flex; gap: 4px; margin: 14px -16px 0; padding: 0 16px; overflow-x: auto; border-bottom: 1px solid var(--line); scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { flex: none; padding: 10px 14px; color: var(--muted); text-decoration: none; font-weight: 500; font-size: 1rem; text-transform: uppercase; letter-spacing: .04em; border-bottom: 3px solid transparent; border-radius: 6px 6px 0 0; }
.tabs a:hover { color: var(--ink); background: color-mix(in srgb, var(--accent) 8%, transparent); }
.tabs a.on { color: var(--brand); border-bottom-color: var(--brand); }
.panel { padding-top: 6px; min-height: 40vh; }
.panel[hidden] { display: none; }

/* Logos, wordmarks, photos (loaded from the manufacturers' own sites) */
.logo { width: 18px; height: 18px; object-fit: contain; border-radius: 4px; background: #fff; flex: none; vertical-align: -3px; }
.brand-label { display: inline-flex; align-items: center; gap: 6px; }
.wordmark { height: 20px; width: auto; max-width: 124px; object-fit: contain; }
.wordmark.on-dark { box-sizing: content-box; height: 14px; padding: 4px 7px; border-radius: 4px; }
h3 > .logo, .crumb > .logo, .results .logo { margin-right: 6px; }
.col-photo { display: block; width: 100%; height: 70px; object-fit: contain; background: #fff; border-radius: 6px; margin-bottom: 6px; }
.specs thead th a { display: flex; flex-direction: column; gap: 2px; align-items: flex-start; }
.chips a { flex-direction: row; align-items: center; gap: 10px; }
.chips a > span { display: flex; flex-direction: column; }
.chip-photo { width: 54px; height: 38px; object-fit: contain; background: #fff; border-radius: 5px; flex: none; }
.card header { display: flex; gap: 10px; align-items: center; }
.card-photo { width: 84px; height: 60px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: 6px; flex: none; }
.profile { display: inline-flex; align-items: center; gap: 8px; font-size: .88rem; font-weight: 600; }
.avatar { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line); }
@media (max-width: 719px) { .profile span { display: none; } .profile { margin-left: auto; } .top nav { margin-left: 0; } }

/* Collapsible sections */
details.sec { margin-top: 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
details.sec.yours { background: var(--yours); border-color: var(--yours-line); padding: 0; }
details.sec > summary, details.sub-sec > summary { list-style: none; display: flex; align-items: center; gap: 8px; padding: 11px 14px; cursor: pointer; color: var(--ink); border-radius: var(--radius); transition: background-color var(--ease); }
details.sec > summary::-webkit-details-marker, details.sub-sec > summary::-webkit-details-marker { display: none; }
details.sec > summary::before, details.sub-sec > summary::before { content: ""; width: 8px; height: 8px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(-45deg); transition: transform var(--ease); flex: none; margin-right: 2px; }
details.sec[open]:not(.closing) > summary::before, details.sub-sec[open]:not(.closing) > summary::before { transform: rotate(45deg); }
details.sec > summary:hover, details.sub-sec > summary:hover { background: color-mix(in srgb, var(--accent) 6%, transparent); }
details.sec > summary h2, details.sub-sec > summary h3 { margin: 0; font-size: 1.05rem; display: flex; align-items: center; flex-wrap: wrap; gap: 2px 6px; }
details.sub-sec > summary h3 { font-size: .95rem; }
details.sec > .sec-body { padding: 0 14px 14px; }
details.sec > .sec-body > .scroll { border-radius: 8px; }
details.sub-sec { border-top: 1px solid var(--line); }
details.sub-sec.points { border: 1px solid var(--line); border-radius: var(--radius); margin: 10px 0 0; padding: 0; background: var(--panel); }
details.sub-sec > .sec-body { padding: 0 12px 12px; }
.card details.sub-sec > summary { padding: 10px 4px; } .card details.sub-sec > .sec-body { padding: 0 0 8px; }
.card details.sub-sec.points { border: 0; border-top: 1px solid var(--line); border-radius: 0; }
.yours .note:first-child { margin-top: 0; }
tr.grp th { background: var(--bg); font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 6px 12px; position: sticky; left: 0; text-align: left; }
.sheet tr.grp th { font-size: 6pt; padding: 1.5pt 5pt; background: #f2f2f2; }
.sheet .col-photo { height: .55in; margin-bottom: 2pt; } .sheet .wordmark { height: 10pt; } .sheet .wordmark.on-dark { height: 7pt; padding: 2pt 4pt; -webkit-print-color-adjust: exact; print-color-adjust: exact; } .sheet .logo { width: 9pt; height: 9pt; }
.sheet .brand-label { gap: 3pt; }
.edit { margin-left: 8px; font-size: .74rem; font-weight: 400; }

.src-tag { display: inline-block; font-size: .62rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 1px 5px; border-radius: 4px; border: 1px dashed currentColor; color: var(--muted); font-style: normal; }
.src-tag.third_party { color: #9a5a00; } .src-tag.user { color: var(--accent); }
@media (prefers-color-scheme: dark) { .src-tag.third_party { color: #e2a64a; } }
.sheet .src-tag { font-size: 5.5pt; padding: 0 3pt; }

/* Customer printout: the on-screen sheet is sized like the paper, so what you see is what prints. */
.print-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 16px; font-size: .9rem; }
.sheet-wrap { overflow-x: auto; }
.sheet-inner { transform-origin: top left; }
.fit-note { color: var(--muted); }
.sheet { background: #fff; color: #111; border: 1px solid var(--line); border-radius: 4px; padding: .4in; width: 8.5in; min-height: 11in; margin: 0 auto; font-size: 8.5pt; line-height: 1.3; --panel: #fff; --ink: #111; --muted: #555; --line: #cfcfcf; --base-col: #eef3fa; --best: #e3f3e6; --best-ink: #1c6b2e; --worst: #fbe9e6; --worst-ink: #a23a26; }
.sheet.many { width: 11in; min-height: 8.5in; }
.sheet header { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; border-bottom: 1.5pt solid #111; padding-bottom: 5pt; margin-bottom: 6pt; }
.sheet .crumb { font-size: 7.5pt; margin: 0 0 2pt; }
.sheet h1 { font-size: 13pt; margin: 0; } .sheet-logo img { display: block; height: 26pt; width: auto; margin-bottom: 3pt; } .sheet h2 { font-size: 9.5pt; margin: 8pt 0 3pt; }
.sheet .date { margin: 0; font-size: 8pt; white-space: nowrap; }
.sheet .specs { min-width: 0; table-layout: fixed; }
.sheet .specs th, .sheet .specs td { padding: 1.6pt 5pt; }
.sheet .specs .spec-col { position: static; width: 1.75in; min-width: 0; font-size: 8pt; }
.sheet .specs .spec-col small { font-size: 6.5pt; }
.sheet .specs thead th { min-width: 0; font-size: 7.5pt; } .sheet .specs thead th strong { font-size: 9.5pt; }
.sheet .cell .val, .sheet .specs.priority .cell .val { display: inline; font-size: 9pt; }
.sheet .specs.priority .cell .val { font-size: 10pt; }
.sheet .cell .val.text, .sheet .specs.priority .cell .val.text { font-size: 7.5pt; }
.sheet .cell .diff { display: inline; margin-left: 4pt; font-size: 6.5pt; white-space: nowrap; }
.sheet .cell .sub { display: none; font-size: 6.5pt; } .sheet .cell.offbasis .sub { display: inline; margin-left: 4pt; } .sheet .cell .cond { display: none; }
.sheet .cell .diff.nobasis { white-space: normal; }
.sheet .cell.np span, .sheet td.np { font-size: 7pt; }
.sheet .tag { font-size: 5.5pt; padding: 0 3pt; margin-left: 3pt; }
.sheet .adv-line { font-size: 8pt; margin: 3pt 0; }
.sheet footer { border-top: .75pt solid #cfcfcf; margin-top: 8pt; padding: 5pt 0 0; font-size: 6.5pt; color: #555; max-width: none; }
.sheet footer p { margin: 0; } .sheet footer ul { margin: 3pt 0 0; padding-left: 12pt; }
@page { size: letter landscape; margin: 0.4in; }
@page wide { size: letter landscape; margin: 0.4in; }
@media print {
  body { background: #fff; }
  .no-print { display: none !important; }
  main { padding: 0; max-width: none; }
  .sheet-wrap { overflow: visible; }
  .sheet { border: 0; padding: 0; width: auto; min-height: 0; margin: 0; }
  .sheet.many { page: wide; width: auto; min-height: 0; }
  .cell.best, .cell.worst, .specs thead th.base, .specs td:nth-child(2) { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  tr { break-inside: avoid; }
}

/* Printout: who prepared the sheet */
.sheet-by { text-align: right; }
.sheet .prepared { margin: 2pt 0 0; font-size: 7pt; line-height: 1.35; color: #333; }

/* Home: one row of chips per kind of machine within a brand */
.kind-label { margin: 14px 0 6px; font-family: var(--font-head); font-size: .78rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.kind-label:first-of-type { margin-top: 4px; }
.kind-label .count { font-weight: 400; }

/* A wordmark published only in black, shown in white on the maker's colour (see wordmark() in views.js) */
.wordmark.inverted { filter: invert(1); }
.sheet .wordmark.inverted { -webkit-print-color-adjust: exact; print-color-adjust: exact; }

/* Printout: one set of column widths for every table, a header that cannot push the sheet wider,
   and nothing drawn outside the page once the sheet has been scaled to fit. */
.sheet .specs { width: 100%; }
.sheet .specs col.spec-w { width: 1.75in; }
.sheet .specs th, .sheet .specs td { overflow-wrap: anywhere; }
.sheet header > div:first-child { min-width: 0; flex: 1 1 auto; }
.sheet-by { flex: 0 1 auto; max-width: 46%; }
.sheet .prepared { overflow-wrap: anywhere; }
.sheet.fitted { overflow: hidden; }

/* Printout is always landscape: a letter page on its side, whatever the number of machines. */
.sheet, .sheet.many { width: 11in; min-height: 8.5in; }
@media print { .sheet, .sheet.many { page: auto; width: auto; min-height: 0; } }
/* Options apply as they are changed; the sheet dims briefly while it is redrawn. */
.print-controls.live button[type="submit"] { display: none; }
.sheet-wrap { transition: opacity .18s ease; }
.sheet-wrap.updating { opacity: .45; }
@media (prefers-reduced-motion: reduce) { .sheet-wrap { transition: none; } }

/* Printout, landscape: rows are kept tight so a full spec list fits one page at a readable size. */
.sheet { line-height: 1.18; }
.sheet header { padding-bottom: 4pt; margin-bottom: 4pt; }
.sheet .specs th, .sheet .specs td { padding: .9pt 5pt; vertical-align: baseline; }
.sheet .specs thead th { padding-top: 2pt; padding-bottom: 2pt; vertical-align: bottom; }
.sheet .specs .spec-col { font-size: 7.5pt; }
.sheet .cell .val { font-size: 8.5pt; }
.sheet .specs.priority .cell .val { font-size: 9.5pt; }
.sheet .col-photo { height: .5in; margin-bottom: 1pt; }
.sheet h2 { margin: 5pt 0 2pt; }
.sheet .adv-line { margin: 2pt 0; }
.sheet footer { margin-top: 5pt; padding-top: 4pt; }

/* Comparison header: the Match menus share one row, so they sit level across the columns. */
.specs thead tr.has-match th { border-bottom: 0; padding-bottom: 4px; }
.specs thead tr.match-row th { padding-top: 0; padding-bottom: 9px; vertical-align: bottom; font-size: .72rem; }
.specs thead tr.match-row .override { display: flex; flex-direction: column; gap: 3px; }
.specs thead tr.match-row .override select { width: 100%; }

/* A section opened from a link lands below the sticky search bar, not under it. */
details.sec { scroll-margin-top: 84px; }

/* A pinned machine: first in its list, with a small pin at its corner. */
.chips li { position: relative; }
.chip-pin { display: none; position: absolute; top: -5px; right: -5px; width: 18px; height: 18px; border-radius: 50%; align-items: center; justify-content: center; background: var(--brand); color: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); pointer-events: none; }
.chip-pin svg { width: 11px; height: 11px; }
.chips li.pinned .chip-pin { display: inline-flex; }
.chips li.pinned > a { border-color: color-mix(in srgb, var(--brand) 55%, var(--line)); }

/* A brand thumbnail drawn from the brand's lettering (Kobelco, Hitachi): a small wide tile. */
.logo.mark { width: 34px; height: 18px; padding: 2px 3px; box-sizing: border-box; border-radius: 3px; }
.logo.mark.inverted { filter: invert(1); }

/* Compare: every machine by kind, makers together; tick machines to compare them */
.kind-head { margin: 22px 0 8px; font-size: 1.05rem; }
.chips li.ours > a { box-shadow: inset 3px 0 0 var(--brand); }
.chip-name { display: inline-flex; align-items: center; gap: 6px; }
.chip-name .logo { width: 16px; height: 16px; margin: 0; vertical-align: 0; }
.chip-name .logo.mark { width: 26px; height: 14px; padding: 1px 2px; }
.chips li:has(> .chip-pick) > a { padding-left: 34px; }
.chip-pick { position: absolute; top: 50%; left: 9px; z-index: 1; width: 18px; height: 18px; margin-top: -9px; cursor: pointer; }
.chip-pick input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.chip-pick i { display: block; width: 18px; height: 18px; border-radius: 5px; border: 1.5px solid var(--line); background: var(--panel); transition: background-color var(--ease), border-color var(--ease), box-shadow var(--ease), opacity var(--ease); }
.chip-pick:hover i { border-color: var(--brand); }
.chip-pick input:focus-visible + i { box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 28%, transparent); border-color: var(--brand); }
.chip-pick input:checked + i { border-color: var(--brand); background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 13px no-repeat; }
.chip-pick input:disabled { cursor: not-allowed; }
.chip-pick input:disabled + i { opacity: .35; }
.chips li.picked > a { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 7%, var(--panel)); }
.chips li > a { transition: border-color var(--ease), background-color var(--ease); }

.pick-bar { position: sticky; bottom: 14px; z-index: 30; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin: 18px 0 0; padding: 10px 14px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, .16); opacity: 0; transform: translateY(10px); transition: opacity .2s ease, transform .2s ease; }
.pick-bar.open { opacity: 1; transform: none; }
.pick-bar[hidden] { display: none; }
.pick-list { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.pick-chip { font: inherit; font-size: .84rem; font-weight: 700; padding: 5px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); cursor: pointer; transition: border-color var(--ease), background-color var(--ease); }
.pick-chip:hover { border-color: var(--brand); }
.pick-chip span { color: var(--muted); font-weight: 400; }
.pick-acts { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.pick-note { font-size: .82rem; color: var(--muted); }
.pick-bar .btn.off { opacity: .5; }
.page-head h1 .vs { font-size: .6em; color: var(--muted); padding: 0 .2em; }
@media (prefers-reduced-motion: reduce) { .pick-bar, .chip-pick i, .chips li > a { transition: none; } }

/* Compare: a machine is selected by clicking it, so its chip reads as a choice rather than a link */
[data-pick-only] .chips > li > a { cursor: pointer; }
[data-pick-only] .chips > li:has(input[data-pick]:disabled) > a { opacity: .5; cursor: not-allowed; }
.pick-bar [hidden] { display: none; }

/* The side-by-side of selected machines: one table, everything in view, sized to the page */
.panel { margin-top: 14px; padding: 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.panel > h2 { margin: 0 0 10px; font-size: 1.05rem; display: flex; align-items: center; flex-wrap: wrap; gap: 2px 8px; }
.panel > .scroll { border-radius: 8px; }
.points.plain { margin-top: 12px; } .points.plain > h3 { margin: 0 0 6px; font-size: .98rem; display: flex; align-items: center; flex-wrap: wrap; gap: 2px 6px; }
table.specs.fit { table-layout: fixed; width: 100%; min-width: 0; }
table.specs.fit col.spec-w { width: 178px; }
table.specs.fit thead th { min-width: 0; }
table.specs.fit .spec-col { width: auto; min-width: 0; }
table.specs.fit th, table.specs.fit td { overflow-wrap: anywhere; }
table.specs.fit .col-photo { max-width: 100%; height: auto; max-height: 76px; object-fit: contain; }
table.specs.fit.many th, table.specs.fit.many td { padding: 7px 8px; }
table.specs.fit.many .cell .val { font-size: .98rem; }
table.specs.fit.many col.spec-w { width: 150px; }
table.specs.fit tr.tier-head th { position: static; background: var(--bg); font-family: var(--font-head); font-size: .95rem; letter-spacing: .02em; text-transform: none; color: var(--ink); padding: 10px 12px; }
/* A phone cannot hold every column: there the table keeps a readable width and scrolls sideways. */
@media (max-width: 900px) { table.specs.fit { min-width: calc(140px + var(--cols) * 128px); } table.specs.fit col.spec-w { width: 140px; } }

/* A box above each machine, and the bar that acts on the boxes that are ticked */
.col-check { display: flex; align-items: center; gap: 6px; width: fit-content; margin: 0 0 6px; cursor: pointer; position: relative; }
.col-check input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.col-check i { display: block; width: 18px; height: 18px; border-radius: 5px; border: 1.5px solid var(--line); background: var(--panel); transition: background-color var(--ease), border-color var(--ease), box-shadow var(--ease); }
.col-check:hover i { border-color: var(--brand); }
.col-check input:focus-visible + i { box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 28%, transparent); border-color: var(--brand); }
.col-check input:checked + i { border-color: var(--brand); background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 13px no-repeat; }
table.specs thead th.col-picked { box-shadow: inset 0 3px 0 var(--brand); }
.col-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; min-height: 40px; margin: 0 0 4px; }
.col-bar-pick, .col-bar-ask { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: .9rem; opacity: 0; transform: translateY(4px); transition: opacity .18s ease, transform .18s ease; }
.col-bar-pick.on, .col-bar-ask.on { opacity: 1; transform: none; }
.col-bar [hidden] { display: none; }
.col-bar-ask { padding: 6px 10px; border-radius: 10px; background: color-mix(in srgb, #d7382a 9%, var(--panel)); border: 1px solid color-mix(in srgb, #d7382a 35%, var(--line)); }
.btn.danger { background: #c0392b; border-color: #c0392b; color: #fff; }
.btn.danger:hover { background: #a93226; border-color: #a93226; }
@media (prefers-reduced-motion: reduce) { .col-bar-pick, .col-bar-ask, .col-check i { transition: none; } }
table.specs.fit thead th a { max-width: 100%; min-width: 0; }
table.specs.fit .wordmark { max-width: 100%; box-sizing: border-box; }
table.specs.fit .wordmark.on-dark { box-sizing: border-box; height: 22px; }
table.specs.fit .brand-label { max-width: 100%; min-width: 0; }
