/* ============================================================
   Bsporty Cloud — MERCHANT PORTAL (post-onboarding)
   Recreates the bsporty-admin (ground-admin) Filament look:
   white sidebar · grouped nav · green active · DataTable+Modal
   White-label: --mp accent follows the merchant's brand color.
   ============================================================ */
#screen-merchant {
  --mp: #1AAF31;               /* brand accent — synced from setup */
  --mp-bg: #F3F4F6;
  --mp-surface: #FFFFFF;
  --mp-text: #111827;
  --mp-muted: #6B7280;
  --mp-border: #E5E7EB;
  --mp-side: #FFFFFF;
  --mp-side-text: #374151;
  --mp-side-muted: #9CA3AF;
  --mp-hover: #F9FAFB;
  font-family: var(--bs-font);
}
#screen-merchant.mp-dark {
  --mp-bg: #0F172A;
  --mp-surface: #1E293B;
  --mp-text: #F1F5F9;
  --mp-muted: #94A3B8;
  --mp-border: #334155;
  --mp-side: #1E293B;
  --mp-side-text: #CBD5E1;
  --mp-side-muted: #64748B;
  --mp-hover: #283548;
}

.mp { display: grid; grid-template-columns: 264px 1fr; min-height: 100vh; background: var(--mp-bg); color: var(--mp-text); }

/* ---------- sidebar ---------- */
.mp-side { background: var(--mp-side); border-inline-end: 1px solid var(--mp-border); display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh; }
.mp-brand { display: flex; align-items: center; gap: 11px; padding: 18px 20px; border-bottom: 1px solid var(--mp-border); min-height: 70px; }
.mp-brand .mp-logo { width: 38px; height: 38px; border-radius: 9px; background: var(--mp); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 19px; flex-shrink: 0; overflow: hidden; }
.mp-brand .mp-logo img { width: 100%; height: 100%; object-fit: cover; }
.mp-brand .mp-bn { font-size: 16px; font-weight: 700; line-height: 1.15; color: var(--mp-text); }
.mp-brand .mp-bn small { display: block; font-size: 11px; font-weight: 500; color: var(--mp-muted); }

.mp-nav { flex: 1; overflow-y: auto; padding: 12px 12px 18px; }
.mp-nav::-webkit-scrollbar { width: 6px; }
.mp-nav::-webkit-scrollbar-thumb { background: var(--mp-border); border-radius: 3px; }
.mp-sec { font-size: 11px; font-weight: 700; letter-spacing: .7px; text-transform: uppercase; color: var(--mp-side-muted);
  padding: 16px 12px 7px; }
.mp-link { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 9px; cursor: pointer;
  color: var(--mp-side-text); font-size: 14px; font-weight: 500; transition: background .12s, color .12s; }
