.pokemon-cards-main { width: min(2360px, 94%); margin: auto; padding: 24px 0 60px; }
.dex-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; padding-bottom: 24px; }
.dex-heading h1, .pokemon-profile h1 { margin: 0; }
.dex-search { width: min(100%, 460px); min-height: 46px; }
.dex-types, .dex-tile-types { display: flex; flex-wrap: wrap; gap: 7px; }
.dex-rankings { width: fit-content; max-width: 100%; flex-wrap: wrap; gap: 3px; margin: 0 0 14px; background: #111929d9; }
.dex-rankings button { min-height: 34px; color: #bfc9dd; }
.dex-rankings button.selected { color: #dfd6ff; background: #2d2544; }
.dex-rankings button:disabled { cursor: default; }
.dex-ranking-note { margin: 15px 0 0; color: #a8b7c9; font-size: 12px; line-height: 1.5; }
.dex-type { border: 1px solid color-mix(in srgb, var(--type, #b4a1d7) 46%, transparent); border-radius: 999px; background: #0e1522cf; padding: 6px 11px; font-size: 11px; }
.dex-type[aria-pressed="true"], .dex-type:hover { background: color-mix(in srgb, var(--type, #b4a1d7) 28%, #0e1522); border-color: var(--type, #b4a1d7); }
.dex-filters { display: flex; flex-wrap: wrap; align-items: end; gap: 9px 12px; margin-top: 15px; }
.dex-filters label { display: grid; gap: 5px; width: 170px; min-width: 0; color: #a8b7c9; font-size: 11px; }
.dex-filters select { width: 100%; min-width: 0; min-height: 36px; background-color: #111929e8; }
.dex-filters select:disabled { opacity: .72; }
.dex-clear { min-height: 36px; border: 1px solid #a89ad14f; border-radius: 7px; background: #111929c7; color: #d3c4f6; padding: 6px 12px; font-size: 11px; }
.dex-clear:not(:disabled):hover { background: #2d2544; border-color: #b4a1d7; }
.dex-clear:disabled { opacity: .48; cursor: default; }
.dex-search-match { color: #cdbef3; font-size: 10px; text-align: center; line-height: 1.4; }
@media (max-width: 560px) {
  .dex-filters { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
  .dex-filters label { width: auto; }
  .dex-clear { justify-self: start; }
}
.dex-count { color: #a8b7c9; font-size: 12px; margin: 20px 0; }
.dex-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(147px, 1fr)); gap: 12px; }
.dex-tile { display: flex; flex-direction: column; align-items: center; gap: 7px; position: relative; min-width: 0; padding: 12px 8px 16px; border: 1px solid #8792ae31; border-radius: 12px; background: radial-gradient(ellipse at 50% 37%, color-mix(in srgb, var(--type) 25%, transparent), transparent 69%), #101727a6; }
.dex-tile img { width: min(100%, 138px); height: auto; aspect-ratio: 1; object-fit: contain; filter: drop-shadow(0 8px 10px #0007); transition: transform 150ms ease-out; }
.dex-tile strong { font: 700 14px/1.25 Manrope, system-ui; text-align: center; overflow-wrap: anywhere; }
.dex-id { color: #afbbcd; font: 10px/1 system-ui; align-self: flex-start; }
.dex-tile-types { justify-content: center; gap: 4px; }
.dex-badge { border-radius: 20px; border: 1px solid color-mix(in srgb, var(--type) 55%, transparent); background: color-mix(in srgb, var(--type) 24%, #101729); padding: 3px 7px; font-size: 9px; }
.dex-tile:focus-visible { border-color: var(--type); }
@media (min-width:1800px) and (min-aspect-ratio:2/1) {
  .pokemon-cards-main { width:min(3500px,94%); }
  .pokemon-cards-main .dex-grid { grid-template-columns:repeat(auto-fill,minmax(clamp(165px,6vw,214px),1fr)); gap:15px; }
  .pokemon-cards-main .dex-chase-grid { grid-template-columns:repeat(auto-fill,minmax(clamp(178px,6.6vw,236px),1fr)); }
  .dex-tile:not(.dex-chase-tile) img { width:min(100%,clamp(138px,5vw,174px)); }
  .dex-heading .dex-search { width:min(100%,560px); }
}
.dex-ranking-price { font: 700 15px/1.25 Manrope,system-ui; color: var(--mint); margin-top: 2px; text-align: center; }
.dex-quote-detail { font-size: 10px; line-height: 1.4; color: #a8b7c9; text-align: center; }
.dex-chase-grid { grid-template-columns: repeat(auto-fill, minmax(176px,1fr)); }
.dex-chase-tile { padding: 10px 10px 12px; }
.dex-chase-card { display: grid; justify-items: center; text-align: center; gap: 6px; width: 100%; }
.dex-chase-card small { color: #a8b7c9; font-size: 10px; overflow-wrap: anywhere; }
.dex-chase-art { width: min(100%,155px); aspect-ratio: .716; display: grid; place-items: center; margin: 0 0 4px; }
.dex-chase-art img { width: 100%; height: 100%; aspect-ratio: auto; }
.dex-chase-art > span { font-size: 10px; color: #a8b7c9; }
.dex-species-link { margin-top: auto; padding-top: 7px; font-size: 11px; color: #c4b5ef; text-align: center; }
.dex-species-link:hover { text-decoration: underline; }
@media (hover:hover) { .dex-tile:hover { border-color: var(--type); box-shadow: 0 0 19px color-mix(in srgb, var(--type) 30%, transparent); } .dex-tile:hover img { transform: scale(1.07); } }
.pokemon-profile { display: flex; gap: clamp(14px, 4vw, 58px); align-items: center; padding: 14px clamp(14px, 3vw, 52px); margin: 15px 0 22px; border-radius: 14px; background: radial-gradient(ellipse at 12% 45%, color-mix(in srgb, var(--type) 25%, transparent), transparent 66%), #1017278c; border: 1px solid #8792ae31; }
.pokemon-profile img { width: clamp(85px, 13vw, 170px); height: auto; aspect-ratio: 1; object-fit: contain; }
.pokemon-profile h1 { overflow-wrap: anywhere; }
.pokemon-profile .dex-tile-types { justify-content: flex-start; margin-top: 13px; }
.dex-back, .pokemon-cards-main footer a { color: #c4b5ef; }
.pokemon-card-tools { display: flex; flex-wrap: wrap; gap: 9px; }
.pokemon-card-tools .searchbox { flex: 1 1 230px; }
.pokemon-card-tools select { flex: 0 1 auto; width: min(225px, 100%); }
.pokemon-cards-main .card-rarity { overflow-wrap: anywhere; }
@media (max-width: 520px) { .pokemon-cards-main { width: calc(100% - 28px); } .dex-heading { gap: 14px; } .dex-grid { grid-template-columns: repeat(auto-fill, minmax(108px, 1fr)); gap: 8px; } .pokemon-card-tools select { flex: 1 1 130px; min-width: 0; } }
@media (max-width: 520px) { .dex-chase-grid { grid-template-columns: repeat(auto-fill,minmax(135px,1fr)); } }
@media (prefers-reduced-motion:reduce) { .dex-tile img { transition: none; } }

.card-pull-badge{display:block;color:#d3b9f4;font-size:10px;line-height:1.4;margin:-5px 0 9px}
.profile-dex-link{display:inline-block;margin-top:10px;color:#c8adf6;font-size:12px}
.profile-dex-link:hover{text-decoration:underline}
