/* RRS Rentals - shared styles */
:root {
  --ink: #1f2933;
  --muted: #5f6b76;
  --bg: #ffffff;
  --panel: #f3f5f7;
  --line: #d9dee3;
  /* Brand colors from the RRS item viewer (ItemViewer.txt): crimson accent + dark maroon */
  --accent: #910039;
  --accent-dark: #5e0025;
  --max: 1040px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-dark); }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: #000; color: #fff; padding: 8px 12px;
}
.skip-link:focus { left: 0; z-index: 10; }

/* Header and navigation */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); }
.header-inner {
  max-width: var(--max); margin: 0 auto; padding: 14px 20px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; font-size: 1.5rem; font-weight: 700; color: var(--ink); text-decoration: none; }
.brand img { width: 40px; height: 40px; display: block; }
.nav { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.nav a { color: var(--ink); text-decoration: none; padding: 6px 2px; border-bottom: 2px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--accent); }

/* Layout */
main { max-width: var(--max); margin: 0 auto; padding: 32px 20px 48px; }
h1 { font-size: 2rem; line-height: 1.2; margin: 0 0 12px; }
h2 { font-size: 1.4rem; margin: 32px 0 10px; }
.lead { font-size: 1.15rem; color: var(--muted); }

.hero { background: var(--panel); border-bottom: 1px solid var(--line); }
.hero-inner { max-width: var(--max); margin: 0 auto; padding: 56px 20px; }
.hero h1 { font-size: 2.4rem; }

.button {
  display: inline-block; background: var(--accent); color: #fff; text-decoration: none;
  padding: 10px 20px; border-radius: 6px; font-weight: 600; border: 0; cursor: pointer; font-size: 1rem;
}
.button:hover { background: var(--accent-dark); }
.button.secondary { background: transparent; color: var(--accent-dark); border: 2px solid var(--accent); }

/* Card grid (home + equipment list) */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; margin-top: 16px; }
.card { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--bg); }
.card img { aspect-ratio: 3 / 2; object-fit: cover; width: 100%; background: var(--panel); }
.card-body { padding: 14px 16px 18px; }
.card h3 { margin: 0 0 6px; font-size: 1.1rem; }
.card p { margin: 0 0 10px; color: var(--muted); }

/* Equipment item page (matches the live test page: gallery, availability pill, rate card, info card) */
.breadcrumb { font-size: 0.9rem; color: var(--muted); margin-bottom: 16px; }
.status { color: var(--muted); }
#item-root h1 { text-align: center; margin-bottom: 20px; }

.gallery { display: grid; grid-template-columns: 76px 1fr; gap: 14px; align-items: start; max-width: 760px; margin: 0 auto 28px; }
.thumbs { display: flex; flex-direction: column; gap: 10px; }
.thumb { padding: 0; border: 2px solid transparent; border-radius: 6px; background: none; cursor: pointer; overflow: hidden; }
.thumb img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.thumb.active, .thumb:hover { border-color: var(--accent); }
.main-photo { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; background: var(--panel); }

.rate-card, .info-card {
  max-width: 760px; margin: 0 auto 24px; padding: 20px 24px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 2px 10px rgba(91, 4, 37, 0.10);
}
.pill {
  display: inline-block; background: var(--accent-dark); color: #fff; font-weight: 700;
  font-size: 0.85rem; letter-spacing: 0.03em; text-transform: uppercase;
  padding: 6px 16px; border-radius: 999px; margin-bottom: 8px;
}
.rate-row { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 0; border-bottom: 1px solid var(--line); }
.rate-row span { color: var(--muted); font-weight: 600; }
.rate-row strong { color: var(--accent-dark); font-size: 1.25rem; }
.rate-card h2, .info-card h2 { margin-top: 0; color: var(--accent-dark); }
.rate-card .button, .rate-card .button.secondary { margin-top: 6px; margin-right: 8px; }
.rate-card p { margin: 14px 0 0; }

