/* Restock week */
.rs { display: flex; flex-direction: column; gap: 6px; }
.rs-row { display: grid; grid-template-columns: minmax(110px, 1.4fr) repeat(7, minmax(22px, 1fr)) minmax(70px, 1fr); gap: 6px; align-items: center; }
.rs-head span { text-align: center; font-size: 11px; font-weight: 600; color: var(--faint); }
.rs-head span.today { color: var(--text); }
.rs-store b { display: block; font-size: 14px; font-weight: 600; } .rs-store small { font-size: 12px; color: var(--mute); }
.rs-d { display: block; height: 28px; border-radius: 8px; }
.rs-d.lv0 { background: transparent; box-shadow: inset 0 0 0 1px var(--line); opacity: .5; }
.rs-d.lv1 { background: color-mix(in srgb, var(--fair) 14%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fair) 35%, transparent); }
.rs-d.lv2 { background: var(--buy); }
.rs-d.today { outline: 2px solid var(--text); outline-offset: 2px; }
.rs-next { font-size: 11px; color: var(--mute); text-align: right; line-height: 1.2; }
.rs-next b { display: block; font-size: 13px; color: var(--text); text-transform: capitalize; }
.rs-key { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; margin-top: 6px; font-size: 12px; color: var(--mute); }
.rs-key span { display: inline-flex; align-items: center; gap: 6px; } .rs-key .rs-d { width: 14px; height: 14px; border-radius: 4px; display: inline-block; }
.rs-key .rs-src { color: var(--faint); margin-left: auto; }
/* Receipt */
.rc { background: var(--raise); border-radius: var(--r-s); padding: var(--sp-3) var(--sp-4); }
.rc-row { display: flex; justify-content: space-between; align-items: baseline; padding: 6px 0; font-size: 14px; color: var(--mute); }
.rc-row b { color: var(--text); font-weight: 600; }
.rc-row.minus b { color: var(--mute); }
.rc-row.total { border-top: 1px dashed var(--line); margin-top: 4px; padding-top: 10px; color: var(--text); font-weight: 600; }
.rc-row.total b { font: 700 24px var(--f-big); letter-spacing: -.02em; }
.rc-bars { display: grid; gap: 6px; margin-top: var(--sp-3); position: relative; }
.rc-bar { display: grid; grid-template-columns: 110px minmax(0, 1fr) 70px; gap: var(--sp-3); align-items: center; font-size: 13px; color: var(--mute); }
.rc-bar i { height: 10px; border-radius: 5px; display: block; } .rc-bar i.paid { background: var(--mute); } .rc-bar i.up { background: var(--buy); } .rc-bar i.dn { background: var(--bad); }
.rc-bar b { text-align: right; color: var(--text); font-weight: 600; }
.rc-result { justify-self: end; font: 700 16px var(--f-big); letter-spacing: -.02em; padding: 4px 10px; border-radius: 10px; }
.rc-result small { font: 600 12px var(--f-ui); margin-left: 4px; }
.rc-result.up { color: var(--buy); background: color-mix(in srgb, var(--buy) 12%, transparent); } .rc-result.dn { color: var(--bad); background: color-mix(in srgb, var(--bad) 12%, transparent); }
.rc-note { display: flex; gap: var(--sp-2); flex-wrap: wrap; margin-top: var(--sp-3); }
.rc-chip { font-size: 13px; padding: 5px 10px; border-radius: 99px; background: var(--surface); color: var(--mute); } .rc-chip b { color: var(--text); }
/* Timeline */
.tl { list-style: none; margin: 0; padding: 0; position: relative; }
.tl li { display: grid; grid-template-columns: 74px minmax(0, 1fr); gap: var(--sp-3); padding: 8px 0; position: relative; }
.tl li + li::before { content: ''; position: absolute; left: 36px; top: -8px; height: 14px; border-left: 1px dashed var(--line); }
.tl-date { font-size: 12px; font-weight: 600; color: var(--mute); background: var(--raise); border-radius: 8px; padding: 4px 6px; text-align: center; align-self: start; }
.tl-body { font-size: 14px; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; }
.tl-pill { font-size: 11px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--wait); background: color-mix(in srgb, var(--wait) 12%, transparent); padding: 2px 7px; border-radius: 6px; }
.tl-line { color: var(--text); }
.tl details { width: 100%; font-size: 13px; color: var(--mute); } .tl summary { cursor: pointer; color: var(--fair); font-weight: 600; font-size: 12px; } .tl details p { margin-top: 4px; line-height: 1.45; }
/* Locks inside free sections */
.lockrow { all: unset; cursor: pointer; display: grid; grid-template-columns: 12px 150px minmax(0, 1fr) auto; gap: var(--sp-3); align-items: center; width: 100%; box-sizing: border-box; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; }
.lockrow::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: transparent; box-shadow: inset 0 0 0 1.5px #FFB84D; }
.lockrow .n { font-weight: 600; } .lockrow .h { color: var(--faint); }
.locktile { all: unset; cursor: pointer; box-sizing: border-box; display: flex; flex-direction: column; gap: 2px; padding: var(--sp-3); border-radius: var(--r-s); background: var(--raise); box-shadow: inset 0 0 0 1px rgba(255, 184, 77, .35); }
.locktile span:first-child { color: var(--mute); font-size: 12px; } .locktile b { margin: 2px 0; } .locktile small { font-size: 12px; color: #FFD27A; }
.mk.lockd { box-shadow: inset 0 0 0 1px rgba(255, 184, 77, .4); }
.mk.lockd i { background: transparent; box-shadow: inset 0 0 0 1.5px #FFB84D; }
.callrow { display: flex; align-items: center; gap: var(--sp-3); flex-wrap: wrap; margin-bottom: var(--sp-2); }
.cta-card { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); padding: var(--sp-3) var(--sp-4); border-radius: var(--r-s); background: var(--raise); }
.cta-card span { font-size: 14px; color: var(--mute); } .cta-card b { display: block; color: var(--text); font-weight: 600; }
@media (max-width: 760px) {
  .rs-row { grid-template-columns: minmax(84px, 1.3fr) repeat(7, minmax(18px, 1fr)); gap: 4px; }
  .rs-next { display: none; } .rs-d { height: 24px; border-radius: 6px; }
  .rs-key .rs-src { margin-left: 0; width: 100%; }
  .lockrow { grid-template-columns: 12px minmax(0, 1fr) auto; } .lockrow .h { display: none; }
  .rc-bar { grid-template-columns: 90px minmax(0, 1fr) 60px; }
}
/* Outcome strip */
.oc { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; height: 132px; align-items: end; padding-top: 4px; }
.oc-col { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; gap: 4px; }
.oc-col i { width: 100%; border-radius: 6px 6px 3px 3px; display: block; }
.oc-col.dn i { background: color-mix(in srgb, var(--bad) 70%, transparent); } .oc-col.flat i { background: var(--mute); } .oc-col.up i { background: var(--buy); }
.oc-n { font-size: 12px; font-weight: 600; color: var(--text); }
.oc-l { font-size: 11px; color: var(--mute); text-align: center; white-space: nowrap; }
.oc-head { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: baseline; margin-bottom: var(--sp-3); }
.oc-head b { font: 700 22px var(--f-big); letter-spacing: -.02em; } .oc-head span { font-size: 13px; color: var(--mute); }
/* Month strip */
.mo { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; }
.mo-c { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.mo-c i { display: block; width: 100%; height: 30px; border-radius: 7px; background: color-mix(in srgb, var(--wait) calc(var(--f) * 75%), color-mix(in srgb, var(--buy) 75%, transparent)); opacity: calc(.45 + .55 * (1 - 2 * min(var(--f), 1 - var(--f)))); }
.mo-c b { font-size: 11px; font-weight: 600; color: var(--mute); }
.mo-c.now i { outline: 2px solid var(--text); outline-offset: 2px; } .mo-c.now b { color: var(--text); }
.mo-k { width: 14px; height: 14px; border-radius: 4px; display: inline-block; } .mo-k.lo { background: color-mix(in srgb, var(--buy) 75%, transparent); } .mo-k.hi { background: var(--wait); }
@media (max-width: 760px) { .oc-l { font-size: 10px; white-space: normal; line-height: 1.1; } .oc { height: 150px; } }

.tl li.new .tl-date { background: color-mix(in srgb, var(--buy) 14%, var(--raise)); color: var(--text); }
.tl-new { display: block; font: 700 9px var(--f-big); letter-spacing: .06em; text-transform: uppercase; color: var(--buy); }

/* multiChart: calm % change lines, one dash per line, a crosshair; values are shown beside the chart, not over it */
.mc { height: 250px; border-radius: 12px; -webkit-tap-highlight-color: transparent; }   /* compare charts: the Pulse chart in % mode */
@media (max-width: 480px) { .mc { height: 210px; } }

/* store mark: a placeholder until each retailer's official logo comes from its affiliate brand kit */
.store-mark { flex: none; display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; font: 800 11px/1 var(--f-big); letter-spacing: -.02em; box-shadow: inset 0 0 0 1px #ffffff1a; }

/* ---------- shared since Explore: section header (UI.secHead), dropdown (.w-dd), segmented control (.seg) ---------- */
.w-band { padding-top: var(--sp-6); border-top: 1px solid var(--line); scroll-margin-top: 64px; }
.sec-h { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: var(--sp-3) var(--sp-4); align-items: center; margin-bottom: var(--sp-5); }
.sec-ic { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: var(--raise); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.w-sec .sec-h h2 { font: 700 20px/1.2 var(--f-big); letter-spacing: -.02em; margin: 0; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.sec-n { font: 700 13px var(--f-big); color: var(--mute); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); padding: 4px 9px; border-radius: 9px; letter-spacing: 0; }
.sec-sub { margin: 4px 0 var(--sp-5) calc(44px + var(--sp-4)); font-size: 14px; color: var(--mute); }
.sec-h.has-sub { margin-bottom: 0; }
.sec-stick + .sec-sub { margin-left: 0; margin-top: 0; margin-bottom: var(--sp-4); }
.sec-act { display: flex; align-items: center; gap: var(--sp-2); }
.w-addbtn { all: unset; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 12px; background: var(--buy); color: var(--deep); font-weight: 700; font-size: 14px; white-space: nowrap; }
.w-addbtn:hover { filter: brightness(1.08); } .w-addbtn:focus-visible { box-shadow: 0 0 0 2px var(--deep), 0 0 0 4px var(--text); }
.sec-more { width: 40px; height: 40px; color: var(--mute); }
.w-band h3 { font: 600 16px var(--f-ui); margin: 0 0 var(--sp-3); }
.w-band .w-two { margin-bottom: var(--sp-5); }
.w-dd { all: unset; cursor: pointer; position: relative; display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 14px; border-radius: 12px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); min-width: 0; box-sizing: border-box; transition: background var(--dur-1); }
.w-dd .k { font-size: 12px; color: var(--mute); white-space: nowrap; } .w-dd b, .w-dd select { font: 600 14px var(--f-ui); color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.w-dd .n { font: 700 12px var(--f-big); color: var(--faint); } .w-dd > svg:last-child { color: var(--mute); flex: none; }
.w-dd > svg:first-child { color: var(--text); flex: none; }
.w-dd:hover { background: var(--raise); } .w-dd:focus-visible, .w-dd:focus-within { box-shadow: inset 0 0 0 1px var(--line), 0 0 0 2px var(--text); }
.w-dd-sel select { appearance: none; -webkit-appearance: none; background: transparent; border: 0; padding: 0 18px 0 0; margin-right: -22px; cursor: pointer; outline: none; max-width: 170px; }
.w-dd-sel select option { background: var(--surface); color: var(--text); }
.w-dd-sel > svg { pointer-events: none; }
.seg { position: relative; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 4px; margin: var(--sp-4) 0 var(--sp-4); border-radius: 13px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.seg button { all: unset; position: relative; z-index: 1; cursor: pointer; text-align: center; height: 36px; line-height: 36px; border-radius: 9px; font: 600 13px var(--f-ui); color: var(--mute); transition: color var(--dur-2); }
.seg button[aria-pressed=true] { color: var(--text); } .seg button:hover { color: var(--text); }
.seg button:focus-visible { box-shadow: 0 0 0 2px var(--text); }
.seg-ind { position: absolute; top: 4px; bottom: 4px; left: 0; width: 0; border-radius: 9px; background: var(--raise); box-shadow: 0 2px 10px #0007, inset 0 0 0 1px var(--line); transition: transform var(--dur-3) var(--ease-out); }
@media (max-width: 760px) {
  .sec-h { grid-template-columns: 40px minmax(0, 1fr); margin-bottom: var(--sp-4); }
  .sec-ic { width: 40px; height: 40px; border-radius: 12px; }
  .sec-act { grid-column: 1 / -1; }
  .sec-more { width: 44px; height: 44px; }
  .w-sec .sec-h h2 { font-size: 18px; }
  .w-band { scroll-margin-top: 56px; }
}
@media (pointer: coarse), (max-width: 760px) { .seg button { height: 44px; line-height: 44px; } }
@media (prefers-reduced-motion: reduce) { .seg-ind { transition: none; } }

/* shared: cards that act as a chart legend, the calm empty state, Show more, the live dot */
.dotlive { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--buy); margin-right: 6px; vertical-align: 1px; box-shadow: 0 0 0 3px color-mix(in srgb, var(--buy) 25%, transparent); }
.sp-more .d { display: none; }
.sp-more { all: unset; cursor: pointer; display: block; margin: var(--sp-3) auto 0; padding: 12px 18px; min-height: 20px; border-radius: 12px; background: var(--surface); font-weight: 600; font-size: 14px; color: var(--text); }
.sp-more:hover { background: var(--raise); } .sp-more:focus-visible { box-shadow: 0 0 0 2px var(--text); }
.w-quiet { display: flex; align-items: center; gap: var(--sp-4); padding: var(--sp-5); border-radius: var(--r); background: var(--surface); }
.w-quiet i { flex: none; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: color-mix(in srgb, var(--buy) 14%, transparent); color: var(--buy); }
.w-quiet b { display: block; font-size: 16px; font-weight: 600; margin-bottom: 2px; } .w-quiet span { font-size: 14px; color: var(--mute); }
.cmp-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: var(--sp-2); margin-top: var(--sp-4); }
.cmp-card { all: unset; cursor: pointer; display: flex; flex-direction: column; gap: 3px; min-width: 0; padding: 12px 14px; border-radius: 14px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); transition: opacity var(--dur-2), box-shadow var(--dur-2); }
.cmp-card:hover { background: color-mix(in srgb, var(--raise) 60%, var(--surface)); }
.cmp-card:focus-visible { box-shadow: inset 0 0 0 1px var(--line), 0 0 0 2px var(--text); }
.cmp-card.on { box-shadow: inset 0 0 0 1.5px var(--text); } .cmp-card.dim { opacity: .5; }
.cc-top { display: flex; align-items: center; gap: 8px; min-width: 0; } .cc-top svg { flex: none; }
.cc-n { font-size: 13px; font-weight: 600; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cc-top { align-items: flex-start; } .cc-top svg { margin-top: 5px; }
.cmp-card b { font: 700 26px/1.1 var(--f-big); letter-spacing: -.03em; margin-top: 6px; font-variant-numeric: tabular-nums; }
.cmp-card small { font-size: 12px; color: var(--mute); } .cmp-card .cc-now { color: var(--faint); margin-top: 2px; }
@media (max-width: 760px) { .cmp-cards { grid-template-columns: 1fr 1fr; } .cmp-card b { font-size: 22px; } }
@media (pointer: coarse), (max-width: 760px) { .cmp-card { min-height: 44px; } }

/* shared: loading skeleton, Retry button, spinner */
.w-skel { padding: var(--sp-6) 0; } .w-skel i { display: block; border-radius: 12px; background: linear-gradient(90deg, var(--surface) 0%, var(--raise) 50%, var(--surface) 100%); background-size: 200% 100%; animation: skel 1.1s linear infinite; }
.w-skel-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--sp-4); margin-top: var(--sp-5); } .w-skel-row i { height: 210px; }
.w-retry { all: unset; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 11px; background: var(--text); color: var(--deep); font-weight: 700; font-size: 14px; }
.w-retry[disabled] { opacity: .7; cursor: default; } .w-retry:focus-visible { box-shadow: 0 0 0 2px var(--deep), 0 0 0 4px var(--text); }
.spin { width: 14px; height: 14px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .w-skel i { animation: none; } .spin { animation-duration: 2s; } }

/* ---------- motion and sticky headers (pulse-motion.js), on every page ---------- */
/* sections rise in once as they come into view; children key off .in (bars grow, lines draw, numbers count) */
.rv { opacity: 0; transform: translateY(18px); }
.rv.in { opacity: 1; transform: none; transition: opacity .55s var(--ease-out), transform .55s var(--ease-out); }
.rv.in.shown { transition: none; }
/* a section's header (with its filters, when wrapped in .sec-stick) sticks while you're inside that section */
:root { --stick-top: 0px; }
:root:has(.xp-bar) { --stick-top: 57px; } :root:has(.w-nav) { --stick-top: 53px; } :root:has(.cv-switch) { --stick-top: 57px; }
@media (pointer: coarse) { :root:has(.w-nav) { --stick-top: 61px; } }
.st-sentinel { display: block; height: 0; }
.w-sec > .sec-h, .sec-stick { position: sticky; top: var(--stick-top); z-index: 8; margin-left: calc(-1 * var(--gut)); margin-right: calc(-1 * var(--gut)); padding: 4px var(--gut); background: color-mix(in srgb, var(--deep) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }   /* always opaque, so nothing ever shows through */
/* stuck: only a shadow and hairline fade in. Nothing that changes its height, so the page never jumps as it sticks and unsticks */
.w-sec > .sec-h::after, .sec-stick::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--line); box-shadow: 0 10px 24px -6px #000; opacity: 0; transition: opacity var(--dur-2); pointer-events: none; }
.w-sec > .sec-h.stuck::after, .sec-stick.stuck::after { opacity: 1; }
.sec-stick > .sec-h { margin-bottom: var(--sp-3); }
@media (prefers-reduced-motion: reduce) { .rv, .rv.in { opacity: 1; transform: none; transition: none; } .w-sec > .sec-h, .sec-stick { transition: none; } }

/* ---------- the Pulse chart (pulse-chart.js): one look for every chart ---------- */
:root { --v: var(--fair); }   /* the chart's colour; product pages set it by verdict, holdings and cards by which way the price went */
.pc { position: relative; touch-action: pan-y; cursor: crosshair; outline: none; }
.pc:focus-visible { box-shadow: 0 0 0 2px var(--text); border-radius: 12px; }
.pc svg { display: block; width: 100%; height: 100%; overflow: visible; }
.pc .line:not(.pc-sub) { filter: drop-shadow(0 0 6px color-mix(in srgb, var(--v) 60%, transparent)); }
.pc .line, .pc .pc-dot { transition: opacity var(--dur-2); } .pc .dim { opacity: .22; }
.pc-g { stroke: var(--line); } .pc-z { stroke: color-mix(in srgb, var(--text) 30%, transparent); }
.pc-yl { fill: var(--faint); font: 500 11px var(--f-ui); } .pc-xl { fill: var(--faint); font: 500 12px var(--f-ui); } .pc-xl.now { fill: var(--mute); }
.pc-xh { stroke: var(--text); stroke-opacity: .4; stroke-dasharray: 2 3; }
.pc-dot { stroke: var(--deep); stroke-width: 3; } .pc-dot.sub { stroke-width: 2; }
.pc-spark { display: block; overflow: visible; } .pc-spark.none line { stroke: var(--line); stroke-dasharray: 3 3; }
/* the readout above a chart: the value at the date you're reading, and what it's done */
.pc-read b { display: block; font: 700 22px var(--f-big); letter-spacing: -.02em; } .pc-read small { font-size: 12px; color: var(--mute); }
.pc-read .up { color: var(--buy); } .pc-read .dn { color: #FF8A7A; }
@media (prefers-reduced-motion: reduce) { .w-sec > .sec-h::after, .sec-stick::after { transition: none; } }

/* ---------- back to where you came from (pulse-nav.js) ---------- */
.nav-backrow { margin: 0 0 var(--sp-2); }
.nav-back { display: inline-flex; align-items: center; gap: 2px; min-height: 44px; padding: 0 10px 0 2px; margin-left: -2px; border-radius: 12px; color: #FFD27A; font-weight: 600; font-size: 14px; text-decoration: none; max-width: 100%; box-sizing: border-box; }
.nav-back span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav-back:hover { background: color-mix(in srgb, #FFD27A 10%, transparent); } .nav-back:focus-visible { outline: 2px solid var(--text); outline-offset: 1px; }
@media (max-width: 760px) { .sec-sub { margin-left: calc(40px + var(--sp-3)); margin-bottom: var(--sp-4); } .sec-stick + .sec-sub { margin-left: 0; } }
@media (max-width: 760px) { .ov-fab ~ * .sec-stick .sec-act, :root:has(.ov-fab) .sec-stick > .sec-h .sec-act { display: none; } }   /* phones: the floating bar already has Manage, so the sticky header stays one line */

/* ---------- Your position (pulse-yours.js): what you own of one thing, wherever it's shown ---------- */
.yp { margin: var(--sp-4) 0; padding: 20px; border-radius: 20px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.yp-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.yp-h h2 { margin: 0; font: 700 18px var(--f-big); letter-spacing: -.02em; }
.yp-m { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 10px; margin-right: -10px; border-radius: 12px; color: #FFD27A; font-size: 14px; font-weight: 600; text-decoration: none; }
.yp-m:hover { background: color-mix(in srgb, #FFD27A 10%, transparent); } .yp-m:focus-visible { outline: 2px solid var(--text); }
.yp-sum { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; margin: 0; }
.yp-sum > div { padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, var(--deep) 55%, transparent); }
.yp-sum dt { font-size: 12px; font-weight: 600; color: var(--mute); } .yp-sum dd { margin: 2px 0 0; } .yp-sum b { display: block; font: 700 18px var(--f-big); letter-spacing: -.02em; } .yp-sum small { font-size: 12px; color: var(--faint); }
.yp .up { color: var(--buy); } .yp .dn { color: #FF8A7A; }
.yp-sh { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin: 18px 0 6px; font: 700 14px var(--f-ui); color: var(--text); } .yp-sh small { font-size: 12px; font-weight: 500; color: var(--faint); }
.yp-list { list-style: none; margin: 0; padding: 0; }
.yp-row { all: unset; box-sizing: border-box; width: 100%; display: grid; grid-template-columns: auto minmax(0, 1fr) auto 28px; gap: 12px; align-items: center; min-height: 60px; padding: 8px 6px; border-top: 1px solid var(--line); }
.yp-list li:first-child .yp-row { border-top: 0; }
button.yp-row { cursor: pointer; border-radius: 12px; transition: background var(--dur-2); } button.yp-row:hover { background: color-mix(in srgb, var(--raise) 70%, transparent); } button.yp-row:focus-visible { box-shadow: 0 0 0 2px var(--text); }
.yp-tag { justify-self: start; font: 700 11px var(--f-big); letter-spacing: .03em; padding: 6px 9px; border-radius: 8px; background: var(--raise); color: var(--mute); white-space: nowrap; }
.yp-tag.slab { background: color-mix(in srgb, #FFD27A 16%, transparent); color: #FFD27A; } .yp-tag.sold { background: color-mix(in srgb, var(--buy) 16%, transparent); color: var(--buy); }
.yp-t { min-width: 0; } .yp-t b { display: block; font-size: 14px; font-weight: 600; } .yp-t small { display: block; font-size: 12px; color: var(--mute); }
.yp-t em { display: block; margin-top: 2px; font-style: normal; font-size: 12.5px; color: var(--mute); } .yp-t em::before { content: '“'; } .yp-t em::after { content: '”'; }
.yp-v { text-align: right; } .yp-v b { display: block; font: 700 15px var(--f-big); } .yp-v small { font-size: 11px; font-weight: 600; color: var(--faint); }
.yp-e { color: var(--faint); display: grid; place-items: center; } button.yp-row:hover .yp-e { color: var(--text); }
.yp-sold .yp-row { grid-template-columns: auto minmax(0, 1fr) auto 28px; }
.yp-acts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.yp-a { all: unset; box-sizing: border-box; cursor: pointer; flex: 1 1 120px; min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 14px; background: var(--raise); font-weight: 600; font-size: 14px; }
.yp-a.main { background: var(--buy); color: var(--deep); } .yp-a:hover { filter: brightness(1.08); } .yp-a:focus-visible { box-shadow: 0 0 0 2px var(--text); }
@media (max-width: 560px) {
  .yp { padding: 16px; } .yp-sum { grid-template-columns: 1fr 1fr; }
  .yp-row { grid-template-columns: minmax(0, 1fr) auto 24px; row-gap: 4px; } .yp-row .yp-tag { grid-column: 1; grid-row: 1; } .yp-row .yp-t { grid-column: 1; grid-row: 2; }
  .yp-row .yp-v { grid-column: 2; grid-row: 1 / span 2; } .yp-row .yp-e { grid-column: 3; grid-row: 1 / span 2; }
}

/* stepping through your holdings on an item page that has no bar of its own (the card page) */
.yp { scroll-margin-top: 76px; }
.stepbar { position: sticky; top: var(--stick-top); z-index: 9; display: flex; align-items: center; gap: 8px; margin: 0 calc(-1 * var(--gut)) var(--sp-3); padding: 8px var(--gut); background: color-mix(in srgb, var(--deep) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.sb-cur { flex: 1; min-width: 0; min-height: 48px; display: flex; align-items: center; gap: 10px; padding: 6px 12px 6px 8px; border-radius: 14px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); color: var(--text); text-decoration: none; }
.sb-cur img { width: 32px; height: 32px; object-fit: contain; border-radius: 6px; flex: none; } .sb-cur span { min-width: 0; display: flex; flex-direction: column; }
.sb-cur b { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .sb-cur small { font-size: 12px; color: var(--mute); } .sb-cur svg { margin-left: auto; flex: none; color: var(--mute); }
.sb-step { all: unset; box-sizing: border-box; cursor: pointer; width: 48px; height: 48px; flex: none; display: grid; place-items: center; border-radius: 14px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.sb-step:focus-visible, .sb-cur:focus-visible { outline: 2px solid var(--text); }
.xcd .yp { scroll-margin-top: 140px; }   /* the card page has two sticky bars above it */

/* ---------- Pulse rail (pulse-rail.js): every sideways scroller, in our style ---------- */
.prail { --rail-bg: var(--deep); position: relative; }
.prail-s { scrollbar-width: none !important; } .prail-s::-webkit-scrollbar { display: none !important; }
.prail::before, .prail::after { content: ""; position: absolute; z-index: 3; top: 0; bottom: 18px; width: 56px; pointer-events: none; transition: opacity var(--dur-3) var(--ease-out); }
.prail::before { left: 0; background: linear-gradient(90deg, var(--rail-bg), transparent); } .prail::after { right: 0; background: linear-gradient(270deg, var(--rail-bg), transparent); }
.prail.at-start::before, .prail.at-end::after, .prail.none::before, .prail.none::after { opacity: 0; }
.prail-b { all: unset; box-sizing: border-box; cursor: pointer; position: absolute; z-index: 4; top: calc(50% - 9px); transform: translateY(-50%); width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%;
  color: var(--text); background: color-mix(in srgb, var(--raise) 88%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); box-shadow: 0 10px 26px -8px #000c, inset 0 0 0 1px var(--line);
  opacity: 0; transition: opacity var(--dur-2), transform var(--dur-2) var(--ease-out), background var(--dur-2); }
.prail-b.prev { left: 6px; } .prail-b.next { right: 6px; }
.prail:hover .prail-b { opacity: 1; } .prail-b:hover { background: var(--raise); transform: translateY(-50%) scale(1.06); }
.prail.at-start .prail-b.prev, .prail.at-end .prail-b.next, .prail.none .prail-b { opacity: 0 !important; pointer-events: none; }
@media (pointer: coarse) { .prail-b { display: none; } }
.prail-bar { position: relative; width: min(180px, 42%); height: 4px; margin: 8px auto 0; border-radius: 99px; background: color-mix(in srgb, var(--text) 10%, transparent); overflow: hidden; }
.prail-bar i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: inherit; background: linear-gradient(90deg, var(--buy), var(--fair)); box-shadow: 0 0 10px color-mix(in srgb, var(--buy) 50%, transparent); transition: transform 80ms linear; }
.prail.none .prail-bar { display: none; }
/* the page's own scrollbars, in our colours */
html { scrollbar-color: color-mix(in srgb, var(--fair) 40%, var(--raise)) transparent; }
* { scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; height: 10px; } ::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { border: 3px solid transparent; border-radius: 99px; background: linear-gradient(180deg, color-mix(in srgb, var(--fair) 55%, var(--raise)), color-mix(in srgb, var(--buy) 45%, var(--raise))) padding-box; }
::-webkit-scrollbar-thumb:hover { background: linear-gradient(180deg, var(--fair), var(--buy)) padding-box; }
@media (prefers-reduced-motion: reduce) { .prail-bar i { transition: none; } }

/* product pictures with the white background cut out: no white tile behind them anywhere */
img[src^="img/p/"] { background: transparent !important; box-shadow: none !important; border-radius: 0 !important; object-fit: contain !important; object-position: center bottom; filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .45)); }

/* ---------- Quick search (pulse-search.js): / or Ctrl+K on any page ---------- */
.ab-search { all: unset; box-sizing: border-box; cursor: pointer; margin-left: auto; display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 8px 0 12px; min-width: 200px; border-radius: 12px; background: var(--surface); color: var(--mute); font-size: 14px; box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow var(--dur-2), color var(--dur-2); }
.ab-search span { flex: 1; } .ab-search:hover { color: var(--text); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--text) 25%, transparent); } .ab-search:focus-visible { box-shadow: 0 0 0 2px var(--text); }
.ab-search + .ab-add { margin-left: 0; }
.ab-search kbd, .qs kbd { font: 600 11px var(--f-ui); padding: 2px 6px; border-radius: 6px; background: var(--raise); color: var(--mute); box-shadow: inset 0 -1px 0 #0006; }
@media (max-width: 1000px) { .ab-search { min-width: 0; } .ab-search span, .ab-search kbd { display: none; } .ab-search { width: 40px; padding: 0; justify-content: center; } }
@media (max-width: 760px) { .ab-search { display: none; } }
html.qs-on { overflow: hidden; }
.qs { position: fixed; inset: 0; z-index: 200; display: grid; justify-items: center; align-items: start; padding: min(12vh, 120px) 16px 16px; }
.qs-scrim { position: absolute; inset: 0; background: #020a0dcc; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); animation: qs-fade var(--dur-2) var(--ease-out); }
.qs-box { position: relative; width: min(640px, 100%); max-height: min(70vh, 640px); display: flex; flex-direction: column; border-radius: 20px; background: var(--surface); box-shadow: 0 40px 80px -20px #000, inset 0 0 0 1px var(--line); overflow: hidden; animation: qs-in var(--dur-3) var(--ease-out); }
@keyframes qs-fade { from { opacity: 0; } } @keyframes qs-in { from { opacity: 0; transform: translateY(-10px) scale(.98); } }
.qs-in { display: flex; align-items: center; gap: 12px; padding: 0 16px; min-height: 60px; border-bottom: 1px solid var(--line); color: var(--mute); }
.qs-in input { all: unset; flex: 1; min-width: 0; font: 500 17px var(--f-ui); color: var(--text); } .qs-in input::placeholder { color: var(--faint); } .qs-in input::-webkit-search-cancel-button { display: none; }
.qs-list { list-style: none; margin: 0; padding: 6px; overflow-y: auto; flex: 1; }
.qs-g { padding: 10px 10px 4px; font: 700 10px var(--f-big); letter-spacing: .1em; text-transform: uppercase; color: var(--faint); }
.qs-list a { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 12px; align-items: center; min-height: 52px; padding: 6px 10px; border-radius: 12px; color: inherit; text-decoration: none; }
.qs-list [aria-selected=true] a, .qs-list a:hover { background: var(--raise); }
.qs-list [aria-selected=true] a { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--buy) 40%, transparent); }
.qs-pimg { width: 44px; height: 40px; object-fit: contain; filter: drop-shadow(0 4px 6px #0008); display: block; }
.qs-card { width: 30px; height: 42px; object-fit: cover; border-radius: 4px; justify-self: center; }
.qs-logo { width: 44px; height: 26px; object-fit: contain; } .qs-mono { width: 32px; height: 32px; border-radius: 10px; background: var(--raise); justify-self: center; }
.qs-t { min-width: 0; display: flex; flex-direction: column; } .qs-t b { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .qs-t small { font-size: 12px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qs-list em { font: 700 14px var(--f-big); font-style: normal; } .qs-list em.t-buy { color: var(--buy); } .qs-list em.t-wait { color: var(--wait); } .qs-list em.t-fair { color: var(--fair); }
.qs-hint, .qs-load { padding: 18px 12px; color: var(--mute); font-size: 14px; } .qs-hint b { color: var(--text); }
.qs-foot { display: flex; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 12px; color: var(--faint); } .qs-foot kbd { margin-right: 3px; }
@media (max-width: 760px) { .qs { padding: 12px; } .qs-box { max-height: calc(100dvh - 24px); } .qs-foot { display: none; } }
@media (prefers-reduced-motion: reduce) { .qs-scrim, .qs-box { animation: none; } }

/* ---------- Install the app (pulse-app.js) ---------- */
.app-install { position: fixed; z-index: 150; left: 12px; right: 12px; bottom: calc(84px + env(safe-area-inset-bottom)); max-width: 460px; margin: 0 auto; display: flex; align-items: center; gap: 12px; padding: 12px 10px 12px 12px; border-radius: 18px;
  background: color-mix(in srgb, var(--raise) 94%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 20px 50px -14px #000, inset 0 0 0 1px var(--line);
  opacity: 0; transform: translateY(16px); transition: opacity var(--dur-3) var(--ease-out), transform var(--dur-3) var(--ease-out); }
.app-install.on { opacity: 1; transform: none; }
.app-install img { width: 40px; height: 40px; border-radius: 10px; flex: none; }
.ai-t { flex: 1; min-width: 0; display: flex; flex-direction: column; } .ai-t b { font-size: 14px; } .ai-t small { font-size: 12px; color: var(--mute); } .ai-t small svg { vertical-align: -3px; }
.ai-go { all: unset; cursor: pointer; min-height: 40px; padding: 0 16px; border-radius: 12px; background: var(--buy); color: var(--deep); font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; }
.ai-x { all: unset; cursor: pointer; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; color: var(--mute); font-size: 22px; }
.ai-go:focus-visible, .ai-x:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; }
@media (min-width: 761px) { .app-install { bottom: 24px; left: 24px; right: auto; } }
@media (prefers-reduced-motion: reduce) { .app-install { transition: none; } }
/* inside the installed app: no "All designs" mockup switch, and taps don't flash */
html.is-app #accessDev { display: none; }
html.is-app { -webkit-tap-highlight-color: transparent; }

/* 16px or more, so iPhone and iPad don't zoom in when it's tapped */
.w-dd select { font-size: 16px; }
