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
1 change: 1 addition & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ <h1 class="newspaper-name">Ironhack News</h1>
<li><a href="#">Sports</a></li>
</ul>
</nav>
<img src="./images/menu-icon.png" alt="menu" class="menu-icon">
</header>

<main>
Expand Down
120 changes: 119 additions & 1 deletion styles/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ header {
justify-content: space-between;
flex-direction: row;
align-items: center;
padding: 20px;
padding: 10px;
}

.article {
Expand Down Expand Up @@ -177,3 +177,121 @@ header {
}

/* Write your CSS below */
.articles-container {
justify-content: space-around;
padding: 1rem;
gap: 1rem;
}


@media (max-width: 760px){
.navbar{
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 8px;
padding: 0;
margin: 0;
}
.navbar li{
width: 100%;
border: none;
border-bottom: 1px solid white;
}
.navbar a{
display: flex;
text-align: center;
}
.main-article .image .main-article .content{
padding: 0px;
width: 100%;
}

.main-article {
width: 100%;
height: 100%;
flex-direction: column;
margin: 0px;
padding: 10px 10px;
justify-content: center;
align-items: center;
gap: 1rem;
}
.main-article .content {
width: 100%;
}
.main-article .image {
width: 100%;
}

.article {
width: 100%;
padding: 1rem;
border: 1px solid #ccc;
}

.article img {
width: 100%;
height: auto;
}

.btn{ width: fit-content; }

.articles-container{
display: flex;
flex-direction: column;
gap: 10px;
}
}

@media (max-width: 1024px) and (min-width: 760px){
.navbar{
display: flex;
align-items: center;
justify-content:space-around;
padding: 0;
margin: 0;
}
.navbar li{
width: 100%;
border: none;
border: 0.5px solid white;
}
.articles-container {
display: flex;
flex-direction: row;
gap: 1rem;
justify-content: space-around;

}
.article{
width: 45%;
}
}


.menu-icon {
display: none;
}

@media (max-width: 480px){
header {
display: flex;
flex-direction: column;
align-items: center;
border: none;
}

.menu-icon {
display: block;
flex-direction: column;
align-items: center;
}
.navbar {
display: none;
}
.newspaper-name {
border-bottom: none;
}
}