/* Floating header, 30 November 2026. Loaded last, on every page with the site header.
   The bar stays fixed at the top of the window. At the top of a page it looks as before: transparent over the hero,
   92px high (75px at 900px and below, 72px at 480px and below), with its thin bottom line. Once the page has scrolled
   more than 24px, script.js adds .is-scrolled: the bar turns solid #080909, shrinks to 72px (64px at 900px and below)
   and the logo scales down to fit. Flat colour only: no gradient, no blur, no shadow.
   The bar is out of the page flow, as it was before (it was position:absolute over the hero), so nothing below it
   moves when it changes. The hero top padding is unchanged. */

:root{--cd-bar:72px}
@media(max-width:900px){:root{--cd-bar:64px}}

.site-header{position:fixed;top:0;left:0;right:0;transition:height .25s ease,background-color .25s ease}
.site-header.is-scrolled{height:calc(var(--cd-bar) + env(safe-area-inset-top,0px));background-color:#080909}
.site-header .brand img.cd-logo{transform-origin:0 50%;transition:transform .25s ease}
.site-header.is-scrolled .brand img.cd-logo{transform:scale(.84)}

/* In-page links (#work, #services, #ai, #studio, #contact, #motion, #downloads) and keyboard focus land below the bar.
   The offset lives on the targets as scroll-margin, so the old 80px scroll-padding on html from mobile-hardening.css
   is set to 0 here, otherwise the two would add up. */
html{scroll-padding-top:0}
main,main [id],a[href],button,input,select,textarea,summary,[tabindex]{scroll-margin-top:calc(var(--cd-bar) + 16px)}

/* Sticky columns start below the bar instead of under it (desktop only; both are static at 900px and below). */
.process-copy,.coupon-video{top:calc(var(--cd-bar) + 40px)}

/* Mobile menu (the Menu button shows at 1100px and below, see mobile-hardening.css). Open, it fills the whole window
   behind the bar, in solid black. It scrolls itself if it is taller than the window, and that scroll never passes
   to the page behind it. script.js stops the page itself from scrolling while the menu is open. */
@media(max-width:1100px){
.site-header nav{inset:0;max-height:none;overflow-y:auto;overscroll-behavior:contain;background:#080909;-webkit-backdrop-filter:none;backdrop-filter:none;border-bottom:0;position:fixed}
}

@media(prefers-reduced-motion:reduce){
.site-header,.site-header .brand img.cd-logo{transition:none}
}
