
:root {
  --bg: #f1f2f4; --panel: #ffffff; --ink: #151833; --muted: #636780; --line: #dde0e7;
  --accent: #6d41f9; --accent-ink: #fff; --ok: #247348; --chip: #e7e8ee; --chip-on: #151833;
  --danger: #d23b38; --soft: #efeafe; --star: #fcc035; --star-ink: #151833;
  --shadow: 0 1px 2px rgba(0,0,0,.05), 0 8px 24px -14px rgba(0,0,0,.25);
  --radius: 14px; --top-h: 71px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --bg: #0e1020; --panel: #171a2c; --ink: #f3f2fa; --muted: #a4a7bf; --line: #2b2f47;
  --accent: #7c55fa; --ok: #8fd5ad; --chip: #22263a; --chip-on: #f3f2fa; --shadow: 0 8px 24px -14px rgba(0,0,0,.8);
  --danger: #f26b67; --soft: #262046;
  color-scheme: dark;
} }
:root[data-theme="dark"] {
  --bg: #0e1020; --panel: #171a2c; --ink: #f3f2fa; --muted: #a4a7bf; --line: #2b2f47;
  --accent: #7c55fa; --ok: #8fd5ad; --chip: #22263a; --chip-on: #f3f2fa; --shadow: 0 8px 24px -14px rgba(0,0,0,.8);
  --danger: #f26b67; --soft: #262046;
  color-scheme: dark;
}

:root[data-size="s"] { --card-min: 150px; }
:root[data-size="m"] { --card-min: 195px; }
:root[data-size="l"] { --card-min: 260px; }
:root[data-size="s"] .card .when, :root[data-size="s"] .card .set img { display: none; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 15px/1.45 ui-rounded, "SF Pro Rounded", -apple-system, system-ui, "Segoe UI", sans-serif;
}
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
button, .chip { touch-action: manipulation; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }
html.locked, html.sheet { overflow: hidden; overscroll-behavior: none; scrollbar-gutter: stable; }
html.locked body, html.sheet body { overflow: hidden; }

.top {
  position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line);
}
.top-in { max-width: 1760px; margin: 0 auto; padding: 12px 24px; display: flex; gap: 12px; align-items: center; }
.brand { display: inline-flex; align-items: center; font-weight: 800; font-size: 20px; letter-spacing: -.02em; text-decoration: none; color: inherit; white-space: nowrap; }
.brand img { display: block; height: 36px; width: auto; }
.brand small { font-weight: 500; color: var(--muted); font-size: 12px; margin-left: 6px; }
.search { flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 0 14px; height: 46px; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.search:focus-within { border-color: var(--ink); }
.search svg { width: 20px; height: 20px; color: var(--muted); flex: none; }
.search input { flex: 1; border: 0; background: none; font: inherit; font-size: 16px; color: inherit; outline: none; min-width: 0; }
.search .clear { color: var(--muted); font-size: 22px; line-height: 1; padding: 4px 6px; }
a.icon-btn { color: inherit; text-decoration: none; }
.icon-btn { position: relative; width: 46px; height: 46px; border-radius: 999px; background: var(--panel); border: 1px solid var(--line); display: grid; place-items: center; box-shadow: 0 1px 2px rgba(0,0,0,.04); flex: none; transition: border-color .15s, transform .15s; }
.icon-btn:hover { border-color: var(--muted); }
.icon-btn:active { transform: scale(.94); }
.icon-btn svg { width: 21px; height: 21px; display: block; stroke-width: 1.7; }
.icon-btn.on { border-color: var(--ink); }
@media (max-width: 860px) { .icon-btn.on { border-color: var(--line); } }
.icon-btn.pill { width: auto; padding: 0 14px 0 12px; gap: 8px; display: inline-flex; align-items: center; font-weight: 600; font-size: 14px; }
.icon-btn.pill .lbl:empty { display: none; }
@media (max-width: 860px) { .icon-btn.pill { width: 46px; padding: 0; justify-content: center; gap: 0; } .icon-btn.pill .lbl { display: none; } }
@media (max-width: 520px) { .icon-btn.pill.admin-pill { display: none; } }
@media (max-width: 480px) {
  .top-in { gap: 8px; padding: 10px 12px; flex-wrap: wrap; }
  .brand { margin-right: auto; }
  .brand img { height: 32px; }
  .brand small { display: none; }
  .icon-btn, .icon-btn.pill { width: 42px; height: 42px; }
  .search { order: 1; flex-basis: 100%; height: 42px; padding: 0 12px; }
}
.brand small { cursor: default; }
.brand small[title] { cursor: pointer; padding: 2px 6px; border-radius: 6px; background: var(--accent); color: var(--accent-ink); }
.badge { position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--star); color: var(--star-ink); font-size: 12px; font-weight: 700; display: grid; place-items: center; }
.badge:empty { display: none; }
.badge.pop { animation: pop .35s cubic-bezier(.2,1.4,.4,1); }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.45); } 100% { transform: scale(1); } }

