/* The viewer's listing card, shared by insights.html and the client app. Colors come from the page's
   --bg, --surface, --text, --muted, --border, --accent, --ok, --warn and --bad. */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); gap: 16px; padding: 0 24px 32px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; display: grid;
        align-content: start; grid-template-columns: minmax(0, 1fr); min-width: 0; }
.strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 2px; background: var(--border); }
.strip img { width: 100%; aspect-ratio: 730 / 532; object-fit: cover; display: block; background: var(--border); cursor: zoom-in; }
/* Full-size photos of one listing, one at a time. */
.lb { border: 0; padding: 0; margin: 0; width: 100vw; height: 100dvh; max-width: none; max-height: none; background: #000; color: #fff; }
.lb::backdrop { background: #000; }
.lb img { position: absolute; inset: 0; margin: auto; max-width: 100%; max-height: 100%; object-fit: contain; user-select: none; }
.lb button { position: absolute; background: rgba(0, 0, 0, .45); color: #fff; border: 0; border-radius: 999px;
             width: 48px; height: 48px; font-size: 28px; line-height: 1; cursor: pointer; }
.lb button:hover { background: rgba(0, 0, 0, .7); }
.lb .prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb .next { right: 12px; top: 50%; transform: translateY(-50%); }
.lb .close { right: 12px; top: 12px; font-size: 24px; }
.lb .count { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); font-size: 14px;
             background: rgba(0, 0, 0, .45); padding: 4px 10px; border-radius: 999px; font-variant-numeric: tabular-nums; }
.body { padding: 12px 14px 14px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; min-width: 0; }
.head { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.head > div:first-child { min-width: 0; flex: 1; }
.title { font-weight: 600; }
.price { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 600; flex-shrink: 0; text-align: right; }
.summary { background: var(--bg); border-radius: 6px; padding: 8px 10px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
/* Short chips stay on one line; long ones (e.g. a quoted amount) wrap inside the card instead of widening it. */
.chip { font-size: 12px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border); max-width: 100%; overflow-wrap: anywhere; }
.chip[title] { cursor: help; text-decoration: underline dotted var(--muted); text-underline-offset: 3px; }
.chip.good { color: var(--ok); border-color: currentColor; }
.chip.warn { color: var(--warn); border-color: currentColor; }
.chip.bad { color: var(--bad); border-color: currentColor; }
.label { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; }
ul.flags { margin: 0; padding-left: 18px; color: var(--warn); font-size: 13px; }
details.more summary { cursor: pointer; font-size: 12px; color: var(--warn); margin-top: 4px; }
ul.checks { margin: 0; padding-left: 18px; color: var(--muted); font-size: 12px; }
.foot { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--muted); }
.empty { padding: 40px 24px; color: var(--muted); }
.card .muted { color: var(--muted); font-size: 12px; }
.card a { color: var(--accent); text-decoration: none; }
.card a:hover { text-decoration: underline; }
@media (max-width: 520px) { .cards { grid-template-columns: 1fr; padding: 0 16px 24px; } }
