/* Shared by the home page and the browse page, on top of landing-v3.css:
   what a real listing card needs, and the browse page's own layout. */

/* The page below the header is drawn once, when the market has loaded, so
   nothing appears and then moves. Its room is kept meanwhile. */
body.loading main { visibility: hidden; min-height: 100vh; }
.links:empty { min-height: 40px; }
.links a { padding: 4px 0; font-weight: 600; white-space: nowrap; text-decoration: none; }

/* Listing cards. */
.who .nm { display: block; font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mock { font-size: 10px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); border: 1px dashed var(--line); border-radius: 5px; padding: 0 5px; }
.price small { font-size: 12px; font-weight: 500; color: var(--muted); }
.listing .line { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.listing.auction .badge { color: var(--text); }
.listing.seemore { min-height: 250px; }

/* The hero card for an item with no listing yet: a prompt, never a price. */
.deal .check { font-size: 14px; font-weight: 600; color: var(--accent); margin-top: 4px; }
.deal .badge { justify-self: center; }

/* Said in place of an empty shelf. */
.empty { border: 1px dashed var(--line); border-radius: 16px; padding: 36px 20px; display: grid; gap: 8px; justify-items: center; text-align: center; }
.empty b { font-size: 18px; }
.empty p { margin: 0 0 6px; color: var(--muted); max-width: 48ch; }
.empty[hidden] { display: none; }

/* In a category's sheet: on to that category's listings. */
.more.go { color: var(--accent); font-weight: 600; font-size: 14px; text-decoration: none; }
.more.go:hover { text-decoration: underline; }

/* The browse page. */
main.browse { gap: 16px; padding-top: 22px; }
.browse h1 { margin: 0; font-size: 28px; letter-spacing: -.02em; }
.browse .head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.browse .count { color: var(--muted); font-size: 14px; }
.filters { display: grid; gap: 12px; }
.filters .line { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; }
.cats-row { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 2px; }
.cats-row::-webkit-scrollbar { display: none; }
.cats-row .chip { white-space: nowrap; flex: none; }
.field { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.field input[type="text"], .field select { border: 1px solid var(--line); background: var(--panel); border-radius: 999px; padding: 7px 14px; color: var(--text); }
.field input[type="text"] { width: 120px; }
.field.check { cursor: pointer; color: var(--text); }
.cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); align-items: stretch; }
.cards .listing { width: auto; }
@media (max-width: 460px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } .cards .listing { padding: 10px; } }
.field[hidden] { display: none; }

/* The browse page, second pass: tabs with counts across the top, filters down
   the side, results beside them. */
.bz-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; }
.bz-tabs { display: flex; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 4px; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.bz-tabs button { border: 0; background: none; color: var(--muted); padding: 9px 16px; border-radius: 10px; font-weight: 600; font-size: 15px; cursor: pointer; white-space: nowrap; display: inline-flex; gap: 8px; align-items: center; }
.bz-tabs button:hover { color: var(--text); }
.bz-tabs button[aria-pressed="true"] { background: var(--accent); color: var(--accent-text); }
.bz-tabs .n { font-size: 12px; font-weight: 700; background: color-mix(in srgb, currentColor 16%, transparent); border-radius: 999px; padding: 1px 8px; font-variant-numeric: tabular-nums; }
.bz { display: grid; grid-template-columns: 236px minmax(0, 1fr); gap: 22px; align-items: start; }
.bz-side { position: sticky; top: 96px; display: grid; gap: 18px; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 16px; max-height: calc(100vh - 112px); overflow-y: auto; scrollbar-width: thin; }
.bz-group { display: grid; gap: 8px; }
.bz-group[hidden], .bz-check[hidden], .bz-clear[hidden], .bz-more[hidden] { display: none; }
.bz-group h2 { margin: 0; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
.bz-cats { display: grid; gap: 2px; }
.bz-cat { display: flex; justify-content: space-between; align-items: center; gap: 8px; border: 0; background: none; color: var(--text); padding: 7px 10px; border-radius: 9px; cursor: pointer; font-size: 14px; text-align: left; }
.bz-cat:hover { background: var(--chip); }
.bz-cat[aria-pressed="true"] { background: color-mix(in srgb, var(--accent) 18%, transparent); color: var(--accent); font-weight: 700; }
.bz-cat .n { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.bz-types { display: flex; flex-wrap: wrap; gap: 5px; }
.bz-types .chip { font-size: 12px; padding: 3px 9px; }
.bz-side input[type="text"] { width: 100%; min-width: 0; border: 1px solid var(--line); background: var(--bg); border-radius: 9px; padding: 8px 10px; color: var(--text); font-size: 14px; }
.bz-range { display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px; align-items: center; color: var(--muted); font-size: 13px; }
.bz-check { display: flex; gap: 8px; align-items: center; font-size: 14px; cursor: pointer; }
.bz-clear { border: 1px solid var(--line); background: none; color: var(--muted); border-radius: 9px; padding: 8px; cursor: pointer; font-size: 13px; }
.bz-clear:hover { color: var(--text); border-color: var(--accent); }
.bz-main { display: grid; gap: 14px; min-width: 0; }
.bz-bar { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; }
.bz-bar input[type="search"] { flex: 1 1 220px; min-width: 0; border: 1px solid var(--line); background: var(--panel); border-radius: 999px; padding: 9px 16px; color: var(--text); font-size: 15px; }
.bz-bar input:focus, .bz-side input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.bz-bar .count { margin-left: auto; color: var(--muted); font-size: 14px; white-space: nowrap; }
.cards.items { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; }
.icard { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 12px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); text-decoration: none; color: inherit; transition: border-color .12s ease, transform .12s ease; }
.icard:hover { border-color: var(--accent); transform: translateY(-1px); }
.icard .pic { width: 64px; height: 64px; border-radius: 12px; background: var(--tile); display: grid; place-items: center; overflow: hidden; }
.icard .txt { display: grid; gap: 1px; min-width: 0; }
.icard .txt > b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.icard small { color: var(--muted); font-size: 12px; }
.icard .mk { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.icard .mk b { color: var(--text); }
.icard .mk.live::before, .icard .mk.want::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 6px; background: #37b26c; vertical-align: 1px; }
.icard .mk.want::before { background: #3987e5; }
.icard .mk.none { opacity: .7; }
.icard.on { border-color: color-mix(in srgb, #37b26c 40%, var(--line)); }
.bz-more { justify-self: center; border: 1px solid var(--line); background: var(--panel); color: var(--text); border-radius: 999px; padding: 11px 26px; font-weight: 600; cursor: pointer; }
.bz-more:hover { border-color: var(--accent); }
@media (max-width: 900px) {
  .bz { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .bz-side { position: static; max-height: none; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 12px; }
  .bz-group.wide, .bz-clear { grid-column: 1 / -1; }
  .bz-cats { display: flex; overflow-x: auto; scrollbar-width: none; gap: 6px; }
  .bz-cat { flex: none; border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; white-space: nowrap; }
  .bz-types { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .bz-types .chip { flex: none; }
  .cards.items { grid-template-columns: minmax(0, 1fr); }
}
