/* Local preparation candidate; activated only by prepArtUI after authenticated theme + complete assets. */
:root[data-ui-theme='black-gold'] body.prep-art-active.preparation-dashboard #prep-dashboard {
  --prep-skill-size: clamp(48px, 7.1vw, 68px);
  --prep-padding-inline: 12px; --prep-padding-block: 10px;
  --prep-art-ink: #fff0b5; --prep-art-muted: #dbd5bd;
  grid-template-rows: 50px 44px minmax(0, 1fr); gap: 8px;
  background: #080e15 var(--prep-art-background) center / 100% 100% no-repeat;
  color: var(--prep-art-ink); font-family: 'RD Prep Serif', 'Noto Serif CJK SC', SimSun, serif;
}
:root[data-ui-theme='black-gold'] body.prep-art-active.preparation-dashboard:not(.shop-open)::after {
  border: 0; border-image: var(--prep-art-frame) 40 / 13px / 0 stretch; z-index: 2500;
}
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard::selection { background: #71603b; color: #fff0b5; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-dashboard-header {
  padding: 5px 10px; gap: 10px;
  border-image: var(--prep-art-panel) 48 / 10px / 0 stretch;
  background: #080c10e8;
}
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-identity { min-width: 110px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-identity img { width: 36px; height: 36px; border-radius: 0; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-identity strong { font-size: 14px; color: var(--prep-art-ink); }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-identity span { font-size: 12px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-vitals { flex-basis: 135px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-vitals b { font: 12px/15px 'RD Prep Serif', serif; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-core-stats { gap: 3px 12px; font-size: 12px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-core-stats dt { color: var(--prep-art-muted); }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-economy { gap: 10px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-economy b { font-size: 19px; font-weight: 400; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-economy span { font-size: 13px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-shortcuts { width: calc(100% - 28.5vw); gap: 5px; background: transparent; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard button {
  color: var(--prep-art-ink); background: transparent; border: 0; border-radius: 0;
  border-image: var(--prep-art-neutral) 12 fill / 6px / 0 stretch; box-shadow: none;
  font-family: 'RD Prep Serif', 'Noto Serif CJK SC', SimSun, serif; font-weight: 400;
  text-shadow: 0 1px 2px #000;
}
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard button:is(:active, [data-theme-pressed='true']):not(:disabled) { border-image-source: var(--prep-art-neutral); filter: brightness(.73); }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard button:disabled { border-image-source: var(--prep-art-neutral); filter: saturate(.12); opacity: .5; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard button:focus-visible { outline: 2px solid #9de0ff; outline-offset: -4px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard .prep-shortcuts button { flex: 1; min-width: 0; padding: 4px 6px; font-size: clamp(10px, 1.35vw, 13px); }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard #prep-shop-shortcut { flex: 1.05; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-shop-shortcut::after { content: '商店'; margin-left: 4px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-shop-shortcut svg { width: 18px; height: 18px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-dashboard-body { display: flex; flex-direction: column; width: 51.8%; gap: 23px; padding-top: 8px; padding-bottom: 4px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid {
  position: relative; flex: 1; display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); grid-template-rows: 1fr;
  gap: 7px; min-height: 0; padding: 28px 13px 21px;
  background: #080c10d9 var(--prep-art-stone) center / 180px 132px repeat;
  border-image: var(--prep-art-panel) 48 / 13px / 0 stretch;
}
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-title {
  display: flex; position: absolute; z-index: 2; top: -18px; left: 50%; transform: translateX(-50%);
  align-items: center; justify-content: center; width: clamp(116px,16vw,140px); height: 36px; min-width: 0; margin: 0; padding: 0 22px;
  font-size: 16px; line-height: 1; color: var(--prep-art-ink); font-weight: 400;
  background: var(--prep-art-heading) center / 100% auto no-repeat; pointer-events: none;
  text-shadow: 0 1px 2px #000;
}
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-skill-cell { padding: 0; min-width: 0; align-items: center; }
:root[data-ui-theme='black-gold'] body.prep-art-active.preparation-dashboard #prep-skills-grid .cmd-slot { border: 0; border-radius: 0; background: transparent; border-image: var(--prep-art-slot) 12 fill / 5px / 0 stretch; padding: 5px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid .cmd-slot img { border-radius: 0; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid .cmd-slot.unlearned { border-image-source: var(--prep-art-slot); filter: saturate(0); }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid .prep-skill-name { font-size: clamp(10px,1.4vw,14px); color: var(--prep-art-ink); width: 110%; top: calc(100% + 9px); overflow: hidden; text-overflow: ellipsis; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid .cmd-key { left: -4px; top: -5px; padding: 2px 5px; background: var(--prep-art-level) center / 100% 100% no-repeat; font: 16px/20px 'RD Prep Serif',serif; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid .skill-level-badge { top: auto; bottom: -7px; left: 50%; transform: translateX(-50%); min-width: 36px; padding: 1px 5px; background: var(--prep-art-level) center / 100% 100% no-repeat; border: 0; font: 11px/16px 'RD Prep Serif',serif; }
:root[data-ui-theme='black-gold'] body.prep-art-active.preparation-dashboard #prep-skills-grid .skill-learn-plus { top: -33px; left: auto; right: -10px; transform: none; width: 44px; height: 44px; background: transparent; border-image: none; font-size: 27px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host {
  position: relative; flex: 0 0 92px; padding: 20px 12px 10px;
  background: #080c10d9 var(--prep-art-stone) center / 180px 132px repeat;
  border-image: var(--prep-art-panel) 48 / 13px / 0 stretch;
}
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host > .prep-art-title { left: 72px; width: 116px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host .console-center { max-width: none; position: static; height: 100%; border-image: none; background: transparent; gap: 0; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host .inventory-sidebar { position: absolute; right: 10px; top: -22px; z-index: 3; height: 44px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host #btn-toggle-destroy {
  position: relative; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-width: 88px; min-height: 44px; padding: 6px 8px; font-size: 12px;
  background: transparent; border-image: none;
}
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host #btn-toggle-destroy::before {
  content: ''; flex: 0 0 14px; width: 14px; height: 16px; background: currentColor;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 26' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 6h18M8 6V3h8v3M5 6l1 17h12l1-17M10 10v9M14 10v9'/%3E%3C/svg%3E") center / contain no-repeat;
}
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host #btn-toggle-destroy::after {
  content: ''; position: absolute; inset: 6px 0; z-index: -1;
  border-image: var(--prep-art-neutral) 12 fill / 5px / 0 stretch;
}
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host #btn-toggle-destroy.active { color: #ffe2d1; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host #btn-toggle-destroy.active::after { outline: 1px solid #df9170; outline-offset: -4px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host #inventory-grid { grid-template-columns: repeat(6,minmax(0,1fr)); grid-template-rows: 1fr; gap: 4px; height: 100%; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host .inv-slot { min-width: 0; min-height: 44px; aspect-ratio: auto; height: 100%; border: 0; border-image: var(--prep-art-slot) 12 fill / 4px / 0 stretch; padding: 4px; background: #04070a; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host .inv-slot img { max-width: 100%; max-height: 100%; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-next-round {
  position: absolute; left: auto; width: 26.5vw; right: calc(var(--prep-padding-inline) + var(--rd-safe-area-right,0px));
  top: calc(var(--prep-padding-block) + var(--rd-safe-area-top,0px) + 58px);
  bottom: calc(var(--prep-padding-block) + var(--rd-safe-area-bottom,0px)); gap: 6px;
}
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-challenges { display: flex; flex-direction: column; flex: 0 0 auto; gap: 4px; padding: 5px 7px; background: #070c12e8; border-image: var(--prep-art-panel) 48 / 9px / 0 stretch; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-challenge-count-control { grid-template-columns: minmax(0,1fr) 44px 44px; gap: 3px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-challenge-summary { padding: 0 2px; font-size: 13px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-art-conditions { display: flex; gap: 4px; flex-wrap: nowrap; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-art-conditions[hidden] { display: none; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-art-conditions button { flex: 1 1 0; padding: 4px 3px; min-width: 44px; font-size: 11px; line-height: 14px; white-space: normal; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-wave-panel { display: flex; flex-direction: column; flex: 1; min-height: 0; gap: 5px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard #prep-next-boss { order: -1; flex: 0 0 auto; text-align: center; font-size: 13px; line-height: 1.35; min-height: 27px; padding: 4px 7px; background: var(--prep-art-neutral) center / 100% 100% no-repeat; color: var(--prep-art-ink); }
#prep-art-stage[hidden], .prep-art-title[hidden] { display: none !important; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-art-stage { position: relative; display: flex; align-items: end; justify-content: center; flex: 1; min-height: 30px; margin: 0; padding: 12px 6px 15px; gap: 0; background: #0b1725 var(--prep-art-stage) center / cover no-repeat; border-image: var(--prep-art-panel) 48 / 12px / 0 stretch; pointer-events: none; overflow: hidden; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-unit { position: relative; display: flex; align-items: center; justify-content: flex-end; flex-direction: column; height: 100%; min-width: 0; flex: 1; padding-bottom: 13px; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-unit img { width: 100%; height: 100%; object-fit: contain; object-position: center bottom; filter: drop-shadow(1px 5px 3px #0009); }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-minion { flex: .64; height: 62%; }
:root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-unit span { position: absolute; bottom: -2px; left: -3px; right: -3px; text-align: center; font-size: 10px; line-height: 13px; color: #fff0b5; text-shadow: 0 1px 3px #000,1px 1px 2px #000; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard #btn-banner-start-wave { flex: 0 0 54px; width: 100%; min-height: 54px; padding: 6px; background: transparent; border-image: var(--prep-art-primary) 20 fill / 10px / 0 stretch; font-size: clamp(16px,2.1vw,21px); }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard #btn-banner-start-wave:is(:active,:disabled) { border-image-source: var(--prep-art-primary); }
:root[data-ui-theme='black-gold'] body.prep-art-active #theme-preview-bar { top: auto; bottom: calc(var(--rd-safe-area-bottom,0px) + 12px); left: 54%; right: 29%; transform: none; max-width: none; font-size: 9px; padding: 2px; background: #06101ac9; text-align: center; }
@media (max-width: 740px) and (orientation: landscape) {
  :root[data-ui-theme='black-gold'] body.prep-art-active.preparation-dashboard #prep-dashboard { --prep-padding-inline: 9px; --prep-padding-block: 8px; grid-template-rows: 46px 44px minmax(0,1fr); gap: 5px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-dashboard-header { gap: 7px; padding: 5px 8px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-identity { min-width: 93px; gap: 5px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-identity img { width: 30px; height: 30px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-identity strong { font-size: 12px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-vitals { min-width: 85px; flex-basis: 105px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-core-stats { min-width: 149px; font-size: 10px; gap: 2px 6px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-economy { gap: 7px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-economy b { font-size: 16px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-economy span { font-size: 11px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-shortcuts { gap: 3px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard .prep-shortcuts button { padding: 4px 3px; font-size: 10px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-shop-shortcut::after { margin-left: 0; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-shop-shortcut svg { width: 14px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-dashboard-body { width: 53.2%; gap: 22px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid { padding: 25px 10px 22px; gap: 4px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host { flex-basis: 83px; padding: 20px 10px 9px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-next-round { left: auto; top: calc(var(--prep-padding-block) + var(--rd-safe-area-top,0px) + 51px); }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-challenges { padding: 4px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-challenge-summary { font-size: 11px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-art-conditions button { font-size: 10px; padding: 3px; }
}
@media (max-height: 340px) and (orientation: landscape) {
  :root[data-ui-theme='black-gold'] body.prep-art-active.preparation-dashboard #prep-dashboard { --prep-skill-size: 44px; --prep-padding-block: 6px; grid-template-rows: 44px 44px minmax(0,1fr); gap: 4px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-dashboard-body { gap: 20px; padding-top: 5px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid { padding: 20px 9px 20px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-inventory-host { flex-basis: 74px; padding-top: 18px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-skills-grid .prep-skill-name { top: calc(100% + 7px); }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-title { font-size: 14px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard #btn-banner-start-wave { flex-basis: 46px; min-height: 46px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-dashboard #prep-next-boss { font-size: 11px; min-height: 24px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active.preparation-dashboard #prep-skills-grid .skill-learn-plus { top: -9px; right: -13px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active #prep-art-stage { padding: 3px 4px 12px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-unit { padding-bottom: 9px; }
  :root[data-ui-theme='black-gold'] body.prep-art-active .prep-art-unit span { font-size: 9px; line-height: 10px; }
}

:root[data-ui-theme='black-gold'] body.prep-art-active #prep-chosen-talents { position: relative; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-chosen-talents:has(#prep-talent-pending:not([hidden])) { padding-bottom: 13px; }
:root[data-ui-theme='black-gold'] body.prep-art-active #prep-talent-pending { position: absolute; bottom: 3px; left: 0; right: 0; margin: 0; padding: 0; background: none; font-size: 9px; line-height: 10px; color: #ffe196; }
