/* ScrimMate v0.20 — scrim templates, organizer ban list, safe admin data edits. */

.v20-muted { color: var(--on-surface-variant); }

/* Scrim templates (Create wizard) */
.v20-tpl { display: grid; gap: 8px; margin: 0 0 14px; padding: 12px; border-radius: 18px; border: 1px dashed color-mix(in srgb, var(--primary) 40%, var(--outline-variant)); background: color-mix(in srgb, var(--primary) 6%, var(--surface-container-low)); animation: v20-rise .22s ease both; }
.v20-tpl__head { display: grid; gap: 2px; }
.v20-tpl__head b { font-size: 14px; }
.v20-tpl__head small { color: var(--on-surface-variant); font-size: 12px; }
.v20-tpl__list { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; scroll-snap-type: x proximity; scrollbar-width: none; overscroll-behavior-x: contain; }
.v20-tpl__list::-webkit-scrollbar { display: none; }
.v20-tpl__item { flex: 0 0 auto; display: grid; gap: 2px; text-align: left; max-width: 190px; min-height: 48px; padding: 8px 12px; border-radius: 14px; border: 1px solid var(--outline-variant); background: var(--surface-container); color: var(--on-surface); font: inherit; cursor: pointer; scroll-snap-align: start; transition: border-color .15s ease, background .15s ease, transform .12s ease; }
.v20-tpl__item b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.v20-tpl__item small { font-size: 11.5px; color: var(--on-surface-variant); white-space: nowrap; }
.v20-tpl__item:active { transform: scale(.97); }
.v20-tpl__item.is-on { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 16%, var(--surface-container)); }
.v20-tpl__item[aria-busy="true"] { opacity: .7; }
.v20-tpl__skel { flex: 0 0 140px; height: 48px; border-radius: 14px; background: linear-gradient(90deg, var(--surface-container) 0%, var(--surface-container-high, var(--surface-container)) 50%, var(--surface-container) 100%); background-size: 200% 100%; animation: v20-shimmer 1.2s linear infinite; }

/* Ban list */
.v20-ban-btn { color: var(--error) !important; }
.v20-bans .v18-row__main small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v20-scope { display: grid; gap: 8px; border: 0; padding: 0; margin: 10px 0; }
.v20-scope legend { font-weight: 750; font-size: 13px; margin-bottom: 6px; }
.v20-radio { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: center; padding: 10px 12px; border-radius: 14px; border: 1px solid var(--outline-variant); background: var(--surface-container-low); cursor: pointer; transition: border-color .15s ease, background .15s ease; }
.v20-radio input { accent-color: var(--error); width: 18px; height: 18px; margin: 0; }
.v20-radio span { display: grid; gap: 2px; min-width: 0; }
.v20-radio small { color: var(--on-surface-variant); font-size: 12px; }
.v20-radio:has(input:checked) { border-color: color-mix(in srgb, var(--error) 60%, var(--outline-variant)); background: color-mix(in srgb, var(--error) 9%, var(--surface-container-low)); }

/* Admin safe data edits */
.v20-edit-form { display: grid; gap: 4px; }
.v20-edit-form code { font-size: 11.5px; word-break: break-all; }
.v20-edit-form textarea { resize: vertical; min-height: 72px; }
.v20-edit-form [data-old] { overflow-wrap: anywhere; max-height: 5.5em; overflow: hidden; }
.sm-adm-row .sm-adm-mini + .sm-adm-mini { margin-left: 6px; }

@keyframes v20-rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes v20-shimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .v20-tpl, .v20-tpl__skel { animation: none; } }

