From 68d22810fcb0835214db5b9b7a79a5054263a562 Mon Sep 17 00:00:00 2001 From: daudix Date: Mon, 29 Jan 2024 20:13:03 +0300 Subject: [PATCH] feat: CRT flicker --- sass/_crt.scss | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/sass/_crt.scss b/sass/_crt.scss index f1d5368..dc4bac3 100644 --- a/sass/_crt.scss +++ b/sass/_crt.scss @@ -16,6 +16,29 @@ background-color: unset; box-shadow: unset; margin: unset; + animation: flicker 250ms alternate infinite; + + @keyframes flicker { + from { + opacity: 1; + } + 25%{ + opacity: 0.95; + } + 50% { + opacity: 0.85; + } + 75% { + opacity: 1; + } + to { + opacity: 0.9; + } + } + + @media (prefers-reduced-motion) { + animation: none; + } } }