CSS:
.header-cat-menu {
background-color: rgba(0, 0, 0, 0.2);
position: absolute;
left: 0;
z-index: 10000;
width: 100vw;
overflow-y: auto;
@media screen and (min-width:768px) and (max-width:992px) {
margin-left: calc(-1 * var(--layout-side-padding));
margin-top: calc(-1* var(--layout-pt));
}
.m-cat-menu {
position: relative;
padding-left: 300px;
padding-top: 24px;
padding-bottom: 48px;
display: inline-block;
@include background-color(--bg-cat-menu);
height: auto;
&__level-1 {
z-index: 10001;
padding-top: 20vm;
}
&__level-2 {
z-index: 10002;
}
&__back-btn {
display: none;
}
ul {
display: inline-block;
list-style: none;
margin: 0;
padding: 0;
li {
display: flex;
align-items: center;
width: 300px;
font-size: 14px;
padding-bottom: 16px;
padding-right: 32px;
&.title {
color: var(--color-text);
font-size: 18px;
font-weight: bold;
}
a {
display: flex;
align-items: center;
width: 100%;
text-decoration: none;
color: var(--color-text);
img {
width: 40px;
height: 40px;
object-fit: cover;
border-radius: var(--img-border-radius);
}
span.title {
color: var(--color-text);
font-weight: 800;
margin-left: 16px;
}
span.icon {
margin-left: auto;
font-size: 18px;
display: none;
}
}
&:hover {
& > a {
color: var(--color-active-link);
span.title {
color: var(--color-active-link);
}
span.icon {
display: inline;
}
}
}
& > .m-cat-menu__wrapper {
@include background-color(--bg-cat-menu);
display: none;
position: absolute;
top: 0;
left: 100%;
height: 100%;
ul {
list-style: none;
height: auto;
padding-top: 24px;
padding-left: 32px;
}
&::before {
content: "";
width: 2px;
height: calc(100% - 48px);
background: #e8f1ff;
display: block;
position: absolute;
left: 0;
}
}
}
li.is-current {
& > a {
color: var(--color-active-link);
span.title {
color: var(--color-accent-text);
}
}
}
}
}