fix: PhotoSwipe bg doesn't cover bottom — add !important and pin bg to viewport

This commit is contained in:
2026-06-22 09:11:52 +02:00
parent 68b328dabc
commit 21c1d22859
+4 -2
View File
@@ -457,8 +457,10 @@ body::after {
.pswp__bg { background: #000; }
/* iOS Safari: 100vh freezes when address bar hides; dvh tracks the live viewport */
.pswp { height: 100dvh; }
/* pswp.css loads in <body> after this stylesheet, so !important is needed to win */
.pswp { height: 100dvh !important; }
/* Pin bg directly to viewport so it can't be cut short by parent height rounding */
.pswp__bg { position: fixed !important; inset: 0 !important; }
/* Keyboard arrow navigation slide-in animations */
.pswp-key-from-right { animation: pswpKeyFromRight 0.35s cubic-bezier(0.4, 0, 0.22, 1) both; }