/* Marketplace (addons/market): vending shops, buying stores and player listings, drawn on the home page frame (home.css). */

.gh-market { gap: 18px; }
.mk-page { overflow: hidden; }
.mk-page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 22px 26px 0; }
.mk-page-head h1 { font-size: clamp(26px, 3.4vw, 36px); }
.mk-page-head p { color: var(--gh-muted); }
.mk-page-head p b { color: var(--gh-ink); }
.mk-page-head .gh-eyebrow { display: block; margin-bottom: 4px; }
.mk-pill { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 5px 11px; font-size: 12.5px; font-weight: 800; background: #eef1f6; color: var(--gh-muted); white-space: nowrap; }
.mk-pill.is-live { background: var(--gh-good-bg); color: var(--gh-good-ink); }
.mk-pill.is-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--gh-good); font-size: 0; }
.mk-pill.is-gold { background: #fdf0dd; color: var(--gh-gold-deep); }
.mk-tabs { display: flex; gap: 6px; padding: 14px 26px 0; flex-wrap: wrap; }
.mk-tab { padding: 9px 14px; border-radius: 12px 12px 0 0; font-weight: 800; font-size: 14px; color: var(--gh-muted); background: #f3f5f9; border: 1px solid var(--gh-line); border-bottom: 0; text-decoration: none; }
.mk-tab:hover { color: var(--gh-gold-deep); }
.mk-tab.is-active { background: #fff; color: var(--gh-ink); position: relative; top: 1px; }
.mk-tab.is-soon { opacity: .7; }
.mk-tab small { color: var(--gh-muted); font-weight: 700; margin-left: 6px; }
.mk-filters { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr auto; gap: 10px; padding: 16px 26px 20px; border-top: 1px solid var(--gh-line); align-items: end; margin: 0; }
.mk-filters-short { grid-template-columns: 2fr 1fr auto; }
.mk-field { display: grid; gap: 4px; min-width: 0; margin: 0; }
.mk-field span { font-size: 11.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gh-muted); }
.mk-field input, .mk-field select { width: 100%; border: 1px solid rgba(23,33,58,0.16); border-radius: 12px; padding: 10px 12px; background: #fff; color: var(--gh-ink); font-family: var(--gh-body); font-weight: 700; font-size: 14px; }
.mk-submit { align-self: end; }

.mk-section { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 0 6px; }
.mk-section h2 { font-size: 20px; text-shadow: 0 1px 0 rgba(255,255,255,0.7); }

/* ---------------------------------------------------------------- category sidebar + grid */
.mk-layout { display: grid; grid-template-columns: 224px minmax(0, 1fr); gap: 18px; align-items: start; }
.mk-side-nav { padding: 10px; display: grid; gap: 2px; position: sticky; top: 92px; }
.mk-side-nav h3 { font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gh-muted); padding: 8px 12px 6px; }
.mk-cat { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 12px; text-decoration: none; color: var(--gh-ink); font-weight: 800; font-size: 14px; border-left: 3px solid transparent; min-width: 0; }
.mk-cat:hover { background: #f3f5f9; color: var(--gh-gold-deep); }
.mk-cat.is-active { background: #fdf0dd; color: var(--gh-gold-deep); border-left-color: var(--gh-gold); }
.mk-cat img { width: 24px; height: 24px; image-rendering: pixelated; flex: none; }
.mk-cat em { font-style: normal; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-cat small { margin-left: auto; color: var(--gh-muted); font-weight: 700; font-size: 12px; background: #eef1f6; border-radius: 999px; padding: 2px 8px; }
.mk-cat.is-active small { background: #fff; }
.mk-main { display: grid; gap: 14px; min-width: 0; align-content: start; }
.mk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(212px, 1fr)); gap: 16px; }

/* ---------------------------------------------------------------- item boxes */
.mk-item { padding: 0; position: relative; display: grid; align-content: start; min-width: 0; }
.mk-item.is-featured { border: 2px solid var(--gh-gold); }
.mk-badge { position: absolute; top: -10px; right: 12px; background: #fdf0dd; color: var(--gh-gold-deep); border-radius: 999px; padding: 3px 10px; font-size: 11.5px; font-weight: 800; z-index: 4; }
.mk-frame { position: relative; margin: 8px 8px 0; border-radius: 16px; padding: 7px 7px 4px; background: linear-gradient(160deg, #36416a 0%, #1c2342 55%, #0f1429 100%); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08), inset 0 0 0 2px rgba(224,150,42,0.4), 0 6px 14px rgba(23,33,58,0.18); }
.mk-canvas { display: grid; place-items: center; position: relative; height: 212px; border-radius: 10px; background: radial-gradient(ellipse at 50% 35%, #ffffff 0%, #f6f2e7 58%, #e8e2d0 100%); overflow: hidden; text-decoration: none; }
.mk-pic { width: 150px; height: 200px; object-fit: contain; image-rendering: pixelated; visibility: hidden; filter: drop-shadow(0 6px 4px rgba(23,33,58,0.18)); }
.mk-canvas.has-img .mk-pic { visibility: visible; }
.mk-canvas.is-card .mk-pic { image-rendering: auto; filter: drop-shadow(0 8px 8px rgba(23,33,58,0.3)); }
.mk-pic-id { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--gh-display); font-weight: 600; color: #b8b2a2; font-size: 15px; }
.mk-canvas.has-img .mk-pic-id { display: none; }
.mk-refine { position: absolute; top: 8px; right: 8px; background: #17213a; color: #fff; font-family: var(--gh-display); font-weight: 600; font-size: 15px; padding: 3px 9px; border-radius: 9px; box-shadow: 0 2px 6px rgba(0,0,0,0.25); z-index: 2; }
.mk-flags { position: absolute; top: 8px; left: 8px; display: grid; gap: 3px; z-index: 2; }
.mk-flags img { width: 26px; height: 26px; image-rendering: pixelated; background: rgba(23,33,58,0.85); border-radius: 7px; padding: 2px; box-sizing: border-box; }
.mk-flags b { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 7px; background: #2a9d5c; color: #fff; font-size: 12px; font-weight: 800; }
.mk-slots { position: absolute; left: 11px; bottom: 9px; display: flex; gap: 5px; z-index: 2; }
.mk-slots i { width: 11px; height: 11px; transform: rotate(45deg); border: 1.5px solid #9a9381; border-radius: 2px; font-size: 0; background: rgba(255,255,255,0.55); }
.mk-slots i.is-set { background: var(--gh-gold); border-color: var(--gh-gold-deep); }
.mk-grade { position: absolute; top: 8px; right: 8px; background: linear-gradient(180deg, #f3c773, #c9962f); color: #17213a; font-size: 11px; font-weight: 800; letter-spacing: 0.04em; padding: 3px 7px; border-radius: 7px; box-shadow: 0 2px 6px rgba(0,0,0,0.25); z-index: 2; }
.mk-refine + .mk-grade { top: 44px; }
.mk-d-opts p { color: #ffd37a; }
.mk-qty { position: absolute; right: 9px; bottom: 8px; font-weight: 800; font-size: 12.5px; color: #fff; background: rgba(23,33,58,0.82); border-radius: 999px; padding: 2px 8px; z-index: 2; }
.mk-name { display: flex; align-items: center; gap: 8px; padding: 8px 2px 4px 4px; color: #fff; font-weight: 800; font-size: 14px; min-width: 0; }
.mk-name img { width: 24px; height: 24px; image-rendering: pixelated; flex: none; }
.mk-name a { color: #fff; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.mk-name a:hover { color: #ffd37a; }
.mk-info { margin-left: auto; flex: none; width: 24px; height: 24px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.45); color: #fff; font-family: var(--gh-display); font-weight: 600; font-size: 13px; line-height: 22px; text-align: center; background: transparent; cursor: pointer; padding: 0; }
.mk-info:hover { background: rgba(255,255,255,0.14); }
.mk-detail { position: absolute; inset: 0; border-radius: 16px; background: rgba(13,18,37,0.965); color: #dfe4f0; padding: 14px 14px 12px; overflow: auto; font-size: 12.5px; line-height: 1.45; z-index: 3; opacity: 0; visibility: hidden; transition: opacity 0.18s; scrollbar-width: thin; }
.mk-item.is-open .mk-detail { opacity: 1; visibility: visible; }
@media (hover: hover) { .mk-frame:hover .mk-detail { opacity: 1; visibility: visible; } }
.mk-detail h4 { color: #fff; font-size: 14px; margin: 0 0 2px; display: flex; gap: 8px; align-items: center; }
.mk-detail h4 img { width: 24px; height: 24px; image-rendering: pixelated; }
.mk-detail .mk-d-id { color: #8c96b3; font-size: 11.5px; font-weight: 700; margin: 0 0 6px; }
.mk-detail p { margin: 0; overflow-wrap: anywhere; }
.mk-detail hr { border: 0; border-top: 1px solid rgba(255,255,255,0.14); margin: 7px 0; }
.mk-detail .mk-d-key { color: #f3c773; font-weight: 800; }
.mk-d-cards { display: grid; gap: 2px; margin-bottom: 4px; }
.mk-d-cards span { color: #8c96b3; font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; font-weight: 800; }
.mk-d-cards p { color: #7fd99a; font-weight: 700; }
.mk-d-cards p.is-card { color: #9ec5ff; }
.mk-d-act { display: block; margin-top: 10px; text-align: center; }
.mk-foot { padding: 10px 14px 12px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 8px; align-items: center; }
.mk-seller-chip { display: inline-flex; align-items: center; gap: 6px; background: var(--gh-good-bg); color: var(--gh-good-ink); border-radius: 999px; padding: 3px 10px; font-size: 12.5px; font-weight: 800; min-width: 0; max-width: 100%; justify-self: start; }
.mk-seller-chip b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-seller-chip.is-sky { background: #e6eefc; color: #2b57b4; }
.mk-id { color: var(--gh-muted); font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.mk-price { font-family: var(--gh-display); font-weight: 600; font-size: 19px; color: var(--gh-gold-deep); font-variant-numeric: tabular-nums; line-height: 1.2; min-width: 0; overflow-wrap: anywhere; }
.mk-price small { display: block; font-family: var(--gh-body); font-weight: 700; font-size: 12px; color: var(--gh-muted); }
.mk-foot-act { justify-self: end; text-align: right; }
.mk-foot-act a { color: var(--gh-sky); font-weight: 800; text-decoration: none; white-space: nowrap; font-size: 13px; }
.mk-foot-act .gh-btn { white-space: nowrap; }
.mk-where { grid-column: 1 / -1; color: var(--gh-muted); font-size: 12px; font-weight: 700; }

/* small square icons (vault table, confirm page, home card) */
.mk-icon { position: relative; width: 64px; height: 64px; border-radius: 14px; background: #f3f5f9; border: 1px solid var(--gh-line); display: grid; place-items: center; overflow: hidden; text-decoration: none; }
.mk-icon img { width: 48px; height: 48px; image-rendering: pixelated; position: relative; z-index: 1; visibility: hidden; }
.mk-icon.has-img img { visibility: visible; }
.mk-icon.has-img .mk-icon-id { display: none; }
.mk-icon-id { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--gh-display); font-weight: 600; font-size: 13px; color: var(--gh-muted); }

.mk-pager { display: flex; justify-content: center; gap: 6px; padding: 6px; flex-wrap: wrap; }
.mk-pager a, .mk-pager span { min-width: 36px; height: 36px; padding: 0 10px; display: grid; place-items: center; border-radius: 10px; background: #fff; border: 1px solid var(--gh-line); font-weight: 800; text-decoration: none; color: var(--gh-ink); }
.mk-pager a:hover { color: var(--gh-gold-deep); }
.mk-pager .is-on { background: var(--gh-ink); color: #fff; border-color: var(--gh-ink); }
.mk-empty { padding: 26px; display: grid; gap: 8px; justify-items: start; }
.mk-empty h3 { font-size: 20px; }
.mk-empty p { color: var(--gh-muted); }
.mk-notice { padding: 18px 22px; border-left: 6px solid var(--gh-gold); }

/* home page card */
.gh-mk-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 10px 18px 18px; }
.gh-mk-offer { border: 1px solid var(--gh-line); border-radius: 16px; padding: 12px; display: grid; gap: 4px; background: #fff; text-decoration: none; color: var(--gh-ink); min-width: 0; }
.gh-mk-offer:hover { border-color: rgba(224,150,42,0.5); color: var(--gh-ink); }
.gh-mk-offer .mk-icon { width: 48px; height: 48px; border-radius: 12px; }
.gh-mk-offer .mk-icon img { width: 36px; height: 36px; }
.gh-mk-offer h4 { font-size: 14px; overflow-wrap: anywhere; }
.gh-mk-offer .gh-mk-price { font-weight: 800; color: var(--gh-gold-deep); font-variant-numeric: tabular-nums; }
.gh-mk-offer small { color: var(--gh-muted); font-size: 12px; }

@media (max-width: 1100px) { .mk-filters { grid-template-columns: 1fr 1fr 1fr; } .mk-field-wide { grid-column: 1 / -1; } }
@media (max-width: 900px) {
	.mk-layout { grid-template-columns: 1fr; }
	.mk-side-nav { position: static; display: flex; overflow-x: auto; gap: 6px; padding: 8px; scrollbar-width: thin; }
	.mk-side-nav h3 { display: none; }
	.mk-cat { white-space: nowrap; border-left: 0; border-radius: 999px; padding: 7px 12px; flex: none; }
	.mk-cat small { margin-left: 2px; }
}
@media (max-width: 820px) { .mk-filters { grid-template-columns: 1fr 1fr; } .mk-page-head, .mk-tabs { padding-left: 18px; padding-right: 18px; } .mk-filters { padding: 14px 18px 18px; } }
@media (max-width: 560px) { .mk-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; } .mk-canvas { height: 180px; } .mk-pic { width: 112px; height: 150px; } .mk-filters { grid-template-columns: 1fr; } .gh-mk-list { grid-template-columns: 1fr; } .mk-submit { width: 100%; } .mk-foot { padding: 8px 10px 10px; } .mk-price { font-size: 16px; } }

/* ---------------------------------------------------------------- phase 2b: vault, listings, wallet, staff */
.mk-pill.is-sky { background: #e6eefc; color: #2b57b4; }
.mk-tab-right { margin-left: auto; }
.mk-btn-sm { padding: 7px 12px; font-size: 13px; border-radius: 10px; }
.mk-two { display: grid; grid-template-columns: 1.5fr 1fr; gap: 18px; align-items: start; }
.mk-side { display: grid; gap: 18px; min-width: 0; }
.mk-table-card { padding: 6px 0 4px; min-width: 0; }
.mk-head-in { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 12px 18px 6px; }
.mk-head-in h3 { font-size: 18px; }
.mk-sub-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.mk-sub-tabs a { text-decoration: none; }
.mk-tbl-wrap { overflow-x: auto; }
.mk-t { border-collapse: collapse; width: 100%; font-size: 13.5px; }
.mk-t th, .mk-t td { padding: 10px 14px; border-bottom: 1px solid var(--gh-line); vertical-align: middle; text-align: left; white-space: nowrap; }
.mk-t th { font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gh-muted); font-weight: 800; }
.mk-t tr:last-child td { border-bottom: 0; }
.mk-t td b { font-weight: 800; }
.mk-t td small { display: block; color: var(--gh-muted); white-space: normal; }
.mk-t td.mk-r, .mk-t th.mk-r { text-align: right; font-variant-numeric: tabular-nums; }
.mk-t td.is-pos { color: var(--gh-good-ink); font-weight: 800; }
.mk-t td.is-neg { color: #b4324f; font-weight: 800; }
.mk-t-action { text-align: right; }
.mk-t-action form { display: inline; margin: 0; }
.mk-icon-sm { width: 34px; height: 34px; border-radius: 9px; display: inline-grid; vertical-align: middle; margin-right: 8px; }
.mk-icon-sm img { width: 26px; height: 26px; }
.mk-icon-sm .mk-icon-id { font-size: 9px; }
.mk-details summary { list-style: none; cursor: pointer; display: inline-flex; }
.mk-details summary::-webkit-details-marker { display: none; }
.mk-details[open] summary { opacity: .6; }
.mk-list-form { display: grid; gap: 10px; padding: 12px 0 4px; text-align: left; min-width: 240px; }
.mk-radio { display: grid; gap: 6px; }
.mk-radio label { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 14px; white-space: normal; }
.mk-radio small { color: var(--gh-muted); font-weight: 700; }
.mk-wallet { padding: 18px; display: grid; gap: 12px; }
.mk-wallet-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mk-wallet-head h3 { font-size: 18px; }
.mk-wallet-head a { color: var(--gh-sky); font-weight: 800; text-decoration: none; }
.mk-bal { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.mk-bal > div { background: #fff; border: 1px solid var(--gh-line); border-radius: 12px; padding: 12px; min-width: 0; }
.mk-bal small { display: block; color: var(--gh-muted); font-weight: 700; font-size: 12px; }
.mk-bal b { display: block; font-family: var(--gh-display); font-weight: 600; font-size: 22px; line-height: 1.2; overflow-wrap: anywhere; }
.mk-bal em { display: block; font-style: normal; font-size: 12px; color: var(--gh-muted); }
.mk-bal em a { color: var(--gh-sky); font-weight: 800; }
.mk-howto { padding: 18px; display: grid; gap: 8px; }
.mk-howto h3 { font-size: 18px; }
.mk-howto ol { margin: 0; padding-left: 20px; display: grid; gap: 6px; color: var(--gh-muted); font-size: 14px; }
.mk-howto p { color: var(--gh-muted); font-size: 14px; }
.mk-form-card { padding: 18px; display: grid; gap: 6px; }
.mk-form-card h3 { font-size: 18px; }
.mk-inline-form { display: grid; grid-template-columns: 1fr 2fr auto; gap: 10px; padding: 6px 18px 14px; align-items: end; margin: 0; }
.mk-note { font-size: 13px; color: var(--gh-muted); padding: 10px 12px; border-radius: 12px; background: #f6f7fa; }
.mk-empty-small { padding: 6px 18px 16px; color: var(--gh-muted); }
.mk-confirm { max-width: 560px; margin: 0 auto; padding: 24px; display: grid; gap: 14px; }
.mk-confirm-item { display: flex; align-items: center; gap: 14px; }
.mk-confirm-item h2 { font-size: 22px; }
.mk-confirm-item p { color: var(--gh-muted); font-size: 14px; }
.mk-rows { display: grid; gap: 6px; }
.mk-row { display: flex; justify-content: space-between; gap: 10px; font-weight: 700; font-size: 14.5px; }
.mk-row span:last-child { font-variant-numeric: tabular-nums; }
.mk-row-total { border-top: 1px solid var(--gh-line); padding-top: 8px; font-size: 16px; }
.mk-row-total span:last-child { color: var(--gh-gold-deep); font-family: var(--gh-display); font-weight: 600; font-size: 20px; }
.mk-actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; margin: 0; }
@media (max-width: 900px) { .mk-two { grid-template-columns: 1fr; } .mk-inline-form { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .mk-bal { grid-template-columns: 1fr; } .mk-tab-right { margin-left: 0; } }
.mk-rules { margin: 4px 18px 10px; padding: 12px 14px; border-radius: 12px; background: #fdf0dd; display: grid; gap: 10px; }
.mk-rules p { font-size: 13.5px; color: var(--gh-ink); }
.mk-actions-left { justify-content: flex-start; }

/* ---------------------------------------------------------------- cash-out */
.mk-cashout { padding: 18px; display: grid; gap: 12px; }
.mk-cashout-sub { color: var(--gh-muted); font-size: 14px; margin-top: -6px; }
.mk-t-rates td, .mk-t-rates th { padding: 7px 12px; }
.mk-cashout-form { display: grid; grid-template-columns: 1fr auto; gap: 10px 14px; align-items: end; margin: 0; }
.mk-cashout-form .mk-field { grid-column: 1; }
.mk-cashout-result { grid-column: 1 / -1; font-size: 15px; color: var(--gh-muted); font-weight: 700; }
.mk-cashout-result b { font-family: var(--gh-display); font-weight: 600; font-size: 24px; color: var(--gh-gold-deep); margin-left: 6px; font-variant-numeric: tabular-nums; }
.mk-cashout-form .gh-btn { grid-column: 2; grid-row: 1; }
.mk-payouts { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.mk-payouts li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border: 1px solid var(--gh-line); border-radius: 12px; background: #fff; }
.mk-payouts b { display: block; font-weight: 800; }
.mk-payouts small { display: block; color: var(--gh-muted); font-weight: 700; }
.mk-payouts form { margin: 0; }
.mk-details-block { margin-top: 4px; }
.mk-details-block .mk-list-form { min-width: 0; }
.mk-field-label { font-size: 11.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gh-muted); }
.mk-payout-pick { display: grid; gap: 8px; margin: 0; }
.mk-payout-option { display: flex; gap: 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--gh-line); border-radius: 12px; background: #fff; cursor: pointer; }
.mk-payout-option b { display: block; font-weight: 800; }
.mk-payout-option small { display: block; color: var(--gh-muted); font-weight: 700; }
.mk-inline-pair { display: inline-flex; gap: 6px; margin: 2px 0; align-items: center; }
.mk-inline-pair input[type="text"] { width: 150px; border: 1px solid rgba(23,33,58,0.16); border-radius: 10px; padding: 6px 10px; font-family: var(--gh-body); font-size: 13px; font-weight: 700; }
.mk-t td small { white-space: normal; }
@media (max-width: 560px) { .mk-cashout-form { grid-template-columns: 1fr; } .mk-cashout-form .gh-btn { grid-column: 1; grid-row: auto; } }

/* ---------------------------------------------------------------- activity tab and item codes */
.mk-act-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 14px 26px 18px; border-top: 1px solid var(--gh-line); }
.mk-act-search { display: flex; gap: 8px; flex: 1 1 320px; min-width: 0; margin: 0; }
.mk-act-search input[type="text"] { flex: 1 1 auto; min-width: 0; padding: 9px 12px; border: 1px solid var(--gh-line); border-radius: 12px; font: inherit; font-size: 14px; }
.mk-act-search select { padding: 8px 10px; border: 1px solid var(--gh-line); border-radius: 12px; font: inherit; font-size: 13px; background: #fff; }
.mk-seg { display: inline-flex; flex-wrap: wrap; max-width: 100%; gap: 2px; padding: 3px; background: #f3f5f9; border: 1px solid var(--gh-line); border-radius: 12px; }
.mk-seg a { padding: 7px 12px; border-radius: 9px; font-weight: 800; font-size: 13px; color: var(--gh-muted); text-decoration: none; white-space: nowrap; }
.mk-seg a:hover { color: var(--gh-gold-deep); }
.mk-seg a.is-on { background: #fff; color: var(--gh-ink); box-shadow: 0 1px 3px rgba(20, 30, 60, .12); }
.mk-act-sum { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.mk-act-t td { vertical-align: middle; }
.mk-act-rank { width: 36px; color: var(--gh-muted); font-weight: 800; }
.mk-act-item { min-width: 240px; white-space: nowrap; }
.mk-act-name { display: inline-block; vertical-align: middle; white-space: normal; max-width: 320px; }
.mk-act-name > a { font-weight: 800; color: var(--gh-ink); text-decoration: none; }
.mk-act-name > a:hover { color: var(--gh-gold-deep); }
.mk-act-name small a { color: var(--gh-sky); font-weight: 800; }
.mk-act-foot { margin: 12px 4px 0; font-size: 13px; color: var(--gh-muted); }
.mk-muted { color: var(--gh-muted); }
.mk-code-link { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12.5px; font-weight: 700; color: var(--gh-sky); text-decoration: none; letter-spacing: .02em; }
.mk-code-link:hover { text-decoration: underline; }
.mk-code { grid-column: 1 / -1; font-size: 11.5px; font-weight: 700; color: var(--gh-muted); overflow-wrap: anywhere; }
.mk-code a, .mk-detail .mk-d-id a { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--gh-sky); text-decoration: none; letter-spacing: .02em; }
.mk-code a:hover, .mk-detail .mk-d-id a:hover { text-decoration: underline; }
@media (max-width: 820px) { .mk-act-bar { padding-left: 18px; padding-right: 18px; } .mk-act-search { flex-basis: 100%; } }

/* ---------------------------------------------------------------- item page (action=item) */
.mk-back { margin: 0 0 4px; font-size: 13px; font-weight: 800; }
.mk-back a { color: var(--gh-sky); text-decoration: none; }
.mk-seg a small { color: var(--gh-muted); font-weight: 700; margin-left: 4px; }
.mk-act-note { font-size: 13px; color: var(--gh-muted); }
.mk-item-top { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 18px; align-items: start; }
.mk-item-card { padding: 14px; min-width: 0; }
.mk-item-card .mk-frame { margin-bottom: 12px; }
.mk-item-card .mk-name b { font-weight: 800; color: #fff; }
.mk-desc { font-size: 13.5px; color: var(--gh-ink); }
.mk-desc p { margin: 0 0 4px; }
.mk-desc hr { border: 0; border-top: 1px solid var(--gh-line); margin: 8px 0; }
.mk-desc .mk-d-key { font-weight: 800; color: var(--gh-gold-deep); }
.mk-item-side { display: grid; gap: 14px; min-width: 0; }
.mk-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.mk-stat { background: #fff; border: 1px solid var(--gh-line); border-radius: 14px; padding: 12px 14px; min-width: 0; }
.mk-stat small { display: block; color: var(--gh-muted); font-weight: 800; font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; }
.mk-stat b { display: block; font-family: var(--gh-display); font-weight: 600; font-size: 20px; line-height: 1.25; overflow-wrap: anywhere; }
.mk-stat em { display: block; font-style: normal; font-size: 12px; color: var(--gh-muted); }
.mk-chart-card { padding: 6px 0 0; min-width: 0; }
.mk-chart-wrap { position: relative; padding: 4px 14px 14px; }
.mk-chart-wrap canvas { display: block; width: 100%; height: 220px; }
.mk-chart-tip { position: absolute; pointer-events: none; transform: translate(-50%, -135%); background: var(--gh-ink, #1d2433); color: #fff; font-size: 12px; font-weight: 800; padding: 5px 9px; border-radius: 8px; white-space: nowrap; }
.mk-sales { padding: 2px 0; }
.mk-sale { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--gh-line); align-items: start; }
.mk-sale:last-child { border-bottom: 0; }
.mk-sale .mk-icon-sm { margin-right: 0; }
.mk-sale-main { min-width: 0; font-size: 14px; }
.mk-sale-main > b { font-weight: 800; }
.mk-sale-who { font-size: 12.5px; color: var(--gh-muted); margin-top: 2px; overflow-wrap: anywhere; }
.mk-chips { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 6px; font-size: 12px; font-weight: 800; }
.mk-chip { display: inline-flex; align-items: center; gap: 4px; }
.mk-chip img { width: 16px; height: 16px; }
.mk-chip.is-card { color: var(--gh-ink); }
.mk-chip.is-pos { color: #1f8a4c; }
.mk-chip.is-neg { color: #c0392b; }
.mk-sale-price { text-align: right; white-space: nowrap; }
.mk-sale-price b { display: block; font-family: var(--gh-display); font-weight: 600; font-size: 17px; color: var(--gh-gold-deep); }
.mk-sale-price small { display: block; font-size: 12px; color: var(--gh-muted); }
.mk-item-empty { padding: 16px 18px; }
.mk-item-empty a { color: var(--gh-sky); font-weight: 800; }
@media (max-width: 900px) { .mk-item-top { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .mk-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .mk-sale { grid-template-columns: auto minmax(0, 1fr); } .mk-sale-price { grid-column: 2; text-align: left; } }

/* ---- staff cash-out page (market/cashouts) ---- */
.mk-pill.is-warn { background: #fde8ec; color: #b4324f; }
.mk-stat.is-hot { border-color: rgba(224, 150, 42, 0.55); background: #fff8ec; }
.mk-co-stats { padding: 16px 26px 22px; }
.mk-co-closed { margin: 0 26px 22px; }
.mk-co-queue { display: grid; }
.mk-co-req { display: grid; grid-template-columns: 150px minmax(0, 1fr) minmax(260px, 340px); gap: 18px; padding: 16px 18px; border-top: 1px solid var(--gh-line); align-items: start; }
.mk-co-amt b { display: block; font-family: var(--gh-display); font-weight: 600; font-size: 28px; line-height: 1.1; color: var(--gh-gold-deep); }
.mk-co-amt small { display: block; color: var(--gh-muted); font-size: 12.5px; font-weight: 700; margin-top: 2px; }
.mk-co-main { display: grid; gap: 8px; min-width: 0; font-size: 14px; }
.mk-co-top { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; color: var(--gh-muted); font-size: 13px; font-weight: 700; }
.mk-co-id { font-weight: 800; color: var(--gh-ink); font-size: 15px; }
.mk-co-k { display: inline-block; min-width: 118px; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--gh-muted); }
.mk-co-send { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; background: #f6f7fa; border-radius: 12px; padding: 10px 12px; }
.mk-co-send b { font-weight: 800; }
.mk-co-holder { font-weight: 700; }
.mk-co-num { display: inline-flex; gap: 6px; align-items: center; }
.mk-co-num code { font-size: 15px; font-weight: 800; color: var(--gh-ink); background: #fff; border: 1px solid var(--gh-line); border-radius: 8px; padding: 3px 8px; letter-spacing: .02em; overflow-wrap: anywhere; }
.mk-co-copy { border: 1px solid rgba(23,33,58,0.16); background: #fff; border-radius: 8px; padding: 3px 9px; font: inherit; font-size: 12px; font-weight: 800; color: var(--gh-sky); cursor: pointer; }
.mk-co-who, .mk-co-src { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.mk-co-who small { color: var(--gh-muted); }
.mk-co-chip { display: inline-block; border-radius: 999px; padding: 2px 9px; font-size: 12px; font-weight: 800; background: var(--gh-good-bg); color: var(--gh-good-ink); }
.mk-co-chip.is-out { background: #eef1f6; color: var(--gh-muted); }
.mk-co-chip.is-warn { background: #fde8ec; color: #b4324f; }
.mk-co-flag { margin: 0; font-size: 13px; font-weight: 700; color: #b4324f; }
.mk-co-acts { display: grid; gap: 8px; }
.mk-co-form { display: flex; gap: 6px; margin: 0; }
.mk-co-form input[type="text"] { flex: 1 1 auto; min-width: 0; border: 1px solid rgba(23,33,58,0.16); border-radius: 10px; padding: 7px 10px; font-family: var(--gh-body); font-size: 13px; font-weight: 700; }
.mk-co-form .gh-btn { flex: 0 0 96px; justify-content: center; }
.mk-co-search { padding: 4px 18px 12px; }
.mk-co-ref { white-space: normal !important; max-width: 260px; }
.mk-co-audit { padding: 0; }
.mk-co-audit summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 16px 18px; }
.mk-co-audit summary::-webkit-details-marker { display: none; }
.mk-co-audit summary b { font-family: var(--gh-display); font-weight: 600; font-size: 18px; }
.mk-co-audit summary small { color: var(--gh-muted); font-weight: 700; margin-left: 6px; }
.mk-co-audit .mk-co-when-open, .mk-co-audit[open] .mk-co-when-shut { display: none; }
.mk-co-audit[open] .mk-co-when-open { display: inline; }
.mk-co-audit-body { display: grid; gap: 12px; padding: 0 0 18px; border-top: 1px solid var(--gh-line); }
.mk-co-audit-note { margin: 0; padding: 0 18px; font-size: 13px; color: var(--gh-muted); }
.mk-co-audit-body > .mk-co-audit-note:first-child { padding-top: 12px; }
.mk-co-audit-t td small { font-size: 12px; }
.mk-co-audit-t .mk-co-sec td { background: #f6f7fa; font-size: 11.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--gh-muted); padding-top: 7px; padding-bottom: 7px; }
.mk-co-audit-t .mk-co-total td { font-weight: 800; }
.mk-co-audit-t .mk-co-tax td { background: #fff8ec; font-weight: 800; color: var(--gh-gold-deep); border-top: 2px solid rgba(224, 150, 42, 0.45); }
.mk-co-audit-t .mk-co-tax td small { color: var(--gh-muted); font-weight: 700; }
.mk-co-now { padding: 0 18px; }
@media (max-width: 1000px) { .mk-co-req { grid-template-columns: 130px minmax(0, 1fr); } .mk-co-acts { grid-column: 1 / -1; grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .mk-co-req { grid-template-columns: minmax(0, 1fr); gap: 10px; } .mk-co-acts { grid-template-columns: minmax(0, 1fr); } .mk-co-k { min-width: 0; width: 100%; } .mk-co-stats { padding: 14px 18px 18px; grid-template-columns: minmax(0, 1fr); } .mk-co-closed { margin: 0 18px 18px; } .mk-co-now { grid-template-columns: minmax(0, 1fr); } }
.mk-co-link { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }

/* ---- staff zeny log (market/zeny) ---- */
.mk-zl-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 16px 26px 22px; }
.mk-zl-stats .mk-stat b { font-size: 18px; }
.mk-zl-in, .mk-t td.mk-zl-in { color: var(--gh-good-ink); }
.mk-zl-out, .mk-t td.mk-zl-out { color: #9a5b0c; }
.mk-zl-warn { border-left: 6px solid #d9536f; }
.mk-zl-acct { margin: 0 18px 12px; padding: 14px 16px; border: 1px solid var(--gh-line); border-radius: 14px; background: #fbfcfe; display: grid; gap: 10px; }
.mk-zl-acct-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; }
.mk-zl-acct-top small { color: var(--gh-muted); font-weight: 700; }
.mk-zl-acct-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.mk-zl-acct-grid > div { background: #fff; border: 1px solid var(--gh-line); border-radius: 12px; padding: 9px 11px; min-width: 0; }
.mk-zl-acct-grid > div.is-hot { border-color: rgba(217, 83, 111, 0.55); background: #fff4f6; }
.mk-zl-acct-grid small { display: block; font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--gh-muted); }
.mk-zl-acct-grid b { display: block; font-family: var(--gh-display); font-weight: 600; font-size: 16px; overflow-wrap: anywhere; }
.mk-zl-acct-grid em { display: block; font-style: normal; font-size: 12px; color: var(--gh-muted); }
.mk-zl-note { margin: 0; font-size: 13px; font-weight: 700; color: #9a5b0c; }
.mk-zl-pad { padding: 0 18px 10px; }
.mk-zl-foot { margin: 0; padding: 8px 18px 12px; font-size: 12.5px; color: var(--gh-muted); }
@media (max-width: 1000px) { .mk-zl-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .mk-zl-acct-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .mk-zl-stats { padding: 14px 18px 18px; } .mk-zl-acct-grid b { font-size: 14px; } .mk-zl-acct { margin: 0 12px 12px; } .mk-zl-acct-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Individual compounded cards: visible before opening the equipment tooltip. */
.mk-card-list { display: grid; gap: 5px; margin: 9px 13px 0; min-width: 0; }
.mk-card-entry { min-width: 0; border: 1px solid #dde4ef; border-radius: 9px; background: #f5f8fd; color: #263654; }
.mk-card-entry > summary { display: flex; align-items: center; gap: 7px; min-height: 36px; padding: 5px 7px; cursor: pointer; list-style: none; }
.mk-card-entry > summary::-webkit-details-marker { display: none; }
.mk-card-entry > summary::after { content: '+'; margin-left: auto; flex: none; font-weight: 800; }
.mk-card-entry[open] > summary::after { content: '\2212'; }
.mk-card-entry > summary:hover { background: rgba(61,111,196,.08); border-radius: 9px; }
.mk-card-entry > summary:focus-visible { outline: 2px solid #3e6fc4; outline-offset: 2px; border-radius: 9px; }
.mk-card-entry summary img { width: 24px; height: 24px; flex: none; image-rendering: pixelated; object-fit: contain; }
.mk-card-entry summary strong { font-size: 12px; line-height: 1.3; overflow-wrap: anywhere; }
.mk-card-entry summary small { color: #687790; font-size: 10px; white-space: nowrap; }
.mk-card-body { padding: 8px 9px; border-top: 1px solid #dde4ef; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.mk-card-body p { margin: 0 0 5px; }
.mk-card-body p:last-child { margin-bottom: 0; }
.mk-card-body a { color: #215ec4; text-decoration: underline; }
.mk-card-rawuid, .mk-card-unavailable { color: #687790; font-size: 11px; }
.mk-detail .mk-card-list { margin: 7px 0; }
.mk-detail .mk-card-entry { background: rgba(255,255,255,.05); border-color: #3b4661; color: #e2eaff; }
.mk-detail .mk-card-entry summary small, .mk-detail .mk-card-unavailable, .mk-detail .mk-card-rawuid { color: #aab8d2; }
.mk-detail .mk-card-body { border-color: #3b4661; }
.mk-detail .mk-card-body a { color: #a8ceff; }

/* Single-listing share page. Keep the item readable without hovering. */
.mk-sale-page { padding:24px; }
.mk-sale-layout { display:grid; grid-template-columns:minmax(220px,300px) minmax(0,1fr); gap:28px; align-items:start; }
.mk-sale-description p { overflow-wrap:anywhere; }
.mk-sale-description input { display:block; width:100%; padding:10px; margin:8px 0; }
.mk-sale-page .mk-detail, .mk-sale-page .mk-info, .mk-sale-page .mk-foot-act { display:none; }
@media(max-width:650px) { .mk-sale-layout { grid-template-columns:minmax(0,1fr); } .mk-sale-page { padding:16px; } }

/* Image/name clicks navigate; the explicit info button opens the overlay. */
.mk-item.is-player-listing:not(.is-open) .mk-frame:hover .mk-detail { opacity:0; visibility:hidden; pointer-events:none; }

/* Sale tiles navigate to the complete listing; no overlay covers the art. */
.mk-item.is-player-listing .mk-detail { display:none !important; }
.mk-item.is-player-listing .mk-info { text-decoration:none; display:inline-flex; align-items:center; justify-content:center; }
.mk-item.is-player-listing { align-self:start; }

/* Revision 4: consistent sale tile geometry, including narrow columns. */
.mk-grid { align-items:stretch; }
.mk-item.is-player-listing {
 display:flex; flex-direction:column; align-self:stretch;
 min-width:0; max-width:100%; box-sizing:border-box; overflow:hidden;
}
.mk-item.is-player-listing .mk-frame {
 flex:none; min-width:0; max-width:calc(100% - 16px); box-sizing:border-box;
 margin:8px 8px 0; padding:7px; box-shadow:inset 0 0 0 1px rgba(224,150,42,.45);
}
.mk-item.is-player-listing .mk-canvas {
 width:100%; min-width:0; height:218px; box-sizing:border-box;
 padding:12px 12px 24px; background:#fff;
}
.mk-item.is-player-listing .mk-pic {
 display:block; width:auto; height:auto; max-width:100%; max-height:182px;
 object-fit:contain; object-position:center; margin:auto; filter:none;
}
.mk-item.is-player-listing .mk-name {
 display:grid; grid-template-columns:20px minmax(0,1fr) 24px;
 gap:6px; min-width:0; min-height:52px; box-sizing:border-box; padding:8px 2px 2px;
}
.mk-item.is-player-listing .mk-name img { width:20px; height:20px; }
.mk-item.is-player-listing .mk-name > a:not(.mk-info) {
 white-space:normal; overflow-wrap:anywhere; font-size:13px; line-height:1.3;
}
.mk-item.is-player-listing .mk-card-list { flex:none; min-height:36px; }
.mk-item.is-player-listing .mk-card-spacer { height:36px; margin:9px 13px 0; flex:none; }
.mk-item.is-player-listing .mk-foot {
 margin-top:auto; padding:12px 14px 14px; min-width:0;
 grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:8px;
}
.mk-item.is-player-listing .mk-id { font-size:11px; }
.mk-item.is-player-listing .mk-price { grid-column:1 / -1; line-height:1.3; }
.mk-item.is-player-listing .mk-foot-act {
 grid-column:1 / -1; justify-self:stretch; text-align:center; min-width:0;
}
.mk-item.is-player-listing .mk-foot-act > a,
.mk-item.is-player-listing .mk-foot-act > .mk-pill {
 display:flex; align-items:center; justify-content:center;
 width:100%; min-height:36px; padding:8px 10px; box-sizing:border-box;
 white-space:normal; margin:0;
}
.mk-item.is-player-listing .mk-code { grid-column:1 / -1; min-width:0; overflow-wrap:anywhere; }
.mk-sale-page .mk-item.is-player-listing .mk-foot-act { display:none; }
