You’ve used the same hex colour for your video background and the site section underneath it. It looks fine on your computer. Then you open the page on your phone and you can see exactly where the video ends.
That was the problem Armin of Braunsberger Media brought me. A client’s Squarespace homepage opened with an animation on a purple background. The purple was supposed to carry on into the section below, without anyone being able to tell where the video stopped. On some devices it did exactly that. On others, the join was obvious.
How can one purple turn into two?
The colour difference is exaggerated here to make it easier to see. On the real site, it was subtler, but you could still see where the video ended.
Why the same colour can look different
A hex colour in CSS is specified in sRGB. Video can use a different colour space, so its colours have to be converted for display. That conversion can happen in the graphics hardware as part of video playback, separately from how the browser draws the page. That’s how two purples that started with the same hex value can end up looking different on screen.
One tempting fix is to sample the purple from the video as it plays and use that colour in the CSS. That might hide the join in the browser you’re testing, but it could introduce one in a browser where the colours already matched. It’s like Whack-a-mole.
So what’s the fix?
The video had several lines of text scrolling horizontally across the screen. We wanted to keep the way the text moved and change what sat behind it.
My first idea was to recreate the animation in SVG, but it was taking too long to make it match the video the client had approved.
So we asked the motion designer to export the video with a transparent background so the page’s purple background would show through. That did get rid of the join. Eventually.
Getting transparent video to work across browsers opened a different can of worms. That’s Part 2: How to add transparent video to Squarespace.