/* Pokémon Market set and product pages (/pokemon-market/<set>/ and /pokemon-market/<set>/<product>/,
   scripts/sections/market-pages.mjs). Loaded after fair-prices.css, whose header, answer line, picture tile, "Watch this
   price" button and tables these pages share; this file adds the product grid, the numbers, the chart, the store box and
   the alert note. Mobile first: at 400 px the H1 and the price line are the first screen. No inline styles (CSP). */
.mp-v { font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.fp-answer .mp-v { color: var(--lime); }
.mp-sub { display: block; font-size: 13px; color: var(--muted); }
.mp-singles .mp-sub { display: inline; }

/* The numbers under the header */
.mp-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0 0 28px; }
@media (min-width: 720px) { .mp-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.mp-stats > div { padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); min-width: 0; }
.mp-stats dt { font-size: 13px; font-weight: 700; color: var(--muted); }
.mp-stats dd { margin: 2px 0 0; }
.mp-stat { display: block; font-size: 20px; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }

/* The price chart: one line (the typical price) over the low-to-high band; no axes beyond the first and last day */
.mp-chart { margin: 0 0 8px; max-width: 760px; }
.mp-chart svg { display: block; width: 100%; height: 200px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); }
.mp-chart figcaption { margin-top: 6px; font-size: 14px; color: var(--muted); }
.mp-line { fill: none; stroke: var(--blue); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.mp-band { fill: var(--blue); opacity: .14; }
.mp-grid { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.mp-pt { fill: transparent; stroke: none; }
.mp-pt:hover { fill: var(--blue); }
.mp-hit-end { fill: var(--blue); stroke: var(--bg-alt); stroke-width: 2; vector-effect: non-scaling-stroke; }
.mp-ax { font-size: 12px; fill: var(--muted); }
.mp-table { margin: 8px 0 0; max-width: 760px; }
.mp-table summary { cursor: pointer; font-weight: 700; min-height: 44px; display: flex; align-items: center; }
.mp-table .fp-table { min-width: 0; }

/* A set's products */
.mp-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 640px) { .mp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .mp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.mp-card-a { display: flex; gap: 12px; align-items: center; min-height: 72px; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); color: var(--text); text-decoration: none; }
.mp-card-a:hover { border-color: var(--blue); }
.mp-card-a:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
.mp-card-t { display: grid; gap: 2px; min-width: 0; }
.mp-card-n { font-weight: 800; color: var(--ink); }
.mp-card-l { font-size: 14px; }
.mp-card-c { font-size: 13px; color: var(--muted); }

.mp-singles { margin: 0; padding-left: 22px; display: grid; gap: 8px; }
.mp-facts, .mp-links { margin: 0; padding-left: 20px; display: grid; gap: 6px; line-height: 1.5; }
.mp-links a, .mp-facts a { padding-block: 2px; } /* inline: a long title wraps beside its bullet; 1.5 line height keeps a 24px tap */
.mp-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.mp-chips a { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 14px; border: 1px solid var(--border); border-radius: 999px; color: var(--ink); font-weight: 700; text-decoration: none; }
.mp-chips a:hover { border-color: var(--blue); color: var(--blue); }

/* The store box: free members get the cheapest stores (market-pages.js); visitors the join line */
.mp-gate { max-width: 760px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); }
.mp-gate[hidden], .mp-list[hidden] { display: none; }
.mp-gate p { margin: 0 0 10px; }
.mp-gate-act { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin: 0 !important; font-size: 14px; }
.mp-btn { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 18px; border-radius: 999px; background: var(--blue); color: #fff; font-weight: 800; text-decoration: none; }
.mp-btn:hover { filter: brightness(1.08); }
.mp-btn:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
.mp-stores { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; max-width: 760px; }
/* The price comparison's per-store cards, folded under one line once the compact list is on the page (UX audit 2026-11-19 #3). */
.fp-compare-fold { margin: 0 0 24px; max-width: 760px; }
.fp-compare-fold > summary { display: flex; align-items: center; min-height: 44px; padding: 8px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); font-weight: 700; color: var(--ink); cursor: pointer; }
.fp-compare-fold[open] > summary { margin-bottom: 12px; }
.mp-stores li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); }
.mp-stores li.is-best { border-color: var(--blue); }
.mp-st-n { font-weight: 800; color: var(--ink); }
.mp-st-side { text-align: right; flex: none; }
.mp-st-side a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 700; }
.mp-pill { display: inline-block; margin-right: 6px; padding: 0 8px; border-radius: 999px; background: var(--bg-soft); font-size: 12px; font-weight: 800; line-height: 1.7; color: var(--ink); }
/* an outlier price (src/assets/market-moves.js outliers): listed, never the cheapest; a plain note, not an alarm */
.mp-pill.is-warn { background: transparent; border: 1px solid var(--border); border-radius: 6px; font-weight: 700; color: var(--muted); }

