单个div+css布局实现光盘刻录整套设备效果代码
代码语言:html
所属分类:布局界面
代码描述:仅仅使用单个div结合一些css代码布局就实现光盘刻录整套设备效果代码,包含电脑、光盘、刻录机。
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <style> body { min-height: 250px; height: 100vh; position: relative; background-color: #556b2f; } div { position: absolute; left: 50%; top: 50%; } div:before, div:after { display: block; content: ''; position: absolute; } @media (max-width: 400px) { div { transform: scale(0.8); } } #stack { font-size: 10px; width: 37em; height: 11em; margin-left: -18.5em; margin-top: -5.5em; background-repeat: no-repeat; background-image: linear-gradient(white, white), linear-gradient(white, white), linear-gradient(rgba(255,255,255,0.3), rgba(255,255,255,0.3)), linear-gradient(rgba(0,0,0,0.2), rgba(0,0,0,0.2)), linear-gradient(rgba(0,0,0,0.2), rgba(0,0,0,0.2)), linear-gradient(rgba(255,255,255,0.3), rgba(255,255,255,0.3)), repeating-linear-gradient(to top, rgba(255,255,255,0), rgba(255,255,255,0) 0.2em, white 0.2em, white 0.3em), linear-gradient(white, white), linear-gradient(white, white), linear-gradient(white, white), linear-gradient(white, white), linear-gradient(white, white), linear-gradient(to right, white 0.2em, rgba(255,255,255,0) 0.2em, rgba(255,255,255,0) 1em, white 1em, white 1.1em, rgba(255,255,255,0) 1.1em, rgba(255,255,255,0) calc(100% - 0.1em), white calc(100% - 0.1em)), linear-gradient(to bottom, white 0.1em, rgba(255,255,255,0) 0.2em, rgba(255,255,255,0) calc(100% - 0.1em), white calc(100% - 0.1em)), radial-gradient(circle at 50% 0, rgba(255,255,255,0) 65%, rgba(255,255,255,0.25) 66%, rgba(255,255,255,0.25) 68%, rgba(255,255,255,0) 69%), radial-gradient(circle at 50% 100%, rgba(0,0,0,0) 65%, rgba(0,0,0,0.25) 66%, rgba(0,0,0,0.25) 68%, rgba(0,0,0,0) 69%), radial-gradient(circle, rgba(0,0,0,0) 7%, rgba(0,0,0,0.3) 8%, rgba(0,0,0,0.3) 9.5%, rgba(0,0,0,0) 10.5%); background-size: 12em 0.5em, 1em 0.5em, 1em 9.5em, 1.2em 10.4em, 1.2em 10.4em, 0.6em 10.4em, 9em 9em, 0.1em 10.6em, 0.1em 10.6em, 10.2em 0.1em, 1em 0.2em, 0.2em 3em, 11em 10em, 11em 10em, 10em 5em, 10em 5.........完整代码请登录后点击上方下载按钮下载查看
网友评论0