/* kanal3 spoke — page-specific styles on top of the ported MediaForce chrome.
 * admin.css + site-themes.css own the shell (top bar, footer, cards, buttons,
 * breadcrumbs, avatar). This file only styles the streaming surfaces (hero
 * rails, player, login) and binds them to the same --mf-* tokens. */

/* Single source for the horizontal content gutter (#1115). Wide on web/TV;
 * shrunk right down in the Android app (html.mf-app) and on phones so the WebView
 * fills the screen side to side instead of wasting the sides on margins. */
html { --mfs-gutter: 44px; }
html.mf-phone { --mfs-gutter: 12px; }
html.mf-app { --mfs-gutter: 8px; }

/* Top-bar nav (sits in .admin-main-menu-widgets-left next to the brand) */
.mfs-nav { display:flex; align-items:center; gap:4px; }
.mfs-nav-item { display:inline-flex; align-items:center; padding:6px 12px; border-radius:6px;
  color:var(--mf-text-muted); font-size:14px; font-weight:600; text-decoration:none; }
.mfs-nav-item:hover { background:var(--mf-surface-2); color:var(--mf-text); }
.admin-brand span { color:var(--mf-primary); }
.mfs-brand-logo { height:30px; max-width:220px; display:block; object-fit:contain; }

/* ---- frontpage: Netflix-style rails ---- */
.mfs-empty { padding:60px 22px; color:var(--mf-text-muted); font-size:16px; }
.mfs-hero { position:relative; height:min(52vw,440px); margin:0 0 10px; display:flex; align-items:flex-end;
  text-decoration:none; color:inherit; overflow:hidden; }
