@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/inter-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("assets/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FFFD;
}
@font-face {
  font-family: Gilroy;
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("assets/Gilroy-SemiBold.ttf") format("truetype");
}
@font-face {
  font-family: MinefiteIcons;
  font-display: block;
  src: url("assets/minefite.woff") format("woff");
}
:root {
  color-scheme: dark;
  --bg: #181a20;
  --panel: #23262f;
  --raised: #2d3039;
  --line: #383c47;
  --muted: #b1b5c1;
  --text: #f6f7fa;
  --brand: #e2b53a;
  --brand-text: #15161a;
  --green: #a5d2aa;
  --red: #ffb0a8;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, Arial, sans-serif;
  --display: Gilroy, Inter, Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; color: var(--text); background: var(--bg); font: 16px/1.55 var(--sans); }
main { flex: 1; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .55; cursor: not-allowed; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
.wrap { width: min(1240px, calc(100% - 64px)); margin-inline: auto; }
.shop-entrance {
  position: fixed;
  z-index: 50;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse at 50% 48%, #2b251d 0, #191a20 32%, #15171d 68%);
  transition: opacity 160ms ease-out, visibility 0s;
}
.shop-entrance[data-phase="ready"] {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition-delay: 0s, 160ms;
}
.shop-entrance[data-phase="leaving"] { transition-duration: 110ms, 0s; }
.shop-entrance:is([data-phase="loading"], [data-phase="leaving"]) {
  animation: shop-entrance-timeout 200ms ease-out 5s forwards;
}
.shop-entrance-inner { display: grid; justify-items: center; gap: 20px; }
.shop-entrance img { width: min(200px, 44vw); height: auto; }
.shop-entrance-trace {
  display: block;
  position: relative;
  width: 92px;
  height: 2px;
  overflow: hidden;
  border-radius: 2px;
  background: #b28b4540;
}
.shop-entrance-trace::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, #da993e, #ffe2a0, #da993e, transparent);
}
.shop-entrance:not([data-phase="ready"]) .shop-entrance-inner {
  animation: shop-entrance-logo 250ms cubic-bezier(.2,.7,.25,1) both;
}
.shop-entrance:not([data-phase="ready"]) .shop-entrance-trace::after {
  animation: shop-entrance-trace 760ms cubic-bezier(.25,.65,.35,1) both;
}
@keyframes shop-entrance-logo {
  from { transform: translateY(5px) scale(.97); }
  to { transform: none; }
}
@keyframes shop-entrance-trace {
  from { transform: translateX(-100%); }
  56% { transform: translateX(0); }
  to { transform: translateX(100%); }
}
@keyframes shop-entrance-timeout {
  to { opacity: 0; visibility: hidden; }
}
.topbar { background: #0d0d10; border-bottom: 1px solid #252831; position: relative; z-index: 1; }
.topbar-inner { width: min(1370px, calc(100% - 64px)); min-height: 88px; margin: auto; display: flex; align-items: center; gap: 44px; }
.brand { flex: 0 0 150px; }
.brand img { width: 150px; height: auto; max-height: 50px; object-fit: contain; }
.main-nav, .top-actions, .footer nav { display: flex; align-items: center; gap: 24px; }
.main-nav { align-self: stretch; }
.main-nav > a { display: flex; align-items: center; gap: 9px; color: var(--text); font-size: 1rem; white-space: nowrap; }
.site-icon { display: inline-block; flex: none; font: 18px/1 MinefiteIcons; }
.chevron { font-size: 12px; }
.main-nav > a:hover, .top-link:hover { color: var(--brand); }
.shop-rank-link { white-space: nowrap; }
.shop-rank-link svg { width: 20px; height: 20px; flex: none; }
.top-actions { margin-left: auto; gap: 16px; }
.top-link { display: flex; align-items: center; gap: 9px; border: 0; padding: 6px 0; background: transparent; color: var(--text); white-space: nowrap; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 10px 16px; min-height: 44px; border: 1px solid var(--line); border-radius: 12px; background: #242731; color: var(--text); font-weight: 600; text-align: center; }
.button:hover { border-color: #555c6a; background: #313541; }
.button-gold { background: #e2b53a; color: var(--brand-text); border-color: #e2b53a; }
.button-gold:hover { background: #f0ca63; color: #15161a; }
.button-small { min-height: 38px; padding: 7px 13px; font-size: .92rem; }
.cart-count { display: inline-grid; place-items: center; min-width: 21px; height: 21px; border-radius: 50%; background: #333845; color: #f6f7fa; font-size: .78rem; }
#floating-cart { position: fixed; right: max(17px, env(safe-area-inset-right));
  bottom: max(17px, env(safe-area-inset-bottom)); z-index: 4; width: 53px; height: 53px; border-radius: 15px;
  padding: 0; display: grid; place-items: center; box-shadow: 0 6px 24px #08090b88; }
#floating-cart .cart-count { position: absolute; top: -5px; right: -5px; padding-inline: 4px; box-shadow: 0 0 0 2px #181a20; }
#cart-toast { position: fixed; z-index: 6; width: max-content; max-width: min(335px, calc(100% - 24px));
  padding: 10px 13px; border: 1px solid #89703d; border-radius: 10px; color: #fbf3dd; background: #332b20;
  box-shadow: 0 7px 28px #08090b88; font-size: .88rem; overflow-wrap: anywhere; pointer-events: none; }
.realm-picker { position: relative; isolation: isolate; }
.realm-picker::before { content: ""; position: absolute; z-index: -1; inset: 0 0 auto; margin-inline: auto;
  width: min(610px, calc(100% - 32px)); height: 64px; pointer-events: none;
  background: radial-gradient(ellipse 50% 100% at center top, #0c0d1099 16%, #0c0d1070 44%, #0c0d1028 74%, transparent 100%); }
.realm-picker > summary { position: relative; z-index: 1; display: flex; align-items: center; justify-content: center;
  gap: 12px; width: fit-content; min-height: 44px; margin: -1px auto 0; padding: 6px 20px; list-style: none;
  border: 1px solid var(--line); border-top: 0; border-radius: 0 0 12px 12px; background: #0d0d10;
  font-size: .92rem; font-weight: 600; cursor: pointer; }
.realm-picker > summary::-webkit-details-marker { display: none; }
.realm-picker > summary::after { content: ""; width: 7px; height: 7px; border: solid var(--brand);
  border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); transition: transform 220ms ease; }
.realm-picker[open] > summary::after { transform: translateY(2px) rotate(225deg); }
.realm-picker > summary:hover { color: var(--brand); }
.realm-row { display: grid; grid-template-columns: repeat(2, minmax(0, 286px)); justify-content: center; gap: 14px; padding: 14px 0 4px; }
.realm { text-align: left; border: 1px solid #5c626d; height: 96px; border-radius: 14px; color: #f6f7fa; overflow: hidden; padding: 0 18px; position: relative; isolation: isolate; background: #2d3039; }
.realm::before { content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, #141722 12%, #1c202bf0 44%, #24263330 82%),
    var(--realm-image, url("assets/mirtan-shop.webp")) var(--realm-focus, center 42%) / cover no-repeat; }
.realm[data-realm="anthalor"] { --realm-image: url("assets/anthalor-shop.webp"); --realm-focus: center 64%; }
.realm:hover, .realm[aria-pressed="true"] { border-color: #e2b53a; box-shadow: inset 0 0 0 1px #e2b53a88; }
.realm[aria-pressed="true"]::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); position: absolute; inset: 16px 15px auto auto; box-shadow: 0 0 12px #e2b53a; }
.realm strong { display: block; font: 700 1.95rem/1.05 var(--serif); }
.realm small { display: block; margin-top: 7px; color: #dcdee5; font-size: .85rem; }
#fundraiser-slot { width: min(270px, calc(100% - 32px)); margin: 16px 16px 0 auto; }
.fundraiser-card { --fundraiser-red: #ff9a9e; border: 1px solid #8e4d55; border-radius: 15px;
  background: #251c23; box-shadow: 0 7px 26px #0b080d6e, 0 0 28px #cf4a5720; }
.fundraiser-card > summary { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 9px 14px;
  border-radius: 14px; cursor: pointer; list-style: none; color: #ffe2e3; font-weight: 650;
  background: linear-gradient(105deg, #74323f 0%, #4a2733 65%, #3a232d); }
.fundraiser-card > summary::-webkit-details-marker { display: none; }
.fundraiser-card > summary::before { content: ""; width: 7px; height: 7px; flex: none; border-radius: 50%;
  background: var(--fundraiser-red); box-shadow: 0 0 10px #ff8a96a6; }
.fundraiser-card > summary::after { content: ""; width: 8px; height: 8px; margin-left: auto; flex: none;
  border: solid #ffc1c4; border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); transition: transform 220ms ease; }
.fundraiser-card > summary:hover { background: linear-gradient(105deg, #873b49, #4a2733); }
.fundraiser-card[open] > summary { border-radius: 14px 14px 0 0; border-bottom: 1px solid #7f444d; }
.fundraiser-card[open] > summary::after { transform: translateY(2px) rotate(225deg); }
@supports (interpolate-size: allow-keywords) and selector(details::details-content) {
  @media (prefers-reduced-motion: no-preference) {
    :is(.realm-picker, .fundraiser-card)::details-content {
      interpolate-size: allow-keywords; block-size: 0; overflow: clip; opacity: 0;
      transition: block-size 230ms cubic-bezier(.2,.75,.25,1), opacity 180ms ease, content-visibility 230ms allow-discrete;
    }
    :is(.realm-picker, .fundraiser-card)[open]::details-content { block-size: auto; opacity: 1; }
  }
}
.fundraiser-body { padding: 13px 15px 14px; }
.fundraiser-heading { display: flex; gap: 10px; justify-content: space-between; align-items: start; margin-bottom: 12px; }
.fundraiser-heading h2 { font: 600 1.1rem/1.2 var(--display); overflow-wrap: anywhere; }
.fundraiser-info { display: grid; place-items: center; flex: 0 0 28px; width: 28px; height: 28px; border: 1px solid #9c6671;
  border-radius: 50%; color: #ffc2c6; background: #422b37; font: 700 .92rem var(--serif); }
.fundraiser-info:hover { color: #fff; background: #6c3947; }
.fundraiser-total, .fundraiser-target { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.fundraiser-total { font-size: .85rem; color: #e3cbd0; }
.fundraiser-total strong { color: #ffd1d3; }
.fundraiser-target { margin-top: 5px; color: #d5b7c1; font-size: .79rem; }
.fundraiser-target strong { color: #f6e1e5; }
.fundraiser-pay { width: 100%; min-height: 36px; margin-top: 12px; color: #ffe1e2;
  border-color: #8e4d55; background: #5b2d39; }
.fundraiser-pay:hover { border-color: #db8792; background: #753945; }
.fundraiser-ranking { width: 100%; min-height: 34px; margin-top: 7px; padding: 6px; color: #f6d6db; border-color: #73535d; background: transparent; font-size: .82rem; }
.fundraiser-ranking:hover { background: #483039; }
.fundraiser-paused { margin-top: 9px; color: #efbbbf; font-size: .8rem; }
.fundraiser-meter { display: block; appearance: none; width: 100%; height: 8px; margin: 7px 0 0;
  border: 0; border-radius: 20px; background: #503640; color: #e97583; }
.fundraiser-meter::-webkit-progress-bar { background: #503640; border-radius: 20px; }
.fundraiser-meter::-webkit-progress-value { background: linear-gradient(90deg, #b7465d, #ff9b9d); border-radius: 20px; }
.fundraiser-meter::-moz-progress-bar { background: linear-gradient(90deg, #b7465d, #ff9b9d); border-radius: 20px; }
.fundraiser-note { margin-bottom: 0; }
.fundraiser-note a { color: var(--brand); text-decoration: underline; }
#fundraiser-pay-status { margin-top: 12px; }
@media (min-width: 1760px) {
  .shop-content { position: relative; }
  #fundraiser-slot:not([hidden]) { position: absolute; inset: 28px 16px 0 auto;
    width: min(270px, calc((100% - 1240px) / 2 - 36px)); margin: 0; }
  .fundraiser-card { position: sticky; top: 16px; }
}
@media (max-width: 410px) {
  #fundraiser-slot { width: calc(100% - 22px); margin-right: 11px; }
}
.catalog { padding: 12px 0 72px; }
.catalog-head, .section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; margin: 16px 0 19px; }
.catalog-head h1, .section-head h1 { font: 600 clamp(2rem, 3.6vw, 2.8rem)/1.1 var(--display); }
.catalog-tools { display: flex; align-items: center; flex: 0 1 450px; justify-content: flex-end; gap: 9px; min-width: 0; }
#fitting-trigger { flex: none; white-space: nowrap; padding-inline: 16px; min-height: 44px;
  box-shadow: 0 4px 18px #e2b53a3d; border-color: #f6d576; }
#fitting-trigger:hover { box-shadow: 0 5px 24px #e2b53a60; }
#fitting-trigger img { width: 23px; height: 23px; }
.catalog-head p, .section-head p, .muted { color: var(--muted); }
.search { max-width: 275px; width: 100%; }
input:not([type=checkbox]), select, textarea { width: 100%; border: 1px solid #454b59; border-radius: 10px; color: var(--text); background: #171920; padding: 9px 12px; min-height: 42px; }
input::placeholder { color: #aeb4c3; }
textarea { min-height: 100px; resize: vertical; }
select { padding-right: 13px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 17px; }
.pill { border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--muted); padding: 6px 13px; font-size: .9rem; }
.pill:hover { border-color: #737b8e; }
.pill[aria-pressed="true"] { color: #f2cf6e; border-color: #927c42; background: #353022; }
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px 22px; }
.product { display: flex; flex-direction: column; min-width: 0; }
.product-art { display: block; position: relative; isolation: isolate; width: 100%; aspect-ratio: 1; overflow: hidden; border-radius: 18px; background: #252932 url("assets/background.png") center / cover; color: var(--text); }
.product-art[data-server="anthalor"] { background-image: url("assets/yellow_castle.png"); }
.product-art > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; background: #191c22; z-index: 1; }
.product-art > .gem-original { inset: 22%; width: 56%; height: 56%; object-fit: contain; background: none; image-rendering: pixelated; }
.product-art:is(:hover,:focus-visible) { box-shadow: 0 0 0 1px #d6ad5266, 0 10px 24px #0b0c114a; }
.product-art .fallback { display: grid; place-items: center; position: absolute; inset: 0; padding: 15px; background: linear-gradient(0deg,#11131bba,#20263415); color: #f6f7fa; text-shadow: 0 2px 10px #000; font: 700 1.55rem var(--serif); }
.product-art .sale-badge { position: absolute; z-index: 2; top: 10px; left: 10px; border-radius: 4px; padding: 2px 7px; background: #7b3f43; color: #fff; font-size: .85rem; }
.product-body { padding: 12px 2px 0; display: grid; gap: 6px; flex: 1; grid-template-rows: auto 1fr auto auto; }
.product-meta { color: var(--brand); font-size: .81rem; }
.product-title { place-self: start; position: relative; text-align: left; color: var(--text); font: 600 1.12rem/1.25 var(--sans); border: 0; background: transparent; padding: 0; }
.product-title:hover { text-decoration: underline; }
.product-hint { position: absolute; z-index: 3; visibility: hidden; pointer-events: none; width: max-content;
  padding: 5px 10px; border: 1px solid #565b69; border-radius: 8px; background: var(--panel);
  color: var(--text); box-shadow: 0 4px 12px #0b0c1188; font: 600 .8rem/1.3 var(--sans); }
.product-art > .product-hint { inset: auto auto 10px 50%; transform: translateX(-50%); }
.product-title > .product-hint { inset: auto auto calc(100% + 5px) 0; }
:is(.product-art, .product-title):focus-visible > .product-hint { visibility: visible; }
@media (hover: hover) {
  :is(.product-art, .product-title):hover > .product-hint { visibility: visible; }
}
.product-prices { display: flex; align-items: baseline; flex-wrap: wrap; min-height: 25px; gap: 4px 8px; }
.product-prices .price { font-size: 1.1rem; }
.product-actions { display: flex; flex-wrap: wrap; gap: 7px; }
.product-actions > .button { min-height: 38px; padding: 7px 10px; line-height: 1.2; font-size: .86rem; }
.product-actions > :first-child { flex: 1 0 auto; }
.product-actions > [data-action="fit"] { flex: 1 0 auto; }
:is(.product-actions, .xp-picker) > [data-action="add"] { border-color: #8c7442; }
:is(.product-actions, .xp-picker) > [data-action="add"]:hover { border-color: var(--brand); }
.collection-card .product-actions > .button { border-color: #c8cbd3; }
.collection-card .product-actions > .button:hover { border-color: var(--text); }
.price { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.old-price { display: block; text-decoration: line-through; font-size: .79rem; color: var(--muted); }
.empty, .loading { padding: 35px 18px; color: var(--muted); }
.empty { border: 1px dashed var(--line); border-radius: 14px; text-align: center; }
.footer { border-top: 1px solid var(--line); background: #0f1014; color: var(--muted); }
.footer-inner { display: flex; justify-content: space-between; align-items: center; min-height: 85px; gap: 16px; }
.footer a:hover { color: var(--brand); }
dialog { padding: 0; width: min(680px, calc(100% - 36px)); max-height: 88vh; background: #23262f; color: var(--text); border: 1px solid #454b59; border-radius: 20px; box-shadow: 0 24px 100px #000a; }
dialog::backdrop { background: #0d0f15b8; backdrop-filter: blur(4px); }
.dialog-content { padding: 23px; }
.dialog-head { display: flex; justify-content: space-between; align-items: start; gap: 12px; margin-bottom: 18px; }
.dialog-head h2 { font: 600 1.65rem/1.1 var(--display); }
.close { border: 1px solid var(--line); background: #242731; color: var(--text); border-radius: 10px; width: 33px; height: 33px; font-size: 1.2rem; }
.winter-coupon-trigger { display: inline-flex; align-items: center; gap: 6px; }
.winter-coupon-trigger svg { color: #e7b947; flex: none; }
.winter-coupon-form { display: grid; gap: 13px; }
.winter-coupon-form label { display: grid; gap: 5px; }
.winter-coupon-form [role="status"]:empty { display: none; }
.winter-coupon-form .winter-coupon-balance { display: flex; align-items: center; justify-content: space-between; padding: 10px 13px; border: 1px solid var(--line); border-radius: 10px; }
.winter-coupon-balance strong { color: var(--brand); font-size: 1.25rem; }
.winter-coupon-admin { display: grid; gap: 16px; }
.winter-inline-field { display: flex; flex-wrap: wrap; gap: 8px; }
.winter-inline-field input { flex: 1; min-width: 135px; }
.winter-code-list { display: grid; gap: 8px; }
.winter-code-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; padding: 8px 11px; border: 1px solid var(--line); border-radius: 10px; overflow-wrap: anywhere; }
.winter-coupon-status { color: var(--muted); }
.winter-coupon-status[data-active="true"] { color: #3d7446; }
.winter-cart-wallet { display: grid; gap: 8px; padding: 11px; border: 1px solid var(--line); border-radius: 10px; }
.winter-cart-wallet[hidden] { display: none; }
.winter-wallet-checkout { display: flex; align-items: end; flex-wrap: wrap; gap: 7px; }
.winter-wallet-checkout label { display: grid; gap: 4px; }
.winter-wallet-checkout input { width: 108px; }
.dialog-art { height: min(36vw, 270px); aspect-ratio: auto; border-radius: 10px; margin-bottom: 15px; }
.dialog-art img { object-fit: contain; background: #191c22; }
.dialog-description { white-space: pre-wrap; margin: 0 0 14px; color: #d6d9e3; overflow-wrap: anywhere; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }
.field { display: grid; align-content: start; gap: 5px; font-size: .92rem; }
.wide { grid-column: 1 / -1; }
.field input[type=checkbox] { align-self: center; }
.dialog-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.dialog-actions .price { margin-right: auto; align-self: center; }
.stack { display: grid; gap: 12px; }
.icon-button { display: inline-grid; place-items: center; border: 1px solid var(--line); border-radius: 10px; background: transparent; color: var(--muted); width: 34px; height: 34px; padding: 0; font-size: 1.2rem; line-height: 1; }
.icon-button:hover { color: var(--text); background: var(--raised); }
.button-danger { color: #fff; background: #a52623; border-color: #a52623; }
.button-danger:hover { color: #fff; background: #851e1b; border-color: #851e1b; }
#character-modal { width: min(840px, calc(100% - 8px)); height: min(710px, 93dvh); max-height: none; background: transparent; border: 0; box-shadow: none; }
#character-modal iframe { display: block; width: 100%; height: 100%; border: 0; }
#fitting-drawer { position: fixed; inset: 16px 16px auto auto; margin: 0; width: min(400px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; overflow-y: auto; }
#fitting-drawer[open] { animation: fitting-drawer-in .24s ease-out both; }
#fitting-drawer::backdrop { backdrop-filter: blur(2px); }
#fitting-drawer .fitting { position: static; border: 0; border-radius: 0; }
#fitting-drawer .fitting-heading { padding: 19px 59px 0 19px; }
#fitting-drawer .fitting-controls { padding-inline: 19px; }
#fitting-drawer .fitting-stage { height: clamp(190px, 42vh, 380px); }
.fitting-close { position: absolute; right: 13px; top: 16px; z-index: 3; }
.cart-flight { position: fixed; z-index: 20; pointer-events: none; display: block; border: 2px solid var(--brand); border-radius: 12px; object-fit: cover; box-shadow: 0 4px 24px #0009; }
.realm-login { display: flex; align-items: flex-start; gap: 15px; padding: 14px; border: 1px solid #665332; border-radius: 12px; background: #2c2820; }
.realm-login .category-icon { width: 34px; height: 34px; }
.account-needs-login { background: #242127; color: #f2ca64; border-color: #745b2c; }
.account-needs-login:hover { background: #343027; color: #ffe196; }
#modal[data-dialog-type="cart"] { width: min(860px, calc(100% - 30px)); }
#cart-item-modal { width: min(590px, calc(100% - 34px)); }
.cart-realms { display: flex; gap: 5px; padding: 4px; border-radius: 12px; background: #191b22; margin-bottom: 17px; }
.cart-realms button { flex: 1; min-height: 42px; padding: 8px 10px; border-color: transparent; background: transparent; }
.cart-realms button[aria-pressed="true"] { background: #30333d; border-color: #5d5140; color: #f2cf70; }
.cart-realms button span { display: grid; place-items: center; min-width: 22px; height: 22px; padding-inline: 4px; border-radius: 8px; background: #444754; color: #eef0f4; font-size: .8rem; }
.cart-empty { display: grid; place-items: center; gap: 12px; padding: 30px 15px; border: 1px dashed #4d5260; border-radius: 16px; background: #20222a; text-align: center; }
.cart-empty > strong { font-size: 1.15rem; }
.cart-items { display: grid; gap: 8px; padding: 0; margin: 0 0 16px; list-style: none; }
.cart-row { display: grid; grid-template-columns: minmax(0, 1fr) 113px minmax(72px, auto) 34px; align-items: center; gap: 12px; padding: 10px; background: #292c35; border: 1px solid var(--line); border-radius: 14px; }
.cart-product { display: grid; grid-template-columns: 58px minmax(0, 1fr); align-items: center; gap: 11px; padding: 0; text-align: left; color: var(--text); background: none; border: none; }
.cart-product:hover strong { color: #f2cf70; text-decoration: underline; }
.cart-product span:last-child { min-width: 0; overflow-wrap: anywhere; }
.cart-product small { color: var(--muted); display: block; }
.cart-product-image, .cart-product-image img { display: block; width: 58px; height: 58px; border-radius: 10px; object-fit: cover; }
.cart-product-image { background: #191b22; }
.quantity-stepper { display: grid; grid-template-columns: 30px minmax(0, 1fr) 30px; border: 1px solid #444957; border-radius: 10px; background: #191b22; align-items: stretch; }
.quantity-stepper button { padding: 0; color: var(--text); background: transparent; border: 0; font-size: 1.2rem; }
.quantity-stepper button:hover:enabled { background: var(--raised); }
.quantity-stepper input.quantity { appearance: textfield; min-height: 36px; padding: 0 2px; border-radius: 0; border: 0; border-inline: 1px solid #444957; text-align: center; font-size: .85rem; }
.quantity-stepper input::-webkit-inner-spin-button, .quantity-stepper input::-webkit-outer-spin-button { appearance: none; }
.quantity-locked { text-align: center; color: var(--muted); font-size: .85rem; }
.cart-line-price { text-align: right; }
.cart-remove:hover { color: var(--red); border-color: var(--red); }
.cart-summary { display: grid; gap: 14px; padding: 16px; border: 1px solid var(--line); border-radius: 15px; background: #1c1e26; }
.cart-summary-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
.cart-summary-fields > .button { justify-self: start; }
.cart-recipient, .cart-coupon { display: grid; align-content: start; gap: 9px; min-width: 0; padding: 12px;
  border: 1px solid var(--line); border-radius: 11px; background: #23252e; }
.cart-summary-fields { align-items: stretch; }
.cart-recipient h3, .cart-coupon > label { font-size: .9rem; color: var(--muted); font-weight: 600; }
.cart-recipient > .button { justify-self: start; }
.cart-account, .cart-recipient-actions, .cart-input-action { display: flex; align-items: center; gap: 8px; min-width: 0; }
.cart-account { padding: 7px 8px; background: #191c23; border: 1px solid var(--line); border-radius: 9px; }
.cart-account img { flex: none; border-radius: 7px; image-rendering: pixelated; }
.cart-account span { display: grid; overflow-wrap: anywhere; }
.cart-account small { color: var(--green); }
.cart-recipient-actions { flex-wrap: wrap; }
.cart-input-action :is(input, button) { min-height: 42px; }
.cart-input-action input { min-width: 0; }
.cart-input-action .button { flex: none; }
#gift-lookup { display: grid; gap: 6px; }
#gift-result:empty { display: none; }
.cart-total { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.cart-total .price { font-size: 1.35rem; }
.cart-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
.cart-footer .button { min-height: 42px; }
.cart-empty + .cart-footer { margin-top: 12px; }
.cart-info-button { color: var(--muted); }
.cart-info-button span { font-size: 1.05rem; }
.cart-info-copy { display: grid; gap: 12px; overflow-wrap: anywhere; }
.cart-info-copy :is(a, code) { color: var(--brand); }
.cart-info-copy a { text-decoration: underline; }
.cart-summary > .feedback { margin: 0; min-height: 0; }
.cart-summary > .feedback:empty { display: none; }
.cart-item-details { display: flex; gap: 14px; align-items: center; margin: 0 0 20px; }
.cart-item-details > img { width: 85px; height: 85px; object-fit: cover; border-radius: 12px; }
.notice { position: fixed; bottom: 17px; right: 17px; z-index: 5; width: min(420px, calc(100% - 34px)); color: #f6f7fa; background: #2b303b; border: 1px solid #5c6578; border-radius: 12px; padding: 12px 15px; box-shadow: 0 12px 40px #0009; }
.cart-ranking { display: grid; gap: 8px; margin-top: 13px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 12px; background: #1c1f27; }
.cart-ranking-choice { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.cart-ranking-choice input { width: 17px; height: 17px; min-height: 0; margin: 0; accent-color: var(--brand); }
.cart-ranking-fields { display: grid; gap: 5px; color: var(--muted); font-size: .85rem; }
.cart-ranking-fields small:empty { display: none; }
.ranking-subtitle { margin: 0 0 14px; color: var(--muted); }
.shop-ranking ol { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 9px; margin: 0; padding: 0; list-style: none; }
.shop-ranking-entry { position: relative; isolation: isolate; overflow: hidden; grid-column: span 3; display: flex; align-items: center;
  gap: 9px; min-height: 57px; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.shop-ranking-entry[data-place="1"] { --rank-glow: #ad8231; --rank-light: #f7dc94; --rank-field: #533a18; }
.shop-ranking-entry[data-place="2"] { --rank-glow: #8d9faf; --rank-light: #eff4ff; --rank-field: #3e4a5a; }
.shop-ranking-entry[data-place="3"] { --rank-glow: #ad7148; --rank-light: #ffca9f; --rank-field: #59382e; }
.shop-ranking-entry[data-place]:nth-child(-n+3):is(.shop-ranking-top > *) { flex-wrap: wrap; grid-column: span 2; min-height: 117px;
  align-content: end; padding: 13px; border-color: var(--rank-glow); background: linear-gradient(125deg, #25232b 7%, var(--rank-field)); }
.shop-ranking-top > :nth-child(-n+3)::after { content: ""; position: absolute; z-index: -1; top: -29px; right: -16px; width: 120px; aspect-ratio: 1;
  opacity: .48; border-radius: 50%; background: repeating-radial-gradient(circle at center, transparent 0 10px, var(--rank-glow) 11px 12px, transparent 13px 19px); }
.shop-ranking[data-kind="fundraisers"] .shop-ranking-top > :nth-child(-n+3)::after { border-radius: 37%; transform: rotate(45deg); }
.shop-ranking-place { display: grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 50%;
  color: var(--rank-light, var(--muted)); background: #15151baf; font-weight: 700; font-size: .76rem; }
.shop-ranking-entry img { flex: 0 0 36px; border-radius: 7px; background: #13151b; }
.shop-ranking-person { min-width: 0; overflow-wrap: anywhere; }
.shop-ranking-person small { display: block; color: #d0d0d8; font-size: .72rem; }
.shop-ranking-amount { margin-left: auto; white-space: nowrap; color: var(--rank-light, #f5d778); }
.shop-ranking-top > :nth-child(-n+3) .shop-ranking-amount { width: 100%; padding-left: 2px; font-size: 1.15rem; }
.shop-ranking-more { margin-top: 11px; }
.shop-ranking-more summary { padding: 9px 0; color: var(--brand); cursor: pointer; }
.shop-ranking-more ol { max-height: 50vh; overflow: auto; }
.feedback { color: var(--red); min-height: 1.2em; font-size: .9rem; margin: 7px 0 0; }
.feedback[data-saved] { color: var(--green); }
.admin-shell { width: min(1370px, calc(100% - 64px)); min-height: 76vh; margin: 0 auto; display: grid; grid-template-columns: 208px 1fr; gap: 26px; padding: 24px 0 68px; }
.side { border-right: 1px solid var(--line); padding: 10px 14px 10px 0; }
.side h2 { font: 700 1.45rem var(--serif); margin: 0 0 13px; }
.side nav { display: grid; gap: 6px; }
.side button { padding: 9px 12px; text-align: left; border: 1px solid transparent; border-radius: 10px; color: var(--muted); background: transparent; }
.side button.active, .side button:hover { border-color: #4c515f; color: #f2cf6e; background: #2b303b; }
.admin-body { min-width: 0; }
.fundraiser-admin-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 310px), 1fr)); gap: 16px; }
.fundraiser-admin-card { display: grid; align-content: start; gap: 9px; }
.fundraiser-admin-head { display: flex; align-items: start; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
.fundraiser-admin-head h2 { overflow-wrap: anywhere; }
.fundraiser-status { border-radius: 999px; padding: 3px 9px; background: #f0e9e8; color: #534a4a; font-size: .77rem; }
.fundraiser-status.is-active { background: #f4e0df; color: #702e3d; }
.fundraiser-admin-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 5px; }
.fundraiser-checkbox { display: flex; gap: 8px; align-items: center; align-self: end; min-height: 43px; }
.fundraiser-form-note { margin: 8px 0 10px; }
.panel { border: 1px solid var(--line); border-radius: 14px; padding: 16px; background: var(--panel); margin: 0 0 15px; min-width: 0; }
.panel h2 { margin: 0 0 11px; font: 700 1.4rem var(--serif); }
.fundraiser-admin-head h2 { margin: 0; }
.metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(127px, 1fr)); gap: 9px; margin-bottom: 15px; }
.metric { padding: 12px; background: #292d37; border: 1px solid var(--line); border-radius: 10px; color: var(--muted); font-size: .86rem; }
.metric strong { display: block; color: var(--text); font-size: 1.25rem; font-variant-numeric: tabular-nums; }
.table-wrap { overflow-x: auto; }
.mobile-table-label { display: none; }
table { border-collapse: collapse; width: 100%; text-align: left; font-size: .91rem; }
th, td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { color: var(--muted); font-weight: 500; white-space: nowrap; }
td:last-child, th:last-child { text-align: right; }
tr:last-child td { border-bottom: 0; }
.cell-money, .cell-date { white-space: nowrap; }
.status { color: var(--green); }
.status-off { color: var(--muted); }
.section-filters { display: flex; gap: 10px; align-items: end; flex-wrap: wrap; margin: 0 0 13px; }
.section-filters .field { flex: 1 1 140px; }
.bars { display: grid; grid-template-columns: repeat(auto-fit, minmax(35px, 1fr)); align-items: end; gap: 6px; padding-top: 10px; }
.bar-item { text-align: center; color: var(--muted); font-size: .78rem; display: grid; gap: 2px; }
.bar-item i { display: block; min-height: 2px; background: linear-gradient(0deg,#8f7429,#e2b53a); border-radius: 3px 3px 0 0; }
.option-list { display: grid; gap: 5px; max-height: 190px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; padding: 8px; }
.rule-product-header { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.rule-product-header small { display: block; }
.rule-products { grid-template-columns: repeat(auto-fit, minmax(min(235px, 100%), 1fr)); gap: 8px; max-height: min(310px, 44vh); }
.rule-products .collection-pick { grid-template-columns: auto 48px minmax(0, 1fr); }
.coupon-decay { border: 1px solid var(--line); border-radius: 12px; padding: 10px 13px 13px; min-inline-size: 0; }
.coupon-decay legend { padding-inline: 4px; font-weight: 600; }

body[data-shop-view="admin"] {
  color-scheme: light;
  --bg: #f4f3f0;
  --panel: #fff;
  --raised: #f2f2f2;
  --line: #ddd9d1;
  --muted: #55575b;
  --text: #18191c;
  --brand: #d9a92d;
  --brand-text: #17171a;
  --green: #25633e;
  --red: #a52623;
}
.admin-topbar { background: var(--panel); border-color: var(--line); }
.admin-topbar .topbar-inner { min-height: 72px; gap: 20px; }
.admin-back { display: inline-flex; gap: 8px; align-items: center; color: var(--muted); font-size: .9rem; }
.admin-back:hover { color: var(--text); }
.admin-title { border-left: 1px solid var(--line); padding-left: 20px; font: 600 1.22rem var(--display); }
body[data-shop-view="admin"] .button:not(.button-gold),
body[data-shop-view="admin"] :is(input:not([type=checkbox]), select, textarea, .metric, .close) {
  background: var(--panel);
  border-color: var(--line);
}
body[data-shop-view="admin"] :is(.button:not(.button-gold):hover, .close:hover) { background: var(--raised); }
body[data-shop-view="admin"] input::placeholder { color: var(--muted); }
body[data-shop-view="admin"] .side button:is(.active, :hover) {
  background: #f1e9d2;
  border-color: #e6d7ac;
  color: #49370a;
}
body[data-shop-view="admin"] :is(dialog, .notice) {
  background: var(--panel);
  border-color: var(--line);
  color: var(--text);
}
body[data-shop-view="admin"] .table-wrap { scrollbar-width: thin; }
body[data-shop-view="admin"] .admin-main > .wrap { padding: 26px 0; }
body[data-shop-view="admin"] .admin-shell { gap: 30px; padding-top: 32px; align-items: start; }
body[data-shop-view="admin"] .side { position: sticky; top: 20px; background: #292722; color: #fbf6e9; border: 0; border-radius: 18px; padding: 20px 13px 16px; }
body[data-shop-view="admin"] .side h2 { padding-inline: 10px; font: 600 1.35rem var(--display); }
body[data-shop-view="admin"] .side button { min-height: 44px; color: #e5dfd1; }
body[data-shop-view="admin"] .side button.active { color: #31250d; background: #efd58e; border-color: #efd58e; font-weight: 700; }
body[data-shop-view="admin"] .side button:not(.active):hover { color: #fff; background: #3e3a30; border-color: #514c3f; }
body[data-shop-view="admin"] .section-head { align-items: center; gap: 18px; margin: 16px 0 20px; flex-wrap: wrap; }
body[data-shop-view="admin"] .section-head h1 { letter-spacing: -.026em; }
body[data-shop-view="admin"] .section-head p { margin-top: 5px; }
body[data-shop-view="admin"] .admin-heading-actions > .button { min-height: 44px; padding-inline: 14px; }
body[data-shop-view="admin"] .metrics { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-bottom: 20px; }
body[data-shop-view="admin"] .metric, body[data-shop-view="admin"] .panel { padding: 18px; border-radius: 16px; }
body[data-shop-view="admin"] .metric { border-top: 3px solid #dfc482; }
body[data-shop-view="admin"] .metric strong { font-size: 1.65rem; margin-top: 7px; }
body[data-shop-view="admin"] table { font-size: .94rem; }
body[data-shop-view="admin"] :is(th, td) { padding: 12px; }
body[data-shop-view="admin"] th { background: #f4f1eb; color: #50483a; }
body[data-shop-view="admin"] dialog .dialog-content { padding: clamp(16px, 3vw, 30px); }
body[data-shop-view="admin"] input:focus, body[data-shop-view="admin"] textarea:focus { border-color: #aa771e; }
body[data-shop-view="admin"] .button-danger { background: #a52623 !important; border-color: #a52623 !important; color: #fff; }
body[data-shop-view="admin"] .button-danger:hover { background: #851e1b !important; }

.category-list .pill { display: inline-flex; align-items: center; gap: 8px; padding: 10px 12px; }
.category-list:empty { display: none; }
.catalog > .category-list { margin-bottom: 12px; }
.catalog > .category-list:not(:empty) + #cards { border-top: 1px solid var(--line); padding-top: 12px; }
.category-icon { width: 24px; height: 24px; flex: none; object-fit: contain; }
.category-grid-icon { display: grid; grid-template-columns: repeat(2, 6px); grid-template-rows: repeat(2, 6px); gap: 3px; place-content: center; width: 24px; height: 24px; flex: none; }
.category-grid-icon i { border: 1px solid #f0ca63; border-radius: 2px; background: #a87429; }
.category-list .pill > small { color: var(--muted); font-variant-numeric: tabular-nums; }
.catalog-layout { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 24px; align-items: start; }
.catalog-layout .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.collection-thumbnails { position: absolute; z-index: 2; right: 10px; bottom: 10px; display: flex; padding-left: 8px; }
.collection-thumbnails > span { width: clamp(30px, 3.4vw, 44px); aspect-ratio: 1; display: grid; place-items: center; margin-left: -8px; border: 2px solid #272830; border-radius: 50%; overflow: hidden; background: #353640; color: #fff; box-shadow: 0 2px 6px #101017b0; font-size: .75rem; font-weight: 700; }
.collection-thumbnails img { width: 100%; height: 100%; object-fit: cover; }
.product-page { --detail-gap: clamp(14px, 2vw, 24px); padding-block: 36px 54px; }
.product-page > h1 { margin-bottom: 24px; font: 600 clamp(2rem, 4vw, 3.5rem)/1.15 var(--display); }
.back-to-catalog { display: inline-block; margin-bottom: var(--detail-gap); color: var(--muted); }
.back-to-catalog:hover { color: var(--brand); }
.product-detail-grid { display: grid; grid-template-columns: min(42%, 486px) minmax(0, 1fr); align-items: start; gap: var(--detail-gap); }
.product-detail-art { border: 1px solid var(--line); border-radius: 20px; aspect-ratio: 1; }
.product-detail-art > img { object-fit: cover; }
.product-detail-side { min-width: 0; display: grid; gap: var(--detail-gap); }
.product-detail-side:has(.related-products) { align-self: stretch; grid-template-rows: 1fr auto; }
.product-detail-info { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 10px;
  padding: var(--detail-gap); background: var(--panel); border-radius: 20px; }
.product-detail-info h1 { font: 600 clamp(1.65rem, 3.2vw, 2.65rem)/1.13 var(--display); overflow-wrap: anywhere; }
.product-detail-price { display: flex; align-items: baseline; gap: 11px; font-size: 1.5rem; }
.product-detail-price .old-price { font-size: 1rem; }
.product-detail-actions { display: flex; flex-wrap: wrap; gap: 9px; }
.product-detail-actions .button { padding: 10px 11px; }
.product-detail-actions :is([data-action="fit"], [data-action="item-lore"]) { color: #f7d575; border-color: #8b723b; background: #393121; }
.product-detail-actions :is([data-action="fit"], [data-action="item-lore"]):hover { background: #4c3d24; }
#modal[data-dialog-type="item-lore"] { width: min(820px, calc(100% - 24px)); }
#item-lore-result { display: grid; gap: 12px; }
.item-tooltip {
  min-width: 0; max-width: 100%; overflow-x: auto; padding: 14px;
  border: 1px solid #7955af; border-radius: 9px; background: #181221;
  box-shadow: inset 0 0 0 2px #332447; font: 16px/22px ui-monospace, monospace;
  text-shadow: 2px 2px #0008; scrollbar-width: thin;
}
.item-tooltip h3, .item-tooltip-line { min-height: 1.375em; white-space: pre; font: inherit; }
.item-tooltip h3 { margin-bottom: 5px; }
.lore-scroll-hint { font-size: .85rem; }
.lore-space { display: inline-block; }
.lore-glyph { display: inline-block; max-width: none; margin-right: .125em; image-rendering: pixelated; }
.lore-bold { font-weight: 700; text-shadow: 1px 0 currentColor, 2px 2px #0008; }
.lore-bold > .lore-glyph { filter: drop-shadow(1px 0 currentColor); }
.lore-italic { font-style: italic; }
.lore-italic > .lore-glyph { transform: skewX(-10deg); }
.lore-underlined { text-decoration: underline; }
.lore-strike { text-decoration: line-through; }
.lore-underlined.lore-strike { text-decoration: underline line-through; }
.detail-bottom { margin-top: var(--detail-gap); }
.detail-bottom.catalog-layout { gap: var(--detail-gap); }
.detail-bottom > .panel { padding: var(--detail-gap); }
.detail-bottom .dialog-description a { color: var(--brand); text-decoration: underline; overflow-wrap: anywhere; }
.related-products { min-width: 0; border: 1px solid var(--line); border-radius: 20px; padding: 12px var(--detail-gap) 7px; background: #1f2129; }
.related-heading { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 6px 14px; margin-bottom: 8px; }
.related-heading h2 { font-size: .97rem; overflow-wrap: anywhere; }
.related-heading a { color: var(--brand); font-size: .83rem; }
.related-track { display: grid; grid-auto-flow: column; grid-auto-columns: clamp(96px, 9vw, 122px); gap: 9px; margin: 0; padding: 2px 2px 6px; list-style: none; overflow-x: auto; scrollbar-width: thin; scroll-snap-type: x proximity; }
.related-track li { scroll-snap-align: start; }
.related-track a { display: grid; justify-items: start; grid-template-rows: auto 1fr auto; gap: 4px; height: 100%; padding: 7px; border: 1px solid transparent; border-radius: 9px; background: var(--panel); }
.related-track a:hover { border-color: #a78743; }
.related-thumb { display: grid; place-items: center; width: 100%; aspect-ratio: 1; max-width: 80px; background: var(--raised); border-radius: 7px; overflow: hidden; }
.related-thumb img { width: 100%; height: 100%; object-fit: cover; }
.related-label { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; font-size: .78rem; line-height: 1.3; }
.related-track strong { color: var(--brand); font-size: .82rem; }
.xp-feature { --xp-accent: #82e9d1; --xp-line: #41706b; isolation: isolate; display: grid; align-items: center;
  gap: clamp(18px, 3vw, 42px); padding: clamp(14px, 2.4vw, 34px); border: 1px solid var(--xp-line); border-radius: 23px;
  background: radial-gradient(ellipse at 10% 45%, #254f4d, transparent 65%), linear-gradient(140deg, #1c3235, #182124 75%); }
.xp-catalog-card { grid-column: 1 / -1; grid-template-columns: min(36%, 380px) minmax(0, 1fr); }
.xp-feature .product-art { border: 1px solid #6fbcad75; border-radius: 17px; box-shadow: 0 12px 35px #091819a6; }
.xp-feature-content, .xp-detail .product-detail-info { min-width: 0; display: grid; gap: 9px; }
.xp-detail .product-detail-info { border: 0; padding: 0; border-radius: 0; background: transparent; }
.xp-feature .product-title { font: 650 clamp(1.75rem, 3.3vw, 3rem)/1.05 var(--display); }
.xp-feature-content > p, .xp-detail .product-detail-info > p:not(.product-meta) { color: #c0d4d3; max-width: 60ch; }
.xp-detail .product-meta { color: var(--xp-accent); }
.xp-picker { display: grid; gap: 13px; width: 100%; max-width: 690px; padding: clamp(13px, 2vw, 22px); margin-top: 5px;
  border: 1px solid #416b6588; border-radius: 16px; background: #0f212491; }
.xp-picker-value, .xp-picker-footer { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 7px 12px; }
.xp-picker-value label { display: grid; gap: 5px; color: #c0d4d3; font-size: .85rem; }
.xp-number { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; }
.xp-number input { width: 123px; min-height: 42px; padding: 5px 10px; border-color: var(--xp-line); color: var(--text); background: #16292d; }
.xp-rate { font-size: .81rem; color: var(--xp-accent); }
.xp-picker input[type="range"] { appearance: none; width: 100%; height: 22px; padding: 0; min-height: 0; border: 0; background: transparent; cursor: pointer; }
.xp-picker input[type="range"]::-webkit-slider-runnable-track { height: 6px; border-radius: 6px; background: linear-gradient(to right, var(--xp-accent) var(--xp-progress), #385152 var(--xp-progress)); }
.xp-picker input[type="range"]::-moz-range-track { height: 6px; border-radius: 6px; background: linear-gradient(to right, var(--xp-accent) var(--xp-progress), #385152 var(--xp-progress)); }
.xp-picker input[type="range"]::-webkit-slider-thumb { appearance: none; width: 17px; height: 17px; margin-top: -6px; border-radius: 50%; background: #a9f4e0; box-shadow: 0 0 13px #6ddec6a0; }
.xp-picker input[type="range"]::-moz-range-thumb { width: 17px; height: 17px; border: 0; border-radius: 50%; background: #a9f4e0; }
.xp-picker-labels { display: flex; justify-content: space-between; gap: 6px; color: #b0c6c5; font-size: .76rem; }
.xp-presets { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(95px, 100%), 1fr)); gap: 6px; }
.xp-presets .button { min-height: 37px; padding: 6px; border-color: #345859; color: #dcf0eb; background: #193236; font-size: .8rem; }
.xp-presets .button[aria-pressed="true"], .xp-presets .button:hover { border-color: #80dcca; background: #24524e; }
.xp-picker-footer { align-items: center; padding-top: 11px; border-top: 1px solid #416b6570; }
.xp-picker-footer small { display: block; color: #b0c6c5; }
.xp-picker-footer strong { display: block; font-size: clamp(1.3rem, 3vw, 1.9rem); line-height: 1.15; white-space: nowrap; }
.xp-picker-footer .button { min-height: 44px; padding: 9px 20px; }
.fitting { background: var(--panel); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; position: sticky; top: 16px; }
.fitting-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 15px 0; }
.fitting-heading h2 { font: 600 1.3rem var(--display); }
.fitting-heading .muted { font-size: .88rem; overflow-wrap: anywhere; }
.fitting-stage { height: clamp(180px, 32vh, 300px); position: relative; background: radial-gradient(ellipse at 50% 75%, #42454d, transparent 65%); }
.fitting-stage canvas { display: block; width: 100%; height: 100%; touch-action: pan-y; cursor: grab; }
.fitting-stage canvas:active { cursor: grabbing; }
.fitting-stage::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 50% 57%, #e7bb5359, transparent 65%); opacity: 0; }
.fitting-stage.fitting-equipped::after { animation: fitting-equip .52s ease-out; }
@keyframes fitting-equip { 30% { opacity: .78; } }
@keyframes fitting-drawer-in { from { transform: translateX(22px); opacity: .4; } to { transform: none; opacity: 1; } }
.fitting-status { inset: 45% 12px auto; text-align: center; position: absolute; pointer-events: none; }
.fitting-controls { padding: 0 15px 15px; }
.animation-picker { position: relative; z-index: 2; }
.animation-picker > summary { display: grid; grid-template-columns: minmax(0, 1fr) 12px; gap: 1px 10px; padding: 8px 12px; border: 1px solid #5a5038; border-radius: 12px; background: #191b22; line-height: 1.25; cursor: pointer; list-style: none; }
.animation-picker > summary::-webkit-details-marker { display: none; }
.animation-picker > summary::after { content: ""; grid-area: 1 / 2 / 3 / 3; align-self: center; width: 8px; height: 8px; border-bottom: 2px solid #dfb650; border-right: 2px solid #dfb650; transform: rotate(45deg); }
.animation-picker[open] > summary::after { transform: rotate(225deg); }
.animation-caption { color: var(--muted); font-size: .72rem; }
.animation-picker strong { font-size: .9rem; font-weight: 600; grid-column: 1; }
.animation-options { display: grid; gap: 2px; position: absolute; inset: auto 0 calc(100% + 6px); padding: 5px; background: #191b22; border: 1px solid #514831; border-radius: 12px; box-shadow: 0 12px 25px #0f1018a0; }
.animation-options button { padding: 9px; text-align: left; line-height: 1.25; color: var(--text); background: transparent; border: 0; border-radius: 7px; font-size: .86rem; }
.animation-options button:is(:hover,[aria-pressed="true"]) { background: #343027; color: #f2d188; }
.fitting-worn { margin-top: 12px; font-size: .84rem; }
.fitting-worn h3 { font-size: .87rem; }
.fitting-worn ul { display: grid; gap: 4px; padding: 0; margin: 4px 0 0; list-style: none; max-height: 150px; overflow-y: auto; }
.fitting-worn li { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 4px 4px 4px 8px; border-radius: 8px; background: #191b2270; overflow-wrap: anywhere; }
.fitting-worn .icon-button { flex: none; width: 28px; height: 28px; }
.fitting-components { display: block; margin-top: 2px; }
.profile-section { margin: 0 0 16px; }
.profile-section h3 { padding-bottom: 8px; margin-bottom: 10px; border-bottom: 1px solid var(--line); }
.profile-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 9px; }
.profile-choice { display: grid; justify-items: center; gap: 6px; color: var(--text); background: var(--raised); border: 1px solid var(--line); border-radius: 12px; padding: 11px 8px; overflow-wrap: anywhere; }
.profile-choice[aria-pressed="true"] { border-color: var(--brand); }
.profile-choice > img { width: 58px; height: 58px; image-rendering: pixelated; border-radius: 9px; }
.profile-choice small { font-size: .78rem; color: var(--muted); }
.recent-purchases { padding: 0 0 52px; }
.recent-purchases h2 { font: 600 1.8rem var(--display); }
.recent-track { display: flex; overflow-x: auto; gap: 12px; scrollbar-width: thin; scroll-snap-type: x mandatory; }
.recent-item { display: flex; align-items: center; flex: 0 0 220px; gap: 11px; padding: 9px; border-radius: 13px; background: var(--panel); scroll-snap-align: start; }
.recent-item img { width: 46px; height: 46px; object-fit: cover; border-radius: 8px; }
.recent-controls, .admin-realms { display: flex; gap: 8px; }
.admin-heading-actions { display: flex; flex-wrap: wrap; gap: 8px; }
#modal[data-dialog-type="collections"] { width: min(1060px, calc(100% - 30px)); overflow: hidden; max-height: 90dvh; }
#modal[data-dialog-type="collections"] .dialog-content { display: flex; flex-direction: column; height: min(820px, 90dvh - 2px); }
#collection-editor { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.collection-editor-body { display: grid; grid-template-columns: minmax(230px, 33%) minmax(0, 1fr); align-items: start; gap: 20px; padding: 2px 10px 12px 2px; overflow: auto; scrollbar-width: thin; }
.collection-settings { display: grid; gap: 12px; min-width: 0; }
.collection-settings input[type="file"] { min-width: 0; width: 100%; }
.collection-preview { display: grid; place-items: center; height: 116px; border-radius: 12px; background: var(--raised); color: var(--muted); overflow: hidden; font-size: .85rem; }
.collection-preview img { max-width: 100%; height: 116px; object-fit: contain; }
.collection-product-filters { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; margin-bottom: 12px; }
#collection-count { color: var(--muted); font-size: .9rem; text-align: right; }
.collection-pick-list { display: grid; gap: 7px; }
.collection-pick { display: grid; grid-template-columns: auto 48px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.collection-pick:hover { background: var(--raised); }
.collection-pick:has(:checked) { border-color: #d6b157; background: #fbf3dd; }
.collection-pick strong, .collection-pick small { display: block; overflow-wrap: anywhere; }
.collection-pick small { color: var(--muted); }
.collection-pick-group { max-width: 12ch; text-align: right; }
.collection-pick-thumb { display: grid; place-items: center; width: 48px; aspect-ratio: 1; overflow: hidden; border-radius: 7px; background: #eeebe2; }
.collection-pick-thumb img:not(.category-icon) { width: 100%; height: 100%; object-fit: cover; }
.collection-editor-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 8px; }
.collection-editor-footer .button { margin-left: auto; flex-shrink: 0; }
.collection-editor-footer .feedback { margin: 0; }
.partner-permissions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 16px; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px 14px; margin: 0; min-width: 0; }
.partner-permissions legend { padding: 0 6px; font-weight: 700; }
.partner-permissions label { min-height: 38px; }
.category-editor-list { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.category-editor-list span { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 8px; background: var(--raised); padding: 5px 9px; }
.category-switches { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 14px 0; }
.category-switch { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: 8px;
  min-height: 48px; padding: 7px 11px; border: 1px solid var(--line); border-radius: 9px; cursor: pointer; }
.category-switch:has(:checked) { background: #f8f0db; border-color: #dcc58e; }
.category-switch input { width: 18px; height: 18px; accent-color: #a57408; }
#modal[data-dialog-type="catalog-order"] { width: min(790px, calc(100% - 30px)); overflow: hidden; max-height: 90dvh; }
#modal[data-dialog-type="catalog-order"] .dialog-content { display: flex; flex-direction: column; max-height: calc(90dvh - 2px); }
#catalog-order { display: flex; flex-direction: column; min-height: 0; gap: 12px; }
.order-hint { color: var(--muted); font-size: .92rem; }
.order-list { display: grid; align-content: start; gap: 6px; min-height: 0; margin: 0; padding: 3px 6px 3px 3px; overflow-y: auto; scrollbar-width: thin; list-style: none; }
.order-row { display: grid; grid-template-columns: 29px 30px 42px minmax(0, 1fr) auto; align-items: center; gap: 8px; min-height: 58px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); }
.order-row.order-dragging { opacity: .48; }
.order-row[data-drop="before"] { box-shadow: 0 -3px 0 #c28e25; }
.order-row[data-drop="after"] { box-shadow: 0 3px 0 #c28e25; }
.order-handle { text-align: center; color: #756557; cursor: grab; user-select: none; font-size: 1.38rem; }
.order-handle:active { cursor: grabbing; }
.order-position { color: var(--muted); text-align: center; font-variant-numeric: tabular-nums; font-size: .84rem; }
.order-thumb { display: grid; place-items: center; width: 42px; aspect-ratio: 1; border-radius: 7px; overflow: hidden; background: var(--raised); }
.order-thumb > img:not(.category-icon) { width: 100%; height: 100%; object-fit: cover; }
.order-info { display: grid; min-width: 0; overflow-wrap: anywhere; line-height: 1.27; }
.order-info small { color: var(--muted); margin-top: 3px; }
.order-arrows, .order-footer { display: flex; align-items: center; gap: 6px; }
.order-arrows .icon-button { min-width: 30px; width: 30px; height: 32px; padding: 0; font-size: .95rem; }
.order-footer { flex-wrap: wrap; justify-content: flex-end; padding-top: 10px; border-top: 1px solid var(--line); }
.order-footer .feedback { flex: 1 1 0; margin: 0; }
@media (max-width: 640px) {
  .collection-editor-body, .partner-permissions { grid-template-columns: minmax(0, 1fr); }
  .collection-pick-group { display: none !important; }
  .collection-pick { grid-template-columns: auto 48px minmax(0, 1fr); }
  .order-row { grid-template-columns: 21px 23px 34px minmax(0, 1fr) auto; gap: 5px; padding: 6px 4px; }
  .order-thumb { width: 34px; }
  .order-arrows { gap: 3px; }
}
.admin-realms { display: inline-flex; padding: 4px; border-radius: 14px; border: 1px solid var(--line); background: #eae6dc; }
body[data-shop-view="admin"] .admin-realms .button { min-width: 112px; border-color: transparent; background: transparent; }
body[data-shop-view="admin"] .admin-realms button[aria-pressed="true"] { background: #fff; color: #513b0b; border-color: #ded3b7; box-shadow: 0 3px 8px #51402014; }
.admin-product-filters { padding: 12px; border: 1px solid var(--line); border-radius: 15px; background: var(--panel); margin-bottom: 20px; }
.admin-product-filters .search { max-width: 350px; }
.admin-product-filters select { width: auto; }
.editor-products { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 310px), 1fr)); gap: 16px; }
.editor-product { position: relative; display: grid; grid-template-columns: 90px minmax(0, 1fr); grid-template-rows: 1fr auto; gap: 15px; align-items: start; padding: 14px; border: 1px solid var(--line); border-radius: 17px; background: var(--panel); box-shadow: 0 4px 12px #352a0d0b; }
.editor-product:has(.product-drag-handle) .editor-product-info { padding-right: 34px; }
.product-drag-handle { position: absolute; top: 10px; right: 10px; display: grid; place-items: center; width: 34px; height: 34px;
  border: 1px solid var(--line); border-radius: 8px; background: #f3f0e8; color: #6a5838; font-size: 1.35rem;
  cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; }
.product-drag-handle:is(:hover, :active) { background: #efdfb8; }
.product-drag-handle:active { cursor: grabbing; }
.editor-products[aria-busy="true"] .product-drag-handle { opacity: .65; cursor: progress; }
.editor-product.card-order-dragging { opacity: .48; }
.editor-product[data-card-drop="before"] { box-shadow: -4px 0 #af791c; }
.editor-product[data-card-drop="after"] { box-shadow: 4px 0 #af791c; }
.editor-product[data-card-drop="before-row"] { box-shadow: 0 -4px #af791c; }
.editor-product[data-card-drop="after-row"] { box-shadow: 0 4px #af791c; }
.editor-product[data-status="hidden"] { background: #fbf9f3; }
.editor-product:is([data-status="archived"],[data-status="hidden"]) .editor-product-image img { filter: saturate(.68); }
.editor-product-image { aspect-ratio: 1; display: grid; place-items: center; border-radius: 12px; overflow: hidden; background: #ece9e1; }
.editor-product-image img { width: 100%; height: 100%; object-fit: cover; }
.editor-product-info h3 { font-size: 1.08rem; line-height: 1.25; margin: 6px 0 4px; overflow-wrap: anywhere; }
.admin-product-state { display: inline-flex; gap: 5px; align-items: center; border-radius: 999px; padding: 2px 8px; background: #dcefe3; color: #276040; font-size: .8rem; font-weight: 700; }
.admin-product-state::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
[data-status="hidden"] .admin-product-state { color: #885819; background: #f9ecd3; }
[data-status="archived"] .admin-product-state { color: #5b584f; background: #e8e5dd; }
.admin-product-category { display: flex; gap: 6px; align-items: center; color: var(--muted); font-size: .84rem; }
.admin-product-category .category-icon { width: 17px; height: 17px; }
.admin-product-price { display: block; margin-top: 5px; font-size: 1rem; }
.editor-product-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 7px; align-items: center; margin-top: 1px; padding-top: 12px; border-top: 1px solid var(--line); }
.editor-product-actions .button { min-height: 40px; padding: 7px 11px; font-size: .89rem; }
.product-action-menu { position: relative; margin-left: auto; }
.product-action-menu > summary { display: grid; place-content: center; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); width: 40px; height: 40px; color: var(--text); font-weight: 700; cursor: pointer; list-style: none; }
.product-action-menu > summary::-webkit-details-marker { display: none; }
.product-action-menu[open] > div { display: grid; min-width: 145px; z-index: 2; position: absolute; right: 0; top: 45px; border: 1px solid var(--line); border-radius: 11px; background: var(--panel); box-shadow: 0 6px 16px #2c211b22; padding: 4px; }
.product-action-menu button { border: 0; border-radius: 8px; background: transparent; text-align: left; color: var(--text); padding: 8px; }
.product-action-menu button:hover { background: var(--raised); }
.product-action-menu .danger-text { color: var(--red); }
.editor-category { position: relative; }
.editor-category .category-icon { position: absolute; top: 9px; left: 9px; pointer-events: none; }
.editor-category select { padding-left: 40px; }
dialog:has(#editor[data-section="products"]) { width: min(960px, calc(100% - 30px)); }
.editor-pane { padding: 16px; border: 1px solid var(--line); border-radius: 12px; min-width: 0; }
.editor-pane :is(h3, summary) { font-size: 1.05rem; font-weight: 600; margin: 0 0 13px; }
.editor-pane summary { cursor: pointer; }
.editor-pane:not([open]) > summary { margin-bottom: 0; }
[data-quantity-settings] { min-width: 0; padding: 0; margin: 0; border: 0; }
.editor-footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.editor-footer .dialog-actions, .editor-footer .feedback { margin: 0; }
.editor-footer .dialog-actions { margin-left: auto; }
.editor-footer .feedback:empty { display: none; }
.editor-preview { max-height: 125px; margin: 0 auto 12px; border-radius: 8px; }
.rich-field { display: grid; gap: 6px; }
.rich-editor { border: 1px solid var(--line); border-radius: 13px; }
.rich-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; padding: 7px 8px; background: #f5f2eb; border-radius: 12px 12px 0 0; border-bottom: 1px solid var(--line); }
.rich-toolbar > div { display: flex; align-items: center; gap: 2px; padding-right: 6px; border-right: 1px solid var(--line); }
.rich-toolbar button { border: 0; border-radius: 7px; min-width: 34px; min-height: 34px; background: transparent; color: #302c24; font-size: .9rem; }
.rich-toolbar button:hover { background: #e9dfca; }
.rich-color { display: flex; align-items: center; font-size: .82rem; gap: 5px; }
body[data-shop-view="admin"] .rich-color input { padding: 2px; width: 28px; min-height: 26px; height: 26px; border-radius: 6px; }
.rich-url { display: flex; align-items: center; gap: 6px; padding: 8px; border-bottom: 1px solid var(--line); }
.rich-surface { padding: 14px; min-height: 130px; max-height: min(43vh, 370px); overflow-y: auto; overflow-wrap: anywhere; }
.rich-surface:focus-visible { outline-offset: -2px; border-radius: 0 0 12px 12px; }
.rich-description { margin-bottom: 16px; overflow-wrap: anywhere; }
:is(.rich-surface, .rich-description) :is(h1, h2, h3) { margin: .65em 0 .3em; line-height: 1.2; }
:is(.rich-surface, .rich-description) p { margin: 0 0 .5em; }
:is(.rich-surface, .rich-description) table { width: auto; max-width: 100%; }
:is(.rich-surface, .rich-description) :is(td,th) { border: 1px solid var(--line); padding: 6px 10px; text-align: start; }
:is(.rich-surface, .rich-description) blockquote { margin: .7em 0; border-left: 3px solid var(--brand); padding: .25em .8em; }
:is(.rich-surface, .rich-description) pre { white-space: pre-wrap; }
:is(.rich-surface, .rich-description) img { width: auto; max-width: 100%; border-radius: 9px; }
:is(.rich-surface, .rich-description, #cart-item-modal .dialog-description) a { color: #bb8b2f; text-decoration: underline; }
.rich-description a, #cart-item-modal .dialog-description a { color: var(--brand); }

@media (max-width: 1100px) {
  .catalog-layout .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .catalog-layout { grid-template-columns: minmax(0, 1fr) minmax(235px, 28%); }
}
@media (max-width: 740px) {
  .catalog-layout, .product-detail-grid { grid-template-columns: 1fr; }
  .fitting { position: static; grid-row: 1; }
  .fitting-stage { height: 250px; }
  .product-page { padding-block: 23px 40px; }
  #editor[data-section="products"] > .form-grid { grid-template-columns: 1fr; }
  .shop-ranking ol { grid-template-columns: minmax(0, 1fr); }
  .shop-ranking-entry, .shop-ranking-entry[data-place]:nth-child(-n+3):is(.shop-ranking-top > *) { grid-column: 1; min-height: 54px; flex-wrap: nowrap; }
  .shop-ranking-top > :nth-child(-n+3) .shop-ranking-amount { width: auto; font-size: .98rem; }
}
@media (max-width: 1190px) {
  .topbar .main-nav:has(.shop-rank-link) { order: 3; width: 100%; min-height: 36px; padding-bottom: 6px; flex-wrap: wrap; gap: 8px 14px; }
  .topbar .topbar-inner:has(.shop-rank-link) { flex-wrap: wrap; gap: 9px 22px; padding-top: 8px; }
}
@media (max-width: 1025px) {
  .topbar-inner { gap: 22px; }
  .main-nav { gap: 15px; }
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .admin-shell { grid-template-columns: 164px 1fr; gap: 17px; }
}
@media (max-width: 740px) {
  .wrap, .topbar-inner, .admin-shell { width: calc(100% - 32px); }
  .topbar-inner { min-height: 68px; gap: 10px; flex-wrap: wrap; padding-top: 8px; }
  .brand { flex-basis: 110px; }
  .top-actions .button { padding-inline: 9px; min-height: 39px; }
  #account { max-width: 131px; }
  #account [data-account-name] { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .footer-inner { flex-wrap: wrap; padding-block: 16px; }
  .main-nav { order: 3; width: 100%; min-height: 37px; gap: 17px; }
  .top-actions { gap: 10px; font-size: .88rem; }
  .realm-row { grid-template-columns: 1fr 1fr; }
  .realm { height: 88px; padding: 0 11px; }
  .realm strong { font-size: 1.56rem; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 14px; }
  .product-body { padding: 10px 0 0; }
  .catalog-head { align-items: stretch; flex-direction: column; }
  .catalog-tools { flex: 0; justify-content: space-between; }
  .category-list { display: grid; justify-content: start; grid-auto-flow: column; grid-template-rows: repeat(2, auto);
    grid-auto-columns: max-content; overflow-x: auto; scrollbar-width: thin; padding: 3px 3px 7px; }
  .admin-shell { grid-template-columns: 1fr; gap: 0; }
  body[data-shop-view="admin"] .admin-shell { gap: 16px; padding-top: 16px; }
  body[data-shop-view="admin"] .side { position: static; padding: 6px; }
  .side { border: 0; padding: 0; }
  .side h2 { display: none; }
  .side nav { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
  .side button { text-align: center; white-space: normal; padding: 7px 6px; line-height: 1.2; overflow-wrap: anywhere; font-size: .89rem; }
  .admin-topbar .topbar-inner { padding-block: 10px; gap: 8px 14px; }
  .admin-title { padding-left: 14px; }
  .editor-product:has(.product-drag-handle) .editor-product-info { padding-right: 42px; }
  .product-drag-handle { width: 42px; height: 42px; }
  body[data-shop-view="admin"] .section-head { align-items: stretch; flex-direction: column; gap: 11px; }
  .admin-heading-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body[data-shop-view="admin"] .admin-heading-actions > .button { padding: 8px; white-space: normal; line-height: 1.2; }
  .admin-product-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: stretch; }
  #admin-search { grid-column: 1 / -1; max-width: none; }
  .admin-product-filters select { width: 100%; min-width: 0; }
  .table-wrap { overflow: visible; }
  .table-wrap :is(table, tbody) { display: block; }
  .table-wrap thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .table-wrap tr { display: grid; gap: 7px; padding: 12px; margin-bottom: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
  body[data-shop-view="admin"] .table-wrap td { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 0; border: 0; }
  .table-value { min-width: 0; overflow-wrap: anywhere; text-align: right; }
  .mobile-table-label { display: block; flex: 0 0 32%; color: var(--muted); text-align: left; font-size: .81rem; }
  .table-wrap td:first-child .table-value { font-weight: 600; }
  .table-wrap td:empty, .table-wrap td:has(.table-value:empty) { display: none; }
  .table-wrap td:not(:has(.mobile-table-label)) .table-value { display: flex; flex-wrap: wrap; gap: 7px; }
}
@media (max-width: 540px) {
  dialog:not(#character-modal, #fitting-drawer) { width: calc(100% - 16px); max-height: calc(100dvh - 16px); }
  #modal:is([data-dialog-type="cart"], [data-dialog-type="collections"], [data-dialog-type="catalog-order"],
    [data-dialog-type="admin-edit"], [data-dialog-type="item-lore"]) {
    width: calc(100% - 16px); max-height: calc(100dvh - 16px);
  }
  #modal[data-dialog-type="collections"] .dialog-content { height: min(780px, calc(100dvh - 18px)); padding: 13px; }
  #modal[data-dialog-type="catalog-order"] .dialog-content { max-height: calc(100dvh - 18px); padding: 13px; }
  #modal[data-dialog-type="admin-edit"] .dialog-content { padding: 0 13px; }
  #modal[data-dialog-type="admin-edit"] .dialog-head { position: sticky; top: 0; z-index: 3; background: var(--panel); padding: 10px 0; margin-bottom: 8px; border-bottom: 1px solid var(--line); }
  .dialog-head h2 { font-size: 1.35rem; overflow-wrap: anywhere; }
  .dialog-head .close { flex: 0 0 42px; height: 42px; }
  .form-grid, .category-switches { grid-template-columns: minmax(0, 1fr); }
  .editor-pane { padding: 12px; }
  .editor-footer { position: sticky; bottom: 0; z-index: 2; background: var(--panel); padding: 9px 0; border-top: 1px solid var(--line); }
  .editor-footer .button, .collection-editor-footer .button, .order-footer .button { min-height: 42px; }
  .collection-product-filters input[type="search"] { grid-column: 1 / -1; }
  .collection-product-filters label { grid-column: 1 / -1; min-height: 35px; }
  .rich-toolbar { gap: 4px; }
  .rich-toolbar button { min-height: 40px; min-width: 34px; }
  .rich-url { flex-wrap: wrap; }
  .rich-url input { flex: 1 1 100%; }
  :is(#modal, .section-filters) :is(input:not([type="checkbox"],[type="range"],[type="color"]), select, textarea, .rich-surface) { font-size: 16px; }
  .order-arrows .icon-button { min-width: 36px; height: 40px; }
  .editor-products { grid-template-columns: minmax(0, 1fr); }
  .editor-product { grid-template-columns: 72px minmax(0, 1fr); gap: 11px; }
  .editor-product-actions > .button, .product-action-menu > summary { min-height: 44px; }
  .editor-product-info :is(h3, p), .product-title { overflow-wrap: anywhere; }
  .product-actions > .button { flex: 1 1 100% !important; min-height: 44px; text-align: center; }
  .product-art .sale-badge { top: 6px; left: 6px; font-size: .74rem; }
  #fitting-drawer { inset: auto 0 0; width: 100%; max-width: none; max-height: 89dvh; border-radius: 20px 20px 0 0; }
  #fitting-drawer[open] { animation-name: fitting-drawer-mobile; }
  @keyframes fitting-drawer-mobile { from { transform: translateY(24px); opacity: .5; } to { transform: none; opacity: 1; } }
  #fitting-trigger { padding-inline: 10px; }
  .xp-feature { grid-template-columns: minmax(0, 1fr); }
  .xp-feature .product-art { width: min(100%, 230px); justify-self: center; }
}
@media (prefers-reduced-motion: reduce) {
  #fitting-drawer[open], .fitting-stage.fitting-equipped::after { animation: none; }
  .shop-entrance, .shop-entrance[data-phase] { transition: none; }
  .shop-entrance:not([data-phase="ready"]) { animation-duration: 0s; }
  .shop-entrance:not([data-phase="ready"]) .shop-entrance-inner,
  .shop-entrance:not([data-phase="ready"]) .shop-entrance-trace::after { animation: none; }
  :is(.realm-picker, .fundraiser-card) > summary::after { transition: none; }
}
@media (max-width: 540px) {
  .cart-row { grid-template-columns: minmax(94px, 1fr) minmax(0, auto) 38px; gap: 7px; }
  .cart-product { grid-column: 1 / 3; grid-template-columns: 46px minmax(0, 1fr); }
  .cart-product strong { overflow-wrap: anywhere; }
  .cart-product-image, .cart-product-image img { width: 46px; height: 46px; }
  .cart-remove { grid-column: 3; grid-row: 1; min-width: 38px; height: 42px; }
  .cart-row > :is(.quantity-stepper, .quantity-locked) { grid-row: 2; justify-self: start; min-width: 92px; }
  .quantity-stepper { grid-template-columns: 33px minmax(45px, 1fr) 33px; }
  .quantity-stepper input.quantity { min-height: 40px; }
  .cart-line-price { grid-column: 2 / 4; }
  .cart-summary-fields { grid-template-columns: 1fr; }
  .cart-summary { padding: 11px; }
  .cart-footer .button[data-action="checkout"] { flex: 1 1 125px; }
  #modal[data-dialog-type="item-lore"] .dialog-content { padding: 0 12px 12px; }
  #modal[data-dialog-type="item-lore"] .dialog-head { position: sticky; top: 0; z-index: 2; margin: 0 0 9px;
    padding: 10px 0; background: var(--panel); border-bottom: 1px solid var(--line); }
  .item-tooltip { padding: 11px; font-size: .875rem; line-height: 1.4; }
}
@media (max-width: 410px) {
  .topbar-inner, .wrap { width: calc(100% - 22px); }
  .top-actions { gap: 5px; }
  .brand { flex-basis: 90px; }
  .top-actions .button { gap: 5px; font-size: .78rem; padding-inline: 6px; }
  #account { max-width: 113px; }
  #account > .site-icon { display: none; }
  .top-actions .button-small { padding-inline: 7px; }
  .main-nav { gap: 14px; }
  .form-grid { grid-template-columns: 1fr; }
  .cart-row { gap: 5px; }
  .dialog-content { padding: 13px; }
  .admin-topbar .top-actions { margin-left: 0; width: 100%; }
}