/* Org share invite button icon */
.sm-invite-share-btn { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.sm-invite-share-btn svg { width: 18px; height: 18px; flex: 0 0 18px; fill: currentColor; }

/* Admin OCR Inspector: test flows + "What users see" */
.sm-ocrlab__label { margin: 10px 0 6px; font-weight: 700; color: var(--on-surface-variant); font-size: 12px; letter-spacing: .04em; text-transform: uppercase; }
.sm-ocrlab__hint { margin: 6px 0 0; color: var(--on-surface-variant); }
.sm-ocrlab__seg + .sm-ocrlab__seg { margin-top: 8px; }
.sm-ocrlab__table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid var(--outline-variant); }
.sm-ocrlab__table { width: 100%; border-collapse: collapse; font-size: 13px; }
.sm-ocrlab__table th, .sm-ocrlab__table td { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--outline-variant); white-space: nowrap; }
.sm-ocrlab__table td:nth-child(2) { white-space: normal; overflow-wrap: anywhere; min-width: 110px; }
.sm-ocrlab__table th { font-size: 11.5px; color: var(--on-surface-variant); font-weight: 700; }
.sm-ocrlab__table tr:last-child td { border-bottom: 0; }
.sm-ocrlab__seg--grid { display: grid !important; grid-template-columns: 1fr 1.4fr .8fr; width: 100%; }
.sm-ocrlab__seg--grid > button { min-width: 0; padding-inline: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; justify-content: center; }

