/* Admin accents are scoped to their own controls. */
#mfAdminLockVisible{background:#6b234e!important;color:#fff!important;border:1px solid #a64679!important;box-shadow:0 2px 8px #6b234e20;font-weight:800}
#mfAdminLockVisible:hover{background:#852b62!important}
/* Phone header: keep the lock button inside its 54px tools column so it never overlaps the login button. */
#topAppHeader #mfMobileHeaderActions #mfAdminLockVisible{box-sizing:border-box;width:54px;min-width:0;max-width:54px;padding:3px 2px;font-size:8px;line-height:1.25;white-space:normal}
.mf-admin-metric-active{background:#11683c!important;border-color:#45c489!important}
.mf-admin-metric-banned{background:#962b3b!important;border-color:#ff8b9b!important}
.mf-admin-metric-active>div,.mf-admin-metric-banned>div{color:#fff!important}
#mainViewportContainer:has(#adminView:not(.hidden)){max-width:1800px!important;width:calc(100% - 32px)}
#adminDynamicGrid[data-workspace=split]{display:grid!important;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);gap:20px;direction:rtl}
#adminDynamicGrid[data-workspace=split]>div{min-width:0}
html[dir=ltr] #adminDynamicGrid[data-workspace=split]{direction:ltr}
#adminDynamicGrid [hidden]{display:none!important}
/* The sheet stays a table on small screens. Its own scroll area contains its width. */
#adminSubscribersList{max-width:100%;min-width:0;max-height:70dvh;overflow:auto;overscroll-behavior:contain;scrollbar-gutter:stable}
#adminSubscribersList .mf-sheet{display:table!important;width:100%;min-width:1360px;table-layout:fixed;border-collapse:separate;border-spacing:0}
#adminSubscribersList .mf-sheet thead{display:table-header-group!important;position:sticky;top:0;z-index:2}
#adminSubscribersList .mf-sheet tbody{display:table-row-group!important}
#adminSubscribersList .mf-sheet tr{display:table-row!important;border:0;border-radius:0;margin:0;padding:0}
#adminSubscribersList .mf-sheet th,#adminSubscribersList .mf-sheet td{display:table-cell!important;width:auto;min-width:0!important;padding:9px 8px;vertical-align:top;border-inline-end:1px solid var(--mf-border,#d9e5ef);border-bottom:1px solid var(--mf-border,#d9e5ef);text-align:start}
#adminSubscribersList .mf-sheet th{background:var(--mf-soft,#edf4fa);color:var(--mf-ink,#12304e);font-size:12px;padding-block:12px;white-space:nowrap}
#adminSubscribersList .mf-sheet th:nth-child(1){width:170px}
#adminSubscribersList .mf-sheet th:nth-child(2){width:175px}
#adminSubscribersList .mf-sheet th:nth-child(3){width:145px}
#adminSubscribersList .mf-sheet th:nth-child(4){width:200px}
#adminSubscribersList .mf-sheet th:nth-child(5){width:130px}
#adminSubscribersList .mf-sheet th:nth-child(6){width:180px}
#adminSubscribersList .mf-sheet th:nth-child(7){width:180px}
#adminSubscribersList .mf-sheet th:nth-child(8){width:130px}
#adminSubscribersList .mf-sheet th:nth-child(9){width:130px}
#adminSubscribersList .mf-sheet td::before{display:none!important}
#adminSubscribersList .mf-sheet tr:nth-child(even){background:var(--mf-soft,#f6f9fc)!important}
#adminSubscribersList .mf-copy-value{display:block;width:100%;max-width:100%;padding:3px 0;margin:0;border:0;background:none;color:inherit;font:inherit;font-size:12px;line-height:1.6;text-align:start;cursor:copy;overflow-wrap:anywhere;white-space:normal}
#adminSubscribersList .mf-copy-value:hover,#adminSubscribersList .mf-copy-value:focus-visible{color:var(--mf-accent,#1974c9);text-decoration:underline}
.mf-sheet-value{display:flex;align-items:start;gap:6px;min-width:0}
.mf-sheet-value details{flex:1;min-width:0}
.mf-sheet-value summary{display:block;cursor:pointer;padding:3px 0;list-style:none}
.mf-sheet-value summary::-webkit-details-marker{display:none}
.mf-sheet-value summary span{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:12px;line-height:1.6}
.mf-sheet-value summary:hover span{color:var(--mf-accent,#1974c9);text-decoration:underline}
.mf-sheet-value details[open] summary{display:none}
.mf-sheet-expanded{padding:3px 0;white-space:normal;overflow-wrap:anywhere;font-size:12px;line-height:1.6;user-select:text}
#adminSubscribersList .mf-copy{flex:none;padding:2px 5px;margin:2px 0;font-size:10px;min-width:30px}
#adminSubscribersList .mf-sheet-order{font-size:10px;color:var(--mf-muted-ink,#64748b);margin:3px 0 0}
#adminSubscribersList .mf-count-note{padding:10px;margin:0;font-size:12px;color:var(--mf-muted-ink,#64748b)}
.anki-single-num-tip,.mf-instant-tooltip{font-family:'Cairo','Tahoma',Arial,sans-serif!important;font-size:16px!important;font-weight:900!important;line-height:1.8!important;letter-spacing:0!important;background:transparent!important;border:0!important;box-shadow:none!important;text-shadow:none!important}
@media(max-width:1100px){#adminDynamicGrid[data-workspace=split]{grid-template-columns:minmax(0,1fr)}}
@media(max-width:600px){#mainViewportContainer:has(#adminView:not(.hidden)){width:calc(100% - 16px)}#adminSubscribersList{max-height:65dvh}}
#adminDynamicGrid[data-workspace=split] > :is(#adminSubsColWrap,#adminCardsColWrap){grid-column:auto!important;width:100%!important;min-width:0!important}

.mf-sheet-value details[open] summary{display:block}
.mf-sheet-value details[open] summary span{white-space:normal;overflow-wrap:anywhere}
.mf-sheet-value .mf-sheet-expanded{display:none}

/* Subscribers table: fits the page width, no inner scrollbars, every column visible without sideways scrolling. */
#adminSubscribersList{max-height:none!important;overflow:visible!important;max-width:100%;min-width:0;scrollbar-gutter:auto}
#adminSubscribersList .mf-sheet{min-width:0!important;width:100%!important;table-layout:auto!important}
#adminSubscribersList .mf-sheet th,#adminSubscribersList .mf-sheet td{padding:7px 5px!important;overflow-wrap:anywhere;word-break:break-word}
#adminSubscribersList .mf-sheet th{white-space:normal!important;font-size:11px}
#adminSubscribersList .mf-sheet th:nth-child(n){width:auto!important}
#adminSubscribersList .mf-sheet td{font-size:11px}
#adminSubscribersList .mf-sheet-value span,#adminSubscribersList .mf-copy-value{font-size:11px!important;white-space:normal!important}

/* Student details popup: still a modal popup, but large enough that its actions are visible without scrolling. */
#mfSubscriberDialog{width:min(1200px,96vw)!important;max-width:96vw!important;max-height:94dvh!important;padding:20px 24px!important;overflow:auto}
#mfSubscriberDialog .mf-dialog-body{display:grid;gap:14px}
#mfSubscriberDialog .mf-dialog-body h2{margin:4px 0 2px}
#mfSubscriberDialog .mf-detail-fields{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:10px}
#mfSubscriberDialog .mf-actions{display:flex;flex-wrap:wrap;gap:8px}
#mfSubscriberDialog .mf-dialog-body>p{margin:0}

/* Student details popup: tighter sizes so everything shows on one screen without scrolling. */
#mfSubscriberDialog{width:min(980px,94vw)!important;max-width:94vw!important;max-height:92dvh!important;padding:14px 18px!important}
#mfSubscriberDialog .mf-dialog-body{gap:8px}
#mfSubscriberDialog .mf-dialog-body h2{font-size:16px;margin:0}
#mfSubscriberDialog .mf-detail-fields{grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:6px}
#mfSubscriberDialog .mf-detail-fields>div{padding:5px 7px}
#mfSubscriberDialog .mf-detail-fields small{font-size:10px}
#mfSubscriberDialog .mf-detail-fields strong{font-size:12px}
#mfSubscriberDialog .mf-dialog-body>p{font-size:11px;line-height:1.5;margin:0}
#mfSubscriberDialog button{font-size:11px;padding:4px 8px;min-height:28px}
#mfSubscriberDialog .mf-actions{gap:5px}
#mfSubscriberDialog .mf-review-detail,#mfSubscriberDialog .mf-receipts{font-size:11px}

/* Count badges on the admin section switch: what needs a decision now. */
.mf-switch-badge{display:inline-flex;align-items:center;justify-content:center;min-width:18px;height:18px;padding:0 5px;margin-inline-start:6px;border-radius:999px;background:#dc2626;color:#fff;font-size:11px;font-weight:800;vertical-align:middle}
.mf-switch-badge[hidden]{display:none}

/* WhatsApp action in the student details popup: WhatsApp's brand green. */
#mfSubscriberDialog a.mf-whatsapp-link{background:#25D366!important;border-color:#1ebe57!important;color:#fff!important;font-weight:800}
#mfSubscriberDialog a.mf-whatsapp-link:hover{background:#1ebe57!important}
