Mobile navigation
This commit is contained in:
1 parent
35caa410ff
commit
35bed40129
6 files changed
+199
-13
No files matched your search
@@ -57,6 +57,50 @@
|
||||
.contact-grid {
|
||||
gap: 0;
|
||||
}
|
||||
|
||||
.btn-mobile-nav {
|
||||
display: block;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
.nav-links {
|
||||
background-color: rgb(11, 21, 50, 0.9);
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
width: 30%;
|
||||
height: 40vh;
|
||||
transform: translateX(100%);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border-bottom-left-radius: 100px;
|
||||
transition: all 0.4s ease-in;
|
||||
|
||||
opacity: 0;
|
||||
pointer-events: none;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.nav-open .nav-links {
|
||||
opacity: 1;
|
||||
pointer-events: auto;
|
||||
visibility: visible;
|
||||
transform: translateX(0);
|
||||
}
|
||||
|
||||
.nav-open .icon-mobile-nav[name="close"] {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.nav-open .icon-mobile-nav[name="open"] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.main-nav-link {
|
||||
font-size: 3rem;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 47em) {
|
||||
@@ -102,6 +146,9 @@
|
||||
.contact-img {
|
||||
grid-row: 1;
|
||||
}
|
||||
.nav-links {
|
||||
width: 40%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 38em) {
|
||||
@@ -111,6 +158,9 @@
|
||||
.hero {
|
||||
max-width: 90%;
|
||||
}
|
||||
.nav-links {
|
||||
width: 50%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 31em) {
|
||||
@@ -136,4 +186,7 @@
|
||||
.heading-sub {
|
||||
max-width: 80%;
|
||||
}
|
||||
.nav-links {
|
||||
width: 60%;
|
||||
}
|
||||
}
|
||||
+24
-2
@@ -50,6 +50,7 @@ html {
|
||||
/* font-size: 10px; */
|
||||
font-size: 62.5%;
|
||||
scroll-behavior: smooth;
|
||||
overflow-x: hidden;
|
||||
}
|
||||
|
||||
body {
|
||||
@@ -59,6 +60,11 @@ body {
|
||||
color: #fff;
|
||||
background-color: #0b1532;
|
||||
font-size: 2rem;
|
||||
overflow-x: hidden;
|
||||
}
|
||||
|
||||
.header {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.nav {
|
||||
@@ -103,10 +109,26 @@ body {
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.rocket-icon {
|
||||
max-width: 4rem;
|
||||
.btn-mobile-nav {
|
||||
border: none;
|
||||
background: none;
|
||||
cursor: pointer;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.icon-mobile-nav {
|
||||
height: 5rem;
|
||||
width: 5rem;
|
||||
}
|
||||
|
||||
.icon-mobile-nav[name="close"] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* .rocket-icon {
|
||||
max-width: 4rem;
|
||||
} */
|
||||
|
||||
.main-nav-link.nav-btn:link,
|
||||
.nav-btn:visited {
|
||||
transition: all 0.3s;
|
||||
|
||||
Reference in new issue
Block a user