/* Extras (Extras/extras.js) */

/* ---- before / after ---- */
.ba-wrap { position: fixed; z-index: 40; --ba: 50%; overflow: hidden; border-radius: 14px; box-shadow: 0 0 0 1px #ffffff1a, 0 24px 60px #000a; background: var(--stage-bg, #15171a); cursor: ew-resize; touch-action: none; user-select: none; }
.ba-img { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.ba-before { clip-path: inset(0 calc(100% - var(--ba)) 0 0); }
.ba-wrap.is-loading::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 30%, #ffffff10 50%, transparent 70%) 0 0 / 200% 100%; animation: ba-shimmer 0.9s linear infinite; }
@keyframes ba-shimmer { to { background-position: -200% 0; } }
.ba-line { position: absolute; top: 0; bottom: 0; left: var(--ba); width: 2px; margin-left: -1px; background: #fff; box-shadow: 0 0 12px #0008; pointer-events: none; }
.ba-knob { position: absolute; top: 50%; left: 50%; display: flex; gap: 2px; align-items: center; justify-content: center; width: 40px; height: 40px; border: 2px solid #fff; border-radius: 50%; background: var(--lime, #2e8bff); color: #fff; font-size: 18px; font-weight: 800; line-height: 1; transform: translate(-50%, -50%); box-shadow: 0 6px 18px #0009; pointer-events: auto; cursor: ew-resize; }
.ba-knob:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.ba-tag { position: absolute; top: 12px; padding: 4px 10px; border-radius: 99px; background: #000a; color: #fff; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; pointer-events: none; }
.ba-left { left: 12px; } .ba-right { right: 52px; }
.ba-close { position: absolute; top: 8px; right: 8px; width: 34px; height: 34px; border: 0; border-radius: 9px; background: #000a; color: #fff; font-size: 14px; cursor: pointer; }
.view-button.ba-button svg { width: 19px; height: 19px; }
.view-button.ba-button[aria-pressed="true"] { border-color: var(--lime, #2e8bff); color: var(--lime, #2e8bff); }

/* ---- charge card (third card next to weight + range) ---- */
.cx-stat-row.has-charge { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cx-stat-row.has-charge .cx-weight b { font-size: 19px; }
.cx-charge { font: inherit; text-align: left; color: inherit; cursor: pointer; }
.cx-charge svg { width: 14px; height: 14px; }
.cx-charge:hover { border-color: #3e444b; }
.cx-charge:focus-visible { outline: 2px solid var(--lime, #2e8bff); outline-offset: 2px; }

/* ---- stock dots ---- */
.px-tag.st-in, .px-tag.st-out { display: inline-flex; align-items: center; gap: 5px; }
.px-tag.st-in::before, .px-tag.st-out::before, .st-dot { content: ""; display: inline-block; flex: 0 0 auto; width: 6px; height: 6px; border-radius: 50%; }
.px-tag.st-in::before, .st-dot.st-in { background: #2ecf7a; box-shadow: 0 0 6px #2ecf7a88; }
.px-tag.st-out::before, .st-dot.st-out { background: #ff6b6b; }
.st-dot { margin-right: 6px; vertical-align: 1px; }
.st-dot:not(.st-in):not(.st-out) { display: none; }
.st-bell { flex: 0 0 auto; display: grid; place-items: center; width: 26px; height: 26px; margin-left: auto; padding: 0; border: 1px solid transparent; border-radius: 7px; background: transparent; color: #6f7883; cursor: pointer; }
.st-bell svg { width: 15px; height: 15px; }
.st-bell:hover { border-color: #30353b; color: #c9d0d8; }
.st-bell.on { color: var(--lime, #2e8bff); }
.st-bell.on svg { fill: currentColor; }
.px-item .st-bell + .px-item-price { margin-left: 4px; }

/* ---- parts list fitting column ---- */
.bt-fitcell, .bt-table tfoot .bt-small { white-space: nowrap; }
.bt-lvl { display: inline-block; padding: 2px 7px; border-radius: 99px; font-size: 10.5px; font-weight: 800; }
.bt-lvl.l1 { background: #133d2a; color: #7dffb0; } .bt-lvl.l2 { background: #10314f; color: #8fc0ff; } .bt-lvl.l3 { background: #45250f; color: #ffb36b; } .bt-lvl.l4 { background: #4a1616; color: #ff9b9b; }
.bt-fitcell[title] { cursor: help; }

/* ---- explore ---- */
.ex-button svg { width: 17px; height: 17px; }
.ex-modal { width: min(860px, calc(100vw - 24px)); }
.ex-modal header { flex-wrap: wrap; gap: 10px; }
.ex-tabs { display: flex; gap: 4px; margin-right: auto; margin-left: 14px; padding: 3px; border: 1px solid #2b2f34; border-radius: 10px; background: #111316; }
.ex-tab { height: 30px; padding: 0 12px; border: 0; border-radius: 7px; background: transparent; color: #8d97a3; font: inherit; font-size: 12.5px; font-weight: 800; cursor: pointer; }
.ex-tab[aria-selected="true"] { background: var(--lime, #2e8bff); color: #fff; }
.ex-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; padding: 4px 0 12px; }
.ex-card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid #2b2f34; border-radius: 14px; background: #1a1d20; transition: border-color .15s, transform .15s; }
.ex-card:hover { border-color: #3e444b; transform: translateY(-2px); }
.ex-pic { position: relative; display: grid; grid-template: minmax(0, 1fr) / minmax(0, 1fr); place-items: center; height: 120px; padding: 6px; overflow: hidden; border: 0; background: #111316; cursor: pointer; }
.ex-pic img { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
.ex-pic.t0 { background: linear-gradient(135deg, #1b1e22, #2a2e33); } .ex-pic.t1 { background: linear-gradient(135deg, #0d2238, #17497a); } .ex-pic.t2 { background: linear-gradient(135deg, #0e2b1e, #1c6b44); } .ex-pic.t3 { background: linear-gradient(135deg, #3a1c08, #8a4a12); } .ex-pic.t4 { background: linear-gradient(120deg, #ff5a36, #ff2f8f 55%, #7a4dff); }
.ex-pic.has-img { background: radial-gradient(ellipse at 50% 60%, #262a30, #111316 75%); }
.ex-pic-name { display: grid; justify-items: center; color: #fff; font-family: var(--teko, "Teko", sans-serif); line-height: .9; }
.ex-pic-name b { font-size: 46px; font-weight: 600; letter-spacing: .02em; }
.ex-pic-name small { color: #ffffffb3; font-size: 17px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.ex-body { display: flex; flex: 1; flex-direction: column; gap: 6px; min-width: 0; padding: 10px 12px 12px; }
.ex-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-width: 0; }
.ex-head h3 { min-width: 0; margin: 0; overflow: hidden; color: #e3e8ee; font-size: 14.5px; font-weight: 800; letter-spacing: 0; text-overflow: ellipsis; text-transform: none; white-space: nowrap; }
.ex-tier { flex: 0 0 auto; margin: 0; padding: 2px 8px; font-family: var(--teko, "Teko", sans-serif); font-size: 15px; font-weight: 600; text-transform: uppercase; cursor: default; }
.ex-sub { margin: 0; color: #9aa4b0; font-size: 12px; line-height: 1.4; }
.ex-stats { display: flex; flex-wrap: wrap; gap: 5px; margin-top: auto; color: #c9d0d8; font-size: 11.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.ex-stats span { padding: 3px 8px; border-radius: 99px; background: #ffffff0d; white-space: nowrap; }

.ex-act { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.ex-act .bt-btn { flex: 1; }
.ex-like { display: inline-flex; align-items: center; gap: 5px; height: 34px; padding: 0 10px; border: 1px solid #30353b; border-radius: 9px; background: #1f2226; color: #8d97a3; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; }
.ex-like svg { width: 15px; height: 15px; }
.ex-like.on { border-color: #ff3d6b66; color: #ff5a7e; }
.ex-sort { display: flex; gap: 6px; margin-bottom: 6px; }
.ex-chip { height: 28px; padding: 0 12px; border: 1px solid #30353b; border-radius: 99px; background: transparent; color: #8d97a3; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; }
.ex-chip.on { border-color: var(--lime, #2e8bff); color: var(--lime, #2e8bff); }
.ex-msg { grid-column: 1 / -1; padding: 24px 0; text-align: center; }
.ex-post { width: min(420px, calc(100vw - 24px)); }
.ex-name { box-sizing: border-box; width: 100%; height: 42px; margin-top: 4px; padding: 0 12px; border: 1px solid #30353b; border-radius: 10px; background: #111316; color: #e3e8ee; font: inherit; font-size: 15px; }
.ex-name:focus { outline: 2px solid var(--lime, #2e8bff); outline-offset: 1px; }

/* ---- light theme ---- */
html[data-theme="light"] .ex-card { border-color: #e3e6ea; background: #fff; }
html[data-theme="light"] .ex-pic.has-img, html[data-theme="light"] .ex-tabs, html[data-theme="light"] .ex-name { border-color: #dde1e5; background: #f4f6f8; color: #16202c; }
html[data-theme="light"] .ex-head h3 { color: #16202c; }
html[data-theme="light"] .ex-sub { color: #5a616b; }
html[data-theme="light"] .ex-stats { color: #2a323c; }
html[data-theme="light"] .ex-stats span { background: #eef1f4; }
html[data-theme="light"] .ex-like, html[data-theme="light"] .ex-chip { border-color: #d0d5db; background: #f6f7f9; }
html[data-theme="light"] .bt-lvl.l1 { background: #e3f7ec; color: #138a3d; } html[data-theme="light"] .bt-lvl.l2 { background: #e6f0ff; color: #0b4fae; } html[data-theme="light"] .bt-lvl.l3 { background: #fff1e4; color: #b25d00; } html[data-theme="light"] .bt-lvl.l4 { background: #ffecec; color: #b42020; }
html[data-theme="light"] .st-bell:hover { border-color: #d0d5db; color: #16202c; }

@media (max-width: 760px) {
  .ex-tabs { order: 3; width: 100%; margin-left: 0; }
  .ex-tab { flex: 1; }
  .ex-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .ex-pic { height: 92px; }
  .ex-sub { display: none; }
  .cx-stat-row.has-charge .cx-weight b { font-size: 17px; }
}
@media (max-width: 420px) { .ex-grid { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .ex-card, .ex-card:hover { transform: none; transition: none; } .ba-wrap.is-loading::after { animation: none; } }