.mp-link .material-symbols-outlined { font-size: 20px; flex-shrink: 0; }
.mp-link:hover { background: var(--mp-hover); }
.mp-link.on { background: var(--mp); color: #fff; box-shadow: 0 4px 12px -3px color-mix(in srgb, var(--mp) 55%, transparent); }
.mp-link .mp-badge { margin-inline-start: auto; background: #EF4444; color: #fff; font-size: 11px; font-weight: 700; min-width: 19px; height: 19px;
  border-radius: 10px; display: grid; place-items: center; padding: 0 5px; }
.mp-link.on .mp-badge { background: rgba(255,255,255,.28); }

.mp-side-foot { border-top: 1px solid var(--mp-border); padding: 12px; }
.mp-poweredby { font-size: 11px; color: var(--mp-side-muted); text-align: center; padding: 4px 0 10px; }
.mp-poweredby b { color: var(--mp-muted); font-weight: 700; }
.mp-logout { display: flex; align-items: center; gap: 11px; width: 100%; padding: 10px 12px; border: 0; background: transparent;
  font-family: inherit; cursor: pointer; color: var(--mp-side-text); border-radius: 9px; font-size: 14px; font-weight: 500; }
.mp-logout:hover { background: #FEE2E2; color: #DC2626; }
.mp-logout .material-symbols-outlined { font-size: 20px; }

/* ---------- header ---------- */
.mp-main { display: flex; flex-direction: column; min-width: 0; }
.mp-head { position: sticky; top: 0; z-index: 30; background: var(--mp-surface); border-bottom: 1px solid var(--mp-border);
  display: flex; align-items: center; gap: 18px; padding: 0 26px; min-height: 70px; }
.mp-burger { display: none; }
.mp-head .mp-title { font-size: 20px; font-weight: 700; color: var(--mp-text); }
.mp-search { margin-inline-start: auto; display: flex; align-items: center; gap: 8px; background: var(--mp-bg);
  border: 1px solid var(--mp-border); border-radius: var(--bs-r-pill); padding: 8px 14px; width: 260px; color: var(--mp-muted); }
.mp-search input { border: 0; background: transparent; outline: none; font-family: inherit; font-size: 14px; color: var(--mp-text); width: 100%; }
.mp-search .material-symbols-outlined { font-size: 18px; }
.mp-ico-btn { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--mp-border); background: var(--mp-surface);
  display: grid; place-items: center; cursor: pointer; color: var(--mp-muted); font-family: inherit; transition: all .12s; }
.mp-ico-btn:hover { background: var(--mp-hover); color: var(--mp-text); }
.mp-ico-btn .material-symbols-outlined { font-size: 20px; }
.mp-prof { display: flex; align-items: center; gap: 9px; cursor: pointer; padding: 5px 8px 5px 5px; border-radius: var(--bs-r-pill); }
.mp-prof:hover { background: var(--mp-hover); }
.mp-prof .mp-av { width: 36px; height: 36px; border-radius: 50%; background: var(--mp); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 14px; }
.mp-prof .mp-pn { font-size: 13.5px; font-weight: 600; line-height: 1.2; color: var(--mp-text); }
.mp-prof .mp-pn small { display: block; font-size: 11.5px; font-weight: 500; color: var(--mp-muted); }
.mp-prof .material-symbols-outlined { font-size: 18px; color: var(--mp-muted); }

/* ---------- content ---------- */
.mp-body { padding: 28px 26px 60px; overflow-y: auto; }
.mp-view { display: none; }
.mp-view.on { display: block; animation: mpfade .25s ease; }
@keyframes mpfade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.mp-h1 { font-size: 24px; font-weight: 700; color: var(--mp-text); }
.mp-sub { font-size: 14px; color: var(--mp-muted); margin-top: 3px; }
.mp-view-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }

.mp-btn { font-family: inherit; cursor: pointer; border: 0; border-radius: var(--bs-r-input); font-size: 14px; font-weight: 600;
  padding: 11px 18px; display: inline-flex; align-items: center; gap: 7px; transition: all .12s; }
