/* ==========================================================================================
   shop-art.css — the official shop look (local patch, docs/LOCAL-PATCH.md "상점 화면"), over screens/game-shop.css.
   Only under `.shopbar.has-shop-art` (js/ui/shopArt.js sets it with the sprite variables when the web manifest has the
   official shopPanel / shopCard sprites). Geometry from the client's prefabs (ui/autochess/[uc]autochessbattle.ab):
   autochess_shop_card_item 158×176, the upgrade group 111×175, the close box 168×184, buttons 128×55 (bg 149×77),
   cost hexagon 44×35, bond rows 154×18 — in the client's canvas units. The scale is the client's: the battle UI page's
   CanvasScaler (auto_chess_battle_ui_page: 1280×720 reference) with every localScale from it down to the shop at 1,
   i.e. 1 unit = 1.5 px at 1920×1080, so `--u` = .015rem (theme.css rem = 1/100 of a 1920×1080 frame; the CN capture of
   2026-10-06 measures ≈ 1.5 too — docs/LOCAL-PATCH.md 「상점 화면」. It was .0108rem, fitted to screenshots, until then).
   Capped so the widest bar (6 slots ≈ 1270 units) stays right of upstream's bottom-left buttons (emotes, chat, settings,
   guide, fullscreen ≈ 4.4rem — the official prep screen has none there): at 16:9 a 6-slot bar is drawn ≈ 1.15 px/unit.
   ========================================================================================== */

.shopbar.has-shop-art { --u: min(var(--ui-u, .015rem), calc((100vw - 4.75rem) / 1270)); /* --ui-u: css/hud-art.css (PC UI scale) */ gap: calc(var(--u) * 6); }
.shopbar.has-shop-art .shopbar__row {
  gap: calc(var(--u) * 6); padding: calc(var(--u) * 10) calc(var(--u) * 6) calc(var(--u) * 6);
  background: var(--sa-shadow-total) center bottom / 100% 100% no-repeat; border: 0; box-shadow: none;
}
.shopbar.has-shop-art .shopbar__row::before { display: none; }
.shopbar.has-shop-art .shopbar__cards, .shopbar.has-shop-art .shopbar__item, .shopbar.has-shop-art .shopbar__rwcards { gap: calc(var(--u) * 6); }
.shopbar.has-shop-art .shopbar__item { padding-left: 0; border-left: 0; }
.shopbar.has-shop-art.is-frozen .shopbar__row { border: 0; }

