Skip to content
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
2 changes: 2 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
<body>
<header>
<h1 class="newspaper-name">Ironhack News</h1>

<nav>
<button class="toggle-button"><img src="/images/menu-icon.png" alt="sandwich-button"></button>
<ul class="navbar">
<li><a href="#">Home</a></li>
<li><a href="#">News</a></li>
Expand Down
97 changes: 97 additions & 0 deletions styles/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -177,3 +177,100 @@ header {
}

/* Write your CSS below */

/*make the button disapear*/
.toggle-button {
display: none;
/*/ "display: "block" para aparecer*/
}

@media screen and (max-width: 480px){

.toggle-button {
display: block;
width: 100%;
background: none;
border: none;
line-height: 2rem;
}

.newspaper-name {
border-bottom: none;
}

.navbar {
display: none;
}

}


@media screen and (max-width: 760px){

/* Header and Navbar */
.navbar {
flex-direction: column;
}

.navbar li {
width: auto;
border-bottom: 1px solid #ffffff;
border-right: none;
}

.main-article {
flex-direction: column;
}

.main-article .image {
width: 100%;
padding-bottom: 20px;
}

.main-article .content {
width: 100%;
}

/* Articles */
.articles-container {
justify-content: space-between;
flex-direction: column;
align-items: center;
padding: 20px;
}

.article {
width: auto;
margin-bottom: 40px;
}

}

@media screen and (max-width: 1024px) and (min-width: 760px) {

/* Header and Navbar */
.navbar {
justify-content: space-evenly;
}

.navbar li {
width: 100%;
border-right: 1px solid #ffffff;
}

.main-article .image {
width: 50%;
}

/* Articles */
.articles-container {
justify-content: space-between;
flex-wrap: wrap;
}

.article {
width: 45%;
margin-bottom: 40px;
}

}