.mfs-hero-vid { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; object-position:top center; background:#000; } /* theme-audit-allow: video pillarbox black — #1217 start at top, not middle */
.mfs-hero-scrim, .mfs-hero-bg::after { content:""; position:absolute; inset:0;
  background:linear-gradient(90deg,var(--mf-bg) 0%,color-mix(in srgb,var(--mf-bg) 55%,transparent) 45%,transparent 100%),
             linear-gradient(0deg,var(--mf-bg),transparent 55%); }
.mfs-hero-bg { position:absolute; inset:0; background-size:cover; background-position:center; }
.mfs-hero-inner { position:relative; padding:0 var(--mfs-gutter) 34px; max-width:640px; }
.mfs-hero-title { font-size:clamp(26px,4vw,46px); font-weight:800; margin:0 0 10px; color:var(--mf-text); }
.mfs-hero-desc { color:var(--mf-text-muted); font-size:15px; margin:0 0 16px; max-height:66px; overflow:hidden; }
/* Play button — deliberately compact (#1219, was oversized). */
.mfs-hero-play { display:inline-flex; align-items:center; gap:6px; background:var(--mf-primary); color:var(--mf-on-accent,#fff);
  font-weight:700; padding:6px 14px; border-radius:7px; font-size:13px; text-decoration:none; }
/* "New" kicker badge on a hero (#1222). */
.mfs-hero-badge { display:inline-block; align-self:flex-start; margin:0 0 8px; padding:2px 10px; border-radius:999px;
  background:var(--mf-primary); color:var(--mf-on-accent,#fff); font-size:12px; font-weight:800; letter-spacing:.06em; text-transform:uppercase; }
/* Hero style variants (#1220) — one machinery, three looks. Height is a per-style
   var so the adjacency rule below can scale it. */
/* Hero heights (#1281/#1282): a full-width 16:9 video is ~56vw tall, so a hero
   must be at least 60% of that (~34vw) — and bigger overall, the heroes were too
   short. Every style now clears the 34vw floor. */
.mfs-hero-cine { --mfsh:min(58vw,600px); height:var(--mfsh); }
.mfs-hero-spotlight { --mfsh:min(50vw,500px); height:var(--mfsh); }
.mfs-hero-spotlight .mfs-hero-scrim { background:
  linear-gradient(90deg,var(--mf-bg) 0%,color-mix(in srgb,var(--mf-bg) 30%,transparent) 60%,transparent 100%),
  linear-gradient(0deg,var(--mf-bg),transparent 45%); }
.mfs-hero-spotlight .mfs-hero-inner { max-width:520px; padding-bottom:28px; }
.mfs-hero-spotlight .mfs-hero-title { font-size:clamp(22px,3vw,38px); }
.mfs-hero-banner { --mfsh:min(40vw,380px); height:var(--mfsh); }
.mfs-hero-banner .mfs-hero-title { font-size:clamp(18px,2.2vw,28px); margin-bottom:8px; }
.mfs-hero-banner .mfs-hero-inner { padding-bottom:20px; }
/* Manager/Webmaster edit control on the hero — same ✎ chip as the tiles (#1321),
   overlaid top-right above the scrim; .mfs-thumb-ic supplies the dark rounded look. */
.mfs-hero-edit { position:absolute; top:10px; right:10px; z-index:6; }
/* Absolute floor: no hero is ever shorter than 60% of a full 16:9 video (#1281). */
.mfs-hero { min-height:34vw; }
/* Heroes are never placed back-to-back anymore (#1282) — a video row always sits
   between them — so the old adjacency up-scaling is gone. */
html.mf-phone .mfs-hero-cine { --mfsh:min(60vw,320px); }
html.mf-phone .mfs-hero-spotlight { --mfsh:min(58vw,300px); }
html.mf-phone .mfs-hero-banner { --mfsh:min(42vw,220px); }
/* Every-4th-row heroes (#1189) span the full grid width. */
.mfs-browse-grid > .mfs-rowhero { grid-column:1 / -1; }
.mfs-shelf { padding:14px 0 6px; }
.mfs-shelf-head { margin:0; padding:4px var(--mfs-gutter) 8px; font-size:17px; font-weight:700; color:var(--mf-text);
  display:flex; align-items:baseline; gap:12px; }
.mfs-shelf-head a { font-size:13px; font-weight:600; color:var(--mf-link); }
/* Rails scroll DOWN, never sideways (#1100): a wrapping grid, identical width to
   every other block on the page. One canonical video display everywhere. */
.mfs-rail { display:grid; grid-template-columns:repeat(auto-fill,minmax(230px,1fr)); gap:14px; padding:6px var(--mfs-gutter) 20px; }
/* Single-row rail (#1223) — a horizontal scroller, never wraps to a second row. */
.mfs-rail-1 { display:flex; flex-wrap:nowrap; overflow-x:auto; gap:14px; padding:6px var(--mfs-gutter) 18px; scroll-snap-type:x proximity; }
.mfs-rail-1 > * { flex:0 0 clamp(200px,42vw,250px); scroll-snap-align:start; }
html.mf-phone .mfs-rail-1 > * { flex-basis:70vw; }
/* Article cards on the frontpage (#1221). */
.mfs-artrail { display:grid; grid-template-columns:repeat(auto-fill,minmax(280px,1fr)); gap:14px; padding:6px var(--mfs-gutter) 20px; }
.mfs-artcard { display:flex; flex-direction:column; background:var(--mf-surface); border:1px solid var(--mf-border);
  border-radius:10px; overflow:hidden; text-decoration:none; color:inherit; transition:transform .12s, box-shadow .12s; }
.mfs-artcard:hover { transform:translateY(-2px); box-shadow:0 6px 16px rgba(0,0,0,.28); } /* theme-audit-allow: hover elevation shadow */
.mfs-artcard-img { aspect-ratio:16/9; background-size:cover; background-position:center; background-color:var(--mf-surface-2); }
.mfs-artcard-noimg { display:flex; align-items:center; justify-content:center; font-size:40px; }
.mfs-artcard-body { padding:11px 13px 14px; }
.mfs-artcard-kicker { display:inline-block; font-size:11px; font-weight:800; letter-spacing:.06em; text-transform:uppercase; color:var(--mf-primary); margin-bottom:5px; }
.mfs-artcard-title { font-size:16px; font-weight:700; margin:0 0 6px; color:var(--mf-text); }
.mfs-artcard-excerpt { font-size:13px; color:var(--mf-text-muted); margin:0; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
/* Country flag chips (#1225). */
.mfs-flagrow { display:flex; flex-wrap:wrap; gap:10px; padding:6px var(--mfs-gutter) 20px; }
.mfs-flagchip { display:inline-flex; align-items:center; gap:8px; padding:7px 13px; border-radius:999px;
  background:var(--mf-surface); border:1px solid var(--mf-border); text-decoration:none; color:var(--mf-text);
  transition:background-color .12s, border-color .12s; }
.mfs-flagchip:hover { background:var(--mf-primary); color:var(--mf-on-accent,#fff); border-color:var(--mf-primary); }
.mfs-flagchip:hover .mfs-flagchip-n { color:var(--mf-on-accent,#fff); }
.mfs-flagchip-flag { font-size:20px; line-height:1; }
.mfs-flagchip-name { font-size:14px; font-weight:600; }
.mfs-flagchip-n { font-size:12px; color:var(--mf-text-muted); font-weight:700; }
/* Playback settings rows (#1228). */
.mfs-pref-row { display:flex; align-items:center; justify-content:space-between; gap:16px; padding:8px 0; flex-wrap:wrap; }
.mfs-pref-label { font-size:14px; color:var(--mf-text); font-weight:600; }
.mfs-tile { width:auto; background:var(--mf-surface); border:1px solid var(--mf-border);
  border-radius:8px; overflow:hidden; transition:transform .12s, box-shadow .12s; text-decoration:none; color:inherit; }
.mfs-tile:hover { transform:translateY(-2px); box-shadow:0 6px 16px rgba(0,0,0,.28); z-index:2; } /* theme-audit-allow: hover elevation shadow */
.mfs-tile img { width:100%; aspect-ratio:16/9; object-fit:cover; background:#000; display:block; } /* theme-audit-allow: video pillarbox black */
.mfs-tile .mfs-meta { padding:9px 11px; }
.mfs-tile .mfs-name { font-size:14px; font-weight:600; color:var(--mf-text); }
.mfs-tile .mfs-dur { font-size:12px; color:var(--mf-text-muted); margin-top:2px; }

/* facet switcher + featured/rating badges (#1032/#1033/#1034) */
.mfs-facetbar { display:flex; align-items:center; gap:8px; padding:12px var(--mfs-gutter) 4px; flex-wrap:wrap; }
.mfs-facet-label { font-size:13px; color:var(--mf-text-muted); }
.mfs-facet { padding:5px 12px; border-radius:6px; font-size:13px; font-weight:600; color:var(--mf-text-muted); text-decoration:none; border:1px solid var(--mf-border); }
.mfs-facet:hover { background:var(--mf-surface-2); color:var(--mf-text); }
.mfs-facet.active { background:var(--mf-primary); color:var(--mf-on-accent,#fff); border-color:var(--mf-primary); } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */
.mfs-tile-thumb { position:relative; }
.mfs-badge-feat { position:absolute; top:6px; left:6px; z-index:2; background:var(--mf-primary); color:var(--mf-on-accent,#fff); font-size:11px; font-weight:700; padding:2px 7px; border-radius:5px; } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */
.mfs-rate { color:#f5c518; font-size:12px; letter-spacing:1px; margin-top:2px; } /* theme-audit-allow: IMDb-style gold star rating, semantic */

/* browse-all grid (frontpage "see all" / paged) */
.mfs-browse-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(220px,1fr)); gap:14px; padding:8px var(--mfs-gutter) 24px; }
.mfs-pager { display:flex; gap:10px; justify-content:center; align-items:center; padding:6px 0 30px; color:var(--mf-text-muted); }

/* ---- player ---- */
.mfs-player-wrap { max-width:1280px; margin:0 auto; padding:22px var(--mfs-gutter); }
.mfs-player-wrap video { width:100%; aspect-ratio:16/9; background:#000; border-radius:10px; } /* theme-audit-allow: video pillarbox black */
.mfs-back { display:inline-block; margin-bottom:14px; font-size:14px; color:var(--mf-text-muted); }

/* ---- login (pre-auth, no chrome) ---- */
.mfs-login { max-width:360px; margin:12vh auto 0; padding:0 22px; text-align:center; }
.mfs-login h1 { font-size:40px; font-weight:800; margin:0 0 26px; color:var(--mf-text); }
.mfs-login h1 span { color:var(--mf-primary); }
.mfs-login input { width:100%; padding:13px 14px; margin-bottom:12px; border-radius:8px;
  border:1px solid var(--mf-border); background:var(--mf-input-bg); color:var(--mf-text); font-size:15px; }
.mfs-login button { width:100%; padding:13px; border:0; border-radius:8px; background:var(--mf-primary);
  color:var(--mf-on-accent,#fff); font-size:15px; font-weight:700; cursor:pointer; }
.mfs-login .mfs-err { color:var(--mf-danger); font-size:14px; margin-bottom:12px; min-height:18px; }
/* App-download link, directly under the login form (#1071). */
.mfs-login-app-wrap { margin-top:18px; }
.mfs-login-app { display:inline-flex; align-items:center; gap:8px; padding:10px 18px; border-radius:8px;
  border:1px solid var(--mf-border); background:var(--mf-surface); color:var(--mf-text); font-size:14px;
  font-weight:600; text-decoration:none; }
.mfs-login-app:hover { border-color:var(--mf-primary); color:var(--mf-primary); }

/* ---- settings / actions cards ---- */
/* Full screen width, side to side (#1170) — no 640px cap, and lift the .admin-main
   1400px frame for the settings route so it truly goes edge to edge. */
.mfs-settings { max-width:none; margin:0; padding:8px 0 26px; }
.admin-main:has(> .mfs-settings), .admin-main:has(.mfs-settings) { max-width:none; }
/* The cards themselves flow in a responsive multi-column grid so the width is used. */
/* Masonry columns (#1177): cards pack tight top-to-bottom with no grid-row empty
   space, so uneven card heights (tall Theme/Actions vs short Language) don't leave
   big gaps. Reorganized, denser cards. */
.mfs-settings-grid { column-width:340px; column-gap:16px; }
.mfs-settings-grid > .mfs-card-box { break-inside:avoid; margin:0 0 16px; display:inline-block; width:100%; }
.mfs-settings .mfs-card-box { padding:14px 16px; margin-bottom:0; }
.mfs-settings .mfs-card-box h2 { margin:0 0 10px; font-size:16px; }
.mfs-settings h1 { margin:0 0 14px; }
/* Light / Dark / Follow-OS segmented toggle (#1188). */
.mfs-mode-toggle { display:inline-flex; margin:0 0 14px; border:1px solid var(--mf-border); border-radius:8px; overflow:hidden; }
.mfs-mode-btn { border:0; border-right:1px solid var(--mf-border); background:var(--mf-surface); color:var(--mf-text-muted); font:inherit; font-size:13px; padding:7px 14px; cursor:pointer; }
.mfs-mode-btn:last-child { border-right:0; }
.mfs-mode-btn.on { background:var(--mf-primary); color:var(--mf-on-accent,#fff); } /* theme-audit-allow: documented var() fallback */
.mfs-settings h1 { font-size:24px; margin:0 0 18px; color:var(--mf-text); }
.mfs-card-box { background:var(--mf-surface); border:1px solid var(--mf-border); border-radius:12px; padding:18px 20px; margin-bottom:16px; }
.mfs-card-box h2 { font-size:15px; margin:0 0 12px; color:var(--mf-text-muted); font-weight:600; }
.mfs-langopts { display:flex; gap:10px; }
.mfs-langopts button { flex:1; padding:11px; border-radius:8px; border:1px solid var(--mf-border);
  background:var(--mf-input-bg); color:var(--mf-text); font:inherit; font-weight:600; cursor:pointer; }
.mfs-langopts button.active { background:var(--mf-primary); color:var(--mf-on-accent,#fff); border-color:var(--mf-primary); }

/* lean buttons + inputs reused on spoke pages (match admin.css .btn language) */
.mfs-btn { display:inline-flex; align-items:center; gap:6px; padding:6px 12px; border-radius:6px;
  border:1px solid var(--mf-border); background:var(--mf-surface-2); color:var(--mf-text);
  font:inherit; font-size:13px; font-weight:600; line-height:1.4; cursor:pointer; text-decoration:none; }
.mfs-btn:hover { background:var(--mf-surface-alt); }
.mfs-btn.pri { background:var(--mf-primary); border-color:var(--mf-primary); color:var(--mf-on-accent,#fff); }
.mfs-btn.pri:hover { background:var(--mf-primary-hover); border-color:var(--mf-primary-hover); }
.mfs-btn-danger { background:var(--mf-danger,#c0392b); border-color:var(--mf-danger,#c0392b); color:#fff; } /* theme-audit-allow */
.mfs-btn-danger:hover { filter:brightness(1.1); }
.mfs-actor-deleterow { margin-top:14px; padding-top:12px; border-top:1px solid var(--mf-border); }
.mfs-btn.danger { color:var(--mf-danger); border-color:var(--mf-border); background:transparent; }
.mfs-input { padding:8px 11px; border-radius:6px; border:1px solid var(--mf-border);
  background:var(--mf-input-bg); color:var(--mf-text); font:inherit; font-size:14px; }

/* app download link in the footer bottom line (#1042). Uses --mf-on-accent
 * (constant #fff) not --mf-on-primary — the latter is derived via oklch(from …)
 * which resolves to the primary colour in some browsers → invisible text (#1044). */
.admin-footer-app { display:inline-flex; align-items:center; gap:6px; padding:5px 12px; border-radius:6px;
  background:var(--mf-primary); color:var(--mf-on-accent,#fff) !important; font-weight:700; font-size:13px; text-decoration:none; white-space:nowrap; } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */
.admin-footer-app:hover { background:var(--mf-primary-hover); }

/* App WebView (older chromium) can't resolve admin.css's oklch-derived
 * --mf-on-primary, so primary buttons render text the same colour as the fill
 * (invisible "Play"/"Browse all" in the app). Force the constant white on every
 * primary fill (#1051). */
.btn-primary, .mfs-hero-play, .mfs-btn.pri { color:var(--mf-on-accent,#fff) !important; } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */

/* ── YouTube-style viewing page (#1055) ─────────────────────────────── */
.mfs-watch { max-width:1400px; margin:0 auto; padding:16px 0 30px; }
.mfs-watch-stage { padding:0 var(--mfs-gutter); }
.mfs-watch-stage video { width:100%; max-height:78vh; aspect-ratio:16/9; background:#000; border-radius:12px; } /* theme-audit-allow: video pillarbox black */
.mfs-watch-bar { display:flex; align-items:center; gap:14px; padding:14px var(--mfs-gutter) 4px; flex-wrap:wrap; }
.mfs-watch-title { margin:0; font-size:22px; font-weight:700; color:var(--mf-text); flex:1; min-width:200px; }
.mfs-watchnav { display:flex; gap:8px; }
.mfs-watchnav-a { padding:8px 16px; border-radius:22px; font-size:14px; font-weight:600; text-decoration:none;
    background:var(--mf-primary); color:var(--mf-on-accent,#fff); } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */
.mfs-watchnav-a:hover { background:var(--mf-primary-hover); }
.mfs-watchnav-x { padding:8px 16px; border-radius:22px; font-size:14px; color:var(--mf-text-faint); border:1px solid var(--mf-border); }
.mfs-watch-chips { display:flex; flex-wrap:wrap; gap:8px; padding:6px var(--mfs-gutter) 4px; }
.mfs-chip { padding:5px 13px; border-radius:16px; font-size:13px; font-weight:600; text-decoration:none;
    background:var(--mf-surface-alt); color:var(--mf-text); border:1px solid var(--mf-border); }
.mfs-chip:hover { background:var(--mf-primary); color:var(--mf-on-accent,#fff); border-color:var(--mf-primary); } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */
html.mf-desktop .admin-main .mfs-watch { max-width:1400px; }

/* watch-page edit button + tag chips (#1058) */
.mfs-editbtn { padding:6px 14px; border-radius:22px; font-size:13px; font-weight:600; text-decoration:none;
    background:var(--mf-surface-alt); color:var(--mf-text); border:1px solid var(--mf-border); }
.mfs-editbtn:hover { background:var(--mf-primary); color:var(--mf-on-accent,#fff); border-color:var(--mf-primary); } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */

/* ── Articles (#1065) ─────────────────────────────────────────────── */
.mfs-fl { display:block; font-size:12px; font-weight:600; color:var(--mf-text-muted); text-transform:uppercase; letter-spacing:.04em; margin:14px 0 4px; }
.mfs-article-body { font-size:17px; line-height:1.7; color:var(--mf-text); }
.mfs-article-body h2 { font-size:24px; margin:26px 0 10px; }
.mfs-article-body h3 { font-size:20px; margin:22px 0 8px; }
.mfs-article-body p { margin:0 0 16px; }
.mfs-article-body img { max-width:100%; height:auto; border-radius:8px; }
.mfs-article-body a { color:var(--mf-link); }
.mfs-article-body ul, .mfs-article-body ol { margin:0 0 16px 22px; }
.mfs-article-body blockquote { margin:0 0 16px; padding:6px 16px; border-left:3px solid var(--mf-primary); color:var(--mf-text-muted); }
.mfs-article-body code { font-family:ui-monospace,monospace; background:var(--mf-surface-2,#222); padding:1px 5px; border-radius:4px; font-size:.9em; } /* theme-audit-allow: #222 is the documented var() fallback */
/* pre-login brand logo (#1067) */
.mfs-login-logo { max-width:min(280px,70vw); max-height:120px; margin:0 auto 22px; display:block; }

/* ── D-pad focus marker (#1071/#1161/#1244) ─────────────────────────── */
/* The D-pad nav marks the current element with .mfs-tvfocus (it does NOT rely on the
   WebView's :focus, which is unreliable). A marker MUST stay — the remote has to show
   which item is current — but the treatment differs per device.
   NOTE: a Google-TV app has BOTH mf-tv AND mf-app on <html>, so the bold phone-app
   style below is gated with :not(.mf-tv) to keep it OFF the TV. */
/* Phone app: bold ring + a small tile pop, unchanged. */
html.mf-app:not(.mf-tv) :focus, html.mf-app:not(.mf-tv) .mfs-tvfocus { outline: 4px solid var(--mf-primary, #6c8cff) !important; outline-offset: 3px; border-radius: 6px; }
html.mf-app:not(.mf-tv) .mfs-tile, html.mf-app:not(.mf-tv) .mf-media-tile { transition: transform .12s ease; }
html.mf-app:not(.mf-tv) .mfs-tile.mfs-tvfocus, html.mf-app:not(.mf-tv) .mf-media-tile.mfs-tvfocus,
html.mf-app:not(.mf-tv) .mfs-tile:focus, html.mf-app:not(.mf-tv) .mf-media-tile:focus { transform: scale(1.08); z-index: 20; box-shadow: 0 10px 34px rgba(0,0,0,.6); } /* theme-audit-allow: focus elevation shadow */
/* Google TV: CLEAN flat marker (#1244). Janus found the 4px glow + scale(1.08)
   reflow clumsy on a 10-foot screen — no scale, no shadow, no big offset, just a
   crisp 2px border so the current item is obvious without the jump. */
html.mf-tv :focus, html.mf-tv .mfs-tvfocus { outline: 2px solid var(--mf-primary, #6c8cff) !important; outline-offset: 1px; border-radius: 4px; }
html.mf-tv .mfs-tile.mfs-tvfocus, html.mf-tv .mf-media-tile.mfs-tvfocus,
html.mf-tv .mfs-tile:focus, html.mf-tv .mf-media-tile:focus { transform: none; box-shadow: none; } /* theme-audit-allow: focus elevation shadow */
/* On TV the top menu must NOT dominate — smaller, and it does not trap focus. */
html.mf-tv .admin-main-menu { position: static; }
html.mf-tv .mfs-watch-stage video, html.mf-tv .mfs-player-wrap video { max-height: 100vh; }
/* No sidebar on TV anymore (#1161): the clumsy left menu that trapped the D-pad is
   gone — TV uses the same standard top-nav chrome as desktop. Full-width content, no
   84px gutter; the footer stays hidden (unreachable on a 10-foot remote). */
html.mf-tv .admin-footer { display: none !important; }
html.mf-tv .admin-main { max-width: none; padding: 20px var(--mfs-gutter); }
/* The top nav is hidden on TV now (#1241, see below); the avatar "scroll-down"
   menu carries every destination, so there is no remote-nav bar to size here. */

/* ── Front-page search bar (#1075) ──────────────────────────────────── */
/* Tight above, a little air below so the bar isn't crammed against the hero (#1064). */
/* Persistent search on the breadcrumb line (#1140). */
.mfs-crumb-search { margin-left: auto; display: flex; }
.mfs-crumb-search input { width: 200px; max-width: 42vw; padding: 6px 12px; font-size: 14px; border-radius: 20px;
  border: 1px solid var(--mf-border); background: var(--mf-input-bg, var(--mf-surface)); color: var(--mf-text); }
.mfs-crumb-search input:focus { outline: 2px solid var(--mf-primary); border-color: var(--mf-primary); }
.breadcrumbs .mfs-tsctl, .breadcrumbs .breadcrumb-device { margin-left: 10px; }
/* Home filter/sort row (search moved to the breadcrumb). */
.mfs-facetrow { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.mfs-searchwrap { padding: 6px var(--mfs-gutter) 14px; }
.mfs-search { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.mfs-search-input { flex: 1; min-width: 220px; padding: 11px 16px; font-size: 16px; border-radius: 24px;
    border: 1px solid var(--mf-border); background: var(--mf-input-bg, var(--mf-surface)); color: var(--mf-text); }
.mfs-search-input:focus { outline: 3px solid var(--mf-primary); border-color: var(--mf-primary); }
.mfs-search-sel { padding: 10px 12px; font-size: 14px; border-radius: 8px; border: 1px solid var(--mf-border);
    background: var(--mf-input-bg, var(--mf-surface)); color: var(--mf-text); }
/* No search field on Google TV (#1243): typing a query with a D-pad is misery, so
   the breadcrumb search AND the frontpage search bar are both dropped on TV. Search
   stays on desktop/pad/phone, where there's a real keyboard/touch. */
html.mf-tv .mfs-crumb-search, html.mf-tv .mfs-searchwrap { display: none; }

/* Collapsing search (#1116): on phone/app the search bar is hidden behind a small
   icon and only expands when tapped, so it stops eating half the screen. On web/TV
   the icon is hidden and the full bar shows inline as before. */
.mfs-search-toggle { display: none; align-items: center; justify-content: center;
    width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--mf-border);
    background: var(--mf-surface-2); color: var(--mf-text); font-size: 18px; cursor: pointer; }
.mfs-search-toggle:hover { background: var(--mf-surface-alt); }
html.mf-phone .mfs-search-toggle, html.mf-app .mfs-search-toggle { display: inline-flex; }
html.mf-phone .mfs-searchwrap .mfs-search, html.mf-app .mfs-searchwrap .mfs-search { display: none; }
html.mf-phone .mfs-searchwrap.mfs-search-open .mfs-search,
html.mf-app .mfs-searchwrap.mfs-search-open .mfs-search { display: flex; margin-top: 10px; }
html.mf-phone .mfs-searchwrap.mfs-search-open .mfs-search-toggle,
html.mf-app .mfs-searchwrap.mfs-search-open .mfs-search-toggle { background: var(--mf-primary); color: var(--mf-on-accent, #fff); } /* theme-audit-allow: documented var() fallback */

/* resume progress bar on tiles (#1079) */
.mfs-tile-thumb { position: relative; }
.mfs-tile-prog { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: rgba(0,0,0,.55); z-index: 3; } /* theme-audit-allow: scrim under progress bar */
.mfs-tile-prog i { display: block; height: 100%; background: var(--mf-primary); }

/* Resolution badge (2K/4K/8K) top-right of the thumb (#1066). */
.mfs-badge-res { position: absolute; top: 6px; right: 6px; z-index: 2;
    font-size: 11px; font-weight: 800; letter-spacing: .5px; padding: 2px 7px; border-radius: 5px;
    background: rgba(0,0,0,.72); color: #fff; } /* theme-audit-allow: fixed dark scrim badge over video still */
/* Per-tier quality colours so the resolution reads at a glance (#1146). */
.mfs-badge-res.mfs-res-12k { background: #7c3aed; } /* theme-audit-allow: semantic quality tier */
.mfs-badge-res.mfs-res-8k  { background: #c026d3; } /* theme-audit-allow: semantic quality tier */
.mfs-badge-res.mfs-res-4k  { background: #dc2626; } /* theme-audit-allow: semantic quality tier */
.mfs-badge-res.mfs-res-2k  { background: #ea580c; } /* theme-audit-allow: semantic quality tier */
.mfs-badge-res.mfs-res-1k  { background: #0891b2; } /* theme-audit-allow: semantic quality tier */
.mfs-badge-res.mfs-res-sd  { background: rgba(0,0,0,.6); color: #cbd5e1; } /* theme-audit-allow: semantic quality tier */

/* Watched badge (#1078) — bottom-left, the user has finished this video. */
.mfs-badge-watched { position:absolute; bottom:6px; left:6px; z-index:2; display:inline-flex; align-items:center; gap:3px;
  font-size:10px; font-weight:800; letter-spacing:.4px; padding:2px 7px; border-radius:5px;
  background:rgba(0,0,0,.72); color:#fff; } /* theme-audit-allow: fixed dark scrim badge over video still */

/* Hover preview video (#1073) — fills the thumb over the poster. */
.mfs-tile-thumb video.mfs-prev { position: absolute; inset: 0; width: 100%; height: 100%;
    object-fit: cover; background: #000; z-index: 1; } /* theme-audit-allow: video pillarbox black */

/* Film-roll icon on the thumb → jumps to the film roll (#1068). */
.mfs-tile-roll { position: absolute; bottom: 6px; right: 6px; z-index: 4; width: 30px; height: 30px; border-radius: 7px;
    display: flex; align-items: center; justify-content: center; font-size: 16px; cursor: pointer;
    background: rgba(0,0,0,.62); color: #fff; opacity: .9; transition: background .12s, transform .12s; } /* theme-audit-allow: control scrim over video still */
.mfs-tile-roll:hover, .mfs-tile-roll:focus { background: var(--mf-primary); opacity: 1; transform: scale(1.08); outline: none; }

/* Device pill on the breadcrumb row (#1069) — copied from the master admin.css
 * .breadcrumb-device design. Kept visible on every form factor (incl. phone) so
 * the user can always confirm which device the system detected. */
.breadcrumbs { display: flex; align-items: center; gap: 10px; }
.breadcrumb-device {
    margin-left: auto;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 11px; color: var(--mf-text-faint);
    white-space: nowrap; /* theme-audit-allow: 'white' here is white-space, not a colour */
    padding: 1px 6px; border: 1px solid var(--mf-border); border-radius: 3px;
    line-height: 1.5; letter-spacing: 0.02em; }

/* TWO-ROW breadcrumb bar site-wide (#1173): row 1 = identity (trail + access + device),
   row 2 = tools (search + thumbnail size). Auto-height — the bar is exactly as tall
   as its content (#1280): a single-row page (most pages) stays compact like /media,
   which only looks taller because it genuinely carries a toolbar row (and a search
   row). The old min-height:60px reserved two rows' worth on every page. */
.breadcrumbs.breadcrumbs-2row { height: auto; min-height: 34px; flex-direction: column;
    align-items: stretch; gap: 2px; padding: 5px var(--mfs-gutter); overflow: visible; justify-content: flex-start; }
.breadcrumbs-2row .breadcrumb-row { display: flex; align-items: center; gap: 10px; min-height: 27px; flex-wrap: wrap; }
.breadcrumbs-2row .breadcrumb-row-2 { border-top: 1px solid var(--mf-border); padding-top: 3px; }
/* Optional 3rd breadcrumb line (#1266) — hosts the media archive's own search bar
   on its own row, below the identity + tools rows. */
.breadcrumbs-2row .breadcrumb-row-3 { border-top: 1px solid var(--mf-border); padding-top: 3px; }
.breadcrumb-row-3 .mf-media-search { flex: 1 1 auto; max-width: none; margin: 0; }
.breadcrumb-row-3 .mf-media-search input { width: 100%; }
.breadcrumbs-2row .breadcrumb-trail { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.breadcrumb-access { font-size: 11px; font-weight: 700; padding: 1px 9px; border-radius: 10px; white-space: nowrap; /* theme-audit-allow: 'white' here is white-space, not a colour */
    background: var(--mf-accent-soft, rgba(108,60,255,.14)); color: var(--mf-accent, #6c3cff); }
/* Row 1: trail takes the space; search + thumbnail-size + access + device group at the
   right END (search+size come BEFORE the access pill). Same on every page. */
.breadcrumbs-2row .breadcrumb-row-1 .breadcrumb-trail { flex: 1 1 auto; }
.breadcrumbs-2row .breadcrumb-row-1 .mfs-crumb-search { margin-left: 0; }
.breadcrumbs-2row .breadcrumb-row-1 .mfs-crumb-search input { width: 160px; max-width: 34vw; }
.breadcrumbs-2row .breadcrumb-row-1 .mfs-tsctl,
.breadcrumbs-2row .breadcrumb-row-1 .breadcrumb-access,
.breadcrumbs-2row .breadcrumb-row-1 .breadcrumb-device { margin-left: 0; }
/* Page controls hosted on breadcrumb row 2 (#1174/#1176) — compact + inline. */
.breadcrumbs-2row .breadcrumb-row-2 .mfs-facetrow,
.breadcrumbs-2row .breadcrumb-row-2 .mf-media-toolbar {
    display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0; padding: 0; background: none; border: 0; }
.breadcrumbs-2row .breadcrumb-row-2 select,
.breadcrumbs-2row .breadcrumb-row-2 .mfs-facetrow input { font-size: 12px; padding: 3px 8px; height: auto; }
.mfs-crumb-home { font-size: 12px; font-weight: 600; text-decoration: none; color: var(--mf-text);
    padding: 2px 9px; border-radius: 9px; background: var(--mf-surface-2, #222); white-space: nowrap; } /* theme-audit-allow: 'white' here is white-space, not a colour */
.mfs-crumb-home:hover { background: var(--mf-primary); color: var(--mf-on-accent, #fff); } /* theme-audit-allow: documented var() fallback */
/* Back link pinned to the FRONT of the breadcrumb's identity line (#1277) — one
   line, replacing the old lone second row. Styled like .mfs-crumb-home. */
.mfs-back-crumb { font-size: 12px; font-weight: 600; text-decoration: none; color: var(--mf-text);
    padding: 2px 9px; border-radius: 9px; background: var(--mf-surface-2, #222);
    white-space: nowrap; flex: 0 0 auto; margin-right: 8px; } /* theme-audit-allow: documented var() fallback */
.mfs-back-crumb:hover { background: var(--mf-primary); color: var(--mf-on-accent, #fff); } /* theme-audit-allow: documented var() fallback */
/* #1176: the whole /media archive toolbar hosted on the (sticky) breadcrumb. */
.mf-media-crumbtools { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; width: 100%; }
.mf-media-crumbtools .mf-media-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin: 0; padding: 0; background: none; border: 0; width: 100%; position: static; }
.mf-media-crumbtools select, .mf-media-crumbtools input, .mf-media-crumbtools button,
.mf-media-crumbtools .btn, .mf-media-crumbtools a { font-size: 12px; }
.mf-media-crumbtools .mf-media-tsize { margin-left: 0; }
/* Content clears the fixed two-row breadcrumb bar (#1262). The bar is a fixed
   child of .admin-main, which ALREADY sits below the 56px top nav in normal
   flow — so the padding only has to clear the bar itself (~60px), not the nav
   too. The old 122px double-counted the header and left a ~60px empty band at
   the top of every page (most visible on the actors/producers/favorites/devils
   pages). The archive overrides this per-page via JS where the bar is taller. */
html .admin-main { padding-top: 66px; }

/* Watch-page film-roll strip (#1068) — horizontal, scrollable. */
.mfs-filmroll { scroll-margin-top: 80px; }
.mfs-roll-strip { display: flex; gap: 8px; overflow-x: auto; padding: 4px var(--mfs-gutter) 14px; scrollbar-width: thin; }
.mfs-roll-strip::-webkit-scrollbar { height: 8px; }
.mfs-roll-strip::-webkit-scrollbar-thumb { background: var(--mf-border); border-radius: 4px; }
.mfs-roll-shot { flex: 0 0 auto; width: 160px; border-radius: 6px; overflow: hidden;
    border: 1px solid var(--mf-border); background: #000; text-decoration: none; } /* theme-audit-allow: frame-still pillarbox black */
.mfs-roll-shot img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; }
.mfs-roll-shot:hover { border-color: var(--mf-primary); }
.mfs-roll-shot { cursor: zoom-in; }
.mfs-roll-shot .mfs-roll-time { display: block; text-align: center; font-size: 10px; padding: 2px 0 3px;
    color: var(--mf-text-muted); background: var(--mf-surface); font-variant-numeric: tabular-nums; }
/* Film-roll zoom lightbox (#1120). */
.mfs-roll-lightbox { position: fixed; inset: 0; z-index: 9999; display: none; align-items: center; justify-content: center;
    background: rgba(0,0,0,.9); } /* theme-audit-allow: media lightbox scrim */
.mfs-roll-lightbox.open { display: flex; }
.mfs-roll-lightbox img { max-width: 96vw; max-height: 96vh; object-fit: contain; transition: transform .12s;
    transform-origin: center center; will-change: transform; user-select: none; }
/* tile country + actor chips (#1085) */
.mf-tile-origin { background: var(--mf-info-soft, #0e2a44) !important; color: var(--mf-link, #6cb1ff) !important; }
.mf-tile-actor { background: var(--mf-surface-alt, #1a1a22) !important; color: var(--mf-text-muted, #aaa) !important; }

/* TV: video fills the screen on the watch page (#1086) */
html.mf-tv .mfs-watch { padding: 0; }
html.mf-tv .mfs-watch-stage { padding: 0; }
html.mf-tv .mfs-watch-stage video { width: 100vw; height: 100vh; max-height: 100vh; object-fit: contain; background: #000; border-radius: 0; } /* theme-audit-allow: video pillarbox */
/* Auto-fullscreen on Android/TV (#1161): the app WebView has no browser chrome, so
   pinning the player to cover the whole viewport IS fullscreen — reliable and needs
   no user gesture (the real fullscreen API is gesture-gated after a navigation). The
   top nav / breadcrumb are covered while a video plays. */
html.mf-app .mfs-watch-stage video, html.mf-tv .mfs-watch-stage video,
html.mf-app .mfs-player-wrap video, html.mf-tv .mfs-player-wrap video {
  position: fixed; inset: 0; width: 100vw; height: 100vh; max-height: 100vh;
  object-fit: contain; background: #000; border-radius: 0; z-index: 9999; } /* theme-audit-allow: fullscreen video pillarbox */
html.mf-app .mfs-watch-stage, html.mf-tv .mfs-watch-stage { padding: 0; }
/* reactions row (#1087) */
.mfs-react { display:flex; gap:10px; align-items:center; padding:6px var(--mfs-gutter) 2px; }
.mfs-react button { display:inline-flex; align-items:center; gap:7px; padding:8px 16px; border-radius:22px; font-size:15px; cursor:pointer;
    background:var(--mf-surface-alt); color:var(--mf-text); border:1px solid var(--mf-border); }
.mfs-react button.on { background:var(--mf-primary); color:var(--mf-on-accent,#fff); border-color:var(--mf-primary); } /* theme-audit-allow: #fff documented fallback */
.mfs-react .mfs-rate-show { margin-left:auto; color:#f5c518; font-size:18px; letter-spacing:2px; } /* theme-audit-allow: IMDb-style rating gold */

/* ── Geo access grid (Settings → Access by country, #1089) ─────────────── */
.mfs-geo-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
    gap: 4px; max-height: 320px; overflow: auto; padding: 6px;
    border: 1px solid var(--mf-border); border-radius: 8px; background: var(--mf-input-bg, rgba(0,0,0,.15));
}
.mfs-geo-cc { display: flex; align-items: center; gap: 8px; padding: 5px 8px; border-radius: 6px; font-size: 13px; cursor: pointer; }
.mfs-geo-cc:hover { background: var(--mf-hover, rgba(255,255,255,.05)); }
.mfs-geo-cc input { width: auto; margin: 0; }
.mfs-geo-cc em { color: var(--mf-text-faint); font-style: normal; font-size: 11px; }

/* ── Stats dashboard (#1089) ───────────────────────────────────────────── */
.mfs-stat-cards { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.mfs-stat-card {
    flex: 1; min-width: 120px; padding: 16px 18px; border-radius: 10px;
    background: var(--mf-surface, #fff); border: 1px solid var(--mf-border, #ccc); text-align: center;
}
.mfs-stat-n { font-size: 30px; font-weight: 700; color: var(--mf-accent, #6c3cff); }
.mfs-stat-l { font-size: 12px; color: var(--mf-text-muted); margin-top: 4px; }
.mfs-stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 0 16px; }
.mfs-barchart { display: flex; align-items: flex-end; gap: 3px; height: 140px; padding-top: 6px; }
.mfs-bar { flex: 1; display: flex; align-items: flex-end; height: 100%; }
.mfs-bar-fill { width: 100%; background: var(--mf-accent, #6c3cff); border-radius: 2px 2px 0 0; min-height: 2px; }
.mfs-stat-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.mfs-stat-table td, .mfs-stat-table th { padding: 6px 8px; border-bottom: 1px solid var(--mf-border); text-align: left; }
.mfs-stat-table th { color: var(--mf-text-muted); font-weight: 600; }
.mfs-log-wrap { max-height: 460px; overflow: auto; }
.mfs-log-table { font-size: 12px; }
.mfs-log-table td { white-space: nowrap; }

/* Action chip on archive tiles (#1088). */
.mf-tile-tag.mf-tile-action { background: var(--mf-accent-soft, rgba(108,60,255,.14)); color: var(--mf-accent, #6c3cff); font-weight: 600; }
/* Clickable meta/tag chips (#1171) — action/country/actor navigate on click. */
.mfs-chip-nav { cursor: pointer; }
.mfs-chip-nav:hover { filter: brightness(1.15); text-decoration: underline; }

/* Per-tile quick actions: favorite (love) + star rating (#1091). */
.mf-tile-quick { display:flex; align-items:center; gap:8px; margin-top:6px; }
.mf-tile-quick .qfav, .mf-tile-quick .qstar { cursor:pointer; background:none; border:0; padding:0; font-size:15px; line-height:1; color:var(--mf-text-faint,#999); }
.mf-tile-quick .qfav.on { color:#e0245e; } /* theme-audit-allow: semantic love-heart red, same everywhere */
/* Selectable per-tile flags (#1206): 👍 favorite, 😈 devil, ⭐ feature. Muted when
   off, solid glyph + a tinted pill when ON so the selected state is unmistakable —
   the old grayscale-only cue was too subtle to read as "selected". Each keeps its
   own semantic colour. */
.mf-tile-quick .qbookmark, .mf-tile-quick .qdevil, .mf-tile-quick .qfeat {
  cursor:pointer; background:none; border:0; padding:2px 6px; font-size:15px; line-height:1;
  border-radius:9px; color:var(--mf-text-faint,#999); filter:grayscale(1); opacity:.55;
  transition:filter .12s, opacity .12s, background-color .12s; }
.mf-tile-quick .qbookmark:hover, .mf-tile-quick .qdevil:hover, .mf-tile-quick .qfeat:hover { filter:none; opacity:.9; }
.mf-tile-quick .qbookmark.on, .mf-tile-quick .qdevil.on, .mf-tile-quick .qfeat.on { filter:none; opacity:1; }
.mf-tile-quick .qbookmark.on { color:#3b82f6; background:rgba(59,130,246,.16); } /* theme-audit-allow: semantic favorite blue, same everywhere */
.mf-tile-stars { display:inline-flex; gap:1px; }
.mf-tile-stars .qstar.on { color:#f5b301; } /* theme-audit-allow: semantic rating-star gold, same everywhere */
.mf-tile-quick .qcount { font-size:11px; color:var(--mf-text-muted); min-width:10px; }

/* Devil 😈 (#1153/#1287) — base look shared with the other flags above; ON is a
   solid RED chip (the emoji glyph can't be recoloured via `color:`, so the red
   comes from the pill) and stays red for as long as the devil is selected. */
.mf-tile-quick .qdevil.on { background:#dc2626; box-shadow:0 0 0 2px rgba(220,38,38,.45); } /* theme-audit-allow: semantic devil red, same everywhere */

/* Thumb icons live BELOW the thumbnail, bottom-right (#1162): the kind icon, status
   badges and the selectable quick actions — OFF the image so the poster stays a
   clean select target for the D-pad remote. A right-aligned flex row in the meta. */
.mfs-tile-icons { display:flex; align-items:center; flex-wrap:wrap; justify-content:flex-start;
  gap:6px; margin-top:6px; }
.mfs-tile-icons .kind-tag, .mfs-tile-icons .mfs-badge-res,
.mfs-tile-icons .mfs-badge-watched, .mfs-tile-icons .mfs-tile-roll { position:static; inset:auto; margin:0; }
.mfs-tile-icons .kind-tag { text-transform:none; font-size:13px; padding:1px 5px; line-height:1.1; background:var(--mf-surface-2,#222); display:inline-flex; align-items:center; }
/* Inline video-kind icon (#1204) — sits in the kind-tag next to the resolution badge. */
.mfs-vid-ic { display:inline-block; vertical-align:middle; }
.mf-media-tile .preview .icon .mfs-vid-ic, .mf-media-tile .preview .mfs-vid-ic { width:.9em; height:.9em; }
.mfs-tile-icons .mfs-tile-roll { width:22px; height:22px; font-size:13px; background:var(--mf-surface-2,#222); }
.mfs-tile-icons .mf-tile-quick { margin:0; gap:7px; }
/* On-thumb icon overlay (#1292/#1293): film-roll marker + icon-only Edit, top-right
   ON the poster (no text). Neutralise the base .mfs-tile-roll absolute position. */
.mf-media-tile .preview .mfs-thumb-icons { position:absolute; top:6px; right:6px; z-index:5; display:flex; gap:6px; }
.mfs-thumb-ic { width:30px; height:30px; display:flex; align-items:center; justify-content:center; border-radius:8px;
    background:rgba(0,0,0,.6); color:#fff; font-size:16px; line-height:1; cursor:pointer; } /* theme-audit-allow: scrim over arbitrary poster */
.mfs-thumb-ic:hover, .mfs-thumb-ic:focus { background:var(--mf-primary); outline:none; }
.mfs-thumb-icons .mfs-tile-roll { position:static; inset:auto; width:30px; height:30px; font-size:16px; opacity:1; }
/* 10-star rating fits on the tile (#1294): tighten the glyphs a touch. */
.mf-tile-stars .qstar { font-size:13px; }

/* Public showcase frontpage (#1051): guest bar + hero extras. Reuses the existing
   .mfs-hero / .mfs-shelf / .mfs-rail / .mfs-tile machinery. */
.mfs-guest-bar { display:flex; align-items:center; gap:12px; padding:12px var(--mfs-gutter); }
.mfs-guest-bar .admin-brand { margin-right:auto; text-decoration:none; font-weight:800; font-size:20px; color:var(--mf-text); }
.mfs-hero-showcase { height:min(60vw,520px); }
.mfs-hero-kicker { text-transform:uppercase; letter-spacing:.12em; font-size:12px; font-weight:700;
    color:var(--mf-primary); margin:0 0 8px; }
.mfs-hero-actions { display:flex; align-items:center; gap:12px; flex-wrap:wrap; }

/* Bottom navigation removed (#1213): ONLY the top bar remains on every device —
   its inline nav links on desktop, and the avatar "scroll-down" menu (which carries
   every item, #1197) on phone/pad/app. No fixed bottom bar anywhere, incl. the app. */
/* Google TV joins phone/pad here (#1241/#1242): the wrapping top nav was the "main
   menu" Janus wanted gone — on a 10-foot remote it just ate D-pad focus. The TV
   header now carries ONLY the logo (.admin-brand) + the avatar "scroll-down" menu
   (mfs_header_right); every destination still lives in that menu. */
html.mf-phone .mfs-nav, html.mf-pad .mfs-nav, html.mf-tv .mfs-nav { display:none; }

/* ── Actors (#1074) — directory grid + profile showroom ─────────────── */
.mfs-actor-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(160px,1fr)); gap:16px; padding:12px var(--mfs-gutter) 28px; }
/* Actor/producer person-cards use the SAME chassis as the media-archive tile
   (#1286): one thumbnail style everywhere — identical border, radius, hover
   shadow-lift, and meta typography. Only the photo stays portrait (people read
   better than a 16:9 crop). */
.mfs-actor-card { text-decoration:none; color:inherit; background:var(--mf-surface); border:1px solid var(--mf-border);
  border-radius:8px; overflow:hidden; transition:transform .12s, box-shadow .12s; }
.mfs-actor-card:hover { transform:translateY(-2px); box-shadow:0 6px 16px rgba(0,0,0,.28); z-index:2; } /* theme-audit-allow: hover elevation, same as .mf-media-tile */
.mfs-actor-photo { aspect-ratio:1/1; background:var(--mf-surface-alt,#111); } /* theme-audit-allow: pillarbox fallback, same as .mf-media-tile .preview */
.mfs-actor-photo img { width:100%; height:100%; object-fit:cover; display:block; }
.mfs-actor-noimg { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:52px; color:var(--mf-text-faint); }
.mfs-actor-meta { padding:8px 10px; }
.mfs-actor-name { font-size:14px; font-weight:600; color:var(--mf-text); overflow:hidden; text-overflow:ellipsis;
  white-space:nowrap; } /* theme-audit-allow: 'white' here is white-space, not a colour */
.mfs-actor-sub { font-size:11px; color:var(--mf-text-muted); margin-top:2px; }
/* Actor-edit action picker — tag-style click chips, no checkboxes (#1145). */
#mfs-actor-actions-input { width: 100%; padding: 8px 12px; border-radius: 8px; border: 1px solid var(--mf-border);
  background: var(--mf-input-bg, var(--mf-surface)); color: var(--mf-text); font: inherit; }
.mfs-actor-actionsuggest { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.mfs-actor-actionsug { font-size: 12px; padding: 3px 9px; border-radius: 12px; text-decoration: none;
  border: 1px solid var(--mf-border); background: var(--mf-surface-2); color: var(--mf-text-muted); }
.mfs-actor-actionsug:hover { background: var(--mf-primary); color: var(--mf-on-accent, #fff); border-color: var(--mf-primary); }
/* Origin chip under the actor card (#1261) — actors are classified by origin
   ONLY now (the action chips + sections were dropped, #1263). It hovers
   exactly like the media-archive origin chip (#1207): fills with the theme
   primary + on-accent text, overriding the `.mfs-chip-nav:hover` underline. */
.mfs-actor-originrow { display:flex; flex-wrap:wrap; gap:4px; margin-top:4px; }
.mfs-actor-origin-chip { font-size:11px; font-weight:600; padding:2px 7px; border-radius:5px;
  background:var(--mf-surface-2); color:var(--mf-text-muted); border:1px solid var(--mf-border); cursor:pointer; }
.mfs-actor-origin-chip:hover { background:var(--mf-primary); color:var(--mf-on-accent,#fff);
  border-color:var(--mf-primary); text-decoration:none; filter:none; }
/* The actor card is a whole <a>, so admin.css's global `a:hover{underline}`
   underlined every meta line on hover (the same #1232 issue the archive fixed).
   Kill the card-wide underline; only the name and the origin chip react to
   hover — name underlines, chip fills — matching `.mf-media-tile .name:hover`. */
.mfs-actor-card:hover, .mfs-actor-card:hover .mfs-actor-meta,
.mfs-actor-card:hover .mfs-actor-name, .mfs-actor-card:hover .mfs-actor-originrow,
.mfs-actor-card:hover .mfs-actor-sub { text-decoration:none; }
.mfs-actor-name:hover { text-decoration:underline; }

.mfs-actor-hero { display:flex; gap:24px; align-items:flex-end; padding:14px var(--mfs-gutter) 18px; flex-wrap:wrap; }
.mfs-actor-hero-photo { width:180px; height:180px; object-fit:cover; border-radius:14px; background:var(--mf-surface-2); flex-shrink:0; }
.mfs-actor-hero-info { min-width:220px; flex:1; }
.mfs-actor-hero-name { font-size:clamp(24px,3vw,38px); font-weight:800; margin:0 0 8px; color:var(--mf-text); }
.mfs-actor-hero-nat { font-size:15px; color:var(--mf-text-muted); margin-bottom:8px; }
.mfs-actor-hero-bio { font-size:14px; color:var(--mf-text-muted); max-width:640px; margin:0 0 8px; }
.mfs-actor-hero-count { font-size:13px; color:var(--mf-text-faint); }
.mfs-actor-edit { margin:0 var(--mfs-gutter) 8px; background:var(--mf-surface); border:1px solid var(--mf-border); border-radius:10px; padding:10px 14px; }
.mfs-actor-edit summary { cursor:pointer; font-weight:600; color:var(--mf-text); }
.mfs-actor-editform { display:flex; gap:10px; align-items:flex-end; flex-wrap:wrap; margin-top:12px; }
.mfs-actor-editform label { display:flex; flex-direction:column; gap:4px; font-size:13px; color:var(--mf-text-muted); }
.mfs-actor-editform input[type=text], .mfs-actor-editform textarea { padding:8px 10px; border-radius:8px; border:1px solid var(--mf-border);
  background:var(--mf-input-bg,var(--mf-surface)); color:var(--mf-text); min-width:240px; font-family:inherit; }
html.mf-phone .mfs-actor-hero { padding:14px 16px 18px; }
html.mf-phone .mfs-actor-grid { padding:12px 16px 28px; }

/* Actor external links (#1086). */
.mfs-actor-links { display:flex; flex-wrap:wrap; gap:8px; margin:2px 0 10px; }
.mfs-actor-link { display:inline-flex; align-items:center; gap:5px; padding:5px 11px; border-radius:16px;
  border:1px solid var(--mf-border); background:var(--mf-surface); color:var(--mf-text); font-size:13px; text-decoration:none; }
.mfs-actor-link:hover { border-color:var(--mf-primary); color:var(--mf-primary); }
.mfs-actor-linkedit { display:flex; flex-direction:column; gap:6px; }
.mfs-actor-linklabel { font-size:13px; color:var(--mf-text-muted); }
.mfs-actor-linkrow { display:flex; gap:8px; }
.mfs-actor-linkrow input { padding:8px 10px; border-radius:8px; border:1px solid var(--mf-border);
  background:var(--mf-input-bg,var(--mf-surface)); color:var(--mf-text); }
.mfs-actor-linkrow input[name="link_label[]"] { flex:0 0 180px; }
.mfs-actor-linkrow input[name="link_url[]"] { flex:1; min-width:220px; }

/* Favorite toggle button on actor profile (#1087). */
.mfs-fav-btn { display:inline-flex; align-items:center; gap:7px; margin:2px 0 10px; padding:8px 16px; border-radius:22px;
  border:1px solid var(--mf-border); background:var(--mf-surface); color:var(--mf-text); font:inherit; font-size:14px;
  font-weight:600; cursor:pointer; }
.mfs-fav-btn:hover { border-color:var(--mf-primary); }
.mfs-fav-btn.on { border-color:var(--mf-primary); color:var(--mf-primary); }
.mfs-fav-btn .mfs-fav-ic { font-size:16px; }

/* Actor card badges + hover bio popup (#1092/#1093/#1094). */
.mfs-actor-card { position: relative; }
.mfs-actor-photo { position: relative; }
.mfs-actor-favbadge { position: absolute; top: 6px; right: 6px; z-index: 3; font-size: 15px;
  border-radius: 50%; width: 26px; height: 26px; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.5); } /* theme-audit-allow: scrim badge over arbitrary thumbnail */
.mfs-actor-ratebadge { position: absolute; bottom: 6px; right: 6px; z-index: 3; font-size: 11px; font-weight: 800;
  background: rgba(0,0,0,.72); color: #f5c518; padding: 2px 7px; border-radius: 5px; } /* theme-audit-allow: scrim gold rating over arbitrary thumbnail */
/* Superstar crown (top-left) + card accent (#1123). */
.mfs-actor-starbadge { position: absolute; top: 6px; left: 6px; z-index: 3; font-size: 15px; line-height: 1;
  width: 26px; height: 26px; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.5); border-radius: 50%; } /* theme-audit-allow: scrim badge over arbitrary thumbnail */
.mfs-actor-card.is-superstar { border-color: #f5b301; } /* theme-audit-allow: semantic superstar gold, same everywhere */
/* Clickable quick-toggles on the card thumb (top-right), stacked (#1123/#1128). */
.mfs-actor-quick { position: absolute; top: 6px; right: 6px; z-index: 4; display: flex; flex-direction: column; gap: 6px; }
.mfs-actor-quick > span { width: 28px; height: 28px; display: flex; align-items: center; justify-content: center;
  border-radius: 50%; font-size: 15px; cursor: pointer; background: rgba(0,0,0,.5); color: #fff; } /* theme-audit-allow: scrim toggle over arbitrary thumbnail */
.mfs-actor-quick .mfs-actor-qfav.on { color: #e0245e; } /* theme-audit-allow: semantic favourite red */
.mfs-actor-quick .mfs-actor-qstar { filter: grayscale(1); opacity: .7; }
.mfs-actor-quick .mfs-actor-qstar.on { filter: none; opacity: 1; }
/* Devil 😈 on the actor card — greyed off, full colour when marked (#1158). */
.mfs-actor-quick .mfs-actor-qdevil { filter: grayscale(1); opacity: .7; }
/* Devil ON = solid RED chip, matching the media tile (#1287); persists via .on. */
.mfs-actor-quick .mfs-actor-qdevil.on { filter: none; opacity: 1; background:#dc2626; box-shadow:0 0 0 2px rgba(220,38,38,.45); } /* theme-audit-allow: semantic devil red, same everywhere */
/* Actor-card icons live BELOW the photo, bottom-right (#1162) — off the image so the
   photo stays a clean select target. Badges + toggles in one right-aligned row. */
.mfs-actor-icons { display:flex; align-items:center; flex-wrap:wrap; justify-content:flex-start; gap:6px; margin-top:6px; }
.mfs-actor-icons .mfs-actor-starbadge, .mfs-actor-icons .mfs-actor-ratebadge,
.mfs-actor-icons .mfs-actor-typebadges { position:static; inset:auto; margin:0; }
.mfs-actor-icons .mfs-actor-quick { position:static; inset:auto; flex-direction:row; gap:7px; }
.mfs-actor-icons .mfs-actor-quick > span { width:24px; height:24px; }
/* Same cluster on the actor profile/edit hero (#1278) — favorite / devil /
   superstar, inline row, a touch larger for the bigger surface. */
.mfs-actor-hero-quick { margin: 4px 0 12px; }
.mfs-actor-hero-quick .mfs-actor-quick { position: static; inset: auto; flex-direction: row; gap: 10px; }
.mfs-actor-hero-quick .mfs-actor-quick > span { width: 38px; height: 38px; font-size: 19px; }
/* Full-profile hover popup (#1119). */
.mfs-actor-profile-pop { position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%) translateY(6px);
  width: max(100%, 250px); max-width: 320px; z-index: 40; opacity: 0; visibility: hidden; pointer-events: none;
  padding: 12px 14px; font-size: 13px; line-height: 1.5; color: var(--mf-text);
  background: var(--mf-surface); border: 1px solid var(--mf-border); border-radius: 10px;
  box-shadow: 0 12px 34px rgba(0,0,0,.45); max-height: 300px; overflow: auto; transition: opacity .12s, transform .12s; } /* theme-audit-allow: popover elevation shadow */
.mfs-actor-profile-pop::after { content: ""; position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
  border: 7px solid transparent; border-top-color: var(--mf-border); }
.mfs-actor-card:hover .mfs-actor-profile-pop { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.mfs-actor-pop-head { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
.mfs-actor-pop-photo { width: 54px; height: 54px; border-radius: 8px; object-fit: cover; flex-shrink: 0; }
.mfs-actor-pop-name { font-size: 15px; font-weight: 700; }
.mfs-actor-pop-row { color: var(--mf-text-muted); margin-top: 2px; }
.mfs-actor-pop-bio { margin-top: 8px; color: var(--mf-text); }

/* Rich article editor (#1085). */
.mfs-md-toolbar { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; border: 1px solid var(--mf-border);
  border-bottom: 0; border-radius: 8px 8px 0 0; background: var(--mf-surface-2); }
.mfs-md-btn { min-width: 32px; height: 30px; padding: 0 8px; border: 1px solid var(--mf-border); border-radius: 6px;
  background: var(--mf-surface); color: var(--mf-text); font-size: 13px; cursor: pointer; }
.mfs-md-btn:hover { background: var(--mf-primary); color: var(--mf-on-accent, #fff); border-color: var(--mf-primary); } /* theme-audit-allow: documented var() fallback */
.mfs-art-split { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid var(--mf-border); border-radius: 0 0 8px 8px; overflow: hidden; }
.mfs-art-split #mfs-art-body { border: 0; border-right: 1px solid var(--mf-border); border-radius: 0; min-height: 52vh;
  font-family: ui-monospace, Menlo, monospace; line-height: 1.55; resize: vertical; }
.mfs-art-preview { padding: 14px 18px; overflow: auto; min-height: 52vh; background: var(--mf-surface); color: var(--mf-text); }
.mfs-art-preview h1, .mfs-art-preview h2, .mfs-art-preview h3 { color: var(--mf-text); }
.mfs-art-preview img { max-width: 100%; border-radius: 8px; }
.mfs-art-preview blockquote { border-left: 3px solid var(--mf-primary); margin: 0; padding: 4px 14px; color: var(--mf-text-muted); }
html.mf-phone .mfs-art-split { grid-template-columns: 1fr; }
html.mf-phone .mfs-art-split #mfs-art-body { border-right: 0; border-bottom: 1px solid var(--mf-border); }
.mfs-art-imgpick { display: none; position: fixed; right: 20px; bottom: 20px; width: min(420px, 90vw); z-index: 60;
  background: var(--mf-surface); border: 1px solid var(--mf-border); border-radius: 12px; box-shadow: 0 12px 34px rgba(0,0,0,.4); } /* theme-audit-allow: popover elevation */
.mfs-art-imgpick.open { display: block; }
.mfs-art-imgpick-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--mf-border); font-weight: 600; }
.mfs-art-imgpick-head button { background: none; border: 0; color: var(--mf-text-muted); font-size: 16px; cursor: pointer; }
.mfs-art-imgpick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 6px; padding: 12px; max-height: 50vh; overflow: auto; }
.mfs-art-imgpick-grid img { width: 100%; aspect-ratio: 1/1; object-fit: cover; border-radius: 6px; cursor: pointer; border: 2px solid transparent; }
.mfs-art-imgpick-grid img:hover { border-color: var(--mf-primary); }
/* Files / content-size list (#1127). */
.mfs-file-list { display: flex; flex-direction: column; gap: 2px; }
.mfs-file-row { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 8px;
  text-decoration: none; color: inherit; border-bottom: 1px solid var(--mf-border); }
.mfs-file-row:hover { background: var(--mf-surface-2); }
.mfs-file-thumb { flex: 0 0 auto; width: 96px; height: 54px; border-radius: 5px; overflow: hidden;
  display: flex; align-items: center; justify-content: center; background: #000; } /* theme-audit-allow: thumb pillarbox black */
.mfs-file-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mfs-file-noimg { font-size: 22px; }
.mfs-file-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.mfs-file-name { font-size: 14px; font-weight: 600; color: var(--mf-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mfs-file-meta { font-size: 12px; color: var(--mf-text-muted); margin-top: 2px; }
.mfs-file-size { flex: 0 0 auto; font-size: 14px; font-weight: 700; color: var(--mf-text); font-variant-numeric: tabular-nums;
  min-width: 90px; text-align: right; }
/* Floating bio popup above the card on hover (#1106) — a real tooltip card, not a
   scrim on the thumb. */
.mfs-actor-bio-pop { position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%) translateY(6px);
  width: max(100%, 240px); max-width: 300px; z-index: 40; opacity: 0; visibility: hidden; pointer-events: none;
  padding: 12px 14px; font-size: 13px; line-height: 1.45; color: var(--mf-text);
  background: var(--mf-surface); border: 1px solid var(--mf-border); border-radius: 10px;
  box-shadow: 0 12px 34px rgba(0,0,0,.45); max-height: 240px; overflow: auto; transition: opacity .12s, transform .12s; } /* theme-audit-allow: popover elevation shadow */
.mfs-actor-bio-pop::after { content: ""; position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
  border: 7px solid transparent; border-top-color: var(--mf-border); } /* little arrow */
.mfs-actor-card:hover .mfs-actor-bio-pop { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.mfs-actor-hero-rating { font-size: 15px; font-weight: 700; color: #f5c518; margin-bottom: 6px; } /* theme-audit-allow: IMDb-style gold rating */
/* One rating system — 10 clickable stars (#1294). Used in the actor editor and,
   read-only, in the hero. Matches the media-tile star gold. */
.mfs-rate { display: inline-flex; gap: 2px; align-items: center; }
.mfs-rate-star { background: none; border: 0; padding: 0; cursor: pointer; font-size: 20px; line-height: 1; color: var(--mf-text-faint, #999); }
.mfs-rate-star.on { color: #f5b301; } /* theme-audit-allow: semantic rating-star gold, same everywhere */
.mfs-rate-ro .mfs-rate-star { cursor: default; font-size: 16px; }
.mfs-actor-aka { font-size: 14px; color: var(--mf-text-muted); font-style: italic; margin-bottom: 6px; } /* a.k.a. line (#1152) */

/* Actor photo archive picker (#1091). */
.mfs-actor-pick { margin: 4px 0 8px; }
.mfs-actor-pick summary { cursor: pointer; font-size: 13px; color: var(--mf-text-muted); }
.mfs-actor-pickgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; margin-top: 10px;
  max-height: 320px; overflow: auto; }
.mfs-actor-pickitem { padding: 0; border: 1px solid var(--mf-border); border-radius: 6px; overflow: hidden; cursor: pointer; background: #000; } /* theme-audit-allow: image pillarbox */
.mfs-actor-pickitem img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; }
.mfs-actor-pickitem:hover { border-color: var(--mf-primary); }
.mfs-actor-pickitem img { aspect-ratio: 1/1; }   /* square previews to match the square profile crop (#1138) */

/* Zoom/crop modal (#1138). */
.mfs-crop-modal { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.85); } /* theme-audit-allow: modal scrim */
.mfs-crop-box { background: var(--mf-surface); border: 1px solid var(--mf-border); border-radius: 12px; padding: 16px; max-width: 94vw; }
.mfs-crop-stage { position: relative; width: min(80vw, 70vh, 460px); height: min(80vw, 70vh, 460px); overflow: hidden;
  background: #000; border-radius: 8px; cursor: grab; touch-action: none; } /* theme-audit-allow: crop backdrop */
.mfs-crop-stage:active { cursor: grabbing; }
.mfs-crop-img { position: absolute; left: 0; top: 0; user-select: none; -webkit-user-drag: none; max-width: none; }
.mfs-crop-frame { position: absolute; inset: 0; pointer-events: none; box-shadow: 0 0 0 100vmax rgba(0,0,0,.35) inset;
  border: 2px solid rgba(255,255,255,.85); border-radius: 8px; } /* theme-audit-allow: crop framing overlay */
.mfs-crop-ctrls { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.mfs-crop-ctrls .mfs-crop-zoom { flex: 1; }
.mfs-crop-ctrls .mfs-crop-use { margin-left: auto; }

/* Edit link under a video tile (manager, #1099). */
.mfs-tile-edit { display:inline-block; margin-top:4px; font-size:12px; font-weight:600; color:var(--mf-link); cursor:pointer; }
.mfs-tile-edit:hover { text-decoration:underline; }
/* Auto-save "Saved" indicator (#1097). */
.mfs-saved { font-size:12px; font-weight:600; color:var(--mf-success-text,#1a7f37); opacity:0; transition:opacity .2s; }
.mfs-saved.on { opacity:1; }

/* Actor type + actions (#1095). */
.mfs-actor-hero-tags { display:flex; flex-wrap:wrap; gap:6px; margin:2px 0 10px; }
.mfs-actor-type { display:inline-flex; align-items:center; padding:3px 10px; border-radius:14px; font-size:12px; font-weight:700;
  background:var(--mf-primary); color:var(--mf-on-accent,#fff); } /* theme-audit-allow: #fff documented var() fallback */
.mfs-actor-action { display:inline-flex; align-items:center; padding:3px 10px; border-radius:14px; font-size:12px;
  border:1px solid var(--mf-border); color:var(--mf-text-muted); text-decoration:none; }
.mfs-actor-action:hover { border-color:var(--mf-primary); color:var(--mf-primary); }
.mfs-actor-typebadge { position:absolute; bottom:6px; left:6px; z-index:3; font-size:10px; font-weight:700; padding:2px 7px; border-radius:5px;
  background:var(--mf-primary); color:var(--mf-on-accent,#fff); } /* theme-audit-allow: #fff documented var() fallback */
.mfs-actor-actiongrid { display:flex; flex-wrap:wrap; gap:8px; margin-top:8px; }
.mfs-actor-actionchk { display:inline-flex; align-items:center; gap:5px; font-size:13px; color:var(--mf-text); }
.mfs-actor-actionchk input { width:auto; margin:0; }

/* Thumbnail size S/M/L, applied to every grid on every page (#1103). */
html.mf-ts-small  .mfs-rail, html.mf-ts-small  .mfs-actor-grid, html.mf-ts-small  .mfs-browse-grid { grid-template-columns:repeat(auto-fill,minmax(150px,1fr)); }
html.mf-ts-medium .mfs-rail, html.mf-ts-medium .mfs-actor-grid, html.mf-ts-medium .mfs-browse-grid { grid-template-columns:repeat(auto-fill,minmax(230px,1fr)); }
html.mf-ts-large  .mfs-rail, html.mf-ts-large  .mfs-actor-grid, html.mf-ts-large  .mfs-browse-grid { grid-template-columns:repeat(auto-fill,minmax(320px,1fr)); }
html.mf-ts-huge   .mfs-rail, html.mf-ts-huge   .mfs-actor-grid, html.mf-ts-huge   .mfs-browse-grid { grid-template-columns:repeat(auto-fill,minmax(440px,1fr)); }
html.mf-ts-poster .mfs-rail, html.mf-ts-poster .mfs-actor-grid, html.mf-ts-poster .mfs-browse-grid { grid-template-columns:repeat(auto-fill,minmax(620px,1fr)); }
html.mf-ts-full   .mfs-rail, html.mf-ts-full   .mfs-actor-grid, html.mf-ts-full   .mfs-browse-grid { grid-template-columns:1fr; }
.mfs-tsctl { display:inline-flex; margin-left:8px; border:1px solid var(--mf-border); border-radius:6px; overflow:hidden; }
.mfs-tsbtn { border:0; background:transparent; color:var(--mf-text-muted); font:inherit; font-size:12px; font-weight:700;
  width:26px; height:26px; cursor:pointer; }
.mfs-tsbtn:hover { background:var(--mf-surface-2); color:var(--mf-text); }
.mfs-tsbtn.on { background:var(--mf-primary); color:var(--mf-on-accent,#fff); } /* theme-audit-allow: #fff documented var() fallback */
html.mf-phone .mfs-tsctl { display:none; }

/* Film rolls on the actor page (#1104) — down-scrolling grid per video. */
.mfs-actor-rolls { padding:0 var(--mfs-gutter) 18px; }
.mfs-actor-roll { margin-bottom:18px; }
.mfs-actor-roll-head { margin:0 0 8px; font-size:14px; font-weight:600; }
.mfs-actor-roll-head a { color:var(--mf-text); text-decoration:none; }
.mfs-actor-roll-head a:hover { color:var(--mf-primary); }
.mfs-actor-roll-head a + a { margin-left:8px; color:var(--mf-link); font-size:13px; }
.mfs-roll-gridstrip { display:grid; grid-template-columns:repeat(auto-fill,minmax(120px,1fr)); gap:6px; }
html.mf-phone .mfs-actor-rolls { padding:0 16px 18px; }

/* Edit link next to the actor name, toggles the edit section (#1107). */
.mfs-actor-namerow { display:flex; align-items:baseline; gap:14px; flex-wrap:wrap; }
.mfs-actor-editlink { border:0; background:transparent; color:var(--mf-link); font:inherit; font-size:14px; font-weight:600;
  cursor:pointer; padding:2px 4px; display:inline-flex; align-items:center; gap:8px; }
.mfs-actor-editlink:hover { text-decoration:underline; }
.mfs-actor-editsummary { display:none; }

/* ===== THE canonical media tile (#1108) — identical on every surface ===== */
.mf-media-tile { display:flex; flex-direction:column; background:var(--mf-surface); border:1px solid var(--mf-border);
  border-radius:8px; overflow:hidden; text-decoration:none; color:inherit; position:relative; transition:transform .12s, box-shadow .12s; }
.mf-media-tile:hover { transform:translateY(-2px); box-shadow:0 6px 16px rgba(0,0,0,.28); z-index:2; } /* theme-audit-allow: hover elevation */
.mf-media-tile .preview { aspect-ratio:16/9; background:var(--mf-surface-alt,#111); display:flex; align-items:center; justify-content:center; overflow:hidden; position:relative; } /* theme-audit-allow: pillarbox fallback */
.mf-media-tile .preview img { width:100%; height:100%; object-fit:cover; }
.mf-media-tile .preview .icon { font-size:46px; opacity:.5; }
.mf-media-tile .preview video.mfs-prev { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; background:#000; z-index:1; } /* theme-audit-allow: video pillarbox */
/* Kind tag (video icon) flows in the below-thumb .mfs-tile-icons row next to the
   resolution badge (#1204) — no longer absolutely pinned to the image corner. */
.mf-media-tile .kind-tag { background:var(--mf-surface-2,#222); color:var(--mf-text-muted,#aaa);
  font-size:10px; padding:1px 6px; border-radius:3px; text-transform:uppercase; }
.mf-media-tile .meta { padding:8px 10px; font-size:12px; }
.mf-media-tile .meta .name { font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; color:var(--mf-text); }
.mf-media-tile .meta .sub { color:var(--mf-text-muted); font-size:11px; margin-top:3px; }
/* Source channel + video date/time on a tile (#1318). */
.mf-media-tile .meta .mfs-tile-prov { color:var(--mf-text-muted); font-size:11px; opacity:.9; }
/* Same, on the watch page under the title. */
.mfs-watch-prov { display:flex; flex-wrap:wrap; gap:14px; padding:2px var(--mfs-gutter) 4px;
  color:var(--mf-text-muted); font-size:13px; }
.mfs-watch-prov span { display:inline-flex; align-items:center; gap:5px; }
.mf-media-tile .mf-tile-tag { font-size:10px; padding:1px 6px; border-radius:4px; background:var(--mf-surface-2,#222);
  color:var(--mf-link,#6cb1ff); border:1px solid var(--mf-border,#333); transition:background-color .12s, color .12s, border-color .12s; }
/* Metadata chips hover exactly like the edit-page action chips (#1207): fill with
   the theme primary and switch to on-accent text so it's always readable. */
.mf-media-tile .mf-tile-tag:hover { background:var(--mf-primary,#1a73e8); color:var(--mf-on-accent,#fff); border-color:var(--mf-primary,#1a73e8); text-decoration:none; }
/* #1232: the whole tile is an <a>, so admin.css's global `a:hover{underline}`
   underlined EVERY meta line on hover. Kill the tile-wide underline; underline
   only the specific item under the cursor (the title; chips highlight via fill). */
.mf-media-tile:hover, .mf-media-tile:hover .meta, .mf-media-tile:hover .sub { text-decoration:none; }
.mf-media-tile .name:hover { text-decoration:underline; }
.mf-access { display:inline-block; font-size:10px; font-weight:700; padding:1px 7px; border-radius:9px; }
.mf-access-public  { background:var(--mf-success-soft,#113a24); color:var(--mf-success-text,#4ec27c); }
.mf-access-private { background:var(--mf-surface-2,#222); color:var(--mf-text-muted,#aaa); }
.mf-access-group   { background:var(--mf-info-soft,#0e2a44); color:var(--mf-link,#6cb1ff); }
.mf-media-tile .mfs-tile-edit { display:inline-block; margin-top:5px; }

/* all actor types on the card thumb (#1109) */
.mfs-actor-typebadges { position:absolute; bottom:6px; left:6px; z-index:3; display:flex; flex-wrap:wrap; gap:4px; max-width:calc(100% - 12px); }
.mfs-actor-typebadges .mfs-actor-typebadge { position:static; }

/* One-click feature toggle on the tile (#1110) — base look shared with the flags
   above (#1206); ON is a gold star in a gold pill. */
.mf-tile-quick .qfeat.on { color:#f5b301; background:rgba(245,179,1,.16); } /* theme-audit-allow: semantic featured-star gold, same everywhere */

/* Background-jobs bottom bar (#1296) — a live pill + click-to-open running list. */
.mfs-jobs { position:fixed; right:14px; bottom:14px; z-index:200; display:flex; flex-direction:column; align-items:flex-end; gap:8px; }
.mfs-jobs-pill { display:inline-flex; align-items:center; gap:6px; background:var(--mf-primary); color:var(--mf-on-accent,#fff); border:0; border-radius:999px; padding:8px 14px; font-size:13px; font-weight:600; cursor:pointer; box-shadow:0 4px 14px rgba(0,0,0,.3); } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */
.mfs-jobs-spin { display:inline-block; animation:mfs-spin 2s linear infinite; }
@keyframes mfs-spin { to { transform:rotate(360deg); } }
.mfs-jobs-panel { width:min(340px,86vw); max-height:50vh; overflow:auto; background:var(--mf-surface); border:1px solid var(--mf-border); border-radius:12px; box-shadow:0 8px 28px rgba(0,0,0,.35); padding:8px; } /* theme-audit-allow: neutral drop shadow */
.mfs-jobs-head { font-size:12px; font-weight:700; text-transform:uppercase; letter-spacing:.05em; color:var(--mf-text-muted); padding:4px 8px 8px; }
.mfs-jobs-item { display:flex; gap:10px; align-items:flex-start; padding:8px; border-radius:8px; }
.mfs-jobs-item + .mfs-jobs-item { border-top:1px solid var(--mf-border); }
.mfs-jobs-ic { font-size:18px; line-height:1.2; }
.mfs-jobs-txt { flex:1; min-width:0; display:flex; flex-direction:column; gap:2px; }
.mfs-jobs-txt b { font-size:13px; color:var(--mf-text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; } /* theme-audit-allow: 'white' is white-space, not a colour */
.mfs-jobs-txt small { font-size:11px; color:var(--mf-text-muted); }
.mfs-jobs-bar { height:4px; background:var(--mf-surface-2,#222); border-radius:2px; overflow:hidden; margin-top:3px; } /* theme-audit-allow: documented var() fallback */
.mfs-jobs-bar i { display:block; height:100%; background:var(--mf-primary); }

/* Actor-research AI chat (#1284) — Webmaster-only panel on the actor edit page. */
.mfs-ai-research { padding:0 var(--mfs-gutter) 8px; }
.mfs-ai-box { max-width:820px; border:1px solid var(--mf-border); border-radius:10px; background:var(--mf-surface); overflow:hidden; }
.mfs-ai-log { max-height:340px; overflow:auto; padding:12px; display:flex; flex-direction:column; gap:8px; }
.mfs-ai-hint { color:var(--mf-text-muted); font-size:13px; }
.mfs-ai-msg { padding:8px 12px; border-radius:10px; font-size:14px; line-height:1.5; max-width:88%; overflow-wrap:anywhere; }
.mfs-ai-me { align-self:flex-end; background:var(--mf-primary); color:var(--mf-on-accent,#fff); } /* theme-audit-allow: #fff is the documented var() fallback for --mf-on-accent */
.mfs-ai-ai { align-self:flex-start; background:var(--mf-surface-2,#222); color:var(--mf-text); } /* theme-audit-allow: documented var() fallback */
.mfs-ai-wait { font-style:italic; color:var(--mf-text-muted); }
.mfs-ai-err { align-self:flex-start; background:var(--mf-danger,#c0392b); color:var(--mf-on-accent,#fff); font-size:13px; } /* theme-audit-allow: semantic error + documented fallback */
.mfs-ai-form { display:flex; gap:8px; padding:10px; border-top:1px solid var(--mf-border); }
.mfs-ai-form input { flex:1; padding:9px 12px; border-radius:8px; border:1px solid var(--mf-border); background:var(--mf-bg); color:var(--mf-text); font-size:14px; }
