/* Kandeel show deck — 41 scenes (ex-PowerPoint), same 2:1 stage sizing language as led.css (cqh/cqw of its own box). */
#deck { position: fixed; inset: 0; z-index: 25; display: none; background: #000; }
#deck.on { display: grid; place-items: center; }
/* MFZ_PA 2026-11-16 (MFZ sent the real JW Marriott stage photo — "respect the LED screen size as per
   the stage design"): REVERTS the 2026-11-14 "10x3 m" fork. Measuring the actual photo (screen
   left/right/top/bottom edges against the visible truss + stage floor) gives ~1.9:1, matching the
   ORIGINAL 8x4 m / 2:1 assumption, not the 10x3 m (3.33:1) ultra-wide banner this was changed to.
   The 10x3 fork was never corroborated by a real photo — this one is. Back to 2:1 (min(100vw,200vh) /
   min(50vw,100vh)). See the same photo-driven fix in led.css (#st, #speakercard .spk-stage). */
.dwrap { position: relative; width: min(100vw, 200vh); height: min(50vw, 100vh); /* MFZ_PA 2026-11-16: 8x4 m / 2:1, confirmed against real stage photo (was 10x3 m, 2026-11-14 fork, unconfirmed) */ container-type: size; overflow: hidden;
  background: radial-gradient(65% 85% at 50% 40%, #2a1e15 0%, transparent 65%), linear-gradient(180deg, var(--esp2), var(--esp) 75%); }
#deckfx { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 8; }
/* MFZ_PA 2026-11-16 (MFZ: "lift data up, the speaker will be sitting in front of the screen"): the
   real stage photo shows the head table + 6 chairs covering roughly the BOTTOM 40-45% of the screen
   height. Old bottom inset (7cqh) let content run to ~93% down — straight into the blocked band.
   New bottom inset (46cqh) caps all .dcontent-flow content at ~54% down, with a safety margin above
   where seated speakers' heads/shoulders reach. Combined with the 2:1 revert above (a physically
   TALLER screen than the old 10:3 assumption), this still leaves a generous ~41cqh-tall content band. */
.dcontent { position: absolute; inset: 13cqh 7cqw 46cqh 7cqw; z-index: 2; display: flex; flex-direction: column; justify-content: center;
  animation: din .5s ease both; }
@keyframes din { from { opacity: 0; transform: translateY(1.6cqh); } to { opacity: 1; transform: none; } }

/* ── V3 image scenes (2026-11-15/16, MFZ: "the live /show must be VISUALLY IDENTICAL to
   Gridline_Press_Conference_v3_LED_Bilingual.pptx/pdf"). The approved v3 deck was designed ultra-wide
   (13.333×4in = 10:3), but the REAL confirmed stage (.dwrap above, photo-verified ~2:1) is proportionally
   TALLER than that banner. Cropping the 10:3 render to fit a 2:1 box would cut the logos sitting at its
   far left/right edges — not allowed ("no clipped... logos"). So .v3scene shows the FULL approved slide,
   uncropped and undistorted (background-size:contain), letterboxed on a flat backdrop colour matching
   each slide's own edge tone (brown for every scene except the cream pricing scene, i=12 — see the
   `.v3scene.cream` override and deck.js). Ken-Burns is a slow scale only (no pan) so the contained
   image never drifts off-centre or reveals a gap at its own edge.
   TRIED-AND-REVERTED (2026-11-15/16): a two-layer version (crisp contain-fit slide over a separate,
   oversized, blurred/darkened copy as a "fills the whole box" backdrop) looked better in theory but
   reliably rendered as garbled vertical colour bars across the WHOLE scene in headless Chromium the
   moment BOTH layers were visible together (each layer alone rendered perfectly — isolated-element
   screenshots proved it; only visible when composited simultaneously; reproduced with the backdrop as
   both a live CSS filter:blur() and a pre-blurred static jpg, so it wasn't the blur itself — looks like
   a compositing bug with two overlapping animated/background-image layers at this scale). A single flat
   colour is less fancy but cannot glitch the same way — not worth the risk two days before the event. */
#deck.k-v3img .dcontent { position: absolute !important; inset: 0 !important; animation: none !important; display: block !important; }
#deck.k-v3img .dhead { display: none; } /* baked slide already carries both wordmarks top-left/top-right */
/* the old animated welcome-skyline layer (cover-motion.css, only ever meant for the OLD cover scene)
   was bleeding through on top of the v3 cover render — old-show content on the approved design is
   exactly what this whole pass exists to eliminate, so force it off for every v3 image scene. */
#deck.k-v3img .cover-stage { display: none !important; }
#deck.k-v3img .showcredit { top: auto; bottom: 1.6cqh; right: 2.4cqw; font-size: 1.5cqh; opacity: .7; }
.v3scene { position: absolute; inset: 0; overflow: hidden; background: var(--esp); background-repeat: no-repeat;
  background-position: center; background-size: contain; }
.v3scene.cream { background-color: #F3E8DA; } /* matches s-12's own cream edge tone (deck.js THEME_CREAM) */
.v3scene.kb1 { animation: v3fadein .6s ease both, v3kbIn 26s ease-in-out infinite alternate; }
.v3scene.kb2 { animation: v3fadein .6s ease both, v3kbOut 26s ease-in-out infinite alternate; }
.v3scene.kb3 { animation: v3fadein .6s ease both, v3kbIn 32s ease-in-out infinite alternate; }
.v3scene.kb4 { animation: v3fadein .6s ease both, v3kbOut 32s ease-in-out infinite alternate; }
@keyframes v3fadein { from { opacity: 0; } to { opacity: 1; } }
@keyframes v3kbIn { from { transform: scale(1); } to { transform: scale(1.035); } }
@keyframes v3kbOut { from { transform: scale(1.035); } to { transform: scale(1); } }
/* film slot (scene 13) — real <video> autoplays right over its own poster frame, same contain-fit
   so nothing crops/stretches; poster stays visible for the single frame before playback starts. */
.v3filmvid { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; z-index: 1; }
/* MFZ_PA 2026-11-11: footer→header per MFZ (8x4m LED — stage/podium/heads hide the bottom band).
   Moved from bottom:2.6cqh to top:2.6cqh, same two elements, same mirrored corners (logo stays
   top-right, event line top-left — was bottom-right/bottom-left in RTL flex order, unchanged). */
.dhead { position: absolute; top: 2.6cqh; right: 4cqw; left: 4cqw; display: flex; justify-content: space-between; align-items: center;
  font-size: 2.4cqh; color: var(--muted); z-index: 4; }
/* MFZ_PA 2026-11-14 (MFZ: +50% on the show header logo) — was 4.4cqh, ×1.5. .dhead's own box has no
   explicit height, so it grows with this image (align-items:center); still clears .dcontent's top
   inset (13cqh) by a comfortable margin: 2.6cqh + 6.6cqh = 9.2cqh bottom edge, 3.8cqh to spare. */
.dlogo { height: 6.6cqh; width: auto; opacity: .85; }

.d-kicker { font-size: 3.6cqh; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 1.6cqh; }
.d-title { font-size: 9cqh; font-weight: 800; line-height: 1.4; padding: .06em 0; background: linear-gradient(180deg, var(--gold2), var(--gold) 55%, var(--bronze)); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; }
.d-sub { font-size: 4.2cqh; font-weight: 500; line-height: 1.5; color: var(--cream); margin-top: 2cqh; max-width: 80cqw; }
.d-note { font-size: 2.6cqh; color: var(--muted); margin-top: 2.4cqh; }
.d-tag { font-size: 3cqh; letter-spacing: .1em; color: var(--gold); margin-top: 2cqh; }

/* cover / thanks */
.k-cover .dcontent, .k-thanks .dcontent { align-items: center; text-align: center; justify-content: center; }
.k-cover .d-title, .k-thanks .d-title { font-size: 13cqh; }
.k-thanks .hotline { font-size: 3.4cqh; color: var(--cream); margin-top: 1.4cqh; }
.k-thanks .hotline b { color: var(--gold); font-weight: 800; }

/* guest (talk-show lower-third) */
.k-guest .dcontent { align-items: flex-start; justify-content: center; }
.g-name { font-size: 11cqh; font-weight: 800; color: var(--cream); line-height: 1.35; }
.g-title { font-size: 4cqh; color: var(--gold); margin-top: 1.4cqh; font-weight: 500; }
/* MFZ_PA 2026-11-11: bottom offset is relative to .dcontent's own box (cqh resolves against .dwrap,
   but .dcontent now has bottom:7cqh — total clearance from the real stage floor = 7+15=22cqh, clear
   of the bottom ~20% safe-zone). */
.g-sub { position: absolute; left: 7cqw; bottom: 15cqh; font-size: 3.2cqh; color: var(--muted); letter-spacing: .08em; }

/* mc question card */
.k-mc .dcontent { align-items: center; text-align: center; justify-content: center; gap: 2cqh; }
.mc-mark { font-size: 14cqh; font-weight: 900; color: var(--bronze); line-height: 1; }
.mc-q { font-size: 6.6cqh; font-weight: 700; line-height: 1.4; max-width: 86cqw; color: var(--cream); }
.mc-by { font-size: 2.8cqh; color: var(--gold); letter-spacing: .1em; margin-top: 1.4cqh; }

/* stat tiles */
.d-stats { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0,1fr); gap: 3cqw; margin-top: 3.4cqh; border-top: .22cqh solid rgba(207,196,177,.22); padding-top: 3cqh; }
.d-stats.wrap3 { grid-auto-flow: row; grid-template-columns: repeat(3,1fr); }
.d-stat b { display: block; font-size: 7cqh; font-weight: 800; color: var(--gold2); line-height: 1.05; font-variant-numeric: tabular-nums; }
.d-stat span { display: block; font-size: 2.6cqh; color: var(--muted); margin-top: .8cqh; line-height: 1.4; }
.d-companies { display: grid; grid-template-columns: repeat(5,1fr); gap: 1.6cqw; margin-top: 3cqh; }
.d-companies div { border: .18cqh solid rgba(207,196,177,.2); border-radius: 1cqh; padding: 1.4cqh 1cqw; text-align: center; }
.d-companies b { display: block; font-size: 2.6cqh; color: var(--cream); }
.d-companies span { display: block; font-size: 2cqh; color: var(--muted); margin-top: .5cqh; }

/* video placeholder slate */
.k-video .dcontent { align-items: center; text-align: center; justify-content: center; gap: 1.6cqh; }
.v-badge { font-size: 3cqh; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); border: .2cqh solid var(--bronze); border-radius: 99px; padding: .8cqh 2.4cqw; }
.v-icon { font-size: 10cqh; }

/* keypoints (6 numbered reasons) */
.d-bullets { display: grid; grid-template-columns: repeat(2,1fr); gap: 2cqh 3cqw; margin-top: 3cqh; }
.d-bullets .bl { display: flex; gap: 1.4cqw; align-items: flex-start; }
.d-bullets .bn { font-size: 4cqh; font-weight: 800; color: var(--bronze); flex: 0 0 auto; }
.d-bullets .bt b { display: block; font-size: 3cqh; color: var(--cream); font-weight: 700; }
.d-bullets .bt span { display: block; font-size: 2.4cqh; color: var(--muted); margin-top: .4cqh; }

/* gift round intro — mirrors led.css idle styling for continuity */
.k-gift .dcontent { align-items: center; text-align: center; justify-content: center; gap: 1.6cqh; }
.k-gift .d-title { font-size: 15cqh; }
.k-gift .d-sub { font-size: 5cqh; color: var(--gold); margin-top: 0; }
.k-gift .d-qr-hint { font-size: 2.8cqh; color: var(--muted); margin-top: 2.4cqh; }

/* round winner / champion */
.k-winner .dcontent { align-items: center; text-align: center; justify-content: center; gap: 1.4cqh; }
.k-winner .trophy { font-size: 10cqh; }
.k-winner .champ-name { font-size: 15cqh; font-weight: 900; line-height: 1.35; padding: .05em 0; max-width: 88cqw;
  background: linear-gradient(180deg, #fff6e3, var(--gold2) 40%, var(--gold) 75%, var(--bronze)); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 3cqh rgba(224,176,119,.45)); }
.k-winner .champ-ph { font-size: 6cqh; color: var(--muted); }

/* MFZ_PA 2026-11-12: persistent "now presenting" corner badge — see led.html/deck.mjs comments.
   Placed top-left in the ~6cqh gap between .dhead and .dcontent (never the bottom band — the
   2026-11-11 lesson on this same stage: stage/podium/heads at the live 8x4m LED hide the bottom). */
#spkBadge { position: absolute; top: 7.6cqh; left: 4cqw; z-index: 6; display: none; align-items: center; gap: 1.4cqw;
  background: rgba(21,16,12,.55); border: .14cqh solid rgba(224,176,119,.35); border-radius: 99px;
  padding: .5cqh 2.2cqw .5cqh .5cqh; backdrop-filter: blur(6px); opacity: 0; transition: opacity .35s ease; }
#spkBadge.on { display: flex; opacity: 1; }
#spkBadge .spkb-photo { width: 5.6cqh; height: 5.6cqh; border-radius: 50%; overflow: hidden; flex: 0 0 auto;
  border: .1cqh solid rgba(224,176,119,.4); background: var(--esp); }
/* MFZ_PA 2026-11-12 (v3 corporate pass): badge draws from the same rembg cutout as #speakercard
   (deck.js cutoutUrl()) but neutral B&W, no duotone tint / glow — consistent with the main card. */
#spkBadge .spkb-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center top; display: block;
  filter: grayscale(1) contrast(1.08) brightness(1.03); }
