mirror of
https://github.com/ArthurDanjou/arthurdanjou.fr.git
synced 2026-01-14 12:14:34 +01:00
200 lines
3.4 KiB
SCSS
200 lines
3.4 KiB
SCSS
$cross-closed: black;
|
|
$cross-opened: red;
|
|
$menu-background: rgb(38, 38, 38);
|
|
$hover-color: rgba(205, 205, 205, 0.3);
|
|
|
|
#header {
|
|
z-index: 100;
|
|
position: fixed;
|
|
width: 100%;
|
|
height: 10%;
|
|
|
|
ul {
|
|
list-style: none;
|
|
}
|
|
|
|
@media screen and (max-width: 700px) {
|
|
height: 75px;
|
|
width: 100%;
|
|
background-color: rgba(49, 49, 49, 0.8);
|
|
}
|
|
|
|
.logo {
|
|
z-index: 100;
|
|
position: fixed;
|
|
top: 6%;
|
|
left: 5%;
|
|
font-size: $web-h1;
|
|
font-weight: 700;
|
|
cursor: pointer;
|
|
transition: .3s;
|
|
text-align: center;
|
|
line-height: 1.5rem;
|
|
|
|
&:active {
|
|
transform: scale(0.85);
|
|
}
|
|
|
|
&:hover {
|
|
color: grey;
|
|
}
|
|
|
|
@media screen and (max-width: 700px) {
|
|
font-size: $mobile-h1;
|
|
top: 3%;
|
|
left: 4%;
|
|
|
|
&.opened {
|
|
display: none;
|
|
}
|
|
}
|
|
}
|
|
|
|
.cross {
|
|
z-index: 100;
|
|
position: fixed;
|
|
top: 5%;
|
|
right: 5%;
|
|
width: 64px;
|
|
height: 64px;
|
|
font-size: 24px;
|
|
font-weight: 700;
|
|
line-height: 20px;
|
|
cursor: pointer;
|
|
|
|
@media screen and (max-width: 700px) {
|
|
top: 1%;
|
|
width: 48px;
|
|
right: 5%;
|
|
}
|
|
|
|
&:active::before, &:active::after {
|
|
transform: scale(0.85);
|
|
}
|
|
|
|
&:before, &:after {
|
|
position: absolute;
|
|
transition: transform .3s;
|
|
display: block;
|
|
content: "";
|
|
height: 5px;
|
|
width: 100%;
|
|
background-color: $cross-closed;
|
|
|
|
@media screen and (max-width: 700px) {
|
|
height: 3px;
|
|
}
|
|
}
|
|
|
|
&:before {
|
|
top: 22px;
|
|
}
|
|
|
|
&:after {
|
|
bottom: 22px;
|
|
right: 0;
|
|
width: 65%;
|
|
}
|
|
|
|
&.opened {
|
|
&:before, &:after {
|
|
width: 100%;
|
|
background-color: $cross-opened;
|
|
}
|
|
|
|
&:before {
|
|
top: 30px;
|
|
transform: rotate(-45deg);
|
|
}
|
|
|
|
&:after {
|
|
bottom: 30px;
|
|
left: 0;
|
|
transform: rotate(45deg);
|
|
box-shadow: 0 0 0 4px $menu-background, 0 0 12px 8px $menu-background;
|
|
}
|
|
}
|
|
}
|
|
|
|
.menu {
|
|
user-select: none;
|
|
opacity: 0;
|
|
visibility: hidden;
|
|
position: absolute;
|
|
top: 40%;
|
|
right: 4.5%;
|
|
height: 80px;
|
|
width: 80px;
|
|
transition: opacity .3s;
|
|
padding: 25px;
|
|
border-radius: 5px;
|
|
|
|
a {
|
|
padding: 2px 3px;
|
|
box-shadow: inset 0 -10px 0 $hover-color;
|
|
transition: box-shadow 0.2s ease-in-out;
|
|
|
|
&:hover, &.active {
|
|
box-shadow: inset 0 -100px 0 $hover-color;
|
|
}
|
|
}
|
|
|
|
.pages-link {
|
|
margin-top: 40px;
|
|
transition: transform .5s;
|
|
transform: translateY(60px);
|
|
.title {
|
|
font-size: 22px;
|
|
font-weight: 700;
|
|
}
|
|
li {
|
|
font-size: 20px;
|
|
padding: 7px 20px;
|
|
}
|
|
}
|
|
|
|
.contact-links {
|
|
margin-top: 50px;
|
|
transition: transform .5s;
|
|
transform: translateY(80px);
|
|
border-top: solid 1px $white;
|
|
|
|
ul {
|
|
margin-top: 20px;
|
|
display: flex;
|
|
flex-direction: row;
|
|
justify-content: space-evenly;
|
|
|
|
li {
|
|
padding: 3px 5px;
|
|
}
|
|
}
|
|
}
|
|
|
|
&.opened {
|
|
z-index: 99;
|
|
height: 375px;
|
|
width: 350px;
|
|
color: $white;
|
|
background-color: $menu-background;
|
|
opacity: 1;
|
|
visibility: visible;
|
|
|
|
@media screen and (max-width: 700px) {
|
|
border-radius: 0;
|
|
top: 0;
|
|
right: 0;
|
|
width: 100%;
|
|
height: 150vh;
|
|
}
|
|
|
|
.pages-link {
|
|
transform: translateY(0);
|
|
}
|
|
|
|
.contact-links {
|
|
transform: translateY(0);
|
|
}
|
|
}
|
|
}
|
|
} |