本帖最后由 花简静 于 2024-8-18 15:25 编辑
<style>
#mydiv { margin:130px 0 20px calc(50% - 931px); width: 1700px; height: 900px; background: url('https://642303.freep.cn/642303/tu/20245.6bksqy05.webp') no-repeat center/cover; box-shadow: 3px 3px 6px gray; overflow: hidden; z-index: 1; position: relative; display: grid; place-items: center; }
#player { position: absolute; top: 555px; right:320px;width: 100px; filter: drop-shadow(0 0 6px #fff) opacity(.95); cursor: pointer; animation: rot 6s linear infinite var(--state); }
.vid { position: absolute; object-fit: cover; mix-blend-mode: screen; }
.vid:nth-of-type(1) { bottom: 0; width: 60%; height: 55%; top:30%;left:-10%;transform: rotate(170deg);}
.vid:nth-of-type(2) { left: 0; top:-80px; width: 100%; height: 110%; opacity: .4;transform: rotate(-20deg);}
@keyframes rot { to { transform: rotate(360deg); } }
@keyframes swear { to { transform: skew(15deg); } }
</style>
<div id="mydiv">
<audio id="aud" src="https://music.163.com/song/media/outer/url?id=1331937276" autoplay loop></audio>
<video class="vid" src="https://img.tukuppt.com/video_show/2269348/00/14/65/5e59d9be359da.mp4" loop muted></video>
<video class="vid" src="https://img.tukuppt.com/video_show/2269348/00/14/66/5e5a2fd36a145.mp4" loop muted></video>
<img id="player" src="https://638183.freep.cn/638183/t24/leaf/5l.png" alt="" />
</div>
<script>
let sc = document.createElement('script');
sc.charset = 'utf-8';
sc.src = 'https://638183.freep.cn/638183/web/js/lzwz.js';
document.body.appendChild(sc);
let wz = {papa: '#mydiv', text: 'TO:柒玥', left: '120px', top: '370px', color: 'rgba(0,205,250,.3)'};
let vids = document.querySelectorAll('.vid');
let mState = () => vids.forEach(vid => aud.paused ?
(vid.pause(), mydiv.style.setProperty('--state', 'paused')) :
(vid.play(), mydiv.style.setProperty('--state', 'running')));
aud.onplaying = aud.onpause = () => mState();
player.onclick = () => aud.paused ? aud.play() : aud.pause();
</script>
<br><br><br><br><br>
|