#spkBadge .spkb-nameAr { font-size: 2.3cqh; font-weight: 700; color: var(--cream); white-space: nowrap; }

/* FORK v2 (2026-11-15): "partners" scene — The Power Behind / شركاء النجاح, grid of 4 real consultant
   logos (deck-data.mjs PARTNERS).
   MFZ_PA 2026-11-15 v5 (second rejection, same day — MFZ: "No, not accepted. Use same presentation
   theme tone. Remove logos BG, change logos colors to match the theme!!"). v4's fix (above, see git
   history) kept the logos' original client colours (navy/black/red/green) and solved their contrast
   problem by flipping this ONE scene to a light cream surface — exactly the "looks like a pasted-in
   PowerPoint slide" effect MFZ rejected: a light island in an otherwise dark-espresso show. v5 fixes
   the actual root cause instead of working around it: tools/recolor-partners-gold.py (+
   tools/recolor-htco.py for the low-res HTCO source, which needed a potrace vector pass to avoid
   jagged upscale edges) recolours all 4 PNGs in place — real alpha transparency already existed
   around each mark (confirmed, untouched by this pass), so the "remove BG" part was already correct
   from v4; what changes here is the COLOUR: each logo's own luminance range is normalized onto the
   deck's own 3-stop gold ramp (--bronze/--gold/--gold2, the exact gradient already used for
   `.d-title`/"Gridline."/stat numbers elsewhere), preserving each mark's internal contrast (frame vs.
   fill, name vs. caption) so nothing reads as a flat silhouette — no redraw, no re-typesetting, same
   letterforms. Mohamed Talaat's logo (previously white-on-transparent, invisible on light v4's cream
   surface, fine on dark but mismatched vs. the other 3's original colour) now matches the same gold
   family instead of needing a client re-send. Net effect: this scene no longer needs its own special
   surface at all — it now uses the SAME dark-espresso `.dwrap` background as every other scene (no
   override below), which is the "same presentation theme tone" MFZ asked for.
   MFZ_PA 2026-11-15 v6 (THIRD rejection, same day — MFZ angry: "Use Photoshop on the NUC, not Python").
   v5's numpy/potrace pass (tools/recolor-partners-gold.py / recolor-htco.py, now unused/kept for
   history only) is OUT. v6 redoes all 4 logos from scratch, pixels generated entirely in real Adobe
   Photoshop 27 on the NUC via COM/ExtendScript (ArtLayer.duplicate/adjustLevels/applyGaussianBlur +
   a real alpha channel built from a luminance threshold, selection.load/clear for background removal,
   selection.fill(..., preserveTransparency) for recolor, Preserve-Details upscale for the two small
   sources) — see memory/notes.md for the exact NUC pipeline + the nuc_photoshop_jsx stale-process
   workaround (drives Photoshop via nuc_powershell directly). Sources this time: the ORIGINAL
   higher-res client uploads in assets/client/ (not the already-degraded v1 partners/ crops) — ES in
   particular came from a clean 1922x2228 original instead of the cropped 985x240 version with a
   visible white card edge. Same 2-tone split as v5 (primary mark = --gold #92ADBB flat fill, caption/
   secondary line = --bronze #A99884 flat fill, both sampled straight from this file's own vars) but a
   true flat Color Overlay per region instead of a continuous luminance gradient-map, which is what
   actually gives "one consistent gold set" — no per-logo luminance-curve drift. ES's white card fill
   is now genuinely deleted (transparent, showing the stage through it) instead of recoloured pale —
   fixes the "looks like a sticker" box effect. HTCO's "HANY TAWFIK CONSULTING OFFICE" tagline (a
   handful of pixels tall in the only source that exists, 159×60) is dropped from the raster entirely
   rather than shipped as an illegible smear — the same string is already rendered as real, crisp HTML
   text via PARTNERS[].nameAr/nameEn + .ptile-cap (deck-data.mjs), so nothing is actually lost. */
