@[牛顿摆]
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>牛顿摆</title>
<style>
*{
margin: 0;
padding: 0;
}
<!--平台大小,自定义-->
.terrace{
margin: 0 auto;
position: relative;
margin: 0 auto;
width: 500px;
height: 500px;
}
<!--单杆-->
.pole{
left: 15%;
top: 5%;
width: 70%;
height: 5%;
position:absolute;
border-top-right-radius: 5% 50%;
border-bottom-right-radius: 5% 50%;
border-top-left-radius: 5% 50%;
border-bottom-left-radius: 5% 50%;
background-color: silver;
box-shadow:0 0 1px rgba(0,0,0,.5);
}
<!--带线摆球-->
.wire_ball{
top: 9.5%;
width: 8%;
height: 45%;
position:absolute;
display: inline-block;
text-align: center;
}
<!--线-->
.wire{
margin: 0 auto;
width: 12.5%;
height: 88%;
border-top-right-radius: 50% 1%;