.specs { width: 100%; border-collapse: collapse; margin: 18px 0; }
.specs th, .specs td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.specs th { width: 42%; color: var(--muted); font-weight: 600; }
.specs tr:nth-child(odd) { background: var(--panel); }
.feature-list { padding-left: 22px; margin: 18px 0; }
.feature-list li { margin: 6px 0; }
.compare-note { background: var(--panel); border-left: 4px solid var(--accent); padding: 10px 14px; margin: 20px 0 0; color: var(--muted); }
.note { background: var(--panel); border-left: 4px solid var(--accent); padding: 10px 14px; margin: 16px 0; }

/* Forms */
form { max-width: 560px; }
label { display: block; font-weight: 600; margin: 14px 0 4px; }
input, select, textarea {
  width: 100%; padding: 10px; font: inherit; border: 1px solid var(--line); border-radius: 6px;
}
textarea { min-height: 140px; resize: vertical; }
form .button { margin-top: 18px; }

/* Footer */
.site-footer { background: var(--panel); border-top: 1px solid var(--line); color: var(--muted); }
/* Compact footer: contact details + links share one wrapping row; copyright sits beneath. */
.footer-inner {
  max-width: var(--max); margin: 0 auto; padding: 12px 20px;
  font-size: 0.88rem; line-height: 1.45;
  display: flex; flex-wrap: wrap; gap: 2px 22px;
}
.footer-inner p { margin: 0; }
.footer-inner p:last-child { flex-basis: 100%; margin-top: 4px; font-size: 0.82rem; }

@media (max-width: 720px) {
  .gallery { grid-template-columns: 1fr; }
  .thumbs { flex-direction: row; order: 2; }
  .thumb { width: 64px; }
  .hero h1 { font-size: 1.9rem; }
}

