/* match-controls.css - Match Controls (#matchCommandCenterModal)
 *
 * Filled by showCommandCenterModal() in js/bracket-rendering.js. Three views, by the
 * tournament's status: before the draw (players, settings, Shuffle & Draw), running (the
 * lanes board, the ready queue, referees) and finished (podium and highlights). Uses the
 * shared tokens in css/design-tokens.css. Light only.
 */

/* ---- the view: a layer over the bracket in the same frame ---- */
#matchCommandCenterModal.mc-view {
  position: absolute; inset: 0; z-index: 20; overflow: auto;
  background: var(--nt-bg); border-radius: 10px;
  font-family: var(--nt-sans); font-size: 14px; line-height: 1.45; color: var(--nt-ink);
}
.mc-view button, .mc-view input, .mc-view select { font: inherit; color: inherit; }
.mc-view :focus-visible { outline: 2px solid var(--nt-accent); outline-offset: 2px; }
.mc-view [hidden] { display: none !important; }
/* a match picked in the bracket's selection bar flashes once */
.mc-flash { animation: mc-flash 1.8s ease-out 1; }
@keyframes mc-flash { 0% { box-shadow: 0 0 0 4px rgba(255,107,53,.7); } 100% { box-shadow: 0 0 0 0 rgba(255,107,53,0); } }

.mc-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 16px; padding: 2px 0 16px; align-content: start; }
.mc-body.mc-one { grid-template-columns: minmax(0, 1fr); }
.mc-col { display: grid; gap: 20px; align-content: start; min-width: 0; }

.mc-panel { background: var(--nt-surface); border: 1px solid var(--nt-line); border-radius: 12px; min-width: 0; }
.mc-ph { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; flex-wrap: wrap; padding: 14px 18px 10px; }
.mc-ph h3 { margin: 0; font-size: 15px; font-weight: 700; color: var(--nt-ink); }
.mc-ph h3 small { font-weight: 500; color: var(--nt-muted); font-size: 13px; margin-left: 6px; }
.mc-hint, .mc-note { font-size: 12px; color: var(--nt-muted); }
.mc-hint .mc-scan { margin-left: 10px; }
.mc-note { margin: 0; padding: 0 18px 14px; }
.mc-empty { display: grid; gap: 4px; place-items: center; text-align: center; padding: 48px 20px; color: var(--nt-muted); }
.mc-empty b { color: var(--nt-ink); font-size: 16px; }