.k-partners .dcontent { align-items: center; text-align: center; justify-content: center; }
.d-partners { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6cqw; margin-top: 3.4cqh; width: 100%; }
/* no card/background/border on the tile — the now gold-on-dark logos sit directly on the scene's
   normal .dwrap background, same as every other element in the deck. */
.ptile { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.4cqh; padding: 2.4cqh 1.2cqw; min-height: 27cqh; }
.ptile img { max-width: 92%; max-height: 15cqh; object-fit: contain;
  /* uniform, subtle depth on all 4 equally — a warm glow suited to a DARK surface (the old v4 filter
     here was a dark drop-shadow, which only worked against the light cream scene it was paired with). */
  filter: drop-shadow(0 0 .35cqh rgba(0,0,0,.45)); }
.ptile-cap { font-size: 2cqh; line-height: 1.4; color: var(--muted); opacity: .85; }
/* MFZ_PA 2026-11-16 (dual-language pass): the logos themselves already carry their English wordmark,
   but the caption under them was Arabic-only — add the English company name too (nameEn was already
   in the data, just unused except as an img alt attribute). */
.ptile-cap-en { font-size: 1.6cqh; line-height: 1.4; color: var(--muted); opacity: .62; margin-top: .2cqh; }
/* MFZ_PA 2026-11-15 v5 (equal optical weight pass, re-checked against the new gold renders — the 4
   source files still have wildly different aspect ratios/ink density even after recolouring): ES is a
   tall bold portrait mark (reads heavy already, trimmed down slightly); HTCO is a thin wordmark
   (boosted, and now vector-traced so it stays crisp at this size); Talaat is mostly whitespace inside
   its own bounding box (boosted most). DMA keeps the 15cqh baseline. */
