Skip to content

first commit and classwork practice #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
315 changes: 315 additions & 0 deletions css.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,315 @@
@import url('https://fonts.googleapis.com/css2?family=Itim&family=Roboto&display=swap');


/*
font-family: 'Itim', cursive;
font-family: 'Roboto', sans-serif;

//Holding this for reference// */

@font-face{
font-family:jungle;
src:url(jungle.ttf);
} /* this is a way to import external fonts that you've dl and can be added in css */


/* Universal Style Section */
*{
max-width: 100%;/* doesnt allow divs to go rogue */
box-sizing: border-box;
}

/* Header */

header{
display: flex;
justify-content: space-between;
width: 100%;
height: 140px;
padding: 20px;
background: rgba(115,167,136,.8);
margin-bottom: 20px;/* for the space between the header and the next box*/
}

header a{
text-decoration: none; /*gets rid of the underline for links*/
}
.logo{
background:url(images/logo.png) no-repeat;
background-size:100px;
font-family: jungle;
font-size: 3rem;
color:#135e46;
padding-left: 100px;/* to move the logo over to the left to get away from the text */
text-shadow: 3px 3px black; /* helps the text be readable and gives depth */
transition: .3s; /* animates the logo */
}

.logo:hover{
transform: translate(10px);
color: white;
}
nav{ /* flexbox inside flexbox */
display: flex;
width: 40%;
justify-content: space-around;
align-items: center;
}
nav a{ /* stylizing the a tags inside nav*/
font-family: jungle;
color: #b67b65;
font-size: 1.8rem;
text-shadow: 2px 2px black;
transition: .3s;
}

nav a:hover{ /* for the mouse to interact */
color: white;
transform: scale(1.3);
}

/* Banner Style Section*/

.banner{
display: flex;
width: 100%;
height: 60vh;
background: url(images/slothStare.jpg) no-repeat;
background-position: center;
background-size: cover; /*using bg-pos and bg-size will help stylize the image*/
align-items: center;
margin-bottom: 20px;
}

.banner:hover .slothText{
opacity: 1;
}
.slothText{
width:30%;
height: auto;
opacity: 0;
background: rgba(115,167,136,.8);
border-radius: 10px;
color:white;
padding: 15px;
margin-right: 20px;
text-shadow: 1px 1px black;
font-family:'Roboto', sans-serif;
font-size: 1.1rem;
transition: .5s;
}

/* Sloths Style Section*/

.meetSloths{
height: 50vh;
width: 100%;
background: rgba(115,167,136,.8);
}

.sloths{
width: 100%;
display: flex;
justify-content: space-evenly;
}

h1{
font-family: 'Roboto', sans-serif;
font-size: 1.7rem;
color: white;
text-shadow: 2px 2px black;
margin: 0 0 40px 30px;
padding-top: 40px;
}

.sloths div{
width: 25%;
height: 30vh;
border: 5px solid white;
border-radius: 20px;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background-position: center;
background-size: cover;
}

.sloth1{
background:url(images/slothHanging.jpg) no-repeat;
}
.sloth2{
background:url(images/slothClimbing.jpg) no-repeat;
}
.sloth3{
background:url(images/slothChilling.jpg) no-repeat;
}

.sloths div div{
width: 70%;
height: auto;
background: rgba(115,167,136,.8);
border-radius: 10px;
padding:15px;
font-size: 1rem;
color:white;
text-shadow: 1px 1px black;
font-family:'Roboto', sans-serif;
text-align: center;
opacity: 0;
transition: .5s;
}

.sloths div:hover div{
display: flex;
height: 10vh;
width: 100%;
justify-content: space-evenly;
align-items: center;
opacity: 1;
}

/* Footer Styling */


footer{
display: flex;
width:100%;
height: 15vh;
justify-content: space-evenly;
align-items: center;
}

footer img{
width: 50px;
}
footer img:hover{
transition: 1s;
transform: scale(1.5);
}

footer span{
font-family:'Roboto', sans-serif;
}
footer span:hover{
color:#135e46;
transition: 1s;
transform: scale(1.5);
}
footer a{
text-decoration: none;
font-family: 'Roboto', sans-serif;
color: black;
font-size: 1rem;
transition:.3s;
}
footer a:hover{
color:#135e46;
transform: scale(1.3);
transition:1s;
}

/* ******* MEDIA STYLES ******* */

@media(max-width:800px){/* anything less than 800px will inherit the styles*/


/* Header */

header{
display: flex;
justify-content: space-around;
flex-direction: column;
height: 180px;
padding: 10px;
align-items: center;
margin-bottom: 10px;
}
.logo{
background-size:80px;
font-size: 2.3rem;
padding-left: 80px;
}
nav{
display: flex;
width: 100%;
justify-content: space-evenly;
}
nav a{
font-size: 1.5rem;
}

/* Banner Style Section*/

.banner{
display: flex;
width: 100%;
height: 40vh;
align-items: center;
margin-bottom: 20px;
}

.slothText{
width:100%;
height: auto;
margin-right: 20px;
opacity: 1;
padding: 10px;
font-size: .9rem;
position: relative;
top: 30%;

}

/* Sloths Style Section*/

.meetSloths{
height: auto;
width: 100%;
text-align: center;
}
.meetSloths h1:hover{
color:#135e46;
transform:scale(1.3);
transition:1s;
}
.sloths{
width: 100%;
display: flex;
flex-direction: column;
justify-content: space-evenly;
align-items: center;
}

h1{
font-size: 1.5rem;
}

.sloths div{
width: 90%;
height: 35vh;
margin-bottom: 20px;
}

.sloth div div{
width: 90%;
height: auto;
padding:10px;
font-size: 1rem;
text-align: center;
opacity: 1;
position: relative;
top: 35%;
}
footer{
display: flex;
flex-direction: column;
height: 15vh;
}

footer img{
display: none;
}


} /* closing media query bracket */
58 changes: 58 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,67 @@
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <!-- need this for mobile, uses to expand the content for mobile users-->
<link rel="stylesheet" href="css.css">
<link rel="stylesheet" href="images/favicon.png">

<title>Sloth Sanctum - Enjoying Life in the Slow Lane</title>
</head>
<body>

<header>
<a href="index.html">
<div class="logo">
SLOTH<br>SANCTUM<!-- will get stylize in css, no need to span/p cuz of styling later-->
</div>
</a>
<nav>
<a href="#" class="href">HOME</a>
<a href="##" class="href">ABOUT</a>
<a href="###" class="href">CONTACT</a>
</nav>
</header>
<section class="banner">
<div class="slothText">
<h2>Slots Are Wonderful</h2>
<p>Sloths are a group of arboreal Neotropical xenathran mammals, constituting the suborder Folivora. Noted for their slowness of movement, they spend most of their lives hanging upside down in the trees of the tropical rainforests of South America and Central America. </p>
</div>
</section>

<section class="meetSloths">
<h1>Come Meet Our Friendly Sloths!</h1>
<div class="sloths">
<div class="sloth1">
<div>
<span>Flash</span>
He's the fastest sloth ever recorded
</div>
</div>

<div class="sloth2">
<div>
<span>Pricilla</span>
She works with Flash, she's his main lover.
</div>
</div>

<div class="sloth3">
<div>
<span>Sid</span>
He's been around since the ice age, hates acorns for some reason.
</div>
</div>
</div>

</section>

<footer>
<img src="images/logo.png">
<span>Copyright &copy;2020</span>
<a href="tel:8009997777">Call a Sloth</a>
</footer>



</body>
</html>