/* StayWatch marketplace search page. Self-contained; no blur effects (they make scrolling janky). */
:root {
  --ink: #15333a; --muted: #5c6f72; --paper: #ffffff; --bg: #f6f4ee; --line: #e3e0d6;
  --sea: #0f5c66; --sea-ink: #ffffff; --sand: #efe7d6; --good: #1f6b45; --good-bg: #e6f2e8;
  --warn: #8a5a1c; --warn-bg: #fbf1e1; --radius: 14px;
  color-scheme: light;
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink); background: var(--bg);
}
* { box-sizing: border-box; }
body { margin: 0; line-height: 1.5; }
h1, h2, h3 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-weight: 400; letter-spacing: -0.02em; }
p { margin: 0; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid #3aa0ad; outline-offset: 2px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--paper); padding: 8px 12px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }

.top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px max(16px, 4vw); background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.brand { font-family: Georgia, serif; font-size: 24px; text-decoration: none; display: flex; align-items: center; gap: 8px; }
.brand-mark { color: var(--sea); }
.top nav { display: flex; gap: 20px; font-size: 14px; }
.top nav a { text-decoration: none; color: var(--muted); }
.top nav a:hover { color: var(--ink); }

main { max-width: 1180px; margin: 0 auto; padding: 0 max(16px, 4vw) 64px; }
.hero { padding: 48px 0 24px; display: grid; gap: 14px; }
.eyebrow { font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sea); font-weight: 600; }
.hero h1 { font-size: clamp(36px, 6vw, 64px); line-height: 1.05; }
.lede { max-width: 640px; color: var(--muted); font-size: 17px; }
.inventory { font-size: 13px; color: var(--muted); }

.ask { margin-top: 12px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: 0 10px 30px #15333a0d; }
.ask textarea { width: 100%; border: 0; resize: vertical; font-size: 17px; min-height: 84px; background: transparent; padding: 4px; }
.ask textarea:focus-visible { outline: none; }
.ask:focus-within { border-color: var(--sea); }
.ask-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { border: 1px solid var(--line); background: var(--bg); border-radius: 999px; padding: 6px 12px; font-size: 13px; }
.chip:hover { border-color: var(--sea); }
.primary { background: var(--sea); color: var(--sea-ink); border: 0; border-radius: 10px; padding: 12px 20px; font-weight: 600; }
.primary:disabled { opacity: 0.6; cursor: progress; }
.secondary { background: var(--paper); border: 1px solid var(--line); border-radius: 10px; padding: 10px 16px; }
.hint { font-size: 13px; color: var(--muted); margin-top: 8px; min-height: 1.5em; }
.hint.error { color: #9b2f25; }

.review { background: var(--paper); border: 1px solid var(--sea); border-radius: var(--radius); padding: 18px; display: grid; gap: 12px; }
.review h2 { font-size: 22px; }
.changes { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; font-size: 14px; }
.changes li { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--line); padding: 6px 0; }
.changes .label { color: var(--muted); }
.review form { display: flex; gap: 8px; flex-wrap: wrap; }
.review input[type="text"] { flex: 1; min-width: 200px; border: 1px solid var(--line); border-radius: 10px; padding: 10px; }
.review .actions { display: flex; gap: 10px; flex-wrap: wrap; }
.verify-note { font-size: 13px; background: var(--warn-bg); color: var(--warn); padding: 8px 10px; border-radius: 8px; }

.filters { margin: 8px 0 24px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.filters summary { padding: 14px 18px; cursor: pointer; font-weight: 600; }
.filter-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; padding: 0 18px 18px; }
.filter-grid label { display: grid; gap: 6px; font-size: 13px; font-weight: 600; }
.filter-grid input, .filter-grid select { border: 1px solid var(--line); border-radius: 8px; padding: 9px; background: var(--paper); min-width: 0; }
.prefs { grid-column: 1 / -1; border: 0; padding: 0; margin: 0; }
.prefs legend { font-size: 13px; font-weight: 600; margin-bottom: 8px; }
.pref-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.pref-grid label { background: var(--bg); padding: 10px; border-radius: 10px; font-weight: 500; }
.filter-actions { grid-column: 1 / -1; }

.results:focus { outline: none; }
.results-head { display: flex; justify-content: space-between; align-items: end; gap: 12px; flex-wrap: wrap; margin: 8px 0 18px; }
.results-head h2 { font-size: 30px; }
.results-head p { font-size: 13px; color: var(--muted); }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; display: grid; gap: 10px; align-content: start; }
.card-top { display: flex; justify-content: space-between; gap: 10px; align-items: start; }
.agency { font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--sea); font-weight: 600; }
.card h3 { font-size: 22px; }
.meta { font-size: 13px; color: var(--muted); }
.score { background: var(--good-bg); color: var(--good); border-radius: 10px; padding: 6px 10px; text-align: center; white-space: nowrap; }
.score strong { display: block; font-size: 20px; line-height: 1.1; }
.score small { font-size: 10px; }
.why { font-size: 14px; }
.why b { color: var(--good); font-weight: 600; }
.trade { font-size: 13px; color: var(--muted); }
.card details { font-size: 13px; }
.card details summary { cursor: pointer; color: var(--sea); }
.card details ul { margin: 8px 0 0; padding-left: 18px; }
.price { display: flex; justify-content: space-between; align-items: end; gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; }
.price strong { font-size: 22px; }
.price small { display: block; font-size: 12px; color: var(--muted); }
.view { background: var(--sea); color: var(--sea-ink); border: 0; border-radius: 10px; padding: 11px 14px; font-weight: 600; width: 100%; }
.view:disabled { background: var(--line); color: var(--muted); cursor: not-allowed; }
.more { text-align: center; margin: 24px 0; }

.confirm { margin-top: 36px; }
.confirm h3 { font-size: 22px; margin-bottom: 6px; }
.confirm > p { font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.confirm ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.confirm li { background: var(--sand); border-radius: 10px; padding: 12px 14px; font-size: 14px; }
.empty { background: var(--paper); border: 1px dashed var(--line); border-radius: var(--radius); padding: 28px; text-align: center; color: var(--muted); }
.loading { color: var(--muted); padding: 24px 0; }

.how, .agencies { margin-top: 64px; display: grid; gap: 16px; }
.how h2, .agencies h2 { font-size: 30px; }
.steps { margin: 0; padding-left: 20px; display: grid; gap: 10px; max-width: 760px; }
.agencies { background: var(--sea); color: var(--sea-ink); border-radius: var(--radius); padding: 28px; }
.agencies p { max-width: 640px; }

footer { border-top: 1px solid var(--line); padding: 24px max(16px, 4vw); font-size: 12px; color: var(--muted); display: grid; gap: 6px; background: var(--paper); }
.test-note { color: var(--warn); }

@media (max-width: 600px) {
  .top nav { display: none; }
  .hero { padding-top: 28px; }
  .ask-row { flex-direction: column; align-items: stretch; }
  .ask-row .primary { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
.contact { display: inline-block; background: var(--paper); color: var(--sea); text-decoration: none; font-weight: 600; border-radius: 10px; padding: 12px 18px; margin-bottom: 8px; }
.contact:hover { background: var(--sand); }
.contact-note { font-size: 13px; opacity: 0.9; }