.ptile img[src*="es-engineering-solutions"] { max-height: 16cqh; }
.ptile img[src*="htco-hany-tawfik"] { max-height: 15.5cqh; }
.ptile img[src*="mohamed-talaat-architects"] { max-height: 18cqh; }

/* FORK v2 (2026-11-15): live per-speaker Q&A card — speaker picked from /admin → "أسئلة الصحافة",
   stepping through their real client questions (★ = priority, always first). No speaker picked yet
   falls back to the plain v1 "جلسة الأسئلة والإجابات" title/sub intro (no extra markup needed, handled
   by deck.js's own if/else — this CSS only styles the populated state). */
.k-qa .dcontent { justify-content: center; gap: 0; }
.qa-top { display: flex; align-items: baseline; justify-content: space-between; gap: 2cqw; }
.qa-progress { font-size: 2.6cqh; color: var(--muted); font-variant-numeric: tabular-nums; }
.qa-star { display: inline-block; margin-top: 2cqh; font-size: 2.4cqh; font-weight: 800; letter-spacing: .06em; color: var(--esp); background: linear-gradient(180deg, var(--gold2), var(--gold)); border-radius: 99px; padding: .5cqh 1.8cqw; width: fit-content; }
.qa-q { font-size: 6cqh; font-weight: 700; line-height: 1.45; color: var(--cream); margin-top: 2.6cqh; max-width: 90cqw; }
.qa-sp { display: flex; align-items: center; gap: 1.6cqw; margin-top: 4cqh; padding-top: 2.6cqh; border-top: .18cqh solid rgba(207,196,177,.22); }
/* MFZ_PA 2026-11-15 v5: the v4 cream chip behind this logo was the same "white box behind a logo"
   treatment MFZ rejected on the partners slide (see deck.css's big partners-scene comment above) —
   just a smaller instance of the identical problem. Now that the 4 partner logos are recoloured into
   the deck's own gold family (tools/recolor-partners-gold.py / recolor-htco.py), they read fine
   directly on the normal dark espresso stage, same as everywhere else — chip removed, logo sits
   straight on the scene background like .qa-sp-name/.qa-sp-title next to it. */
.qa-sp-logo { height: 7.8cqh; max-width: 21cqw; object-fit: contain; }
.qa-sp-logo[src*="mohamed-talaat-architects"] { height: 9.4cqh; }
.qa-sp-logo[src*="es-engineering-solutions"] { height: 9cqh; }
.qa-sp-name { font-size: 3.4cqh; font-weight: 800; color: var(--gold2); }
.qa-sp-title { font-size: 2.3cqh; color: var(--muted); margin-top: .4cqh; }

/* blackout / logo hold */
#blackout { position: fixed; inset: 0; z-index: 90; display: none; align-items: center; justify-content: center; background: #000; }
#blackout.on { display: flex; }
#blackout img { width: 16vw; max-width: 260px; min-width: 120px; opacity: .92; }