/* ---------- Equipment index: search + category chips ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.filters { margin: 16px 0 8px; }
.filters input[type="search"] { max-width: 420px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.chip {
  border: 1px solid var(--line); background: var(--bg); color: var(--ink); border-radius: 999px;
  padding: 6px 14px; font: inherit; font-size: 0.92rem; cursor: pointer;
}
.chip:hover { border-color: var(--accent); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.card-cat { margin: 0 0 2px !important; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--accent) !important; font-weight: 600; }
.save-tag { display: inline-block; background: var(--panel); color: var(--accent-dark) !important; font-size: 0.82rem; font-weight: 600; padding: 2px 10px; border-radius: 999px; }

/* ---------- Interactive price chart ---------- */
.chart-card { overflow: visible; }
.price-chart { margin-top: 8px; }
.chart-tabs { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; margin-bottom: 16px; }
.chart-tab { border: 0; background: var(--bg); padding: 8px 18px; font: inherit; font-weight: 600; color: var(--muted); cursor: pointer; }
.chart-tab.active { background: var(--accent); color: #fff; }
.chart-tab:focus-visible, .legend-item:focus-visible, .bar-row:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.chart-summary { display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 0 0 16px; }
.chart-summary span { display: block; font-size: 0.8rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.chart-summary strong { font-size: 1.35rem; }
.chart-summary strong.ours, .chart-summary .saving strong { color: var(--accent-dark); }

.bars { display: grid; gap: 10px; }
.bar-row { display: grid; grid-template-columns: 130px 1fr 74px; align-items: center; gap: 10px; cursor: default; border-radius: 6px; }
.bar-row:hover { background: var(--panel); }
.bar-name { font-size: 0.92rem; font-weight: 600; }
.bar-row.ours .bar-name { color: var(--accent-dark); }
.bar-track { height: 22px; background: var(--panel); border-radius: 6px; overflow: hidden; display: block; }
.bar-fill { display: block; height: 100%; border-radius: 6px; transition: width 0.7s cubic-bezier(.2,.8,.2,1); }
.bar-row.ours .bar-fill { background: var(--accent); }
.bar-value { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.bar-row.ours .bar-value { color: var(--accent-dark); }

.chart-tip {
  position: absolute; transform: translate(-50%, -100%); background: var(--ink); color: #fff;
  padding: 6px 10px; border-radius: 6px; font-size: 0.85rem; white-space: nowrap; pointer-events: none; z-index: 5;
}
.chart-legend { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.legend-item { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--bg); border-radius: 999px; padding: 4px 12px; font: inherit; font-size: 0.85rem; cursor: pointer; }
.legend-item i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.legend-item.off { opacity: 0.45; text-decoration: line-through; }
.chart-note { font-size: 0.85rem; color: var(--muted); margin: 14px 0 0; }
.chart-table { margin-top: 12px; font-size: 0.9rem; }
.chart-table summary { cursor: pointer; color: var(--accent-dark); font-weight: 600; }
.chart-table table { border-collapse: collapse; margin-top: 8px; width: 100%; }
.chart-table th, .chart-table td { text-align: right; padding: 6px 10px; border-bottom: 1px solid var(--line); }
.chart-table th:first-child, .chart-table td:first-child { text-align: left; }
.chart-table tr.ours { color: var(--accent-dark); font-weight: 700; }

@media (max-width: 560px) {
  .bar-row { grid-template-columns: 1fr 64px; grid-template-areas: "name value" "track track"; gap: 4px 8px; }
  .bar-name { grid-area: name; } .bar-value { grid-area: value; } .bar-track { grid-area: track; }
}

.consent { max-width: 560px; margin-top: 20px; font-size: 0.9rem; color: var(--muted); }

/* ---------- Directions notice dialog ---------- */
.visit-dialog { border: 0; border-radius: 12px; padding: 24px 26px; max-width: 460px; width: calc(100% - 32px); box-shadow: 0 12px 40px rgba(0,0,0,0.3); color: var(--ink); }
.visit-dialog::backdrop { background: rgba(33, 33, 33, 0.55); }
.visit-dialog h2 { margin: 0 0 10px; color: var(--accent-dark); font-size: 1.25rem; }
.visit-dialog p { margin: 0 0 12px; }
.visit-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; }
.visit-actions .button { margin: 0; }
.visit-close { margin-left: auto; border: 0; background: none; color: var(--muted); font: inherit; text-decoration: underline; cursor: pointer; }
.directions-link { white-space: nowrap; }

/* =====================================================================
   v2 additions: pictures, calculator, lightbox, call bar, quote list,
   related items, category pages, printing
   ===================================================================== */
picture { display: block; }
.js-only[hidden] { display: none !important; }

/* ---------- Buttons row on the rate card ---------- */
.rate-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.rate-actions .button { margin: 0; }

/* ---------- Rental cost calculator ---------- */
.calc-card h2 { margin-top: 0; }
.calc-intro { margin: 0 0 12px; color: var(--muted); }
.calc-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.calc-row label { font-weight: 600; margin: 0; }
.calc-row input[type="number"] { width: 96px; }
.calc-row input[type="range"] { flex: 1 1 200px; width: auto; padding: 0; accent-color: var(--accent); }
#calc-result { margin-top: 14px; }
#calc-result p { margin: 8px 0; }
.calc-total { font-size: 1.15rem; }
.calc-total span { color: var(--muted); }
.calc-total strong { font-size: 1.7rem; color: var(--accent-dark); }
.calc-total small { color: var(--muted); }
.calc-note { font-size: 0.82rem; color: var(--muted); }

/* ---------- Gallery: zoom cursor, lightbox ---------- */
.main-photo[role="button"] { cursor: zoom-in; }
.lightbox { border: 0; padding: 0; width: 100vw; height: 100vh; max-width: none; max-height: none; background: rgba(15, 15, 15, 0.94); color: #fff; }
.lightbox::backdrop { background: rgba(0, 0, 0, 0.9); }
.lb-stage { position: absolute; inset: 56px 64px 44px; overflow: auto; display: flex; align-items: center; justify-content: center; }
.lb-stage img { max-width: 100%; max-height: 100%; object-fit: contain; cursor: zoom-in; user-select: none; }
.lb-stage.zoomed { display: block; }
.lb-stage.zoomed img { max-width: none; max-height: none; width: 220%; cursor: zoom-out; }
.lb-close { position: absolute; top: 8px; right: 14px; background: none; border: 0; color: #fff; font-size: 2.4rem; line-height: 1; cursor: pointer; z-index: 3; }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,0.14); border: 0; color: #fff; font-size: 1.6rem; width: 46px; height: 46px; border-radius: 50%; cursor: pointer; z-index: 3; }
.lb-nav:hover, .lb-close:hover { background: rgba(255,255,255,0.28); }
.lb-prev { left: 8px; }
.lb-next { right: 8px; }
.lb-count { position: absolute; bottom: 10px; left: 0; right: 0; text-align: center; margin: 0; font-size: 0.9rem; }
.lb-hint { position: absolute; bottom: 10px; right: 16px; margin: 0; font-size: 0.78rem; color: #bbb; }
@media (max-width: 640px) {
  .lb-stage { inset: 52px 8px 44px; }
  .lb-nav { width: 40px; height: 40px; background: rgba(0,0,0,0.45); }
  .lb-hint { display: none; }
}

/* ---------- Related items, category pages ---------- */
.related { margin-top: 36px; }
.related h2 { margin-top: 0; }
.cat-links { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 18px 0; }
.cat-links > span { font-weight: 600; color: var(--muted); margin-right: 4px; }
.chip-link { border: 1px solid var(--line); border-radius: 999px; padding: 4px 14px; font-size: 0.9rem; text-decoration: none; color: var(--ink); background: var(--bg); }
.chip-link:hover { border-color: var(--accent); color: var(--accent-dark); }
.cat-cta { margin: 28px 0 8px; display: flex; flex-wrap: wrap; gap: 10px; }
.cat-cta .button { margin: 0; }

/* ---------- Quote list ---------- */
.quote-badge { background: var(--accent); color: #fff !important; border-radius: 999px; padding: 4px 14px !important; border-bottom: 0 !important; font-size: 0.9rem; }
.quote-badge:hover { background: var(--accent-dark); }
.quote-box { max-width: 560px; border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px; margin: 24px 0; background: var(--panel); }
.quote-box h2 { margin: 0 0 8px; font-size: 1.15rem; color: var(--accent-dark); }
.quote-list { list-style: none; margin: 0; padding: 0; }
.quote-list li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 4px 12px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.quote-list li:last-child { border-bottom: 0; }
.quote-list small { color: var(--muted); display: block; }
.quote-remove { background: none; border: 0; color: var(--accent-dark); text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }
.quote-total { margin: 10px 0 0; font-weight: 600; }
.quote-clear { margin-top: 6px; }
.consent-row { display: flex; gap: 10px; align-items: flex-start; margin-top: 16px; }
.consent-row input { width: auto; margin-top: 5px; flex: none; }
.consent-row label { margin: 0; font-weight: 400; font-size: 0.9rem; color: var(--muted); }

/* ---------- Toast ---------- */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 10px 18px; border-radius: 8px; font-size: 0.95rem; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; z-index: 60; max-width: calc(100% - 32px); }
.toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast a { color: #fff; font-weight: 700; }

/* ---------- Mobile call bar ---------- */
.callbar { display: none; }
@media (max-width: 720px) {
  .callbar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; background: var(--accent); box-shadow: 0 -2px 10px rgba(0,0,0,0.2); padding-bottom: env(safe-area-inset-bottom); }
  .callbar a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 9px 4px 8px; color: #fff; text-decoration: none; font-size: 0.78rem; font-weight: 600; }
  .callbar a + a { border-left: 1px solid rgba(255,255,255,0.28); }
  .callbar a:active { background: var(--accent-dark); }
  body.has-callbar { padding-bottom: 62px; }
  .toast { bottom: 78px; }
}

/* ---------- Print sheet (hidden on screen) and price list ---------- */
.print-sheet { display: none; }
.pl-head { display: flex; align-items: center; gap: 16px; margin-bottom: 8px; }
.pl-head h1 { margin: 0; font-size: 1.7rem; }
.pl-head p { margin: 2px 0 0; color: var(--muted); }
.pl-cat h2 { margin: 24px 0 6px; font-size: 1.15rem; color: var(--accent-dark); }
.pl-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.pl-table th:first-child { width: 46%; }
.pl-table th:not(:first-child) { width: 18%; }
.pl-table th, .pl-table td { padding: 6px 10px; border-bottom: 1px solid var(--line); text-align: right; }
.pl-table th:first-child, .pl-table td:first-child { text-align: left; }
.pl-table thead th { color: var(--muted); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.04em; }
.pl-table tbody th { font-weight: 600; }
.pl-table a { color: inherit; text-decoration: none; }
.pl-foot { margin-top: 24px; font-size: 0.85rem; color: var(--muted); }

@media print {
  body > :not(.print-sheet) { display: none !important; }
  body { background: #fff !important; color: #000; padding: 0 !important; }
  .print-sheet { display: block; font-family: system-ui, -apple-system, "Segoe UI", Arial, sans-serif; }
  .ps-head { display: flex; align-items: center; gap: 12px; border-bottom: 3px solid #910039; padding-bottom: 8px; font-size: 9.5pt; line-height: 1.35; }
  .ps-title { font-size: 20pt; font-weight: 700; margin: 12px 0 0; line-height: 1.15; }
  .ps-cat { margin: 2px 0 8px; font-size: 9pt; text-transform: uppercase; letter-spacing: .06em; color: #910039; font-weight: 700; }
  .ps-photo { display: block; width: 100%; max-height: 3.1in; object-fit: cover; border-radius: 6px; margin-bottom: 10px; }
  .ps-rates { width: 100%; border-collapse: collapse; margin: 6px 0; }
  .ps-rates th { font-size: 8pt; text-transform: uppercase; letter-spacing: .05em; color: #555; text-align: center; padding: 4px; border-bottom: 1px solid #999; }
  .ps-rates td { text-align: center; font-size: 17pt; font-weight: 700; color: #5e0025; padding: 6px 4px; }
  .ps-save { text-align: center; font-size: 9pt; color: #5e0025; margin: 2px 0 8px; }
  .ps-specs { font-size: 9.5pt; line-height: 1.4; margin: 6px 0; padding-left: 18px; }
  .ps-foot { position: fixed; left: 0; right: 0; bottom: 0; border-top: 1px solid #999; padding-top: 5px; font-size: 7.5pt; color: #444; margin: 0; }
  a { color: inherit !important; text-decoration: none !important; }
}

/* price list page: show only the content block when printing */
@media print {
  body.price-list > :not(main) { display: none !important; }
  body.price-list main { display: block !important; padding: 0; max-width: none; }
  .no-print { display: none !important; }
  .pl-cat { break-inside: avoid; }
  .pl-table th, .pl-table td { padding: 3px 8px; font-size: 10pt; }
}

/* =====================================================================
   v3: equipment cards - photo with overlaid savings badge, price strip,
   full-width "View details" button on its own line
   ===================================================================== */
.card { display: flex; flex-direction: column; border-radius: 12px; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06); transition: box-shadow 0.2s, transform 0.2s; }
.card:hover { box-shadow: 0 8px 22px rgba(94, 0, 37, 0.16); transform: translateY(-2px); }
.card-media { position: relative; display: block; }
.card-media img { display: block; }
.save-badge {
  position: absolute; left: 10px; bottom: 10px;
  background: rgba(94, 0, 37, 0.94); color: #fff;
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.02em;
  padding: 5px 11px; border-radius: 999px; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}
.card-body { display: flex; flex-direction: column; flex: 1; padding: 14px 16px 16px; }
.card-body h3 { margin: 0 0 12px; font-size: 1.12rem; line-height: 1.25; }

.price-strip {
  display: grid; grid-template-columns: 1.35fr 1fr 1fr;
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px; overflow: hidden;
  margin: 0 0 14px;
}
.price { padding: 8px 6px 9px; text-align: center; min-width: 0; }
.price + .price { border-left: 1px solid var(--line); }
.p-label { display: block; font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 700; }
.p-amt { display: block; margin-top: 2px; font-weight: 800; font-size: 1.05rem; color: var(--accent-dark); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.price-day { background: #fff; box-shadow: inset 0 -3px 0 var(--accent); }
.price-day .p-amt { font-size: 1.6rem; line-height: 1.1; color: var(--accent); }

.card-btn { display: block; width: 100%; margin-top: auto; text-align: center; }

/* ---------- Availability pill variants (text comes from the D1 sync) ---------- */
.pill.pill-wait { background: #8a5a00; }
.pill.pill-off { background: #5f6b76; }

/* ---------- Contact form status + spam honeypot ---------- */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin: 14px 0 0; padding: 0; font-weight: 600; }
.form-status:empty { display: none; }
.form-status.ok, .form-status.err { padding: 10px 14px; border-radius: 6px; border-left: 4px solid; }
.form-status.ok { background: #eef7ee; border-color: #2e7d32; color: #1b4d1e; }
.form-status.err { background: #fdeeee; border-color: #b71c1c; color: #7f1212; }
.form-status:focus { outline: none; }

/* =====================================================================
   v5: footer pinned to the bottom, category chips as links, site-wide search
   ===================================================================== */
/* The footer sits at the bottom of the window even on a nearly empty page; long pages push it down as usual. */
html { min-height: 100%; }
body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
body > main { flex: 1 0 auto; width: 100%; }
body > .site-footer { flex-shrink: 0; }

/* Category bar: every chip is a link to a page */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 8px; }
a.chip { text-decoration: none; display: inline-block; }
a.chip:hover { border-color: var(--accent); }
a.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.chip-n { opacity: 0.7; font-size: 0.85em; }
.filters .chips { margin-top: 12px; }

/* Grouped search results on the equipment page */
.grid.grouped { display: block; }
.result-group { margin: 0 0 8px; }
.result-group h2 { margin: 26px 0 0; display: flex; align-items: baseline; gap: 10px; }
.result-group h2 small { font-size: 0.85rem; font-weight: 400; color: var(--muted); }
.result-group h2 a { text-decoration: none; }
.result-group h2 a:hover { text-decoration: underline; }

/* Header search box with grouped suggestions (added by site.js) */
.site-search { position: relative; flex: 1 1 240px; max-width: 360px; display: flex; }
.site-search input[type="search"] { width: 100%; padding: 8px 40px 8px 12px; border-radius: 999px; }
.site-search-btn {
  position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  width: 32px; height: 32px; border: 0; border-radius: 50%; background: transparent; color: var(--accent-dark);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
}
.site-search-btn:hover { background: var(--panel); }
.search-pop {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 40; max-height: 70vh; overflow-y: auto;
  background: var(--bg); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 10px 28px rgba(0, 0, 0, 0.18); padding: 6px 0;
}
.search-pop[hidden] { display: none; }
.search-cat { padding: 8px 14px 2px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.search-opt, .search-all { display: flex; justify-content: space-between; gap: 12px; padding: 8px 14px; color: var(--ink); text-decoration: none; }
.search-opt .p { color: var(--muted); font-size: 0.85rem; white-space: nowrap; }
.search-opt:hover, .search-opt.active, .search-all:hover, .search-all.active { background: var(--panel); }
.search-all { border-top: 1px solid var(--line); margin-top: 6px; color: var(--accent-dark); font-weight: 600; }
.search-empty { margin: 0; padding: 12px 14px; color: var(--muted); }
@media (max-width: 720px) {
  .site-search { order: 3; flex-basis: 100%; max-width: none; }
}

/* ---------- Little circled (i) on a photo: a short note such as "AI Generated" or "Background Modified" ---------- */
.main-photo-wrap { position: relative; }
.photo-info {
  position: absolute; top: 10px; right: 10px; z-index: 2; width: 30px; height: 30px; padding: 0;
  border-radius: 50%; border: 2px solid #fff; background: rgba(0, 0, 0, 0.62); color: #fff; cursor: pointer;
  font: italic 700 17px/1 Georgia, "Times New Roman", serif; display: flex; align-items: center; justify-content: center;
}
.photo-info[hidden], .photo-info-pop[hidden] { display: none; }
.photo-info:hover, .photo-info:focus-visible, .photo-info[aria-expanded="true"] { background: var(--accent); outline: none; }
.photo-info-pop {
  position: absolute; top: 48px; right: 10px; z-index: 2; max-width: min(75%, 320px); margin: 0; padding: 7px 12px;
  background: rgba(0, 0, 0, 0.88); color: #fff; border-radius: 8px; font-size: 0.88rem; line-height: 1.3;
}
.lb-info { position: absolute; left: 50%; bottom: 52px; transform: translateX(-50%); margin: 0; padding: 6px 14px; max-width: 90%; border-radius: 999px; background: rgba(0, 0, 0, 0.7); color: #fff; font-size: 0.9rem; text-align: center; }
.lb-info[hidden] { display: none; }
.i-dot { display: inline-flex; width: 18px; height: 18px; border: 1.5px solid #fff; border-radius: 50%; align-items: center; justify-content: center; font: italic 700 12px/1 Georgia, serif; margin-right: 4px; vertical-align: middle; }
