/* ================================================================
   SUPERMAFUN OPENING WALL — integration layer (Lawrence 2026-12-01
   ~11:51 EST clarified directive). Loads AFTER assets/style.css on
   the 24 homepages only.
   The approved square layered-C painting, watermarked edition, is
   presented as a WALL: the painting itself is shown WHOLE and
   unaltered (never cropped — Lawrence's standing ruling, restated
   2026-12-01 ~17:04 EST after the magazine rebuild's cover fit cut
   49.6% of the painting away at desktop and 46.0% on phone), and
   the rest of the first screen is filled by the painting's OWN sky
   continued (wall-sky.webp, derived from the master's sky only).
   The earlier cover presentation and its crop measurements are
   recorded in ~/workspace/supermafun-wall-whole-fix-2026-12-01/.
   Above the wall, the small masthead line in the Mafun register.
   ================================================================ */

/* — Masthead: one small line, Cormorant, letterspaced, one gold
   hairline (bronze/gold metal register) — the mafun.com opening. */
.masthead{text-align:center;padding:16px 16px 12px;position:relative}
/* .masthead-line REMOVED 2026-12-02 (header fix batch): the line over the
   painting duplicated the header's bilingual lockup; the header line is
   the one surviving instance. The masthead section + gold rule remain. */
.masthead-rule{width:min(420px,62vw);height:1px;margin:12px auto 0;
  background:linear-gradient(90deg,transparent,#D78642,#FFC981,#D78642,transparent)}
/* the masthead sits on the painting's own sky, not on page colour:
   a strip of the painting itself (its starfield top), shaded only
   enough for the line to read — no flat colour band */
.opening{background:#FFF8EA}
.masthead{background:linear-gradient(180deg,rgba(22,7,28,.42),rgba(22,7,28,.42)),
  url('logo-layered-painting-wall.webp') center top/100% auto no-repeat #2B1632}

/* — The wall: full-bleed, edge to edge. The chrome stack that used
   to sit above it (festival strip, region bar, preview strip) now
   lives BELOW the wall; the cover starts under the one-line header
   + the masthead lintel, and header + lintel + wall together fill
   the first screen (--cover-top = measured header + lintel height,
   calibrated per breakpoint in the magazine-rebuild batch). */
.wall{--cover-top:87px;position:relative;overflow:hidden;display:flex;flex-direction:column;
  height:calc(100svh - var(--cover-top));min-height:440px;background:#FFF8EA}
@media (max-width:860px){.wall{--cover-top:76px}}
/* the ground is the painting's own sky continued — wall-sky.webp,
   a starfield ground derived ONLY from the master's sky (its plum
   gradient, nebula washes and star colours sampled from the
   painting itself; no watch, no wordmark, no blurred copy of the
   whole painting, no foreign colours). It fills whatever the
   whole painting does not, so the first screen is covered edge to
   edge with the painting's own sky — no bands, no frame. */
.wall-sky{position:absolute;inset:0;
  background:#FFF8EA}
/* the stage fills the whole wall; the painting hangs CENTRED in it
   with clear space on all four sides (§86/§142 breathing room — the
   stage padding IS the clear space: >=4.5% of the wall's width at
   the sides, never less than 18px, 24px at the top; the bottom
   padding is the wall-foot's height, so the painting's wordmark
   (image rows 85.5–92.5%) always clears the foot's action row).
   The painting reads as a whole artwork on the cream wall — no
   feather, no dissolve, no frame line. */
.wall-stage{position:absolute;inset:0;z-index:1;box-sizing:border-box;
  padding:24px max(18px,4.5%) 62px;
  display:flex;align-items:center;justify-content:center}
/* WALL-PRESENTATION FIX (2026-12-02, Lawrence live on his phone
   ~07:53 EST: "画都变形了" / "两边都切" / "没有呼吸感" / "logo贴边"
   — §137 repeat instruction). Three defects, one root family:
   (1) DISTORTION: the old desktop rule sized the img by height
   (height:100%) and the <=860px rule by width (width:100%) with an
   independent max-height clamp — when the clamp bound, width and
   height were clamped separately and the square painting rendered
   off-aspect (measured 1.127 at 390x500, 2.193 at 844x390).
   (2) EDGE EATING: a feather mask dissolved all four edges of the
   artwork (transparent->opaque 6%/94%, 4%/95%), eating toward the
   baked-in crown (x~8%) and wordmark.
   (3) NO CLEAR SPACE: the painting sat flush with the screen edge
   (measured clearL/clearR = 0 at 390 and 768).
   Fix: the img is sized by NEITHER dimension — width/height auto
   under max-width/max-height 100% of the padded stage, so the
   browser scales the natural 1:1 artwork down preserving aspect
   (contain semantics); the mask is REMOVED entirely (subjects are
   100% opaque, unclipped); the stage padding above supplies the
   measured clear space. Gate: breathing-gate G7 (aspect fidelity)
   + G8 (edge clearance / no mask), fail-closed. Record:
   ~/workspace/supermafun-wall-presentation-fix-2026-12-02/REPORT.md */
.wall-painting{display:block;width:auto;height:auto;max-width:100%;max-height:100%;position:relative;z-index:1}
/* HERO-OVERLAY FIX (Lawrence 2026-12-02 call, named defect: the
   "bright lights, beautifully legal" plate sat ON the painting and
   covered it — in his words it blocked the picture he asked for).
   The H1 is a headline, not legal text: nothing requires it on the
   artwork, so it now stands BELOW the wall as one quiet editorial
   line on the wall's own plum ground — wording verbatim in all 24
   editions, same display type, gold second line kept. The painting
   itself now carries nothing over its surface. Every legally
   required element (19+ age gate, region/jurisdiction bar, the
   hero-note with the ConnexOntario line, operator disclaimers) was
   already below the wall and is untouched by this batch. */
.wall-headline{background:#FFF8EA;text-align:center;
  padding:30px 20px 32px}
.wall-headline h1{color:#2C1E07;margin:0;
  font-size:var(--type-display);line-height:1.08}
/* Phase 2: the wall foot is the cover's ONE action zone — a single
   slim row (Vega chip + actions). The old 118px right padding reserved
   a hole for the floating Host FAB; the FAB now stands down while the
   wall is in view, so the zone runs full width, and its height is
   budgeted so its top edge clears the painting's wordmark (measured
   overlap = 0 at 390/768/1280). */
.wall-foot{position:absolute;left:0;right:0;bottom:0;z-index:3;display:flex;flex-wrap:nowrap;gap:10px 16px;
  align-items:center;justify-content:space-between;
  padding:6px clamp(20px,4.5vw,28px);
  background:linear-gradient(180deg,rgba(43,22,50,0),rgba(43,22,50,.55))}
body.wall-in-view #hostFab{display:none}
.wall-actions .btn{padding:11px 24px}
.wall-vega .btn{white-space:nowrap}
.wall-vega{display:inline-flex;align-items:center;gap:10px;background:rgba(24,10,30,.74);
  border:1px solid rgba(215,134,66,.6);border-radius:999px;padding:5px 12px 5px 5px;color:#DCDCD9;
  backdrop-filter:blur(6px)}
.wall-vega img{width:38px;height:38px;border-radius:50%;display:block}
.wall-vega strong{color:var(--gold-soft)}
.wall-actions{margin:0}
.wall-note{flex-basis:100%;text-align:center;color:#DCDCD9;font-size:var(--type-caption);margin:4px 0 0;
  text-shadow:0 1px 10px rgba(10,2,16,.85)}

/* — Hero copy re-seated below the wall, original order and wording;
   its magazine cover-lines stack as a quiet row here. */
.welcome-in .cover-lines{position:static;display:flex;gap:14px 34px;flex-wrap:wrap;margin:0 0 20px}
.welcome-in .cover-line{position:static;transform:none;font-size:1rem;letter-spacing:.14em;
  text-transform:uppercase;color:#7A5410}

@media (max-width:640px){
  .masthead{padding:13px 12px 10px}
  .wall{--cover-top:122px;height:calc(100svh - var(--cover-top));min-height:400px}
  /* phone wall-foot is 51px: stage padding tracks it (wordmark clearance) */
  .wall-stage{padding-bottom:54px}
  /* HERO-OVERLAY FIX: the headline band below the wall, phone size */
  .wall-headline{padding:24px 16px 26px}
  .wall-headline h1{font-size:var(--type-display);line-height:1.12}
  /* Phase 2: phone foot = the same single slim row as desktop */
  .wall-foot{justify-content:space-between;text-align:left;padding:5px 12px;gap:8px 10px;flex-wrap:nowrap}
  .wall-vega{padding:4px 8px 4px 4px;gap:6px;flex:none}
  .wall-vega img{width:26px;height:26px}
  .wall-vega .btn{padding:6px 10px}
  .wall-actions{flex-direction:row;width:auto;display:flex;gap:10px;flex-wrap:nowrap;justify-content:flex-end;flex:none}
  .wall-actions a.btn{flex:none;padding:8px 10px;font-size:var(--type-caption);white-space:nowrap;max-width:54vw;overflow:hidden;text-overflow:ellipsis}
  .wall-note{font-size:var(--type-caption)}
}

/* ================================================================
   HOMEPAGE PASS 2 (Lawrence 2026-12-01 ~12:29-12:37 EST, items
   5-13): hierarchy + magazine register for the first screen and
   the sections below the wall. Homepage only (this file loads on
   the 24 homepages). Colours are sampled values only: Wynn bronze
   #D78642, Bellagio champagne #DCDCD9, the painting's own plum
   #2B1632. ================================================================ */

/* — the preview strip steps down: a quiet plum line, not a gold
   banner competing with the painting */
.preview-strip{background:#2B1632;color:#DCDCD9;font-size:var(--type-caption);
  letter-spacing:.14em;text-transform:uppercase;padding:9px 16px}

/* — Item 7: the header mark, as large as the one-line header
   (§132) carries: 46 -> 58 desktop, 36 -> 44 phone */
.brand-mark{width:58px;height:58px}
@media (max-width:760px){.brand-mark{width:48px;height:48px}}
@media (max-width:480px){.brand-mark{width:44px;height:44px}}

/* — Item 11: the region bar in one row (desktop) / at most two
   (phone): flex with a shrinkable text cell and a nowrap CTA */
.region-in{flex-wrap:wrap;gap:6px 16px;padding-top:8px;padding-bottom:8px}
.region-text{flex:1 1 300px;min-width:0}
.region-cta{flex:none;white-space:nowrap}
@media (max-width:640px){
  /* two rows, never three: row 1 = "Your region:" + name + CTA,
     row 2 = the region message on one line (bar wording tightened
     in app.js REGIONS, Item 11 — fuller text lives below) */
  .region-in{padding:8px 12px;gap:5px 8px;align-items:center;font-size:var(--type-caption)}
  .region-text{display:contents}
  .region-text strong{order:1;font-size:var(--type-caption);white-space:nowrap}
  .region-cta{order:2;margin-left:auto;font-size:var(--type-caption);padding:6px 11px}
  #regionMsg{order:3;flex:1 1 100%;font-size:var(--type-caption);line-height:1.35}
}

/* — Item 8: breathing margins below the wall (§86). Desktop wrap
   already insets via max-width + 28px; the phone wrap padding was
   zeroed by a base media query — restore a measured 20px. */
@media (max-width:640px){
  main .wrap{padding-left:20px;padding-right:20px}
  .section{padding:64px 0}
}

/* — Items 9 + 13: the magazine register (Vogue / L'Officiel
   conventions): oversized editorial headlines, a slower spacing
   rhythm, folio-numbered feature columns with a bronze rule —
   the directory look is the defect being removed. */
.section{padding:104px 0}
.band{padding:104px 0}
.band-title,.section-head h2{font-size:var(--type-h2);
  line-height:1.08;letter-spacing:var(--ls-display)}
.section-head p{font-size:1.07rem;line-height:1.65;max-width:62ch}
.pillars{gap:46px 40px;margin-top:56px;counter-reset:folio}
.pillar{background:transparent;border:none;border-top:2px solid #D78642;
  border-radius:0;padding:20px 4px 0;box-shadow:none}
.pillar::before{counter-increment:folio;content:counter(folio,decimal-leading-zero);
  display:block;font-family:var(--font-display);color:#D78642;
  font-size:var(--type-caption);letter-spacing:var(--ls-eyebrow);margin-bottom:12px}
.pillar h3{font-size:var(--type-h3);line-height:1.2;margin-bottom:.45em}
.pillar p{line-height:1.68}
.op-grid{gap:30px;margin-top:8px}
.op-card{border-top:3px solid #D78642;padding:30px 30px 26px}
.op-card h3{font-size:var(--type-h3);line-height:1.15}
.city-grid{gap:34px}
.photo-fig figcaption{font-size:var(--type-caption);letter-spacing:.05em;line-height:1.55}
@media (max-width:640px){
  .section{padding:64px 0}
  .band{padding:64px 0}
  .pillars{gap:34px;margin-top:40px}
  .op-card{padding:24px 22px 20px}
}

/* --- EV2 (elevation 2026-12-02): masthead absorbed, motion, marquee --- */
.wall>.masthead{position:absolute;top:10px;left:0;right:0;z-index:4;background:none;padding:6px 16px 0}
.wall>.masthead .masthead-rule{margin-top:8px}
.wall-sky{animation:ev2drift 56s ease-in-out infinite alternate}
@keyframes ev2drift{from{transform:scale(1.03)}to{transform:scale(1.1) translate(-1.4%,-1.2%)}}
.wall-stage::after{content:"";position:absolute;inset:0;z-index:0;pointer-events:none;
  background:radial-gradient(ellipse 96% 86% at 50% 46%,rgba(255,178,84,.20),rgba(255,178,84,0) 68%);
  animation:ev2glow 9s ease-in-out infinite alternate}
@keyframes ev2glow{from{opacity:.55}to{opacity:1}}
.wall-foot{border-top:1px solid rgba(255,201,129,.35)}
.wall-foot::before{content:"";position:absolute;top:-6px;left:0;right:0;height:11px;pointer-events:none;
  background-image:radial-gradient(circle,#FFC981 2.3px,rgba(255,201,129,.0) 3.1px);
  background-size:27px 11px;background-repeat:repeat-x;background-position:center;opacity:.85}
@media (prefers-reduced-motion: reduce){.wall-sky,.wall-stage::after{animation:none}}
@media (max-width:860px){
  /* the old width:100% painting rule that lived here was the phone
     distortion source (independent max-height clamp) — removed by
     the 2026-12-02 wall-presentation fix; the base rule's contain
     sizing now governs every width. */
  .wall>.masthead{top:6px}
}

/* ================================================================
   SIDE-EDGE FIX (Lawrence 2026-12-02 ~02:31 EST call, named defect:
   "SuperMafun 那两边那个边怎么那么丑" — the opening wall's two side
   edges). The whole painting stays whole and uncropped; ONLY the
   side-edge treatment changes:
   1. The wall ground is now wall-ambient.webp — an ambient
      continuation derived from the painting itself (cover-scaled,
      gaussian-blurred 42px, brightness .8): the painting's own
      colours continue across its left/right edges, so the two flat
      plum columns (measured 293px each at 1280, 613px at 1920) and
      the luminance cliff at the seams are gone. No subject is
      presented by the ground — it is atmosphere only, in the
      YouTube-ambient / Apple-backdrop register.
   2. The painting's left/right feather widens 4% -> 6% (still
      inside its sky margins; the crown at x~8% stays fully opaque).
   3. The EV2 warm glow no longer traces the painting's rectangle
      (ellipse 62% 58% -> 96% 86%, wall-wide).
   Staged 2026-12-02 in ~/workspace/supermafun-side-edges-fix-2026-12-02/
   (REPORT.md + LEDGER.md there). NOT deployed by this batch.
   ================================================================ */

/* ================================================================
   §142 CONFORMANCE PASS (2026-12-02 — Lawrence 2026-12-02 03:00–03:04
   EST rulings, §142 补款): the wall's surround ground and the C3
   headline band are re-grounded from dark plum #1F0B22 to the white
   museum register — #FFF8EA, the site's own header cream (sampled
   from the live computed header ground rgba(255,249,234,.94)); the
   band's H1 takes the site's ink #2C1E07 (its gold second line is
   the standing gold accent, kept). The canonical painting itself —
   file, aspect, feather, warm glow, foot action zone — is
   untouched; it now hangs in a sunlit gallery. wall-ambient.webp
   (the blurred plum field) is retired from the ground; the file
   stays in the tree, unused. On portrait phones/tablets the
   width-fit painting no longer reaches the wall's top or foot, so
   the masthead line and the wall foot stand on the white ground in
   that geometry: they take the ink and drop the over-painting
   gradient/shadow there only. Ledger:
   ~/workspace/supermafun-142-conformance-pass-2026-12-02/LEDGER.md
   ================================================================ */
@media (max-width:860px) and (min-height:560px){
  .wall-foot{background:none}
  .wall-note{color:#2C1E07;text-shadow:none}
}

/* ================================================================
   WALL-PRESENTATION FIX (2026-12-02) — record: the feather mask is
   gone, the painting is contain-sized inside a padded stage, and
   clear space is measured by gate G7/G8 on every deploy. The
   SIDE-EDGE FIX comment above is retained as history: its blurred
   ambient ground was already retired by the §142 pass, and its
   feather widening is superseded by NO feather at all.
   ================================================================ */
/* Header-growth compensation (same batch): the bilingual EN/FR
   wordmark line (style.css, 2026-12-02) stacks on narrow screens and
   grows the one-row header by a measured delta — +48px at 360–400,
   +36px at 430, +21px at 500, 0 from 600 up (delta table in the
   batch REPORT.md). --cover-top is by definition "measured header +
   lintel height", so it absorbs the same delta per band and the
   wall's first-screen geometry (top offset + height + bottom) is
   pixel-identical to the pre-batch calibration. */
@media (max-width:400px){.wall{--cover-top:170px}}
@media (min-width:401px) and (max-width:460px){.wall{--cover-top:158px}}
@media (min-width:461px) and (max-width:560px){.wall{--cover-top:143px}}

/* ================================================================
   FINAL WALL FORM — Lawrence's ruling 2026-12-02 08:16-08:18 EST
   supersedes the contain/clear-space sizing above: the original
   painting, byte-identical and undistorted, is simply scaled up to
   fill the full screen width; the wall's height follows the
   painting ("长一点也无所谓，墙高跟着画走"); nothing is cropped —
   crown and wordmark are whole in frame; no element is added; the
   showy glow animation is off (quiet presentation). The foot moves
   into normal flow below the painting so it can never cover the
   baked-in wordmark at the painting's foot.
   ================================================================ */
.wall{height:auto}
.wall-stage{position:relative;inset:auto;height:auto;padding:0;display:block}
.wall-painting{width:100%;height:auto;max-width:none;max-height:none}
.wall-sky{animation:none}
.wall-stage::after{display:none}
.wall-foot{position:relative;left:auto;right:auto;bottom:auto;transform:none;margin:16px auto 20px}
@media (max-width:560px){.wall-foot{flex-wrap:wrap;justify-content:center;width:auto}}

/* -- Dali banner band (2026-12-02, Lawrence-approved banner placement):
      the banner painting shown whole at native ratio, full-bleed width,
      cream breathing room above and below; no overlay of any kind. */
.dali-banner{margin:0;line-height:0;background:#FFF8EA;padding:clamp(48px,6vw,88px) 0}
.dali-banner img{display:block;width:100%;height:auto}

/* ==== BANNER-HERO BATCH 2026-12-02 (Lawrence rulings 18:35-18:42 EST) ====
   Hero: the approved Dali banner replaces the square painting in the wall
   slot. Gallery framing (ruling 18:42): the painting sits IN the page on
   the cream ground with breathing margins - desktop >=4% of viewport per
   side, phone >=16px per side; whole and uncropped at its native ratio,
   nothing overlaid, nothing touching the viewport edge. The lintel rule
   moves into flow above the painting. Vega sits right (ruling 18:37).
   Type/spacing lifted to the family ladder (SS142 R-4/R-5, ruling 18:41). */
.wall>.masthead{position:static;padding:12px 16px 2px}
.wall-stage{padding:26px max(16px,4.5%) 6px}
:dir(ltr) .wall-foot>.wall-vega{order:2}
:dir(ltr) .vega-card>.vega-portrait{order:9}
:dir(ltr) .vega-line>.guide-face{order:9}
@media (max-width:560px){.wall-foot{justify-content:flex-end}}
@media (max-width:640px){.host-portrait{float:none;width:min(240px,80%);margin:0 0 1.2rem auto}}
.wall-headline{padding:64px 20px 56px}
.wall-headline h1{font-size:var(--type-display)}
.city-grid .city-card:not(.ev-feature) .photo-fig img{aspect-ratio:16/10;object-fit:cover}
.section{padding:104px 0}
@media (max-width:860px){.wall-headline{padding:48px 16px 40px}.section{padding:64px 0}}

/* BANNER-HERO BATCH (cont.): push the Vega card portrait fully to the
   right end of its flex line on narrow cards too. */
:dir(ltr) .vega-card>.vega-portrait{margin-inline-start:auto}

/* ================================================================
   FULL-BLEED HERO — GAP FIX 2026-12-02 (Lawrence live ruling
   2026-12-02 22:35-22:38 EST, superseding the 18:42 gallery-frame
   form above for the OPENING IMAGE only): "图满屏、字留白" — the
   opening painting bleeds to both viewport edges with NO side
   margins (measured gap vs mafun.com: framed 57px sides / 61%
   first-screen height vs full-bleed 0px / 90%); text and action
   blocks keep their whitespace and never touch the edge. The
   banner asset is byte-identical; only its presentation frame
   changes. The masthead lintel returns to its EV2 overlay seat
   over the painting's own sky so no cream band precedes the
   painting. The wall's forced min-height is released so no dead
   cream opens between the foot and the headline on portrait
   screens. Headline lifted to the measured family display scale
   (80px desktop class). Record:
   ~/workspace/supermafun-mafun-gap-2026-12-02/REPORT.md
   ================================================================ */
.wall{min-height:0}
.wall-stage{padding:0}
.wall>.masthead{position:absolute;top:10px;left:0;right:0;z-index:4;
  background:none;padding:6px 16px 0}
.wall-foot{margin:12px auto 14px}
.wall-headline{padding:40px 20px 48px}
.wall-headline h1{font-size:var(--type-display)}
@media (max-width:860px){
  .wall>.masthead{top:6px}
  .wall-headline{padding:32px 16px 36px}
}
