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

Improved Navbar UI #243

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
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
100 changes: 47 additions & 53 deletions Css-files/navbarstyles.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,61 +6,56 @@ body {

/* Navbar styles */
.navbar {
background-color: rgba(255, 255, 245, 0.8);
background-color: #ffcd9f; /* Solid background color */
position: sticky;
top: 0;
padding: 1rem;
display: flex;
width: 100%;
justify-content: space-between;
margin: 10px 1px!important;
border-radius: 20px;
margin: 10px 4rem!important;
margin-left: 4.5rem!important;
border-radius: 25px;
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
z-index: 100; /* Ensures it stays on top */
}

.nav-right {
margin-left: auto;
/* Pushes the login/signup to the right side */
display: flex;
gap: 15px;
/* Space between login and signup */
}

.ms-auto {
margin-left: auto;
/* Pushes to the right */
gap: 20px;
align-items: center;
}

.navbar-brand {
font-size: 1.5rem;
font-size: 1.8rem;
color: black;
font-weight: bold;
transition: transform 0.3s ease;
font-family: 'Philosopher', sans-serif;
}

.navbar-brand:hover {
transform: scale(1.6);
}

.navbar-nav .nav-item {
margin-right: 15px;
transform: scale(1.2);
color: #e06b6b;
}

.nav-link {
color: black;
font-size: 1rem;
font-family: var(--ff-philosopher);
font-size: 1.1rem;
font-family: 'Philosopher', sans-serif;
text-decoration: none;
/* Remove default underline */
position: relative;
transition: all 0.3s ease;
padding: 0 10px;
}

.nav-item.dropdown .nav-link {
text-decoration: none;
/* No underline for dropdown toggle */
.cart-shopping{
margin-right: 1rem;
}

.nav-link:hover {
text-decoration: none;
/* Prevent default underline on hover */
color: #e06b6b;
}

.nav-link::after {
Expand All @@ -69,15 +64,10 @@ body {
left: 0;
bottom: -5px;
width: 0%;
height: 3.5px;
/* Thicker underline */
height: 2px;
background: transparent;
transition: all 0.3s ease-in-out;
box-shadow:
0 0 30px rgba(255, 159, 128, 1),
/* Initial glow effect with bright peach color */
0 0 60px rgba(255, 159, 128, 1);
/* Increased glow effect */
box-shadow: 0 0 15px rgba(255, 159, 128, 0.8);
}

.nav-link:hover::after {
Expand All @@ -94,10 +84,11 @@ body {
color: black;
text-decoration: none;
position: relative;
padding: 0 10px;
}

.nav-btn:hover {
color: #d2691e;
color: #e06b6b;
}

.nav-btn::after {
Expand All @@ -108,24 +99,18 @@ body {
width: 0%;
height: 2px;
background: #ffb6c1;
/* Adjust to match background color */
transition: all 0.3s ease-in-out;
box-shadow: 0 20px #ffb6c1;
/* Glow effect */
}

.nav-link:hover::after {
.nav-btn:hover::after {
background: rgba(255, 159, 128, 1);
width: 100%;
box-shadow:
0 0 25px rgba(255, 159, 128, 1),
0 0 50px rgba(255, 159, 128, 1);
/* Glow effect with bright peach color */
box-shadow: 0 0 25px rgba(255, 159, 128, 0.8);
}

.nav-link:hover,
.nav-btn:hover {
color: hwb(327 21% 3%) !important;
color: #d2691e !important;
}

.dropdown-menu {
Expand All @@ -134,34 +119,43 @@ body {
}

.dropdown-item {
/*color: black;*/
font-family: var(--ff-philosopher);
font-family: 'Philosopher', sans-serif;
}

.dropdown-item:hover {
background-color: #f0c0a0;
color: #d2691e;
}

.nav-right a, .nav-right button {
padding: 0 15px;
}

.nav-right .cart-btn {
font-size: 1.2rem;
position: relative;
}

.cart-btn:hover {
color: #e06b6b;
}

/* Mobile Styles */
@media (max-width: 768px) {
.navbar-brand {
margin-left: 10px;
font-size: 1.5rem;
}

.navbar-nav {
text-align: center;
}

.navbar-toggler {
border: none;
}

.navbar-toggler-icon {
color: black;
}

.nav-item {
margin-bottom: 1rem;
}
}

.nav-right {
gap: 10px;
}
}
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@
<a class="nav-link" onclick="redirectSignup()"
style="color: black; font-family: var(--ff-philosopher);">Signup</a>
</li>
<li class="nav-item" style="list-style-type: none;">
<li class="nav-item cart-shopping" style="list-style-type: none;">
<a class="nav-link" href="Html-files/cart.html" style="color: black;"><i
class="fa-solid fa-cart-shopping"></i>Cart</a>
</li>
Expand Down
15 changes: 12 additions & 3 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,16 @@ body {
}
*/

.navbar-brand{
color: #a42b2a !important;
font-size: 1.7rem !important;
margin-left: 1rem;
}

.navbar.fixed-top {
position: fixed;
top: 0;
width: 100%;
top: 0.6rem;
width: 90%;
z-index: 1030;
}
.navbar.scrolled {
Expand Down Expand Up @@ -601,7 +607,7 @@ ul p {
ul a {
display: block;
font-size: 0.85rem;
margin-top: 10px;
/* margin-top: 10px; */
color: #dddddd;
text-decoration: none;
}
Expand Down Expand Up @@ -682,6 +688,9 @@ textarea {
transform: scale(1.5); /* Increase size */
transition: transform 0.3s ease; /* Smooth transition effect */
}
.fa-cart-shopping {
margin-left: 1.5rem;
}
.fa-brands.fa-facebook:hover {
color: #3B5998 !important;
}
Expand Down