62070024 CSS Var and CalC (Guide Edition)
✨ KOMCHAN AUMPONG
<html> <head> <title>Let's Start </title> <style> body{ background: black; margin:1em; font-family:sans-serif; font-size:0; } div{ --size:calc(100vw / 10); width:var(--size); height:var(--size); background:grey; display:inline-block; background:hsl(calc(var(--sec) * 60),calc(50% + var(--i) * 10%),50%); animation: anim 2s calc(var(--i) * 0.75s) infinite linear alternate, border 2s infinite alternate, glow 3s infinite alternate; box-sizing:border-box; } @keyframes anim{ from{transform:rotate(0deg);} to{transform:rotate(360deg);} } @keyframes border{ from{border-radius:0%;} to{border-radius:50%;} } @keyframes glow{ from{border: 1px gray solid;} to{border:5px white dashed} } </style> </head> <body> <section style="--sec:0"> <div style="--i:0"></div> <div style="--i:1"></div> <div style="--i:2"></div> <div style="--i:3"></div> <div style="--i:4"></div> <div style="--i:5"></div> <div style="--i:6"></div> <div style="--i:7"></div> <div style="--i:8"></div> <div style="--i:9"></div> </section> <section style="--sec:1"> <div style="--i:0"></div> <div style="--i:1"></div> <div style="--i:2"></div> <div style="--i:3"></div> <div style="--i:4"></div> <div style="--i:5"></div> <div style="--i:6"></div> <div style="--i:7"></div> <div style="--i:8"></div> <div style="--i:9"></div> </section> <section style="--sec:2"> <div style="--i:0"></div> <div style="--i:1"></div> <div style="--i:2"></div> <div style="--i:3"></div> <div style="--i:4"></div> <div style="--i:5"></div> <div style="--i:6"></div> <div style="--i:7"></div> <div style="--i:8"></div> <div style="--i:9"></div> </section> <section style="--sec:3"> <div style="--i:0"></div> <div style="--i:1"></div> <div style="--i:2"></div> <div style="--i:3"></div> <div style="--i:4"></div> <div style="--i:5"></div> <div style="--i:6"></div> <div style="--i:7"></div> <div style="--i:8"></div> <div style="--i:9"></div> </section> <section style="--sec:4"> <div style="--i:0"></div> <div style="--i:1"></div> <div style="--i:2"></div> <div style="--i:3"></div> <div style="--i:4"></div> <div style="--i:5"></div> <div style="--i:6"></div> <div style="--i:7"></div> <div style="--i:8"></div> <div style="--i:9"></div> </section> <section style="--sec:5"> <div style="--i:0"></div> <div style="--i:1"></div> <div style="--i:2"></div> <div style="--i:3"></div> <div style="--i:4"></div> <div style="--i:5"></div> <div style="--i:6"></div> <div style="--i:7"></div> <div style="--i:8"></div> <div style="--i:9"></div> </section> </body> </html>