/* TrackRestocks Stage 16: visual polish (CSS only, no markup or copy changes).
   Loaded after stage11.css on every page (layout.php render_head), so it only overrides looks.
   1. Readability: lighter muted/dim text on dark, 15-16px body copy, no helper text under 13px.
   2. Most Wanted cards in four zones (needs the Stage 16 index.php): category pill + one status badge,
      title + MSRP, TGT/WMT/BBY/AMZ store chips with dots, last check + actions.
   3. Setup panel grouped into numbered blocks; restock log, FAQ, steps and pricing get more air.
   No new fonts, images or scripts. Motion is limited to short hover transitions and respects
   prefers-reduced-motion. */

/* ---------- 1. readability ---------- */
:root {
  --muted: #CBCBD3;   /* was #A1A1AA: body-level secondary copy */
  --dim: #A1A1AA;     /* was #71717A: helper copy, ~7:1 on the panel colour */
  --faint: #8A8A94;   /* only for decoration such as placeholders and separators */
  --line: #222228; --line-2: #2E2E35;
  --glow: rgba(16, 185, 129, .18);
}
body { font-size: 16px; line-height: 1.6; }
.s11-input::placeholder { color: var(--faint); }
.s11-sub { font-size: 16px; line-height: 1.65; color: var(--muted); max-width: 660px; }
.s11-lead { color: var(--muted); line-height: 1.6; }
.s11-note { font-size: 13.5px; line-height: 1.55; color: var(--dim); }
.s11-help { font-size: 13px; color: var(--dim); }
.s11-label { font-size: 13px; color: var(--muted); letter-spacing: .01em; }
.s11-mono { font-size: 12.5px; color: var(--dim); }
.s11-msg { font-size: 14px; line-height: 1.55; }
.s11-badge { font-size: 10.5px; padding: 3px 8px; }
.s11-store { font-size: 10.5px; padding: 3px 8px; }
.s11-pill { font-size: 13px; }
.s11-top { font-size: 13px; }
.s11-nav { font-size: 14px; color: var(--muted); }
.s11-urlmsg { font-size: 14px; color: var(--muted); }
.s11-or { font-size: 14px; color: var(--muted); }
.s11-or .s11-select { font-size: 14px; }
.s11-eyebrow { font-size: 11.5px; }
.s11-footer { font-size: 14px; color: var(--dim); }
.s11-fine { font-size: 13px; line-height: 1.65; color: var(--dim); }

/* ---------- section rhythm ---------- */
.s11-section { padding: 88px 0; }
.s11-h2 { margin: 12px 0 10px; line-height: 1.15; }
@media (max-width: 600px) { .s11-section { padding: 64px 0; } }

/* ---------- hero accents ---------- */
.s11-hero { padding: 96px 0 72px; }
.s11-hero::after { width: 900px; height: 520px; top: -220px;
  background: radial-gradient(closest-side, rgba(16,185,129,.20), rgba(16,185,129,.05) 60%, transparent); }
.s11-lead { text-wrap: pretty; max-width: 620px; }
.s11-urlbar { border-radius: 16px; padding: 8px; box-shadow: 0 24px 70px -24px rgba(0,0,0,.9), 0 0 0 1px rgba(255,255,255,.02) inset; }
.s11-storepills { margin-top: 16px; }