.mp-btn .material-symbols-outlined { font-size: 18px; }
.mp-btn-primary { background: var(--mp); color: #fff; }
.mp-btn-primary:hover { filter: brightness(.93); }
.mp-btn-ghost { background: var(--mp-surface); color: var(--mp-text); border: 1px solid var(--mp-border); }
.mp-btn-ghost:hover { background: var(--mp-hover); }

/* stat cards */
.mp-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 24px; }
.mp-stat { background: var(--mp-surface); border: 1px solid var(--mp-border); border-radius: 12px; padding: 22px; box-shadow: var(--bs-elev-sm);
  display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.mp-stat .ms-l { font-size: 13px; color: var(--mp-muted); }
.mp-stat .ms-v { font-size: 27px; font-weight: 700; color: var(--mp-text); margin-top: 4px; letter-spacing: -.5px; }
.mp-stat .ms-ico { width: 50px; height: 50px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.mp-stat .ms-ico .material-symbols-outlined { font-size: 25px; }
.ms-blue   { background: #DBEAFE; color: #2563EB; }
.ms-green  { background: #DCFCE7; color: #16A34A; }
.ms-purple { background: #EDE9FE; color: #7C3AED; }
.ms-orange { background: #FFEDD5; color: #EA580C; }
.mp-dark .ms-blue { background: rgba(37,99,235,.2); color: #93C5FD; }
.mp-dark .ms-green { background: rgba(22,163,74,.2); color: #86EFAC; }
.mp-dark .ms-purple { background: rgba(124,58,237,.2); color: #C4B5FD; }
.mp-dark .ms-orange { background: rgba(234,88,12,.2); color: #FDBA74; }

/* two-up cards */
.mp-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 24px; }
.mp-card { background: var(--mp-surface); border: 1px solid var(--mp-border); border-radius: 12px; padding: 22px; box-shadow: var(--bs-elev-sm); }
.mp-card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.mp-card-head h3 { font-size: 16px; font-weight: 600; color: var(--mp-text); }
.mp-card-head .material-symbols-outlined { font-size: 20px; color: var(--mp-muted); }
.mp-rev .rev-row { padding: 10px 0; }
.mp-rev .rev-row .rl { font-size: 13px; color: var(--mp-muted); }
.mp-rev .rev-row .rv { font-size: 23px; font-weight: 700; color: var(--mp-text); margin-top: 2px; }
.mp-rev .rev-trend { display: flex; align-items: center; gap: 6px; padding-top: 12px; margin-top: 6px; border-top: 1px solid var(--mp-border); font-size: 13px; color: #16A34A; font-weight: 600; }
.mp-rev .rev-trend .material-symbols-outlined { font-size: 18px; }

/* mini bar chart (reports/revenue) */
.mp-bars { display: flex; align-items: flex-end; gap: 10px; height: 150px; padding-top: 8px; }
.mp-bars .bar { flex: 1; background: color-mix(in srgb, var(--mp) 22%, transparent); border-radius: 6px 6px 0 0; position: relative; display: flex; justify-content: center; align-items: flex-end; min-height: 4px; }
.mp-bars .bar i { position: absolute; inset: 0; background: var(--mp); border-radius: 6px 6px 0 0; opacity: .85; }
.mp-bars .bar span { position: absolute; bottom: -22px; font-size: 11px; color: var(--mp-muted); }

/* popular slots */
.mp-slots { display: grid; grid-template-columns: repeat(8, 1fr); gap: 10px; }
.mp-slot { text-align: center; padding: 12px 6px; background: var(--mp-bg); border-radius: 10px; }
.mp-slot .t { font-size: 11px; color: var(--mp-muted); }
.mp-slot .b { font-size: 16px; font-weight: 700; color: var(--mp-text); margin-top: 3px; }

/* quick actions */
.mp-qa { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.mp-qa-btn { display: flex; flex-direction: column; align-items: center; gap: 9px; padding: 20px; border-radius: 12px;
  border: 1px solid var(--mp-border); background: var(--mp-surface); cursor: pointer; color: var(--mp-text); font-family: inherit;
  font-size: 13.5px; font-weight: 600; transition: all .12s; }
.mp-qa-btn:hover { border-color: var(--mp); color: var(--mp); background: color-mix(in srgb, var(--mp) 6%, var(--mp-surface)); }
.mp-qa-btn .material-symbols-outlined { font-size: 28px; }

/* data table */
.mp-table-wrap { background: var(--mp-surface); border: 1px solid var(--mp-border); border-radius: 12px; overflow: hidden; box-shadow: var(--bs-elev-sm); }
.mp-table-tools { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--mp-border); }
.mp-table-tools .mp-search { margin: 0; width: 280px; }
.mp-table-tools .spacer { flex: 1; }
table.mp-table { width: 100%; border-collapse: collapse; font-size: 14px; }
table.mp-table th { text-align: start; font-size: 12px; font-weight: 600; letter-spacing: .4px; text-transform: uppercase;
  color: var(--mp-muted); padding: 13px 18px; background: var(--mp-bg); border-bottom: 1px solid var(--mp-border); white-space: nowrap; }
table.mp-table td { padding: 14px 18px; border-bottom: 1px solid var(--mp-border); color: var(--mp-text); vertical-align: middle; }
table.mp-table tr:last-child td { border-bottom: 0; }
table.mp-table tbody tr { transition: background .1s; }
table.mp-table tbody tr:hover { background: var(--mp-hover); }
.mp-cell-main { font-weight: 600; }
.mp-cell-sub { font-size: 12.5px; color: var(--mp-muted); margin-top: 2px; }
.mp-row-actions { display: flex; gap: 6px; }
.mp-row-actions button { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--mp-border); background: var(--mp-surface);
  display: grid; place-items: center; cursor: pointer; color: var(--mp-muted); font-family: inherit; }
.mp-row-actions button:hover { color: var(--mp); border-color: var(--mp); }
.mp-row-actions .material-symbols-outlined { font-size: 17px; }

.mp-badge-pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; padding: 4px 11px; border-radius: var(--bs-r-pill); white-space: nowrap; }
.mp-badge-pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.bg-active   { background: #DCFCE7; color: #15803D; }
.bg-pending  { background: #FEF3C7; color: #B45309; }
.bg-cancel   { background: #FEE2E2; color: #DC2626; }
.bg-confirm  { background: #DBEAFE; color: #1D4ED8; }
.bg-done     { background: #F1F5F9; color: #475569; }
.mp-dark .bg-active { background: rgba(22,163,74,.18); color: #86EFAC; }
.mp-dark .bg-pending { background: rgba(180,83,9,.22); color: #FCD34D; }
.mp-dark .bg-cancel { background: rgba(220,38,38,.2); color: #FCA5A5; }
.mp-dark .bg-confirm { background: rgba(37,99,235,.2); color: #93C5FD; }
.mp-dark .bg-done { background: rgba(71,85,105,.3); color: #CBD5E1; }

.mp-table-foot { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-top: 1px solid var(--mp-border); font-size: 13px; color: var(--mp-muted); }
.mp-pager { display: flex; gap: 6px; }
.mp-pager button { min-width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--mp-border); background: var(--mp-surface); cursor: pointer; font-family: inherit; font-size: 13px; color: var(--mp-text); }
.mp-pager button.on { background: var(--mp); color: #fff; border-color: var(--mp); }

/* calendar — day view (courts as columns) */
.mp-cal-nav { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: var(--mp-surface); border: 1px solid var(--mp-border);
  border-radius: 12px; padding: 10px 14px; margin-bottom: 16px; box-shadow: var(--bs-elev-sm); }
.mp-cal-pickwrap { position: relative; display: inline-flex; }
.mp-cal-pick { position: absolute; inset-inline-start: 0; bottom: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; border: 0; padding: 0; margin: 0; }
.mp-cal-nav .nav-btn { width: 38px; height: 38px; border-radius: 9px; border: 1px solid var(--mp-border); background: var(--mp-surface);
  cursor: pointer; color: var(--mp-text); display: grid; place-items: center; font-family: inherit; transition: all .12s; }
.mp-cal-nav .nav-btn:hover { background: var(--mp-hover); border-color: var(--mp); color: var(--mp); }
.mp-cal-nav .nav-btn .material-symbols-outlined { font-size: 22px; }
[dir="rtl"] .mp-cal-nav .nav-btn .material-symbols-outlined { transform: scaleX(-1); }
.mp-cal-nav .nav-date { font-size: 15px; font-weight: 700; color: var(--mp-text); min-width: 200px; text-align: center; }
.mp-cal-navline { display: flex; align-items: center; gap: 10px; }
.mp-cal-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-inline-start: auto; }

.mp-cal { background: var(--mp-surface); border: 1px solid var(--mp-border); border-radius: 12px; overflow: hidden; box-shadow: var(--bs-elev-sm); }
.mp-cal-strip { background: linear-gradient(90deg, color-mix(in srgb, var(--mp) 78%, #000) 0%, var(--mp) 100%); color: #fff; padding: 14px 18px; }
.mp-cal-strip .t { font-size: 15px; font-weight: 700; }
.mp-cal-strip .s { font-size: 12.5px; opacity: .9; margin-top: 2px; }
.mp-cal-scroll { overflow-x: auto; }
.mp-cal-grid { display: grid; }            /* grid-template-columns set inline */
.mp-cal-grid > div { border-bottom: 1px solid var(--mp-border); border-inline-end: 1px solid var(--mp-border); }
.mp-cal-grid .chx { background: var(--mp-bg); }
.mp-cal-grid .ch { background: var(--mp-bg); padding: 10px 8px; text-align: center; }
.mp-cal-grid .ch .cn { font-size: 13px; font-weight: 700; color: var(--mp-text); white-space: nowrap; }
.mp-cal-grid .ch .cs { font-size: 11px; color: var(--mp-muted); margin-top: 1px; }
.mp-cal-grid .ct { color: var(--mp-muted); font-size: 12px; font-weight: 600; display: flex; align-items: center; justify-content: center; padding: 8px; }
.mp-cal-cell { padding: 5px; }
.mp-cal-cell .mp-slot { width: 100%; min-height: 44px; border-radius: 8px; padding: 6px 9px; font-family: inherit; cursor: pointer;
  display: flex; flex-direction: column; justify-content: center; gap: 2px; border: 1px solid transparent; transition: all .12s; text-align: start; }
.mp-slot .nm { font-size: 12px; font-weight: 700; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mp-slot .am { font-size: 10.5px; opacity: .92; }
.mp-slot.paid { background: linear-gradient(135deg, #22C55E, #16A34A); color: #fff; border-color: #15803D; }
.mp-slot.pending { background: linear-gradient(135deg, #FBBF24, #F97316); color: #fff; border-color: #EA580C; }
.mp-slot.cancelled { background: linear-gradient(135deg, #F87171, #EF4444); color: #fff; border-color: #DC2626; }
.mp-slot.paid:hover, .mp-slot.pending:hover, .mp-slot.cancelled:hover { transform: translateY(-1px); box-shadow: 0 4px 10px -3px rgba(0,0,0,.3); filter: brightness(1.05); }
.mp-slot.avail { background: var(--mp-surface); border: 1px solid var(--mp-border); color: var(--mp-muted); align-items: center; justify-content: center; }
.mp-slot.avail:hover { background: color-mix(in srgb, var(--mp) 8%, var(--mp-surface)); border-color: var(--mp); color: var(--mp); }
.mp-slot.avail .am { font-weight: 700; font-size: 11.5px; opacity: 1; }
.mp-cell-unavail { display: flex; align-items: center; justify-content: center; min-height: 44px; color: var(--mp-muted); font-size: 11px; opacity: .65; }

.mp-cal-legend { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 14px; }
.mp-cal-legend .lg { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--mp-muted); font-weight: 600; }
.mp-cal-legend .sw { width: 14px; height: 14px; border-radius: 4px; }
.mp-cal-legend .sw.paid { background: linear-gradient(135deg, #22C55E, #16A34A); }
.mp-cal-legend .sw.pending { background: linear-gradient(135deg, #FBBF24, #F97316); }
.mp-cal-legend .sw.cancelled { background: linear-gradient(135deg, #F87171, #EF4444); }
.mp-cal-legend .sw.avail { background: var(--mp-surface); border: 1px solid var(--mp-border); }

/* calendar modal helpers */
.mp-cal-sum { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; background: var(--mp-bg); border-radius: 10px; padding: 14px; }
.mp-cal-sum > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.mp-cal-sum span { font-size: 11px; text-transform: uppercase; letter-spacing: .4px; color: var(--mp-muted); font-weight: 700; }
.mp-cal-sum b { font-size: 14px; color: var(--mp-text); }
.mp-cal-sum b.amt { color: var(--mp); }
.mp-cal-detail { display: flex; flex-direction: column; }
.mp-cal-detail .row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 2px; border-bottom: 1px solid var(--mp-border); font-size: 14px; }
.mp-cal-detail .row:last-child { border-bottom: 0; }
.mp-cal-detail .row > span { color: var(--mp-muted); }
.mp-cal-detail .row > b { color: var(--mp-text); font-weight: 600; }

.mp-empty { text-align: center; padding: 50px 20px; color: var(--mp-muted); }
.mp-empty .material-symbols-outlined { font-size: 46px; opacity: .5; }

/* sport icon (tintable — fills with currentColor) */
.mp-sport-ico { display: inline-flex; align-items: center; justify-content: center; width: 1em; height: 1em; color: inherit; }
.mp-sport-ico svg { width: 100%; height: 100%; display: block; }
.mp-sport-ico svg path { fill: currentColor !important; }
.mp-sport-cell { display: inline-flex; align-items: center; gap: 9px; font-weight: 600; }
.mp-sport-cell .mp-sport-ico { width: 22px; height: 22px; color: var(--mp); flex-shrink: 0; }

/* sports management grid */
.mp-sports-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.mp-sport-card { background: var(--mp-surface); border: 1px solid var(--mp-border); border-radius: 14px; padding: 20px; box-shadow: var(--bs-elev-sm);
  display: flex; flex-direction: column; gap: 16px; }
.mp-sport-top { display: flex; align-items: center; gap: 13px; }
.mp-sport-badge { width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0; display: grid; place-items: center;
  background: color-mix(in srgb, var(--mp) 12%, transparent); color: var(--mp); }
.mp-sport-badge .mp-sport-ico { width: 27px; height: 27px; }
.mp-sport-meta { flex: 1; min-width: 0; }
.mp-sport-name { font-size: 17px; font-weight: 700; color: var(--mp-text); }
.mp-sport-courts { font-size: 12.5px; color: var(--mp-muted); margin-top: 1px; }
.mp-sport-group .mp-sport-glabel { font-size: 11px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; color: var(--mp-muted); margin-bottom: 8px; }
.mp-chips { display: flex; flex-wrap: wrap; gap: 7px; }
.mp-chip { font-size: 12.5px; font-weight: 600; padding: 5px 11px; border-radius: var(--bs-r-pill);
  background: var(--mp-bg); color: var(--mp-text); border: 1px solid var(--mp-border); }
.mp-sport-actions { display: flex; gap: 8px; margin-top: auto; padding-top: 4px; }
.mp-sport-actions .mp-btn { flex: 1; justify-content: center; padding: 9px 12px; font-size: 13px; }
.mp-icon-sq { width: 40px; flex-shrink: 0; border: 1px solid var(--mp-border); background: var(--mp-surface); border-radius: var(--bs-r-input);
  display: grid; place-items: center; cursor: pointer; color: var(--mp-muted); font-family: inherit; }
.mp-icon-sq:hover { color: var(--mp); border-color: var(--mp); }
.mp-icon-sq .material-symbols-outlined { font-size: 19px; }

/* ---------- responsive ---------- */
.mp-scrim { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 90; }
.mp-scrim.show { display: block; }
@media (max-width: 1080px) {
  .mp-stats { grid-template-columns: repeat(2, 1fr); }
  .mp-grid2 { grid-template-columns: 1fr; }
  .mp-qa { grid-template-columns: repeat(2, 1fr); }
  .mp-slots { grid-template-columns: repeat(4, 1fr); }
  .mp-sports-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .mp { grid-template-columns: 1fr; }
  .mp-side { position: fixed; top: 0; bottom: 0; inset-inline-start: 0; width: 274px; z-index: 100;
    transform: translateX(-100%); transition: transform .25s ease; }
  [dir="rtl"] .mp-side { transform: translateX(100%); }
  .mp-side.open { transform: translateX(0); }
  .mp-burger { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 9px; border: 1px solid var(--mp-border);
    background: var(--mp-surface); cursor: pointer; color: var(--mp-text); font-family: inherit; }
  .mp-burger .material-symbols-outlined { font-size: 22px; }
  .mp-head { padding: 0 16px; gap: 12px; }
  .mp-head .mp-search { display: none; }
  .mp-body { padding: 20px 16px 70px; }
  .mp-stats { grid-template-columns: 1fr; }
  .mp-slots { grid-template-columns: repeat(4, 1fr); }
  .mp-qa { grid-template-columns: 1fr 1fr; }
  .mp-sports-grid { grid-template-columns: 1fr; }
  .mp-prof .mp-pn { display: none; }
  .mp-cal-wrap { overflow-x: auto; }
  .mp-cal { min-width: 680px; }
  table.mp-table { min-width: 640px; }
  .mp-table-scroll { overflow-x: auto; }
}

/* ============================================================
   EDITING — modal, forms, editable chips, empty state
   ============================================================ */
.mp-status-btn { cursor: pointer; border: 0; font-family: inherit; }
.mp-status-btn:hover { filter: brightness(.96); }
.mp-row-actions button[data-act="del"]:hover { color: #DC2626; border-color: #DC2626; }
.mp-empty { text-align: center; padding: 40px 16px; color: var(--mp-muted); font-size: 14px; }

.mp-modal-overlay { position: fixed; inset: 0; z-index: 1000; background: rgba(4,5,3,.5);
  display: flex; align-items: flex-start; justify-content: center; padding: 44px 16px; overflow-y: auto;
  opacity: 0; pointer-events: none; transition: opacity .18s; }
.mp-modal-overlay.show { opacity: 1; pointer-events: auto; }
.mp-modal { background: var(--mp-surface); color: var(--mp-text); border: 1px solid var(--mp-border);
  border-radius: 16px; width: 100%; max-width: 540px; box-shadow: 0 26px 70px -16px rgba(0,0,0,.45);
  display: flex; flex-direction: column; margin: auto; transform: translateY(10px) scale(.985); transition: transform .2s; }
.mp-modal-overlay.show .mp-modal { transform: none; }
.mp-modal-head { display: flex; align-items: center; gap: 13px; padding: 18px 20px; border-bottom: 1px solid var(--mp-border); }
.mp-modal-ico { width: 42px; height: 42px; border-radius: 12px; flex-shrink: 0; display: grid; place-items: center;
  background: color-mix(in srgb, var(--mp) 13%, transparent); color: var(--mp); font-size: 22px; }
.mp-modal-head h3 { flex: 1; font-size: 18px; font-weight: 700; line-height: 1.25; }
.mp-modal-x { width: 34px; height: 34px; border-radius: 9px; border: 0; background: transparent; cursor: pointer;
  color: var(--mp-muted); display: grid; place-items: center; font-family: inherit; flex-shrink: 0; }
.mp-modal-x:hover { background: var(--mp-hover); color: var(--mp-text); }
.mp-modal-x .material-symbols-outlined { font-size: 20px; }
.mp-modal-body { padding: 24px; display: flex; flex-direction: column; gap: 22px; max-height: 64vh; overflow-y: auto; }
.mp-modal-foot { display: flex; align-items: center; gap: 9px; padding: 15px 20px; border-top: 1px solid var(--mp-border); }
.mp-foot-spacer { flex: 1; }
.mp-btn-danger { background: transparent; color: #DC2626; border: 1px solid transparent; }
.mp-btn-danger:hover { background: #FEE2E2; }

.mp-field { display: flex; flex-direction: column; gap: 7px; }
.mp-field > label { font-size: 12px; font-weight: 700; letter-spacing: .2px; color: var(--mp-muted); text-transform: uppercase; }
.mp-input { font-family: inherit; font-size: 14px; padding: 10px 13px; border-radius: var(--bs-r-input); width: 100%;
  border: 1px solid var(--mp-border); background: var(--mp-bg); color: var(--mp-text); outline: none; transition: border-color .12s; }
.mp-input:focus { border-color: var(--mp); }
select.mp-input { cursor: pointer; appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 11px center; padding-inline-end: 36px; }
[dir="rtl"] select.mp-input { background-position: left 11px center; }
.mp-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }

.mp-seg { display: flex; flex-wrap: wrap; gap: 7px; }
.mp-seg button { font-family: inherit; font-size: 13px; font-weight: 600; padding: 8px 15px; border-radius: var(--bs-r-pill);
  border: 1px solid var(--mp-border); background: var(--mp-surface); color: var(--mp-muted); cursor: pointer; transition: all .12s; }
.mp-seg button:hover { border-color: var(--mp); color: var(--mp-text); }
.mp-seg button.on { background: var(--mp); color: #fff; border-color: var(--mp); }

.mp-echips { display: flex; flex-wrap: wrap; gap: 8px; min-height: 4px; }
.mp-echip { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 600;
  padding-block: 6px; padding-inline: 12px 7px; border-radius: var(--bs-r-pill);
  background: var(--mp-bg); border: 1px solid var(--mp-border); color: var(--mp-text); }
.mp-echip button { border: 0; background: transparent; cursor: pointer; color: var(--mp-muted);
  display: grid; place-items: center; padding: 0; width: 18px; height: 18px; border-radius: 50%; }
.mp-echip button:hover { background: #FEE2E2; color: #DC2626; }
.mp-echip button .material-symbols-outlined { font-size: 15px; }
.mp-echips-empty { font-size: 13px; color: var(--mp-muted); font-style: italic; }
.mp-chip-add { display: flex; gap: 8px; }
.mp-chip-add .mp-input { flex: 1; }
.mp-chip-add button { flex-shrink: 0; padding: 9px 13px; }

@media (max-width: 560px) {
  .mp-field-row { grid-template-columns: 1fr; }
  .mp-modal-overlay { padding: 16px 12px; }
}