/* The free price email's link (in the dark header; market-pages.mjs priceMailLink): shown to members too. */
.mp-mail-link { margin: 6px 0 0; font-size: 14px; line-height: 1.5; color: #d4dcf1; }
.mp-mail-link a { color: #fff; font-weight: 800; }

@media (prefers-reduced-motion: no-preference) { .mp-card-a, .mp-chips a { transition: border-color .15s, color .15s; } }
@media (forced-colors: active) { .mp-line { stroke: CanvasText; } .mp-band { fill: GrayText; } }
/* The set's card price pages under its top singles (card pages audit 2026-11-15). */
.mp-cardsets { margin: 12px 0 0; font-weight: 600; }
/* "Buy in Canada or from the US?" (scripts/lib/landed-sealed.mjs): one summary line under the price, the parts inside. */
.mp-us { margin: 10px 0 0; max-width: 760px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-alt); }
.mp-us summary { cursor: pointer; padding: 10px 14px; list-style-position: outside; line-height: 1.5; }
.mp-us summary:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
.mp-us-h { display: block; font-weight: 800; color: var(--ink); }
.mp-us-line { font-size: 15px; color: var(--text); }
.mp-us-verdict { color: var(--ink); }
.mp-us-body { padding: 0 14px 12px; }
.mp-us-est { margin: 0 0 8px; font-size: 14px; }
.mp-us-parts { margin: 0 0 8px; padding-left: 18px; font-size: 14px; line-height: 1.55; }
.mp-us-parts li { margin: 4px 0; overflow-wrap: anywhere; }
.mp-us summary { list-style: none; }
.mp-us summary::-webkit-details-marker { display: none; }
.mp-us-h::after { content: " \25B8"; color: var(--muted); }
.mp-us[open] .mp-us-h::after { content: " \25BE"; }
/* Where to buy, near the top, for everyone (Lane 17, owner 2026-11-17) */
.mp-storebox h2 { margin-bottom: 8px; }
.mp-stores li { min-height: 64px; }
.mp-st-main { min-width: 0; }
.mp-st-side { display: grid; justify-items: end; gap: 0; }
.mp-st-side .mp-v { font-size: 20px; }
.mp-pp { font-size: 12.5px; color: var(--muted, #667); }
.mp-buy { min-height: 44px; display: inline-flex; align-items: center; font-weight: 800; }
.mp-none { max-width: 760px; padding: 12px 14px; border: 1px dashed var(--border); border-radius: var(--radius); margin: 0; }
.mp-buys { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 8px; max-width: 760px; }
.mp-buys li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg); }
.mp-h3 { font-size: 16px; margin: 10px 0 6px; }
.mp-more { max-width: 760px; margin: 6px 0 10px; }
.mp-more summary { min-height: 44px; display: flex; align-items: center; font-weight: 700; cursor: pointer; }
/* Every store (2026-11-19): pre-orders and recently sold out after the stores in stock; the rest under "Show all N stores" */
.mp-allstores { margin: 8px 0 10px; }
.mp-allstores > .mp-stores { margin-top: 4px; }
.mp-stores li.is-out { background: var(--bg); }
.mp-stores li.is-out .mp-v { font-size: 17px; color: var(--muted, #667); }
