/* The show bible: the desk (tools, slide, inspector, strip), the slide's looks, the presentation, the phone, the export.
   Every look's decoration is here; where things go is in js/themes.js. Loaded after app.css. */

/* ---------- title fonts, self-hosted: each reads Hebrew and Latin. Rubik's own file holds its heavy weights too */
@font-face { font-family: 'Rubik'; font-style: normal; font-weight: 700 900; font-display: swap; src: url(/fonts/rubik-he.woff2) format('woff2'); unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Rubik'; font-style: normal; font-weight: 700 900; font-display: swap; src: url(/fonts/rubik-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Karantina'; font-weight: 700; font-display: swap; src: url(/fonts/karantina-he.woff2) format('woff2'); unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Karantina'; font-weight: 700; font-display: swap; src: url(/fonts/karantina-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+20AC, U+2122, U+FEFF, U+FFFD; }
@font-face { font-family: 'Frank Ruhl Libre'; font-weight: 800; font-display: swap; src: url(/fonts/frank-he.woff2) format('woff2'); unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Frank Ruhl Libre'; font-weight: 800; font-display: swap; src: url(/fonts/frank-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+20AC, U+2122, U+FEFF, U+FFFD; }
@font-face { font-family: 'Suez One'; font-weight: 400; font-display: swap; src: url(/fonts/suez-he.woff2) format('woff2'); unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Suez One'; font-weight: 400; font-display: swap; src: url(/fonts/suez-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+20AC, U+2122, U+FEFF, U+FFFD; }
@font-face { font-family: 'Amatic SC'; font-weight: 700; font-display: swap; src: url(/fonts/amatic-he.woff2) format('woff2'); unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F; }
@font-face { font-family: 'Amatic SC'; font-weight: 700; font-display: swap; src: url(/fonts/amatic-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+20AC, U+2122, U+FEFF, U+FFFD; }

@keyframes si-in { from { opacity: 0; scale: .94; } to { opacity: 1; scale: 1; } }
@keyframes si-out { to { opacity: 0; scale: .9; } }
@keyframes sw-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes pr-l { from { opacity: 0; transform: translateX(-6%); } to { opacity: 1; transform: none; } }
@keyframes pr-r { from { opacity: 0; transform: translateX(6%); } to { opacity: 1; transform: none; } }
@keyframes pulse-dot { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

/* ---------- the screen */
.screen:has(.bible) { max-width: 1680px; }
.bible { display: grid; gap: 10px; --sel: #2f6bff; --guide: #ff2fd0; }
.bb-bar { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; }
.bb-bar h1 { font-size: 24px; }
.bb-where { font-size: 14px; min-width: 0; }
.tag.ok { background: #e7f5ee; color: var(--ok); }
.tg.icon { padding: 0 8px; }
.present-btn { background: var(--ink); color: #fff; border-color: var(--ink); height: 38px; padding: 0 18px 0 16px; font-size: 15px; gap: 8px; position: relative; }
.present-btn:hover { background: #2a2a2a; border-color: #2a2a2a; }
.present-btn::after { content: ''; position: absolute; top: 7px; inset-inline-end: 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--red); animation: pulse-dot 2s ease-in-out infinite; }
.bb-banner { border-radius: var(--r); animation: rise var(--mid) var(--ease) backwards; }
.bb-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.bb-chips .chip { height: 26px; display: inline-flex; align-items: center; text-decoration: none; }
.bb-export { position: relative; }
.bb-export .pick-menu { inset-inline-start: auto; inset-inline-end: 0; min-width: 220px; }

/* ---------- the desk: tools at the start side, the slide, the inspector at the end side */
.bb-desk { display: grid; grid-template-columns: 48px minmax(0, 1fr) 300px; gap: 12px; align-items: start; }
.bb-rail { display: flex; flex-direction: column; gap: 4px; align-items: center; padding: 6px 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); position: sticky; top: calc(var(--tally) + var(--nav) + 8px); min-height: 220px; animation: rise var(--mid) var(--ease) backwards; }
.bb-rail.idle { border-color: transparent; background: none; min-height: 0; }
.bb-rail .btn { width: 38px; height: 38px; }
.rail-sep { width: 24px; height: 1px; background: var(--line); margin: 4px 0; }
.rail-count { position: relative; }
.rail-count b { position: absolute; top: 1px; inset-inline-end: 0; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--ink); color: #fff; font-size: 11px; line-height: 17px; font-weight: 600; text-align: center; }
.btn.on.rail-count b { background: #fff; color: var(--ink); }
.rail-pop-wrap { position: relative; }
.rail-pop { position: absolute; inset-inline-start: calc(100% + 6px); top: 0; display: flex; gap: 2px; padding: 4px; background: var(--paper); border: 1px solid var(--line2); border-radius: 10px; box-shadow: 0 8px 24px rgba(0,0,0,.14); z-index: 40;
  opacity: 0; transform: translateX(6px) scale(.97); pointer-events: none; transition: opacity var(--fast), transform var(--fast) var(--ease); }
.rail-pop.in { opacity: 1; transform: none; pointer-events: auto; }
.bb-stage { min-width: 0; }
.slide-row { display: flex; align-items: center; justify-content: center; gap: 6px; }
.sl-nav { flex: none; width: 34px; height: 64px; display: grid; place-items: center; border-radius: 10px; color: var(--ink2); text-decoration: none; transition: background var(--fast), color var(--fast), opacity var(--fast); }
.sl-nav:hover { background: var(--soft); color: var(--ink); }
.sl-nav.off { opacity: .2; pointer-events: none; }
.slide { position: relative; flex: none; overflow: hidden; background: #000; border-radius: 6px; user-select: none; box-shadow: 0 1px 0 rgba(0,0,0,.05), 0 10px 34px rgba(0,0,0,.16); transition: box-shadow var(--fast); }
.editing .slide { touch-action: none; }
.slide.dropping { box-shadow: 0 0 0 3px var(--sel), 0 10px 34px rgba(0,0,0,.2); }
.slide.marking { cursor: crosshair; }
.slide-scale { position: absolute; top: 0; left: 0; width: 1600px; height: 900px; transform-origin: 0 0; }
.slide-wait { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(255,255,255,.12); animation: fade var(--mid) backwards; pointer-events: none; }
.spin.dark { position: static; }

/* ---------- a slide */
.slide-in { position: relative; width: 1600px; height: 900px; overflow: hidden; direction: rtl; font-family: var(--body); }
.slide-in.switch { animation: sw-in .3s var(--ease) backwards; }
.si { position: absolute; transform-origin: 50% 50%; animation: si-in .28s var(--ease) backwards; }
.mini .si, .present .si { animation: none; }
.si.ghost { animation: si-out .22s var(--ease) forwards; pointer-events: none; z-index: 5; }
.m-edit .si { cursor: default; }
.editing .m-edit .si { cursor: move; }
.si.on { outline: 4px solid var(--sel); outline-offset: 5px; box-shadow: 0 0 0 9px rgba(255,255,255,.55); }
.si.ref { outline: 3px dashed currentColor; outline-offset: 6px; }
.is-dark .si.ref { outline-color: rgba(255,255,255,.7); } .is-light .si.ref { outline-color: rgba(0,0,0,.45); }
.si.ref.on { outline: 4px solid var(--sel); }
.si.idea { opacity: .82; }
.slide.arranging .si { transition: left .55s var(--ease), top .55s var(--ease), width .55s var(--ease), height .55s var(--ease), transform .55s var(--ease); }
.si-clip { position: absolute; inset: 0; overflow: hidden; border-radius: 2px; }
.si-clip img { position: absolute; display: block; pointer-events: none; }
.si.cropping .si-clip { overflow: visible; }
.si.cropping .si-clip img { opacity: .4; }
.si.cropping::after { content: ''; position: absolute; inset: 0; outline: 3px dashed #fff; box-shadow: 0 0 0 9999px rgba(0,0,0,.35); pointer-events: none; }
.si-text { width: 100%; height: 100%; white-space: pre-wrap; unicode-bidi: plaintext; overflow-wrap: break-word; }
.si-text.title { text-wrap: balance; }
.editing-text { outline: 3px solid var(--sel); outline-offset: 6px; cursor: text; overflow: visible; }
.si-text .ph { opacity: .45; }
.muted-ph { font-size: 22px; opacity: .65; display: grid; place-items: center; text-align: center; border: 2px dashed currentColor; }
.si-artists { display: flex; gap: 12px 30px; line-height: 1.3; }
.si-artists.row { flex-wrap: wrap; align-content: flex-start; }
.si-artists.list { flex-direction: column; gap: .35em; }
.si-artists span { white-space: nowrap; display: inline-flex; align-items: center; }
.si-artists i { display: inline-block; width: .62em; height: .62em; border-radius: 50%; margin-inline-end: .4em; flex: none; }
.si-artists.on-acc i { box-shadow: 0 0 0 2px rgba(255,255,255,.75); }
.si-artists i.ph { width: 1.25em; height: 1.25em; overflow: hidden; margin-inline-end: .45em; background: #333; }
.si-artists i.ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.si-artists.byline { display: block; }
.si-artists.byline span { display: inline; white-space: normal; }
.si-artists.byline i { display: inline-block; vertical-align: .1em; }
.si-artists.byline .by { color: var(--sub); }
.si-link { display: flex; align-items: center; gap: 14px; height: 100%; padding: 0 20px; border-radius: 10px; color: inherit; text-decoration: none; font-size: 26px; overflow: hidden; border: 2px solid currentColor; }
.is-dark .si-link { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.22); } .is-light .si-link { background: rgba(0,0,0,.04); border-color: rgba(0,0,0,.15); }
.si-shape, .si-stage { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.si-stage.marking { cursor: crosshair; }
.si-cap { position: absolute; top: calc(100% + 10px); left: 0; right: 0; font-size: 24px; line-height: 1.25; text-align: right; unicode-bidi: plaintext; color: var(--ink); }
.si-badge { position: absolute; top: 10px; right: 10px; background: rgba(0,0,0,.72); color: #fff; font-size: 18px; padding: 3px 12px; border-radius: 14px; }
.si-badge.warn { background: #ffd23f; color: #111; }
.si-badge.ok { background: #138a52; padding: 4px 7px; }
.si-badge.idea { background: rgba(255,255,255,.88); color: #111; font-size: 16px; padding: 2px 10px; letter-spacing: .02em; }
.is-light .si-badge.idea { background: rgba(0,0,0,.72); color: #fff; }
.si-pin, .si-chain, .si-changed { position: absolute; background: #fff; color: #111; border-radius: 50%; width: 30px; height: 30px; display: grid; place-items: center; box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.si-pin { top: -15px; left: -15px; }
.si-chain { bottom: -16px; left: -16px; }
.si-chain.off { background: #111; color: #fff; opacity: .85; }
.si-changed { bottom: -16px; left: 22px; background: #ffd23f; }
.si-new { position: absolute; top: -8px; left: -8px; width: 18px; height: 18px; border-radius: 50%; background: var(--red); border: 3px solid #fff; z-index: 2; }
.si-play { position: absolute; inset: 0; margin: auto; width: 84px; height: 84px; border-radius: 50%; border: 0; background: rgba(0,0,0,.6); color: #fff; cursor: pointer; display: grid; place-items: center; transition: transform var(--fast); }
.si-play:hover { transform: scale(1.06); }
.hd { position: absolute; width: 22px; height: 22px; background: #fff; border: 4px solid var(--sel); border-radius: 5px; z-index: 3; box-shadow: 0 1px 4px rgba(0,0,0,.35); }
.hd.turn { top: -60px; left: calc(50% - 11px); border-radius: 50%; cursor: grab; }
.hd.turn::after { content: ''; position: absolute; left: 7px; top: 18px; width: 0; height: 26px; border-left: 3px solid var(--sel); }
.cr { position: absolute; background: #fff; z-index: 3; border-radius: 4px; box-shadow: 0 1px 6px rgba(0,0,0,.5); }
.cr-l, .cr-r { top: calc(50% - 30px); width: 14px; height: 60px; cursor: ew-resize; }
.cr-l { left: -7px; } .cr-r { right: -7px; }
.cr-t, .cr-b { left: calc(50% - 30px); height: 14px; width: 60px; cursor: ns-resize; }
.cr-t { top: -7px; } .cr-b { bottom: -7px; }
.si.pending { animation: si-in .28s var(--ease) backwards; }
.si.pending img { width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.si.pending .spin, .slide-wait .spin { position: absolute; inset: 0; margin: auto; width: 56px; height: 56px; border: 6px solid rgba(255,255,255,.3); border-top-color: #fff; border-radius: 50%; animation: spin 1s linear infinite; }
.slide-wait .spin { width: 34px; height: 34px; border-width: 3px; border-color: rgba(0,0,0,.15); border-top-color: var(--ink); position: static; }
.guide { position: absolute; background: var(--guide); z-index: 990; pointer-events: none; box-shadow: 0 0 0 1px rgba(255,255,255,.6); }
.guide.v { top: 0; bottom: 0; width: 3px; } .guide.h { left: 0; right: 0; height: 3px; }
.drop-hint { position: absolute; z-index: 4; display: grid; place-items: center; align-content: center; gap: 14px; border: 4px dashed currentColor; border-radius: 18px; opacity: .35; font-size: 32px; pointer-events: none; animation: sw-in .4s var(--ease) backwards; }
.sel-band { position: absolute; z-index: 991; border: 3px solid var(--sel); background: rgba(47,107,255,.12); pointer-events: none; }
.sel-box { position: absolute; z-index: 989; outline: 3px dashed var(--sel); outline-offset: 14px; pointer-events: none; animation: fade var(--fast) backwards; }
.round-frame { position: absolute; inset: 0; z-index: 980; pointer-events: none; background: radial-gradient(circle at 50% 50%, transparent 449px, rgba(0,0,0,.66) 451px); animation: fade var(--mid) backwards; }
.round-frame i { position: absolute; left: 350px; top: 0; width: 900px; height: 900px; border-radius: 50%; border: 3px dashed rgba(255,255,255,.75); }
.ctx-menu { position: absolute; z-index: 60; background: var(--paper); color: var(--ink); border: 1px solid var(--line2); border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.22); display: grid; min-width: 180px; padding: 4px; animation: rise var(--fast) var(--ease) backwards; }
.ctx-menu button { display: flex; align-items: center; gap: 8px; text-align: start; background: none; border: 0; padding: 7px 10px; border-radius: 6px; cursor: pointer; font-size: 13px; transition: background var(--fast); }
.ctx-menu button:hover { background: var(--soft); }
.cast-list { display: grid; gap: 40px; align-content: center; height: 100%; font-size: 36px; }
.cl-artists { display: flex; flex-wrap: wrap; gap: 16px 40px; }
.cl-faces { display: flex; flex-wrap: wrap; gap: 26px 18px; }
.cl-faces figure { margin: 0; display: grid; justify-items: center; gap: 12px; text-align: center; }
.cl-ph { display: grid; place-items: center; border-radius: 50%; overflow: hidden; box-shadow: 0 0 0 6px var(--c), 0 12px 30px rgba(0,0,0,.35); font-family: 'Secular One', sans-serif; }
.cl-ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cl-faces figcaption { font-size: 26px; line-height: 1.15; }
.cl-artists i { display: inline-block; width: 24px; height: 24px; border-radius: 50%; margin-inline-end: 12px; vertical-align: middle; }
.cl-groups { display: flex; flex-wrap: wrap; gap: 14px 44px; }
.cl-total { font-size: 50px; }

/* ---------- the looks' decoration (positions and sizes in slide units) */
.d-bgimg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; pointer-events: none; }
.d-foot { position: absolute; left: 40px; right: 40px; bottom: 20px; height: 26px; display: flex; justify-content: space-between; align-items: center; font-size: 17px; letter-spacing: .06em; opacity: .75; z-index: 2; pointer-events: none; }
.d-foot b { font-weight: 600; }
.d-rule { position: absolute; height: 10px; z-index: 2; }
.th-festigal .d-strip { position: absolute; left: 0; right: 0; top: 0; z-index: 1; }
.th-festigal .d-strip i { position: absolute; left: 0; right: 0; bottom: -10px; height: 10px; }
.th-poster .d-fade { position: absolute; inset: 0; z-index: 1; background: linear-gradient(to top, rgba(0,0,0,.88) 0%, rgba(0,0,0,.55) 32%, rgba(0,0,0,0) 62%); pointer-events: none; }
.th-poster .d-bar { position: absolute; width: 240px; height: 16px; z-index: 2; }
.th-numeral .d-numeral { position: absolute; left: -10px; bottom: -150px; font-family: 'Karantina', 'Secular One', sans-serif; font-weight: 700; font-size: 1080px; line-height: 1; -webkit-text-stroke-width: 6px; letter-spacing: -.02em; z-index: 1; pointer-events: none; user-select: none; }
.th-numeral .d-edge { position: absolute; right: 0; top: 0; bottom: 0; width: 16px; z-index: 2; }
.th-lookbook { background-image: radial-gradient(rgba(0,0,0,.035) 1px, transparent 1.4px) !important; background-size: 18px 18px !important; }
.th-lookbook .d-scribble { position: absolute; z-index: 2; overflow: visible; }
.th-lookbook .t-image .si-clip, .th-lookbook .t-video .si-clip { border: 12px solid #fff; border-bottom-width: 12px; box-shadow: 0 10px 24px rgba(40,30,15,.22), 0 2px 4px rgba(40,30,15,.18); border-radius: 0; }
.th-lookbook .t-image:not(.cutout)::before, .th-lookbook .t-video::before { content: ''; position: absolute; z-index: 2; top: -16px; left: calc(50% - 54px); width: 108px; height: 34px; background: rgba(255, 236, 170, .78); transform: rotate(-3deg); box-shadow: 0 1px 2px rgba(0,0,0,.1); }
.th-lookbook .t-image.cutout .si-clip { border: 0; box-shadow: none; filter: drop-shadow(0 10px 14px rgba(40,30,15,.28)); }
.th-lookbook .si-badge.ok { background: none; border: 4px solid #138a52; color: #138a52; transform: rotate(-12deg); }
.th-tech .d-grid { position: absolute; inset: 0; z-index: 0; background-image: linear-gradient(rgba(140,180,255,.07) 1px, transparent 1px), linear-gradient(90deg, rgba(140,180,255,.07) 1px, transparent 1px); background-size: 40px 40px; pointer-events: none; }
.th-tech .d-panel { position: absolute; left: 1120px; right: 30px; top: 30px; bottom: 30px; border: 2px solid; border-radius: 4px; background: rgba(255,255,255,.035); z-index: 1; }
.th-tech .d-frame { position: absolute; left: 40px; top: 40px; width: 1050px; height: 820px; z-index: 1; pointer-events: none;
  background: linear-gradient(var(--acc), var(--acc)) left top / 40px 3px no-repeat, linear-gradient(var(--acc), var(--acc)) left top / 3px 40px no-repeat,
    linear-gradient(var(--acc), var(--acc)) right top / 40px 3px no-repeat, linear-gradient(var(--acc), var(--acc)) right top / 3px 40px no-repeat,
    linear-gradient(var(--acc), var(--acc)) left bottom / 40px 3px no-repeat, linear-gradient(var(--acc), var(--acc)) left bottom / 3px 40px no-repeat,
    linear-gradient(var(--acc), var(--acc)) right bottom / 40px 3px no-repeat, linear-gradient(var(--acc), var(--acc)) right bottom / 3px 40px no-repeat; }
.th-tech .d-row { position: absolute; z-index: 2; border-top: 1px solid rgba(255,255,255,.18); padding-top: 6px; font-size: 17px; letter-spacing: .12em; color: var(--sub); }
.th-tech .d-meta { display: grid; gap: 2px; }
.th-tech .d-meta b { color: var(--ink); font-weight: 500; font-size: 22px; letter-spacing: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.th-editorial .d-hair { position: absolute; height: 2px; z-index: 2; opacity: .85; }
.th-editorial .d-vrule { position: absolute; left: 860px; top: 70px; bottom: 70px; width: 1px; opacity: .25; z-index: 1; }
.th-editorial .d-dot { position: absolute; left: 852px; top: 58px; width: 17px; height: 17px; border-radius: 50%; z-index: 2; }
.th-editorial .t-image .si-clip { border-radius: 0; }
.th-spotlight .d-spot { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.th-spotlight .d-floor { position: absolute; left: 0; right: 0; bottom: 0; height: 300px; z-index: 0; background: radial-gradient(ellipse 60% 70% at 50% 100%, rgba(255,255,255,.07), transparent 70%); pointer-events: none; }
.th-band .d-band { position: absolute; top: 0; right: 0; height: 900px; z-index: 1; }

/* ---------- the strip and small slides */
.mini { position: relative; overflow: hidden; background: #000; border-radius: 4px; flex: none; }
.mini-in { position: absolute; top: 0; left: 0; width: 1600px; height: 900px; transform-origin: 0 0; pointer-events: none; }
.cut-mini { display: grid; place-items: center; color: #fff; width: 120px; height: 68px; background: #2a2a2e; }
.bb-strip { display: flex; gap: 12px; overflow-x: auto; padding: 6px 4px 10px; scroll-snap-type: x proximity; scrollbar-width: thin; }
.st-it { position: relative; display: grid; gap: 5px; width: 120px; flex: none; text-decoration: none; font-size: 11.5px; color: var(--muted); scroll-snap-align: center; transition: color var(--fast), transform var(--fast) var(--ease); }
.st-it:hover { transform: translateY(-2px); color: var(--ink); }
.st-it span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-it .mini, .st-it .cut-mini { transition: outline-color var(--fast), box-shadow var(--fast); outline: 2px solid transparent; outline-offset: 2px; }
.st-it.st-on .mini, .st-it.st-on .cut-mini { outline-color: var(--ink); }
.st-it.st-on { color: var(--ink); font-weight: 500; }
.st-it .si-new { top: -5px; left: -5px; width: 12px; height: 12px; border-width: 2px; }
.st-count { position: absolute; top: 4px; right: 4px; font-style: normal; font-size: 10.5px; font-weight: 600; background: rgba(0,0,0,.66); color: #fff; padding: 0 5px; border-radius: 8px; line-height: 16px; }
.st-count.all { background: #138a52; }

/* ---------- the inspector */
.bb-panel { border: 1px solid var(--line); border-radius: 12px; background: var(--paper); position: sticky; top: calc(var(--tally) + var(--nav) + 8px); max-height: calc(100vh - var(--tally) - var(--nav) - 24px); display: flex; flex-direction: column; overflow: hidden; animation: rise var(--mid) var(--ease) backwards; }
.bp-tabs { display: flex; gap: 2px; padding: 5px; border-bottom: 1px solid var(--line); background: var(--soft); }
.bp-tab { flex: 1; height: 34px; border: 0; background: none; border-radius: 7px; cursor: pointer; color: var(--muted); display: grid; place-items: center; position: relative; transition: background var(--fast), color var(--fast); }
.bp-tab:hover { color: var(--ink); background: var(--soft2); }
.bp-tab.on { background: var(--paper); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.1); }
.bp-tab b { position: absolute; top: 2px; inset-inline-end: 4px; font-size: 10px; min-width: 15px; height: 15px; line-height: 15px; border-radius: 8px; background: var(--ink); color: #fff; padding: 0 3px; }
.bp-body { overflow: auto; padding: 12px; animation: sw-in var(--mid) var(--ease) backwards; }
.bp-sec { display: grid; gap: 10px; }
.bp-sec .lbl { margin: 2px 0 0; }
.bp-h { display: flex; align-items: center; gap: 6px; font-size: 13px; font-family: var(--body); font-weight: 600; color: var(--ink2); margin-top: 6px; }
.tool-row { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.tool-row .sep, .arr-tools .sep { width: 1px; height: 20px; background: var(--line); margin: 0 3px; }
.tool-row input[type=range] { flex: 1; min-width: 70px; }
.it-head { display: flex; align-items: center; gap: 8px; }
.state-box { display: grid; gap: 8px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.text-tools { display: grid; gap: 8px; }
.ok-t { color: var(--ok); display: flex; gap: 5px; align-items: baseline; margin: 0; }
.swatch { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line2); cursor: pointer; padding: 0; flex: none; transition: transform var(--fast) var(--ease), box-shadow var(--fast); }
.swatch:hover { transform: scale(1.1); }
.swatch.on { box-shadow: 0 0 0 2px var(--paper), 0 0 0 4px var(--ink); }
.swatch.none { background: linear-gradient(135deg, #fff 45%, var(--red) 46%, var(--red) 54%, #fff 55%); }
.swatch.big { width: 34px; height: 34px; cursor: default; }
.swatch.auto { position: relative; }
.swatch.auto::after { content: 'A'; position: absolute; inset: 0; display: grid; place-items: center; font-size: 12px; font-weight: 600; color: var(--paper); mix-blend-mode: difference; }
.cpick { position: relative; }
.cpick-btn { display: inline-flex; align-items: center; gap: 2px; height: 30px; padding: 0 4px 0 6px; border: 1px solid var(--line2); border-radius: 15px; background: var(--paper); cursor: pointer; }
.cpick-btn .swatch { width: 20px; height: 20px; }
.cpick-pop { position: absolute; z-index: 70; top: calc(100% + 6px); inset-inline-end: 0; width: 248px; padding: 10px; display: grid; gap: 8px; background: var(--paper); border: 1px solid var(--line2); border-radius: 12px; box-shadow: 0 14px 36px rgba(0,0,0,.18);
  opacity: 0; transform: translateY(-4px) scale(.98); transform-origin: top; pointer-events: none; transition: opacity var(--fast), transform var(--fast) var(--ease); }
.cpick-pop.in { opacity: 1; transform: none; pointer-events: auto; }
.cp-row { display: flex; flex-wrap: wrap; gap: 6px; }
.cp-custom { display: grid; grid-template-columns: auto 1fr; gap: 8px; align-items: center; }
.cp-sliders { display: grid; gap: 6px; }
.cp-sliders input { -webkit-appearance: none; appearance: none; height: 12px; border-radius: 6px; }
.cp-sliders .hue { background: linear-gradient(90deg, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00); }
.cp-sliders .light { background: linear-gradient(90deg, #000, hsl(var(--h), 80%, 50%), #fff); }
.cp-sliders input::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 2px solid #111; }
.cp-hex { grid-column: 1 / -1; height: 30px; }
.bp-counts { display: flex; gap: 6px; }
.bp-counts span { flex: 1; display: grid; justify-items: center; padding: 8px 4px; border-radius: 8px; background: var(--soft); }
.bp-counts b { font-size: 22px; font-family: var(--head); line-height: 1.1; font-weight: 400; }
.bp-counts i { font-style: normal; font-size: 11px; color: var(--muted); }
.bp-counts .ok b { color: var(--ok); } .bp-counts .warn b { color: var(--warn); }
.bp-bar { height: 6px; border-radius: 3px; background: var(--soft2); overflow: hidden; }
.bp-bar i { display: block; height: 100%; background: var(--ok); border-radius: 3px; transition: width var(--mid) var(--ease); }
.exp-bar i { background: var(--ink); }
.bp-log { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 13px; }
.bp-log li { display: grid; padding-bottom: 6px; border-bottom: 1px solid var(--line); animation: rise var(--mid) var(--ease) backwards; }
.bp-log .muted { font-size: 11.5px; }
.tray { display: flex; gap: 8px; flex-wrap: wrap; }
.tray-it { width: 76px; height: 54px; padding: 0; border: 1px solid var(--line2); border-radius: 6px; overflow: hidden; cursor: grab; background: #000; animation: si-in var(--mid) var(--ease) backwards; transition: transform var(--fast); }
.tray-it:hover { transform: scale(1.05); }
.tray-it img { width: 100%; height: 100%; object-fit: cover; }
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.gal-it { display: grid; gap: 4px; padding: 3px; border: 2px solid transparent; border-radius: 8px; background: none; cursor: pointer; font-size: 12px; text-align: center; transition: border-color var(--fast), transform var(--fast) var(--ease); }
.gal-it:hover { transform: translateY(-2px); border-color: var(--line2); }
.gal-it.on { border-color: var(--ink); }
.gal-it .mini { width: 100% !important; }
.pal { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pal-c { position: relative; }
.pal-x { position: absolute; top: -6px; inset-inline-end: -6px; width: 16px; height: 16px; border-radius: 50%; border: 0; background: var(--ink); color: #fff; display: grid; place-items: center; cursor: pointer; padding: 0; opacity: 0; transition: opacity var(--fast); }
.pal-c:hover .pal-x { opacity: 1; }
.font-list { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.font-it { display: grid; gap: 0; padding: 8px 6px; border: 1px solid var(--line2); border-radius: 8px; background: var(--paper); cursor: pointer; font-size: 22px; line-height: 1.15; transition: border-color var(--fast), background var(--fast); }
.font-it small { font-family: var(--body); font-weight: 400; font-size: 11px; color: var(--muted); }
.font-it.on { border-color: var(--ink); background: var(--soft); }
.bg-pick { display: flex; gap: 6px; flex-wrap: wrap; }
.bg-im { width: 64px; height: 40px; padding: 0; border: 2px solid transparent; border-radius: 5px; overflow: hidden; cursor: pointer; }
.bg-im.on { border-color: var(--ink); }
.bg-im img { width: 100%; height: 100%; object-fit: cover; }
.arr-list { display: grid; gap: 8px; }
.arr-opt { display: grid; gap: 4px; justify-items: center; border: 2px solid transparent; background: none; padding: 3px; border-radius: 8px; cursor: pointer; font-size: 12px; transition: border-color var(--fast), transform var(--fast) var(--ease); }
.arr-opt:hover { border-color: var(--ink); transform: translateY(-1px); }
.arch-list { display: flex; flex-wrap: wrap; gap: 12px; }
.arch-it { display: grid; gap: 4px; width: 124px; text-decoration: none; color: inherit; animation: rise var(--mid) var(--ease) backwards; }
.arch-it img { width: 124px; height: 80px; object-fit: cover; border-radius: 5px; background: #000; }
.arch-t { font-size: 13px; padding: 8px; background: var(--soft); border-radius: 5px; overflow: hidden; max-height: 80px; }
.hist { display: grid; gap: 6px; width: 100%; animation: rise var(--fast) var(--ease) backwards; }
.hist-it { display: grid; grid-template-columns: 64px 1fr auto; gap: 8px; align-items: center; }
.hist-it img { width: 64px; height: 42px; object-fit: cover; border-radius: 4px; background: #000; }
/* shadow and glow: the settings fold open under the three choices; the colour picker may leave the box once it is open */
.m-edit .si-text, .m-edit .si-clip, .m-edit .si-shape, .m-edit .si-stage, .m-edit .si-link, .m-edit .si-artists, .m-edit .cast-list { transition: text-shadow var(--fast) var(--ease), filter var(--fast) var(--ease); }
.fx-live .si-text, .fx-live .si-clip, .fx-live .si-shape, .fx-live .si-stage, .fx-live .si-link, .fx-live .si-artists, .fx-live .cast-list { transition: none !important; }
.fx-reset { display: inline-flex; animation: fade var(--mid) var(--ease); }
.fx-tools { display: grid; gap: 6px; padding-top: 10px; border-top: 1px solid var(--line); }
.fx-more { display: grid; grid-template-rows: 0fr; opacity: 0; transition: grid-template-rows var(--mid) var(--ease), opacity var(--mid) var(--ease); }
.fx-more.in { grid-template-rows: 1fr; opacity: 1; }
.fx-in { min-height: 0; overflow: hidden; display: grid; gap: 6px; animation: sw-in var(--mid) var(--ease) backwards; }
.fx-more.settled .fx-in { overflow: visible; }
.fx-row { display: grid; grid-template-columns: 44px 1fr; align-items: center; gap: 8px; min-height: 30px; }
.fx-row input[type=range] { width: 100%; min-width: 0; }
.fx-dial { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line2); background: radial-gradient(circle, var(--soft2) 0 3px, transparent 3.5px), var(--soft); display: grid; place-items: center; cursor: pointer; touch-action: none; transition: box-shadow var(--fast); }
.fx-dial:hover, .fx-dial:focus-visible { box-shadow: 0 0 0 3px var(--soft2); outline: none; }
.fx-dial i { width: 10px; height: 10px; border-radius: 50%; background: var(--ink); transition: transform var(--fast) var(--ease); }
.marks { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.marks li { display: flex; gap: 6px; align-items: center; }
.marks input { width: 64px !important; }
.np-mini { gap: 8px; }
.npm-head { display: flex; align-items: baseline; gap: 8px; font-size: 16px; }
.npm-idx { font-family: var(--head); font-size: 22px; color: var(--red); }
.npm-head b { flex: 1; font-family: var(--head); font-weight: 400; font-size: 19px; line-height: 1.2; }
.npm-songs { margin: 0; padding-inline-start: 20px; display: grid; gap: 3px; font-size: 13.5px; }
.npm-songs li span:last-child { margin-inline-start: 8px; }
.npm-els { margin: 0; padding-inline-start: 18px; font-size: 13.5px; }
.npm-t { margin: 0; font-size: 13.5px; white-space: pre-wrap; line-height: 1.5; }
.bb-player:empty { display: none; }
.link-form { display: grid; gap: 4px; }
.cut-page { display: grid; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; animation: rise var(--mid) var(--ease) backwards; }
.cut-nums { display: flex; flex-wrap: wrap; gap: 14px; }
.cut-num { display: grid; gap: 4px; text-decoration: none; color: inherit; width: 180px; transition: transform var(--fast) var(--ease); }
.cut-num:hover { transform: translateY(-2px); }
.cut-group { display: grid; gap: 8px; }
.pub-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.ver-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; max-height: 320px; overflow: auto; }
.ver-list li { display: flex; gap: 8px; align-items: center; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--line); animation: rise var(--mid) var(--ease) backwards; }
.ver-list li > span { display: grid; }

/* ---------- presenting */
.present { position: fixed; inset: 0; z-index: 200; background: #000; color: #fff; display: grid; animation: fade var(--mid) var(--ease) backwards; user-select: none; }
.pr-stage { position: relative; display: grid; place-items: center; overflow: hidden; cursor: pointer; }
.pr-cur { grid-area: 1 / 1; display: grid; place-items: center; animation: sw-in .35s var(--ease) backwards; }
.pr-cur.from-l { animation: pr-l .38s var(--ease) backwards; } .pr-cur.from-r { animation: pr-r .38s var(--ease) backwards; }
.present-slide { position: relative; overflow: hidden; }
.pr-preload { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }
.pr-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(255,255,255,.08); }
.pr-bar i { display: block; height: 100%; background: rgba(255,255,255,.55); transition: width var(--mid) var(--ease); margin-inline-start: auto; }
.present-count { position: absolute; bottom: 12px; left: 18px; color: rgba(255,255,255,.45); font-size: 13px; }
.present-x { position: absolute; top: 12px; left: 12px; background: rgba(255,255,255,.12); color: #fff; border: 0; width: 42px; height: 42px; border-radius: 50%; cursor: pointer; display: grid; place-items: center; z-index: 5; opacity: .5; transition: opacity var(--fast), background var(--fast); }
.present-x:hover { opacity: 1; background: rgba(255,255,255,.22); }
.pr-arrows { position: absolute; bottom: 10px; right: 14px; display: flex; gap: 6px; opacity: 0; transition: opacity var(--mid); z-index: 5; }
.present:hover .pr-arrows { opacity: 1; }
.pr-arrow { width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255,255,255,.14); color: #fff; display: grid; place-items: center; cursor: pointer; transition: background var(--fast); }
.pr-arrow:hover { background: rgba(255,255,255,.26); }
.pr-arrow:disabled { opacity: .25; }
.pr-count { position: absolute; top: 14px; right: 16px; display: flex; align-items: center; gap: 6px; background: rgba(0,0,0,.55); color: #fff; padding: 4px 6px 4px 10px; border-radius: 16px; font-size: 13px; z-index: 5; }
.pr-count button { border: 0; background: #138a52; color: #fff; border-radius: 12px; padding: 3px 10px; cursor: pointer; font-size: 12px; }
.present.presenter { grid-template-columns: minmax(0, 1fr) 360px; background: #0d0d10; }
.present.presenter .pr-stage { cursor: default; }
.pr-side { display: grid; align-content: start; gap: 14px; padding: 18px; overflow: auto; background: #16161a; border-inline-start: 1px solid rgba(255,255,255,.08); }
.pr-clock { display: flex; justify-content: space-between; align-items: baseline; }
.pr-clock b { font-family: var(--head); font-size: 40px; font-weight: 400; color: #fff; }
.pr-clock span { color: #888; font-size: 18px; }
.pr-next { display: grid; gap: 6px; }
.pr-side .muted { color: #9a9aa2; }
.pr-side .btn { color: var(--ink); }
.present.presenter .present-x { left: 372px; }
.present.presenter .present-count { left: 18px; }
.pr-info { display: grid; gap: 8px; color: #e8e8ee; }
.pri-head { display: flex; align-items: baseline; gap: 10px; }
.pri-idx { font-family: var(--head); font-size: 26px; color: var(--red); }
.pri-head b { flex: 1; font-family: var(--head); font-weight: 400; font-size: 22px; line-height: 1.2; }
.present.portrait { grid-template-rows: auto; align-content: start; overflow: auto; }
.present.portrait .pr-stage { place-items: start center; align-content: start; padding-top: 70px; gap: 18px; }
.present.portrait .pr-info { padding: 0 18px 90px; width: 100%; }
.present.portrait .pr-arrows { opacity: 1; position: fixed; bottom: 16px; right: auto; left: 50%; transform: translateX(-50%); }
.present.portrait .present-count { position: fixed; }
.pr-setup { display: grid; gap: 10px; }
.pr-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pr-mode { display: grid; gap: 4px; justify-items: start; text-align: start; padding: 14px; border: 2px solid var(--line2); border-radius: 12px; background: var(--paper); cursor: pointer; transition: border-color var(--fast), background var(--fast), transform var(--fast) var(--ease); }
.pr-mode:hover { transform: translateY(-1px); }
.pr-mode b { font-family: var(--head); font-weight: 400; font-size: 18px; }
.pr-mode span { color: var(--muted); font-size: 13px; }
.pr-mode.on { border-color: var(--ink); background: var(--soft); }
.pr-artists { display: flex; flex-wrap: wrap; gap: 6px; }
.pr-artists .chip { display: inline-flex; align-items: center; gap: 6px; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; }
.pr-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 0 12px; max-height: 240px; overflow: auto; padding: 6px; border: 1px solid var(--line); border-radius: 8px; }
.pr-pick > .row { grid-column: 1 / -1; }
.pr-opts { display: grid; gap: 2px; }

/* ---------- the phone: a card per number */
.bible.phone { gap: 14px; }
.pb-head { display: flex; align-items: center; gap: 8px; }
.pb-jump { display: flex; gap: 6px; overflow-x: auto; position: sticky; top: var(--tally); z-index: 5; background: var(--paper); padding: 6px 0; scrollbar-width: none; }
.pb-jump a { flex: none; min-width: 34px; height: 34px; display: grid; place-items: center; border-radius: 17px; border: 1px solid var(--line2); text-decoration: none; font-size: 14px; font-weight: 500; }
.pcard { display: grid; gap: 0; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; scroll-margin-top: calc(var(--tally) + 52px); animation: rise var(--mid) var(--ease) backwards; animation-delay: calc(var(--i) * 30ms); }
.pc-face { position: relative; overflow: hidden; border: 0; padding: 0; background: #000; cursor: pointer; display: block; }
.pc-body { display: grid; gap: 10px; padding: 14px; border-top: 4px solid var(--acc); }
.pc-title { display: flex; align-items: center; gap: 10px; }
.pc-title h2 { font-size: 22px; line-height: 1.2; }
.pc-idx { font-family: var(--head); font-size: 17px; padding: 2px 9px; border-radius: 6px; }
.pc-artists { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 15px; }
.pc-artists i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-inline-end: 6px; }
.pc-text { margin: 0; white-space: pre-wrap; font-size: 15px; }
.pc-pic { margin: 0; position: relative; }
.pc-pic button { display: block; width: 100%; padding: 0; border: 0; background: #000; border-radius: 8px; overflow: hidden; cursor: zoom-in; }
.pc-pic img { display: block; width: 100%; height: auto; }
.pc-pic figcaption { font-size: 13px; color: var(--muted); padding-top: 4px; }
.pc-vid { position: absolute; top: 10px; right: 10px; width: 38px; height: 38px; border-radius: 50%; background: rgba(0,0,0,.6); color: #fff; display: grid; place-items: center; pointer-events: none; }
.pc-link { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border: 1px solid var(--line2); border-radius: 8px; text-decoration: none; }
.pc-tray { display: flex; gap: 8px; flex-wrap: wrap; }
.pz { position: fixed; inset: 0; z-index: 210; background: rgba(0,0,0,.94); display: grid; place-items: center; animation: fade var(--mid) backwards; padding: 12px; }
.pz img, .pz video { max-width: 100%; max-height: 86vh; object-fit: contain; animation: si-in var(--mid) var(--ease) backwards; }
.pz p { color: #ddd; text-align: center; }

@media (max-width: 1180px) { .bb-desk { grid-template-columns: 48px minmax(0, 1fr) 260px; } .gallery { grid-template-columns: 1fr; } }
@media (max-width: 760px) {
  .pub-grid, .pr-modes { grid-template-columns: 1fr; }
  .present-btn { height: 34px; padding: 0 12px; }
}
@media (prefers-reduced-motion: reduce) { .present-btn::after { animation: none; } }
