/* Market only: jade panels, brass trim and illustrated harbor. No release bump. */
#market{--scene-accent:#f1d4a1;--scene-dark:#102d2b;background:#0c2326;color:#ebeee0;padding:0 14px 16px;font-size:14px;line-height:1.45;--mh-gold:#f1d4a1;--mh-muted:#abc4bb;--mh-line:#52796a66}
#market::before{background:radial-gradient(ellipse at 0 25%,#5b85641c,transparent 50%);opacity:1}
#market h2,#market h3{color:#f1dfb9;letter-spacing:0}
#market h2{font:600 clamp(25px,6.7vw,36px)/1.12 Georgia,'Times New Roman',serif}
#market h3{font-size:17px;line-height:1.3}
#market p{color:var(--mh-muted)}
#market small{font-size:11px}
#market button,#market input,#market select{font-family:inherit;touch-action:manipulation}
#market button{min-height:44px}
#market button:focus-visible,#market input:focus-visible,#market select:focus-visible,#market summary:focus-visible{outline:2px solid #f4d79c;outline-offset:3px}
#market .up{color:#a9e3bf}#market .down{color:#f0b6a8}
#market .mh-topline{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 -4px;color:#b8d1c3;font-size:9px;letter-spacing:.14em}
#market .mh-topline button{border:0;background:none;padding:8px 4px;color:#d3dac4;font-size:13px;letter-spacing:0}
#market .mh-harbor{position:relative;min-height:240px;margin:0 -14px;isolation:isolate;display:flex;flex-direction:column;justify-content:space-between;padding:21px 20px 16px;background:linear-gradient(180deg,#10282911 24%,#10282900 54%,#0c2326 100%),url('./assets/market/harbor.svg') center 56%/cover;border-top:1px solid #e5c88644}
#market .mh-harbor-title{text-shadow:0 2px 8px #081e22,0 0 25px #081e22}
#market .mh-harbor-title h2{max-width:290px;margin:6px 0;color:#fff0d0}
#market .mh-harbor-title p{font:italic 14px Georgia,serif;color:#f4dfb7;margin:4px 0}
#market .mh-eyebrow{font-size:9px;letter-spacing:.18em;color:#ced5ba;font-weight:600}
#market .mh-balance{align-self:flex-start;display:grid;gap:2px;padding:9px 14px;min-width:160px;border:1px solid #dfc78f6b;background:#102e2ae8;border-radius:11px;box-shadow:0 5px 20px #061b2266;backdrop-filter:blur(8px)}
#market .mh-balance small{color:#c5d0b6;font-size:10px}
#market .mh-balance b{font-size:20px;font-variant-numeric:tabular-nums;letter-spacing:.02em}
#market .mh-balance b span{color:#e4c480}
#market .mh-npc-notice{display:flex;align-items:center;gap:10px;padding:10px 12px;margin:0 0 14px;border:1px solid var(--mh-line);border-radius:10px;background:#193c34;box-shadow:inset 0 1px #cfdda50b}
#market .mh-npc-notice>span{font-size:25px;color:#d9c58b}
#market .mh-npc-notice p{margin:0;font-size:11px;line-height:1.5;color:#c0d0bb}
#market .mh-npc-notice b{color:#ecdfbc;font-size:12px}
#market .mh-navigation{display:flex;gap:2px;border-bottom:1px solid #41675b;padding-bottom:5px;margin-bottom:14px}
#market .mh-navigation button{flex:1;min-width:0;border:0;background:none;border-radius:6px 6px 0 0;padding:10px 2px;font-size:12px;color:#b9cbbd;position:relative;white-space:nowrap}
#market .mh-navigation button[aria-current]{color:#ffe1a5;background:linear-gradient(#c5ac6a00,#c5ac6a15)}
#market .mh-navigation button[aria-current]::after{content:'';position:absolute;height:2px;bottom:-6px;left:8px;right:8px;background:#eac481;box-shadow:0 0 10px #d7b97644}
#market .mh-categories{display:flex;gap:7px;padding:3px;border:1px solid #385e53;background:#091f21;border-radius:11px;margin-bottom:14px}
#market .mh-categories button{flex:1;border:0;border-radius:7px;background:none;color:#b6c8bc;font-size:12px;padding:8px 2px}
#market .mh-categories button[aria-pressed=true]{background:linear-gradient(130deg,#315c4c,#214639);box-shadow:inset 0 1px #d0dbb32b;color:#f2e5c5}
#market .mh-categories small{margin-left:4px;color:#c7d9be;font-size:10px}
#market .mh-detail{border:1px solid #c6b4807a;border-radius:18px;padding:14px;background:radial-gradient(ellipse at 0 0,#548b6940,transparent 65%),linear-gradient(140deg,#1d4138,#102d2b);box-shadow:0 8px 26px #031d2340,inset 0 1px #fff3b91a;scroll-margin-top:10px}
#market .mh-detail-heading{display:flex;align-items:center;justify-content:space-between;margin-top:-6px}
#market .mh-watch{border:0!important;background:transparent;color:#f1d4a1;font-size:27px;min-width:44px;padding:0}
#market .mh-showcase{display:grid;grid-template-columns:100px 1fr;align-items:center;gap:10px;margin-top:-5px}
#market .mh-showcase>.mh-art{width:100%;height:auto;filter:drop-shadow(0 9px 12px #041d1bd9)}
#market .mh-showcase h3{margin:4px 0 6px;font-family:Georgia,serif;font-size:20px;color:#f9e8c6}
#market .mh-category{display:block;color:#b6c9b4;font-size:10px;letter-spacing:.07em}
#market .mh-showcase p{font-size:11px;margin:7px 0}
#market .mh-rank{display:inline-flex;align-items:center;gap:5px;font-size:10px;line-height:1.2;color:var(--rarity,#d8ccb3)}
#market .mh-rank::before{content:'';width:5px;height:5px;background:currentColor;transform:rotate(45deg);flex-shrink:0}
#market .mh-quote{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:10px 0 12px}
#market .mh-quote>div small{display:block;color:#b8c9b7;font-size:10px}
#market .mh-quote strong{display:block;font-size:28px;color:#f6e5bd;font-weight:650;font-variant-numeric:tabular-nums;letter-spacing:-.03em}
#market .mh-quote strong span{font-size:19px;color:#d4b97a}
#market .mh-change{text-align:right;font-size:14px;font-weight:600}
#market .mh-change small{display:block;color:#acbfb0;font-size:10px;font-weight:400}
#market .mh-periods{display:flex;gap:4px;justify-content:flex-end}
#market .mh-periods button{min-height:44px;padding:6px 11px;border:0;border-radius:7px;background:transparent;color:#adc6b5;font-size:11px}
#market .mh-periods button.active{background:#3b604a;color:#ffe5b0}
#market .mh-chart{height:120px;display:flex;gap:8px;margin-top:7px}
#market .mh-chart-scale{display:flex;flex-direction:column;justify-content:space-between;color:#b7cbb9;font-size:9px;flex:0 0 auto;min-width:42px;padding:9px 0 8px;font-variant-numeric:tabular-nums}
#market .mh-chart svg{flex:1;min-width:0;width:100%;height:120px;overflow:visible}
#market .mh-chart-times{display:flex;justify-content:space-between;gap:4px;margin-left:50px;font-size:8px;color:#b2c8b7;font-variant-numeric:tabular-nums}
#market .mh-quote-history{border-top:1px solid var(--mh-line);margin:14px 0 0}
#market .mh-quote-history summary{cursor:pointer;min-height:44px;padding:13px 0;font-size:11px;color:#d3dfc7}
#market .mh-quote-history p,#market .mh-quote-history caption{font-size:10px;text-align:left;color:#b1c7b8;margin:0 0 10px}
#market .mh-quote-history table{width:100%;font-size:10px;border-collapse:collapse;margin-bottom:12px;text-align:right;font-variant-numeric:tabular-nums}
#market .mh-quote-history th{color:#b6c5af;font-weight:400}
#market .mh-quote-history td,#market .mh-quote-history th{padding:7px 1px;border-bottom:1px solid #49675b55}
#market .mh-quote-history :is(th,td):first-child{text-align:left}
#market .mh-trade-info{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:4px;padding:11px 0;border-top:1px solid var(--mh-line);font-size:11px;color:#b7cbb9}
#market .mh-trade-info b{color:#f0dfb9;margin-left:4px;font-size:12px}
#market .mh-trade-info small{font-size:9px}
#market .mh-buy{width:100%;padding:12px;border:1px solid #f2d598;border-radius:10px;background:linear-gradient(110deg,#e7c181,#f3dbab 50%,#cfa66b);box-shadow:inset 0 1px #fff3d1,0 4px 12px #051b2166;color:#24372b;font-size:14px;font-weight:750;min-height:48px}
#market .mh-buy:disabled{opacity:.65;background:#466557;color:#e3e4c8;border-color:#8fa081;box-shadow:none}
#market .mh-trade-note{margin:8px 0 0;text-align:center;font-size:9px;color:#b2c4b2}
#market .mh-section-title{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:23px 0 12px}
#market .mh-section-title h3{margin:0;font-family:Georgia,serif;font-size:20px}
#market .mh-section-title>span{color:#adc2b3;font-size:10px}
#market .mh-filters{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);gap:8px;margin-bottom:12px}
#market .mh-filters label{min-width:0}
#market .mh-filters input,#market .mh-filters select{width:100%;height:44px;border:1px solid #4a6d5f;background:#173831;color:#e2e3c9;border-radius:9px;padding:8px;font-size:12px;min-width:0}
#market .mh-filters input::placeholder{color:#b4c6b5;opacity:1}
#market .mh-catalog{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
#market .mh-item{display:flex;flex-direction:column;position:relative;min-width:0;overflow:hidden;text-align:left;align-items:flex-start;padding:10px;border:1px solid #54776385;border-radius:13px;background:linear-gradient(145deg,#1d4237,#14302c);box-shadow:inset 0 1px #efdfa114;transition:border-color .15s,background .15s}
#market .mh-item.current{border-color:#dbbd7c;background:linear-gradient(145deg,#345440,#19392f);box-shadow:inset 0 0 0 1px #dbbd7c33}
#market .mh-item-art{width:100%;height:119px;display:grid;place-items:center;position:relative;background:radial-gradient(ellipse at 50% 65%,#78987633,transparent 70%)}
#market .mh-item-art::after{content:'';position:absolute;bottom:9px;left:17%;right:17%;height:12px;border-radius:50%;border-bottom:1px solid #bcaf6d45;background:#09271c33;z-index:0}
#market .mh-art{width:115px;height:115px;position:relative;z-index:1;pointer-events:none;filter:drop-shadow(0 5px 5px #051c19aa)}
#market .mh-star{position:absolute;top:0;right:0;color:#efd296;font-size:18px}
#market .mh-item-name{display:block;line-height:1.35;font-size:12px;margin:4px 0 8px;min-height:33px;color:#f0e4c6;overflow-wrap:anywhere}
#market .mh-item-price{display:block;margin:12px 0 5px;font-size:19px;font-variant-numeric:tabular-nums;color:#f4dfb1;letter-spacing:-.03em}
#market .mh-item-price small{color:#dbc384;font-size:13px}
#market .mh-card-bottom{display:flex;flex-wrap:wrap;justify-content:space-between;gap:4px;width:100%;font-size:10px;color:#c3ceb2;line-height:1.4}
#market .mh-card-bottom small{font-size:8px;color:#b3c4b5}
#market .mh-card-bottom>span:last-child{font-size:9px}
#market .mh-caption{font-size:11px;margin-bottom:14px}
#market .mh-owned{display:grid;grid-template-columns:62px minmax(0,1fr);align-items:center;gap:10px;border:1px solid #52776499;border-radius:13px;background:linear-gradient(130deg,#214337,#122f2b);padding:12px;margin:10px 0}
#market .mh-owned>.mh-art{width:62px;height:76px}
#market .mh-owned h3{font-size:14px;margin:3px 0 5px}
#market .mh-owned p,#market .mh-owned small{font-size:10px;margin:7px 0 0;color:#b4c7b6}
#market .mh-owned-action{display:flex;grid-column:1/-1;justify-content:space-between;align-items:center;gap:12px;padding-top:8px;border-top:1px solid var(--mh-line)}
#market .mh-owned-action b{font-size:18px;color:#f1d6a3;font-variant-numeric:tabular-nums}
#market .mh-owned-action button{border:1px solid #adb980;border-radius:9px;background:#315542;padding:10px 17px;color:#ecdfb6;font-size:12px}
#market .mh-owned-help{grid-column:1/-1}
#market .mh-empty{grid-column:1/-1;text-align:center;padding:25px 18px;border:1px dashed #496958;border-radius:14px;background:#18372e66}
#market .mh-empty>span{display:block;font-size:38px;color:#cebb87}
#market .mh-empty h3{font-size:16px;margin:5px 0 8px}
#market .mh-empty p{font-size:12px;margin:0}
#market .mh-history ol{list-style:none;padding:0;margin:0;border:1px solid var(--mh-line);border-radius:14px;background:#18392f}
#market .mh-history li{display:grid;grid-template-columns:30px minmax(0,1fr) auto;gap:8px;align-items:center;padding:14px 10px;border-bottom:1px solid #3a5c4f}
#market .mh-history li:last-child{border:0}
#market .mh-history-icon{display:grid;place-items:center;width:28px;height:34px;background:#2c4f3e;border-radius:8px;color:#e1c58d;font-size:20px}
#market .mh-history li b{display:block;font-size:12px;font-weight:500;overflow-wrap:anywhere}
#market .mh-history li small{display:block;color:#b5c9b5;font-size:9px;margin-top:5px}
#market .mh-history li strong{font-size:12px;font-variant-numeric:tabular-nums;color:#f0dfb8}
#market .mh-footer{font-size:9px;line-height:1.7;text-align:center;color:#a8c1b1;margin:24px 0 4px}
#market .mh-sr{position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
#market .mh-dialog{position:fixed;max-width:calc(100% - 28px);width:390px;max-height:calc(100dvh - 80px - env(safe-area-inset-top) - env(safe-area-inset-bottom));overflow:auto;padding:24px 20px;border:1px solid #d6bf82;border-radius:18px;color:#f2e6c7;background:linear-gradient(145deg,#254c3d,#102e2a);box-shadow:0 20px 80px #0009;overscroll-behavior:contain}
#market .mh-dialog::backdrop{background:#031b20cc;backdrop-filter:blur(5px)}
#market .mh-dialog h2{font-size:28px;margin:12px 20px 20px 0}
#market .mh-dialog h3{font:18px Georgia,serif;margin:0 0 10px}
#market .mh-dialog p{font-size:12px}
#market .mh-dialog-close{position:absolute;top:10px;right:10px;width:44px;height:44px;border:0;background:transparent;color:#e7d6aa;font-size:28px}
#market .mh-confirm-total{display:flex;align-items:center;justify-content:space-between;gap:10px;border-block:1px solid #67836c66;padding:16px 0;margin-top:18px;font-size:12px}
#market .mh-confirm-total strong{font-size:23px;color:#f4d69a}
#market .mh-dialog-actions{display:flex;gap:10px;margin-top:20px}
#market .mh-dialog-actions>button:first-child{min-width:90px;border:1px solid #768970;border-radius:10px;background:#244638;color:#e4d8b4;font-size:12px}
@media(min-width:500px){#market{padding-inline:22px}#market .mh-harbor{margin-inline:-22px;min-height:280px;padding:26px}#market .mh-showcase{grid-template-columns:145px 1fr}#market .mh-showcase h3{font-size:25px}#market .mh-catalog{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:350px){#market{padding-inline:10px}#market .mh-harbor{margin-inline:-10px;padding-inline:16px;min-height:220px}#market .mh-showcase{grid-template-columns:75px 1fr;gap:6px}#market .mh-showcase h3{font-size:17px}#market .mh-detail{padding:11px}#market .mh-card-bottom{font-size:9px}#market .mh-item-art{height:98px}#market .mh-item .mh-art{width:96px;height:96px}#market .mh-filters{gap:5px}#market .mh-filters :is(input,select){font-size:11px;padding:6px}#market .mh-history li{grid-template-columns:minmax(0,1fr) auto}#market .mh-history-icon{display:none}}
@media(prefers-reduced-motion:reduce){#market,#market *{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
body:has(#market .mh-dialog[open]){overflow:hidden}
