.pokedex-page {
  --pd-text: var(--text, #292d35);
  --pd-muted: var(--muted, #7d8490);
  --pd-card: var(--card, #fff);
  --pd-soft: var(--card-soft, #f5f6f8);
  --pd-border: var(--border, #e4e7ec);
  --pd-shadow: var(--shadow, 0 8px 24px rgba(30, 36, 46, .06));
  --pd-accent: #c33f49;
  padding: 24px 0 56px;
  color: var(--pd-text);
}
.pokedex-page *, .pokedex-page *::before, .pokedex-page *::after { box-sizing: border-box; }
.pokedex-page .eyebrow { display: block; color: var(--pd-accent); font-size: 11px; font-weight: 800; letter-spacing: 0; }
.pokedex-intro { display: flex; align-items: end; justify-content: space-between; gap: 24px; padding: 12px 0 20px; border-bottom: 1px solid var(--pd-border); }
.pokedex-intro h1 { margin: 3px 0 0; font-size: 30px; line-height: 1.2; letter-spacing: 0; }
.pokedex-intro p { margin: 0 0 3px; color: var(--pd-muted); font-size: 12px; }
.pokedex-view-tabs { display: flex; gap: 24px; border-bottom: 1px solid var(--pd-border); }
.pokedex-view-tabs a { position: relative; padding: 12px 1px; color: var(--pd-muted); font-weight: 700; }
.pokedex-view-tabs a.is-active { color: var(--pd-text); }
.pokedex-view-tabs a.is-active::after { position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; background: var(--pd-accent); content: ""; }
.pokedex-module-nav { gap: 2px; overflow-x: auto; scrollbar-width: thin; }
.pokedex-module-nav a { flex: 0 0 auto; padding-right: 13px; padding-left: 13px; font-size: 12px; white-space: nowrap; }
.pokedex-module-nav a small { margin-left: 3px; padding: 1px 4px; border-radius: 3px; color: var(--pd-muted); background: var(--pd-soft); font-size: 8px; }
.pokedex-filter { display: grid; grid-template-columns: 250px minmax(260px, 1fr) 44px auto; gap: 10px; align-items: end; padding: 18px 0; }
.pokedex-filter label, .pokedex-version-fields label, .pokedex-submit-package > label:not(.pokedex-file) { display: grid; gap: 6px; min-width: 0; }
.pokedex-filter label > span, .pokedex-version-fields label > span, .pokedex-submit-package label > span { color: var(--pd-muted); font-size: 12px; font-weight: 700; }
.pokedex-filter input, .pokedex-filter select, .pokedex-version-fields input, .pokedex-version-fields textarea, .pokedex-submit-package textarea { width: 100%; min-width: 0; min-height: 44px; padding: 10px 12px; border: 1px solid var(--pd-border); border-radius: 6px; outline: 0; color: var(--pd-text); background: var(--pd-card); }
.pokedex-filter input:focus, .pokedex-filter select:focus, .pokedex-version-fields input:focus, .pokedex-version-fields textarea:focus, .pokedex-submit-package textarea:focus { border-color: var(--pd-accent); box-shadow: 0 0 0 3px rgba(195, 63, 73, .09); }
.pokedex-filter button { display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 6px; color: #fff; background: var(--pd-accent); cursor: pointer; }
.pokedex-filter button svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; }
.pokedex-filter > a { height: 44px; padding: 10px 4px; color: var(--pd-accent); }
.pokedex-filter.is-version-only { grid-template-columns: minmax(240px, 360px); }
.pokedex-browser { display: grid; grid-template-columns: 188px minmax(0, 1fr); min-width: 0; border-top: 1px solid var(--pd-border); }
.pokedex-sidebar { min-width: 0; padding: 24px 22px 0 0; border-right: 1px solid var(--pd-border); }
.pokedex-sidebar-body { position: sticky; top: 88px; }
.pokedex-sidebar-toggle { display: none; }
.pokedex-sidebar-scrim { display: none; }
.pokedex-sidebar section + section { margin-top: 28px; }
.pokedex-sidebar h2 { margin: 0 0 10px; font-size: 13px; letter-spacing: 0; }
.pokedex-sidebar nav { display: grid; gap: 3px; }
.pokedex-sidebar nav a { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 7px; min-height: 31px; padding: 5px 7px; border-radius: 4px; color: var(--pd-muted); font-size: 10px; }
.pokedex-sidebar nav a:hover { color: var(--pd-text); background: var(--pd-soft); }
.pokedex-sidebar nav a.is-active { color: #245f4e; background: #e1ece6; font-weight: 700; }
.pokedex-generation span { display: flex; min-width: 0; align-items: center; gap: 7px; }
.pokedex-generation b { display: grid; flex: 0 0 22px; place-items: center; height: 22px; border-radius: 3px; color: #557069; background: #e7efeb; font-size: 9px; }
.pokedex-generation.is-active b { color: #fff; background: #286b59; }
.pokedex-generation small, .pokedex-type-filter small { flex: 0 0 auto; color: var(--pd-muted); font-size: 8px; }
.pokedex-type-filter { grid-template-columns: 1fr 1fr; column-gap: 7px; }
.pokedex-type-filter a { justify-content: flex-start !important; }
.pokedex-type-filter a:first-child { grid-column: 1 / -1; }
.pokedex-type-filter a > i { flex: 0 0 7px; width: 7px; height: 7px; border-radius: 2px; background: #9da3aa; }
.pokedex-type-filter a > span { flex: 1 1 auto; min-width: 0; }
.pokedex-catalog { min-width: 0; padding: 25px 0 0 28px; }
.pokedex-results-head { display: flex; min-height: 76px; align-items: center; justify-content: space-between; gap: 18px; padding-bottom: 17px; }
.pokedex-results-head h2 { margin: 3px 0 0; overflow-wrap: anywhere; font-size: 26px; line-height: 1.2; letter-spacing: 0; }
.pokedex-results-head > div > p { display: flex; flex-wrap: wrap; gap: 5px; margin: 8px 0 0; }
.pokedex-results-head > div > p a { display: inline-flex; align-items: center; gap: 5px; min-height: 25px; padding: 2px 7px; border: 1px solid var(--pd-border); border-radius: 4px; color: var(--pd-muted); background: var(--pd-card); font-size: 9px; }
.pokedex-results-head > div > p a:hover { border-color: #86a99d; color: #286b59; }
.pokedex-results-head > div > p b { font-size: 13px; font-weight: 500; }
.pokedex-results-head > strong { color: var(--pd-muted); font-size: 11px; font-weight: 500; white-space: nowrap; }
.pokedex-results-head > strong b { color: #286b59; font-size: 15px; }
.pokedex-sort-row { display: flex; min-height: 42px; align-items: center; justify-content: space-between; border-top: 1px solid var(--pd-border); border-bottom: 1px solid var(--pd-border); color: var(--pd-muted); font-size: 9px; }
.pokedex-sort-row label { display: flex; align-items: center; gap: 7px; }
.pokedex-sort-row select { min-height: 32px; padding: 4px 25px 4px 8px; border: 0; outline: 0; color: var(--pd-muted); background: transparent; font-size: 10px; }
.pokedex-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 11px; padding-top: 16px; }
.pokedex-card { display: block; min-width: 0; height: 286px; overflow: hidden; border: 1px solid var(--pd-border); border-radius: 7px; color: inherit; background: var(--pd-card); transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease; }
.pokedex-card:hover { border-color: rgba(195, 63, 73, .32); box-shadow: 0 7px 18px rgba(30, 36, 46, .07); transform: translateY(-2px); }
.pokedex-card > header { display: flex; align-items: center; justify-content: space-between; height: 32px; padding: 0 10px; color: var(--pd-muted); }
.pokedex-card > header small { font-size: 9px; font-weight: 800; }
.pokedex-card > figure { position: relative; display: grid; place-items: center; width: auto; height: 153px; margin: 0 7px; overflow: hidden; border-radius: 5px; background: var(--pd-soft); }
.pokedex-card > figure::before { position: absolute; width: 82px; height: 82px; border: 1px solid var(--pd-border); border-radius: 50%; content: ""; }
.pokedex-card > figure::after { position: absolute; width: 100%; height: 1px; background: var(--pd-border); content: ""; }
.pokedex-card > figure em { position: absolute; top: 6px; right: 7px; z-index: 3; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 3px; color: var(--pd-muted); background: var(--pd-card); box-shadow: 0 1px 4px rgba(20,40,31,.08); font-size: 9px; font-style: normal; font-weight: 800; }
.pokedex-card > figure img { position: relative; z-index: 2; display: block; width: 132px; max-width: 88%; height: 132px; object-fit: contain; transition: transform .18s ease; }
.pokedex-card:hover > figure img { transform: scale(1.035); }
.pokedex-card > figure span { color: var(--pd-muted); font-weight: 800; }
.pokedex-card > div { min-width: 0; padding: 12px 11px; }
.pokedex-card h3 { overflow: hidden; margin: 0; font-size: 15px; line-height: 1.4; text-overflow: ellipsis; white-space: nowrap; letter-spacing: 0; }
.pokedex-card p { overflow: hidden; min-height: 16px; margin: 1px 0 0; color: var(--pd-muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.pokedex-types { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.pokedex-types i { --pd-type: #77746d; display: inline-flex; align-items: center; gap: 5px; min-height: 22px; padding: 2px 7px; border-radius: 4px; color: color-mix(in srgb, var(--pd-type) 78%, #17201c); background: color-mix(in srgb, var(--pd-type) 12%, white); font-size: 9px; font-style: normal; font-weight: 700; }
.pokedex-types i::before { flex: 0 0 6px; width: 6px; height: 6px; border-radius: 2px; background: var(--pd-type); content: ""; }
.pokedex-types i[data-type="normal"] { --pd-type: #77746d; } .pokedex-types i[data-type="fire"] { --pd-type: #d9573f; }
.pokedex-types i[data-type="water"] { --pd-type: #367dba; } .pokedex-types i[data-type="electric"] { --pd-type: #d5ae25; }
.pokedex-types i[data-type="grass"] { --pd-type: #4d9152; } .pokedex-types i[data-type="ice"] { --pd-type: #69b9bd; }
.pokedex-types i[data-type="fighting"] { --pd-type: #a3453f; } .pokedex-types i[data-type="poison"] { --pd-type: #8a5796; }
.pokedex-types i[data-type="ground"] { --pd-type: #b58b3d; } .pokedex-types i[data-type="flying"] { --pd-type: #7288c4; }
.pokedex-types i[data-type="psychic"] { --pd-type: #c94872; } .pokedex-types i[data-type="bug"] { --pd-type: #788f33; }
.pokedex-types i[data-type="rock"] { --pd-type: #8d7b45; } .pokedex-types i[data-type="ghost"] { --pd-type: #635985; }
.pokedex-types i[data-type="dragon"] { --pd-type: #5e52a2; } .pokedex-types i[data-type="dark"] { --pd-type: #514843; }
.pokedex-types i[data-type="steel"] { --pd-type: #6f7f87; } .pokedex-types i[data-type="fairy"] { --pd-type: #c66f9e; }
.pokedex-type-filter i[data-type="normal"] { background: #77746d; } .pokedex-type-filter i[data-type="fire"] { background: #d9573f; }
.pokedex-type-filter i[data-type="water"] { background: #367dba; } .pokedex-type-filter i[data-type="electric"] { background: #e8c848; }
.pokedex-type-filter i[data-type="grass"] { background: #4d9152; } .pokedex-type-filter i[data-type="ice"] { background: #8fd6d8; }
.pokedex-type-filter i[data-type="fighting"] { background: #a3453f; } .pokedex-type-filter i[data-type="poison"] { background: #8a5796; }
.pokedex-type-filter i[data-type="ground"] { background: #cba85a; } .pokedex-type-filter i[data-type="flying"] { background: #7288c4; }
.pokedex-type-filter i[data-type="psychic"] { background: #c94872; } .pokedex-type-filter i[data-type="bug"] { background: #788f33; }
.pokedex-type-filter i[data-type="rock"] { background: #8d7b45; } .pokedex-type-filter i[data-type="ghost"] { background: #635985; }
.pokedex-type-filter i[data-type="dragon"] { background: #5e52a2; } .pokedex-type-filter i[data-type="dark"] { background: #514843; }
.pokedex-type-filter i[data-type="steel"] { background: #6f7f87; } .pokedex-type-filter i[data-type="fairy"] { background: #c66f9e; }
.pokedex-tool, .pokedex-resource-view { min-height: 420px; padding: 30px 0 20px; }
.pokedex-tool-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 24px; padding-bottom: 20px; border-bottom: 1px solid var(--pd-border); }
.pokedex-tool-heading h2 { margin: 3px 0 0; font-size: 26px; letter-spacing: 0; }
.pokedex-tool-heading p { margin: 5px 0 0; color: var(--pd-muted); font-size: 11px; }
.pokedex-tool-heading > strong { color: #286b59; font-size: 15px; }
.pokedex-tool-actions { display: flex; flex-wrap: wrap; gap: 7px; justify-content: flex-end; }
.pokedex-tool-actions button, .pokedex-tool-actions label { display: inline-flex; align-items: center; min-height: 34px; padding: 6px 10px; border: 1px solid var(--pd-border); border-radius: 5px; color: var(--pd-text); background: var(--pd-card); font-size: 10px; cursor: pointer; }
.pokedex-tool-actions input { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.pokedex-resource-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.pokedex-resource-filters a { padding: 5px 9px; border: 1px solid var(--pd-border); border-radius: 4px; color: var(--pd-muted); background: var(--pd-card); font-size: 10px; }
.pokedex-resource-filters a.is-active { border-color: #8aafa2; color: #245f4e; background: #e6f0eb; font-weight: 700; }
.pokedex-resource-filters small { margin-left: 3px; }
.pokedex-resource-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
.pokedex-resource-card { position: relative; min-width: 0; min-height: 190px; padding: 16px; border: 1px solid var(--pd-border); border-radius: 6px; background: var(--pd-card); }
.pokedex-resource-card > img { float: right; width: 58px; height: 58px; margin: 0 0 8px 10px; object-fit: contain; }
.pokedex-resource-card > header { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--pd-muted); font-size: 8px; }
.pokedex-resource-card > header span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pokedex-resource-card > header i { padding: 2px 5px; border-radius: 3px; color: var(--pd-muted); background: var(--pd-soft); font-style: normal; }
.pokedex-resource-card h3 { margin: 10px 0 1px; font-size: 16px; letter-spacing: 0; }
.pokedex-resource-card > p { overflow: hidden; margin: 0 0 10px; color: var(--pd-muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.pokedex-resource-card > small { display: inline-block; margin-bottom: 8px; padding: 2px 5px; border-radius: 3px; color: #245f4e; background: #e6f0eb; font-size: 8px; }
.pokedex-resource-card dl { display: grid; grid-template-columns: repeat(3,1fr); margin: 8px 0; border: 1px solid var(--pd-border); border-radius: 4px; }
.pokedex-resource-card dl div { padding: 6px 8px; text-align: center; }
.pokedex-resource-card dl div + div { border-left: 1px solid var(--pd-border); }
.pokedex-resource-card dt { color: var(--pd-muted); font-size: 8px; }.pokedex-resource-card dd { margin: 2px 0 0; font-size: 11px; font-weight: 800; }
.pokedex-resource-description { display: -webkit-box; overflow: hidden; color: var(--pd-muted); font-size: 10px; line-height: 1.65; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.pokedex-compare-selects { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 10px; margin-bottom: 18px; }
.pokedex-compare-selects label, .pokedex-team-grid label, .pokedex-damage-grid label { display: grid; gap: 5px; min-width: 0; }
.pokedex-compare-selects span, .pokedex-team-grid label span, .pokedex-damage-grid label span { color: var(--pd-muted); font-size: 9px; font-weight: 700; }
.pokedex-compare-selects select, .pokedex-team-grid select, .pokedex-damage-grid select, .pokedex-damage-grid input { width: 100%; min-width: 0; height: 38px; padding: 7px 9px; border: 1px solid var(--pd-border); border-radius: 5px; outline: 0; color: var(--pd-text); background: var(--pd-card); }
.pokedex-compare-output { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 10px; }
.pokedex-compare-output article { padding: 15px; border: 1px solid var(--pd-border); border-radius: 6px; background: var(--pd-card); }
.pokedex-compare-output figure { display: grid; place-items: center; height: 130px; margin: 0 0 12px; background: var(--pd-soft); }
.pokedex-compare-output img { width: 120px; height: 120px; object-fit: contain; }
.pokedex-compare-output h3 { margin: 0 0 12px; font-size: 16px; }
.pokedex-compare-stat { display: grid; grid-template-columns: 42px 30px 1fr; gap: 7px; align-items: center; margin: 7px 0; font-size: 9px; }
.pokedex-compare-stat i { height: 6px; overflow: hidden; border-radius: 2px; background: var(--pd-soft); }.pokedex-compare-stat i b { display: block; height: 100%; background: #286b59; }
.pokedex-team-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pokedex-team-grid > article { padding: 15px; border: 1px solid var(--pd-border); border-radius: 6px; background: var(--pd-card); }
.pokedex-team-grid > article > header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.pokedex-team-grid > article > header button { display: grid; place-items: center; width: 27px; height: 27px; border: 0; border-radius: 4px; background: var(--pd-soft); }
.pokedex-team-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 9px; }
.pokedex-team-moves { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 9px; }
.pokedex-tool-result { display: block; min-height: 24px; margin-top: 10px; color: #286b59; font-size: 11px; }
.pokedex-damage-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }
.pokedex-damage-grid > section { display: grid; gap: 10px; align-content: start; padding: 17px; border: 1px solid var(--pd-border); border-radius: 6px; background: var(--pd-card); }
.pokedex-damage-grid h3 { margin: 0 0 3px; font-size: 15px; }
.pokedex-damage-fields { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 8px; }
.pokedex-damage-check { display: flex !important; grid-template-columns: none !important; align-items: center; min-height: 38px; }
.pokedex-damage-check input { width: 16px; height: 16px; margin: 0; }
.pokedex-damage-grid > section > small { color: var(--pd-muted); font-size: 9px; line-height: 1.55; }
.pokedex-damage-grid button { height: 38px; border: 0; border-radius: 5px; color: #fff; background: #286b59; font-weight: 700; }
.pokedex-damage-result { display: block; min-height: 96px; margin-top: 14px; padding: 18px; border: 1px solid var(--pd-border); border-radius: 6px; color: var(--pd-muted); background: var(--pd-card); white-space: pre-wrap; }
.pokedex-detail-backdrop { position: fixed; inset: 0; z-index: 100001; background: rgba(18, 27, 23, .42); animation: pokedex-fade-in .18s ease-out; }
.pokedex-detail { position: fixed; inset: 0 0 0 auto; z-index: 100002; display: block; width: min(560px, 100%); height: 100dvh; overflow-x: hidden; overflow-y: auto; border-left: 1px solid var(--pd-border); background: var(--pd-card); box-shadow: -12px 0 40px rgba(15, 31, 24, .18); animation: pokedex-slide-in .24s ease-out; }
.pokedex-detail-close { position: absolute; top: 13px; right: 17px; z-index: 4; display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--pd-border); border-radius: 5px; font-size: 22px; line-height: 1; background: var(--pd-card); }
.pokedex-detail-close:hover { background: var(--pd-soft); }
.pokedex-detail-identity { display: grid; grid-template-columns: 190px minmax(0, 1fr); align-items: center; gap: 22px; min-height: 250px; padding: 42px 28px 24px; border-bottom: 1px solid var(--pd-border); background: var(--pd-card); }
.pokedex-detail-identity figure { position: relative; display: grid; place-items: center; height: 190px; margin: 0; overflow: hidden; border-radius: 6px; background: var(--pd-soft); }
.pokedex-detail-identity figure::before { position: absolute; width: 120px; height: 120px; border: 1px solid var(--pd-border); border-radius: 50%; content: ""; }
.pokedex-detail-identity figure::after { position: absolute; width: 100%; height: 1px; background: var(--pd-border); content: ""; }
.pokedex-detail-identity figure img { position: relative; z-index: 2; width: 176px; height: 176px; object-fit: contain; }
.pokedex-detail-identity figure span { color: var(--pd-muted); font-size: 28px; font-weight: 800; }
.pokedex-detail-identity > div > span { color: var(--pd-accent); font-size: 11px; font-weight: 800; }
.pokedex-detail-identity h2 { margin: 5px 0; font-size: 27px; line-height: 1.15; letter-spacing: 0; }
.pokedex-detail-identity p, .pokedex-profile > p { margin: 0; color: var(--pd-muted); }
.pokedex-detail-body { display: grid; grid-template-columns: 1fr; gap: 0; padding: 0 28px 38px; }
.pokedex-detail-body section { padding: 25px 0 2px; }
.pokedex-detail-body section + section { margin-top: 22px; border-top: 1px solid var(--pd-border); }
.pokedex-detail-body section h3 { margin: 0 0 15px; font-size: 15px; letter-spacing: 0; }
.pokedex-profile, .pokedex-moves, .pokedex-evolution { grid-column: 1; }
.pokedex-profile > p { margin-bottom: 15px; }
.pokedex-profile dl { display: grid; grid-template-columns: 1fr 1fr; gap: 0; overflow: hidden; margin: 0; border: 1px solid var(--pd-border); border-radius: 5px; }
.pokedex-profile dl div { min-height: 58px; padding: 10px 12px; background: var(--pd-card); }
.pokedex-profile dl div:nth-child(odd) { border-right: 1px solid var(--pd-border); }
.pokedex-profile dl div:not(:nth-last-child(-n+2)) { border-bottom: 1px solid var(--pd-border); }
.pokedex-profile dt { color: var(--pd-muted); font-size: 10px; }
.pokedex-profile dd { overflow-wrap: anywhere; margin: 3px 0 0; font-size: 12px; font-weight: 700; }
.pokedex-stats > div { display: grid; grid-template-columns: 52px 34px minmax(0, 1fr); gap: 8px; align-items: center; margin: 7px 0; font-size: 11px; }
.pokedex-stats > div strong { text-align: right; }
.pokedex-stats > div > i { height: 6px; overflow: hidden; border-radius: 3px; background: var(--pd-soft); }
.pokedex-stats > div > i b { display: block; height: 100%; border-radius: 3px; background: var(--pd-accent); }
.pokedex-stats footer { display: flex; justify-content: space-between; padding-top: 8px; border-top: 1px solid var(--pd-border); font-size: 12px; }
.pokedex-abilities > div, .pokedex-moves > div { display: flex; flex-wrap: wrap; gap: 7px; }
.pokedex-abilities > div > span { display: grid; padding: 8px 11px; border: 1px solid var(--pd-border); border-radius: 6px; background: var(--pd-soft); font-size: 12px; font-weight: 700; }
.pokedex-abilities small { color: var(--pd-accent); font-size: 8px; }
.pokedex-moves > div { max-height: 138px; overflow: auto; gap: 5px; }
.pokedex-moves span { padding: 4px 7px; border: 1px solid var(--pd-border); border-radius: 4px; color: var(--pd-muted); font-size: 10px; }
.pokedex-evolution > div { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.pokedex-evolution > div span { padding: 9px 13px; border-radius: 6px; color: #315d4d; background: #e6f1eb; font-weight: 700; }
.pokedex-evolution pre { max-height: 180px; overflow: auto; padding: 12px; border-radius: 6px; color: var(--pd-muted); background: var(--pd-soft); white-space: pre-wrap; }
.pokedex-detail-meta { grid-column: 1; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--pd-border); color: var(--pd-muted); font-size: 10px; }
.pokedex-detail-meta button { margin-left: auto; padding: 7px 10px; border: 1px solid var(--pd-border); border-radius: 5px; color: var(--pd-text); background: var(--pd-card); cursor: pointer; }
.pokedex-detail-meta script { display: none; }
html.pokedex-filter-open, html.pokedex-detail-open, body.pokedex-filter-open, body.pokedex-detail-open { overflow: hidden; }
@keyframes pokedex-fade-in { from { opacity: 0; } }
@keyframes pokedex-slide-in { from { transform: translateX(100%); } }
.pokedex-pagination { display: flex; align-items: center; justify-content: space-between; margin: 24px 0; }
.pokedex-pagination > div { display: flex; gap: 5px; }
.pokedex-pagination a { display: grid; place-items: center; min-width: 34px; height: 34px; padding: 0 10px; border: 1px solid var(--pd-border); border-radius: 5px; background: var(--pd-card); }
.pokedex-pagination a.is-active { border-color: var(--pd-accent); color: #fff; background: var(--pd-accent); }
.pokedex-empty { display: grid; place-items: center; gap: 7px; min-height: 180px; border-top: 1px solid var(--pd-border); border-bottom: 1px solid var(--pd-border); color: var(--pd-muted); }
.pokedex-empty strong { color: var(--pd-text); font-size: 17px; }
.pokedex-empty a { color: var(--pd-accent); }
.pokedex-contribute { margin-top: 42px; padding: 34px 0; border-top: 1px solid var(--pd-border); }
.pokedex-contribute > header { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.pokedex-contribute h2 { margin: 3px 0 0; font-size: 24px; letter-spacing: 0; }
.pokedex-contribute > header > a { flex: 0 0 auto; padding: 8px 12px; border: 1px solid var(--pd-border); border-radius: 5px; background: var(--pd-card); }
.pokedex-version-fields { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.pokedex-version-fields label.is-wide { grid-column: 1 / -1; }
.pokedex-submit-files { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.pokedex-submit-package { display: grid; grid-template-columns: minmax(280px, 1fr) 220px; gap: 14px; align-items: end; }
.pokedex-file { display: block; min-width: 0; }
.pokedex-file input { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
.pokedex-file > span { display: flex; gap: 12px; align-items: center; min-height: 78px; padding: 13px; border: 1px dashed rgba(195, 63, 73, .42); border-radius: 7px; background: rgba(195, 63, 73, .035); cursor: pointer; }
.pokedex-file svg { flex: 0 0 auto; width: 28px; height: 28px; color: var(--pd-accent); fill: none; stroke: currentColor; stroke-width: 2; }
.pokedex-file strong, .pokedex-file small { display: block; }
.pokedex-file small { max-width: 260px; overflow: hidden; color: var(--pd-muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.pokedex-submit-package > button { height: 44px; border: 0; border-radius: 6px; color: #fff; background: var(--pd-accent); cursor: pointer; }
.pokedex-submit-package > button:disabled { opacity: .55; cursor: wait; }
.pokedex-submit-result { display: block; min-height: 22px; margin-top: 8px; color: #39755e; }
.pokedex-submit-result.is-error { color: var(--pd-accent); }
.pokedex-login { display: flex; align-items: center; justify-content: space-between; padding: 22px 0; border-top: 1px solid var(--pd-border); border-bottom: 1px solid var(--pd-border); }
.pokedex-login a { padding: 8px 14px; border-radius: 5px; color: #fff; background: var(--pd-accent); }
.pokedex-own { margin-top: 28px; }
.pokedex-own h3 { font-size: 15px; }
.pokedex-own > p { color: var(--pd-muted); }
.pokedex-own > div { border-top: 1px solid var(--pd-border); }
.pokedex-own article { display: grid; grid-template-columns: 70px minmax(140px, 1fr) 80px 80px; gap: 12px; align-items: center; padding: 9px 4px; border-bottom: 1px solid var(--pd-border); font-size: 11px; }
.pokedex-own article > span { color: var(--pd-accent); font-weight: 800; }
.pokedex-own article strong > small { display: inline; color: var(--pd-muted); font-size: 10px; font-weight: 500; }
.pokedex-own article em { justify-self: start; padding: 2px 6px; border-radius: 4px; color: #8a672b; background: #fff0c9; font-style: normal; }
.pokedex-own article em.is-approved { color: #36705c; background: #dff2e9; }
.pokedex-own article em.is-rejected { color: #a34e56; background: #fae5e8; }
.pokedex-own article time { color: var(--pd-muted); }
.pokedex-own article > small { grid-column: 2 / -1; color: var(--pd-accent); }
@media (max-width: 1050px) {
  .pokedex-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pokedex-detail { grid-template-columns: 270px minmax(0, 1fr); }
  .pokedex-profile dl { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pokedex-filter { grid-template-columns: 220px minmax(220px, 1fr) 44px; }
  .pokedex-filter > a { grid-column: 1 / -1; height: auto; padding: 0; }
  .pokedex-version-fields, .pokedex-submit-package { grid-template-columns: 1fr 1fr; }
  .pokedex-submit-package > button { grid-column: 1 / -1; }
  .pokedex-resource-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 780px) {
  .pokedex-page { padding-top: 12px; }
  .pokedex-intro { display: block; padding-top: 5px; }
  .pokedex-intro h1 { font-size: 26px; }
  .pokedex-intro p { margin-top: 7px; }
  .pokedex-filter { grid-template-columns: minmax(0, 1fr) 44px; }
  .pokedex-filter label:nth-child(1) { grid-column: 1 / -1; grid-row: 1; }
  .pokedex-filter label:nth-child(2) { grid-column: 1; grid-row: 2; }
  .pokedex-filter button { grid-column: 2; grid-row: 2; }
  .pokedex-browser { grid-template-columns: 1fr; }
  .pokedex-sidebar { padding: 0; border-right: 0; border-bottom: 1px solid var(--pd-border); }
  .pokedex-sidebar-toggle { display: flex; width: 100%; height: 44px; align-items: center; justify-content: space-between; padding: 0; border: 0; color: var(--pd-text); background: transparent; font-weight: 700; cursor: pointer; }
  .pokedex-sidebar-toggle:hover, .pokedex-sidebar-toggle:focus { outline: 0; color: var(--pd-text); background: transparent; box-shadow: none; }
  .pokedex-sidebar-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; transition: transform .18s ease; }
  .pokedex-sidebar-body { position: static; display: none; grid-template-columns: 1fr; gap: 24px; padding: 10px 0 24px; }
  .pokedex-sidebar.is-open { position: fixed; inset: 0 auto 0 0; z-index: 100004; width: min(330px, 88vw); height: 100dvh; overflow-y: auto; padding: 8px 20px 24px; border: 0; background: var(--pd-card); box-shadow: 12px 0 40px rgba(15, 31, 24, .18); animation: pokedex-filter-slide-in .22s ease-out; }
  .pokedex-sidebar.is-open .pokedex-sidebar-body { display: grid; }
  .pokedex-sidebar.is-open .pokedex-sidebar-toggle { border-bottom: 1px solid var(--pd-border); }
  .pokedex-sidebar.is-open .pokedex-sidebar-toggle svg { transform: rotate(90deg); }
  .pokedex-sidebar.is-open + .pokedex-sidebar-scrim { position: fixed; inset: 0; z-index: 100003; display: block; width: 100%; height: 100%; padding: 0; border: 0; background: rgba(18, 27, 23, .42); animation: pokedex-fade-in .18s ease-out; }
  .pokedex-sidebar section + section { margin-top: 0; }
  .pokedex-catalog { padding: 20px 0 0; }
  .pokedex-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pokedex-detail { grid-template-columns: 1fr; }
  .pokedex-detail-identity { display: grid; grid-template-columns: 160px minmax(0, 1fr); align-items: center; padding: 22px; }
  .pokedex-detail-identity figure { height: 160px; }
  .pokedex-detail-body { padding: 24px; }
  .pokedex-version-fields, .pokedex-submit-package { grid-template-columns: 1fr; }
  .pokedex-version-fields label.is-wide, .pokedex-submit-package > button { grid-column: auto; }
  .pokedex-compare-selects, .pokedex-compare-output { grid-template-columns: 1fr 1fr; }
  .pokedex-team-grid { grid-template-columns: 1fr; }
  .pokedex-damage-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .pokedex-sidebar section + section { margin-top: 6px; }
  .pokedex-results-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 7px; align-items: flex-start; }
  .pokedex-results-head h2 { font-size: 21px; }
  .pokedex-results-head > strong { justify-self: start; padding-top: 0; }
  .pokedex-grid { gap: 8px; }
  .pokedex-card > header { height: 29px; padding: 0 8px; }
  .pokedex-card { height: 260px; }
  .pokedex-card > figure { height: 142px; margin: 0 5px; }
  .pokedex-card > figure img { width: 120px; height: 120px; }
  .pokedex-card > div { padding: 9px 8px 10px; }
  .pokedex-card h3 { font-size: 14px; }
  .pokedex-types { margin-top: 6px; }
  .pokedex-types i { min-height: 18px; padding: 1px 5px; font-size: 8px; }
  .pokedex-detail-identity { grid-template-columns: 110px minmax(0, 1fr); padding: 18px; }
  .pokedex-detail-identity figure { height: 120px; } .pokedex-detail-identity h2 { font-size: 25px; }
  .pokedex-detail-body { grid-template-columns: 1fr; gap: 20px; padding: 19px; }
  .pokedex-profile, .pokedex-moves, .pokedex-evolution { grid-column: 1; }
  .pokedex-profile dl { grid-template-columns: 1fr 1fr; }
  .pokedex-detail-meta button { margin-left: 0; }
  .pokedex-own article { grid-template-columns: 62px minmax(100px, 1fr) 70px; }
  .pokedex-own article time { display: none; } .pokedex-own article > small { grid-column: 1 / -1; }
  .pokedex-contribute > header { align-items: flex-start; }
  .pokedex-submit-files, .pokedex-resource-grid { grid-template-columns: 1fr; }
  .pokedex-tool-heading { align-items: flex-start; }
  .pokedex-tool-heading h2 { font-size: 22px; }
  .pokedex-compare-selects, .pokedex-compare-output { grid-template-columns: 1fr; }
  .pokedex-team-fields, .pokedex-team-moves { grid-template-columns: 1fr; }
  .pokedex-damage-fields { grid-template-columns: 1fr; }
}
@keyframes pokedex-filter-slide-in { from { transform: translateX(-100%); } }
html[data-theme="dark"] .pokedex-detail-identity { background: #202b26; }
html[data-theme="dark"] .pokedex-generation b { color: #b9d2c9; background: #273931; }
@media (prefers-color-scheme: dark) {
  html[data-theme="auto"] .pokedex-detail-identity { background: #202b26; }
  html[data-theme="auto"] .pokedex-generation b { color: #b9d2c9; background: #273931; }
}
