/*
 * MGK Merchant legacy page rules.
 *
 * Extracted mechanically from mgk-retail.css so the Merchant portal and the
 * shopper storefront no longer share a page-style bundle. New Merchant CSS
 * belongs in mgk-merchant-shell.css, mgk-merchant-overview.css or
 * mgk-merchant-commerce.css; this file preserves the remaining page rules
 * until those screens are migrated into their final bundles.
 */

/* ── S-030 Operational Dashboard (merchant-only, edge-to-edge shell) ───────── */
/* This page ships its own topbar and never renders .mgk-header, so the
   sitewide body padding-top reserved for that fixed header (line 74) is
   dead space here — zero it, leaving only WP's own admin-bar offset. */
body:has(.mgk-opdash) { padding-top: 0; }
.mgk-opdash { min-height: 100vh; background: var(--mgk-bg); }
.mgk-opdash__shell { display: flex; align-items: stretch; min-height: 100vh; }

.mgk-opdash__gate { display: flex; align-items: center; justify-content: center; min-height: 100vh; padding: 32px; }
.mgk-opdash__gate-card { max-width: 380px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.mgk-opdash__gate-icon { font-size: 32px; margin: 0; }
.mgk-opdash__gate-title { font-size: 20px; font-weight: 800; color: var(--mgk-text); margin: 0; }
.mgk-opdash__gate-text { font-size: 14px; color: var(--mgk-text-2); margin: 0 0 8px; }

/* Pinned while .mgk-opdash__main scrolls (long product tables/forms) — the
   shell's own height (stretched to match main's content) gives this sticky
   sidebar real room to stick within, same reasoning as .mgk-mp__form-side
   below. Disabled on narrow screens (see @media below), where the sidebar
   collapses into a horizontal top bar instead of a full-height column. */
.mgk-opdash__sidebar { flex: 0 0 240px; width: 240px; background: var(--mgk-navy); color: #fff; display: flex; flex-direction: column; padding: 20px 0; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.mgk-opdash__brand { display: flex; align-items: center; gap: 10px; padding: 0 20px 20px; }
.mgk-opdash__brand-badge { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 10px; background: var(--mgk-navy-800, #0A2A5C); color: #fff; font-weight: 700; font-size: 12px; flex: none; }
.mgk-opdash__brand-name { font-size: 14px; font-weight: 700; color: #fff; margin: 0; line-height: 1.4; }
.mgk-opdash__brand-tag { font-size: 12px; color: rgba(255,255,255,.6); margin: 0; }

.mgk-opdash__nav { display: flex; flex-direction: column; gap: 2px; padding: 0 12px; flex: 1 1 auto; }
.mgk-opdash__nav-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; color: rgba(255,255,255,.85); text-decoration: none; font-size: 14px; font-weight: 500; cursor: pointer; }
.mgk-opdash__nav-item:hover { background: rgba(255,255,255,.06); }
.mgk-opdash__nav-item.is-active { background: var(--mgk-cta-blue); color: #fff; }
.mgk-opdash__nav-item.is-disabled { color: rgba(255,255,255,.35); cursor: default; justify-content: space-between; }
.mgk-opdash__nav-item.is-disabled:hover { background: none; }
.mgk-opdash__nav-icon { font-size: 14px; flex: none; }
.mgk-opdash__nav-label { flex: 1 1 auto; }
.mgk-opdash__nav-soon { font-size: 10px; text-transform: uppercase; letter-spacing: .04em; background: rgba(255,255,255,.1); padding: 2px 6px; border-radius: 999px; }

.mgk-opdash__nav-footer { display: flex; flex-direction: column; gap: 6px; padding: 16px 20px 0; margin-top: 8px; border-top: 1px solid var(--mgk-navy-md); }
.mgk-opdash__nav-footer-item { font-size: 12px; color: rgba(255,255,255,.45); display: flex; justify-content: space-between; gap: 8px; }
.mgk-opdash__nav-footer-item em { font-style: normal; font-size: 10px; text-transform: uppercase; opacity: .8; }

.mgk-opdash__profile { display: flex; align-items: center; gap: 10px; padding: 16px 20px 0; margin-top: 16px; border-top: 1px solid var(--mgk-navy-md); }
.mgk-opdash__profile-avatar { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 999px; background: var(--mgk-navy-md); color: #fff; font-weight: 700; font-size: 13px; flex: none; }
.mgk-opdash__profile-name { font-size: 14px; font-weight: 600; color: #fff; margin: 0; line-height: 1.4; }
.mgk-opdash__profile-role { font-size: 12px; color: rgba(255,255,255,.55); margin: 0; }

.mgk-opdash__main { flex: 1 1 auto; min-width: 0; padding: 24px 32px 48px; }
.mgk-opdash__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
/* Operational dashboard uses its own class but must read as the same title. */
.mgk-opdash__heading { margin: 0; font-family: var(--mdash-font-display); font-weight: 700; font-size: 23px; line-height: 1.25; letter-spacing: -0.01em; color: var(--mgk-text); }
.mgk-opdash__sub { font-size: 14px; color: var(--mgk-text-3); margin: 4px 0 0; }
.mgk-opdash__actions { display: flex; gap: 8px; flex-wrap: wrap; }

.mgk-opdash__kpis { margin-bottom: 20px; }
.mgk-opdash__kpi { border-radius: var(--mgk-radius); padding: 20px; border: 1px solid var(--mgk-border); }
.mgk-opdash__kpi-icon { font-size: 24px; line-height: 1; margin-bottom: 8px; }
.mgk-opdash__kpi-value { font-size: 24px; font-weight: 800; line-height: 1.5; }
.mgk-opdash__kpi-delta { font-size: 12px; color: var(--mgk-text-2); margin: 4px 0 0; }
.mgk-opdash__kpi-label { font-size: 12px; color: var(--mgk-text-3); margin: 2px 0 0; }
.mgk-opdash__kpi--green { background: var(--mgk-green-bg); border-color: rgba(34,168,107,.13); }
.mgk-opdash__kpi--green .mgk-opdash__kpi-value { color: var(--mgk-green); }
.mgk-opdash__kpi--blue { background: var(--mgk-sfa-bg); border-color: rgba(21,101,192,.13); }
.mgk-opdash__kpi--blue .mgk-opdash__kpi-value { color: var(--mgk-blue); }
.mgk-opdash__kpi--red { background: var(--mgk-red-bg); border-color: rgba(232,80,64,.13); }
.mgk-opdash__kpi--red .mgk-opdash__kpi-value { color: var(--mgk-red); }
.mgk-opdash__kpi--amber { background: var(--mgk-amber-bg); border-color: rgba(240,152,48,.13); }
.mgk-opdash__kpi--amber .mgk-opdash__kpi-value { color: var(--mgk-amber); }

.mgk-opdash__row { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; margin-bottom: 16px; align-items: start; }
.mgk-opdash__chart-card, .mgk-opdash__fleet-card, .mgk-opdash__oos-card, .mgk-opdash__orders-card { display: flex; flex-direction: column; gap: 4px; }
.mgk-opdash__chart-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.mgk-opdash__chart-tabs { display: flex; gap: 4px; background: var(--mgk-bg-alt); border-radius: var(--mgk-radius-sm, 8px); padding: 3px; }
.mgk-opdash__chart-tab { font-size: 13px; font-weight: 600; color: var(--mgk-text-2); text-decoration: none; padding: 5px 12px; border-radius: 6px; }
.mgk-opdash__chart-tab:hover { color: var(--mgk-text); }
.mgk-opdash__chart-tab.is-active { background: var(--mgk-surface); color: var(--mgk-navy); box-shadow: var(--mgk-shadow); }
.mgk-opdash__chart { width: 100%; height: auto; margin-top: 12px; }
.mgk-opdash__chart-grid { stroke: var(--mgk-border); stroke-width: 1; }
.mgk-opdash__chart-axis { font-size: 10.5px; fill: var(--mgk-text-3); font-family: var(--mgk-font); }
.mgk-opdash__chart-line { stroke: var(--mgk-navy); stroke-width: 2.5; }
.mgk-opdash__chart-dot { fill: var(--mgk-navy); }
.mgk-opdash__empty { font-size: 14px; color: var(--mgk-text-3); padding: 12px 0; margin: 0; }

.mgk-opdash__fleet-cap { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; color: var(--mgk-text-2); margin-top: 12px; }
.mgk-opdash__fleet-cap strong { color: var(--mgk-text); }
.mgk-opdash__fleet-bar { background: var(--mgk-border); height: 8px; border-radius: 999px; overflow: hidden; margin: 8px 0 4px; }
.mgk-opdash__fleet-bar-fill { display: block; height: 100%; border-radius: 999px; background: var(--mgk-cta-blue); }
.mgk-opdash__fleet-bar-fill.is-hot { background: var(--mgk-amber); }
.mgk-opdash__fleet-note { font-size: 12px; color: var(--mgk-text-3); margin: 0 0 8px; }
.mgk-opdash__fleet-note--warn { color: var(--mgk-amber); }
.mgk-opdash__pickers { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.mgk-opdash__picker { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 10px; border-top: 1px solid var(--mgk-border-lt); }
.mgk-opdash__picker:first-child { border-top: 0; padding-top: 0; }
.mgk-opdash__picker-name { font-size: 13px; font-weight: 600; color: var(--mgk-text); margin: 0; }
.mgk-opdash__picker-meta { font-size: 12px; color: var(--mgk-text-3); margin: 0; }

.mgk-opdash__oos-item, .mgk-opdash__order-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--mgk-border-lt); }
.mgk-opdash__oos-item:first-of-type, .mgk-opdash__order-row:first-of-type { border-top: 0; padding-top: 8px; }
.mgk-opdash__oos-name, .mgk-opdash__order-id { font-size: 14px; font-weight: 600; color: var(--mgk-text); margin: 0; }
.mgk-opdash__oos-meta, .mgk-opdash__order-meta { font-size: 12px; color: var(--mgk-text-3); margin: 2px 0 0; }
.mgk-opdash__order-actions { display: flex; align-items: center; gap: 8px; }

@media (max-width: 1024px) {
	.mgk-opdash__row { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
	.mgk-opdash__shell { flex-direction: column; }
	.mgk-opdash__sidebar { width: 100%; flex-direction: row; flex-wrap: wrap; align-items: center; padding: 12px 16px; gap: 12px; position: static; height: auto; overflow: visible; }
	.mgk-opdash__nav { flex-direction: row; flex-wrap: wrap; padding: 0; }
	.mgk-opdash__nav-footer, .mgk-opdash__profile { display: none; }
	.mgk-opdash__main { padding: 20px 16px 40px; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * MERCHANT PRODUCTS (S-032) — migrated onto the shared mgk_merchant_chrome_
 * start()/end() shell (.mgk-mdash__*) and .mgk-mord__*-style list/detail
 * conventions, matching Orders/Customers/Low-Stock. Only the form-field/
 * wizard primitives below (.mgk-mp__*) are page-specific.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mp__notice { padding: 10px 16px; border-radius: var(--mgk-radius-sm); font-size: 14px; font-weight: 600; margin-bottom: 16px; }
.mgk-mp__notice--success { background: var(--mgk-green-bg); color: var(--mgk-green); }
.mgk-mp__notice--error { background: var(--mgk-red-bg); color: var(--mgk-red); }

.mgk-mp__label { display: block; font-size: 11px; font-weight: 600; font-family: 'Quicksand', var(--mgk-font); color: var(--mdash-text-4); margin: 14px 0 6px; }
.mgk-mp__label:first-child { margin-top: 0; }
.mgk-mp__input { width: 100%; height: 40px; border: 1px solid var(--mdash-border); border-radius: 8px; padding: 0 12px; font-size: 13px; font-family: 'Quicksand', var(--mgk-font); color: var(--mdash-text); background: #fff; box-sizing: border-box; }
.mgk-mp__input:focus { outline: none; border-color: var(--mdash-accent); }
.mgk-mp__textarea { height: auto; min-height: 110px; padding: 10px 12px; line-height: 1.5; overflow-y: auto; resize: vertical; box-sizing: border-box; }
.mgk-mp__input--sm { width: auto; display: inline-block; }
.mgk-mp__select-multi { height: auto; }
.mgk-mp__checkbox { display: flex; align-items: center; gap: 8px; font-size: 13px; font-family: 'Quicksand', var(--mgk-font); color: var(--mdash-text); margin: 14px 0; }
.mgk-mp__checkbox--inline { font-size: 12px; margin: 0; }
.mgk-mp__checkbox input[type="checkbox"] { accent-color: var(--mdash-accent); }
.mgk-mp__checkbox--danger { color: var(--mgk-merchant-danger); font-weight: 600; }
.mgk-mp__checkbox--danger input[type="checkbox"] { accent-color: var(--mgk-merchant-danger); }
.mgk-mp__hint { font-size: 12px; font-family: 'Quicksand', var(--mgk-font); color: var(--mdash-text-3); margin: 6px 0 0; }
.mgk-mp__hint--danger { color: var(--mgk-merchant-danger); }

.mgk-mp__row { display: grid; gap: 14px; margin-bottom: 4px; }
.mgk-mp__row--2 { grid-template-columns: 1fr 1fr; }
.mgk-mp__row--3 { grid-template-columns: 1fr 1fr 1fr; }

/* ── Catalog Hub quick-links row (list view header) ──────────────────── */
.mgk-mp__catalog-hub { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; margin-bottom: 16px; }
.mgk-mp__catalog-link { display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; background: #fff; border: 1px solid var(--mdash-border); border-radius: 10px; text-decoration: none; }
.mgk-mp__catalog-link:hover { background: var(--mdash-bg-soft); }
.mgk-mp__catalog-link strong { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12.5px; color: var(--mdash-text); }

/* ── Small badges reused across the form/detail view ─────────────────── */
.mgk-mp__tag-mgk { display: inline-flex; align-items: center; font-family: 'Quicksand', var(--mgk-font); font-size: 10px; font-weight: 600; color: var(--mdash-accent-h); background: var(--mdash-accent-tint); border: 1px solid #E0B8FD; padding: 2px 7px; border-radius: 4px; }
.mgk-mp__tag-plain { display: inline-flex; align-items: center; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; font-weight: 600; color: var(--mdash-text-2); background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border); padding: 4px 9px; border-radius: 999px; }
.mgk-mp__tag-required { font-family: 'Quicksand', var(--mgk-font); font-size: 10px; font-weight: 600; color: var(--mdash-red); background: #FFF4F6; border: 1px solid #FFB8C1; padding: 1px 6px; border-radius: 4px; margin-left: 6px; }

/* ── Product list thumbnail/name (reuses .mgk-mord-detail__item-thumb for the box) ── */
.mgk-mp__thumb-ph { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; font-size: 16px; }
.mgk-mp__product-name { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12.5px; color: var(--mdash-text); }
.mgk-mp__product-sku { margin: 2px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); }

.mgk-mp__categories { display: flex; flex-direction: column; gap: 6px; max-height: 200px; overflow-y: auto; margin-bottom: 10px; padding: 10px; border: 1px solid var(--mdash-border); border-radius: 8px; }
.mgk-mp__cat-item { display: flex; align-items: center; gap: 8px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text); }
.mgk-mp__cat-item-row { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.mgk-mp__cat-add { display: flex; gap: 6px; }
.mgk-mp__cat-add .mgk-mp__input { flex: 1 1 auto; }

.mgk-mp__mod-list { display: flex; flex-direction: column; gap: 8px; }
.mgk-mp__mod-item { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; border: 1px solid var(--mdash-border); border-radius: 9px; font-family: 'Quicksand', var(--mgk-font); }
.mgk-mp__mod-item strong { font-size: 12.5px; color: var(--mdash-text); }
.mgk-mp__mod-item small { display: block; margin-top: 2px; font-size: 11px; color: var(--mdash-text-4); }
.mgk-mp__mod-item input[type="checkbox"] { margin-top: 2px; }
.mgk-mp__mod-item--ro { padding-left: 0; border: none; padding-top: 0; padding-bottom: 0; }

/* ── Read-only detail-view fields ─────────────────────────────────────── */
.mgk-mp__ro-field { margin-bottom: 14px; }
.mgk-mp__ro-value { min-height: 40px; padding: 0 12px; border: 1px solid var(--mdash-border-lt); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-size: 13px; color: var(--mdash-text); background: var(--mdash-bg-page); box-sizing: border-box; display: flex; align-items: center; }
.mgk-mp__ro-value--block { display: block; min-height: 76px; padding: 11px 12px; border: 1px solid var(--mdash-border); background: transparent; font-size: 12.5px; color: var(--mdash-text-2); line-height: 1.55; }
.mgk-mp__ro-value--block > *:first-child { margin-top: 0; }
.mgk-mp__ro-value--block > *:last-child { margin-bottom: 0; }

.mgk-mp__image-preview { min-height: 60px; margin-bottom: 10px; border-radius: 10px; overflow: hidden; }
.mgk-mp__image-preview img { width: 100%; border-radius: 10px; display: block; }
.mgk-mp__image-preview--ro { height: 140px; display: flex; align-items: center; justify-content: center; background: var(--mdash-bg-soft); }
.mgk-mp__image-preview--ro img { height: 100%; object-fit: cover; }

.mgk-mp__gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 10px; }
.mgk-mp__gallery-item { position: relative; cursor: grab; }
.mgk-mp__gallery-item img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 7px; }
.mgk-mp__gallery-remove { position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; border-radius: 999px; border: none; background: var(--mgk-merchant-danger); color: #fff; cursor: pointer; line-height: 1; font-size: 13px; }

.mgk-mp__box-actions { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.mgk-mp__box-actions .mgk-btn { width: 100%; }

/* ── Import CSV form + result summary (now rendered inside the popup modal below) ── */
.mgk-mp__import-form { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.mgk-mp__import-form input[type="file"] { font-size: 13px; }
.mgk-mp__import-form .mgk-btn { margin-top: 8px; }
.mgk-mp__import-summary { margin-bottom: 16px; }
.mgk-mp__import-summary h4 { font-size: 13px; font-weight: 700; color: var(--mdash-text); margin: 0 0 6px; }
.mgk-mp__import-summary h4:not(:first-child) { margin-top: 16px; }
.mgk-mp__import-summary ul { margin: 0; padding-left: 18px; }
.mgk-mp__import-summary li { font-size: 13px; color: var(--mdash-text-3); margin-bottom: 4px; }

.mgk-mp__io-cancel-form { display: inline-block; margin-top: 10px; }

/* ── Import/Export popup modal (mapping/progress/done steps) ─────────── */
.mgk-mp-modal-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.4); z-index: 60; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mgk-mp-modal { width: 760px; max-width: 96vw; max-height: 90vh; background: #fff; border-radius: 14px; border: 1px solid var(--mdash-border); overflow: hidden; display: flex; flex-direction: column; }
.mgk-mp-modal__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 22px 14px; border-bottom: 1px solid var(--mdash-border-lt); }
.mgk-mp-modal__title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 17px; color: var(--mdash-text); }
.mgk-mp-modal__close { border: none; background: transparent; font-size: 22px; line-height: 1; color: var(--mdash-text-3); cursor: pointer; padding: 4px; }
.mgk-mp-modal__close:hover { color: var(--mdash-text); }
.mgk-mp-modal__body { padding: 18px 22px 22px; max-height: 70vh; overflow-y: auto; }
.mgk-mp-modal__body .mgk-mp__hint:first-child { margin-top: 0; }

/* ── Import/Export wizard: mapping, progress, done steps ─────────────── */
.mgk-mp__mapping-table-wrap { overflow-x: auto; margin-bottom: 14px; }
.mgk-mp__mapping-table { width: 100%; border-collapse: collapse; }
.mgk-mp__mapping-table th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .03em; color: var(--mdash-text-4); padding: 6px 10px; border-bottom: 1px solid var(--mdash-border); }
.mgk-mp__mapping-table td { padding: 8px 10px; border-bottom: 1px solid var(--mdash-border); font-size: 13px; vertical-align: middle; }
.mgk-mp__mapping-table td:first-child { font-weight: 600; color: var(--mdash-text); }
.mgk-mp__mapping-sample { color: var(--mdash-text-3); max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mgk-mp__mapping-table select { min-width: 220px; }

.mgk-mp__export-columns { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 4px 12px; margin-bottom: 12px; }

.mgk-mp__progress-card { text-align: center; padding: 32px 24px; }
.mgk-mp__progress-card progress { width: 100%; max-width: 480px; height: 10px; accent-color: var(--mdash-accent); }

.mgk-mp__done-card { text-align: left; }
.mgk-mp__done-title { margin: 0 0 8px; font-size: 20px; font-family: var(--mdash-font-display); }
.mgk-mp__done-title--error { color: var(--mdash-red); }
.mgk-mp__done-card > .mgk-btn { margin-top: 16px; }

@media (max-width: 640px) {
	.mgk-mp__row--2, .mgk-mp__row--3 { grid-template-columns: 1fr; }
	.mgk-mp__catalog-hub { grid-template-columns: 1fr 1fr; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-033 MERCHANT DASHBOARD — companion to S-030 Operational Dashboard.
 * Deliberately its OWN chrome (app header + light sidebar), matching the
 * MGK-Merchant-Admin.html design reference pixel-for-pixel — does NOT reuse
 * .mgk-opdash__* (that shell is dark-navy and single-row-header, this one is
 * a light sidebar + a separate full-width app header). Colors below are the
 * reference file's own literal hex values, not the site's --mgk-* tokens, so
 * this page can match the reference exactly regardless of site rebrands.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mdash {
	--mdash-accent: #9615DB;
	--mdash-accent-h: #7E10BC;
	--mdash-accent-p: #7C1AB8;
	--mdash-accent-tint: #F5EBFD;
	--mdash-accent-tint2: #DDB3F8;
	--mdash-border: #E9E6EF;
	--mdash-border-lt: #F1EFF5;
	--mdash-text: #1B1B1F;
	--mdash-text-2: #44404C;
	--mdash-text-3: #6E6A78;
	--mdash-text-4: #8A8494;
	--mdash-bg-page: #F7F6F9;
	--mdash-bg-soft: #F1EFF5;
	--mdash-green: #0E7C3F; --mdash-green-bg: #E7F6EC; --mdash-green-bd: #B8E9D2; --mdash-green-dot: #17A34A;
	--mdash-amber: #92610A; --mdash-amber-bg: #FBF2DF; --mdash-amber-bd: #F3DFB6; --mdash-amber-dot: #D8930F;
	--mdash-red: #B42121;
	--mdash-font-display: var(--mdash-font);
	height: 100vh;
	overflow: hidden;
	background: var(--mdash-bg-page);
}
body:has(.mgk-mdash) { padding-top: 0; }
/* WP admin bar pushes <html> down via margin-top (32px desktop / 46px ≤782px);
   without subtracting it here, .mgk-mdash's 100vh would overshoot the visible
   viewport by that amount and re-introduce whole-page scroll. */
body.admin-bar .mgk-mdash { height: calc(100vh - 32px); }
@media (max-width: 782px) { body.admin-bar .mgk-mdash { height: calc(100vh - 46px); } }

.mgk-mdash * { box-sizing: border-box; }
.mgk-mdash__shell { display: flex; flex-direction: column; height: 100%; }

/* ── Gate (logged out / not a manager) ─────────────────────────────────── */
.mgk-mdash .mgk-opdash__gate { display: flex; align-items: center; justify-content: center; min-height: 100vh; padding: 32px; }

/* ── App header (full width) ───────────────────────────────────────────── */
.mgk-mdash__header { flex-shrink: 0; height: 56px; display: flex; align-items: center; gap: 16px; padding: 0 18px 0 14px; background: #fff; border-bottom: 1px solid var(--mdash-border); position: relative; z-index: 20; }
.mgk-mdash__burger { width: 34px; height: 34px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border: none; background: transparent; border-radius: 8px; cursor: default; color: var(--mdash-text-2); }
.mgk-mdash__brand { display: flex; align-items: center; gap: 9px; flex-shrink: 0; }
.mgk-mdash__brand-mark { width: 30px; height: 30px; border-radius: 8px; background: var(--mdash-accent); display: flex; align-items: center; justify-content: center; font-family: var(--mdash-font-display); font-weight: 800; font-size: 17px; color: #fff; line-height: 1; }
.mgk-mdash__brand-word { font-family: var(--mdash-font-display); font-weight: 800; font-size: 18px; letter-spacing: -0.01em; color: var(--mdash-text); }
.mgk-mdash__brand-word b { color: var(--mdash-accent); font-weight: 800; }
.mgk-mdash__brand-badge { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 10px; letter-spacing: 0.06em; color: var(--mdash-accent); background: var(--mdash-accent-tint); border: 1px solid #E0B8FD; padding: 2px 6px; border-radius: 4px; text-transform: uppercase; }
.mgk-mdash__divider { width: 1px; height: 24px; background: var(--mdash-border); flex-shrink: 0; }
.mgk-mdash__store { display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 10px; border: 1px solid var(--mdash-border); background: #fff; border-radius: 8px; flex-shrink: 0; }
.mgk-mdash__store-chip { width: 20px; height: 20px; border-radius: 5px; background: var(--mdash-accent-tint2); display: flex; align-items: center; justify-content: center; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 9px; color: var(--mdash-accent-h); }
.mgk-mdash__store-name { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text); max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mgk-mdash__spacer { margin-left: auto; display: flex; align-items: center; gap: 10px; min-width: 0; flex-shrink: 0; }
.mgk-mdash__search { position: relative; display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px; background: var(--mdash-bg-soft); border-radius: 8px; width: 240px; min-width: 44px; flex-shrink: 1; }
.mgk-mdash__search-icon { flex-shrink: 0; color: var(--mdash-text-4); display: flex; }
.mgk-mdash__search-input { border: none; background: transparent; outline: none; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text); width: 100%; }
.mgk-mdash__search-input::placeholder { color: var(--mdash-text-4); }
.mgk-mdash__sim { display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; background: var(--mdash-amber-bg); border: 1px solid var(--mdash-amber-bd); border-radius: 999px; flex-shrink: 0; }
.mgk-mdash__sim-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--mdash-amber-dot); }
.mgk-mdash__sim-label { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-amber); white-space: nowrap; }
.mgk-mdash__viewstore { display: flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-2); flex-shrink: 0; text-decoration: none; }
.mgk-mdash__viewstore:hover { background: var(--mdash-bg-page); }
.mgk-mdash__bell { position: relative; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--mdash-border); background: #fff; border-radius: 8px; color: var(--mdash-text-2); flex-shrink: 0; text-decoration: none; }
.mgk-mdash__bell:hover { background: var(--mdash-bg-page); }
.mgk-mdash__bell-dot { position: absolute; top: 6px; right: 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--mdash-red); box-shadow: 0 0 0 2px #fff; }
.mgk-mdash__avatar { width: 36px; height: 36px; border-radius: 999px; background: var(--mdash-accent-tint); border: 1px solid #E0B8FD; display: flex; align-items: center; justify-content: center; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12px; color: var(--mdash-accent-p); flex-shrink: 0; text-decoration: none; }

/* ── Body: sidebar + main ───────────────────────────────────────────────── */
.mgk-mdash__body { display: flex; flex: 1; min-height: 0; }
.mgk-mdash__sidebar { flex-shrink: 0; width: 248px; background: #fff; border-right: 1px solid var(--mdash-border-lt); display: flex; flex-direction: column; }
.mgk-mdash__nav { flex: 1; min-height: 0; overflow-y: auto; padding: 12px 12px 8px; display: flex; flex-direction: column; gap: 2px; }
.mgk-mdash__nav-group { padding: 10px 12px 4px; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 10px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--mdash-text-4); }
.mgk-mdash__nav-group:not(:first-child) { padding-top: 14px; }
.mgk-mdash__nav-item { position: relative; display: flex; align-items: center; gap: 12px; height: 40px; flex-shrink: 0; padding: 0 12px; border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 12px; color: var(--mdash-text-2); text-decoration: none; }
.mgk-mdash__nav-item:hover { background: var(--mdash-bg-page); }
.mgk-mdash__nav-item.is-active { background: var(--mdash-accent-tint); color: var(--mdash-accent); }
.mgk-mdash__nav-item.is-soon { cursor: default; color: var(--mdash-text-2); }
.mgk-mdash__nav-item.is-soon:hover { background: transparent; }
.mgk-mdash__nav-icon { flex-shrink: 0; display: flex; }
.mgk-mdash__nav-label { flex: 1; white-space: nowrap; }
.mgk-mdash__nav-soon { font-family: 'Quicksand', var(--mgk-font); font-size: 9px; font-weight: 700; color: var(--mdash-text-4); flex-shrink: 0; }
.mgk-mdash__nav-badge { flex-shrink: 0; min-width: 20px; height: 18px; padding: 0 6px; border-radius: 999px; background: var(--mdash-accent); color: #fff; font-weight: 700; font-size: 10px; display: flex; align-items: center; justify-content: center; }
.mgk-mdash__nav-badge--amber { background: var(--mdash-amber-bg); border: 1px solid var(--mdash-amber-bd); color: var(--mdash-amber); }
.mgk-mdash__sidebar-foot { flex-shrink: 0; padding: 12px; border-top: 1px solid var(--mdash-border-lt); }
.mgk-mdash__foot-box { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px; background: var(--mdash-bg-page); }
.mgk-mdash__foot-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.mgk-mdash__foot-title { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mgk-mdash__foot-sub { font-family: 'Quicksand', var(--mgk-font); font-size: 10px; color: var(--mdash-text-4); white-space: nowrap; }

.mgk-mdash__main { flex: 1; min-width: 0; overflow-y: auto; }
.mgk-mdash__content { max-width: 1280px; margin: 0 auto; padding: 26px 30px 60px; }

/* ── Content head ───────────────────────────────────────────────────────── */
.mgk-mdash__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
/* THE page title, all 20 merchant screens. Every screen's h1 resolves here and
   nowhere else: the per-section overrides that used to restyle it (.mgk-msales
   shipped system-ui 650/22px, order detail 700/24px, and .mgk-opdash__heading
   800/22px with no family at all) are gone, so a title cannot drift per screen
   again without editing this line. line-height moved up from the .mgk-mcommerce
   copy so Products keeps the exact look it has today. */
.mgk-mdash__heading { margin: 0 0 4px; font-family: var(--mdash-font-display); font-weight: 700; font-size: 23px; line-height: 1.25; letter-spacing: -0.01em; color: var(--mdash-text); user-select: none; }
.mgk-mdash__sub { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 14px; color: var(--mdash-text-4); }
.mgk-mdash__sub b { color: var(--mdash-text-2); }
.mgk-mdash__range { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; border: 1px solid var(--mdash-border); background: #fff; border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-2); text-decoration: none; cursor: pointer; }
.mgk-mdash__range:hover { background: var(--mdash-bg-page); }

/* ── Date-range dropdown (Overview head) — same [data-mgk-menu] popover
 * toggle mechanism as the header's search/notifications menus. ──────────── */
.mgk-mdash__daterange { position: relative; flex-shrink: 0; }
.mgk-mdash__daterange-menu { right: 0; left: auto; min-width: 210px; padding: 6px; }
.mgk-mdash__daterange-option { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; padding: 9px 10px; font-family: 'Inter', sans-serif; font-weight: 500; font-size: 12px; color: var(--mdash-text-2); text-align: left; text-decoration: none; background: transparent; border: 0; border-radius: 7px; cursor: pointer; }
.mgk-mdash__daterange-option:hover { background: var(--mdash-bg-soft); }
.mgk-mdash__daterange-option.is-active { font-weight: 700; color: var(--mdash-accent); }
.mgk-mdash__daterange-custom { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; padding: 10px 8px 2px; border-top: 1px solid var(--mdash-border-lt); }
.mgk-mdash__daterange-label { display: block; margin-bottom: 4px; font-family: 'Inter', sans-serif; font-weight: 600; font-size: 9.5px; letter-spacing: 0.03em; text-transform: uppercase; color: var(--mdash-text-4); }
.mgk-mdash__daterange-custom input[type="date"] { width: 100%; height: 32px; padding: 0 8px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Inter', sans-serif; font-size: 11.5px; color: var(--mdash-text); box-sizing: border-box; }
.mgk-mdash__daterange-custom button { width: 100%; }

/* ── KPI cards (no icon glyph — plain label/value/delta, matches reference) ── */
.mgk-mdash__kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 16px; }
.mgk-mdash__kpi { background: #fff; border: 1px solid var(--mdash-border); border-radius: 12px; padding: 18px 18px 16px; }
.mgk-mdash__kpi-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.mgk-mdash__kpi-label { font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 12px; color: var(--mdash-text-3); }
.mgk-mdash__kpi-delta { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; padding: 2px 7px; border-radius: 999px; white-space: nowrap; }
.mgk-mdash__kpi-delta--up { color: var(--mdash-green); background: var(--mdash-green-bg); border: 1px solid var(--mdash-green-bd); }
.mgk-mdash__kpi-delta--flat { color: var(--mdash-amber); background: var(--mdash-amber-bg); border: 1px solid var(--mdash-amber-bd); }
.mgk-mdash__kpi-value { font-family: var(--mdash-font-display); font-weight: 700; font-size: 28px; letter-spacing: -0.01em; color: var(--mdash-text); line-height: 1; }
.mgk-mdash__kpi-sub { margin-top: 6px; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); }

/* ── Card shell / section titles ───────────────────────────────────────── */
.mgk-mdash__card { background: #fff; border: 1px solid var(--mdash-border); border-radius: 12px; }
.mgk-mdash__card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.mgk-mdash__card-title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 15px; color: var(--mdash-text); margin: 0; }
.mgk-mdash__card-note { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); margin: 2px 0 0; }
.mgk-mdash__seg { display: flex; padding: 3px; background: var(--mdash-bg-soft); border-radius: 8px; flex-shrink: 0; }
.mgk-mdash__seg-btn { display: flex; align-items: center; justify-content: center; width: 30px; height: 26px; border: none; border-radius: 6px; background: transparent; color: var(--mdash-text-4); text-decoration: none; }
.mgk-mdash__seg-btn.is-active { background: #fff; color: var(--mdash-accent); box-shadow: 0 1px 2px rgba(17,17,26,.06); }
.mgk-mdash__seg-link { display: flex; align-items: center; gap: 5px; height: 28px; padding: 0 9px; background: var(--mdash-bg-soft); border: none; border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-3); text-decoration: none; }
.mgk-mdash__seg-link.is-active { background: var(--mdash-accent-tint); color: var(--mdash-accent); }

/* `.mgk-mdash__col` is a DOM-only grouping wrapper (kept so each column's
 * markup stays together) but takes no part in the layout itself
 * (`display: contents`) — the four cards inside are real children of
 * `.mgk-mdash__grid` and placed on explicit row/column tracks, so Revenue
 * Overview + Incoming Funds share row 1 (and stretch to match each other's
 * height) while Recent Orders + Action Queue share row 2, matching
 * MGK-Merchant-Admin-v2.html's mgk-dash-card--revenue/--funds/--orders/
 * --tasks grid-row spans. `stretch` (grid's own default, kept explicit
 * here) is what makes the shorter card of each row grow to match. */
.mgk-mdash__grid { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; align-items: stretch; }
.mgk-mdash__grid .mgk-mdash__col { display: contents; }
/* Scoped to `.mgk-mdash__grid` (not bare class names) because the Reports
 * page reuses these same card classes inside its own differently-shaped
 * `.mgk-mdash__rep-grid` (12-col, span-based) — an unscoped rule here would
 * leak this explicit row/column placement onto Reports and break it. */
.mgk-mdash__grid .mgk-mdash__chart-card { grid-column: 1; grid-row: 1; min-width: 0; }
.mgk-mdash__grid .mgk-mdash__payment-card { grid-column: 2; grid-row: 1; min-width: 0; display: flex; flex-direction: column; }
.mgk-mdash__grid .mgk-mdash__orders-card { grid-column: 1; grid-row: 2; min-width: 0; display: flex; flex-direction: column; }
.mgk-mdash__grid .mgk-mdash__queue-card { grid-column: 2; grid-row: 2; min-width: 0; display: flex; flex-direction: column; }

.mgk-mdash__chart-card { padding: 18px 20px 20px; }
.mgk-mdash__chart-card .mgk-mdash__card-head { margin-bottom: 16px; }
.mgk-mdash__payment-card .mgk-mdash__card-head { margin-bottom: 16px; }
.mgk-mdash__chart-delta { display: flex; align-items: center; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-green); }
.mgk-mdash__chart-delta--down { color: var(--mdash-red); }
.mgk-mdash__bars { display: flex; align-items: flex-end; gap: 8px; height: 150px; }
.mgk-mdash__bar-col { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; cursor: help; }
.mgk-mdash__bar { width: 100%; background: #E0B8FD; border-radius: 5px 5px 3px 3px; min-height: 6px; }
.mgk-mdash__bar-col:last-child .mgk-mdash__bar { background: var(--mdash-accent); }
.mgk-mdash__axis-row { display: flex; justify-content: space-between; margin-top: 10px; font-family: 'Quicksand', var(--mgk-font); font-size: 10px; color: var(--mdash-text-4); }
.mgk-mdash__empty { font-family: 'Quicksand', var(--mgk-font); font-size: 13px; color: var(--mdash-text-4); padding: 20px 0; margin: 0; text-align: center; }

/* ── Hover tooltips — reusable on chart points and list rows alike, mirrors
 * MGK-Merchant-Admin-v2.html's .mgk-chart-point/.mgk-chart-tooltip (pure
 * CSS, no JS: :hover/:focus reveals the child bubble). ───────────────────── */
.mgk-mdash__tip { position: relative; }
.mgk-mdash__tip-bubble { position: absolute; z-index: 30; left: 50%; bottom: calc(100% + 8px); transform: translate(-50%, 4px); width: max-content; max-width: 220px; padding: 7px 9px; border-radius: 7px; background: #1B1B1F; color: #fff; box-shadow: 0 10px 28px rgba(17, 17, 26, 0.18); font-family: 'Inter', sans-serif; font-weight: 500; font-size: 11px; line-height: 16px; opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .14s ease, transform .14s ease, visibility .14s ease; }
.mgk-mdash__tip-bubble::after { content: ""; position: absolute; left: 50%; top: 100%; transform: translateX(-50%); border: 5px solid transparent; border-top-color: #1B1B1F; }
.mgk-mdash__tip:hover > .mgk-mdash__tip-bubble,
.mgk-mdash__tip:focus-visible > .mgk-mdash__tip-bubble,
.mgk-mdash__tip:focus-within > .mgk-mdash__tip-bubble { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* ── Line chart stage — SVG draws the area/line only; each data point gets
 * its own absolutely-positioned hit-dot on top (in %, so it tracks the
 * responsive SVG regardless of rendered width), matching
 * MGK-Merchant-Admin-v2.html's .mgk-line-stage/.mgk-line-hit split. Comes
 * AFTER the generic .mgk-mdash__tip rule above so its position:absolute
 * (needed here) wins over .mgk-mdash__tip's position:relative — both are
 * single-class selectors of equal specificity, so source order decides. ── */
.mgk-mdash__line-stage { position: relative; height: 150px; width: 100%; }
.mgk-mdash__line-hit { position: absolute; z-index: 4; width: 12px; height: 12px; margin: -6px 0 0 -6px; border: 3px solid #fff; border-radius: 50%; background: var(--mdash-accent); box-shadow: 0 0 0 1px var(--mdash-accent); cursor: help; }
.mgk-mdash__line-hit .mgk-mdash__tip-bubble { bottom: calc(100% + 7px); }

.mgk-mdash__orders-card, .mgk-mdash__queue-card, .mgk-mdash__payment-card, .mgk-mdash__top-card { padding: 16px 18px 8px; }
/* Spans the full grid width (both the 2fr and 1fr tracks) instead of sitting
 * inside either .mgk-mdash__col — matches MGK-Merchant-Admin-v2.html's
 * mgk-dash-card--top, which is pulled full-width via grid-column:1/-1. */
.mgk-mdash__top-card { grid-column: 1 / -1; }
.mgk-mdash__top-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 24px; }
.mgk-mdash__orders-card { padding: 16px 20px 8px; }
.mgk-mdash__link { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-accent); text-decoration: none; }
.mgk-mdash__order-row { display: flex; align-items: center; gap: 12px; padding: 11px 8px; border-radius: 8px; border-top: 1px solid var(--mdash-border-lt); text-decoration: none; color: inherit; cursor: pointer; }
.mgk-mdash__order-row:first-of-type { border-top: 0; }
.mgk-mdash__order-row:hover { background: var(--mdash-bg-soft); }
.mgk-mdash__order-avatar { width: 30px; height: 30px; border-radius: 8px; background: var(--mdash-accent-tint); color: var(--mdash-accent-p); display: flex; align-items: center; justify-content: center; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 11px; flex-shrink: 0; }
.mgk-mdash__order-id { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text); margin: 0; }
.mgk-mdash__order-meta { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); margin: 0; }
.mgk-mdash__order-total { width: 74px; text-align: right; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12px; color: var(--mdash-text); flex-shrink: 0; }
/* Recent Orders' status pill — mgk_dash_recent_orders() labels by fulfilment
   bucket (pending/picking/packed/dispatched/delivered/cancelled), the same
   vocabulary the shopper-facing Order Tracking page uses (.mgk-pill in
   mgk-retail.css), not the raw WC order status .mgk-mord__badge keys by — so
   it needs its own copy of that palette rather than reusing either one.
   Sized like .mgk-mord__badge so it doesn't dwarf its 11-12px row siblings. */
.mgk-mdash__order-row .mgk-pill { display: inline-flex; align-items: center; flex-shrink: 0; height: 22px; padding: 0 9px; border-radius: 999px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; white-space: nowrap; }
.mgk-mdash__order-row .mgk-pill--pending    { background: #F4F4F6; color: #3D3D44; }
.mgk-mdash__order-row .mgk-pill--picking    { background: #EDE9FE; color: #7C3AED; }
.mgk-mdash__order-row .mgk-pill--packed     { background: #EDE9FE; color: #7C3AED; }
.mgk-mdash__order-row .mgk-pill--dispatched { background: #E6FBF8; color: #12806F; }
.mgk-mdash__order-row .mgk-pill--delivered  { background: #F6FCF9; color: #1A9A5E; }
.mgk-mdash__order-row .mgk-pill--cancelled  { background: #FFF4F6; color: #C8002C; }
/* mgk_retail_order_status_pill_class() also returns these two refund-overlay
   values (never part of the bucket list above) — same bg/fg as Merchant
   Orders' status column (mgk_orders_status_style(), 'refunded'/'mgk-partial')
   so a refunded order reads the same colour everywhere a merchant sees it.
   Without these, the pill had no matching class here and rendered unstyled. */
.mgk-mdash__order-row .mgk-pill--refunded    { background: #FBF0FF; color: #8C34AB; }
.mgk-mdash__order-row .mgk-pill--mgk-partial { background: #FFF6F0; color: #B5541A; }

.mgk-mdash__donut-row { display: flex; align-items: center; gap: 18px; padding: 8px 2px 12px; }
.mgk-mdash__donut { position: relative; z-index: 1; width: 106px; height: 106px; flex: none; border-radius: 999px; }
/* Invisible per-slice hit-areas (clip-path'd to that slice's exact arc, in
 * the template) sit ABOVE the gradient but BELOW the hole, so hover only
 * ever lands on the visible ring, never the empty center. Each slice's
 * tooltip bubble is a SIBLING, not a child, of the clip-path'd hit-area —
 * clip-path clips its own descendants' paint too, which silently ate the
 * tooltip (it renders above the slice's own box via bottom:100%, i.e.
 * outside the clip region) when it was nested inside .mgk-mdash__donut-slice. */
/* pointer-events:none on the wedge (re-enabled on its slice child only) —
 * otherwise the wedge's own full 106×106 box, being un-clipped, would sit
 * on top of every earlier sibling wedge's slice and swallow all hover
 * attempts outside its own slice's arc, since stacking multiple full-size
 * wedges only lets the LAST one's slice ever receive a hover. */
.mgk-mdash__donut-wedge { position: absolute; inset: 0; pointer-events: none; }
/* Slice paints nothing at rest (the ring itself is the parent's single
 * conic-gradient) — --mgk-slice-c (set inline, per slice, from the same
 * color used to build that gradient) only becomes visible on hover/focus,
 * scaling from the wedge's own apex (transform-origin 50% 50% coincides
 * with the clip-path polygon's first point, also 50% 50% — the donut's true
 * center) so the wedge grows straight along its existing angular edges and
 * never bleeds into a neighboring slice, regardless of scale amount. */
.mgk-mdash__donut-slice { position: absolute; inset: 0; cursor: help; pointer-events: auto; background: transparent; transform: scale(1); transform-origin: 50% 50%; transition: transform .16s ease, background-color .16s ease; }
.mgk-mdash__donut-slice:hover,
.mgk-mdash__donut-slice:focus-visible { background: var(--mgk-slice-c); transform: scale(1.1); }
.mgk-mdash__donut-slice:hover ~ .mgk-mdash__tip-bubble,
.mgk-mdash__donut-slice:focus-visible ~ .mgk-mdash__tip-bubble { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.mgk-mdash__donut-hole { position: absolute; inset: 16px; z-index: 1; background: #fff; border-radius: 999px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.mgk-mdash__donut-total { font-family: var(--mdash-font-display); font-weight: 700; font-size: 14px; color: var(--mdash-text); }
.mgk-mdash__donut-caption { font-family: 'Quicksand', var(--mgk-font); font-size: 9px; color: var(--mdash-text-4); }
.mgk-mdash__donut-legend { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 9px; }
.mgk-mdash__legend-row, .mgk-mdash__pay-list-row { display: flex; align-items: center; gap: 8px; cursor: help; }
.mgk-mdash__pay-list-row { padding: 10px 4px; border-top: 1px solid var(--mdash-border-lt); }
.mgk-mdash__legend-dot { width: 9px; height: 9px; border-radius: 3px; flex-shrink: 0; }
.mgk-mdash__legend-name { flex: 1; min-width: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 11px; color: var(--mdash-text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mgk-mdash__pay-list-row .mgk-mdash__legend-name { font-size: 12px; }
.mgk-mdash__legend-amt { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 11px; color: var(--mdash-text); }
.mgk-mdash__pay-list-row .mgk-mdash__legend-amt { font-size: 12px; width: 74px; text-align: right; }
.mgk-mdash__pay-list-pct { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); width: 38px; text-align: right; }

/* Separated by the list's gap, not by a rule between them: with the cards
   already carrying a rounded box and a coloured left edge, a hairline on top
   of that read as one continuous block.
   border-left-width comes after the shorthand so the 3px priority edge
   survives it, and the markup's inline border-left-color still wins for the
   colour. Without the outline the gap alone left each card floating on the
   panel with no edge of its own. */
.mgk-mdash__queue-item { display: flex; align-items: center; gap: 11px; padding: 12px 8px 12px 12px; border: 1px solid var(--mdash-border-md); border-left-width: 3px; border-radius: 8px; text-decoration: none; color: inherit; }
.mgk-mdash__queue-item--link { cursor: pointer; }
.mgk-mdash__queue-item--link:hover { background: var(--mdash-bg-soft); }
.mgk-mdash__queue-body { flex: 1; min-width: 0; }
.mgk-mdash__queue-top { display: flex; align-items: center; gap: 7px; margin-bottom: 3px; }
.mgk-mdash__queue-cat { display: inline-flex; align-items: center; height: 18px; padding: 0 7px; border-radius: 5px; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 10px; }
.mgk-mdash__queue-cat--high { background: #FFF4F6; border: 1px solid #FFB8C1; color: var(--mdash-red); }
.mgk-mdash__queue-cat--medium { background: var(--mdash-amber-bg); border: 1px solid var(--mdash-amber-bd); color: var(--mdash-amber); }
.mgk-mdash__queue-cat--low { background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border); color: var(--mdash-text-4); }
.mgk-mdash__queue-pri { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 10px; }
.mgk-mdash__queue-text { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text); line-height: 1.35; margin: 0; }
.mgk-mdash__queue-sub { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); margin: 2px 0 0; }
.mgk-mdash__queue-chevron { flex-shrink: 0; color: #C7C7CD; margin-top: 2px; }

.mgk-mdash__top-row { display: flex; align-items: center; gap: 11px; padding: 8px 6px; border-radius: 8px; cursor: pointer; text-decoration: none; }
.mgk-mdash__top-row:hover { background: var(--mdash-bg-soft); }
.mgk-mdash__top-rank { width: 18px; text-align: center; font-family: var(--mdash-font-display); font-weight: 700; font-size: 12px; color: var(--mdash-text-4); flex-shrink: 0; }
.mgk-mdash__top-row:nth-child(2) .mgk-mdash__top-rank,
.mgk-mdash__top-rank--1 { color: var(--mdash-accent); }
.mgk-mdash__top-body { flex: 1; min-width: 0; }
.mgk-mdash__top-name { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin: 0; }
.mgk-mdash__top-bar-track { height: 4px; margin-top: 5px; background: var(--mdash-border-lt); border-radius: 999px; overflow: hidden; }
.mgk-mdash__top-bar-fill { height: 100%; background: #E0B8FD; border-radius: 999px; }
.mgk-mdash__top-row:nth-child(2) .mgk-mdash__top-bar-fill { background: var(--mdash-accent); }
.mgk-mdash__top-figures { text-align: right; flex-shrink: 0; }
.mgk-mdash__top-qty { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12px; color: var(--mdash-text); margin: 0; }
.mgk-mdash__top-rev { font-family: 'Quicksand', var(--mgk-font); font-size: 10px; color: var(--mdash-text-4); margin: 0; }

/* ── Collapse (desktop/tablet icon rail) — toggled by #mgk-mdash-burger via
 * assets/js/mgk-merchant-chrome.js, persisted in localStorage. ───────────── */
.mgk-mdash__burger { cursor: pointer; }
.mgk-mdash__burger:hover { background: var(--mdash-bg-soft); }
.mgk-mdash__sidebar { transition: width .18s ease; }
.mgk-mdash__shell.is-collapsed .mgk-mdash__sidebar { width: 72px; }
.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-group,
.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-label,
.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-soon,
.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-badge,
.mgk-mdash__shell.is-collapsed .mgk-mdash__foot-title,
.mgk-mdash__shell.is-collapsed .mgk-mdash__foot-sub { display: none; }
.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-item { justify-content: center; padding: 0; }
.mgk-mdash__shell.is-collapsed .mgk-mdash__foot-box { justify-content: center; padding: 10px 0; }

/* ── Mobile/tablet off-canvas drawer — hidden by default below the tablet
 * breakpoint, slides in over a backdrop when #mgk-mdash-burger is tapped. ── */
.mgk-mdash__backdrop { display: none; }

/* ══ Desktop (> 1024px): default 2-col content grid, 4-col KPIs, as above ══ */

/* ══ Tablet (769px–1024px): content stacks to 1 column, KPIs 2×2 ══════════ */
@media (max-width: 1024px) {
	.mgk-mdash__grid { grid-template-columns: 1fr; }
	.mgk-mdash__grid .mgk-mdash__chart-card, .mgk-mdash__grid .mgk-mdash__payment-card, .mgk-mdash__grid .mgk-mdash__orders-card, .mgk-mdash__grid .mgk-mdash__queue-card { grid-column: 1; grid-row: auto; }
	.mgk-mdash__kpis { grid-template-columns: repeat(2, 1fr); }
	.mgk-mdash__top-list { grid-template-columns: 1fr; }
}

/* ══ Mobile (≤ 768px): off-canvas sidebar, condensed header, 1-col KPIs ═══ */
@media (max-width: 768px) {
	.mgk-mdash__search { display: none; }

	.mgk-mdash__body { position: relative; }
	.mgk-mdash__sidebar {
		position: fixed; top: 56px; left: 0; bottom: 0; z-index: 45;
		width: 260px; max-width: 82vw;
		transform: translateX(-100%);
		transition: transform .2s ease;
		box-shadow: 0 10px 30px rgba(17,17,20,.18);
	}
	.mgk-mdash__shell.is-collapsed .mgk-mdash__sidebar { width: 260px; } /* collapse state doesn't apply on mobile — always full drawer */
	.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-group,
	.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-label,
	.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-soon,
	.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-badge,
	.mgk-mdash__shell.is-collapsed .mgk-mdash__foot-title,
	.mgk-mdash__shell.is-collapsed .mgk-mdash__foot-sub { display: block; }
	.mgk-mdash__shell.is-collapsed .mgk-mdash__nav-item { justify-content: flex-start; padding: 0 12px; }
	.mgk-mdash__shell.is-nav-open .mgk-mdash__sidebar { transform: translateX(0); }

	.mgk-mdash__backdrop {
		display: block; position: fixed; inset: 56px 0 0 0; z-index: 40;
		background: rgba(17,17,20,.4);
		opacity: 0; pointer-events: none; transition: opacity .2s ease;
	}
	.mgk-mdash__shell.is-nav-open .mgk-mdash__backdrop { opacity: 1; pointer-events: auto; }

	.mgk-mdash__content { padding: 20px 16px 40px; }
	.mgk-mdash__head { flex-direction: column; align-items: stretch; }
	.mgk-mdash__kpis { grid-template-columns: 1fr 1fr; gap: 10px; }
	.mgk-mdash__donut-row { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
	.mgk-mdash__kpis { grid-template-columns: 1fr; }
	.mgk-mdash__brand-word, .mgk-mdash__brand-badge { display: none; }
	.mgk-mdash__viewstore span { display: none; } /* icon-only "View Store" on very small phones */
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-034 MERCHANT REPORTS — companion to S-033. Reuses the .mgk-mdash chrome,
 * KPI, bar-chart, donut and ranked-list (.mgk-mdash__top-*) rules above as-is;
 * everything here is genuinely new to this page (period dropdown, export
 * button, the report grid's own span layout, and category-bar rows).
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mrep__actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.mgk-mrep__actions #mgk-mrep-export { display: flex; align-items: center; gap: 8px; }

.mgk-mrep__dd { position: relative; }
.mgk-mrep__dd-btn { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; border: 1px solid var(--mdash-border); background: #fff; border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-2); cursor: pointer; }
.mgk-mrep__dd-btn:hover { background: var(--mdash-bg-page); }
/* CSS-drawn chevron (no icon asset) — shared by every .mgk-mrep__dd-btn on
 * every merchant page (Reports/Orders/Products/Media), so it only needs
 * defining once here. Rotates via the same .is-open class the toggle JS
 * already applies to the .mgk-mrep__dd wrapper. */
.mgk-mrep__dd-btn::after { content: ''; width: 7px; height: 7px; margin-left: 1px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); transition: transform .15s ease; flex-shrink: 0; }
.mgk-mrep__dd.is-open .mgk-mrep__dd-btn::after { transform: rotate(225deg); }
.mgk-mrep__dd-menu { position: absolute; top: calc(100% + 6px); right: 0; min-width: 180px; background: #fff; border: 1px solid var(--mdash-border); border-radius: 10px; box-shadow: 0 10px 30px rgba(17,17,20,.12); padding: 6px; z-index: 30; display: none; }
.mgk-mrep__dd.is-open .mgk-mrep__dd-menu { display: block; }
.mgk-mrep__dd-item { display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 8px; border-radius: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 12px; color: var(--mdash-text-2); text-decoration: none; white-space: nowrap; }
.mgk-mrep__dd-item:hover { background: var(--mdash-bg-soft); }
.mgk-mrep__dd-item.is-active { color: var(--mdash-accent); font-weight: 600; }
.mgk-mrep__dd-check { width: 13px; height: 13px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--mdash-accent); }
/* Pages that always render the checkmark SVG (so JS can toggle .is-active
 * without touching markup — see Merchant Media) hide it here by default. */
.mgk-mrep__dd-check svg { visibility: hidden; }
.mgk-mrep__dd-item.is-active .mgk-mrep__dd-check svg { visibility: visible; }
.mgk-mrep__dd-menu--wide { min-width: 260px; }

.mgk-mdash__range-custom { border-top: 1px solid var(--mdash-border-lt); margin-top: 6px; padding-top: 10px; }
.mgk-mdash__range-custom-row { display: flex; gap: 8px; margin-bottom: 8px; }
.mgk-mdash__range-custom-field { flex: 1; display: block; }
.mgk-mdash__range-custom-field span { display: block; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 9.5px; letter-spacing: .03em; color: var(--mdash-text-4); margin-bottom: 4px; text-transform: uppercase; }
.mgk-mdash__range-custom-field input { width: 100%; height: 32px; padding: 0 8px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 11.5px; color: var(--mdash-text); box-sizing: border-box; }
.mgk-mdash__range-custom-apply { width: 100%; justify-content: center; }

/* ── Report grid: 12-col layout, reusing card/chart/top-row/donut rules.
 * Both rows use the SAME 7/5 column split (Revenue by Period/Top Selling
 * Products at span 7, Revenue by Category/Payment Method at span 5) so
 * cards line up in width across rows — matches MGK-Merchant-Admin-v2.html's
 * mgk-report-card--revenue/--products (span 8) vs --categories/--payment
 * (span 4), same ratio. `stretch` (grid's default, kept explicit) makes the
 * shorter card in each row grow to match its row-mate's height. ─────────── */
.mgk-mdash__rep-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 16px; align-items: stretch; }
.mgk-mrep__span-revenue { grid-column: span 7; }
.mgk-mrep__span-products { grid-column: span 5; }
.mgk-mrep__span-category { grid-column: span 7; }
.mgk-mrep__span-payment { grid-column: span 5; }

.mgk-mdash__cat-card { padding: 16px 18px 14px; }
.mgk-mdash__cat-row { padding: 9px 0; border-top: 1px solid var(--mdash-border-lt); }
.mgk-mdash__cat-row:first-child { padding-top: 0; border-top: 0; }
.mgk-mdash__cat-row-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.mgk-mdash__cat-name { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text); }
.mgk-mdash__cat-pct { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12px; color: var(--mdash-text-4); flex-shrink: 0; }

/* ══ Tablet (≤1024px): report grid collapses to a single column ══════════ */
@media (max-width: 1024px) {
	.mgk-mrep__span-revenue, .mgk-mrep__span-products, .mgk-mrep__span-category, .mgk-mrep__span-payment { grid-column: span 12; }
}

/* ══ Mobile (≤768px): actions row stacks full-width under the heading ════ */
@media (max-width: 768px) {
	.mgk-mrep__actions { width: 100%; justify-content: space-between; }
	.mgk-mrep__dd-menu { left: 0; right: auto; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-035 MERCHANT ORDERS — companion to S-033/S-034. Reuses the .mgk-mdash
 * chrome/card/order-avatar rules above; everything here is new to this page
 * (status tabs, toolbar, bulk bar, and the order table itself). Layout/colors
 * mirror MGK-Merchant-Admin.html's Orders screen 1:1.
 * ════════════════════════════════════════════════════════════════════════════ */

/* Shared .mgk-btn is sitewide (shopper pages: 14px type, 12px radius token).
   mgk-merchant-shell.css (owned by Codex) resets "button { font: inherit }"
   inside .mgk-mdash for its own nav/header buttons, but that reset also wins
   over plain .mgk-btn on specificity (.mgk-mdash button beats .mgk-btn), so
   every merchant CTA silently fell back to the body's default 16px/400 text
   and the sitewide 12px radius instead of the mockup's 40px-tall/12px-Inter/
   600-weight/8px-radius button spec. Re-declare it here, scoped + one level
   more specific, to win that fight without touching the Codex-owned file. */
.mgk-mdash .mgk-btn { height: 40px; padding: 0 16px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; font-weight: 600; border-radius: 8px; }
.mgk-mdash .mgk-btn--sm { height: 32px; padding: 0 12px; border-radius: 7px; }
.mgk-mdash .mgk-btn--xs { height: 26px; padding: 0 10px; border-radius: 6px; }

/* Shared merchant-admin button skins (accent = the mockup's purple var(--mdash-accent)
   CTA color, distinct from the site's --mgk-navy used elsewhere) — used by
   both the Orders list and the Order Detail view below. */
.mgk-mord-btn--accent { background: var(--mdash-accent); color: #fff; }
.mgk-mord-btn--accent:hover { background: var(--mdash-accent-h); opacity: 1; }
.mgk-mord-btn--accent-outline { background: #fff; color: var(--mdash-accent-h); border: 1px solid #E0B8FD; }
.mgk-mord-btn--accent-outline:hover { background: var(--mdash-accent-tint); opacity: 1; }
.mgk-mord-btn--outline { background: #fff; color: var(--mdash-text-2); border: 1px solid var(--mdash-border); }
.mgk-mord-btn--outline:hover { background: var(--mdash-bg-page); opacity: 1; }
.mgk-mord-btn--danger-outline { background: #fff; color: var(--mdash-red); border: 1px solid #FFB8C1; }
.mgk-mord-btn--danger-outline:hover { background: #FFF4F6; opacity: 1; }
.mgk-mord-btn--green { background: var(--mdash-green); color: #fff; }
.mgk-mord-btn--green:hover { background: #158150; opacity: 1; }
.mgk-mord-btn--red { background: var(--mgk-merchant-danger); color: #fff; }
.mgk-mord-btn--red:hover { background: var(--mdash-red); opacity: 1; }

.mgk-mord__actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* Real toggle for mgk_auto_receive_orders (wp_ajax_mgk_order_toggle_auto_receive) — same option Store Setup exposes, not a fabricated switch. */
.mgk-mord__auto-toggle { display: flex; align-items: center; gap: 9px; height: 40px; padding: 0 13px; border: 1px solid var(--mdash-border); background: #fff; border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-2); cursor: pointer; white-space: nowrap; }
.mgk-mord__auto-toggle.is-on { border-color: #E0B8FD; background: var(--mdash-accent-tint); color: var(--mdash-accent-h); }
.mgk-mord__auto-track { position: relative; width: 32px; height: 18px; border-radius: 999px; background: #C7C7CD; flex-shrink: 0; transition: background-color .15s ease; }
.mgk-mord__auto-toggle.is-on .mgk-mord__auto-track { background: var(--mdash-accent); }
.mgk-mord__auto-knob { position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: left .15s ease; }
.mgk-mord__auto-toggle.is-on .mgk-mord__auto-knob { left: 16px; }

.mgk-mord__tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--mdash-border); margin-bottom: 14px; overflow-x: auto; }
.mgk-mord__tab { display: flex; align-items: center; gap: 7px; height: 38px; padding: 0 12px; background: transparent; border: none; border-bottom: 2px solid transparent; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-3); text-decoration: none; white-space: nowrap; flex-shrink: 0; user-select: none; }
.mgk-mord__tab.is-active { border-bottom-color: var(--mdash-accent); color: var(--mdash-text); }
.mgk-mord__tab-count { min-width: 18px; height: 17px; padding: 0 5px; border-radius: 999px; background: var(--mdash-bg-soft); color: var(--mdash-text-4); font-weight: 700; font-size: 10px; display: flex; align-items: center; justify-content: center; }
.mgk-mord__tab.is-active .mgk-mord__tab-count { background: var(--mdash-accent); color: #fff; }

.mgk-mord__toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.mgk-mord__search { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px; background: #fff; border: 1px solid var(--mdash-border); border-radius: 8px; width: 280px; max-width: 100%; }
.mgk-mord__search svg { flex-shrink: 0; color: var(--mdash-text-4); }
.mgk-mord__search input { border: none; outline: none; background: transparent; flex: 1; min-width: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text); }
.mgk-mord__showing { margin-left: auto; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); white-space: nowrap; }

.mgk-mord__bulkbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; margin-bottom: 12px; border-radius: 10px; background: var(--mdash-accent-tint); border: 1px solid #E0B8FD; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12px; color: var(--mdash-accent-p); }

.mgk-mord__table-card { padding: 4px 16px 16px; }
.mgk-mord__table-scroll { overflow-x: auto; }
.mgk-mord__table { width: 100%; border-collapse: collapse; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; }
.mgk-mord__table th { text-align: left; padding: 12px 10px; font-weight: 600; font-size: 11px; color: var(--mdash-text-4); border-bottom: 1px solid var(--mdash-border); white-space: nowrap; }
.mgk-mord__table td { padding: 10px; border-bottom: 1px solid var(--mdash-border-lt); vertical-align: middle; white-space: nowrap; }
.mgk-mord__row { cursor: pointer; }
.mgk-mord__row:hover { background: var(--mdash-bg-page); }
.mgk-mord__table .mgk-mdash__order-avatar { width: 34px; height: 34px; font-size: 11px; }
.mgk-mord__td-date { color: var(--mdash-text-3); }
.mgk-mord__td-total { text-align: right; font-weight: 700; color: var(--mdash-text); }
/* Orders table only (not the other .mgk-mord__table pages — Products,
 * Vouchers, Customers, OOS keep their own auto-sized columns). Status/
 * Fulfillment/Payment text length varies a lot between status tabs
 * ("Refunded" vs "Awaiting Confirmation"), and the default auto table-layout
 * re-measures every column from whichever tab's content is on screen right
 * now — so switching tabs visibly reflowed the whole grid. Fixed widths
 * (set on <th>, which is all table-layout:fixed needs) keep it identical
 * across every tab. */
.mgk-mord__table--fixed { table-layout: fixed; }
.mgk-mord__table--fixed .mgk-mord__th-check { width: 40px; }
/* Order was left as the one column with no explicit width, meaning it
 * absorbed 100% of whatever space the six fixed-px columns didn't use —
 * on a wide dashboard card that's far more than "#1234 · Customer Name"
 * ever needs, which is exactly the huge dead gap before Date. Percentages
 * (proportioned off ui-merchant/MGK-Merchant-Admin-v3.html's flex ratios
 * for this same row: Order 2.4 : Date 1.3 : Status 1.5 : Fulfillment 1.4 :
 * Payment 1.5) keep every column snug to its content instead. */
.mgk-mord__table--fixed .mgk-mord__th-order { width: 28%; }
.mgk-mord__table--fixed .mgk-mord__th-date { width: 12%; }
.mgk-mord__table--fixed .mgk-mord__th-status { width: 16%; }
.mgk-mord__table--fixed .mgk-mord__th-fulfillment { width: 16%; }
.mgk-mord__table--fixed .mgk-mord__th-payment { width: 16%; }
.mgk-mord__table--fixed .mgk-mord__th-money { width: 100px; }
.mgk-mord__table--fixed .mgk-mord__th-chevron { width: 32px; }
.mgk-mord__table--fixed td { overflow: hidden; }
.mgk-mord__table--fixed .mgk-mdash__order-id,
.mgk-mord__table--fixed .mgk-mdash__order-meta,
.mgk-mord__table--fixed .mgk-mord__fulfillment,
.mgk-mord__table--fixed .mgk-mord__slot { overflow: hidden; text-overflow: ellipsis; }
.mgk-mord__badge { display: inline-flex; align-items: center; gap: 5px; height: 23px; padding: 0 8px; border-radius: 4px; border: 1px solid var(--mdash-border); background: var(--mdash-bg-soft); color: var(--mdash-text-2); font-weight: 500; font-size: 11px; white-space: nowrap; }
.mgk-mord__badge-dot { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.mgk-mord__fulfillment { margin: 0; font-weight: 500; color: var(--mdash-text-2); }
.mgk-mord__slot { margin: 2px 0 0; font-size: 10.5px; color: var(--mdash-text-4); }
.mgk-mord__view { display: inline-flex; width: 26px; height: 26px; align-items: center; justify-content: center; border-radius: 6px; color: #C7C7CD; text-decoration: none; }
.mgk-mord__view:hover { background: var(--mdash-bg-soft); color: var(--mdash-text-2); }

.mgk-mord__pagination { display: flex; align-items: center; gap: 4px; margin-top: 14px; flex-wrap: wrap; }
.mgk-mord__page-link, .mgk-mord__page-arrow { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 7px; border: 1px solid var(--mdash-border); background: #fff; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-2); text-decoration: none; }
.mgk-mord__page-link:hover, .mgk-mord__page-arrow:hover { background: var(--mdash-bg-page); }
.mgk-mord__page-link.is-active { background: var(--mdash-accent); border-color: var(--mdash-accent); color: #fff; font-weight: 700; }
.mgk-mord__page-arrow.is-disabled { color: #C7C7CD; cursor: not-allowed; pointer-events: none; }
.mgk-mord__page-gap { display: inline-flex; width: 24px; height: 30px; align-items: center; justify-content: center; color: var(--mdash-text-4); }

/* ══ Mobile (≤768px): toolbar/showing-label stack, actions row full-width ═ */
@media (max-width: 768px) {
	.mgk-mord__actions { width: 100%; justify-content: space-between; }
	.mgk-mord__showing { width: 100%; margin-left: 0; }
	.mgk-mord__search { width: 100%; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-035 MERCHANT ORDERS — Detail view (?order= sub-view of the list above).
 * Reuses .mgk-mdash__card/__order-avatar and .mgk-mord__badge; layout mirrors
 * MGK-Merchant-Admin.html's Order Detail screen 1:1 (1.62fr/1fr split, item
 * thumbnails, the unified "Refund & Cancel" card, kv-row info cards, the
 * dotted notes timeline) — refunds/new-line-items still route to wp-admin
 * (see inc/mgk-merchant-order-detail.php header for why).
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mord-detail__back { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 14px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-3); text-decoration: none; }
.mgk-mord-detail__back:hover { color: var(--mdash-text); }

.mgk-mord-detail__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.mgk-mord-detail__actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.mgk-mord-detail__inline-panel { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; padding: 12px 14px; margin-bottom: 14px; border-radius: 10px; background: #fff; border: 1px solid var(--mdash-border); }
.mgk-mord-detail__inline-panel textarea { flex: 1 1 260px; min-height: 60px; padding: 8px 10px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; resize: vertical; }

.mgk-mord-detail__banner { display: flex; gap: 8px; align-items: flex-start; padding: 13px 16px; margin-bottom: 14px; border-radius: 10px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; line-height: 1.5; }
.mgk-mord-detail__banner strong { font-weight: 700; }
.mgk-mord-detail__banner--awaiting { background: #F3FBFF; border: 1px solid #B8E5FF; color: #204C91; }
.mgk-mord-detail__banner--locked { background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border); color: var(--mdash-text-3); }
.mgk-mord-detail__banner--cod { background: var(--mdash-amber-bg); border: 1px solid var(--mdash-amber-bd); color: #8A5200; }

.mgk-mord-detail__grid { grid-template-columns: 1.62fr 1fr; }
@media (max-width: 900px) { .mgk-mord-detail__grid { grid-template-columns: 1fr; } }

.mgk-mord-detail__items-card { padding: 15px 18px 18px; }
.mgk-mord-detail__item-row { display: flex; align-items: center; gap: 13px; padding: 13px 0; border-top: 1px solid var(--mdash-border-lt); }
.mgk-mord-detail__item-row:first-of-type { border-top: 0; }
.mgk-mord-detail__item-thumb { width: 42px; height: 42px; border-radius: 8px; background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border); display: flex; align-items: center; justify-content: center; color: #C7C7CD; flex-shrink: 0; overflow: hidden; }
.mgk-mord-detail__item-thumb img { width: 100%; height: 100%; object-fit: cover; border-radius: 7px; }
.mgk-mord-detail__item-info { flex: 1; min-width: 0; }
.mgk-mord-detail__item-name { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 13px; color: var(--mdash-text); }
.mgk-mord-detail__item-sku { margin: 2px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); }
.mgk-mord-detail__sub-alert { display: flex; align-items: flex-start; gap: 10px; margin-top: 10px; padding: 11px 13px; border-radius: 9px; background: #FFF4F6; border: 1px solid #FFB8C1; }
.mgk-mord-detail__sub-alert svg { flex-shrink: 0; margin-top: 1px; color: var(--mdash-red); }
.mgk-mord-detail__sub-alert-title { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: #A30024; }
.mgk-mord-detail__sub-alert-sub { margin: 1px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-red); }
.mgk-mord-detail__qty { display: flex; align-items: center; gap: 8px; height: 30px; padding: 0 4px; border: 1px solid var(--mdash-border); border-radius: 8px; flex-shrink: 0; }
.mgk-mord-qty-dec, .mgk-mord-qty-inc { width: 22px; height: 22px; border: none; background: transparent; border-radius: 6px; font-size: 14px; color: var(--mdash-text-2); cursor: pointer; }
.mgk-mord-qty-dec:hover, .mgk-mord-qty-inc:hover { background: var(--mdash-bg-soft); }
.mgk-mord-qty-val { min-width: 18px; text-align: center; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12px; }
.mgk-mord-detail__qty-ro { flex-shrink: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-3); width: 40px; text-align: center; }
.mgk-mord-item-remove { width: 30px; height: 30px; flex-shrink: 0; border: 1px solid #FFB8C1; background: #fff; border-radius: 7px; color: var(--mdash-red); font-size: 14px; cursor: pointer; }
.mgk-mord-item-remove:hover { background: #FFF4F6; }
.mgk-mord-detail__item-total { flex-shrink: 0; width: 80px; text-align: right; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 13px; color: var(--mdash-text); }

.mgk-mord-detail__totals { margin-top: 6px; padding-top: 12px; border-top: 1px solid var(--mdash-border); }
.mgk-mord-detail__totals > div { display: flex; justify-content: space-between; padding: 5px 0; font-family: 'Quicksand', var(--mgk-font); font-size: 13px; color: var(--mdash-text-3); }
.mgk-mord-detail__totals-grand { font-weight: 700 !important; font-family: var(--mdash-font-display); font-size: 15px !important; color: var(--mdash-text) !important; border-top: 1px solid var(--mdash-border-lt); margin-top: 4px; padding-top: 9px !important; }

.mgk-mord-detail__refund-card { overflow: hidden; }
.mgk-mord-detail__refund-head { display: flex; align-items: center; gap: 8px; padding: 15px 18px 13px; border-bottom: 1px solid var(--mdash-border-lt); }
.mgk-mord-detail__refund-head svg { color: var(--mdash-accent); flex-shrink: 0; }
.mgk-mord-detail__refund-note { margin-left: auto; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); }
.mgk-mord-detail__refund-body { padding: 14px 18px; }
.mgk-mord-detail__refund-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.mgk-mord-detail__refund-copy { display: flex; align-items: flex-start; gap: 9px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-3); line-height: 1.5; }
.mgk-mord-detail__refund-copy svg { flex-shrink: 0; margin-top: 1px; color: var(--mdash-text-4); }
.mgk-mord-detail__refund-none { display: flex; align-items: center; gap: 9px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); }
.mgk-mord-detail__cod-copy { font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: #8A5200; line-height: 1.5; }
.mgk-mord-detail__cod-actions { display: flex; gap: 10px; margin-top: 12px; }

.mgk-mord-detail__notes-card { padding: 16px 18px; }

.mgk-mord-detail__note { display: flex; gap: 12px; padding: 9px 0; }
.mgk-mord-detail__note-rail { display: flex; flex-direction: column; align-items: center; flex-shrink: 0; }
.mgk-mord-detail__note-dot { width: 9px; height: 9px; border-radius: 50%; background: #E0B8FD; margin-top: 3px; flex-shrink: 0; }
.mgk-mord-detail__note-line { flex: 1; width: 1.5px; background: var(--mdash-border-lt); margin-top: 2px; }
.mgk-mord-detail__note-body { flex: 1; padding-bottom: 4px; }
.mgk-mord-detail__note-text { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text-2); line-height: 1.5; }
.mgk-mord-detail__note-meta { margin: 2px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); }
.mgk-mord-detail__add-note { display: flex; gap: 8px; margin-top: 8px; }
.mgk-mord-detail__add-note textarea { flex: 1; min-height: 38px; max-height: 38px; padding: 9px 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; resize: vertical; }

.mgk-mord-detail__side-card { padding: 16px 18px; }
.mgk-mp__detail-card { padding: 18px; }
.mgk-mord-detail__side-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.mgk-mord-detail__side-title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 14px; color: var(--mdash-text); margin: 0; }
.mgk-mord-detail__ful-box { display: flex; align-items: center; gap: 10px; padding: 11px; background: var(--mdash-accent-tint); border: 1px solid #E0B8FD; border-radius: 9px; margin-bottom: 12px; }
.mgk-mord-detail__ful-box svg { color: var(--mdash-accent); flex-shrink: 0; }
.mgk-mord-detail__ful-label { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12.5px; color: var(--mdash-accent-p); }
.mgk-mord-detail__ful-status { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-accent-h); margin-top: 1px; }
.mgk-mord-detail__ful-addr { font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-3); line-height: 1.6; }
.mgk-mord-detail__ful-zone { display: flex; align-items: center; gap: 7px; margin-top: 8px; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: #3174C7; background: #F3FBFF; border: 1px solid #B8E5FF; padding: 6px 9px; border-radius: 6px; }
.mgk-mord-detail__ful-pending { margin-top: 8px; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; line-height: 1.6; color: #92400E; background: #FEF3E2; border: 1px solid rgba(240,152,48,.4); padding: 8px 10px; border-radius: 6px; }

.mgk-mord-detail__cust-head { display: flex; align-items: center; gap: 11px; margin-bottom: 12px; }
.mgk-mord-detail__cust-avatar { width: 38px; height: 38px; font-size: 13px; }
.mgk-mord-detail__cust-name { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 13px; color: var(--mdash-text); margin: 0; }
.mgk-mord-detail__cust-sub { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); margin: 1px 0 0; }

.mgk-mord-detail__kv-rows { display: flex; flex-direction: column; gap: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; }
.mgk-mord-detail__kv-rows > div { display: flex; gap: 8px; align-items: baseline; }
.mgk-mord-detail__kv-rows .mgk-mord-detail__kv-label { color: var(--mdash-text-4); width: 60px; flex-shrink: 0; }
.mgk-mord-detail__kv-rows.mgk-mord-detail__kv-rows--between > div { justify-content: space-between; }
.mgk-mord-detail__kv-rows.mgk-mord-detail__kv-rows--between .mgk-mord-detail__kv-label { color: var(--mdash-text-3); width: auto; }
.mgk-mord-detail__kv-value { color: var(--mdash-text); }
.mgk-mord-detail__kv-value--strong { font-weight: 600; }

@media print {
	.mgk-mdash__header, .mgk-mdash__sidebar, .mgk-mdash__backdrop,
	.mgk-mord-detail__back, .mgk-mord-detail__actions, .mgk-mord-detail__inline-panel,
	.mgk-mord-detail__add-note, .mgk-mord-qty-dec, .mgk-mord-qty-inc, .mgk-mord-item-remove,
	.mgk-mord-detail__refund-card {
		display: none !important;
	}
	.mgk-mdash__main, .mgk-mdash__content { overflow: visible !important; padding: 0 !important; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-044 MERCHANT AWAITING CONFIRMATION. Reuses .mgk-mord__table / __row / __badge,
 * .mgk-mord-btn--*, .mgk-mord-detail__inline-panel and pagination wholesale —
 * only the row-actions group and the per-row reject-reveal <tr> are new.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-awaiting__row-actions { display: flex; gap: 8px; justify-content: flex-end; white-space: nowrap; }
.mgk-awaiting__reject-row td { padding: 0 10px 12px; border-bottom: 1px solid var(--mdash-border-lt); }
.mgk-awaiting__reject-row .mgk-mord-detail__inline-panel { margin-bottom: 0; }

/* ════════════════════════════════════════════════════════════════════════════
 * S-045 MERCHANT NOTIFICATIONS. Reuses .mgk-mdash__card/__empty and
 * .mgk-mord__pagination wholesale — only the toolbar toggle and list rows
 * below are new.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mnotif__toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.mgk-mnotif__toggle { display: flex; gap: 4px; background: var(--mdash-bg-soft); border-radius: 9px; padding: 3px; }
.mgk-mnotif__toggle-item { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-3); text-decoration: none; padding: 7px 12px; border-radius: 7px; }
.mgk-mnotif__toggle-item.is-active { background: #fff; color: var(--mdash-text); box-shadow: 0 1px 2px rgba(17,17,26,.08); }

.mgk-mnotif__list-card { padding: 4px 16px; }
.mgk-mnotif__row { display: flex; align-items: center; gap: 12px; padding: 13px 4px; border-bottom: 1px solid var(--mdash-border-lt); cursor: pointer; }
.mgk-mnotif__row:last-child { border-bottom: none; }
.mgk-mnotif__row:hover { background: var(--mdash-bg-page); }
.mgk-mnotif__row.is-unread { background: var(--mdash-accent-tint); }
.mgk-mnotif__row.is-unread:hover { background: #F5E9FE; }
.mgk-mnotif__icon { width: 30px; height: 30px; border-radius: 8px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.mgk-mnotif__text { flex: 1; min-width: 0; }
.mgk-mnotif__title { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12.5px; color: var(--mdash-text); display: flex; align-items: center; gap: 6px; }
.mgk-mnotif__message { margin: 2px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-3); }
.mgk-mnotif__dot { width: 6px; height: 6px; border-radius: 50%; background: var(--mdash-accent); flex-shrink: 0; }
.mgk-mnotif__time { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); white-space: nowrap; flex-shrink: 0; }

/* ════════════════════════════════════════════════════════════════════════════
 * S-036 MERCHANT LOW STOCK/OOS. Reuses .mgk-mdash__card, .mgk-mord__table*,
 * .mgk-mord-btn--*, .mgk-mord-detail__banner*, item-name/item-sku/kv-sub and
 * .mgk-mord__badge/pagination wholesale — only genuinely new pieces below.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-moos__actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.mgk-moos__banner { margin-bottom: 16px; }

.mgk-moos__report-card { padding: 16px 18px; margin-bottom: 16px; }
.mgk-moos__search { display: flex; gap: 8px; margin: 12px 0 4px; }
.mgk-moos__search input { flex: 1 1 320px; max-width: 420px; height: 38px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text); }

.mgk-moos__report-order { padding: 12px 0; border-top: 1px solid var(--mdash-border-lt); }
.mgk-moos__report-order:first-of-type { border-top: 0; }
.mgk-moos__report-order-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text-2); }
.mgk-moos__report-order-row > :last-child { margin-left: auto; }
.mgk-moos__report-order-id { font-weight: 700; color: var(--mdash-accent); }

.mgk-moos__report-items { margin-top: 10px; padding: 10px 14px; background: var(--mdash-bg-soft); border-radius: 9px; display: flex; flex-direction: column; gap: 12px; }
.mgk-moos__report-item { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 8px 0; border-top: 1px solid var(--mdash-border-lt); }
.mgk-moos__report-item:first-of-type { border-top: 0; }
.mgk-moos__report-item-info { flex: 1; min-width: 200px; }
.mgk-moos__report-form { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mgk-moos__substitute-select { height: 34px; padding: 0 8px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 11.5px; color: var(--mdash-text-2); max-width: 220px; }

.mgk-moos__table-card { padding: 4px 16px 16px; }
.mgk-moos__timer { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 13px; color: var(--mdash-text); font-variant-numeric: tabular-nums; }
.mgk-moos__resolve-row td { padding: 12px !important; background: var(--mdash-bg-soft); }
.mgk-moos__resolve-panel { display: flex; gap: 10px; flex-wrap: wrap; }

/* ════════════════════════════════════════════════════════════════════════════
 * S-037 MERCHANT CUSTOMERS. Reuses .mgk-mdash__card, .mgk-mord__table*, tab*,
 * search/pagination, .mgk-mord-btn--*, .mgk-mord-detail__back/head/actions/
 * inline-panel/grid/side-card/kv-rows/ful-addr wholesale — only genuinely
 * new pieces (avatar size override, stat-card grid, edit-grid) below.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mcust__avatar { width: 52px; height: 52px; font-size: 17px; border-radius: 999px; flex-shrink: 0; }

.mgk-mcust-modal-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.4); z-index: 60; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mgk-mcust-modal { width: 460px; max-width: 100%; max-height: 90vh; background: #fff; border-radius: 14px; border: 1px solid var(--mdash-border); overflow: hidden; display: flex; flex-direction: column; }
.mgk-mcust-modal__head { padding: 20px 22px 14px; border-bottom: 1px solid var(--mdash-border-lt); }
.mgk-mcust-modal__title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 17px; color: var(--mdash-text); }
.mgk-mcust-modal__sub { margin: 4px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text-3); line-height: 1.5; }
.mgk-mcust-modal__body { padding: 18px 22px; max-height: 56vh; overflow-y: auto; display: flex; flex-direction: column; gap: 14px; }
.mgk-mcust-modal__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--mdash-border-lt); flex-shrink: 0; }

.mgk-mcust__edit-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; width: 100%; }
.mgk-mcust__edit-grid label { display: flex; flex-direction: column; gap: 5px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); }
.mgk-mcust__edit-grid input { height: 40px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); }
.mgk-mcust__edit-grid input:focus { outline: none; border-color: var(--mdash-accent); }

/* Phone fields carry a fixed "+65" prefix, so the merchant only types the
   8-digit local number (Add customer modal). The box moves to the wrapping
   <span>; the input inside gives up its own border/height/padding, or the two
   boxes would nest — the same fix the storefront's .mgk-field__phone-row
   needed. Scoped to the merchant grid rather than reusing that storefront
   class, which carries the storefront's own height/radius/focus colour.
   `>` from the label so this never catches the [data-mgk-field-error] span. */
.mgk-mcust__edit-grid label > span.mgk-mcust__phone-row {
	display: flex; align-items: center; gap: 6px;
	height: 40px; padding: 0 12px; box-sizing: border-box;
	border: 1px solid var(--mdash-border); border-radius: 8px;
	background: #fff;
}
.mgk-mcust__edit-grid .mgk-mcust__phone-row:focus-within { border-color: var(--mdash-accent); }
.mgk-mcust__edit-grid .mgk-mcust__phone-prefix {
	flex: 0 0 auto; font-family: 'Quicksand', var(--mgk-font);
	font-weight: 400; font-size: 13px; color: var(--mdash-text-4);
}
.mgk-mcust__edit-grid .mgk-mcust__phone-row input {
	flex: 1 1 auto; min-width: 0; width: auto;
	height: 100%; padding: 0; border: 0; background: transparent;
}
.mgk-mcust__edit-grid .mgk-mcust__phone-row input:focus { border-color: transparent; }

/* Account type dropdown — the portal's own control instead of a native
   <select>. Toggle is sized like the grid's inputs (40px / radius 8) so the
   field lines up with its neighbours; the panel and its rows reuse
   .mgk-mdash__popover + .mgk-mdash__daterange-option from the Dashboard
   date-range picker, only widened to the field and left-aligned. */
.mgk-mcust__accttype { position: relative; display: block; }
.mgk-mcust__accttype-toggle {
	display: flex; align-items: center; justify-content: space-between; gap: 8px;
	width: 100%; height: 40px; padding: 0 12px; box-sizing: border-box;
	border: 1px solid var(--mdash-border); border-radius: 8px; background: #fff;
	font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px;
	color: var(--mdash-text); text-align: left; cursor: pointer;
}
.mgk-mcust__accttype-toggle:hover { background: var(--mdash-bg-page); }
.mgk-mcust__accttype-toggle[aria-expanded="true"] { border-color: var(--mdash-accent); }
/* Descendant selector, not the bare class: mgk-merchant-shell.css loads AFTER
   this file, so its `.mgk-mdash__popover { min-width: 250px }` wins on source
   order at equal specificity and the panel overhangs the field. */
.mgk-mcust__accttype .mgk-mcust__accttype-menu { right: 0; left: 0; min-width: 0; padding: 6px; }
/* The tick is rendered on every row and only revealed on the active one, so
   switching rows never shifts the labels. */
.mgk-mcust__accttype-option svg { flex: 0 0 auto; visibility: hidden; }
.mgk-mcust__accttype-option.is-active svg { visibility: visible; }
.mgk-mcust__b2b-row { display: flex; align-items: center; gap: 8px; width: 100%; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text); cursor: pointer; }
.mgk-mcust__b2b-row input { width: 15px; height: 15px; cursor: pointer; }

.mgk-mcust__stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 16px; }
.mgk-mcust__stat-card { padding: 16px 18px; }
.mgk-mcust__stat-label { font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 12px; color: var(--mdash-text-3); margin-bottom: 8px; }
.mgk-mcust__stat-value { font-family: var(--mdash-font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.01em; color: var(--mdash-text); line-height: 1; }

@media (max-width: 768px) {
	.mgk-mcust__stats { grid-template-columns: repeat(2, 1fr); }
	.mgk-mcust__edit-grid { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-038 MERCHANT VOUCHERS — list/detail reuse .mgk-mdash__*, .mgk-mord__*,
 * .mgk-mcust__stats* wholesale (same as Customers/OOS); only the pieces below
 * are genuinely new (info banner, usage progress bar, visibility pill, and
 * the Create/Edit form). Create/Edit is its own full page (?view=new /
 * ?edit=ID, parts/voucher-form.php) rather than a popup — matches
 * MGK-Merchant-Admin-v2.html's isEntityForm (a plain single-column card:
 * "Back" link, heading, fields, footer with Cancel/Save inside the card).
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mvou__banner { display: flex; align-items: flex-start; gap: 11px; padding: 13px 16px; background: var(--mdash-accent-tint); border: 1px solid #E0B8FD; border-radius: 10px; margin-bottom: 18px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-accent-p); line-height: 1.55; }
.mgk-mvou__banner > div { flex: 1; min-width: 0; }

/* The chevron is drawn here rather than left to the browser. Chrome pins a
   native <select> arrow to the inline-end of the border box and ignores
   padding-right for it, so `padding: 0 14px` inset the label by 14px while the
   arrow still sat hard against the border — visibly lopsided. appearance:none
   drops the UA arrow so background-position can place ours with a real 13px
   gap, and the larger padding-right reserves room so a long option label never
   runs underneath it. The colour is --mdash-text-2 (#44404C) written out,
   because a background-image cannot read currentColor.

   One rule covers two screens: merchant-pages.php uses this same class as
   merchant-vouchers.php. */
.mgk-mvou__select {
	height: 40px;
	padding: 0 38px 0 14px;
	border: 1px solid var(--mdash-border);
	background-color: #fff;
	border-radius: 8px;
	font-family: 'Quicksand', var(--mgk-font);
	font-weight: 600;
	font-size: 12px;
	color: var(--mdash-text-2);
	cursor: pointer;
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16' fill='none' stroke='%2344404C' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6.5 8 10.5l4-4'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 13px center;
	background-size: 12px 12px;
}

.mgk-mvou__bar-track { display: inline-block; width: 90px; height: 6px; background: var(--mdash-bg-soft); border-radius: 999px; overflow: hidden; flex-shrink: 0; }
.mgk-mvou__bar-fill { display: block; height: 100%; border-radius: 999px; }

.mgk-mvou__vis-pill { display: inline-block; max-width: 160px; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 999px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; vertical-align: middle; }

.mgk-mvou-form { max-width: 640px; }
.mgk-mvou-form__body { padding: 22px 24px; display: flex; flex-direction: column; gap: 16px; }
.mgk-mvou-form__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--mdash-border-lt); background: var(--mdash-bg-soft); border-radius: 0 0 12px 12px; }
.mgk-mvou-form__field { display: flex; flex-direction: column; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); }
.mgk-mvou-form__field input, .mgk-mvou-form__field select { height: 38px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); }
.mgk-mvou-form__field textarea { padding: 10px 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); resize: vertical; min-height: 64px; }
.mgk-mvou-form__field textarea:focus { outline: none; border-color: var(--mdash-accent); box-shadow: 0 0 0 3px rgba(150, 21, 219,.13); }
.mgk-mvou-form__field input:focus, .mgk-mvou-form__field select:focus { outline: none; border-color: var(--mdash-accent); box-shadow: 0 0 0 3px rgba(150, 21, 219,.13); }
.mgk-mvou-form__field input:disabled { background: var(--mdash-bg-soft); color: var(--mdash-text-4); }
.mgk-mvou-form__field.is-hidden { display: none; }
.mgk-mvou-form__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }

.mgk-msv-modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 60; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mgk-msv-modal { width: 460px; max-width: 100%; max-height: 90vh; background: #fff; border-radius: 14px; border: 1px solid var(--mdash-border); overflow: hidden; display: flex; flex-direction: column; }
.mgk-msv-modal__head { padding: 20px 22px 14px; border-bottom: 1px solid var(--mdash-border-lt); flex-shrink: 0; }
.mgk-msv-modal__title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 17px; color: var(--mdash-text); }
.mgk-msv-modal__body { padding: 18px 22px; max-height: 56vh; overflow-y: auto; display: flex; flex-direction: column; gap: 14px; }
.mgk-msv-modal__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--mdash-border-lt); flex-shrink: 0; }
.mgk-msv-modal__help { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); }
.mgk-msv-modal__field { display: flex; flex-direction: column; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); }
.mgk-msv-modal__field select { height: 40px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); }
.mgk-msv-modal__field select:focus { outline: none; border-color: var(--mdash-accent); }
.mgk-msv-modal__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }

@media (max-width: 640px) {
	.mgk-msv-modal { width: 100%; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * MERCHANT DELIVERY SLOTS — wraps the existing wp-admin Delivery Slots screen.
 * Reuses .mgk-mdash__card/__head, .mgk-mord__table*, .mgk-mord-btn--*
 * wholesale. Two new pieces not covered by any existing class: the 2-card
 * fulfilment-mode picker (mockup-specific layout) and the add/edit modal
 * (structured like .mgk-mvou-modal*, with extra weekday/2-col rows for the
 * weekly-template fields).
 * ════════════════════════════════════════════════════════════════════════ */
.mgk-mds__fulfil-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.mgk-mds__fulfil-card { padding: 14px; border: 1.5px solid var(--mdash-border); background: #fff; border-radius: 10px; cursor: pointer; text-align: left; }
.mgk-mds__fulfil-card.is-active { border-color: var(--mdash-accent); background: var(--mdash-accent-tint); }
.mgk-mds__fulfil-card-head { display: flex; align-items: center; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 13px; color: var(--mdash-text-2); }
.mgk-mds__fulfil-card.is-active .mgk-mds__fulfil-card-head { color: var(--mdash-accent-p); }
.mgk-mds__fulfil-card-desc { margin: 3px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); }
.mgk-mds__fulfil-estimate { margin-top: 12px; display: none; }
.mgk-mds__fulfil-estimate.is-visible { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mgk-mds__fulfil-estimate input { flex: 1; min-width: 220px; height: 36px; padding: 0 10px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; }
.mgk-mds__fulfil-status { font-family: 'Quicksand', var(--mgk-font); font-size: 11.5px; color: var(--mdash-text-4); }
.mgk-mds__fulfil-status.is-saved { color: var(--mgk-merchant-success); }
.mgk-mds__fulfil-status.is-error { color: var(--mdash-red); }
@media (max-width: 640px) {
	.mgk-mds__fulfil-cards { grid-template-columns: 1fr; }
}

.mgk-mds-modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 60; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mgk-mds-modal { width: 480px; max-width: 100%; max-height: 90vh; background: #fff; border-radius: 14px; border: 1px solid var(--mdash-border); overflow: hidden; display: flex; flex-direction: column; }
.mgk-mds-modal__head { padding: 20px 22px 14px; border-bottom: 1px solid var(--mdash-border-lt); flex-shrink: 0; }
.mgk-mds-modal__title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 17px; color: var(--mdash-text); }
.mgk-mds-modal__body { padding: 18px 22px; max-height: 60vh; overflow-y: auto; display: flex; flex-direction: column; gap: 14px; }
.mgk-mds-modal__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--mdash-border-lt); flex-shrink: 0; }
.mgk-mds-modal__field { display: flex; flex-direction: column; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); }
.mgk-mds-modal__field input, .mgk-mds-modal__field select { height: 40px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); }
.mgk-mds-modal__field textarea { padding: 10px 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); resize: vertical; }
.mgk-mds-modal__field input:focus, .mgk-mds-modal__field select:focus, .mgk-mds-modal__field textarea:focus { outline: none; border-color: var(--mdash-accent); }
.mgk-mds-modal__field.is-hidden { display: none; }
.mgk-mds-modal__row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.mgk-mds-modal__weekdays { display: flex; flex-wrap: wrap; gap: 10px; }
.mgk-mds-modal__weekday { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 12.5px; color: var(--mdash-text); }
.mgk-mds-modal__weekday input,
.mgk-mds-modal__checkbox input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.mgk-mds-modal__weekday-mark,
.mgk-mds-modal__checkbox-mark { display: grid; place-items: center; flex: 0 0 18px; width: 18px; height: 18px; border: 1.5px solid var(--mdash-border); border-radius: 4px; background: #fff; }
.mgk-mds-modal__weekday-mark::after,
.mgk-mds-modal__checkbox-mark::after { content: ''; width: 9px; height: 7px; opacity: 0; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translateY(-1px); }
.mgk-mds-modal__weekday input:checked + .mgk-mds-modal__weekday-mark,
.mgk-mds-modal__checkbox input:checked + .mgk-mds-modal__checkbox-mark { background: var(--mdash-accent); border-color: var(--mdash-accent); }
.mgk-mds-modal__weekday input:checked + .mgk-mds-modal__weekday-mark::after,
.mgk-mds-modal__checkbox input:checked + .mgk-mds-modal__checkbox-mark::after { opacity: 1; }
.mgk-mds-modal__checkbox { display: flex; align-items: center; gap: 8px; cursor: pointer; font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 13px; color: var(--mdash-text); }
.mgk-mds-modal__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }
@media (max-width: 640px) {
	.mgk-mds-modal { width: 100%; }
	.mgk-mds-modal__row-2 { grid-template-columns: 1fr; }
}

.mgk-mds-confirm-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 61; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mgk-mds-confirm { width: 380px; max-width: 100%; background: #fff; border-radius: 14px; border: 1px solid var(--mdash-border); padding: 24px 22px 20px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.mgk-mds-confirm__icon { width: 48px; height: 48px; border-radius: 999px; background: #FCE9E9; border: 1px solid #F0C1C1; display: flex; align-items: center; justify-content: center; margin-bottom: 14px; flex-shrink: 0; }
.mgk-mds-confirm__title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 17px; color: var(--mdash-text); margin-bottom: 6px; }
.mgk-mds-confirm__sub { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; line-height: 1.55; color: var(--mdash-text-4); max-width: 300px; }
.mgk-mds-confirm__actions { display: flex; gap: 10px; width: 100%; margin-top: 18px; }
.mgk-mds-confirm__btn { flex: 1; height: 42px; border-radius: 9px; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 13px; cursor: pointer; }
.mgk-mds-confirm__btn--cancel { border: 1px solid var(--mdash-border); background: #fff; color: var(--mdash-text-2); }
.mgk-mds-confirm__btn--cancel:hover { background: var(--mdash-bg-page); }
.mgk-mds-confirm__btn--delete { border: none; background: var(--mgk-merchant-danger); color: #fff; }
.mgk-mds-confirm__btn--delete:hover { background: var(--mdash-red); }

/* ════════════════════════════════════════════════════════════════════════════
 * MERCHANT SHIPPING ZONES — full zone/method CRUD. Reuses .mgk-mdash__card/
 * __head/__title/__note, .mgk-mord-btn--*, .mgk-meml__toggle (method on/off)
 * and .mgk-mds-modal* (shared add/edit dialog chrome) wholesale. Only the
 * zone-card layout and its nested method-row list are genuinely new.
 * ════════════════════════════════════════════════════════════════════════ */
.mgk-msz__zones { display: flex; flex-direction: column; gap: 16px; }
.mgk-msz__zone-card { padding: 16px 18px; }
.mgk-msz__zone-head-left { display: flex; align-items: center; gap: 10px; }
.mgk-msz__drag-handle { cursor: grab; color: var(--mdash-text-4); font-size: 16px; line-height: 1; user-select: none; }
.mgk-msz__drag-handle:active { cursor: grabbing; }
.mgk-msz__zone-head-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mgk-msz__methods { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.mgk-msz__method-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--mdash-border-lt); border-radius: 8px; }
.mgk-msz__method-info { flex: 1; min-width: 0; }
.mgk-msz__method-title { margin: 0; font-family: 'Inter', sans-serif; font-weight: 600; font-size: 13px; color: var(--mdash-text); }
.mgk-msz__method-sub { margin: 2px 0 0; font-family: 'Inter', sans-serif; font-size: 11.5px; color: var(--mdash-text-4); }
.mgk-msz__zone-card.ui-sortable-placeholder { visibility: visible !important; background: var(--mdash-bg-soft); border: 2px dashed var(--mdash-border); border-radius: 12px; }

/* Add/edit zone modal — Singapore's 28-district picker (mgk_sg_postal_districts()). */
.mgk-msz__districts { border: 1px solid var(--mdash-border-lt); border-radius: 8px; max-height: 260px; overflow-y: auto; }
.mgk-msz__districts-head, .mgk-msz__district-row { display: grid; grid-template-columns: 24px 100px 52px 1fr; gap: 8px; align-items: center; padding: 7px 10px; }
.mgk-msz__districts-head { position: sticky; top: 0; background: var(--mdash-bg-soft); font-family: 'Inter', sans-serif; font-weight: 600; font-size: 10.5px; text-transform: uppercase; letter-spacing: .03em; color: var(--mdash-text-4); }
.mgk-msz__district-row { font-family: 'Inter', sans-serif; font-size: 12px; color: var(--mdash-text); border-top: 1px solid var(--mdash-border-lt); cursor: pointer; margin: 0; }
.mgk-msz__district-row:hover { background: var(--mdash-bg-soft); }
.mgk-msz__district-row input { margin: 0; }
.mgk-msz__district-sectors { color: var(--mdash-text-4); font-size: 11.5px; }
.mgk-msz__district-code { font-weight: 700; }
.mgk-msz__extra-label { display: block; margin-top: 12px; }
@media (max-width: 640px) {
	.mgk-msz__zone-head-actions { width: 100%; }
	.mgk-msz__method-row { flex-wrap: wrap; }
	.mgk-msz__districts-head, .mgk-msz__district-row { grid-template-columns: 20px 74px 42px 1fr; font-size: 11px; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-039 MERCHANT CAMPAIGNS ("Flash deal") — list is a card-list (not a
 * table, unlike Vouchers/Customers/Orders); reuses .mgk-mord__tab*,
 * .mgk-mord__search/.mgk-mdash__card/.mgk-mvou__bar-track+__bar-fill
 * wholesale. The create/edit modal embeds the existing wp-admin Sale
 * Campaigns screen's own category/product picker (styled by
 * mgk-seasonal-admin.css + mgk-sale-admin.css, both enqueued alongside this
 * page) — only the modal shell + card-row layout below are genuinely new.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mcamp__banner { display: flex; align-items: flex-start; gap: 11px; padding: 13px 16px; background: #F3FBFF; border: 1px solid #B8E5FF; border-radius: 10px; margin-bottom: 18px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: #204C91; line-height: 1.55; }
.mgk-mcamp__banner > div { flex: 1; min-width: 0; }

.mgk-mcamp__list { display: flex; flex-direction: column; gap: 10px; }
.mgk-mcamp__row { display: flex; align-items: center; gap: 16px; background: #fff; border: 1px solid var(--mdash-border); border-radius: 12px; padding: 14px 18px; }
.mgk-mcamp__swatch { flex-shrink: 0; width: 48px; height: 48px; border-radius: 10px; background: var(--mdash-accent-tint); color: var(--mdash-accent); display: flex; align-items: center; justify-content: center; }
.mgk-mcamp__info { flex: 1.6; min-width: 0; }
.mgk-mcamp__name-row { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.mgk-mcamp__name { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 14px; color: var(--mdash-text); }
.mgk-mcamp__meta { font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); }
.mgk-mcamp__actions { flex-shrink: 0; }

.mgk-mcamp-form { max-width: 720px; }
/* The form's one feedback line. It had no rule at all, so a failure printed as
   bare body text; now that Save also reports success through it, the two have to
   be told apart. Success is the base state and .is-error is the exception,
   because mgkShowMsg() only ever adds that class. */
.mgk-mcamp-form__error {
	margin: 0;
	padding: 8px 11px;
	border-radius: 7px;
	border: 1px solid #BFE7CD;
	background: #F1FBF4;
	color: #1E7A44;
	font-family: 'Quicksand', var(--mgk-font);
	font-weight: 600;
	font-size: 12px;
}
.mgk-mcamp-form__error.is-error {
	border-color: #FFB8C1;
	background: #FFF4F6;
	color: var(--mdash-red);
}
.mgk-mcamp-form__body { padding: 22px; display: flex; flex-direction: column; gap: 20px; }
.mgk-mcamp-form__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 22px; border-top: 1px solid var(--mdash-border-lt); background: var(--mdash-bg-soft); border-radius: 0 0 12px 12px; }
.mgk-mcamp-form__field { display: flex; flex-direction: column; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); }
.mgk-mcamp-form__field input { height: 38px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); }
.mgk-mcamp-form__field input:focus { outline: none; border-color: var(--mdash-accent); box-shadow: 0 0 0 3px rgba(150, 21, 219,.13); }
.mgk-mcamp-form__row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.mgk-mcamp-form__hint { margin: -6px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11.5px; color: var(--mdash-text-4); }
.mgk-mcamp-form__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }

/* Shared image-picker "dropzone" (matches the mockup's isFile field — a
   click-to-browse dashed box, not the wp-admin screens' plain Choose Image/
   Remove button pair) — used by Flash deal's Banner image and Seasonal
   pages' Banner/CTA image fields. Clicking it still opens the real wp.media
   library (assets/js/mgk-sale-admin.js / mgk-seasonal-admin.js bind the
   click on this same element ID, unmodified) — a native <input type=file>
   wouldn't fit this theme's Media Library-based uploads. */
.mgk-mdash__filedrop { width: 100%; border: 1.5px dashed var(--mdash-border); border-radius: 10px; padding: 20px; display: block; background: var(--mdash-bg-soft); cursor: pointer; }
.mgk-mdash__filedrop:hover { border-color: #B65CF0; background: #F9F2FE; }
.mgk-mdash__filedrop svg { color: var(--mdash-text-4); }
.mgk-mdash__filedrop-empty { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.mgk-mdash__filedrop-main { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 13px; color: var(--mdash-text-2); }
.mgk-mdash__filedrop-main em { font-style: normal; color: #9615DB; }
.mgk-mdash__filedrop-hint { font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); }
.mgk-mdash__filedrop-preview:empty { display: none; }
.mgk-mdash__filedrop-preview img { display: block; width: 100%; height: 120px; object-fit: cover; border-radius: 7px; }
/* Once an image is set, the box shows only the image — no dashed "drop" UI
   underneath it — matching the ask that "browse to upload" disappears once
   there's really something to show instead. */
.mgk-mdash__filedrop:has(.mgk-mdash__filedrop-preview img) { padding: 0; border-style: solid; border-color: var(--mdash-border); background: transparent; overflow: hidden; }
.mgk-mdash__filedrop:has(.mgk-mdash__filedrop-preview img) .mgk-mdash__filedrop-empty { display: none; }
.mgk-mdash__filedrop-remove { align-self: flex-start; margin-top: -2px; background: none; border: none; padding: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: #B42121; cursor: pointer; text-decoration: underline; }

.mgk-mcamp-form__prodpick-search { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; background: #fff; border: 1px solid var(--mdash-border); border-radius: 8px; }
.mgk-mcamp-form__prodpick-search input { height: auto; border: none; padding: 0; flex: 1; min-width: 0; }
.mgk-mcamp-form__prodpick-search input:focus { box-shadow: none; }
.mgk-mcamp-form__prod-list { max-height: 260px; overflow-y: auto; margin-top: 6px; }
.mgk-mcamp-form__prod-row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--mdash-border-lt); font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text); cursor: pointer; margin: 0; }
.mgk-mcamp-form__prod-row:last-child { border-bottom: none; }
.mgk-mcamp-form__prod-row:hover { background: var(--mdash-bg-soft); }
.mgk-mcamp-form__prod-name { flex: 1; font-weight: 600; }
.mgk-mcamp-form__prod-sku { font-family: ui-monospace, Menlo, monospace; font-size: 11.5px; color: var(--mdash-text-4); }
/* The product pickers list drafts as well as published products, so the ones
   that are not live yet say so. Shared by the Flash-deal picker and the Fresh
   Picks picker in General settings. */
.mgk-mcamp-form__prod-status { flex-shrink: 0; padding: 2px 7px; border-radius: 999px; background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border-lt); font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 10.5px; letter-spacing: .02em; text-transform: uppercase; color: var(--mdash-text-3); }
/* Shown only when a search matches no row. Those pickers filter client-side over
   the rendered rows, so a miss used to leave a silent empty box that read as
   broken search. */
.mgk-mcamp-form__prod-empty { margin: 0; padding: 14px 12px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text-3); }
.mgk-mcamp-form__prod-empty b { color: var(--mdash-text); }

.mgk-mcamp-form__items.is-empty { display: none; }
.mgk-mcamp-form__items-head, .mgk-mcamp-form__item { display: flex; align-items: center; gap: 10px; }
.mgk-mcamp-form__items-head { padding: 9px 12px; background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border-lt); border-bottom: none; border-radius: 9px 9px 0 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 10px; letter-spacing: 0.05em; text-transform: uppercase; color: var(--mdash-text-4); }
.mgk-mcamp-form__item { padding: 9px 12px; border: 1px solid var(--mdash-border-lt); border-top: none; }
.mgk-mcamp-form__item:last-child { border-radius: 0 0 9px 9px; }
.mgk-mcamp-form__items-col-product, .mgk-mcamp-form__item-product { flex: 1.6; min-width: 0; }
.mgk-mcamp-form__items-col-discount, .mgk-mcamp-form__item-discount { width: 150px; flex-shrink: 0; display: flex; align-items: center; gap: 0; }
.mgk-mcamp-form__items-col-qty, .mgk-mcamp-form__item-qty { width: 90px; flex-shrink: 0; }
.mgk-mcamp-form__items-col-limit, .mgk-mcamp-form__item-limit { width: 110px; flex-shrink: 0; }
.mgk-mcamp-form__items-col-remove { width: 30px; flex-shrink: 0; }
.mgk-mcamp-form__item-name { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12.5px; color: var(--mdash-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mgk-mcamp-form__item-sku { font-family: ui-monospace, Menlo, monospace; font-size: 10.5px; color: var(--mdash-text-4); }
.mgk-mcamp-form__item-qty, .mgk-mcamp-form__item-limit { height: 34px !important; padding: 0 8px !important; font-size: 12.5px !important; }
.mgk-mcamp-form__mode-toggle { display: flex; border: 1px solid var(--mdash-border); border-right: none; border-radius: 7px 0 0 7px; overflow: hidden; flex-shrink: 0; }
.mgk-mcamp-form__mode-btn { width: 28px; height: 34px; display: flex; align-items: center; justify-content: center; border: none; background: var(--mdash-bg-soft); color: var(--mdash-text-4); font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 11.5px; cursor: pointer; }
.mgk-mcamp-form__mode-btn.is-active { background: #F5EBFD; color: #7C1AB8; }
.mgk-mcamp-form__item-value { height: 34px !important; padding: 0 8px !important; font-size: 12.5px !important; border-radius: 0 7px 7px 0 !important; flex: 1; min-width: 0; }
.mgk-mcamp-form__item-remove { width: 26px; height: 26px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--mdash-border-lt); background: #fff; border-radius: 6px; color: #B42121; cursor: pointer; }

@media (max-width: 860px) {
	.mgk-mcamp-form__row-2 { grid-template-columns: 1fr; }
	.mgk-mcamp__row { flex-wrap: wrap; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-040 MERCHANT SEASONAL PAGES — plain 3-col tile grid, no tabs/search
 * (matches MGK-Merchant-Admin.html's Seasonal pages screen, unlike Vouchers/
 * Campaigns); reuses .mgk-mord-detail__back/head/actions, .mgk-mord__badge,
 * .mgk-mdash__card wholesale. The create/edit modal embeds the existing
 * wp-admin Seasonal Landings screen's own category/product picker (styled by
 * mgk-seasonal-admin.css, enqueued alongside this page) — only the tile
 * grid, detail-page product list, and modal shell below are genuinely new.
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-mseason__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.mgk-mseason__tile { display: block; background: #fff; border: 1px solid var(--mdash-border); border-radius: 12px; overflow: hidden; text-decoration: none; color: inherit; }
.mgk-mseason__tile:hover { border-color: #C77EF3; }
.mgk-mseason__tile-banner { position: relative; height: 110px; background: var(--mdash-bg-soft); display: flex; align-items: center; justify-content: center; }
.mgk-mseason__tile-banner img { width: 100%; height: 100%; object-fit: cover; }
.mgk-mseason__tile-ph { color: var(--mdash-text-4); display: flex; }
.mgk-mseason__tile-badge { position: absolute; top: 10px; right: 10px; }
.mgk-mseason__tile-body { padding: 14px 16px; }
.mgk-mseason__tile-title { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 13.5px; color: var(--mdash-text); margin-bottom: 6px; }
.mgk-mseason__tile-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); }
.mgk-mseason__tile-meta span:last-child { font-weight: 600; color: var(--mdash-text-3); }

@media (max-width: 1024px) {
	.mgk-mseason__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
	.mgk-mseason__grid { grid-template-columns: 1fr; }
}

/* ── Detail sub-view (?season=ID) ────────────────────────────────────────── */
.mgk-mseason-detail__banner { height: 180px; border-radius: 12px; background: var(--mdash-bg-soft); overflow: hidden; margin-bottom: 16px; display: flex; align-items: center; justify-content: center; }
.mgk-mseason-detail__banner img { width: 100%; height: 100%; object-fit: cover; }
.mgk-mseason-detail__banner-empty { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text-4); }
.mgk-mseason-detail__products { padding: 15px 18px 6px; }
.mgk-mseason-detail__products .mgk-mdash__card-head { margin-bottom: 4px; }
.mgk-mseason-detail__cat { padding: 14px 0; border-top: 1px solid var(--mdash-border-lt); }
.mgk-mseason-detail__cat:first-child { border-top: 0; }
.mgk-mseason-detail__cat-name { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12.5px; color: var(--mdash-text); margin-bottom: 10px; }
.mgk-mseason-detail__prod-row { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.mgk-mseason-detail__prod-swatch { flex-shrink: 0; width: 32px; height: 32px; border-radius: 7px; background: var(--mdash-bg-soft); overflow: hidden; display: flex; }
.mgk-mseason-detail__prod-swatch img { width: 100%; height: 100%; object-fit: cover; }
.mgk-mseason-detail__prod-name { flex: 1; min-width: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text-2); }
.mgk-mseason-detail__prod-sku { color: var(--mdash-text-4); font-size: 11px; }
.mgk-mseason-detail__prod-price { flex-shrink: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 12.5px; color: var(--mdash-text); }

/* ── Create/Edit full page (isEntityForm) ─────────────────────────────────── */
.mgk-mseason-form { max-width: 640px; }
.mgk-mseason-form__body { padding: 22px 24px; display: flex; flex-direction: column; gap: 16px; }
.mgk-mseason-form__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--mdash-border-lt); background: var(--mdash-bg-soft); border-radius: 0 0 12px 12px; }
.mgk-mseason-form__field { display: flex; flex-direction: column; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); }
.mgk-mseason-form__field input:not([type="checkbox"]):not([type="radio"]) { height: 38px; padding: 0 12px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); }
.mgk-mseason-form__field input:not([type="checkbox"]):not([type="radio"]):focus { outline: none; border-color: var(--mdash-accent); box-shadow: 0 0 0 3px rgba(150, 21, 219,.13); }
.mgk-mseason-form__field input[type="checkbox"] { width: 15px; height: 15px; margin: 0; cursor: pointer; accent-color: var(--mdash-accent); }
.mgk-mseason-form__row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.mgk-mseason-form__hint { margin: -6px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11.5px; color: var(--mdash-text-4); }
.mgk-mseason-form__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }

/* CTA-image-cropped-from-banner modal (parts/seasonal-form.php + mgk-merchant-seasonal.js's ctaCrop()) — same shell as .mgk-msv-modal*. */
.mgk-mseason-cropmodal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 60; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mgk-mseason-cropmodal { width: 640px; max-width: 100%; max-height: 90vh; background: #fff; border-radius: 14px; border: 1px solid var(--mdash-border); overflow: hidden; display: flex; flex-direction: column; }
.mgk-mseason-cropmodal__head { padding: 20px 22px 14px; border-bottom: 1px solid var(--mdash-border-lt); flex-shrink: 0; }
.mgk-mseason-cropmodal__title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 17px; color: var(--mdash-text); margin-bottom: 4px; }
.mgk-mseason-cropmodal__help { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); }
.mgk-mseason-cropmodal__body { padding: 18px 22px; max-height: 62vh; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; }
.mgk-mseason-cropmodal__stage { display: flex; justify-content: center; background: var(--mdash-bg-soft); border-radius: 10px; padding: 8px; }
.mgk-mseason-cropmodal__stage img { max-width: 100%; max-height: 60vh; display: block; }
.mgk-mseason-cropmodal__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }
.mgk-mseason-cropmodal__foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--mdash-border-lt); flex-shrink: 0; }
@media (max-width: 680px) { .mgk-mseason-cropmodal { width: 100%; } }

.mgk-mseason-form__checkgroup { display: flex; flex-direction: column; gap: 8px; max-height: 260px; overflow-y: auto; }
.mgk-mseason-form__cb-row { display: flex; align-items: center; gap: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); cursor: pointer; }

.mgk-mseason-form__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.mgk-mseason-form__chips:empty { display: none; }
.mgk-mseason-form__chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 6px 0 10px; background: #F5EBFD; border: 1px solid #DDB3F8; border-radius: 6px; font-family: 'Quicksand', var(--mgk-font); font-size: 11.5px; color: #7C1AB8; }
.mgk-mseason-form__chip-remove { display: flex; align-items: center; justify-content: center; width: 16px; height: 16px; padding: 0; border: none; background: transparent; color: #7E10BC; cursor: pointer; }
.mgk-mseason-form__prodpick-search { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; background: #fff; border: 1px solid var(--mdash-border); border-radius: 8px; margin-top: 8px; }
/* Ids (not classes) needed here: .mgk-mseason-form__field
   input:not([type=checkbox]):not([type=radio]) above out-specifies a plain
   class+element override and would otherwise leave the input's own border
   visible inside the wrapper's border — the "double search box" look.
   TWO pickers share this markup and both need the rule: the Seasonal form's
   (#mgk-mseason-prodpick-query) and the "Today's Fresh Picks" one in General
   settings → Products (#mgk-fp-prodpick-query). The second was missed when
   this was first written, so only it still drew the small bordered box sitting
   inside the long one, with its own purple focus ring. Add the pair here, not
   a new rule elsewhere: an id-keyed list is what beats the :not() chain above,
   and any third picker added later belongs in this same list. */
#mgk-mseason-prodpick-query,
#mgk-mseason-prodpick-query:focus,
#mgk-fp-prodpick-query,
#mgk-fp-prodpick-query:focus { flex: 1; min-width: 0; height: auto; padding: 0; border: none; outline: none; box-shadow: none; background: transparent; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text); }
.mgk-mseason-form__prod-list { max-height: 260px; overflow-y: auto; margin-top: 6px; }
.mgk-mseason-form__prod-row { display: flex; align-items: center; gap: 10px; padding: 9px 4px; border-bottom: 1px solid var(--mdash-border-lt); font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text); cursor: pointer; margin: 0; }
.mgk-mseason-form__prod-row:last-child { border-bottom: none; }
.mgk-mseason-form__prod-row:hover { background: var(--mdash-bg-soft); }
.mgk-mseason-form__prod-name { flex: 1; }
.mgk-mseason-form__prod-sku { margin-left: auto; font-size: 11px; color: var(--mdash-text-4); }

@media (max-width: 860px) {
	.mgk-mseason-form__row-2 { grid-template-columns: 1fr; }
}

/* ════════════════════════════════════════════════════════════════════════════
 * S-041 MERCHANT ORDER EMAILS — master/detail (300px list + detail card), no
 * search/tabs, no create/delete (the 3 templates are fixed code-defined
 * identities). First portal page with a real view (mgk_view_emails) vs
 * manage (mgk_manage_emails) split — Manager-tier renders the same layout
 * with disabled fields and no action row (see merchant-emails.php).
 * ════════════════════════════════════════════════════════════════════════════ */
.mgk-meml__layout { display: grid; grid-template-columns: 300px 1fr; gap: 16px; align-items: start; }

.mgk-meml__list { background: #fff; border: 1px solid var(--mdash-border); border-radius: 12px; padding: 8px; display: flex; flex-direction: column; gap: 2px; }
.mgk-meml__row { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 8px; text-decoration: none; color: inherit; }
.mgk-meml__row:hover { background: var(--mdash-bg-page); }
.mgk-meml__row.is-active { background: var(--mdash-accent-tint); }
.mgk-meml__row-icon { flex-shrink: 0; color: var(--mdash-text-4); display: flex; }
.mgk-meml__row-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mgk-meml__row-title { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 13px; color: var(--mdash-text); }
.mgk-meml__row-desc { font-family: 'Quicksand', var(--mgk-font); font-size: 10.5px; color: var(--mdash-text-4); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mgk-meml__row-dot { flex-shrink: 0; width: 8px; height: 8px; border-radius: 50%; }

.mgk-meml__detail { padding: 0; overflow: hidden; min-width: 0; }
.mgk-meml__detail-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 20px; border-bottom: 1px solid var(--mdash-border-lt); }
.mgk-meml__detail-info { min-width: 0; flex: 1; }
.mgk-meml__detail-title { font-family: var(--mdash-font-display); font-weight: 700; font-size: 16px; color: var(--mdash-text); }
.mgk-meml__detail-when { font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); margin-top: 3px; }
.mgk-meml__detail-status { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.mgk-meml__toggle { display: inline-flex; cursor: pointer; }
.mgk-meml__toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.mgk-meml__toggle-track { width: 38px; height: 22px; border-radius: 999px; background: var(--mdash-border); position: relative; transition: background .15s; flex-shrink: 0; }
.mgk-meml__toggle-knob { position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(17,17,26,.16); transition: left .15s; }
.mgk-meml__toggle input:checked + .mgk-meml__toggle-track { background: var(--mdash-accent); }
.mgk-meml__toggle input:checked + .mgk-meml__toggle-track .mgk-meml__toggle-knob { left: 18px; }

.mgk-meml__form { padding: 18px 20px; display: flex; flex-direction: column; gap: 16px; }
.mgk-meml__field { display: flex; flex-direction: column; gap: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); text-transform: uppercase; letter-spacing: 0.03em; }
.mgk-meml__field input, .mgk-meml__field textarea { width: 100%; font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); text-transform: none; letter-spacing: normal; border: 1px solid var(--mdash-border); border-radius: 8px; padding: 10px 12px; resize: vertical; }
.mgk-meml__field input { height: 40px; }
.mgk-meml__field input:focus, .mgk-meml__field textarea:focus { outline: none; border-color: var(--mdash-accent); }
.mgk-meml__field input:disabled, .mgk-meml__field textarea:disabled { background: var(--mdash-bg-soft); color: var(--mdash-text-3); }

.mgk-meml__chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.mgk-meml__chip { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-2); background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border-lt); border-radius: 999px; padding: 4px 10px; text-transform: none; letter-spacing: normal; }

.mgk-meml__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }
.mgk-meml__test-msg { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mgk-merchant-success); }
.mgk-meml__test-msg.is-error { color: var(--mdash-red); }
.mgk-meml__actions { display: flex; justify-content: flex-end; gap: 10px; }

@media (max-width: 860px) {
	.mgk-meml__layout { grid-template-columns: minmax(0, 1fr); }
}

/* ============================================================================
 * S-042 MERCHANT STORE SETUP — left tab rail + right panel (one tab's fields
 * at a time, ?open=<key> full-page-reload-per-tab — same `.mgk-mss__layout`/
 * `.mgk-mss__vnav` pattern as S-043 General Settings), per-tab forms (fields/
 * checkboxes/repeaters/image pickers). Owner-only. Matches the mockup's
 * "Store setup" screen.
 * ============================================================================ */

.mgk-mss__panel { padding: 20px; }
.mgk-mss__panel-title { margin-bottom: 18px; }
.mgk-mss__help { font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; color: var(--mdash-text-3); background: var(--mdash-bg-soft); border-left: 3px solid var(--mdash-accent); border-radius: 6px; padding: 10px 14px; margin: 0 0 16px; line-height: 1.5; }
.mgk-mss__subhead { font-family: var(--mdash-font-display); font-weight: 700; font-size: 14px; color: var(--mdash-text); margin: 20px 0 4px; }

.mgk-mss__form { display: flex; flex-direction: column; gap: 14px; max-width: 640px; }
.mgk-mss__form--wide { max-width: none; }
.mgk-mss__row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.mgk-mss__field { display: flex; flex-direction: column; gap: 6px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11px; color: var(--mdash-text-4); }
.mgk-mss__field input, .mgk-mss__field select, .mgk-mss__field textarea { font-family: 'Quicksand', var(--mgk-font); font-weight: 400; font-size: 13px; color: var(--mdash-text); border: 1px solid var(--mdash-border); border-radius: 8px; padding: 10px 12px; resize: vertical; }
.mgk-mss__field input, .mgk-mss__field select { height: 40px; }
.mgk-mss__field input:focus, .mgk-mss__field select:focus, .mgk-mss__field textarea:focus { outline: none; border-color: var(--mdash-accent); }

.mgk-mss__checkbox, .mgk-mss__inline-checkbox { display: flex; align-items: center; gap: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 13px; color: var(--mdash-text); }
.mgk-mss__inline-checkbox { display: inline-flex; margin-right: 14px; }
.mgk-mss__hint { margin: -6px 0 0; font-family: 'Quicksand', var(--mgk-font); font-size: 11.5px; color: var(--mdash-text-4); line-height: 1.5; }

.mgk-mss__test-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.mgk-mss__test-row input { height: 34px; padding: 0 10px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; max-width: 200px; }
.mgk-mss__test-result { font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mgk-merchant-success); }
.mgk-mss__test-result.is-error { color: var(--mdash-red); }

.mgk-mss__error { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-red); }
.mgk-mss__saved { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mgk-merchant-success); }
.mgk-mss__actions { display: flex; justify-content: flex-end; }

.mgk-mss__postal-row { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.mgk-mss__postal-row input { height: 34px; padding: 0 10px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; max-width: 160px; }

.mgk-mss__repeater { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.mgk-mss__repeater-row { display: flex; align-items: center; gap: 8px; }
.mgk-mss__repeater-row input[type="text"], .mgk-mss__repeater-row input[type="url"] { flex: 1; height: 38px; padding: 0 10px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; }
.mgk-mss__repeater-row--compliance { align-items: flex-start; background: var(--mdash-bg-soft); border-radius: 10px; padding: 12px; }
.mgk-mss__repeater-row--iconlib input.mgk-mss__iconlib-emoji { flex: 0 0 64px; text-align: center; font-size: 16px; }
.mgk-mss__compliance-grid { flex: 1; display: flex; flex-direction: column; gap: 8px; }
.mgk-mss__compliance-grid input, .mgk-mss__compliance-grid select, .mgk-mss__compliance-grid textarea { height: 36px; padding: 0 10px; border: 1px solid var(--mdash-border); border-radius: 7px; font-family: 'Quicksand', var(--mgk-font); font-size: 12.5px; }
.mgk-mss__compliance-grid textarea { height: auto; padding: 8px 10px; }

/* Image picker (mirrors mgk_setup_render_image_picker()'s own markup/classes,
 * shared with the wp-admin Store Setup screen — same wp.media wiring). Base
 * rules below are generic (harmless on both screens); the block further down
 * scoped to `.mgk-mss__field` restyles it into the mockup's compact "isImage"
 * dropzone bar for the merchant portal ONLY, overriding that shared function's
 * inline styles (written for the plain wp-admin screen) with !important —
 * wp-admin's own screen isn't wrapped in `.mgk-mss__field` so it never
 * matches these overrides and keeps its original look untouched. */
.mgk-image-picker { margin-bottom: 4px; }
.mgk-image-picker__choose, .mgk-image-picker__remove { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 11.5px; padding: 6px 12px; border: 1px solid var(--mdash-border); border-radius: 7px; background: #fff; cursor: pointer; margin-right: 8px; }
.mgk-image-picker__choose:hover, .mgk-image-picker__remove:hover { background: var(--mdash-bg-soft); }

.mgk-mss__field .mgk-image-picker { display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 10px 14px; border: 1.5px dashed var(--mdash-border); border-radius: 8px; background: var(--mdash-bg-soft); margin-bottom: 0; }
.mgk-mss__field .mgk-image-picker__preview { margin-bottom: 0 !important; display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.mgk-mss__field .mgk-image-picker__img { width: 40px !important; height: 40px !important; max-width: 40px !important; max-height: 40px !important; object-fit: cover; border-radius: 6px !important; border: 1px solid var(--mdash-border) !important; flex-shrink: 0; }
.mgk-mss__field .mgk-image-picker__placeholder { width: auto !important; height: auto !important; flex-direction: row !important; align-items: center !important; justify-content: flex-start !important; gap: 8px !important; border: none !important; border-radius: 0 !important; background: transparent !important; color: var(--mdash-text-4) !important; font-family: 'Inter', sans-serif; font-size: 12.5px !important; flex: 1; min-width: 0; }
.mgk-mss__field .mgk-image-picker__placeholder span:first-child { font-size: 18px; }
.mgk-mss__field .mgk-image-picker__choose, .mgk-mss__field .mgk-image-picker__remove { flex-shrink: 0; margin-right: 0; }

@media (max-width: 860px) {
	.mgk-mss__row-2 { grid-template-columns: 1fr; }
}

/* ============================================================================
 * S-043 MERCHANT GENERAL SETTINGS — reuses .mgk-mss__* from Store Setup
 * (tabs/panel/form/field/checkbox/actions); only the bits unique to this
 * page (read-only rows, the disabled 3PL row + its badge) are added here.
 * ============================================================================ */

.mgk-mss__layout { display: grid; grid-template-columns: 210px 1fr; gap: 16px; align-items: start; }
.mgk-mss__vnav { background: #fff; border: 1px solid var(--mdash-border); border-radius: 12px; padding: 8px; display: flex; flex-direction: column; gap: 2px; }
.mgk-mss__vnav-item { text-align: left; height: 38px; padding: 0 12px; display: flex; align-items: center; border: none; border-radius: 8px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-text-4); text-decoration: none; }
.mgk-mss__vnav-item:hover { background: var(--mdash-bg-soft); color: var(--mdash-text); }
.mgk-mss__vnav-item.is-active { background: var(--mdash-accent-tint); color: var(--mdash-accent-p); }
@media (max-width: 640px) {
	.mgk-mss__layout { grid-template-columns: 1fr; }
	.mgk-mss__vnav { flex-direction: row; flex-wrap: wrap; }
}

.mgk-mss__readonly { margin: 0; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 13px; color: var(--mdash-text); }
.mgk-mss__checkbox--disabled { opacity: .55; }
.mgk-mss__checkbox--disabled input { cursor: not-allowed; }

.mgk-mss__toggle-row { display: flex; align-items: center; justify-content: space-between; padding: 13px 15px; border: 1px solid var(--mdash-border); border-radius: 9px; font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12.5px; color: var(--mdash-text); }
.mgk-mss__toggle-row--disabled { opacity: .55; }
.mgk-mss__toggle-row--disabled .mgk-meml__toggle { cursor: not-allowed; }
.mgk-mss__badge { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 10px; text-transform: uppercase; letter-spacing: .04em; color: var(--mdash-text-4); background: var(--mdash-bg-soft); border: 1px solid var(--mdash-border); border-radius: 999px; padding: 2px 8px; margin-left: 6px; }

/* ── Tax & GST tab (General Settings) — matches MGK-Merchant-Admin-v2.html's
 * isSetTax card exactly: two bordered rows (title+subtitle left, value/pill
 * right) then a plain (unbordered) decorative toggle row. ──────────────────── */
.mgk-mss__gst-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 16px; }
.mgk-mss__gst-row { display: flex; align-items: center; justify-content: space-between; padding: 13px 15px; border: 1px solid var(--mdash-border); border-radius: 9px; }
.mgk-mss__gst-row-title { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12.5px; color: var(--mdash-text); }
.mgk-mss__gst-row-sub { font-family: 'Quicksand', var(--mgk-font); font-size: 11px; color: var(--mdash-text-4); margin-top: 2px; }
.mgk-mss__gst-row-value { font-family: 'Quicksand', var(--mgk-font); font-weight: 700; font-size: 14px; color: var(--mdash-text); flex-shrink: 0; }
.mgk-mss__gst-pill { font-family: 'Quicksand', var(--mgk-font); font-weight: 600; font-size: 12px; color: var(--mdash-accent-h); background: var(--mdash-accent-tint); border: 1px solid #E0B8FD; padding: 4px 10px; border-radius: 999px; flex-shrink: 0; }
.mgk-mss__gst-toggle-row { display: flex; align-items: center; gap: 9px; font-family: 'Quicksand', var(--mgk-font); font-weight: 500; font-size: 12px; color: var(--mdash-text-2); }

/* ── Recovered from the pre-merge stylesheet, round 2 ──────────────────
 * The first recovery pass read class names out of the PHP templates, which
 * misses every class composed in PHP, and so reported the customers,
 * notifications and awaiting screens as complete while they rendered with
 * browser defaults. This pass takes the class list from the RENDERED html of
 * all 18 merchant pages instead. Token/:root blocks stay excluded so the
 * design palette above still wins.
 * ─────────────────────────────────────────────────────────────────────── */

.mgk-awaiting__head { margin-bottom: 18px; }

.mgk-awaiting__card { overflow: hidden; }

.mgk-awaiting__table-scroll { overflow-x: auto; }

.mgk-awaiting__table { width: 100%; min-width: 760px; border-collapse: collapse; table-layout: fixed; font-family: system-ui, sans-serif; font-size: 12.5px; color: #44404C; }

.mgk-awaiting__table th { height: 42px; padding: 0 18px; border-bottom: 1px solid #E9E6EF; background: #FBFAFD; color: #8A8494; font-size: 11px; font-weight: 600; letter-spacing: .05em; text-align: left; text-transform: uppercase; white-space: nowrap; }

.mgk-awaiting__table td { height: 52px; padding: 10px 18px; border-bottom: 1px solid #F1EFF5; vertical-align: middle; }

.mgk-awaiting__table tbody tr:last-child td { border-bottom: 0; }

.mgk-awaiting__table th:nth-child(1), .mgk-awaiting__table td:nth-child(1) { width: 15%; }

.mgk-awaiting__table th:nth-child(2), .mgk-awaiting__table td:nth-child(2) { width: 21%; }

.mgk-awaiting__table th:nth-child(3), .mgk-awaiting__table td:nth-child(3) { width: 17%; }

.mgk-awaiting__table th:nth-child(4), .mgk-awaiting__table td:nth-child(4) { width: 13%; }

.mgk-awaiting__table th:nth-child(5), .mgk-awaiting__table td:nth-child(5) { width: 19%; }

.mgk-awaiting__table th:nth-child(6), .mgk-awaiting__table td:nth-child(6) { width: 15%; }

.mgk-awaiting__table .is-money { color: #1B1B1F; font-weight: 600; text-align: right; }

.mgk-awaiting__table th.is-money { color: #8A8494; font-weight: 600; }

.mgk-awaiting__empty { min-height: 210px; padding: 36px 24px; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 7px; text-align: center; font-family: system-ui, sans-serif; }

.mgk-awaiting__empty[hidden] { display: none; }

.mgk-awaiting__empty-icon { width: 46px; height: 46px; margin-bottom: 4px; display: flex; align-items: center; justify-content: center; border-radius: 12px; background: #F5EBFD; color: #7E10BC; }

.mgk-awaiting__empty strong { color: #1B1B1F; font-size: 14px; }

.mgk-awaiting__empty > span:last-child { max-width: 460px; color: #8A8494; font-size: 12px; line-height: 1.5; }

.mgk-awaiting__feedback { min-height: 20px; margin: 10px 0 0; color: #0E7C3F; font-family: system-ui, sans-serif; font-size: 12px; }

.mgk-awaiting__feedback.is-error { color: #B42121; }

.mgk-mord-detail__notice { margin: 10px 0 0; padding: 10px 12px; border: 1px solid #B8E9D2; border-radius: 8px; background: #E7F6EC; color: #0E7C3F; font-size: 13px; }

.mgk-mord-detail__notice.is-error { border-color: #F3B8B8; background: #FFF7F7; color: #B42121; }

.mgk-mord-detail__notice[hidden] { display: none; }

@media (max-width: 768px) {
	.mgk-awaiting__table th, .mgk-awaiting__table td { padding-left: 14px; padding-right: 14px; }
}

.mgk-mnotif__toggle-count { min-width: 18px; height: 17px; padding: 0 5px; border-radius: 999px; background: #F5EBFD; color: #7E10BC; font: 700 10px system-ui, sans-serif; display: inline-flex; align-items: center; justify-content: center; }

.mgk-mnotif__scroll { overflow-x: auto; }

.mgk-mnotif__dot--btn { padding: 0; border: 0; cursor: pointer; }

.mgk-mnotif__dot--btn:hover { box-shadow: 0 0 0 4px #F5EBFD; }

.mgk-mnotif__dot--btn:focus-visible { outline: 2px solid #9615DB; outline-offset: 3px; }

.mgk-mnotif__dot--btn:disabled { background: #D5CFE0; cursor: wait; box-shadow: none; }

.mgk-mnotif__order { font-weight: 600; color: #7E10BC; text-decoration: none; }

.mgk-mnotif__order:hover { text-decoration: underline; }

.mgk-mnotif__order-none { color: #9B93AB; }

.mgk-mnotif__feedback { margin: 12px 0 0; min-height: 18px; font: 500 12.5px system-ui, sans-serif; color: #0E7C3F; }

.mgk-mnotif__feedback.is-error { color: #B42121; }

.mgk-mcust__page-head { margin-bottom: 16px; }

.mgk-mcust__toolbar { justify-content: space-between; gap: 16px; }

.mgk-mcust__table-card { overflow: hidden; }

.mgk-mcust__readonly-pill { display: inline-flex; align-items: center; padding: 2px 7px; margin-left: 5px; border: 1px solid #E9E6EF; border-radius: 999px; background: #F6F4F9; color: #6E6A78; font-family: var(--mdash-font); font-size: 10px; font-weight: 600; line-height: 1.4; }

.mgk-mcust__muted { color: var(--mdash-text-4); font-family: var(--mdash-font); font-size: 12px; }

.mgk-mcust__empty { padding: 48px 24px; text-align: center; font-family: var(--mdash-font); color: var(--mdash-text-3); }

.mgk-mcust__empty h1, .mgk-mcust__empty h2 { margin: 8px 0 4px; font-family: var(--mdash-font-display); color: var(--mdash-text); font-size: 17px; }

.mgk-mcust__empty p { margin: 0; font-size: 12.5px; }

.mgk-mcust__empty-icon { font-size: 26px; opacity: .72; }

.mgk-mcust__empty--compact { padding: 26px 16px; }

.mgk-mcust-modal--wide { width: 660px; }

.mgk-mcust-modal__close { width: 30px; height: 30px; padding: 0; border: 0; border-radius: 7px; background: transparent; color: #6E6A78; font: 24px/1 var(--mdash-font); cursor: pointer; }

.mgk-mcust-modal__close:hover { background: #F1EFF5; color: #1B1B1F; }

.mgk-mcust__edit-grid label > span[data-mgk-field-error], .mgk-mcust__note-form > span { min-height: 14px; color: #C8002C; font-size: 10.5px; font-weight: 500; }

.mgk-mcust__field--full { grid-column: 1 / -1; }

.mgk-mcust__form-section-title { margin: 2px 0 -2px; font-family: var(--mdash-font-display); font-size: 13px; font-weight: 700; color: var(--mdash-text); }

.mgk-mcust__form-summary { padding: 10px 12px; border: 1px solid #F2B8C4; border-radius: 8px; background: #FFF7F8; color: #A60024; font-family: var(--mdash-font); font-size: 11.5px; }

.mgk-mcust__optional-toggle, .mgk-mcust__checkbox { display: flex !important; flex-direction: row !important; align-items: center; gap: 8px !important; color: var(--mdash-text) !important; cursor: pointer; }

.mgk-mcust__optional-toggle { font-family: var(--mdash-font); font-size: 12px; font-weight: 600; }

.mgk-mcust__optional-toggle input, .mgk-mcust__checkbox input { width: 15px; height: 15px; flex: 0 0 auto; accent-color: #9615DB; }

.mgk-mcust__detail-main, .mgk-mcust__detail-side { display: flex; min-width: 0; flex-direction: column; gap: 16px; }

.mgk-mcust__card-sub { margin: 3px 0 0; color: var(--mdash-text-4); font-family: var(--mdash-font); font-size: 11px; font-weight: 400; }

.mgk-mcust__side-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 13px; }

.mgk-mcust__side-head h2 { margin: 0; font-family: var(--mdash-font-display); color: var(--mdash-text); font-size: 14px; font-weight: 700; }

.mgk-mcust__side-head button { padding: 0; border: 0; background: transparent; color: var(--mdash-accent); font-family: var(--mdash-font); font-size: 11px; font-weight: 700; cursor: pointer; }

.mgk-mcust__profile-list { margin: 0; }

.mgk-mcust__profile-list > div { display: flex; justify-content: space-between; gap: 18px; padding: 8px 0; border-bottom: 1px solid #F1EFF5; font-family: var(--mdash-font); font-size: 11.5px; line-height: 1.45; }

.mgk-mcust__profile-list > div:last-child { border-bottom: 0; }

.mgk-mcust__profile-list dt { color: var(--mdash-text-3); }

.mgk-mcust__profile-list dd { margin: 0; max-width: 58%; color: var(--mdash-text); font-weight: 600; text-align: right; overflow-wrap: anywhere; }

.mgk-mcust__tax-note { margin: 12px 0 0; padding: 9px 10px; border-radius: 7px; background: #F6F4F9; color: #6E6A78; font-family: var(--mdash-font); font-size: 10.5px; line-height: 1.5; }

.mgk-mcust__addresses { display: flex; flex-direction: column; gap: 9px; }

.mgk-mcust__note-form { padding: 0 18px 14px; border-bottom: 1px solid #F1EFF5; }

.mgk-mcust__note-form > label { display: block; margin-bottom: 6px; color: var(--mdash-text-2); font-family: var(--mdash-font); font-size: 11px; font-weight: 700; }

.mgk-mcust__note-form > div { display: flex; align-items: flex-end; gap: 9px; }

.mgk-mcust__note-form textarea { flex: 1; min-width: 0; padding: 9px 11px; border: 1px solid var(--mdash-border); border-radius: 8px; font-family: var(--mdash-font); font-size: 12px; line-height: 1.45; resize: vertical; }

.mgk-mcust__note-form textarea:focus { outline: none; border-color: var(--mdash-accent); box-shadow: 0 0 0 3px rgba(139,1,200,.08); }

.mgk-mcust__timeline { padding: 5px 18px 16px; }

.mgk-mcust__timeline-item { position: relative; display: grid; grid-template-columns: 13px minmax(0, 1fr); gap: 9px; padding: 10px 0; border-bottom: 1px solid #F1EFF5; }

.mgk-mcust__timeline-item:last-child { border-bottom: 0; }

.mgk-mcust__timeline-dot { width: 8px; height: 8px; margin-top: 4px; border-radius: 50%; background: #9615DB; box-shadow: 0 0 0 3px #F4E7FA; }

.mgk-mcust__timeline-item--order .mgk-mcust__timeline-dot { background: #3174C7; box-shadow: 0 0 0 3px #E7F3FB; }

.mgk-mcust__timeline-item--activity .mgk-mcust__timeline-dot { background: #8B8B94; box-shadow: 0 0 0 3px #F1EFF5; }

.mgk-mcust__timeline-title { display: flex; justify-content: space-between; gap: 12px; color: var(--mdash-text); font-family: var(--mdash-font); font-size: 11.5px; font-weight: 700; }

.mgk-mcust__timeline-title a { color: var(--mdash-accent); text-decoration: none; }

.mgk-mcust__timeline-title time { flex: 0 0 auto; color: #8B8B94; font-size: 10px; font-weight: 400; }

.mgk-mcust__timeline-item p { margin: 4px 0 0; color: #6E6A78; font-family: var(--mdash-font); font-size: 11px; line-height: 1.5; white-space: pre-wrap; }

@media (max-width: 768px) {
	.mgk-mcust__stats { grid-template-columns: repeat(2, 1fr); }
	.mgk-mcust__edit-grid { grid-template-columns: 1fr; }
	.mgk-mcust__field--full { grid-column: auto; }
	.mgk-mcust__detail-grid { grid-template-columns: 1fr; }
	.mgk-mcust__detail-side { order: -1; }
	.mgk-mcust__detail-head { align-items: flex-start; }
	.mgk-mcust__identity--detail { align-items: flex-start; }
	.mgk-mcust__note-form > div { align-items: stretch; flex-direction: column; }
}

@media (max-width: 520px) {
	.mgk-mcust-modal-backdrop { padding: 0; align-items: flex-end; }
	.mgk-mcust-modal { width: 100%; max-height: 94vh; border-radius: 14px 14px 0 0; }
	.mgk-mcust__stats { grid-template-columns: 1fr 1fr; gap: 10px; }
	.mgk-mcust__stat-card { padding: 14px; }
	.mgk-mcust__stat-value { font-size: 18px; }
	.mgk-mcust__stat-value--text { font-size: 14px; }
	.mgk-mcust__timeline-title { flex-direction: column; gap: 2px; }
}

/* ── Recovered on the origin/main merge (2026-07-31) ──────────────────────
   These 7 rules lived in mgk-retail.css, which the merchant CSS split moved
   out of. origin/main kept editing them there, so taking our side of that
   conflict would have dropped them: .mgk-mdash__queue-list (dashboard queue
   scroll) and the .mgk-msv-modal__option* set (site-visibility modal radio
   rows). Their sibling selectors already live in this sheet, so they belong
   here. Copied verbatim from origin — no restyling.                          */
.mgk-mdash__queue-list { max-height: 420px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; }

.mgk-msv-modal__options { display: flex; flex-direction: column; gap: 10px; }

.mgk-msv-modal__option { display: flex; align-items: flex-start; gap: 11px; padding: 13px 14px; border: 1.5px solid var(--mdash-border); background: #fff; border-radius: 10px; cursor: pointer; }

.mgk-msv-modal__option-dot { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid #B0A9BE; background: #fff; flex-shrink: 0; margin-top: 1px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; }

.mgk-msv-modal__option-dot-fill { width: 8px; height: 8px; border-radius: 50%; background: var(--mdash-accent); display: none; }

.mgk-msv-modal__option-title { font-family: 'Quicksand', var(--mgk-font); font-weight: 650; font-size: 13.5px; color: var(--mdash-text); }

.mgk-msv-modal__option-desc { font-family: 'Quicksand', var(--mgk-font); font-size: 12px; color: var(--mdash-text-4); margin-top: 3px; line-height: 1.5; }

.mgk-msv-modal__option.is-active { border-color: var(--mdash-accent); background: var(--mdash-accent-tint); }
.mgk-msv-modal__option.is-active .mgk-msv-modal__option-dot { border-color: var(--mdash-accent); }
.mgk-msv-modal__option.is-active .mgk-msv-modal__option-dot-fill { display: block; }

/* ── Order line: picked modifier-group option (F-16 / AB-06) ────────────────
   The design's own chip under the SKU (MGK-Merchant-Admin.html, the
   <sc-if value="{{ l.mod }}"> block): 11px accent text on the accent-soft
   surface with a light accent border. Colours go through the merchant tokens
   rather than the design's literals (#7E10BC / #F5EBFD / #DDB3F8) so this chip
   follows the palette like everything else — scripts/verify-design-tokens.php
   asserts those tokens carry the design's values.                            */
.mgk-mord-detail__item-mod {
	display: inline-block;
	margin-top: 3px;
	padding: 1px 7px;
	font-family: 'Quicksand', var(--mgk-font);
	font-size: 11px;
	color: var(--mgk-merchant-accent-hover);
	background: var(--mgk-merchant-accent-soft);
	border: 1px solid var(--mgk-merchant-accent-line);
	border-radius: 4px;
}
