Skip to content

Commit 72cc251

Browse files
Fix mobile menu backdrop, trim unreleased changelog
public-layout.css sets background: var(--bg-primary) on .pub-navbar__nav in its mobile media query, and that rule lands after this Astro <style is:global> in the bundle. A plain --open selector ties on specificity (0,1,0) and loses on source order, so the panel rendered whatever var(--bg-primary) computed to in the marketing context (effectively transparent on iOS Safari). Stack class selectors (.pub-navbar .pub-navbar__nav.pub-navbar__nav--open, 0,3,0) so this rule wins regardless of bundle order, with a solid #0C1133 fallback before the color-mix line. Lighter blur(10) on mobile so older phones don't fight a heavy filter (the filter cost scales roughly with the radius squared). Take the navbar and sticky CTA to blur(10) on mobile too for a consistent look. Desktop keeps blur(12). Also morph the hamburger into a close icon when the panel opens. Drop the unreleased ### Changed entry on the council master prompt fetch (implementation detail that didn't belong in user-facing release notes).
1 parent 6fca677 commit 72cc251

2 files changed

Lines changed: 46 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
88

99
## [Unreleased]
1010

11-
### Changed
12-
13-
- **Council master prompts now load from the media CDN.** `services/council/generator.ts` fetches `council_advisory_master.json` and `council_debate_master.json` from `${mediaBaseUrl}/instructions/...` instead of a same-origin `/assets/instructions/...` path. Matches how figure-specific instructions already load. Removes the last authored-text leak from the self-host docker image.
14-
1511
### Added
1612

1713
- **Marketing pages migrated to Astro for sub-second first paint.** Figure and theme detail pages, catalogs, about, and contact now ship as prerendered static HTML from the sibling `marketing/` Astro project. The hero, journey overview, ideas, and CTA paint immediately, so ad clickers landing on `/figures/<name>/` see the page within a few hundred milliseconds instead of a blank dark screen until the React bundle parses. React islands handle only the trailer audio button and council preview audio. Catalog and about/contact pages ship zero React JS. The React SPA at `/` and `/de/` continues to handle login + post-login app.

marketing/src/components/Navbar.astro

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,4 +82,50 @@ const isActive = (path: string) => currentPath === path || currentPath === path.
8282
-webkit-backdrop-filter: blur(12px);
8383
border-bottom: 1px solid color-mix(in srgb, var(--gold-primary) 16%, transparent);
8484
}
85+
86+
/* Background fix for the open mobile menu. public-layout.css sets
87+
.pub-navbar__nav { background: var(--bg-primary, #151C47) } inside
88+
its mobile media query, and that rule lands AFTER this Astro
89+
<style is:global> in the bundled CSS. A plain .pub-navbar__nav--open
90+
selector ties on specificity (0,1,0) and loses on source order,
91+
leaving the panel painted with whatever var(--bg-primary) resolves
92+
to in the marketing-page context (which on iOS Safari rendered
93+
effectively transparent). Stack the class selectors so this rule
94+
hits specificity 0,3,0 and wins regardless of bundle order, with
95+
a solid #0C1133 declaration before the color-mix line so the
96+
panel still has a real background if color-mix is unsupported or
97+
the declaration is parsed as invalid. Lighter blur(10) on mobile
98+
so older phones don't fight a heavy filter. */
99+
@media (max-width: 640px) {
100+
.pub-navbar,
101+
.pub-cta--sticky {
102+
backdrop-filter: blur(10px);
103+
-webkit-backdrop-filter: blur(10px);
104+
}
105+
106+
.pub-navbar .pub-navbar__nav.pub-navbar__nav--open {
107+
background: #0C1133;
108+
background: color-mix(in srgb, var(--bg-deep-space, #0C1133) 90%, transparent);
109+
backdrop-filter: blur(10px);
110+
-webkit-backdrop-filter: blur(10px);
111+
border-top: 1px solid color-mix(in srgb, var(--gold-primary, #E6BC5C) 16%, transparent);
112+
box-shadow: 0 16px 40px color-mix(in srgb, #000 45%, transparent);
113+
padding-bottom: max(2rem, env(safe-area-inset-bottom));
114+
}
115+
116+
/* Hamburger morphs into a close icon when the panel is open. */
117+
.pub-navbar__burger-line {
118+
transform-origin: center;
119+
transition: transform 0.2s ease, opacity 0.16s ease;
120+
}
121+
.pub-navbar__burger[aria-expanded="true"] .pub-navbar__burger-line:nth-child(1) {
122+
transform: translateY(7px) rotate(45deg);
123+
}
124+
.pub-navbar__burger[aria-expanded="true"] .pub-navbar__burger-line:nth-child(2) {
125+
opacity: 0;
126+
}
127+
.pub-navbar__burger[aria-expanded="true"] .pub-navbar__burger-line:nth-child(3) {
128+
transform: translateY(-7px) rotate(-45deg);
129+
}
130+
}
85131
</style>

0 commit comments

Comments
 (0)