.lbBackpackShell { color-scheme: dark; --lb-page-gutter: 16px; }
.lbBackpackShell *, .lbBackpackShell *::before, .lbBackpackShell *::after { box-sizing: border-box; }
.lbBackpackShell [hidden] { display: none !important; }
.lbBackpackShell body {
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  isolation: isolate;
  color: #f8f7fa;
  font-family: "Segoe UI Variable", "Segoe UI", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
}

.lbBackpack {
  width: min(1284px, calc(100% - 2 * var(--lb-page-gutter)));
  margin-inline: auto;
  padding-block: 38px 48px;
  --bp-control: 43px;
  --bp-surface: #302e35;
}
.lbBackpack h1 { margin: 0 0 16px; font-size: 26px; line-height: 34px; font-weight: 750; }
.lbBackpackShell :is(button, input, summary) { font: inherit; }
:is(.lbBackpack, .bpFilter) :is(a, button, input, summary):focus-visible { outline: 2px solid #c8ceff; outline-offset: -2px; }
.lbBackpackShell button:not(:disabled) { cursor: pointer; }
.bpTabs { display: flex; align-items: center; gap: 2px; margin-block-end: 17px; }
.bpTabs button {
  min-inline-size: 82px;
  min-block-size: 51px;
  padding: 0 20px;
  border: 0;
  border-block-end: 3px solid transparent;
  background: transparent;
  color: #a5a2a9;
  font-weight: 700;
}
.bpTabs button:first-child { min-inline-size: 92px; }
.bpTabs button[aria-selected="true"] {
  color: #fff;
  border-block-end-color: #fff;
  background: linear-gradient(180deg, transparent, #ffffff23);
}
.bpTabs button:hover { color: #fff; }
.bpToolbar {
  display: grid;
  grid-template-columns: minmax(0, 321px) repeat(2, var(--bp-control)) minmax(max-content, 1fr);
  align-items: center;
  gap: 8px;
}
.bpSearch {
  min-inline-size: 0;
  height: var(--bp-control);
  display: flex;
  align-items: center;
  gap: 8px;
  padding-inline: 8px 4px;
  border-radius: 9px;
  background: var(--bp-surface);
}
.bpSearch:focus-within { outline: 2px solid #c8ceff; outline-offset: -2px; }
.bpSearch > svg { flex: none; }
.bpSearch input {
  flex: 1;
  min-inline-size: 0;
  block-size: 100%;
  padding: 0;
  appearance: none;
  border: 0;
  outline: 0 !important;
  background: transparent;
  color: inherit;
}
.bpSearch input::-webkit-search-cancel-button { display: none; }
.bpSearch input::placeholder { color: #a8b1c2; opacity: 1; }
.bpSearch button, .bpFilterClose {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #e5e1ec;
  font-size: 24px;
  line-height: 1;
}
.bpSearch button:hover, .bpFilterClose:hover { background: #ffffff14; }
.bpTool {
  position: relative;
  inline-size: var(--bp-control);
  block-size: var(--bp-control);
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 9px;
  background: var(--bp-surface);
  color: #fff;
}
.bpTool:hover, .bpTool[aria-expanded="true"] { background: #403e47; }
.bpFilterCount {
  position: absolute;
  inset: 2px 2px auto auto;
  min-width: 14px;
  height: 14px;
  border-radius: 999px;
  padding-inline: 3px;
  background: #eeebff;
  color: #232134;
  font-size: 10px;
  font-weight: 750;
}
.lbBackpackShell .bpSelectAll {
  justify-self: end;
  min-width: 48px;
  min-height: var(--bp-control);
  border: 0;
  padding: 0 8px;
  background: transparent;
  color: #f8f7fa;
  opacity: 1;
  font-size: 14px;
  font-weight: 700;
}
.bpSort { position: relative; }
.bpSortOptions {
  position: absolute;
  z-index: 5;
  inset: calc(100% + 10px) auto auto 50%;
  transform: translateX(-50%);
  min-width: 150px;
  padding: 5px;
  border: 1px solid #ffffff13;
  border-radius: 8px;
  background: #131217;
  box-shadow: 0 8px 24px #0009;
}
.bpSortOptions label { display: block; cursor: pointer; }
.bpSortOptions input, .bpFilterChips input, .bpSrOnly {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.bpSortOptions label span {
  display: flex;
  align-items: center;
  min-height: 34px;
  justify-content: space-between;
  gap: 10px;
  padding: 0 9px;
  border-radius: 5px;
  color: #f7f7fa;
  font-size: 14px;
  font-weight: 650;
  white-space: nowrap;
}
.bpSortOptions label:hover span, .bpSortOptions input:focus-visible + span { background: #ffffff16; }
.bpSortOptions input:focus-visible + span, .bpFilterChips input:focus-visible + span { outline: 2px solid #c8ceff; outline-offset: -2px; }
.bpSortOptions input:checked + span::after { content: ""; width: 10px; height: 6px; border: solid currentColor; border-width: 0 0 1.5px 1.5px; transform: translateY(-1px) rotate(-45deg); }
.bpEmpty { margin-block-start: max(112px, calc(50svh - 273px)); text-align: center; }
.bpEmpty p { margin: 0; }
.bpEmptyTitle { font-size: 18px; line-height: 26px; font-weight: 750; }
.bpEmpty .bpEmptyHint { margin-block-start: 6px; color: #eeedf1; font-size: 16px; line-height: 22px; }

.bpFilter {
  position: fixed;
  inset: 16px 16px 16px auto;
  width: min(354px, calc(100% - 32px));
  height: calc(100% - 32px);
  height: calc(100dvh - 32px);
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 1px solid #ffffff1b;
  border-radius: 20px;
  background: #18181b;
  color: #f7f7fa;
}
.bpFilter[open] { display: flex; flex-direction: column; }
.bpFilter::backdrop { background: #0006; }
.bpFilterHeader, .bpFilterFooter { flex: none; padding: 12px 24px; }
.bpFilterHeader { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #ffffff08; }
.bpFilterHeader h2 { margin: 0; font-size: 18px; }
.bpFilterBody { min-height: 0; padding: 0 24px; overflow-y: auto; overscroll-behavior: contain; }
.bpFilterGroup { padding: 14px 0 16px; border-bottom: 1px solid #ffffff08; }
.bpFilterGroup summary { display: flex; align-items: center; justify-content: space-between; min-height: 32px; cursor: pointer; list-style: none; font-size: 15px; font-weight: 700; }
.bpFilterGroup summary::-webkit-details-marker { display: none; }
.bpFilterGroup summary::after { content: ""; margin-inline-end: 4px; width: 8px; height: 8px; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); }
.bpFilterGroup[open] summary { margin-bottom: 9px; }
.bpFilterGroup[open] summary::after { transform: translateY(3px) rotate(225deg); }
.bpFilterChips { display: flex; flex-wrap: wrap; gap: 8px; }
.bpFilterChips label { cursor: pointer; }
.bpFilterChips span { display: grid; place-items: center; min-height: 39px; padding: 6px 13px; border: 1px solid transparent; border-radius: 8px; background: #222225; font-size: 14px; font-weight: 650; }
.bpFilterChips label:hover span { background: #2e2d33; }
.bpFilterChips input:checked + span { color: #fff; border-color: #d7d4e7; background: #3a3944; }
.bpRarities { display: grid; grid-template-columns: repeat(3, minmax(0, 72px)); }
.bpFilterPrices { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.bpFilter :is(input[type="number"], input[type="search"]) { width: 100%; min-width: 0; min-height: 40px; padding: 7px 12px; border: 0; border-radius: 8px; background: #222225; color: inherit; }
.bpFilter input::placeholder { color: #a1a4b0; opacity: 1; }
.bpSeriesQuery { margin-bottom: 10px; }
.bpSeriesEmpty { margin: 4px 0 0; font-size: 14px; color: #cbc8d0; }
.bpFilterFooter { margin-top: auto; border-top: 1px solid #ffffff08; }
.bpFilterReset { width: 100%; min-height: 48px; border: 0; border-radius: 8px; background: #fff; color: #24232a; }
.bpFilterReset:focus-visible { outline-color: #232134; }

@media (max-width: 1040px) {
  .lbBackpack { padding-block-start: 25px; }
}
@media (max-width: 600px) {
  .lbBackpack { --bp-control: 44px; }
  .lbBackpack h1 { font-size: 24px; line-height: 32px; }
  .bpEmpty { margin-block-start: max(88px, calc(50svh - 269px)); }
  .bpSortOptions label span { min-height: 44px; }
  .bpFilterChips span { min-height: 44px; }
  .bpFilterHeader, .bpFilterFooter { padding-inline: 16px; }
  .bpFilterBody { padding-inline: 16px; }
}