.wrap { max-width: 1760px; margin: 0 auto; padding: 20px 24px; display: grid; grid-template-columns: 250px 1fr; gap: 28px; align-items: start; }
.side { position: sticky; top: calc(var(--top-h) + 16px); max-height: calc(100dvh - var(--top-h) - 32px); overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; padding-right: 4px; }
html.no-filters .wrap { grid-template-columns: 1fr; }
html.no-filters .side { display: none; }
@media (max-width: 860px) {
  .wrap { grid-template-columns: 1fr; padding: 16px; }
  .top-in { padding: 12px 16px; }
  html.no-filters .side, .side { display: block; position: fixed; inset: 0; z-index: 30; max-height: none; background: var(--bg); overflow: auto; padding: 16px; transform: translateX(-100%); transition: transform .22s ease; }
  .side.open { transform: none; }
}
.side h4 { margin: 18px 0 8px; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
.side > h4:first-child { margin-top: 0; }
.side-close { display: none; width: 100%; padding: 14px; border-radius: 14px; background: var(--ink); color: var(--bg); font-weight: 700; font-size: 15px; box-shadow: 0 8px 24px -8px rgba(0,0,0,.5); }
@media (max-width: 860px) {
  .side-close { display: block; position: sticky; bottom: calc(16px + env(safe-area-inset-bottom)); margin-top: 24px; z-index: 31; }
}

.toolbar { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; flex-wrap: wrap; }
.status { margin: 0; color: var(--muted); font-size: 13px; flex: 1; }
.status b { color: var(--ink); }
select.sort { padding: 8px 12px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--panel); color: inherit; font: inherit; font-size: 13px; font-weight: 600; }
.seg { display: inline-flex; border: 1.5px solid var(--line); border-radius: 10px; background: var(--panel); overflow: hidden; }
.seg button { width: 38px; height: 36px; display: grid; place-items: center; color: var(--muted); transition: background .15s, color .15s; }
.seg button + button { border-left: 1.5px solid var(--line); }
.seg button.on { background: var(--chip-on); color: var(--bg); }
.seg svg { width: 14px; height: 14px; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { padding: 7px 12px; border-radius: 999px; background: var(--chip); font-size: 13px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; min-height: 34px; border: 1.5px solid transparent; transition: background .15s, color .15s, border-color .15s, transform .12s; }
.chip:hover { border-color: var(--line); }
.chip:active { transform: scale(.96); }
.chip.on { background: var(--chip-on); color: var(--bg); }
.chip img { width: 16px; height: 16px; object-fit: contain; }
.chip .swatch { width: 14px; height: 14px; border-radius: 50%; background: var(--sw); box-shadow: inset 0 0 0 1px rgba(0,0,0,.18); flex: none; }
.chip.on .swatch { box-shadow: 0 0 0 1.5px var(--bg); }
.chip .n { opacity: .6; font-weight: 500; }
.toggle { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px; background: var(--panel); border: 1.5px solid var(--line); border-radius: 12px; font-weight: 600; }
.toggle input { width: 22px; height: 22px; accent-color: var(--ok); }
.toggle + .toggle, .toggle-why:not([hidden]) + .toggle { margin-top: 8px; }
.toggle:has(input:disabled) { color: var(--muted); }
.toggle-why { margin: 4px 2px 0; font-size: 12px; color: var(--muted); }
.toggle-why a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }

