3D World page

 index.html

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="style.css">
</head>
<body>
    <div class="a">
        <div class="b">
            <h1>Welcome to the 3D World</h1>
            <p>Lorem ipsum dolor sit amet consectetur, adipisicing elit. Voluptas nisi, totam facere autem porro minus.</p>
            <button>Explore</button>
        </div>
    </div>

</body>

<!-- <script src="https://unpkg.com/@lottiefiles/lottie-player@latest/dist/lottie-player.js"></script> -->
</html>

style.css

*{
    margin:0;
    padding:0;
    box-sizing: border-box;
    font-family: gilroy;
}
html,body{
    width: 100%;
    height: 100%;
}
.a{
    width: 100%;
    height: 100%;
    background-image: url("https://images.unsplash.com/photo-1622737133809-d95047b9e673?ixlib=rb-4.0.3&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=1332&q=80");
    background-position: center;
    background-size: cover;
}
.b{
    width: 30%;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    position: absolute;
    text-align: center;
}
.b h1{
    font-size: 60px;
    font-weight: 500;
    color: white;
}
.b p{
    color:white;
    font-size: 18px;
    margin-top: 20px;
    letter-spacing: 2px;
}
.b button{
    background:none;
    padding: 10px 40px;
    border: 2px solid wheat;
    margin-top: 20px;
    color: white;
    font-weight: 600;
    font-size: 20px;
    transition: 1s;
}
.b button:hover{
    background:none;
    padding: 10px 40px;
    background-color: white;
    /* border: 2px solid rgb(172, 112, 0); */
    margin-top: 20px;
    border-radius:  10px;
    color: black;
    font-weight: 600;
    font-size: 20px;
}

output: - 





Post a Comment

Post a Comment (0)

Previous Post Next Post