/* TrackRestocks Stage 18: alive cards, instant answer, Just restocked strip, restock log table, product page live box. */

/* Just restocked strip (homepage top, only when restock_logs has rows) */
.s18-strip { background: linear-gradient(90deg, rgba(16,185,129,.16), rgba(16,185,129,.04)); border-bottom: 1px solid rgba(16,185,129,.35); }
.s18-strip-in { display: flex; align-items: center; gap: 14px; padding-top: 9px; padding-bottom: 9px; font-size: 13px; overflow: hidden; }
.s18-strip-tag { flex: none; display: inline-flex; align-items: center; gap: 7px; font-weight: 700; color: #6EE7B7; text-transform: uppercase; letter-spacing: .04em; font-size: 12px; }
.s18-strip ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 22px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.s18-strip li { flex: none; display: inline-flex; gap: 6px; align-items: baseline; color: var(--muted); white-space: nowrap; }
.s18-strip li strong { color: var(--text); }
.s18-strip-all { flex: none; margin-left: auto; color: #6EE7B7; text-decoration: underline; white-space: nowrap; }

/* Hero live line */
.s18-liveline { margin: 10px 0 0; display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }
.s18-liveline b { color: var(--text); }

/* Price line on cards and answers */
.s18-price { margin: 6px 0 0; font-size: 13px; color: var(--muted); }
.s18-price b { color: var(--text); font-size: 17px; margin-right: 4px; }
.s18-price.is-in_stock b { color: #6EE7B7; }
.s18-price.is-msrp b { color: var(--muted); font-size: 15px; }

/* Store rows with check time */
.s18-stores { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 4px; font-size: 13px; }
.s18-stores li { display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: center; padding: 5px 9px; border-radius: 8px; border: 1px solid var(--line-2); background: rgba(255,255,255,.015); }
.s18-stores li::before { content: none; }
.s18-st { font-weight: 600; color: var(--text); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.s18-sv { color: var(--muted); }
.s18-sa { color: var(--dim); font-size: 11px; }
.s18-stores li.is-in { border-color: rgba(16,185,129,.5); background: rgba(16,185,129,.10); }
.s18-stores li.is-in .s18-sv { color: #6EE7B7; font-weight: 700; }
.s18-stores li.is-unread { border-style: dashed; }
.s18-stores li.is-unread .s18-sv { color: var(--amber); }
.s18-stores li.is-stale .s18-sa { color: var(--amber); }
.s18-buy { color: #6EE7B7; font-weight: 700; text-decoration: underline; }
.s18-stores li:has(.s18-buy) { grid-template-columns: 1fr auto auto; }

.s18-pickup { margin: 10px 0 0; font-size: 12.5px; color: #C7D2FE; }
.s18-hist { text-decoration: underline; }
.s18-card .s16-img { display: block; }

/* Items with no reading yet: a plain list, no stock claim */
.s18-waiting { margin-top: 22px; border: 1px dashed var(--line-2); border-radius: var(--radius); padding: 14px 16px; }
.s18-waiting h3 { margin: 0; font-size: 15px; font-weight: 700; }
.s18-waiting ul { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 8px; }
.s18-waiting li { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 14px; }
.s18-waiting li a { font-weight: 600; text-decoration: underline; }
.s18-waiting li .s11-btn { margin-left: auto; }

/* Instant answer under the hero bar */
.s18-answer { margin-top: 14px; text-align: left; }
.s18-answer-card { display: grid; grid-template-columns: 120px 1fr; gap: 16px; padding: 16px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--panel); margin-top: 10px; }
.s18-answer-img { width: 120px; height: 90px; object-fit: contain; background: #F4F4F5; border-radius: 10px; padding: 6px; }
.s18-answer-body { min-width: 0; }
.s18-answer-cta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.s18-pick { margin-top: 10px; }
.s18-zip { display: flex; gap: 8px; margin-top: 8px; max-width: 320px; }
.s18-zip .s11-input { padding: 8px 10px; font-size: 13px; }
.s18-src { margin-top: 10px; font-size: 11px; opacity: .7; }
@media (max-width: 560px) {
  .s18-answer-card { grid-template-columns: 1fr; }
  .s18-answer-img { width: 100%; height: 140px; }
  .s18-strip-all { display: none; }
}

/* Restock log table (homepage) */
.s18-log-wrap { margin-top: 14px; overflow-x: auto; }
.s18-log { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.s18-log th { text-align: left; font-weight: 600; color: var(--dim); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; padding: 8px 10px; border-bottom: 1px solid var(--line-2); }
.s18-log td { padding: 9px 10px; border-bottom: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.s18-log td strong { color: var(--text); }

/* Product page (dark theme, same panel look as the rest of the site) */
.s18-live { border-radius: 16px; background: var(--panel); border: 1px solid var(--line-2); padding: 20px; }
.s18-live h2, .s18-live h3 { color: var(--text); }
.s18-live .s18-zip-in { background: var(--panel-2); border: 1px solid var(--line-2); color: var(--text); }
.s18-btn-ghost { border: 1px solid var(--line-2); color: var(--text); }
.s18-btn-ghost:hover { background: var(--panel-2); }
.s18-hist-table td.is-in { color: #6EE7B7; font-weight: 700; }
.s18-hist-table td.is-out { color: var(--muted); }
.s18-hist-table td.is-none { color: var(--dim); }
/* Stage 18 fix for a Stage 11 leftover: tables on tracker pages had a white box with near-white text. */
.tr-table-wrap { background: var(--panel) !important; border: 1px solid var(--line-2) !important; }
.tr-table th, .tr-table td { color: var(--muted) !important; border-color: var(--line-2) !important; }
.tr-table th { color: var(--text) !important; }
.tr-table td.font-semibold, .tr-table td a { color: var(--text) !important; }
.tr-table td a.text-berry { color: var(--green-2) !important; }
.s18-cmp td { white-space: normal; vertical-align: top; }
.s18-cmp td:nth-child(2) { color: var(--text); background: rgba(16,185,129,.06); }
.s18-cmp th:nth-child(2) { color: #6EE7B7; }

/* Stage 19: each check's own schedule, Best Buy "soon" pill */
.s18-stores li .s18-every { grid-row: 2; grid-column: 1 / -1; margin-top: -2px; font-size: 11.5px; color: var(--muted); }
.s18-every-line { margin: 8px 0 0; font-size: 12.5px; color: var(--muted); }
.s11-store.is-soon { opacity: .55; }
.s18-stores li .s18-buy { grid-row: 1; grid-column: 3; }

/* Stage 20: choose stores per tracker */
.s20-stores { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; margin: 8px 0 2px; }
.s20-store { display: inline-flex; gap: 5px; align-items: center; font-size: 13px; padding: 3px 9px; border: 1px solid var(--line-2); border-radius: 999px; cursor: pointer; }
.s20-store input { accent-color: var(--green); }
.s20-store:has(input:not(:checked)) { opacity: .55; text-decoration: line-through; }
.s20-muted { opacity: .4; text-decoration: line-through; }
.s20-rules { margin: 10px 0 0; padding-left: 18px; font-size: 13.5px; color: var(--muted); display: grid; gap: 4px; }