/* ---- controls ---- */
.mc-btn { height: 34px; border-radius: 8px; padding: 0 12px; font-weight: 600; font-size: 13px; cursor: pointer; border: 1px solid var(--nt-line-2); background: var(--nt-surface); color: var(--nt-ink-2); white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.mc-btn:hover { border-color: var(--nt-ink-2); }
.mc-btn.mc-sm { height: 28px; padding: 0 10px; font-size: 12px; }
.mc-btn.mc-primary { background: var(--nt-header); border-color: var(--nt-header); color: var(--nt-header-ink); }
.mc-btn.mc-primary:hover { background: var(--nt-accent); border-color: var(--nt-accent); color: #fff; }
.mc-btn:disabled { opacity: .45; cursor: not-allowed; }
.mc-btn.mc-primary:disabled:hover { background: var(--nt-header); border-color: var(--nt-header); color: var(--nt-header-ink); }
/* a result has come back from a Chalker: pulse until it is reviewed */
.mc-btn.mc-result { background: #16a34a; border-color: #16a34a; color: #fff; animation: mc-pulse 1.6s ease-in-out infinite; }
@keyframes mc-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(34,197,94,.5); } 50% { box-shadow: 0 0 10px 3px rgba(34,197,94,.25); } }
.mc-link { border: 0; background: none; padding: 0; color: var(--nt-muted); font-size: 13px; font-weight: 500; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.mc-link:hover { color: var(--nt-ink); }
.mc-sel { height: 30px; border: 1px solid var(--nt-line-2); border-radius: 7px; padding: 0 6px; background: var(--nt-surface); font-size: 13px; min-width: 0; max-width: 100%; }
.mc-text { height: 36px; border: 1px solid var(--nt-line-2); border-radius: 8px; padding: 0 12px; background: var(--nt-surface); flex: 1; min-width: 0; font-size: 14px; }
.mc-text:focus { outline: none; border-color: var(--nt-ink-2); box-shadow: 0 0 0 3px var(--nt-inset); }
.mc-warnname { color: var(--nt-warn); }

/* ---- the lanes board: one tile per live match ---- */
.mc-lanes { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; padding: 0 18px 16px; }
.mc-lane { border: 1px solid var(--nt-line); border-radius: 12px; background: var(--nt-surface); display: grid; min-width: 0; overflow: hidden; }
.mc-lane.mc-on { border-color: var(--nt-accent); box-shadow: inset 0 3px 0 var(--nt-accent); }
.mc-lane.mc-nolane { border-color: #f2c94c; box-shadow: inset 0 0 0 1px #f2c94c; } /* 2px all round, without moving the content */
.mc-lane-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px 6px; }
.mc-lane-no { font-weight: 800; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: #b2410f; }
.mc-nolane .mc-lane-no { color: var(--nt-warn); }
.mc-lane-meta { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--nt-muted); }
.mc-lane-time { font-variant-numeric: tabular-nums; }
.mc-dotsep { color: var(--nt-faint); }
.mc-lane-play { padding: 4px 14px 8px; display: grid; gap: 6px; }
.mc-wins { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; border: 1px solid var(--nt-line-2); border-radius: 10px; padding: 9px 12px; background: var(--nt-surface); cursor: pointer; text-align: left; }
.mc-wins:hover { border-color: var(--nt-ink); box-shadow: inset 0 0 0 1px var(--nt-ink); }
.mc-wins b { font-size: 17px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-wins span { font-size: 12px; font-weight: 700; color: var(--nt-muted); text-transform: uppercase; letter-spacing: .05em; }
.mc-wins:hover span { color: var(--nt-ink); }
.mc-lane-ctl { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); gap: 6px; padding: 0 14px 8px; }
.mc-lane-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 14px 12px; border-top: 1px solid var(--nt-line); }
.mc-round { font-size: 12px; color: var(--nt-muted); min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-acts { display: flex; gap: 6px; flex: none; }

/* free lanes on one line, above the live matches so it stays in one place all night:
   click one to start the next ready match there */
.mc-free { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; padding: 4px 18px 14px; border-bottom: 1px solid var(--nt-line); }
.mc-free + .mc-lanes { padding-top: 16px; }
.mc-k { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--nt-muted); }
.mc-lanechip { min-width: 34px; height: 30px; padding: 0 8px; border-radius: 8px; border: 1px dashed var(--nt-line-2); background: var(--nt-surface-2); font-weight: 800; color: var(--nt-ink-2); cursor: pointer; display: inline-grid; place-items: center; }
.mc-lanechip:hover { border-style: solid; border-color: var(--nt-ink); background: var(--nt-surface); color: var(--nt-ink); }
.mc-lanechip.mc-idle { cursor: default; }
.mc-lanechip.mc-idle:hover { border-style: dashed; border-color: var(--nt-line-2); background: var(--nt-surface-2); color: var(--nt-ink-2); }
/* a busy lane keeps its place in the row, dimmed (so the free ones never move under the pointer) */
.mc-lanechip.mc-busy { cursor: default; border-style: solid; border-color: var(--nt-line); background: var(--nt-inset); color: var(--nt-faint, #a8a29e); }
.mc-lanechip.mc-busy:hover { border-style: solid; border-color: var(--nt-line); background: var(--nt-inset); color: var(--nt-faint, #a8a29e); }
.mc-next { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--nt-ink-2); margin-left: 6px; flex-wrap: wrap; }
.mc-next em { font-style: normal; color: var(--nt-muted); font-size: 12px; }
.mc-none { font-size: 13px; color: var(--nt-muted); }
.mc-off { margin-left: auto; font-size: 12px; color: var(--nt-faint); }

/* ---- the ready queue, by round (frontside and backside side by side) ---- */
.mc-qcols { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--nt-line); }
.mc-qcols.mc-one { grid-template-columns: 1fr; }
.mc-qcol { min-width: 0; }
.mc-qcol + .mc-qcol { border-left: 1px solid var(--nt-line); }
.mc-qround { display: flex; justify-content: space-between; padding: 10px 18px 4px; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--nt-muted); }
/* a group with nothing left to start: the heading only; greyed only when every match is played */
.mc-qround.mc-qdone, .mc-qround.mc-qempty-live { padding-bottom: 10px; }
.mc-qround.mc-qdone { color: var(--nt-faint); }
.mc-qrow { display: grid; grid-template-columns: auto minmax(0, 1fr) 96px minmax(0, 150px) auto; align-items: center; gap: 10px; padding: 8px 18px; border-bottom: 1px solid var(--nt-line); }
.mc-qcol .mc-qrow:last-child { border-bottom: 0; }
.mc-who { min-width: 0; display: grid; }
.mc-who > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-who b { font-weight: 600; }
.mc-vs { color: var(--nt-faint); margin: 0 6px; }
.mc-who small { font-size: 12px; color: var(--nt-muted); }
.mc-who small.mc-warn { color: var(--nt-warn); }
.mc-who small.mc-wait { color: var(--nt-ink-2); } /* groups and cups: waits for its referee, or for its players' referee duty */
.mc-qempty { padding: 16px 18px; color: var(--nt-muted); font-size: 13px; }

/* ---- referees ---- */
.mc-refs { padding: 0 18px 12px; display: grid; gap: 12px; }
.mc-refs h4 { margin: 0 0 6px; font-size: 12px; font-weight: 700; color: var(--nt-muted); letter-spacing: .04em; text-transform: uppercase; }
.mc-refs ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.mc-refs li { display: flex; justify-content: space-between; gap: 8px; font-size: 13px; padding: 3px 0; }
.mc-refs li b { font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.mc-refs li span { color: var(--nt-muted); font-size: 12px; white-space: nowrap; }


/* ---- before the draw ---- */
.mc-addrow { display: flex; gap: 8px; padding: 0 18px 14px; }
.mc-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 18px 16px; }
.mc-chips .mc-note { padding: 0; }
.mc-chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--nt-line-2); background: var(--nt-surface); font-weight: 600; font-size: 13px; cursor: pointer; }
.mc-chip.mc-paid { background: var(--nt-ok-soft); border-color: #b9dcc5; color: var(--nt-ok); }
.mc-chip.mc-paid::before { content: "\2713"; }
.mc-chip.mc-unpaid { background: var(--nt-warn-soft); border-color: #f4dc9a; color: var(--nt-warn); }
/* an unpaid chip: the name (mark paid) and a × (remove), two buttons in one chip */
.mc-chip-split { padding: 0; gap: 0; cursor: default; overflow: hidden; }
.mc-chip-split button { height: 100%; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; padding: 0 8px 0 12px; }
.mc-chip-split .mc-chip-x { padding: 0 10px 0 8px; border-left: 1px solid #f4dc9a; font-size: 15px; line-height: 1; }
.mc-chip-split .mc-chip-x:hover { color: var(--nt-danger); background: #fdecec; }
.mc-note.mc-warn { color: var(--nt-warn); }
/* Swiss: the table in the right column (as Round Robin's group tables) */
.mc-swtable { margin: 0; padding: 0 18px 6px 38px; font-size: 13px; }
.mc-swtable li { padding: 3px 0; }
.mc-swtable li b { font-weight: 600; }
.mc-swtable li span { float: right; color: var(--nt-muted); font-variant-numeric: tabular-nums; }
.mc-swtable li.mc-toa { box-shadow: inset 3px 0 0 var(--nt-ok); margin-left: -20px; padding-left: 17px; }
.mc-swiss > .mc-note { padding: 0 18px 14px; margin: 0; }
/* Pick a format: one card per format (the picked one framed), the picked format's description,
   facts and options, then the Draw bar. A format not offered is greyed out and locked; one that
   doesn't fit tonight's field can still be picked (to change its options), and says why. */
.mc-fcards { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; padding: 0 18px 14px; }
.mc-fcard { position: relative; text-align: left; font: inherit; color: var(--nt-ink); background: var(--nt-surface); border: 2px solid var(--nt-line-2); border-radius: 12px; padding: 12px 14px; display: grid; gap: 3px; align-content: start; cursor: pointer; }
.mc-fcard:hover { border-color: #a8a29e; }
.mc-fcard.mc-on { border-color: var(--nt-accent); box-shadow: inset 0 3px 0 var(--nt-accent); }
.mc-fcard b { font-size: 15px; padding-right: 22px; }
.mc-fpic { display: block; height: 44px; margin-bottom: 6px; } /* the format's pictogram (TOURNAMENT_FORMATS pic) */
.mc-fpic svg { display: block; }
.mc-fcard.mc-on .mc-fpic .dk { fill: var(--nt-accent); }
.mc-fcard.mc-off .mc-fpic { opacity: .4; }
.mc-fline { font-weight: 700; font-size: 13px; color: #c0562a; }
.mc-ffit { font-size: 12px; color: var(--nt-muted); margin-top: 3px; }
.mc-ffit b { font-size: 12px; color: var(--nt-ink-2); padding: 0; }
.mc-fradio { position: absolute; top: 13px; right: 12px; width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--nt-line-2); }
.mc-fcard.mc-on .mc-fradio { border-color: var(--nt-accent); background: var(--nt-accent); box-shadow: inset 0 0 0 3px var(--nt-surface); }
.mc-fcard.mc-off { cursor: not-allowed; background: var(--nt-surface-2); border-style: dashed; }
.mc-fcard.mc-off:hover { border-color: var(--nt-line-2); }
.mc-fcard.mc-off b, .mc-fcard.mc-off .mc-fline { color: var(--nt-faint, #a8a29e); }
.mc-fcard.mc-off .mc-fradio { display: none; }
.mc-fcard.mc-nofit .mc-ffit { color: var(--nt-warn); }
.mc-fdetail { display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 18px; padding: 14px 18px 6px; border-top: 1px solid var(--nt-line); }
.mc-fdetail h4 { margin: 0 0 6px; font-size: 16px; }
.mc-fdetail p { margin: 0 0 8px; color: var(--nt-ink-2); max-width: 72ch; }
.mc-fdetail ul { margin: 0 0 10px; padding-left: 18px; color: var(--nt-ink-2); font-size: 13px; }
.mc-ffacts { margin: 0; display: grid; gap: 6px; align-content: start; font-size: 13px; }
.mc-ffacts div { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px dashed var(--nt-line); padding-bottom: 5px; }
.mc-ffacts dt { color: var(--nt-muted); }
.mc-ffacts dd { margin: 0; font-weight: 600; text-align: right; }
.mc-fopts { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; margin: 0 0 10px; font-size: 13px; }
.mc-fopts small { color: var(--nt-muted); font-size: 12px; }
.mc-seg { display: inline-flex; border: 1px solid var(--nt-line-2); border-radius: 8px; overflow: hidden; }
.mc-seg button { font: inherit; font-size: 12px; font-weight: 600; padding: 5px 10px; border: 0; background: var(--nt-surface); color: var(--nt-ink-2); cursor: pointer; }
.mc-seg button + button { border-left: 1px solid var(--nt-line-2); }
.mc-seg button.mc-on { background: var(--nt-header); color: var(--nt-header-ink); }
.mc-pick > .mc-note { padding: 0 18px 14px; margin: 0; }
@media (max-width: 900px) { .mc-fdetail { grid-template-columns: 1fr; } }
.mc-check { display: flex; align-items: center; gap: 8px; padding: 2px 18px; font-size: 13px; cursor: pointer; }
.mc-check small { color: var(--nt-muted); font-size: 12px; }
.mc-check input { flex: none; }
.mc-seedon { padding-bottom: 12px; font-weight: 600; }
.mc-seedctl { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px 12px; padding: 0 18px 12px; }
.mc-seedctl label:first-child { grid-column: 1 / -1; }
.mc-seedctl label { display: grid; gap: 4px; font-size: 12px; font-weight: 600; color: var(--nt-muted); min-width: 0; }
.mc-seedctl .mc-text, .mc-seedctl select { font-weight: 400; color: var(--nt-ink); }
.mc-seedctl select { width: 100%; min-width: 0; height: 36px; border: 1px solid var(--nt-line-2); border-radius: 8px; padding: 0 8px; background: var(--nt-surface); font-size: 14px; }
.mc-seedlist { padding: 0 0 10px; display: grid; gap: 2px; }
.mc-seedlist .mc-note { padding: 0 18px 4px; }
.mc-seedlist details { padding-top: 6px; }
.mc-seedlist summary { padding: 2px 18px; font-size: 12px; color: var(--nt-muted); cursor: pointer; }
.mc-seeds { list-style: none; counter-reset: seed; margin: 0; padding: 0 18px 8px; display: grid; gap: 2px; }
.mc-seeds li { counter-increment: seed; display: flex; justify-content: space-between; gap: 8px; font-size: 13px; padding: 3px 0; }
.mc-seeds li::before { content: counter(seed); width: 20px; color: var(--nt-muted); font-weight: 700; }
.mc-seeds li b { flex: 1; font-weight: 600; }
.mc-seeds li span { color: var(--nt-muted); font-size: 12px; }
.mc-settings { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--nt-line); }
.mc-settings > div { padding: 12px 18px 14px; min-width: 0; }
.mc-settings > div + div { border-left: 1px solid var(--nt-line); }
.mc-settings h4 { margin: 0 0 6px; font-size: 12px; font-weight: 700; color: var(--nt-muted); letter-spacing: .04em; text-transform: uppercase; }
.mc-settings dl { margin: 0; display: grid; grid-template-columns: 1fr auto; gap: 3px 12px; font-size: 13px; }
.mc-settings dt { color: var(--nt-ink-2); }
.mc-settings dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }

/* ---- the finished tournament ---- */
.mc-done { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: stretch; }
.mc-podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: end; gap: 14px; padding: 24px 24px 0; }
.mc-pod { display: grid; gap: 8px; text-align: center; min-width: 0; }
.mc-podcard { border: 1px solid var(--nt-line); border-radius: 12px; padding: 14px 10px; background: var(--nt-surface); display: grid; gap: 4px; }
.mc-medal { width: 40px; height: 40px; border-radius: 50%; margin: 0 auto; display: grid; place-items: center; font-weight: 800; color: #fff; }
.mc-g .mc-medal { background: linear-gradient(135deg, #f6d365, #c9a227); }
.mc-s .mc-medal { background: linear-gradient(135deg, #e5e7eb, #9ca3af); }
.mc-b .mc-medal { background: linear-gradient(135deg, #f0b27a, #b8732e); }
.mc-podrank { font-size: 12px; font-weight: 700; color: var(--nt-muted); text-transform: uppercase; letter-spacing: .06em; }
.mc-podname { font-size: 18px; font-weight: 800; overflow-wrap: anywhere; }
.mc-g .mc-podname { font-size: 22px; }
.mc-podblock { border-radius: 10px 10px 0 0; display: grid; place-items: center; font-size: 28px; font-weight: 800; color: rgba(255,255,255,.9); }
.mc-g .mc-podblock { height: 150px; background: linear-gradient(180deg, #e8c34a, #c9a227); }
.mc-s .mc-podblock { height: 110px; background: linear-gradient(180deg, #c7cbd2, #9ca3af); }
.mc-b .mc-podblock { height: 80px; background: linear-gradient(180deg, #d99a5c, #b8732e); }
.mc-heads { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 18px; border-top: 1px solid var(--nt-line); }
.mc-head-hl { border: 1px solid var(--nt-line); border-radius: 10px; padding: 10px 12px; display: grid; gap: 2px; }
.mc-head-hl span { font-size: 12px; color: var(--nt-muted); font-weight: 600; }
.mc-head-hl b { font-size: 22px; font-weight: 800; }
.mc-head-hl small { font-size: 13px; color: var(--nt-ink-2); }
/* the plaque under the podium: club, tournament and date, like the plate on a trophy */
.mc-podpanel { display: flex; flex-direction: column; }
.mc-plaque { margin-top: auto; display: grid; justify-items: center; gap: 2px; text-align: center; padding: 18px 20px 20px; background: #4b5563; color: #fff; border-radius: 0 0 11px 11px; }
.mc-plaque-club { font-family: 'Insignia', var(--nt-sans); font-size: 30px; line-height: 1.15; }
.mc-plaque b { font-size: 20px; font-weight: 700; letter-spacing: -.01em; }
.mc-plaque time { font-size: 14px; font-weight: 600; color: #d1d5db; font-variant-numeric: tabular-nums; }
/* each highlight draws its own right edge; the list clips the last column's */
/* awards: one per row, so however many there are tonight there is never a gap */
.mc-aws { border-top: 1px solid var(--nt-line); }
.mc-aw { display: grid; grid-template-columns: 140px max-content minmax(0, 1fr); align-items: baseline; gap: 12px; padding: 9px 18px; border-bottom: 1px solid var(--nt-line); }
.mc-aw span { font-size: 13px; font-weight: 600; color: var(--nt-muted); }
.mc-aw b { font-size: 16px; font-weight: 800; }
.mc-aw small { font-size: 13px; color: var(--nt-ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mc-aw.mc-place b { font-size: 15px; font-weight: 700; } /* 4th, 5th–6th, 7th–8th: the places after the podium */
.mc-factshead { margin: 0; padding: 14px 18px 4px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--nt-muted); }
.mc-facts { display: grid; grid-template-columns: 1fr 1fr; margin: 0; }
.mc-facts > div { padding: 10px 18px; border-bottom: 1px solid var(--nt-line); }
.mc-facts dt { font-size: 12px; color: var(--nt-muted); }
.mc-facts dd { margin: 0; font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; }
/* the actions sit centred at the foot of the Highlights panel, level with the plaque opposite */
.mc-hlpanel { display: flex; flex-direction: column; }
.mc-doneacts { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: auto; padding: 16px 18px 20px; }

@media (max-width: 1200px) {
  .mc-body, .mc-done { grid-template-columns: minmax(0, 1fr); }
  .mc-qcols { grid-template-columns: 1fr; }
  .mc-qcol + .mc-qcol { border-left: 0; border-top: 1px solid var(--nt-line); }
  .mc-settings { grid-template-columns: 1fr; }
  .mc-settings > div + div { border-left: 0; border-top: 1px solid var(--nt-line); }
}
@media (prefers-reduced-motion: reduce) { .mc-btn.mc-result, .mc-flash { animation: none; } }

/* ---- groups and cups (Docs/GROUPS-AND-CUPS.md) ---- */
/* the group tables in the right column */
.mc-gts { display: grid; gap: 12px; padding: 0 18px 14px; }
.mc-gt h4 { margin: 0 0 4px; font-size: 12px; font-weight: 700; color: var(--nt-muted); letter-spacing: .04em; text-transform: uppercase; display: flex; justify-content: space-between; }
.mc-gt h4 small { font-weight: 500; letter-spacing: 0; text-transform: none; }
.mc-gt ol { list-style: none; counter-reset: gt; margin: 0; padding: 0; display: grid; gap: 1px; }
.mc-gt li { counter-increment: gt; display: flex; align-items: center; gap: 6px; font-size: 13px; padding: 2px 0 2px 8px; box-shadow: inset 3px 0 0 var(--nt-card-line); }
.mc-gt li.mc-toa { box-shadow: inset 3px 0 0 var(--nt-ok); }
.mc-gt li::before { content: counter(gt); width: 14px; color: var(--nt-muted); font-weight: 700; font-size: 12px; }
.mc-gt li b { flex: 1; font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-gt li i { font-style: normal; font-size: 10px; font-weight: 700; text-transform: uppercase; color: var(--nt-warn); background: var(--nt-warn-soft); border-radius: 4px; padding: 0 4px; }
.mc-gt li span { color: var(--nt-muted); font-size: 12px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mc-gup { border: 1px solid var(--nt-line-2); background: var(--nt-surface); border-radius: 5px; font-size: 10px; line-height: 1; padding: 3px 5px; cursor: pointer; color: var(--nt-ink-2); }
.mc-gup:hover { border-color: var(--nt-ink); }
/* Draw the cups: both seeded fields, then the switch and the button (framed: the one thing to do) */
.mc-drawcups { border-color: var(--nt-card-line); box-shadow: 0 0 0 1px var(--nt-card-line); }
.mc-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding: 0 18px 12px; }
.mc-field h4 { margin: 0 0 6px; font-size: 13px; font-weight: 700; display: flex; justify-content: space-between; align-items: baseline; }
.mc-field h4 small { font-weight: 500; color: var(--nt-muted); font-size: 12px; }
.mc-field ol { margin: 0; padding: 0 0 0 22px; display: grid; gap: 3px; font-size: 13px; }
.mc-field li b { font-weight: 600; }
.mc-field li span { color: var(--nt-muted); font-size: 12px; margin-left: 6px; }
.mc-off-field { opacity: .5; }
.mc-drawbar { display: flex; justify-content: space-between; align-items: center; gap: 12px 20px; flex-wrap: wrap; padding: 14px 18px 16px; border-top: 1px solid var(--nt-line); }
.mc-drawbar p { margin: 0; flex: 1; min-width: 240px; color: var(--nt-ink-2); font-size: 14px; }
.mc-btn.mc-big { height: 40px; padding: 0 18px; font-size: 15px; }
/* Play the B cup: the switch from Global Settings (as in the mockup) */
.mc-switchrow { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; color: var(--nt-ink-2); cursor: pointer; }
.mc-switchrow small { color: var(--nt-muted); }
.mc-fmt .mc-plate { font-size: 14px; margin: 0 0 4px; } /* Play a Plate on single elimination's card */
.mc-plate-t { display: grid; line-height: 1.3; }
.mc-plate-t small { font-size: 12px; }
.mc-switch { position: relative; display: inline-block; width: 42px; height: 24px; flex: none; }
.mc-switch input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.mc-switch input:disabled { cursor: not-allowed; }
.mc-switch span { position: absolute; inset: 0; border-radius: 99px; background: var(--nt-line-2); transition: background .15s; }
.mc-switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(17,24,39,.25); transition: transform .15s; }
.mc-switch input:checked + span { background: var(--nt-header); }
.mc-switch input:checked + span::after { transform: translateX(18px); }
.mc-switch input:focus-visible + span { outline: 2px solid var(--nt-accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .mc-switch span, .mc-switch span::after { transition: none; } }