/* ---- 剩余可放置角色 + 冻结 / 刷新 (panel_ctrl_btn) ---- */
.shopbar.has-shop-art .shopbar__tools { position: relative; z-index: 2; gap: calc(var(--u) * 4) calc(var(--u) * 14); margin-bottom: calc(var(--u) * 12); }
.shopbar.has-shop-art .shopbar__remain {
  font-size: calc(var(--u) * 20); color: #fff; background: rgba(49, 49, 49, .7); border-left: 0; padding: 0 calc(var(--u) * 12);
  line-height: calc(var(--u) * 33); margin-bottom: calc(var(--u) * 26);
}
/* panel_remaining_available_character text_cnt: Novecentowide-Normal (the free Novecento Wide Normal; docs/rules/ui.md 「HUD 숫자 글꼴」) */
.shopbar.has-shop-art .shopbar__remain b { color: #fff; font-size: calc(var(--u) * 20); font-family: 'Novecento Wide', var(--font-num); font-weight: 400; letter-spacing: 0; }
.shopbar.has-shop-art .toolbtn {
  position: relative; width: calc(var(--u) * 128); height: calc(var(--u) * 55); padding: 0; gap: 0; justify-content: center;
  background: transparent; border: 0; box-shadow: none; color: rgba(0, 0, 0, .9); font-size: calc(var(--u) * 19); letter-spacing: .06em; overflow: visible;
}
/* the sprite is 149×77 and sits 9 units lower (its drop shadow) */
.shopbar.has-shop-art .toolbtn::before {
  content: ''; position: absolute; z-index: -1; left: 50%; top: 50%; width: calc(var(--u) * 149); height: calc(var(--u) * 77);
  transform: translate(-50%, calc(-50% + var(--u) * 9)); background: var(--tb-art) center / 100% 100% no-repeat;
}
.shopbar.has-shop-art .toolbtn--ice { --tb-art: var(--sa-frozen); }
/* btn_frozen's three states: group_lock (frozen_bg_normal + frozen_icon, the "freeze" action) while the shop is not
   frozen, group_unlock (frozen_bg_unselect + frozen_icon2 — the crossed-out snowflake, "unfreeze") while it is,
   group_disable (bg_lock + frozen_icon_lock) */
.shopbar.has-shop-art .toolbtn--ice.is-on { --tb-art: var(--sa-frozen-on); background: transparent; color: rgba(0, 0, 0, .9); }
/* refresh_bg_normal is 147×77, one unit left of the button's centre (the lock / disabled art is 149×77, centred) */
.shopbar.has-shop-art .toolbtn--amber:not(:disabled)::before { width: calc(var(--u) * 147); transform: translate(calc(-50% - var(--u) * 1), calc(-50% + var(--u) * 9)); }
.shopbar.has-shop-art .toolbtn--amber { --tb-art: var(--sa-refresh); }
.shopbar.has-shop-art .toolbtn:disabled { --tb-art: var(--sa-lock); color: rgba(0, 0, 0, .9); }
/* the disabled groups' grey icons (frozen_icon_lock / refresh_icon_lock: the same glyph in grey, about 3/4 as bright) */
.shopbar.has-shop-art .toolbtn:disabled .toolbtn__img { filter: grayscale(1) brightness(.75); }
.shopbar.has-shop-art .toolbtn:hover:not(:disabled) { background: transparent; filter: brightness(1.08); box-shadow: none; }
/* icon 31×31 centred 26.5 left of the button's centre, text (54.5 wide) 18.5 right and 1 up (group_* icon / text) */
.shopbar.has-shop-art .toolbtn__img { position: absolute; left: calc(50% - var(--u) * 26.5); top: 50%; transform: translate(-50%, -50%); width: calc(var(--u) * 31); height: calc(var(--u) * 31); margin: 0; }
.shopbar.has-shop-art .toolbtn > span:not([class]) { position: absolute; left: calc(50% + var(--u) * 18.5); top: 50%; transform: translate(-50%, calc(-50% - var(--u) * 1)); width: calc(var(--u) * 54.5); text-align: center; font-weight: 700; white-space: nowrap; }
/* the key hint under the button (pc_key_holder, 39 units down) */
.shopbar.has-shop-art .toolbtn kbd {
  position: absolute; left: 50%; top: 100%; transform: translate(-50%, calc(var(--u) * 6)); margin: 0;
  color: #e8e8e8 !important; background: rgba(20, 20, 20, .85) !important; border-color: rgba(255, 255, 255, .25) !important;
}
/* the refresh price above the button's top-right (root_cost 28 units up): FREE pill or the cost hexagon */
.shopbar.has-shop-art .toolbtn--amber .hex, .shopbar.has-shop-art .toolbtn__free {
  position: absolute; left: 50%; top: 0; transform: translate(-50%, calc(-50% - var(--u) * 15)); /* KR live check 2026-10-06: at −6 it covered the button's top */
}
.shopbar.has-shop-art .toolbtn__free {
  width: calc(var(--u) * 101); height: calc(var(--u) * 35); padding: 0 0 0 calc(var(--u) * 48); display: flex; align-items: center;
  background: var(--sa-free) center / 100% 100% no-repeat; color: #fff; font-size: calc(var(--u) * 17); font-weight: 700; font-family: var(--font-num); letter-spacing: -.06em;
}

/* ---- price hexagon (autochess_shop_cost_item 44×35: cost_bg_1 + 22 px #ffc600, cost_bg_2 + #c0c5c3 when poor) ---- */
.shopbar.has-shop-cost .scard__price, .shopbar.has-shop-cost .lvcard__price, .shopbar.has-shop-cost .toolbtn--amber .hex {
  --hex-h: calc(var(--u) * 35); width: calc(var(--u) * 44); height: calc(var(--u) * 35); filter: none;
  background: var(--sa-cost) center / 100% 100% no-repeat; clip-path: none;
}
.shopbar.has-shop-cost :is(.scard__price, .lvcard__price, .toolbtn--amber .hex) .hex__fill { background: none; clip-path: none; width: 100%; height: 100%; display: grid; place-items: center; }
.shopbar.has-shop-cost :is(.scard__price, .lvcard__price, .toolbtn--amber .hex)::before,
.shopbar.has-shop-cost :is(.scard__price, .lvcard__price, .toolbtn--amber .hex)::after { display: none; }
/* text_num: Novecentowide-Medium (DynFontLoader; Lexend Exa in its place, maintainer decision 2026-11-11), 6 units above the
   hexagon's centre — in the client's font a MiddleCenter line puts the digits ≈ .09 em under its centre, so they show ≈ 4
   units above the middle; the web line puts them ≈ .02 em under it, hence 4.4 here */
.shopbar.has-shop-cost :is(.scard__price, .lvcard__price, .toolbtn--amber .hex) .hex__value {
  color: #ffc600; font-size: calc(var(--u) * 22); line-height: 1; white-space: nowrap; transform: translateY(calc(var(--u) * -4.4));
  font-family: 'Lexend Exa', 'Novecento Wide', var(--font-num); font-weight: 500; letter-spacing: -.06em;
}
/* two digits (a level-up at 10+): the hexagon widens instead of wrapping (maintainer 2026-10-06) */
.shopbar.has-shop-cost :is(.scard__price, .lvcard__price, .toolbtn--amber .hex) { min-width: calc(var(--u) * 44); width: auto !important; padding: 0 calc(var(--u) * 9); box-sizing: border-box; }
.shopbar.has-shop-cost :is(.scard__price.is-poor, .lvcard__price.hex--dark, .toolbtn--amber .hex--dark) { background-image: var(--sa-cost-grey); }
.shopbar.has-shop-cost :is(.scard__price.is-poor, .lvcard__price.hex--dark, .toolbtn--amber .hex--dark) .hex__value { color: #c0c5c3; }

/* ---- operator / item card (autochess_shop_card_item 158×176) ---- */
.shopbar.has-shop-art .scard {
  width: calc(var(--u) * 158); height: calc(var(--u) * 176); border: 0; background: var(--sa-card-black) center / 100% 100% no-repeat; overflow: visible;
}
/* the prefab's group_frame over everything, chosen by the piece's tier as the client's card does (_charLevelFrame: tier 6 →
   frame_lv3 orange, tier 5 → frame_lv2 gold, else frame_lv1); an item card keeps frame_lv1 */
.shopbar.has-shop-art .scard:not(.scard--sold)::before {
  content: ''; position: absolute; inset: 0; z-index: 3; pointer-events: none; background: var(--sa-card-frame1) center / 100% 100% no-repeat;
}
.shopbar.has-shop-art .scard--t5:not(.scard--sold)::before { background-image: var(--sa-card-frame2); }
.shopbar.has-shop-art .scard--t6:not(.scard--sold)::before { background-image: var(--sa-card-frame3); }
.shopbar.has-shop-art .scard__bg { inset: calc(var(--u) * 2); overflow: hidden; z-index: 1;
  background: var(--sa-card-line) left top / auto repeat, var(--sa-card-common) center / 100% 100% no-repeat; opacity: 1; }
/* portrait: top-right (root_char → char_portrait 90×179 pinned to the card's top-right corner, clipped by the card) */
.shopbar.has-shop-art .scard__art {
  z-index: 0; top: calc(var(--u) * 2); right: calc(var(--u) * 2); height: calc(var(--u) * 172); width: calc(var(--u) * 100); object-fit: cover; object-position: 30% top;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 30%), linear-gradient(180deg, #000 60%, transparent 92%);
  mask-image: linear-gradient(90deg, transparent, #000 30%); }
.shopbar.has-shop-art .scard:not(.scard--sold) { overflow: hidden; }
/* watermark: the 特质 type icon (garrison_icon 65×65 at 35 %, its centre 39 left / 23 up of the card's) */
.shopbar.has-shop-art .scard__water { z-index: 1; left: calc(var(--u) * 7); top: calc(var(--u) * 33); width: calc(var(--u) * 65); height: calc(var(--u) * 65); opacity: .35; }
.shopbar.has-shop-art .scard__mark { width: 100%; height: 100%; object-fit: contain; }
/* tier chip: root_tier (29×29 centred 23 / 24 from the top-left); price centred on top */
.shopbar.has-shop-art .scard__top { z-index: 4; left: calc(var(--u) * 8); right: calc(var(--u) * 8); top: calc(var(--u) * 9); }
.shopbar.has-shop-art .scard__top .tier { width: calc(var(--u) * 29); height: calc(var(--u) * 29); }
.shopbar.has-shop-art .scard__price { top: calc(var(--u) * -12); }
.shopbar.has-shop-art .scard__free { top: calc(var(--u) * -10); }
/* bottom: bonds (rows 154×18, icon 22 #b8b8b8, 14 px #b7b7b7) above the name bar (prof icon 16 + name 16 px) */
.shopbar.has-shop-art .scard__body {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; display: flex; flex-direction: column; gap: 0;
  padding: 0 0 calc(var(--u) * 4); background: none;
}
.shopbar.has-shop-art .scard__bonds { order: 1; flex-direction: column; gap: calc(var(--u) * 2); padding: 0 calc(var(--u) * 4) calc(var(--u) * 6); }
.shopbar.has-shop-art .scard__bond { gap: calc(var(--u) * 4); font-size: calc(var(--u) * 14); line-height: calc(var(--u) * 18); color: #b7b7b7; }
.shopbar.has-shop-art .scard__bond .bglyph { width: calc(var(--u) * 22); height: calc(var(--u) * 22); filter: grayscale(1) brightness(1.4); opacity: .8; }
.shopbar.has-shop-art .scard__name, .shopbar.has-shop-art .scard--item .scard__name {
  order: 3; position: relative; height: calc(var(--u) * 24); line-height: calc(var(--u) * 24); margin: 0 calc(var(--u) * 2);
  padding-left: calc(var(--u) * 25); font-size: calc(var(--u) * 16); font-weight: 700; letter-spacing: .02em;
  background: rgba(0, 0, 0, .55); text-shadow: none;
}
/* the profession icon goes into the name bar (the class subtitle is not on the official card) */
.shopbar.has-shop-art .scard__class { order: 2; position: absolute; left: calc(var(--u) * 9); bottom: calc(var(--u) * 8); z-index: 2; display: flex; }
.shopbar.has-shop-art .scard__class > span { display: none; }
.shopbar.has-shop-art .scard__prof { width: calc(var(--u) * 16); height: calc(var(--u) * 16); opacity: .9; filter: brightness(0) invert(1); }
/* the loadout's skill icon (upstream, DESIGN §16): bottom-right, just above the name bar (maintainer 2026-10-06) */
.shopbar.has-shop-art .scard__skill { top: auto; right: calc(var(--u) * 6); bottom: calc(var(--u) * 31); width: calc(var(--u) * 28); height: calc(var(--u) * 28); z-index: 3; }
.shopbar.has-shop-art .scard__mergetag { top: calc(var(--u) * 42); }
/* not affordable / not editable: the prefab's disable_matte (#5b5b5b99) */
.shopbar.has-shop-art .scard.is-disabled:not(.is-armed)::after, .shopbar.has-shop-art.is-locked .scard:not(.scard--sold)::after {
  content: ''; position: absolute; inset: 0; z-index: 5; pointer-events: none; background: rgba(91, 91, 91, .6); mix-blend-mode: multiply;
}
.shopbar.has-shop-art .scard.is-disabled .scard__art { filter: grayscale(1) brightness(.75); }
/* frozen: state_fx_frozen — ice_matte at the bottom + icon_ice. In the prefab it is its own layer above disable_matte, so a
   frozen card the player cannot afford (or a locked bar) shows both: the grey matte keeps `::after` and the ice is drawn by
   `.scard__ice` (the matte as its background, the icon as its `::before`), under the first-tap confirm (btn_double_check) */
.shopbar.has-shop-art .scard.is-frozen::after { content: none; }
.shopbar.has-shop-art .scard__ice {
  left: 0; right: 0; bottom: 0; transform: none; z-index: 6; pointer-events: none; display: block; width: auto; height: calc(var(--u) * 67);
  border: 0; background: var(--sa-card-icematte) center bottom / 100% 100% no-repeat;
}
.shopbar.has-shop-art .scard__ice::before {
  content: ''; position: absolute; left: 50%; bottom: calc(var(--u) * 10); width: calc(var(--u) * 31); height: calc(var(--u) * 34); transform: translateX(-50%);
  background: var(--sa-card-ice) center / contain no-repeat;
}
.shopbar.has-shop-art .scard__ice .icon { display: none; }
/* item card: deco_item 128×99 behind the 93×93 icon, the name bar with icon_item; no description on the official card */
.shopbar.has-shop-art .scard--item .scard__bg { background: var(--sa-card-deco) center 38% / calc(var(--u) * 128) calc(var(--u) * 99) no-repeat, var(--sa-card-line) left top / auto repeat; }
.shopbar.has-shop-art .scard__itemart { z-index: 2; top: calc(var(--u) * 28); width: calc(var(--u) * 93); height: calc(var(--u) * 93); background: none; }
.shopbar.has-shop-art .scard__idesc { display: none; }
.shopbar.has-shop-art .scard--item .scard__name::before {
  content: ''; position: absolute; left: calc(var(--u) * 7); top: 50%; width: calc(var(--u) * 16); height: calc(var(--u) * 16); transform: translateY(-50%);
  background: var(--sa-card-item) center / contain no-repeat;
}
/* sold / empty slot: bg_empty ([ NO INFO ]) */
.shopbar.has-shop-art .scard--sold { border: 0; background: var(--sa-card-empty) center / 100% 100% no-repeat; }
.shopbar.has-shop-art .scard__soldtxt { display: none; }
.shopbar.has-shop-art .scard:not(.is-disabled):not(.scard--sold):hover { border: 0; box-shadow: none; }

/* ---- upgrade (group_upgrade 111×175) ---- */
.shopbar.has-shop-art .lvcard {
  width: calc(var(--u) * 111); height: calc(var(--u) * 175); padding: 0; gap: 0; justify-content: flex-start; clip-path: none; overflow: visible;
  background:
    var(--sa-up-stripe) center / 100% 100% no-repeat,
    var(--sa-card-line) left top / auto repeat,
    #107463;
}
.shopbar.has-shop-art .lvcard::before { /* deco_up / deco_down */
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: var(--sa-up-deco-up) center calc(var(--u) * 11) / calc(var(--u) * 49) calc(var(--u) * 6) no-repeat,
              var(--sa-up-deco-down) center calc(100% - var(--u) * 5) / calc(var(--u) * 95) calc(var(--u) * 10) no-repeat;
  opacity: .5;
}
.shopbar.has-shop-art .lvcard__price { top: calc(var(--u) * -6); }
.shopbar.has-shop-art .lvcard__frame {
  position: absolute; left: 50%; top: calc(var(--u) * 33); width: calc(var(--u) * 97); height: calc(var(--u) * 85); transform: translateX(-50%);
  padding: 0; border: 0; justify-content: center;
  background: var(--sa-up-frame) center / 100% 100% no-repeat,
              radial-gradient(rgba(2, 2, 1, .6), rgba(2, 2, 1, .6)) center / calc(var(--u) * 85) calc(var(--u) * 69) no-repeat;
}
/* the inner icon is a near-black silhouette at 30 % (prefab colour #0205054c) */
.shopbar.has-shop-art .lvcard__frame::before {
  content: ''; position: absolute; left: 50%; top: 50%; width: calc(var(--u) * 60); height: calc(var(--u) * 61); transform: translate(-50%, -50%);
  border: 0; background: var(--sa-up-icon) center / contain no-repeat; filter: brightness(0); opacity: .3;
}
.shopbar.has-shop-art .lvcard__frame::after { display: none; }
.shopbar.has-shop-art .lvcard__micro { /* the prefab's 39×9 'level' text sprite, centred 51.5 under the box's top (root_inner +12, level +24); the web
   manifest's `shopPanel/level` is another sprite of that name, so it is text here */
  position: absolute; z-index: 1; left: 0; right: 0; top: calc(var(--u) * 18.5); transform: translateY(-50%); text-align: center; font-size: calc(var(--u) * 12); line-height: 1; letter-spacing: .2em; padding-left: .2em; color: #57e8cb; opacity: .85; }
/* text_num: Novecentowide-Bold 50 (DynFontLoader). The level is a roman numeral (maintainer decision 2026-11-19), drawn in
   Krona One: its plain-bar I matches the official roman level sprites (shop_level_n / shop_level_icon_n) where Lexend's
   serifed I did not; its cap height is .763 em against Novecento's .70, so 46 gives the official 50's numeral height
   (docs/rules/ui.md 「HUD 숫자 글꼴」). Krona One's line puts the caps 1.5 higher than Lexend's did, so the line sits at 47.5
   in place of 46 below (measured on the level card, desktop and phone). Before: Lexend Exa 700 (maintainer decision 2026-11-13). Its line
   centred 75.5 under the box's top (root_num +4, text +8; group_disable / group_max text 12.3 up: 75.2). The client's
   MiddleCenter line puts the digits ≈ .09 em under its centre and the web line ≈ .02 em, so the line sits 3.5 lower:
   79 under the top, 46 inside .lvcard__frame (whose top is 33 under the box's; the LEVEL caption 18.5 there). The digits
   then start ≈ 6 under the caption as in the client; at 56 in Bender (until 2026-11-13) they ran into it. */
.shopbar.has-shop-art .lvcard__num { position: absolute; z-index: 1; left: 0; right: 0; top: calc(var(--u) * 47.5); transform: translateY(-50%); margin: 0; text-align: center; line-height: 1; font-size: calc(var(--u) * 46); color: #57e8cb;
  font-family: 'Krona One', 'Lexend Exa', 'Novecento Wide', var(--font-num); font-weight: 400; letter-spacing: 0; }
/* 升级 (text_tip, 100×30, 70.1 under the centre: centred 157.6 under the top) */
.shopbar.has-shop-art .lvcard__label { position: absolute; left: 0; right: 0; top: calc(var(--u) * 157.6); bottom: auto; transform: translateY(-50%); line-height: 1; text-align: center; font-size: calc(var(--u) * 20); color: #6eecd2; letter-spacing: .2em; padding-left: .2em; }
.shopbar.has-shop-art .lvcard__key { left: 50%; right: auto; top: 100%; bottom: auto; transform: translate(-50%, calc(var(--u) * 4));
  color: #e8e8e8 !important; background: rgba(20, 20, 20, .85) !important; border-color: rgba(255, 255, 255, .25) !important; }
.shopbar.has-shop-art .lvcard.is-disabled { background: var(--sa-up-disable) center / 100% 100% no-repeat; }
.shopbar.has-shop-art .lvcard.is-disabled::before, .shopbar.has-shop-art .lvcard.is-max::before { display: none; }
.shopbar.has-shop-art .lvcard.is-disabled .lvcard__frame, .shopbar.has-shop-art .lvcard.is-max .lvcard__frame { background: none; }
.shopbar.has-shop-art .lvcard.is-disabled .lvcard__frame::before, .shopbar.has-shop-art .lvcard.is-max .lvcard__frame::before { display: none; }
/* upgrade_disable / upgrade_max carry the LEVEL text, the frame and the lock glyph in the art: no text of ours there */
.shopbar.has-shop-art .lvcard.is-disabled .lvcard__micro, .shopbar.has-shop-art .lvcard.is-max .lvcard__micro { display: none; }
.shopbar.has-shop-art .lvcard.is-disabled .lvcard__num { color: #b6b6b6; }
.shopbar.has-shop-art .lvcard.is-disabled .lvcard__label { color: #444; }
.shopbar.has-shop-art .lvcard.is-max { background: var(--sa-up-max) center / 100% 100% no-repeat; }
.shopbar.has-shop-art .lvcard.is-max .lvcard__num, .shopbar.has-shop-art .lvcard.is-max .lvcard__label { color: #679a90; }
.shopbar.has-shop-art .lvcard.is-armed { background: var(--sa-up-stripe) center / 100% 100% no-repeat, #1a9a83; animation: none;
  box-shadow: 0 0 0 calc(var(--u) * 2) #6eecd2, 0 0 calc(var(--u) * 20) rgba(110, 236, 210, .45); }

/* ---- funds (group_money: bg_money 110×37, 28 px #ffba00) + close box (bg_close 181×197, 收起 20 px #37e5ca + icon_x) ---- */
.shopbar.has-shop-art .funds {
  position: relative; width: calc(var(--u) * 168); height: calc(var(--u) * 176); padding: 0; gap: 0; border-left: 0; justify-content: flex-end;
  /* bg_close 181×197 sits 3.5 left and 3.5 up of the 168×184 box */
  background: var(--sa-close) calc(50% - var(--u) * 3.5) calc(50% - var(--u) * 3.5) / calc(var(--u) * 181) calc(var(--u) * 197) no-repeat;
}
.shopbar.has-shop-art .funds__hex {
  /* centred on the close box's top edge: group_money's bg 98.7 under main_view's top, btn_close's top 99 */
  position: absolute; z-index: 3; left: 50%; top: calc(var(--u) * -18.8); transform: translateX(-50%); width: calc(var(--u) * 110); height: calc(var(--u) * 37);
  flex-direction: row; gap: 0; padding-left: calc(var(--u) * 34); clip-path: none; background: var(--sa-money) center / 100% 100% no-repeat;
}
.shopbar.has-shop-art .funds__hex::before, .shopbar.has-shop-art .funds__coin { display: none; }
.shopbar.has-shop-art .funds__num { font-size: calc(var(--u) * 28); color: #ffba00; font-family: 'Lexend Exa', 'Novecento Wide', var(--font-num); font-weight: 500; letter-spacing: -.06em; } /* coin_num: Novecentowide-Medium */
.shopbar.has-shop-art .funds__label { display: none; }
.shopbar.has-shop-art .funds__collapse {
  position: relative; flex-direction: row-reverse; margin-bottom: calc(var(--u) * 14); padding: calc(var(--u) * 10) calc(var(--u) * 30);
  font-size: calc(var(--u) * 20); font-weight: 700; color: #37e5ca; border: 0; letter-spacing: .1em;
  background: var(--sa-close-shadow) center / calc(var(--u) * 155) calc(var(--u) * 70) no-repeat;
}
.shopbar.has-shop-art .funds__collapse .icon { width: calc(var(--u) * 20); height: calc(var(--u) * 20); color: transparent; background: var(--sa-x) center / contain no-repeat; }
.shopbar.has-shop-art .funds__collapse .icon * { display: none; }
.shopbar.has-shop-art .funds__collapse:hover { color: #7ff5e2; }

/* ---- promotion reward / special refresh header: as tall as the cards ---- */
.shopbar.has-shop-art .rwtag { width: calc(var(--u) * 84); height: calc(var(--u) * 176); gap: calc(var(--u) * 4); padding: calc(var(--u) * 6) calc(var(--u) * 4); overflow: hidden; }
.shopbar.has-shop-art .rwtag__icon { width: calc(var(--u) * 24); height: calc(var(--u) * 24); }
.shopbar.has-shop-art .rwtag__title { writing-mode: horizontal-tb; font-size: calc(var(--u) * 16); line-height: 1.25; letter-spacing: .06em; text-align: center; }
.shopbar.has-shop-art .rwtag__sub { font-size: calc(var(--u) * 11); }
.shopbar.has-shop-art .rwtag__later { margin-top: 0; font-size: calc(var(--u) * 12); padding: calc(var(--u) * 2) calc(var(--u) * 6); }
.shopbar.has-shop-art .shopbar__reward::before { inset: calc(var(--u) * -4) calc(var(--u) * -3); }

/* ---- 规程 default theme (ac_n_initial: panel_shop_main + autochess_shop_card_item of the theme bundle; js/ui/shopArt.js
   puts its sprites in the same variables and sets `has-shop-theme` — maintainer decision 2026-11-10, that season only) ---- */
/* card 155×187 on bg_black (no bg_common / repeat_line); the tier frame 155×191, 2 units lower (group_frame) */
.shopbar.has-shop-theme .scard { width: calc(var(--u) * 155); height: calc(var(--u) * 187); }
.shopbar.has-shop-theme .scard:not(.scard--sold) { overflow: visible; }
.shopbar.has-shop-theme .scard:not(.scard--sold)::before { top: 0; bottom: calc(var(--u) * -4); }
.shopbar.has-shop-theme .scard__bg { background: none; }
.shopbar.has-shop-theme .scard--item .scard__bg { background: var(--sa-card-deco) center 40% / calc(var(--u) * 128) calc(var(--u) * 99) no-repeat; }
/* portrait 112×224 pinned 9.5 right of and 29.5 above the card's top-right corner (char_portrait, pivot 1,1), faded by
   root_char's soft mask (mask_char's red channel, the card's own size) */
.shopbar.has-shop-theme .scard__art {
  top: calc(var(--u) * -29.5); right: calc(var(--u) * -9.5); width: calc(var(--u) * 112); height: calc(var(--u) * 224); object-fit: cover; object-position: center top;
  -webkit-mask: var(--sa-card-mask) calc(var(--u) * -52.5) calc(var(--u) * 29.5) / calc(var(--u) * 155) calc(var(--u) * 187) no-repeat;
  mask: var(--sa-card-mask) calc(var(--u) * -52.5) calc(var(--u) * 29.5) / calc(var(--u) * 155) calc(var(--u) * 187) no-repeat luminance; mask-mode: luminance;
}
/* watermark 70×70 centred 37 left / 31 up (garrison_icon), #FFFFFF33 (skinColorDataDict garrisonIconColor) */
.shopbar.has-shop-theme .scard__water { left: calc(var(--u) * 5.5); top: calc(var(--u) * 27.5); width: calc(var(--u) * 70); height: calc(var(--u) * 70); opacity: .2; }
/* tier chip 26×26 centred 18 / 19 from the top-left (root_tier) */
.shopbar.has-shop-theme .scard__top { left: calc(var(--u) * 5); top: calc(var(--u) * 6); }
.shopbar.has-shop-theme .scard__top .tier { width: calc(var(--u) * 26); height: calc(var(--u) * 26); }
/* name bar centred 25 above the bottom with the 24-unit profession icon (root_name), the bonds above it (bond_list
   44 under the centre) */
.shopbar.has-shop-theme .scard__body { padding-bottom: calc(var(--u) * 13); }
.shopbar.has-shop-theme .scard__bonds { padding-bottom: calc(var(--u) * 7); }
.shopbar.has-shop-theme .scard__name { background: none; padding-left: calc(var(--u) * 29); }
.shopbar.has-shop-theme .scard__class { bottom: calc(var(--u) * 15); left: calc(var(--u) * 4); }
.shopbar.has-shop-theme .scard__prof { width: calc(var(--u) * 24); height: calc(var(--u) * 24); filter: brightness(0) invert(.94); opacity: 1; }
.shopbar.has-shop-theme .scard__skill { bottom: calc(var(--u) * 44); }
.shopbar.has-shop-theme .scard--sold { width: calc(var(--u) * 158); height: calc(var(--u) * 187); }
.shopbar.has-shop-theme .scard.is-disabled:not(.is-armed)::after, .shopbar.has-shop-theme.is-locked .scard:not(.scard--sold)::after {
  background: var(--sa-card-disable) center / 100% 100%; mix-blend-mode: normal;
}
/* upgrade box 112×188 (group_normal), its inner plate 101×85 under the frame */
.shopbar.has-shop-theme .lvcard { width: calc(var(--u) * 112); height: calc(var(--u) * 188); }
.shopbar.has-shop-theme .lvcard__frame { top: calc(var(--u) * 35);
  background: var(--sa-up-frame) center / 100% 100% no-repeat, var(--sa-up-matte) center / calc(var(--u) * 101) calc(var(--u) * 85) no-repeat; }
.shopbar.has-shop-theme .lvcard__label { top: calc(var(--u) * 164); }
/* 冻结 / 刷新: buttons 144×49, their art 168×72 9 units lower; icon 41 left of the centre, text 26 right (56 wide) */
.shopbar.has-shop-theme .toolbtn { width: calc(var(--u) * 144); height: calc(var(--u) * 49); }
.shopbar.has-shop-theme .toolbtn::before, .shopbar.has-shop-theme .toolbtn--amber:not(:disabled)::before {
  width: calc(var(--u) * 168); height: calc(var(--u) * 72); transform: translate(-50%, calc(-50% + var(--u) * 9)); }
.shopbar.has-shop-theme .toolbtn__img { left: calc(50% - var(--u) * 41); }
.shopbar.has-shop-theme .toolbtn > span:not([class]) { left: calc(50% + var(--u) * 26); width: calc(var(--u) * 56); }
/* close box (btn_close 184×205, bg_close 192×213), the funds plate 120×47 inside its top (root_main_money 188 up) */
.shopbar.has-shop-theme .funds { width: calc(var(--u) * 184); height: calc(var(--u) * 205); margin-top: calc(var(--u) * -18);
  background: var(--sa-close) center calc(100% + var(--u) * .5) / calc(var(--u) * 192) calc(var(--u) * 213) no-repeat; }
.shopbar.has-shop-theme .funds__hex { width: calc(var(--u) * 120); height: calc(var(--u) * 47); top: calc(var(--u) * -6.5); padding-left: calc(var(--u) * 40); }
/* 规程's autochess_main_money_item: coin_num 4 units above bg_money's centre on the prefab's 99×39 plate (drawn 120×47 here, so
   4.8), less the client font's .09 em drop → the digits ≈ 2.4 above the plate's centre, the middle of its visible top 43 of
   47 (as the CN captures show); the price text_num 20 px, 5 units above the hexagon's centre (≈ 3.2 shown, 3.6 here as above) */
.shopbar.has-shop-theme .funds__num { transform: translateY(calc(var(--u) * -3)); }
.shopbar.has-shop-cost.has-shop-theme :is(.scard__price, .lvcard__price, .toolbtn--amber .hex) .hex__value { font-size: calc(var(--u) * 20); transform: translateY(calc(var(--u) * -3.6)); }
.shopbar.has-shop-theme .funds__collapse { background-size: calc(var(--u) * 122) calc(var(--u) * 68); }
.shopbar.has-shop-theme .funds__collapse .icon { width: calc(var(--u) * 18); height: calc(var(--u) * 18); }
.shopbar.has-shop-theme .shopbar__row, .shopbar.has-shop-theme .shopbar__cards { gap: calc(var(--u) * 7); }
