Skip to content

Commit 25526d8

Browse files
suryaprakash0010sumn2u
authored andcommitted
Update styles.css
1 parent bc4b470 commit 25526d8

1 file changed

Lines changed: 16 additions & 1 deletion

File tree

examples/Rock-Paper-Scissors/styles.css

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ body {
1818
.game-container {
1919
background: rgba(255, 255, 255, 0.95);
2020
backdrop-filter: blur(20px);
21+
-webkit-backdrop-filter: blur(20px); /* Safari support */
2122
border-radius: 20px;
2223
padding: 2rem;
2324
box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
@@ -26,6 +27,7 @@ body {
2627
border: 1px solid rgba(255, 255, 255, 0.2);
2728
}
2829

30+
2931
/* Header */
3032
.game-header {
3133
text-align: center;
@@ -342,7 +344,7 @@ body {
342344
padding: 1rem;
343345
}
344346

345-
/* Animations */
347+
/* Shake animation */
346348
@keyframes shake {
347349
0%, 100% {
348350
transform: translateX(0);
@@ -359,6 +361,19 @@ body {
359361
animation: shake 0.5s ease-in-out;
360362
}
361363

364+
/* Respect users' reduced motion preferences */
365+
@media (prefers-reduced-motion: reduce) {
366+
.choice-btn.selected,
367+
.shake {
368+
animation: none !important;
369+
}
370+
371+
.score {
372+
transition: none !important;
373+
}
374+
}
375+
376+
362377
/* Responsive Design */
363378
@media (max-width: 600px) {
364379
.game-container {

0 commit comments

Comments
 (0)