我正在设计谷歌页面,看起来像谷歌,但面临一些问题,因为我是一个新手。我的问题是在谷歌页面右上角的Gmail,图像,应用程序图标和登录按钮如何在这些文本和图像中提供空格以及如何使用html和css设置按钮大小,如谷歌页面。
这是我的HTML代码
selector {
property: value;
}
p1 {
position: absolute;
top: 30px;
right: 180px;
border: 0;
margin-left: 10px;
;
}
p2 {
position: absolute;
top: 30px;
right: 120px;
border: 0;
margin-left: 10px;
;
}
.icon {
position: absolute;
top: -230px;
right: -560px;
width: 20px;
}
div.item {
vertical-align: top;
display: inline-block;
text-align: center;
width: 120px;
}
img {
position: fixed;
width: 280px;
top: 30%;
bottom: 50%;
left: 40%;
margin: auto;
}
.caption {
position: fixed;
color: #6fb3ef;
top: 45%;
bottom: 40%;
left: 58%;
margin: auto;
}
a {
position: relative;
margin-top: 380px;
background: no-repeat left;
font-size: 12px;
font-family: Arial, Helvetica, black;
left: 430px;
}
.venu {
width: 150px;
box-sizing: border-box;
border: 2px solid #ccc;
border-radius: 4px;
font-size: 16px;
background-color: white;
background: url(2.png) top right no-repeat;
background-position: right;
background-size: 20px;
padding: 20px 20px 20px 45%;
position: fixed;
top: 50%;
bottom: 60%;
left: 30%;
margin: auto;
}
p {
position: fixed;
top: 70%;
bottom: 60%;
left: 35%;
margin: auto;
}
p a {
color: #6fb3ef;
left: 0%;
}
body {
margin: 0;
padding: 0;
}
footer {
position: absolute;
bottom: 0;
width: 100%;
padding: 10px 0;
background-color: #efefef;
}
.content.left {
word-spacing: 30px;
margin-left: 30px;
}
.content.right {
word-spacing: 30px;
float: right;
margin-right: 30px;
}
.button {
background-color: #6495ED;
border: none;
color: white;
padding: 5px 5px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 16px;
margin: 2px 2px;
cursor: pointer;
position: absolute;
top: 20px;
right: 20px;
border: 0;
}

<!DOCTYPE html>
<html>
<head>
<link type="text/css" rel="stylesheet" href="2.css" />
<title>Google</title>
<style>
a:link,
a:visited {
background-color: #f3f3f3;
color: #222222;
padding: 14px 25px;
text-align: center;
text-decoration: none;
display: inline-block;
}
a:hover,
a:active {
background-color: #e0e0e0;
}
</style>
</head>
<body>
<div id="content">
<img src="22.png" class="icon" />
</div>
<button class="button">Sign in</button>
<p1>Gmail</p1>
<p2>Images</p2>
<div class="item">
<img src="download.png" />
<span class="caption">India</span>
</div>
<input type="text" class="venu">
<p>From giant trees to microscopic beings,<a>explore the world of natural history</a>
</p>
<footer>
<span class="content left">Advertising Business About</span>
<span class="content right">Privacy Terms Settings UseGoogle.com</span>
</footer>
<a href="" target="www.Google.com">Google Search</a>
<a href="" target="www.Google.com">I'm Feeling Lucky</a>
</body>
</html>
&#13;