/* ---------- 2. setup panel: grouped blocks ---------- */
.s11-setup { border-radius: 18px; border-color: var(--line-2);
  background: linear-gradient(180deg, #15151A 0%, var(--panel) 120px);
  box-shadow: 0 30px 80px -40px rgba(0,0,0,.9), 0 0 0 1px rgba(16,185,129,.06); }
.s11-setup { grid-template-columns: minmax(0, 1fr); }
.s11-setup > div, .s11-setup-in { min-width: 0; }
.s11-setup-in { padding: 24px; counter-reset: s16-step; }
@media (max-width: 560px) { .s11-setup-in { padding: 18px; } }
.s11-setup-head { padding-bottom: 16px; margin-bottom: 6px; }
.s11-setup-head strong { font-size: 16px !important; }
#itemRows { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; margin-top: 10px; }
.s11-item-row { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #0E0E11; gap: 10px 12px; }
.s11-item-row .s11-item-name { font-size: 15px; }
.s11-item-row .s11-input { order: 10; flex: 1 1 100%; font-size: 14px; padding: 9px 12px; }
.s11-item-row > label { order: 11; }
.s11-item-row > [data-remove] { margin-left: auto; }
#addMore { margin-top: 12px !important; gap: 8px !important; flex-wrap: wrap; }
#addMore .s11-input, #addMore .s11-select { font-size: 14px !important; padding: 9px 12px !important; }
#addMore .s11-input { flex: 1 1 220px; }
/* Each "Plan" / "Alert channels" label opens a framed block with a step number */
#setupForm > .s11-label { counter-increment: s16-step; display: flex; align-items: center; gap: 10px; margin-top: 26px !important; margin-bottom: 12px;
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--text); }
#setupForm > .s11-label::before { content: counter(s16-step); display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  font: 700 11px/1 ui-monospace, SFMono-Regular, Menlo, monospace; color: #04130d; background: var(--green); }
#setupForm > .s11-label::after { content: ""; flex: 1; height: 1px; background: var(--line); }
#setupForm > .s11-grid2:not(.s11-plans) { gap: 10px; }
#setupForm > .s11-grid2[style] { margin-top: 26px !important; padding-top: 22px; border-top: 1px solid var(--line); gap: 14px; }
.s11-plans { gap: 10px; }
.s11-plan-opt { padding: 14px 14px 14px 40px; border-radius: 12px; font-size: 13px; line-height: 1.5; color: var(--dim);
  background: #0E0E11; transition: border-color .15s, background .15s, box-shadow .15s; }
.s11-plan-opt::before { content: ""; position: absolute; left: 14px; top: 16px; width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid var(--line-2); box-sizing: border-box; transition: border-color .15s, box-shadow .15s; }
.s11-plan-opt:hover:not(.is-disabled) { border-color: #3a3a44; }
.s11-plan-opt strong { font-size: 15px; margin-bottom: 2px; }
.s11-plan-opt:has(input:checked), .s11-plan-opt.is-checked { border-color: var(--green); background: linear-gradient(180deg, rgba(16,185,129,.14), rgba(16,185,129,.05));
  box-shadow: 0 0 0 3px rgba(16,185,129,.12); color: var(--muted); }
.s11-plan-opt:has(input:checked)::before, .s11-plan-opt.is-checked::before { border-color: var(--green); box-shadow: inset 0 0 0 3px #0E0E11, inset 0 0 0 8px var(--green); }
.s11-plan-opt:has(input:focus-visible) { outline: 2px solid var(--green); outline-offset: 2px; }
.s11-toggle { padding: 12px 14px; border-radius: 12px; font-size: 14px; background: #0E0E11; }
.s11-toggle:not(.is-off) { border-color: rgba(16,185,129,.30); }
.s11-toggle.is-off { color: var(--dim); background: transparent; border-style: dashed; }
#startBtn { margin-top: 22px !important; padding: 15px !important; font-size: 15px; border-radius: 12px;
  box-shadow: 0 12px 30px -12px rgba(16,185,129,.55); }
#setupForm > .s11-note:last-child { margin-top: 14px !important; font-size: 13px; line-height: 1.6; }

/* ---------- 3. Most Wanted cards: four zones (top row, title + MSRP, store chips, footer) ---------- */
.s11-cats, .s11-sorts { gap: 8px; }
.s11-cat { font-size: 14px; padding: 7px 14px; color: var(--muted); transition: border-color .15s, color .15s, background .15s; }
.s11-cat:hover:not(.is-on) { border-color: #3a3a44; color: var(--text); }
.s11-sorts { margin-top: 14px; }
.s11-sorts .s11-cat { font-size: 13px; padding: 5px 12px; }
.s11-cards { gap: 18px; margin-top: 26px; }
.s16-card { --accent: #A78BFA; --accent-bg: rgba(167,139,250,.12); position: relative; display: flex; flex-direction: column; gap: 14px;
  padding: 20px; border-radius: 16px; overflow: hidden; background: linear-gradient(180deg, #141418 0%, var(--panel) 70%);
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease; }
.s16-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; pointer-events: none;
  background: linear-gradient(90deg, transparent, var(--accent), transparent); opacity: .55; }
.s16-card[data-cat="consoles"]    { --accent: #60A5FA; --accent-bg: rgba(96,165,250,.12); }
.s16-card[data-cat="video_games"] { --accent: #A78BFA; --accent-bg: rgba(167,139,250,.12); }
.s16-card[data-cat="pokemon_tcg"] { --accent: #FBBF24; --accent-bg: rgba(251,191,36,.10); }
.s16-card[data-cat="lego"]        { --accent: #F87171; --accent-bg: rgba(248,113,113,.10); }
.s16-card[data-cat="viral_toys"]  { --accent: #F472B6; --accent-bg: rgba(244,114,182,.10); }
.s16-card:hover { border-color: #34343C; transform: translateY(-3px); box-shadow: 0 18px 40px -22px rgba(0,0,0,.95), 0 0 0 1px rgba(255,255,255,.03); }
.s16-card:hover::before { opacity: .9; }
/* Spotlight: items with stock at our last check */
.s16-card:has(.s16-status.is-in) { border-color: rgba(16,185,129,.45); box-shadow: 0 0 0 1px rgba(16,185,129,.15), 0 20px 50px -30px rgba(16,185,129,.45); }
/* zone 1: category pill + one status badge */
.s16-card-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-height: 24px; }
.s16-cat { display: inline-flex; align-items: center; border-radius: 999px; padding: 3px 10px; background: var(--accent-bg); color: var(--accent);
  font: 700 11px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }
.s16-card-top .s11-badge { border-radius: 999px; }
.s16-status { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 3px 10px;
  font: 700 11px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .06em; text-transform: uppercase; white-space: nowrap;
  border: 1px solid var(--line-2); color: var(--dim); }
.s16-status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px currentColor; }
.s16-status.is-in { color: #6EE7B7; border-color: rgba(16,185,129,.45); background: rgba(16,185,129,.12); }
.s16-status.is-in::before { background: var(--green); box-shadow: 0 0 0 3px rgba(16,185,129,.25); }
.s16-status.is-out { color: var(--muted); } .s16-status.is-out::before { background: #71717A; box-shadow: none; }
.s16-status.is-stale { color: var(--amber); border-color: rgba(251,191,36,.35); }
.s16-status.is-watch { color: #A5B4FC; border-color: rgba(165,180,252,.30); background: rgba(99,102,241,.08); }
/* zone 2: title + MSRP */
.s16-card-head { display: grid; gap: 4px; }
.s16-card .s11-card-title { font-size: 17px; font-weight: 650; line-height: 1.35; letter-spacing: -.01em; color: #FAFAFA; }
.s16-msrp { margin: 0; font-size: 14px; color: var(--dim); } .s16-msrp b { color: var(--text); font-weight: 650; }
/* zone 3: store chips TGT / WMT / BBY / AMZ with a status dot (full text in the tooltip and for screen readers) */
.s16-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.s16-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 8px; border-radius: 8px; cursor: default;
  font: 700 12px/1.3 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .04em; color: var(--muted);
  border: 1px solid var(--line-2); background: rgba(255,255,255,.025); }
.s16-chip::before { content: ""; flex: 0 0 7px; width: 7px; height: 7px; border-radius: 50%; background: #71717A; }
.s16-chip.is-in { color: #A7F3D0; border-color: rgba(16,185,129,.5); background: rgba(16,185,129,.12); }
.s16-chip.is-in::before { background: var(--green); box-shadow: 0 0 0 3px rgba(16,185,129,.22); }
.s16-chip.is-stale::before { background: var(--amber); }
.s16-chip.is-none { color: var(--dim); border-style: dashed; } .s16-chip.is-none::before { background: transparent; box-shadow: inset 0 0 0 1.5px #71717A; }
/* zone 4: last check + actions */
.s16-card-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; gap: 10px 8px; }
.s16-meta { margin: 0; flex: 1 1 100%; font-size: 12.5px; color: var(--dim); }
.s16-actions { flex: 1 1 100%; display: flex; gap: 8px; }
.s16-actions .s11-btn { flex: 1 1 0; padding-top: 9px; padding-bottom: 9px; font-size: 14px; }
.s16-actions [data-track][aria-pressed="true"] { color: #6EE7B7; border-color: rgba(16,185,129,.5); background: rgba(16,185,129,.10); }
.s11-empty { border-radius: 16px; padding: 40px 24px; font-size: 15px; line-height: 1.6; color: var(--muted);
  background: radial-gradient(ellipse at 50% 0%, rgba(16,185,129,.07), transparent 70%), var(--panel); border: 1px dashed var(--line-2); }
.s11-empty strong { font-size: 16px; margin-bottom: 8px; }

/* ---------- vote bar ---------- */
.s11-vote { border-radius: 16px; padding: 20px 22px; gap: 18px; }
.s11-vote-title { font-size: 15px; } .s11-vote-title span { font-size: 13.5px; color: var(--dim); margin-top: 2px; }
.s11-vote-pill { font-size: 14px; padding: 7px 9px 7px 14px; }

/* ---------- restock log ---------- */
.s11-status { gap: 14px; margin-top: 26px; }
.s11-stat { padding: 18px 20px; border-radius: 14px; background: linear-gradient(180deg, #141418, var(--panel)); }
.s11-stat b { font-size: 26px; font-weight: 750; color: var(--text); }
.s11-stat span { display: block; margin-top: 4px; font-size: 13.5px; color: var(--dim); }
.s11-stat:last-child b { color: var(--green-2); }
.s11-feed { margin-top: 18px !important; border-radius: 16px; overflow: hidden; }
.s11-feed li { padding: 16px 20px; gap: 14px; font-size: 15px; transition: background .15s; }
.s11-feed li + li { border-top: 1px solid var(--line); }
.s11-feed li:hover { background: rgba(255,255,255,.02); }
.s11-feed .s11-badge-green::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.s11-feed .s11-mono { white-space: nowrap; font-size: 13px; }
#restocks .s11-empty { margin-top: 18px !important; }

/* ---------- how it works ---------- */
.s11-steps { gap: 18px; margin-top: 30px; }
.s11-step { padding: 24px; border-radius: 16px; background: linear-gradient(180deg, #141418, var(--panel)); }
.s11-step i { display: inline-grid; place-items: center; min-width: 34px; height: 26px; padding: 0 8px; border-radius: 8px;
  background: var(--green-bg); border: 1px solid rgba(16,185,129,.3); font-size: 12px; }
.s11-step h3 { font-size: 17px; margin: 14px 0 8px; }
.s11-step p { font-size: 15px; line-height: 1.6; color: var(--muted); }

/* ---------- pricing ---------- */
#pricing { position: relative; overflow: hidden; }
#pricing::before { content: ""; position: absolute; left: 50%; top: 38%; width: 760px; height: 520px; transform: translateX(-50%); pointer-events: none;
  background: radial-gradient(closest-side, rgba(16,185,129,.10), transparent); }
#pricing > .s11-wrap { position: relative; }
.s11-prices { gap: 18px; margin-top: 34px; }
.s11-price { padding: 28px 26px; border-radius: 18px; background: linear-gradient(180deg, #141418, var(--panel)); transition: border-color .18s, transform .18s; }
.s11-price:hover { border-color: #34343C; }
.s11-price.is-best { background: linear-gradient(180deg, rgba(16,185,129,.10), var(--panel) 55%); }
.s11-price h3 { font-size: 16px; }
.s11-price .per { font-size: 14px; color: var(--dim); }
.s11-price ul { font-size: 15px; gap: 11px; margin: 22px 0 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.s11-price li { color: var(--muted); line-height: 1.45; }
.s11-price li.is-soon { color: var(--dim); }
.s11-price .s11-btn { padding: 12px 16px; font-size: 15px; border-radius: 11px; }

/* ---------- FAQ ---------- */
.s11-faq .s11-h2 { margin-bottom: 22px !important; }
.s11-faq details { border: 1px solid var(--line); border-radius: 14px; padding: 0; background: var(--panel); transition: border-color .15s, background .15s; }
.s11-faq details + details { margin-top: 10px; }
.s11-faq details:hover { border-color: var(--line-2); }
.s11-faq details[open] { border-color: rgba(16,185,129,.35); background: linear-gradient(180deg, rgba(16,185,129,.05), var(--panel) 80px); }
.s11-faq summary { padding: 18px 20px; font-size: 16px; line-height: 1.4; align-items: center; }
.s11-faq summary:hover { color: #fff; }
.s11-faq summary::after { flex: 0 0 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-2);
  font-size: 16px; color: var(--muted); }
.s11-faq details[open] summary::after { color: var(--green-2); border-color: rgba(16,185,129,.45); }
.s11-faq p { margin: 0; padding: 14px 20px 20px; border-top: 1px solid var(--line); font-size: 15px; line-height: 1.7; color: var(--muted); }

/* ---------- dashboard and other pages share the readability bump ---------- */
.s11-panel { border-radius: 16px; padding: 24px; }
.s11-panel h2 { font-size: 17px; }
.s11-tracker { padding: 16px; border-radius: 14px; }
.s11-table { font-size: 14px; }
.s11-side a { font-size: 15px; }
.s11-modal-box { border-radius: 18px; padding: 26px; }
.s11-toast { font-size: 14px; }

@media (prefers-reduced-motion: reduce) {
  .s16-card:hover, .s11-price:hover { transform: none; }
}

/* Stage 16: product image slot on the Most Wanted cards (fixed 16:10 frame so rows stay even) */
.s16-img { position: relative; aspect-ratio: 16 / 10; max-height: 150px; width: 100%; display: grid; place-items: center; overflow: hidden;
  border-radius: 12px; border: 1px solid var(--line); padding: 12px;
  background: radial-gradient(ellipse at 50% 40%, var(--accent-bg), transparent 70%), #0E0E11; }
.s16-img img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.s16-img:not(.has-photo) img { width: 46%; opacity: .9; }
/* real photos (often white box shots) sit on a soft light frame instead of pure black */
.s16-img.has-photo { background: linear-gradient(180deg, #F7F7F8, #E7E7EB); border-color: transparent; }
.s16-img.has-photo img { border-radius: 6px; transition: transform .2s ease; }
.s16-card:hover .s16-img.has-photo img { transform: scale(1.03); }
@media (prefers-reduced-motion: reduce) { .s16-card:hover .s16-img.has-photo img { transform: none; } }
