/* pokemoncardvalue.com — PokeVision brand palette, own identity.
   White canvas, ink text, warm amber→orange accent, hairlines, soft shadows. */
:root {
  --bg: #fdfcfa;
  --ink: #1c1c1e;
  --muted: #6f6f74;
  --hairline: #e8e5e0;
  --accent1: #f9a825;
  --accent2: #ec5a2a;
  --card: #ffffff;
  --green: #2e9e5b;
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, sans-serif;
}
a { color: var(--accent2); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; }

/* header */
.top {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px; border-bottom: 1px solid var(--hairline);
  background: #fff; position: sticky; top: 0; z-index: 10;
}
.brand { font-size: 20px; font-weight: 800; letter-spacing: -0.4px; color: var(--ink); }
.brand span {
  background: linear-gradient(90deg, var(--accent1), var(--accent2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.top nav { display: flex; gap: 18px; align-items: center; }
.top nav a { color: var(--ink); font-weight: 600; font-size: 14.5px; }
.nav-app {
  white-space: nowrap;
  background: linear-gradient(90deg, var(--accent1), var(--accent2));
  color: #fff !important; padding: 8px 14px; border-radius: 999px;
  box-shadow: 0 4px 14px rgba(236, 90, 42, 0.35);
}
.nav-app:hover { text-decoration: none; filter: brightness(1.05); }

main { max-width: 980px; margin: 0 auto; padding: 26px 20px 60px; }
h1 { font-size: 30px; letter-spacing: -0.6px; line-height: 1.15; margin: 6px 0 10px; }
.lede { color: var(--muted); font-size: 16.5px; max-width: 46em; }

/* quick-nav jump table (cards with many printings) */
.quicknav {
  background: var(--card); border: 1px solid var(--hairline);
  border-radius: 16px; margin: 18px 0 6px; overflow: hidden;
  box-shadow: 0 6px 22px rgba(28, 28, 30, 0.05);
}
.qn-bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--hairline);
}
.qn-head { margin: 0; font-weight: 700; font-size: 14px; }
.qn-controls { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.qn-sortwrap { display: flex; gap: 6px; align-items: center; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.qn-filter, .qn-sort {
  border: 1px solid var(--hairline); border-radius: 10px;
  padding: 7px 12px; font-size: 13.5px;
  background: var(--bg); color: var(--ink);
}
.qn-filter { width: 150px; }
.qn-filter:focus, .qn-sort:focus { outline: 2px solid var(--accent1); border-color: transparent; }
.qn-scroll { max-height: 340px; overflow: auto; }
.quicknav table { border-collapse: collapse; width: 100%; font-size: 14px; }
.quicknav th {
  text-align: left; color: var(--muted); font-weight: 600; font-size: 12px;
  text-transform: uppercase; letter-spacing: 0.4px; padding: 8px 16px;
  position: sticky; top: 0; background: var(--card);
  border-bottom: 1px solid var(--hairline);
}
.quicknav td { padding: 7px 16px; border-bottom: 1px solid var(--hairline); }
.quicknav tr:last-child td { border-bottom: none; }
.quicknav a { color: var(--ink); font-weight: 600; }
.quicknav a:hover { color: var(--accent2); }

/* anchored sections shouldn't hide under the sticky header */
.printing { scroll-margin-top: 74px; }

/* card page printings */
.printing {
  background: var(--card); border: 1px solid var(--hairline);
  border-radius: 16px; padding: 18px 20px; margin: 22px 0;
  box-shadow: 0 6px 22px rgba(28, 28, 30, 0.05);
}
.printing h2 { font-size: 19px; letter-spacing: -0.3px; margin: 0 0 12px; }
.printing-body { display: flex; gap: 22px; align-items: flex-start; }
.printing-body figure { margin: 0; flex: 0 0 245px; }
.printing-body img { border-radius: 10px; }
.printing-data { flex: 1; min-width: 0; }
.setline { margin: 0 0 10px; color: var(--muted); font-size: 14px; }

table.prices, table.setlist { border-collapse: collapse; width: 100%; font-size: 14.5px; }
.tscroll { overflow-x: auto; max-width: 100%; }
.prices th, .setlist th {
  text-align: left; color: var(--muted); font-weight: 600; font-size: 12.5px;
  text-transform: uppercase; letter-spacing: 0.4px;
  border-bottom: 1px solid var(--hairline); padding: 6px 10px 6px 0;
}
.prices td, .setlist td {
  border-bottom: 1px solid var(--hairline); padding: 9px 10px 9px 0;
}
td.m { font-weight: 800; color: var(--green); }
.noprice { color: var(--muted); font-style: italic; }

/* buy buttons */
.buyrow { display: flex; gap: 10px; flex-wrap: wrap; margin: 14px 0 2px; }
.buy {
  display: inline-block; padding: 9px 16px; border-radius: 12px;
  font-weight: 700; font-size: 14px; color: #fff !important;
}
.buy:hover { text-decoration: none; filter: brightness(1.07); }
.buy.tcg { background: #0b6efd; }
.buy.cm { background: #1d3557; }
.buy.ebay { background: #86400f; }

/* set list page */
.setlist td.thumb { width: 56px; }
.setlist img { border-radius: 4px; display: block; }

/* breadcrumbs, freshness, per-printing prose */
.crumbs { font-size: 13px; color: var(--muted); margin: 2px 0 4px; }
.crumbs a { color: var(--muted); }
.updated { font-size: 13px; color: var(--muted); margin: -2px 0 4px; }
.artist { font-size: 13.5px; color: var(--muted); margin: 12px 0 0; }
.flavor {
  margin: 10px 0 0; padding: 8px 14px; border-left: 3px solid var(--accent1);
  color: var(--muted); font-style: italic; font-size: 14px;
}

/* related-card chips */
.related h2 { font-size: 18px; margin: 26px 0 10px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }
.chip {
  border: 1px solid var(--hairline); background: #fff; color: var(--ink);
  padding: 7px 13px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
}
.chip:hover { border-color: var(--accent2); color: var(--accent2); text-decoration: none; }

/* app CTA footer */
.app-cta {
  border-top: 1px solid var(--hairline); background: #fff;
  padding: 34px 20px 26px; text-align: center;
}
.cta-inner { max-width: 620px; margin: 0 auto; }
.cta-head { font-size: 22px; font-weight: 800; letter-spacing: -0.4px; margin: 0 0 6px; }
.cta-sub { color: var(--muted); margin: 0 0 16px; }
.cta-buttons { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin: 0 0 8px; }
.cta-buttons a {
  background: linear-gradient(90deg, var(--accent1), var(--accent2));
  color: #fff; font-weight: 700; padding: 12px 22px; border-radius: 14px;
  box-shadow: 0 6px 18px rgba(236, 90, 42, 0.32);
}
.cta-buttons a:hover { text-decoration: none; filter: brightness(1.05); }
.foot { color: var(--muted); font-size: 13px; margin-top: 22px; }

/* responsive */
@media (max-width: 900px) {
  .printing-body { flex-direction: column; }
  .printing-body figure { flex: none; align-self: center; }
}
/* mobile sub-row under the sticky header: Sets/Cards stay reachable even
   though the main nav collapses to icons on small screens */
/* nav.subnav: must out-rank ".top nav {display:flex}", which otherwise
   force-shows this on desktop (class alone loses the specificity fight) */
.top nav.subnav { display: none; }
@media (max-width: 640px) {
  .top { flex-wrap: wrap; padding-bottom: 0; }
  .top nav.subnav {
    display: flex; flex-basis: 100%; justify-content: center; gap: 26px;
    margin-top: 8px; padding: 8px 0 9px;
    border-top: 1px solid var(--hairline);
  }
  .subnav a { color: var(--ink); font-weight: 600; font-size: 13.5px; }
  /* header grew ~40px taller: keep anchored sections clear of it */
  .printing, .scanpromo { scroll-margin-top: 118px; }
  h2[id^="l"] { scroll-margin-top: 118px; }
  .wo { display: none; }
  .quicknav th, .quicknav td { padding: 6px 6px 6px 0; font-size: 12px; }
  .quicknav th:first-child, .quicknav td:first-child { padding-left: 10px; }
  .qn-sub { font-size: 10.5px; }
  .top nav { gap: 12px; }
  .top nav:not(.subnav) a:not(.nav-app):not(.nav-search) { display: none; }
  main { padding: 18px 14px 40px; }
}

/* header smart search */
.nav-search { display: inline-flex; align-items: center; color: var(--ink); }
.nav-search:hover { color: var(--accent2); }
.hsearch {
  position: absolute; top: 100%; right: 20px;
  width: min(520px, calc(100vw - 40px));
  background: #fff; border: 1px solid var(--hairline); border-top: none;
  border-radius: 0 0 14px 14px; padding: 10px;
  box-shadow: 0 14px 34px rgba(28, 28, 30, 0.12); z-index: 20;
}
.hsearch-input {
  width: 100%; border: 1px solid var(--hairline); border-radius: 10px;
  padding: 10px 14px; font-size: 15px; background: var(--bg); color: var(--ink);
}
.hsearch-input:focus { outline: 2px solid var(--accent1); border-color: transparent; }
.hsearch-results { margin-top: 6px; }
.hs-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 9px 12px; border-radius: 9px; color: var(--ink); font-weight: 600;
  font-size: 14.5px;
}
.hs-item em {
  font-style: normal; color: var(--muted); font-size: 11.5px;
  text-transform: uppercase; letter-spacing: 0.4px;
}
.hs-item:hover, .hs-sel { background: var(--bg); text-decoration: none; color: var(--accent2); }

/* home + search pages */
.bigsearch { position: relative; margin: 18px 0 30px; max-width: 560px; }
.bigsearch input {
  width: 100%; border: 1px solid var(--hairline); border-radius: 14px;
  padding: 14px 18px; font-size: 17px; background: #fff; color: var(--ink);
  box-shadow: 0 6px 22px rgba(28, 28, 30, 0.06);
}
.bigsearch input:focus { outline: 2px solid var(--accent1); border-color: transparent; }
#page-search-results {
  position: absolute; left: 0; right: 0; top: 100%; z-index: 5;
  background: #fff; border-radius: 12px; margin-top: 6px;
  box-shadow: 0 14px 34px rgba(28, 28, 30, 0.14);
}
#page-search-results:empty { display: none; }
.home h2 { font-size: 20px; margin: 30px 0 12px; }
.popgrid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
}
.pop {
  display: flex; flex-direction: column; gap: 4px; color: var(--ink);
  background: #fff; border: 1px solid var(--hairline); border-radius: 12px;
  padding: 10px; font-size: 13.5px; font-weight: 600;
}
.pop:hover { border-color: var(--accent2); text-decoration: none; }
.pop img { border-radius: 6px; width: 100%; height: auto; }
.pop-val { color: var(--green); font-weight: 800; }

/* archives */
.letterbar { display: flex; flex-wrap: wrap; gap: 6px; }
.letterbar a {
  border: 1px solid var(--hairline); border-radius: 8px; padding: 4px 10px;
  font-weight: 700; color: var(--ink); font-size: 14px;
}
.letterbar a:hover { border-color: var(--accent2); color: var(--accent2); text-decoration: none; }
h2[id^="l"] { scroll-margin-top: 74px; }

/* ranked (rare cards) table */
.ranked td.rank { font-weight: 800; color: var(--muted); width: 34px; }
.ranked .sub { display: block; color: var(--muted); font-size: 12px; font-weight: 500; }

/* set logos on the set index pages */
.setlist td.setlogo { width: 120px; }
/* fixed box + contain: every logo occupies the same footprint regardless of
   its native aspect ratio */
.setlist td.setlogo img { width: 100px; height: 36px; object-fit: contain; display: block; }

/* set page header + prev/next nav */
.set-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.set-head .set-logo { max-height: 64px; max-width: 220px; width: auto; height: auto; }
.rarity { color: var(--muted); font-size: 14px; }
.setnav {
  display: flex; justify-content: space-between; gap: 12px;
  margin: 6px 0 14px; font-weight: 700;
}

/* chase-tile PSA line + quick-nav rarity subline */
.pop-psa { color: var(--muted); font-size: 12px; font-weight: 600; }
.qn-sub { display: block; color: var(--muted); font-size: 11.5px; font-weight: 500; }

/* homepage prose sections */
.home-prose { max-width: 46em; }
.home-prose p { color: var(--muted); line-height: 1.6; }
.ranked td.psa { color: var(--muted); font-weight: 700; }
.quicknav td.psa { color: var(--muted); font-weight: 700; }

/* scan-demo promo unit: CSS-only "video" — card slides in, scan line sweeps,
   price pops. Loops every 4.5s; frozen on the final frame for reduced-motion. */
.scanpromo {
  display: flex; gap: 24px; align-items: center;
  background: linear-gradient(135deg, #fff8ec, #ffeee2);
  border: 1.5px solid rgba(236, 90, 42, 0.4);
  border-radius: 16px; padding: 18px 20px; margin: 22px 0;
  box-shadow: 0 8px 26px rgba(236, 90, 42, 0.12);
}
.sp-phone {
  flex: 0 0 148px; height: 280px; border-radius: 24px;
  background: #1c1c1e; padding: 9px; box-shadow: inset 0 0 0 2px #38383d;
}
.sp-screen {
  position: relative; width: 100%; height: 100%; border-radius: 16px;
  background: linear-gradient(180deg, #2b2b30, #232327); overflow: hidden;
}
.sp-reticle {
  position: absolute; left: 24px; right: 24px; top: 70px; height: 130px;
  border-radius: 10px;
  background:
    linear-gradient(var(--accent1), var(--accent1)) top left/16px 2.5px,
    linear-gradient(var(--accent1), var(--accent1)) top left/2.5px 16px,
    linear-gradient(var(--accent1), var(--accent1)) top right/16px 2.5px,
    linear-gradient(var(--accent1), var(--accent1)) top right/2.5px 16px,
    linear-gradient(var(--accent1), var(--accent1)) bottom left/16px 2.5px,
    linear-gradient(var(--accent1), var(--accent1)) bottom left/2.5px 16px,
    linear-gradient(var(--accent1), var(--accent1)) bottom right/16px 2.5px,
    linear-gradient(var(--accent1), var(--accent1)) bottom right/2.5px 16px;
  background-repeat: no-repeat;
}
.sp-card {
  position: absolute; left: 50%; top: 84px; width: 74px; height: 102px;
  margin-left: -37px; border-radius: 6px;
  background: linear-gradient(160deg, #f5d76e 0%, #f0b429 55%, #e08e0b 100%);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45);
  animation: sp-card 4.5s ease-in-out infinite;
}
.sp-card span {
  position: absolute; inset: 7px 7px 46px; border-radius: 4px;
  background: linear-gradient(140deg, #7ec8ff, #2f7bd8);
}
.sp-card i {
  position: absolute; left: 7px; right: 7px; bottom: 8px; height: 5px;
  border-radius: 3px; background: rgba(0, 0, 0, 0.25);
  box-shadow: 0 9px 0 rgba(0, 0, 0, 0.18), 0 18px 0 rgba(0, 0, 0, 0.12);
}
.sp-line {
  position: absolute; left: 26px; right: 26px; top: 74px; height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--accent2), transparent);
  animation: sp-line 4.5s ease-in-out infinite;
}
.sp-pill {
  position: absolute; top: 26px; left: 50%;
  transform: translateX(-50%) scale(0);
  background: var(--green); color: #fff; font-weight: 800; font-size: 14px;
  padding: 5px 12px; border-radius: 999px; white-space: nowrap;
  box-shadow: 0 4px 14px rgba(46, 158, 91, 0.5);
  animation: sp-pill 4.5s ease-in-out infinite;
}
@keyframes sp-card {
  0% { transform: translateY(230px) scale(0.9); }
  16%, 88% { transform: translateY(0) scale(1); }
  100% { transform: translateY(230px) scale(0.9); }
}
@keyframes sp-line {
  0%, 18% { transform: translateY(0); opacity: 0; }
  22% { opacity: 1; }
  40% { transform: translateY(122px); opacity: 1; }
  56% { transform: translateY(8px); opacity: 1; }
  60%, 100% { opacity: 0; }
}
@keyframes sp-pill {
  0%, 60% { transform: translateX(-50%) scale(0); }
  67% { transform: translateX(-50%) scale(1.12); }
  71%, 86% { transform: translateX(-50%) scale(1); }
  92%, 100% { transform: translateX(-50%) scale(0); }
}
@media (prefers-reduced-motion: reduce) {
  .sp-card, .sp-line, .sp-pill { animation: none; }
  .sp-card { transform: none; }
  .sp-line { opacity: 0; }
  .sp-pill { transform: translateX(-50%) scale(1); }
}
.sp-copy { flex: 1; min-width: 0; }
.sp-head { margin: 0 0 6px; font-size: 19px; font-weight: 800; letter-spacing: -0.3px; }
.sp-sub { margin: 0 0 14px; color: var(--muted); line-height: 1.5; }
.sp-buttons { display: flex; gap: 10px; flex-wrap: wrap; margin: 0; }
.sp-buttons a {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: 14.5px;
  padding: 10px 18px; border-radius: 12px;
}
.sp-buttons a.sp-ios { background: #000; color: #fff; border: 1.5px solid #000; }
.sp-buttons a.sp-play { background: #fff; color: #111; border: 1.5px solid #111; }
.sp-buttons a:hover { text-decoration: none; filter: brightness(1.06); }
@media (max-width: 640px) {
  .scanpromo { flex-direction: column; }
  /* in column flow the basis becomes height and auto-width collapses (the
     screen's contents are absolutely positioned) — pin both dimensions */
  .sp-phone { flex: none; width: 148px; height: 280px; }
  .sp-copy { text-align: center; }
  .sp-buttons { justify-content: center; }
}
.sp-card.sp-real { object-fit: cover; background: none; }

html { scroll-behavior: smooth; }
.scanpromo { scroll-margin-top: 80px; }
.site-foot {
  border-top: 1px solid var(--hairline); background: #fff;
  padding: 20px; text-align: center;
}