.t-Grass { --c: #1f6b2a; --cb: #dff3e0; } .t-Fire { --c: #b3391a; --cb: #fde3d8; }
.t-Water { --c: #1d5fa3; --cb: #d9ecfb; } .t-Lightning { --c: #7a5c00; --cb: #fdf3c4; }
.t-Psychic { --c: #6b2e9c; --cb: #ead9f5; } .t-Fighting { --c: #8a4a1f; --cb: #f1dfd0; }
.t-Darkness { --c: #2f2a45; --cb: #dedbe6; } .t-Metal { --c: #4c545c; --cb: #e6e8ea; }
.t-Dragon { --c: #7a5a10; --cb: #f3e6c5; } .t-Fairy { --c: #a0326a; --cb: #fbe0ec; }
.t-Colorless { --c: #5a5750; --cb: #ecebe7; }
.chip[class*="t-"] { background: var(--cb); color: var(--c); }
.chip[class*="t-"].on { background: var(--c); color: #fff; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .chip[class*="t-"]:not(.on) { background: color-mix(in srgb, var(--c) 22%, transparent); color: color-mix(in srgb, var(--c) 40%, #fff); } }
:root[data-theme="dark"] .chip[class*="t-"]:not(.on) { background: color-mix(in srgb, var(--c) 22%, transparent); color: color-mix(in srgb, var(--c) 40%, #fff); }

.sets { max-height: 380px; overflow: auto; border: 1.5px solid var(--line); border-radius: 12px; background: var(--panel); scrollbar-width: thin; }
.sets details { border-bottom: 1px solid var(--line); }
.sets summary { padding: 9px 12px; font-weight: 700; font-size: 13px; cursor: pointer; list-style: none; display: flex; align-items: center; gap: 8px; }
.sets summary small { font-weight: 500; color: var(--muted); font-size: 11px; }
.sets summary .n { margin-left: auto; font-weight: 500; opacity: .55; font-size: 12px; }
.sets summary::after { content: "›"; color: var(--muted); transform: rotate(90deg); margin-left: 4px; }
.sets details[open] summary::after { transform: rotate(-90deg); }
.set { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; padding: 7px 12px 7px 18px; font-size: 13px; }
.set:hover { background: var(--chip); }
.set.on { background: var(--chip-on); color: var(--bg); }
.set img { width: 26px; height: 16px; object-fit: contain; }
.set .nologo { width: 26px; height: 16px; display: inline-block; }
.set .n { margin-left: auto; opacity: .55; font-size: 12px; }
.set .dexno { color: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
#pokedex .set img { width: 28px; height: 28px; margin: -6px 0; image-rendering: pixelated; }
#pokedex .set { padding-top: 5px; padding-bottom: 5px; }
.chip.species img { width: 24px; height: 24px; margin: -6px -2px -6px -6px; image-rendering: pixelated; }

.active { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.active:empty { display: none; }
.active .chip { background: var(--panel); border-color: var(--line); }
.side-active { display: none; }
.side > .side-active + h4 { margin-top: 0; }
@media (max-width: 860px) { .side-active:not(:empty) { display: flex; margin-bottom: 18px; } }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(var(--card-min), 1fr)); gap: 16px; }
@media (max-width: 480px) {
  .grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .card .when, .card .set img { display: none; }
  .price { font-size: 14px; white-space: nowrap; }
  .toolbar { gap: 8px; }
  .status { white-space: nowrap; }
  .seg { display: none; }
}
.card { background: var(--panel); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; border: 1.5px solid transparent;
  transition: border-color .15s, box-shadow .25s; content-visibility: auto; contain-intrinsic-size: auto 200px 360px;
  animation: rise .4s cubic-bezier(.2,.8,.2,1) backwards; animation-delay: calc(var(--i, 0) * 22ms); }
@keyframes rise { from { opacity: 0; translate: 0 14px; } to { opacity: 1; translate: 0 0; } }
.card:hover { border-color: var(--line); box-shadow: 0 2px 4px rgba(0,0,0,.06), 0 24px 48px -20px rgba(0,0,0,.45); z-index: 1; }
.card .pic { aspect-ratio: 245 / 342; background: var(--chip); position: relative; cursor: pointer; overflow: hidden; }
.card .pic img, .card .pic .ph { width: 100%; height: 100%; object-fit: cover; }
.fin { position: absolute; left: 8px; bottom: 8px; padding: 3px 8px; border-radius: 999px; background: rgba(12,12,13,.72); color: #fff; font-size: 10px; font-weight: 700; letter-spacing: .03em; pointer-events: none; }
@media (hover: hover) and (pointer: fine) {
  .card { transition: border-color .15s, box-shadow .25s, transform .35s cubic-bezier(.2,.8,.2,1); }
  .card.tilting { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) scale(var(--s, 1)); }
  .card .pic::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: var(--g, 0); transition: opacity .3s; background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,.3), transparent 55%); mix-blend-mode: screen; }
  .fin { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
}
.holo { display: none; position: absolute; inset: 0; pointer-events: none; overflow: hidden; --k: .75; opacity: calc(var(--g, 0) * var(--k)); transition: opacity .3s; mix-blend-mode: color-dodge; }
.holo::before, .holo::after { content: ""; position: absolute; inset: 0; }
.holo::before { background: linear-gradient(115deg, transparent 20%, rgba(255,80,80,.7) 34%, rgba(255,220,80,.7) 42%, rgba(80,255,120,.7) 50%, rgba(80,220,255,.7) 58%, rgba(120,80,255,.7) 66%, transparent 80%) no-repeat;
  background-size: 200% 200%; background-position: clamp(0%, var(--mx, 50%), 100%) clamp(0%, var(--my, 50%), 100%); filter: brightness(.9) contrast(1.3) saturate(1.2); }
.holo.window::before { clip-path: inset(var(--ay1) calc(100% - var(--ax2)) calc(100% - var(--ay2)) var(--ax1)); }
.holo.window::before, .holo.reverse::before {
  background: repeating-linear-gradient(115deg, hsl(0 95% 62%) 0%, hsl(45 100% 60%) 2.5%, hsl(120 90% 55%) 5%, hsl(190 95% 60%) 7.5%, hsl(270 90% 66%) 10%, hsl(330 95% 62%) 12.5%, hsl(0 95% 62%) 15%) no-repeat;
  background-size: 200% 200%; filter: brightness(.95) contrast(1.4) saturate(1.3);
  -webkit-mask-image: radial-gradient(farthest-corner circle at var(--mx, 50%) var(--my, 50%), #000 5%, rgba(0,0,0,.2) 75%);
  mask-image: radial-gradient(farthest-corner circle at var(--mx, 50%) var(--my, 50%), #000 5%, rgba(0,0,0,.2) 75%); }
.holo.window { --k: .65; }
.holo.reverse { --k: .55; }
.holo.reverse::before { clip-path: polygon(evenodd, 0 0, 100% 0, 100% 100%, 0 100%, 0 0, var(--ax1) var(--ay1), var(--ax1) var(--ay2), var(--ax2) var(--ay2), var(--ax2) var(--ay1), var(--ax1) var(--ay1)); }
.holo.full { --k: .85; }
.holo.full::after { background: radial-gradient(circle, rgba(255,255,255,.5) 0 .4px, transparent .9px) 0 0 / 5px 5px, radial-gradient(circle, rgba(255,255,255,.35) 0 .35px, transparent .8px) 2px 3px / 7px 7px,
    repeating-linear-gradient(60deg, transparent 0 2px, rgba(255,255,255,.08) 2px 3px); filter: blur(.3px);
  -webkit-mask-image: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), #000, transparent 40%); mask-image: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), #000, transparent 40%); }
.holo.sheen { --k: .35; }
@media (hover: hover) and (pointer: fine) { .holo { display: block; } }
.card .body { padding: 10px 10px 10px; display: flex; flex-direction: column; gap: 5px; }
.card .name { font-weight: 700; font-size: 14px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card .set { padding: 0; font-size: 12px; color: var(--muted); gap: 5px; }
.card .set img { width: 22px; height: 12px; }
.card .set > span:first-of-type { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card .when { margin-left: auto; font-size: 11px; white-space: nowrap; opacity: .8; }
.card .row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 2px; }
.card .row .pricing { min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; }
.card .row .lang { margin-left: 0; }
.card .row .price { white-space: nowrap; }
.price { font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums; }
.price.none { color: var(--muted); font-weight: 600; font-size: 12px; }
.lang { display: inline-block; margin-left: 6px; padding: 1px 5px; border-radius: 5px; background: var(--chip); color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .04em; vertical-align: 2px; }
.flag { margin-right: 3px; font-size: 1.15em; line-height: 1; vertical-align: -1px; }
.price small { font-size: 11px; font-weight: 600; color: var(--muted); }
.add { width: 34px; height: 34px; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 20px; font-weight: 700; display: grid; place-items: center; flex: none; transition: transform .2s cubic-bezier(.2,.8,.2,1), opacity .2s, background .2s; }
.add:hover { transform: scale(1.1); }
.add:active { transform: scale(.92); }
.add:disabled { background: var(--chip); color: var(--muted); cursor: default; transform: none; }
.add.done { background: var(--ok); }
.add { position: relative; }
.add.in { background: var(--ok); color: var(--bg); }
.add svg { width: 18px; height: 18px; display: block; stroke-width: 2; }
.more { display: block; margin: 20px auto 0; padding: 12px 22px; border-radius: 999px; background: var(--panel); border: 1.5px solid var(--line); font-weight: 700; }
.empty { padding: 60px 20px; text-align: center; color: var(--muted); }
.empty b { display: block; color: var(--ink); font-size: 18px; margin-bottom: 6px; }

.detail { position: fixed; inset: 0; z-index: 40; background: rgba(0,0,0,.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; place-items: center; padding: 12px; animation: fade .2s ease both; }
@keyframes fade { from { opacity: 0; } }
.detail-in { background: var(--panel); border-radius: 22px; width: min(1040px, 100%); max-height: calc(100dvh - 24px); overflow: auto; display: grid; grid-template-columns: minmax(300px, 46%) 1fr; position: relative; animation: enter .32s cubic-bezier(.2,.9,.25,1) both; box-shadow: 0 40px 100px -30px rgba(0,0,0,.6); }
@keyframes enter { from { opacity: 0; transform: translateY(18px) scale(.97); } }
.detail-in { overscroll-behavior: contain; }
.detail-in.still { animation: none; }
.detail.still { animation: none; }
@media (max-width: 720px) { .detail-in { grid-template-columns: 1fr; } }
.detail .hero { padding: 28px; position: relative; overflow: hidden; display: grid; place-items: center; touch-action: pan-y; user-select: none; background: var(--chip); perspective: 1000px; min-height: 380px; }
.detail .hero .ambient { position: absolute; inset: -60px; background-size: cover; background-position: center; filter: blur(48px) saturate(1.6); opacity: .55; pointer-events: none; }
.detail .hero .tilt { position: relative; width: 100%; max-width: 400px; transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .4s cubic-bezier(.2,.8,.2,1), opacity .3s; transform-style: preserve-3d; will-change: transform; }
.detail .hero .tilt.drag { transition: none; }
.detail .hero .tilt img { width: 100%; aspect-ratio: 245 / 342; object-fit: cover; background: var(--chip) center / cover no-repeat; border-radius: 14px; box-shadow: 0 30px 60px -20px rgba(0,0,0,.6); }
.detail .hero .tilt .holo { border-radius: 14px; }
.detail .hero .tilt::after { content: ""; position: absolute; inset: 0; border-radius: 14px; pointer-events: none; opacity: var(--g, 0); transition: opacity .3s; background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,.35), transparent 50%); mix-blend-mode: screen; }
.detail .hero .tilt.slide-l { animation: slideL .3s cubic-bezier(.2,.8,.2,1); }
.detail .hero .tilt.slide-r { animation: slideR .3s cubic-bezier(.2,.8,.2,1); }
@keyframes slideL { from { opacity: 0; transform: translateX(40px) rotateY(-8deg); } }
@keyframes slideR { from { opacity: 0; transform: translateX(-40px) rotateY(8deg); } }
.detail .info { padding: 24px 60px 26px 26px; display: flex; flex-direction: column; gap: 14px; }
.detail h2, .detail .card-h { margin: 0; font-size: 28px; letter-spacing: -.02em; line-height: 1.1; }
.detail .sub { color: var(--muted); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 14px; }
.detail .sub img { width: 30px; height: 18px; object-fit: contain; }
.detail .facts { display: flex; gap: 6px; flex-wrap: wrap; }
.detail .facts .chip { min-height: 30px; padding: 5px 10px; font-size: 12px; }
.attack { padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 12px; }
.attack b { display: flex; justify-content: space-between; }
.attack .cost { display: inline-flex; gap: 3px; margin-right: 8px; vertical-align: middle; }
.attack .cost.tag { display: inline; font-size: 11px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.e { width: 16px; height: 16px; border-radius: 999px; background: var(--c, var(--muted)); display: inline-grid; place-items: center; }
.e::before { content: ""; width: 10px; height: 10px; background: #fff; mask: var(--glyph) center / contain no-repeat; -webkit-mask: var(--glyph) center / contain no-repeat; }
.t-Grass { --glyph: url(/energy/Grass.svg); } .t-Fire { --glyph: url(/energy/Fire.svg); } .t-Water { --glyph: url(/energy/Water.svg); }
.t-Lightning { --glyph: url(/energy/Lightning.svg); } .t-Psychic { --glyph: url(/energy/Psychic.svg); } .t-Fighting { --glyph: url(/energy/Fighting.svg); }
.t-Darkness { --glyph: url(/energy/Darkness.svg); } .t-Metal { --glyph: url(/energy/Metal.svg); } .t-Dragon { --glyph: url(/energy/Dragon.svg); }
.t-Fairy { --glyph: url(/energy/Fairy.svg); } .t-Colorless { --glyph: url(/energy/Colorless.svg); }
.chip[class*="t-"]::before { content: ""; width: 16px; height: 16px; border-radius: 999px; background: var(--c) var(--glyph) center / 10px no-repeat; flex: none; }
.chip[class*="t-"].on::before { box-shadow: 0 0 0 1.5px rgba(255,255,255,.7); }
.attack p { margin: 4px 0 0; font-size: 13px; color: var(--muted); }
.variants { display: grid; gap: 6px; }
.variant { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 10px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 12px; }
.variant .v { font-weight: 600; }
.variant .v small { color: var(--muted); font-weight: 500; margin-left: 6px; }
.variant .v small b { color: var(--ink); font-weight: 700; }
.variant .add { width: 34px; height: 34px; font-size: 20px; }
.variant.gone { opacity: .55; }
.partner-note { margin: 4px 2px 6px; font-size: 12.5px; line-height: 1.4; color: var(--muted); }
.variant.hit { animation: hit .7s ease; }
@keyframes hit { 0% { background: color-mix(in srgb, var(--ok) 25%, transparent); border-color: var(--ok); } 100% { background: transparent; } }
.variant kbd { display: none; font: inherit; font-size: 11px; font-weight: 700; color: var(--muted); width: 20px; height: 20px; border: 1.5px solid var(--line); border-radius: 5px; text-align: center; line-height: 17px; margin-right: 10px; }
@media (hover: hover) and (pointer: fine) { .variant { grid-template-columns: auto 1fr auto auto; } .variant kbd { display: inline-block; } }
.nav { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 999px; background: var(--panel); box-shadow: var(--shadow); display: grid; place-items: center; font-size: 26px; z-index: 2; transition: transform .15s; }
.nav:hover { transform: translateY(-50%) scale(1.08); }
.nav.prev { left: 8px; } .nav.next { right: 8px; }
.nav:disabled { opacity: .3; cursor: default; transform: translateY(-50%); }
.detail .bar { position: sticky; top: 0; grid-column: 1 / -1; height: 0; z-index: 3; }
.close { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; border-radius: 999px; background: var(--panel); box-shadow: var(--shadow); font-size: 22px; z-index: 2; }
.swipe-hint { text-align: center; font-size: 12px; color: var(--muted); }

.cart { position: fixed; inset: 0 0 0 auto; width: min(420px, 100%); z-index: 50; background: var(--panel); box-shadow: -10px 0 40px -20px rgba(0,0,0,.4); display: flex; flex-direction: column; transform: translateX(100%); transition: transform .25s cubic-bezier(.2,.8,.2,1); }
.cart.open { transform: none; }
.cart header { display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line); font-weight: 800; font-size: 18px; }
.cart .items { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 8px 18px; }
.item { display: grid; grid-template-columns: 48px 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.item img { width: 48px; border-radius: 6px; }
.item .n { display: block; font-weight: 700; font-size: 14px; text-align: left; }
.item-pic { display: block; }
.item-pic:disabled, .item .n:disabled { cursor: default; }
.item .m { color: var(--muted); font-size: 12px; }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; overflow: hidden; }
.qty button { width: 32px; height: 32px; display: grid; place-items: center; }
.qty button svg { width: 14px; height: 14px; }
.qty button:disabled { opacity: .3; cursor: default; }
.qty span { min-width: 24px; text-align: center; font-weight: 700; }
.cart footer { padding: 16px 18px; border-top: 1px solid var(--line); }
.total { display: flex; justify-content: space-between; font-weight: 800; font-size: 18px; margin-bottom: 10px; }
.checkout { width: 100%; padding: 14px; border-radius: 14px; background: var(--accent); color: var(--accent-ink); font-weight: 800; font-size: 16px; }
.checkout:disabled { background: var(--chip); color: var(--muted); cursor: default; }
.cart .note { font-size: 12px; color: var(--muted); text-align: center; margin: 8px 0 0; }
.scrim { position: fixed; inset: 0; z-index: 45; background: rgba(0,0,0,.3); }

.cond { display: inline-block; min-width: 30px; padding: 2px 6px; border-radius: 6px; text-align: center; color: #fff; font-size: 11px; font-weight: 800; letter-spacing: .04em; line-height: 1.3; vertical-align: 1px; }
.cond-MT { background: #17a2b8; } .cond-NM { background: #3caf56; } .cond-EX { background: #82891e; } .cond-GD { background: #ffc107; color: #1d1a14; }
.cond-LP { background: #fd8b2b; } .cond-PL { background: #e56874; } .cond-PO { background: #dc3545; }
.chip .cond { min-width: 0; margin-left: -4px; }
button.cond { cursor: help; }

.cs-wrap { position: fixed; inset: 0; z-index: 58; }
.cs-scrim { position: absolute; inset: 0; background: rgba(0,0,0,.45); animation: fade .2s ease both; }
.cs { position: absolute; left: 0; right: 0; bottom: 0; max-width: 560px; margin: 0 auto; max-height: 86svh; overflow: auto; overscroll-behavior: contain;
  background: var(--panel); border-radius: 20px 20px 0 0; padding: 10px 18px calc(18px + env(safe-area-inset-bottom)); box-shadow: 0 -20px 60px -20px rgba(0,0,0,.5);
  animation: cs-up .28s cubic-bezier(.2,.9,.25,1) both; }
@keyframes cs-up { from { transform: translateY(40px); opacity: 0; } }
.cs-grip { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 8px; }
.cs header { display: flex; align-items: center; justify-content: space-between; }
.cs h3 { margin: 0; font-size: 18px; }
.cs .close { position: static; width: 36px; height: 36px; box-shadow: none; background: var(--chip); }
.cs > p { margin: 4px 0 10px; color: var(--muted); font-size: 13px; }
.cs-row { display: grid; grid-template-columns: 40px 1fr; gap: 2px 10px; padding: 9px 8px; border-radius: 10px; }
.cs-row .cond { grid-row: span 2; align-self: start; margin-top: 2px; }
.cs-row b { font-size: 14px; }
.cs-row i { font-style: normal; font-size: 13px; color: var(--muted); }
.cs-row.here { background: var(--soft); }
.cs .cs-more { margin: 12px 0 0; }
.cs .cs-more a { color: inherit; }

.filter-input { width: 100%; padding: 9px 12px; margin-bottom: 6px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--panel); color: inherit; font: inherit; font-size: 13px; }
.filter-input:focus { outline: none; border-color: var(--ink); }
@media (max-width: 860px) { .filter-input, select.sort { font-size: 16px; } }
.side h4 .hint { text-transform: none; letter-spacing: 0; font-weight: 500; margin-left: 6px; }

.ph { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 14px; text-align: center;
  background: repeating-linear-gradient(135deg, var(--chip) 0 10px, color-mix(in srgb, var(--chip) 85%, var(--ink)) 10px 20px); color: var(--muted); }
.ph .pn { font-weight: 800; color: var(--ink); font-size: 14px; line-height: 1.2; }
.ph .ps { font-size: 11px; }
.detail .hero .ph { position: relative; aspect-ratio: 245 / 342; width: 100%; max-width: 400px; border-radius: 14px; }

.chip.ghost { background: transparent; border-color: var(--line); color: var(--muted); }
label.chip { cursor: pointer; }
.chip.col { background: color-mix(in srgb, var(--cc) 16%, transparent); color: color-mix(in srgb, var(--cc) 75%, var(--ink)); }
.chip.col.on { background: var(--cc); color: var(--cct, #fff); }
.col-colors { display: inline-flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.col-colors .chip { min-height: 30px; padding: 4px 8px; }
.col-colors .chip.on { border-color: var(--ink); background: transparent; }
.col-colors input[type=color] { width: 22px; height: 18px; padding: 0; border: 0; background: none; margin-left: 4px; }
.chip.col:hover { border-color: var(--cc); }
.chip.col.hid { opacity: .6; border-style: dashed; border-color: var(--cc); }
.cm { display: block; font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.admin { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; border: 1.5px dashed var(--line); font-size: 13px; color: var(--muted); }
.admin a { color: var(--ink); font-weight: 600; text-decoration: none; border-bottom: 1.5px solid var(--line); }
.admin .col-add { display: flex; gap: 6px; flex-wrap: wrap; width: 100%; }
.admin .col-add .chip { min-height: 28px; padding: 4px 10px; font-size: 12px; }
.link { color: inherit; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }
.link:hover { text-decoration-color: var(--ink); }
.h { margin: 6px 0 0; font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.chip.dim, .set.dim { opacity: .45; }
.chip.dim.on, .set.dim.on { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); z-index: 60; max-width: min(92vw, 520px); padding: 10px 16px; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 14px; box-shadow: 0 10px 30px -10px rgba(0,0,0,.5); opacity: 0; pointer-events: none; transition: opacity .2s, transform .25s cubic-bezier(.2,.8,.2,1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.nudge { white-space: normal; border-radius: 16px; text-align: center; }
.toast.nudge.show { pointer-events: auto; }
.nudge a { color: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 2px; margin-left: 4px; }
.toast .cond { vertical-align: 0; }

@media (max-width: 720px) {
  .detail { padding: 8px; }
  .detail-in { border-radius: 18px; max-height: calc(100dvh - 16px); }
  .detail .info { padding: 18px 18px calc(22px + env(safe-area-inset-bottom)); }
  .detail .hero { min-height: 0; padding: 16px; }
  .detail h2, .detail .card-h { font-size: 24px; }
  .detail .hero .tilt { max-width: clamp(220px, calc((100svh - 288px) * 245 / 342), 400px); }
  .nav { width: 40px; height: 40px; top: calc(50svh - 120px); }
}

.detail .fine { font-size: 12.5px; color: var(--muted); margin: 10px 2px 0; }
.detail .fine a { color: inherit; }
.site-foot { max-width: 1760px; margin: 24px auto 0; padding: 20px 24px calc(28px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.site-foot nav { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-bottom: 10px; }
.site-foot nav a { color: var(--ink); font-weight: 650; text-decoration: none; }
.site-foot nav a:hover { text-decoration: underline; }
.site-foot p { margin: 4px 0; }
.site-foot a { color: inherit; }
.news { scroll-margin-top: 84px; box-sizing: border-box; max-width: 640px; margin: 32px auto 0; padding: 20px 22px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.doc .news { margin: 18px 0 8px; }
@media (max-width: 680px) { .news { margin: 28px 16px 0; padding: 18px 16px; } .doc .news { margin: 18px 0 8px; } }
.news h2, .doc .news h2 { margin: 0 0 6px; font-size: 18px; }
.news > p { margin: 0 0 12px; color: var(--muted); line-height: 1.5; }
.news-tick { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; line-height: 1.45; margin: 0 0 12px; cursor: pointer; }
.news-tick input { width: 18px; height: 18px; margin: 1px 0 0; flex: none; accent-color: var(--ink); }
.news-row { display: flex; gap: 8px; }
.news-row input { flex: 1; min-width: 0; padding: 11px 12px; font: inherit; font-size: 16px; color: var(--ink); background: var(--bg); border: 1.5px solid var(--line); border-radius: 10px; }
.news-row input:focus { outline: none; border-color: var(--ink); }
.news button[type=submit] { flex: none; padding: 11px 18px; border-radius: 999px; background: var(--ink); color: var(--bg); font: inherit; font-weight: 700; cursor: pointer; }
.news button[type=submit]:disabled { opacity: .6; cursor: default; }
.news-msg { margin: 10px 0 0; font-size: 14px; line-height: 1.45; }
.news-msg:empty { display: none; }
.news-msg.bad { color: var(--danger); }
.news-form.sent .news-tick, .news-form.sent .news-row { display: none; }
.news-confirm { margin: 18px 0 8px; }
.news-go { padding: 12px 22px; border-radius: 999px; background: var(--ink); color: var(--bg); font: inherit; font-weight: 700; cursor: pointer; }
.top .spacer { flex: 1; }
.help-btn { anchor-name: --help; }
.help-btn:has(+ .help-pop:popover-open) { border-color: var(--ink); }
.help-pop { position: fixed; inset: auto; top: calc(var(--top-h) - 6px); right: 16px; margin: 0; width: max-content; min-width: 230px; max-width: calc(100vw - 24px); max-height: calc(100dvh - var(--top-h) - 16px); overflow: auto;
  padding: 6px; background: var(--panel); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 12px 32px -8px rgba(0,0,0,.25); font-size: 15px; }
@supports (anchor-name: --a) { .help-pop { position-anchor: --help; top: anchor(bottom); right: anchor(right); margin-top: 8px; } }
@media (max-width: 480px) { .help-pop { right: 12px; } }
.help-pop a, .help-pop button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px; border-radius: 10px; color: inherit; text-decoration: none; font: inherit; font-weight: 550; text-align: left; }
.help-pop a:hover, .help-pop button:hover, .help-pop :focus-visible { background: var(--chip); }
.help-pop svg { width: 18px; height: 18px; stroke-width: 1.7; color: var(--muted); flex: none; }
.help-pop nav { margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--line); }
.help-theme { display: flex; align-items: center; gap: 10px; padding: 4px 4px 4px 12px; font-weight: 550; }
.help-theme > span:first-of-type { flex: 1; margin-right: 8px; }
.help-seg { display: inline-flex; gap: 2px; padding: 2px; border-radius: 999px; background: var(--chip); }
.help-pop .help-seg button { width: 36px; height: 32px; padding: 0; justify-content: center; border-radius: 999px; color: var(--muted); }
.help-pop .help-seg button:hover { background: none; color: var(--ink); }
.help-pop .help-seg button[aria-checked="true"] { background: var(--panel); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.15); }
.help-pop .help-seg svg { width: 17px; height: 17px; color: inherit; }
@media (prefers-reduced-motion: no-preference) {
  .help-pop { transition: opacity .15s, translate .15s, display .15s allow-discrete, overlay .15s allow-discrete; }
  .help-pop:not(:popover-open) { opacity: 0; translate: 0 -4px; }
  @starting-style { .help-pop:popover-open { opacity: 0; translate: 0 -4px; } }
}
.doc { max-width: 74ch; margin: 0 auto; padding: 28px 24px 8px; }
.doc h1 { font-size: 30px; letter-spacing: -.02em; line-height: 1.15; margin: 6px 0 6px; }
.doc .updated { color: var(--muted); margin: 0 0 22px; }
.doc h2 { font-size: 18px; margin: 30px 0 8px; }
.doc p, .doc li { line-height: 1.6; }
.doc ol, .doc ul { padding-left: 22px; }
.doc li + li { margin-top: 4px; }
.doc a { color: inherit; }
.doc .table { overflow-x: auto; margin: 10px 0; }
.doc table { border-collapse: collapse; width: 100%; font-size: 14px; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 9px 10px; border-bottom: 1px solid var(--line); }
.doc th { font-weight: 700; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.doc .box { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 20px; margin: 12px 0; }
.doc .box p { margin: 6px 0; }
.doc dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; margin: 10px 0; }
.doc dt { color: var(--muted); }
.doc dd { margin: 0; }
@media (max-width: 560px) { .doc dl { grid-template-columns: 1fr; gap: 0; } .doc dd { margin-bottom: 8px; } .doc h1 { font-size: 26px; } }
.wish { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 10px 0 4px; font-size: 13px; }
.wish:empty { display: none; }
.wish-h { color: var(--muted); }
.wish-f.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.wish-f.ready { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 30%, transparent); }


.fly-star, .spark { position: fixed; left: 0; top: 0; width: 26px; height: 26px; z-index: 95; pointer-events: none; }
.spark { width: 12px; height: 12px; }
.fly-star svg, .spark svg { display: block; width: 100%; height: 100%; }
.cart-ghost { position: fixed; z-index: 94; margin: 0; pointer-events: none; }
.badge.pop { animation: none; }
.badge.land { animation: pop .45s cubic-bezier(.2,1.4,.4,1); }
.icon-btn.land { animation: jig .42s cubic-bezier(.2,1.4,.4,1); }
@keyframes jig { 30% { transform: scale(1.12) rotate(-8deg); } 65% { transform: scale(.97) rotate(4deg); } }

@property --mx { syntax: '<percentage>'; inherits: true; initial-value: 50%; }
@property --my { syntax: '<percentage>'; inherits: true; initial-value: 50%; }
@property --g { syntax: '<number>'; inherits: true; initial-value: 0; }
.detail .hero .holo { display: block; }
.detail .hero .tilt.touching { transition: transform .12s ease-out; }
.detail .hero .tilt.drag { transition: none; }
.detail .hero .tilt.touching .holo { opacity: calc(var(--g) * var(--k) * 1.2); }
.detail .hero.sweep { animation: foil-sweep 1.5s ease-in-out .25s both; }
.tilt-ask { position: absolute; left: 50%; bottom: 6px; translate: -50% 0; z-index: 2; padding: 6px 12px; border-radius: 999px; background: rgba(12,12,13,.74); color: #fff; font-size: 12px; font-weight: 650; white-space: nowrap; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
@keyframes foil-sweep { 0% { --mx: -15%; --my: -10%; --g: 0; } 25%, 70% { --g: 1; } 100% { --mx: 115%; --my: 110%; --g: 0; } }

.dx-tile.pop img { animation: dexpop .55s cubic-bezier(.2,1.5,.4,1); }
.dx-tile.pop { animation: dexring .6s ease-out; }
.dx-tile.unpop img { animation: dexunpop .35s ease; }
@keyframes dexpop { 0% { transform: scale(.6); filter: grayscale(1); opacity: .5; } 55% { transform: scale(1.28); filter: none; opacity: 1; } 100% { transform: none; } }
@keyframes dexring { from { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent), inset 0 0 0 1px var(--ink); } to { box-shadow: 0 0 0 12px transparent, inset 0 0 0 1px var(--ink); } }
@keyframes dexunpop { 0% { filter: none; opacity: 1; } 45% { transform: scale(.85); } 100% { transform: none; } }

.confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 96; pointer-events: none; }

.empty-art { display: block; width: 120px; height: 120px; margin: 0 auto 6px; }
.empty-art .ea-shadow { fill: currentColor; opacity: .12; transform-origin: 60px 110px; animation: ea-shadow 2.8s ease-in-out infinite; }
.empty-art .ea-card { transform-origin: 60px 104px; animation: ea-sway 2.8s ease-in-out infinite; }
.empty-art .ea-eyes { transform-origin: 60px 58px; animation: ea-blink 3.4s infinite, ea-look 5.6s ease-in-out infinite; }
@keyframes ea-sway { 0%, 100% { transform: rotate(-7deg); } 50% { transform: rotate(7deg); } }
@keyframes ea-shadow { 0%, 100% { transform: scaleX(.9) translateX(-3px); } 50% { transform: scaleX(.9) translateX(3px); } }
@keyframes ea-blink { 0%, 90%, 100% { scale: 1 1; } 94% { scale: 1 .1; } }
@keyframes ea-look { 0%, 35%, 100% { translate: 0 0; } 45%, 60% { translate: -2.5px 0; } 70%, 85% { translate: 2.5px 0; } }
.empty .empty-all { margin-top: 16px; }

.card.sk { animation: none; pointer-events: none; box-shadow: none; }
.sk .pic, .sk i { --sk: color-mix(in srgb, var(--chip) 82%, var(--muted)); background: linear-gradient(100deg, var(--sk) 40%, color-mix(in srgb, var(--sk) 40%, var(--panel)) 50%, var(--sk) 60%) var(--sk); background-size: 300% 100%; animation: shimmer 1.3s linear infinite; }
.sk i { display: block; height: 11px; border-radius: 6px; }
.sk i:nth-child(1) { width: 78%; height: 13px; } .sk i:nth-child(2) { width: 56%; } .sk i:nth-child(3) { width: 34%; height: 16px; margin-top: 6px; }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: 0 0; } }
.grid { transition: opacity .2s; }
.grid.loading:not(:has(.sk)) { opacity: .5; transition: opacity .2s .15s; }

.cart { transition-duration: .5s; transition-timing-function: cubic-bezier(.3,1.25,.45,1); box-shadow: -10px 0 40px -20px rgba(0,0,0,.4), 80px 0 0 var(--panel); }
@media (max-width: 860px) { .side { transition: transform .5s cubic-bezier(.3,1.25,.45,1); box-shadow: -80px 0 0 var(--bg); } }
.detail-in { animation: enter-spring .5s cubic-bezier(.3,1.35,.5,1) both; }
.detail-in.still { animation: none; }
@keyframes enter-spring { from { opacity: 0; transform: translateY(26px) scale(.93); } 40% { opacity: 1; } }
.toast { transition: opacity .2s, transform .45s cubic-bezier(.3,1.6,.5,1); }

.doc [data-mike], .facts [data-mike] { background: linear-gradient(transparent 60%, color-mix(in srgb, var(--star) 45%, transparent) 60%); }

.more ~ .facts { margin: 32px 0 8px; padding-top: 16px; border-top: 1px solid var(--line); max-width: 70ch; }
.more ~ .facts h2 { margin: 0 0 6px; font-size: 15px; }
.more ~ .facts p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }

.intro-title { margin: 0 0 4px; font-size: 22px; letter-spacing: -.01em; line-height: 1.2; }
.intro { margin: 0 0 12px; color: var(--muted); font-size: 14px; line-height: 1.45; max-width: 70ch; }

.wrap > main { min-width: 0; }
.banners { position: relative; margin: 0 0 14px; container-type: inline-size; }
.banners-row { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 24px) / 3); gap: 12px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; }
.banners-row::-webkit-scrollbar { display: none; }
.banner { display: block; aspect-ratio: 2 / 1; border-radius: 12px; overflow: hidden; scroll-snap-align: start; background: var(--chip); }
.banner img { display: block; width: 100%; height: 100%; object-fit: cover; }
.banner-ph { display: grid; place-items: center; border: 1.5px dashed var(--line); background: var(--panel); color: var(--muted); font-size: 12px; text-align: center; }
.banner-ph b { display: block; color: var(--ink); font-size: 15px; margin-bottom: 2px; }
@container (max-width: 899px) { .banners-row { grid-auto-columns: calc((100% - 12px) / 2); } }
@container (max-width: 559px) { .banners-row { grid-auto-columns: 86%; margin-inline: -16px; padding-inline: 16px; scroll-padding-inline: 16px; } }
.banners-go { position: absolute; top: 50%; translate: 0 -50%; width: 36px; height: 36px; border-radius: 50%; background: var(--panel); color: var(--ink); border: 1.5px solid var(--line); box-shadow: var(--shadow); font-size: 22px; line-height: 1; display: grid; place-items: center; padding: 0 0 3px; }
.banners-go.prev { left: -12px; } .banners-go.next { right: -12px; }
.banners-go[hidden] { display: none; }
@media (hover: none) { .banners-go { display: none; } }

.card a.pic { display: block; color: inherit; }
a.chip.species { color: inherit; text-decoration: none; }
.card a.name { color: inherit; text-decoration: none; }
.card a.name:hover { text-decoration: underline; text-underline-offset: 2px; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; margin: 0 0 10px; font-size: 13px; color: var(--muted); }
.crumbs a { color: inherit; text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 2px; }
.crumbs [aria-current] { color: var(--ink); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.crumbs .sep { opacity: .55; }
.hub { margin: 0 0 14px; }
.hub[hidden] { display: none; }
.hub h1 { margin: 0 0 4px; font-size: 26px; letter-spacing: -.01em; line-height: 1.2; }
.hub-facts { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.45; max-width: 70ch; }
.hub-logo { display: block; width: auto; height: auto; max-width: min(240px, 70%); max-height: 120px; object-fit: contain; margin: 2px 0 12px; }
.hub-sprite { display: block; width: 96px; height: 96px; image-rendering: pixelated; margin: -10px 0 -4px -10px; }
.detail .info .crumbs { font-size: 12px; margin: 0; }
.more-row { margin-top: 6px; }
.more-cards { display: grid; grid-auto-flow: column; grid-auto-columns: 30%; gap: 10px; overflow-x: auto; overscroll-behavior-x: contain; padding-bottom: 4px; scrollbar-width: thin; }
@media (min-width: 861px) { .more-cards { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); overflow: visible; } }
.more-card { display: flex; flex-direction: column; gap: 2px; min-width: 0; color: inherit; text-decoration: none; font-size: 12px; line-height: 1.3; }
.more-card img, .more-card .ph { width: 100%; aspect-ratio: 245 / 342; object-fit: cover; border-radius: 6px; background: var(--chip); margin-bottom: 4px; }
.more-card .ph { display: flex; flex-direction: column; justify-content: center; padding: 6px; font-size: 11px; }
.more-card .mc-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.more-card .mc-set { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.more-card .mc-price { font-weight: 700; }
.more-card:hover .mc-name { text-decoration: underline; text-underline-offset: 2px; }
.doc:has(.sets-page) { max-width: 1120px; }
.sets-page .series h2 { margin: 26px 0 10px; font-size: 17px; }
.set-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.set-tile { display: flex; flex-direction: column; gap: 3px; padding: 12px 12px 11px; border-radius: var(--radius); background: var(--panel); box-shadow: var(--shadow);
  border: 1.5px solid transparent; color: inherit; text-decoration: none; transition: border-color .15s; }
.set-tile:hover { border-color: var(--line); }
.st-logo { display: flex; align-items: center; justify-content: center; height: 64px; margin-bottom: 6px; }
.st-logo img { max-width: 100%; max-height: 64px; object-fit: contain; }
.st-logo b { font-size: 15px; text-align: center; line-height: 1.2; }
.st-name { font-weight: 700; font-size: 14px; line-height: 1.25; }
.st-meta { color: var(--muted); font-size: 12px; }
@media (max-width: 560px) { .set-tiles { gap: 10px; } .set-tile { padding: 10px; } .st-logo { height: 52px; } .st-logo img { max-height: 52px; } }

.card .pic .cam { position: absolute; right: 8px; bottom: 8px; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 999px; background: rgba(12,12,13,.72); color: #fff; pointer-events: none; }
.card .pic .cam svg { width: 15px; height: 15px; }
.photo-btn { display: inline-flex; align-items: center; gap: 4px; margin-left: 4px; padding: 3px 9px; border: 1.5px solid var(--line); border-radius: 999px; font-size: 12px; font-weight: 650; color: var(--ink); background: var(--panel); vertical-align: middle; }
.photo-btn svg { width: 14px; height: 14px; }
.photo-btn[aria-pressed="true"] { background: var(--chip-on); border-color: var(--chip-on); color: var(--bg); }
.detail .hero.ours .holo { display: none; }
.detail .hero.ours .tilt img { aspect-ratio: auto; object-fit: contain; }
.ours-bar { position: relative; z-index: 1; margin-top: 14px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; max-width: 400px; }
.ours-say { width: 100%; margin: 0; text-align: center; font-size: 13px; font-weight: 700; }
.ours-sides { display: inline-flex; border: 1.5px solid var(--line); border-radius: 999px; overflow: hidden; background: var(--panel); }
.ours-sides button, .ours-off { padding: 7px 13px; font-size: 12.5px; font-weight: 650; background: var(--panel); }
.ours-sides button[aria-pressed="true"] { background: var(--chip-on); color: var(--bg); }
.ours-off { border: 1.5px solid var(--line); border-radius: 999px; }
