/* Page photo as the opening hero's background (owner-authorised background correction, 16 Nov 2026).
   Scope: section.fpw-photo-hero only, the hook tools/market/page_images.py adds to the first section of a
   mapped page. The picture sits behind the existing content and a white overlay keeps the copy readable.
   Hero height, padding, typography, mascot sizing, header and footer are untouched. */
section.fpw-photo-hero{position:relative;isolation:isolate}
section.fpw-photo-hero>.hero-photo-bg{position:absolute;inset:0;z-index:0;display:block;width:100%;height:100%;pointer-events:none}
section.fpw-photo-hero>.hero-photo-bg img{display:block;width:100%;height:100%;object-fit:cover;object-position:50% 50%;border-radius:0;aspect-ratio:auto}
/* Overlay: generic centred and long-text heroes (.section, .legal-hero, .au-hero). Owner correction, 16 Nov 2026: the
   uniform .94 white hid the picture, so the overlay is .62 white and about 38% of the photo shows through. */
section.fpw-photo-hero::after{content:"";position:absolute;inset:0;z-index:1;pointer-events:none;background:rgba(255,255,255,.62)}
/* The existing content stays where it is, above the photo and the overlay (the picture and the hidden glow excepted). */
section.fpw-photo-hero>:not(.hero-photo-bg):not(.hero-glow){position:relative;z-index:2}
/* The decorative glow is hidden only where a photo now backs the hero. */
section.fpw-photo-hero>.hero-glow{display:none}
/* Non-homepage copy over the thinner overlay. Contrast is reckoned against the worst case, the .62 overlay on pure black
   (#9e9e9e, relative luminance .342): headings keep --ink #17120b at 6.9:1; ordinary copy, .section-sub, .lead and
   list items use #2a2118 at 5.9:1; the eyebrow and plain links use #4e2409 at 5.0:1. Local tokens only: --body and
   --muted are redefined on this section so .lead, .section-sub, .updated and inherited text pick the dark value up;
   no global token changes. --accent-d is left alone so chips, buttons and focus rings keep their colours. */
section.fpw-photo-hero:not(.hero-premium){--fpw-hero-text:#2a2118;--fpw-hero-accent:#4e2409;--body:var(--fpw-hero-text);--muted:var(--fpw-hero-text);color:var(--fpw-hero-text)}
/* Outranks the page-level main.uk-body .container>p (#3f3a33, 4.2:1 worst case) without touching the markup. */
section.fpw-photo-hero:not(.hero-premium) .container>p{color:var(--fpw-hero-text)}
section.fpw-photo-hero:not(.hero-premium) .eyebrow,section.fpw-photo-hero:not(.hero-premium) .hl{color:var(--fpw-hero-accent)}
/* Plain links only; .btn keeps its own background and colour. */
section.fpw-photo-hero:not(.hero-premium) a:not(.btn){color:var(--fpw-hero-accent);text-decoration:underline}
/* Cards inside such a hero sit on their own white surface: give them the site tokens back so their text is unchanged. */
section.fpw-photo-hero:not(.hero-premium) .card,section.fpw-photo-hero:not(.hero-premium) .card-elev{--body:#4d4438;--muted:#6e695f;color:var(--body)}
/* Homepage hero only: the accepted gradient, thinning towards the mascot. Owner correction, 16 Nov 2026: the .96/.94
   left stops masked the photo, so the copy side is .70 white; the right .36/.12 stops and the image position are kept. */
section.hero.hero-premium.fpw-photo-hero{background:#f5f1eb}
section.hero.hero-premium.fpw-photo-hero::after{background:linear-gradient(90deg,rgba(255,255,255,.70) 0%,rgba(255,255,255,.70) 52%,rgba(255,255,255,.36) 72%,rgba(255,255,255,.12) 100%)}
@media(max-width:919px){
section.hero.hero-premium.fpw-photo-hero::after{background:linear-gradient(180deg,rgba(255,255,255,.70) 0%,rgba(255,255,255,.70) 75%,rgba(255,255,255,.38) 100%)}
section.hero.hero-premium.fpw-photo-hero>.hero-photo-bg img{object-position:62% center}
}
/* Homepage copy over the .70 overlay, reckoned against the worst case (.70 white on pure black, #b3b3b3): ordinary text
   (.lead, .hp-note, .hp-steps) uses #2a2118; the eyebrow, the highlighted heading words and plain links use #4e2409.
   Scoped to the homepage hero only so it never overrides the non-homepage rules above. Buttons keep their own colours;
   font sizes, spacing and content are untouched. */
section.hero.hero-premium.fpw-photo-hero .lead,section.hero.hero-premium.fpw-photo-hero .hp-note,section.hero.hero-premium.fpw-photo-hero .hp-steps{color:#2a2118}
section.hero.hero-premium.fpw-photo-hero .hp-eyebrow,section.hero.hero-premium.fpw-photo-hero .eyebrow,section.hero.hero-premium.fpw-photo-hero .hl{color:#4e2409}
section.hero.hero-premium.fpw-photo-hero a:not(.btn){color:#4e2409}
/* Contact page framing correction (16 Nov 2026): site/contact.html's
   opening hero also carries the hand-set class fpw-contact-photo, so its photograph is shown whole instead of cropped.
   Desktop: a centred 16:9 panel up to 1100px wide, #f5f1eb behind the letterboxed picture, with the existing copy and
   .62 overlay above it as on every other page. Mobile (<=600px): the copy comes first and the intact 16:9 picture sits
   beneath it. Content, overlay, contrast tokens and every other mapped page's full-bleed cover rules are unchanged. */
section.fpw-contact-photo.fpw-photo-hero{background:#f5f1eb;max-width:1100px;margin-inline:auto;aspect-ratio:16/9;display:flex;align-items:center;justify-content:center;padding:32px 0}
section.fpw-contact-photo.fpw-photo-hero>.hero-photo-bg img{object-fit:contain;object-position:center}
@media(max-width:600px){
section.fpw-contact-photo.fpw-photo-hero{aspect-ratio:auto;flex-direction:column;padding:0}
section.fpw-contact-photo.fpw-photo-hero>.container{padding-block:32px;order:0}
section.fpw-contact-photo.fpw-photo-hero>.hero-photo-bg{position:relative;inset:auto;order:1;aspect-ratio:16/9;height:auto}
section.fpw-contact-photo.fpw-photo-hero>.hero-photo-bg img{height:auto;aspect-ratio:16/9}
}
