Skip to content
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

Navbar Not Responsive on Mobile Devices #547 #578

Closed
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
39 changes: 25 additions & 14 deletions assets/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ body.nav-active .navbar-list .navbar-link {
.header .container,
.navbar-top {
display: flex;
justify-content: space-between;
justify-content: space-evenly;
align-items: center;
}

Expand Down Expand Up @@ -967,7 +967,7 @@ button:hover {
/* Media query for smaller screens */
@media (max-width: 768px) {
.container {
flex-direction: column;
flex-direction: row;
align-items: center;
gap: 20px;
}
Expand Down Expand Up @@ -1445,30 +1445,35 @@ button:hover {
\*-----------------------------------*/

/**
* responsive for large than 575px screen
* responsive for Smaller than 575px screen
*/

@media (min-width: 575px) {
@media (max-width: 575px) {
/**
* REUSED STYLE
*/

.container {
max-width: 640px;
/* max-width: 640px; */
width: 100%;
margin-inline: auto;
/* margin-inline: auto; */
margin-left: 0;
}

.card {
padding: 32px;
}

.nav-open-btn{
margin-right: 20px;
}
}

/**
* responsive for large than 768px screen
*/

@media (min-width: 768px) {
@media (max-width: 768px) {
/**
* CUSTOM PROPERTY
*/
Expand All @@ -1492,9 +1497,6 @@ button:hover {
* REUSED STYLE
*/

.container {
max-width: 768px;
}

.grid-list {
grid-template-columns: 1fr 1fr;
Expand Down Expand Up @@ -1535,6 +1537,7 @@ button:hover {

.container {
max-width: 1024px;
margin-left: 0;
}

.btn {
Expand All @@ -1554,6 +1557,13 @@ button:hover {
display: none;
}

/* .nav-open-btn{
display: flex;
justify-content: flex-end;

align-items: end;
} */

.navbar,
.navbar.active {
all: unset;
Expand Down Expand Up @@ -1627,6 +1637,7 @@ button:hover {

.container {
max-width: 1170px;
margin-left: 0;
}

/**
Expand Down Expand Up @@ -1841,10 +1852,10 @@ button:hover {
gap: 30px;
}

#theme-toggle {
right: 125px;
top: 5px;
}
/* #theme-toggle {
/* right: 125px; */
/* top: 5px; */
/* } */ */

/* Can be used if wanting a more linear Instagram post feed but as a viewer I like the grid better
.footer-top .grid-list {
Expand Down
4 changes: 2 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
<header class="header" data-header>


<div class="container" style="margin-left: 13rem;">
<div class="container" >

<a href="#">
<img src="./assets/images/Skillwise_logo-removebg-preview.png" width="50" height="10" alt="SkillWise home">
Expand Down Expand Up @@ -506,7 +506,7 @@ <h2 class="headline-md section-title">
<p id="keppi" class="title-sm section-subtitle text-center ">Featured Courses</p>

<h2 class="headline-md section-title text-center" id="course-label" data-aos="fade-down">
<div class="header1">Choose Unlimited <span class="span has-after">Courses</span< /div> >
<div class="header1">Choose Unlimited <span class="span has-after">Courses</span></div>
</h2>

<ul class="grid-list">
Expand Down