/* Styled screenshot picker (Review match results) */
.v20-file { position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 12px; align-items: center; margin-top: 10px; padding: 12px; min-height: 64px; border-radius: 16px; border: 1px dashed color-mix(in srgb, var(--primary) 45%, var(--outline-variant)); background: color-mix(in srgb, var(--primary) 6%, var(--surface-container-low)); cursor: pointer; transition: border-color .15s ease, background .15s ease, transform .12s ease; }
.v20-file:active { transform: scale(.99); }
.v20-file input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.v20-file.is-disabled { opacity: .6; pointer-events: none; }
.v20-file__icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--primary) 16%, transparent); color: var(--primary); }
.v20-file__icon svg { width: 22px; height: 22px; fill: currentColor; }
.v20-file__text { display: grid; gap: 2px; min-width: 0; }
.v20-file__text b { font-size: 14px; }
.v20-file__text small { color: var(--on-surface-variant); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sm-team-card .sm-card-actions .btn { overflow: hidden; text-overflow: ellipsis; }

/* v0.21 — themed file button inside the player scan box */
.upload input[type=file]::file-selector-button { margin-right: 10px; padding: 7px 14px; border: 1px solid color-mix(in srgb, var(--primary) 60%, transparent); border-radius: 999px; background: color-mix(in srgb, var(--primary) 16%, transparent); color: var(--primary); font: inherit; font-weight: 600; cursor: pointer; }

/* v0.22 — practice event standings (features/matches/event-standings.js) */
.v22-es__stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.v22-es__stats > div { display: grid; gap: 2px; padding: 12px; border-radius: 14px; background: var(--surface-container, rgb(255 255 255 / .04)); border: 1px solid var(--outline-variant, rgb(255 255 255 / .08)); min-width: 0; }
.v22-es__stats b { font-size: 1.05rem; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v22-es__stats small { font-size: 11.5px; color: var(--on-surface-variant); text-transform: uppercase; letter-spacing: .04em; }
.v22-es__switch { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; flex-wrap: nowrap; }
.v22-es__switch::-webkit-scrollbar { display: none; }
.v22-es__opt { flex: 0 0 auto; }
.v22-es__opt span { display: grid; gap: 1px; line-height: 1.15; }
.v22-es__opt small { font-size: 11px; font-weight: 600; opacity: .72; }
.v22-es__kills { font-size: 1.1rem; color: var(--primary); white-space: nowrap; }
.v22-es__kills small { font-size: 12px; color: var(--on-surface-variant); font-weight: 600; }
.v22-es__note { color: var(--on-surface-variant); margin: 0; }
.v22-es__pending { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.sm-match-detail__standings { margin-top: 8px; }
.sm-match-detail__standings { display: inline-flex; align-items: center; gap: 6px; color: var(--primary); border-color: color-mix(in srgb, var(--primary) 45%, transparent); }
.sm-match-detail__standings svg { width: 18px; height: 18px; }
/* Leaderboards (public scrims + practice events): full team names on small phones */
.v18-lb__team strong { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.2; overflow-wrap: anywhere; }
@media (max-width: 399px) {
  .v18-lb__head, .v18-lb__row { grid-template-columns: 28px minmax(0, 1fr) 36px 40px 44px; gap: 6px; padding: 10px; }
  .v22-es .v18-section { padding: 12px; }
  .v18-lb__head { font-size: 9.5px; letter-spacing: .02em; }
}

/* ---- v0.23: outline icons + multi-screenshot evidence ---- */
.icon--stroke, .sm-app-shell__icon svg.icon--stroke, svg.icon--stroke { fill: none !important; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon--stroke path { fill: none !important; }
.sm-app-shell__icon svg.icon--stroke { width: 22px !important; height: 22px !important; stroke-width: 1.9; }
.v23-file { margin-top: 12px; }
.v23-evidence > h2 { margin-bottom: 2px; }
.v23-progress { margin-top: 12px; }
.v23-progress .sm-progress-fill { transition: width .35s ease; }
.v23-resume { margin-top: 10px; width: 100%; }
.v23-grid { list-style: none; margin: 12px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 560px) { .v23-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.v23-page { border-radius: 14px; overflow: hidden; border: 1px solid var(--outline-variant); background: var(--surface-container-low); display: flex; flex-direction: column; animation: v23-in .22s ease both; transition: border-color .2s ease, box-shadow .2s ease; }
.v23-page.is-reading { border-color: color-mix(in srgb, var(--primary) 70%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.v23-page.is-unknown, .v23-page.is-error { border-color: color-mix(in srgb, var(--error) 65%, transparent); }
@keyframes v23-in { from { opacity: 0; transform: translateY(4px) scale(.98); } to { opacity: 1; transform: none; } }
.v23-thumb { position: relative; display: block; width: 100%; aspect-ratio: 20 / 9; padding: 0; border: 0; background: var(--surface-container); cursor: zoom-in; }
.v23-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.v23-page.is-queued .v23-thumb img { opacity: .55; }
.v23-num { position: absolute; top: 6px; left: 6px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; display: grid; place-items: center; font-size: 12px; font-weight: 800; color: #fff; background: rgba(0, 0, 0, .62); }
.v23-meta { padding: 8px; display: grid; gap: 6px; }
.v23-chip { display: inline-flex; align-items: center; gap: 6px; justify-self: start; max-width: 100%; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; color: var(--on-surface-variant); background: var(--surface-container); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.v23-chip.is-busy { color: var(--primary); background: color-mix(in srgb, var(--primary) 14%, transparent); }
.v23-chip.is-slots { color: color-mix(in srgb, #10b981 72%, var(--on-surface)); background: color-mix(in srgb, #10b981 16%, transparent); }
.v23-chip.is-ranking { color: color-mix(in srgb, #d69e2e 68%, var(--on-surface)); background: color-mix(in srgb, #f5b301 18%, transparent); }
.v23-chip.is-bad { color: var(--error); background: color-mix(in srgb, var(--error) 14%, transparent); }
.v23-spin { width: 11px; height: 11px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: v23-spin .8s linear infinite; }
@keyframes v23-spin { to { transform: rotate(360deg); } }
.v23-row { display: grid; grid-template-columns: minmax(0, 1fr) 34px; gap: 6px; align-items: center; }
.v23-kind { min-height: 34px; padding: 4px 8px; border-radius: 10px; font-size: 13px; width: 100%; }
.v23-x { width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--outline-variant); background: transparent; color: var(--on-surface-variant); font-size: 20px; line-height: 1; cursor: pointer; }
.v23-x:active { transform: scale(.94); }
.v23-err { color: var(--error); font-size: 12px; line-height: 1.35; }
.v23-summary { margin-top: 12px; display: grid; gap: 8px; }
.v23-sum { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--surface-container); font-size: 13px; }
.v23-sum span { color: var(--on-surface-variant); font-weight: 600; }
.v23-sum b { text-align: right; }
.v23-sum.is-ok { box-shadow: inset 3px 0 0 #10b981; }
.v23-sum.is-miss { box-shadow: inset 3px 0 0 var(--error); }
@media (prefers-reduced-motion: reduce) { .v23-page, .v23-spin { animation: none; } }
