有人可以告诉我如何在我的网站上创建一个居中和响应式的报价,这样当浏览器窗口保持居中时它会变得更小,而且它也是居中的,只是在移动设备上更小。
谢谢
CSS
blockquote {
color: black;
position: relative;
display: inline-block;
padding: 0 5px;
margin: 0px auto;
left:27%;
}
blockquote p {
margin-bottom: 5px;
}
blockquote:before,
blockquote:after {
content: "“";
font-size: 70px;
font-family: "Georgia", Serif;
color: #28B701;
position: absolute;
left: -30px;
top: 5px;
}
cite {
float: right;
color: black;
font-size: 12px;
margin: 0;
padding: 0;
}
blockquote:after {
content: "”";
right: -30px;
left: auto;
}
HTML
<blockquote><p style="color:#666;">Socrates said, “Know thyself.” I say, “Know thy users.” They don’t think like you do.</p><cite>- Joshua Brewer</cite></blockquote></p>