|
<!DOCTYPE html>입12:20수 12:33分 https://www.youtube.com/watch?v=h3E68tTyE34
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css"/>
<link rel="stylesheet" href="style.css" />
<title>dropdown Menu</title>
<style>
:root {
--color-primary: #0073ff;
--color-white: #e9e9e9;
--color-black: #141d28;
--color-black-1: #212b38;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: sans-serif;
}
.logo {
color: var(--color-white);
font-size: 30px;
}
.logo span {
color: var(--color-primary);
}
.menu-bar {
background-color: var(--color-black);
height: 80px;
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
padding: 0 5%;
position: relative;
}
.menu-bar ul {
list-style: none;
display: flex;
}
.menu-bar ul li {
/* width: 120px; */
padding: 10px 30px;
/* text-align: center; */
position: relative;
}
.menu-bar ul li a {
font-size: 20px;
color: var(--color-white);
text-decoration: none;
transition: all 0.3s;
}
.menu-bar ul li a:hover {
color: var(--color-primary);
}
.fas {
float: right;
margin-left: 10px;
padding-top: 3px;
}
/* dropdown menu style */
.dropdown-menu {
display: none;
}
.menu-bar ul li:hover .dropdown-menu {
display: block;
position: absolute;
left: 0;
top: 100%;
background-color: var(--color-black);
}
.menu-bar ul li:hover .dropdown-menu ul {
display: block;
margin: 10px;
}
.menu-bar ul li:hover .dropdown-menu ul li {
width: 150px;
padding: 10px;
}
.dropdown-menu-1 {
display: none;
}
.dropdown-menu ul li:hover .dropdown-menu-1 {
display: block;
position: absolute;
left: 150px;
top: 0;
background-color: var(--color-black);
}
.hero {
height: calc(100vh - 80px);
background-image: url(./bg.jpg);
background-position: center;
}
</style>
</head>
<body>
<div class="menu-bar">
<h1 class="logo">Light<span>Code.</span></h1>
<ul>
<li><a href="#">Home</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Pages <i class="fas fa-caret-down"></i></a>
<div class="dropdown-menu">
<ul>
<li><a href="#">Pricing</a></li>
<li><a href="#">Portfolio</a></li>
<li>
<a href="#">Team <i class="fas fa-caret-right"></i></a>
<div class="dropdown-menu-1">
<ul>
<li><a href="#">Team-1</a></li>
<li><a href="#">Team-2</a></li>
<li><a href="#">Team-3</a></li>
<li><a href="#">Team-4</a></li>
</ul>
</div>
</li>
<li><a href="#">FAQ</a></li>
</ul>
</div>
</li>
<li><a href="#">Blog</a>
</li>
<li><a href="#">Contact us</a></li>
</ul>
</div>
<div class="hero">
</div>
</body>
</html>
<!-- (D) 텍스트 볼드 스타일이 필요한 메뉴는 a태그 안에 strong태그로 감싸줍니다. --> | |
<li><a href="https://www.hago.kr/templates/mainpage" data-href="{ '_type': 'link' }"><b>홈</b></a></li> | |
<li class="mm_gnb-parent"> | |
<a href="https://www.hago.kr/templates/fashion" data-href="{ '_type': 'link' }"><b>어패럴</b></a> | |
<div class="mm_gnb-sub"> | |
<div class="sub-category-wrap"> | |
<div class="sub-category"> | |
<a href="/goods/category/002000000" data-href="{ '_type': 'link' }">여성<span class="sub-category-arrow">></span></a> | |
</div> | |
<div class="sub-category-children"> | |
<div> | |
<a href="/goods/category/002001000" data-href="{ '_type': 'link' }">아우터</a> | |
</div> | |
<div> | |
<a href="/goods/category/002002000" data-href="{ '_type': 'link' }">상의</a> | |
</div> | |
<div> | |
<a href="/goods/category/002003000" data-href="{ '_type': 'link' }">원피스</a> | |
</div> | |
<div> | |
<a href="/goods/category/002004000" data-href="{ '_type': 'link' }">니트웨어</a> | |
</div> | |
<div> | |
<a href="/goods/category/002005000" data-href="{ '_type': 'link' }">스커트</a> | |
</div> | |
<div> | |
<a href="/goods/category/002006000" data-href="{ '_type': 'link' }">팬츠</a> | |
</div> | |
<div> | |
<a href="/goods/category/002007000" data-href="{ '_type': 'link' }">언더웨어&홈웨어</a> | |
</div> | |
<div> | |
<a href="/goods/category/002008000" data-href="{ '_type': 'link' }">스포츠웨어</a> | |
</div> | |
</div> | |
</div> | |
<div class="sub-category-wrap"> | |
<div class="sub-category"> | |
<a href="/goods/category/003000000" data-href="{ '_type': 'link' }">남성<span class="sub-category-arrow">></span></a> | |
</div> | |
<div class="sub-category-children"> | |
<div> | |
<a href="/goods/category/003001000" data-href="{ '_type': 'link' }">아우터</a> | |
</div> | |
<div> | |
<a href="/goods/category/003002000" data-href="{ '_type': 'link' }">상의</a> | |
</div> | |
<div> | |
<a href="/goods/category/003003000" data-href="{ '_type': 'link' }">니트웨어</a> | |
</div> | |
<div> | |
<a href="/goods/category/003004000" data-href="{ '_type': 'link' }">팬츠</a> | |
</div> | |
<div> | |
<a href="/goods/category/003005000" data-href="{ '_type': 'link' }">스포츠웨어</a> | |
</div> | |
</div> | |
</div> | |
</div> | |
</li> | |
<li class="mm_gnb-parent"> | |
<a href="https://www.hago.kr/templates/accessory" data-href="{ '_type': 'link' }"><b>잡화</b></a> | |
<div class="mm_gnb-sub"> | |
<div class="sub-category-wrap"> | |
<div class="sub-category"> | |
<a href="/goods/category/004000000" data-href="{ '_type': 'link' }">잡화<span class="sub-category-arrow">></span></a> | |
</div> | |
<div class="sub-category-children"> | |
<div> | |
<a href="/goods/category/004001000" data-href="{ '_type': 'link' }">가방</a> | |
</div> | |
<div> | |
<a href="/goods/category/004002000" data-href="{ '_type': 'link' }">슈즈</a> | |
</div> | |
<div> | |
<a href="/goods/category/004003000" data-href="{ '_type': 'link' }">주얼리</a> | |
</div> | |
<div> | |
<a href="/goods/category/004004000" data-href="{ '_type': 'link' }">액세서리</a> | |
</div> | |
<div> | |
<a href="/goods/category/004005000" data-href="{ '_type': 'link' }">리퍼브샵</a> | |
</div> | |
</div> | |
</div> | |
</div> | |
</li> | |
<li class="mm_gnb-parent"> | |
<a href="https://www.hago.kr/templates/life" data-href="{ '_type': 'link' }"><b>라이프</b></a> | |
<div class="mm_gnb-sub"> | |
<div class="sub-category-wrap"> | |
<div class="sub-category"> | |
<a href="/goods/category/005000000" data-href="{ '_type': 'link' }">라이프<span class="sub-category-arrow">></span></a> | |
</div> | |
<div class="sub-category-children"> | |
<div> | |
<a href="/goods/category/005001000" data-href="{ '_type': 'link' }">홈데코</a> | |
</div> | |
<div> | |
<a href="/goods/category/005002000" data-href="{ '_type': 'link' }">키친</a> | |
</div> | |
<div> | |
<a href="/goods/category/005003000" data-href="{ '_type': 'link' }">패브릭</a> | |
</div> | |
<div> | |
<a href="/goods/category/005004000" data-href="{ '_type': 'link' }">가구</a> | |
</div> | |
<div> | |
<a href="/goods/category/005005000" data-href="{ '_type': 'link' }">오피스</a> | |
</div> | |
<div> | |
<a href="/goods/category/005006000" data-href="{ '_type': 'link' }">뷰티</a> | |
</div> | |
<div> | |
<a href="/goods/category/005007000" data-href="{ '_type': 'link' }">홈케어</a> | |
</div> | |
<div> | |
<a href="/goods/category/005008000" data-href="{ '_type': 'link' }">키즈</a> | |
</div> | |
<div> | |
<a href="/goods/category/005009000" data-href="{ '_type': 'link' }">반려동물</a> | |
</div> | |
<div> | |
<a href="/goods/category/005010000" data-href="{ '_type': 'link' }">푸드</a> | |
</div> | |
<div> | |
<a href="/goods/category/005011000" data-href="{ '_type': 'link' }">아웃도어</a> | |
</div> | |
<div> | |
<a href="/goods/category/005012000" data-href="{ '_type': 'link' }">테크</a> | |
</div> | |
</div> | |
</div> | |
</div> | |
</li> | |
<li class="main-live-gnb"><a href="https://www.hago.kr/shoplive" style="color:red;" data-href="{ '_type': 'link' }"><b>LIVE</b></a></li> | |
<li class="gnb-line"> | |
<a href="#none"><span>|</span></a> | |
</li> | |
<li><a href="https://www.hago.kr/rank" data-href="{ '_type': 'link' }"><b>베스트</b></a></li> | |
<li><a href="https://www.hago.kr/event" data-href="{ '_type': 'link' }"><b>이벤트</b></a></li> | |
<li><a href="https://www.hago.kr/brand" data-href="{ '_type': 'link' }"><b>브랜드</b></a></li> | |
</ul> | |
</div> | |
</nav> | |
<!--// gnb --> | |
<script> | |
$('#main_lnb').find('a[href $="goods/detail/437216"]').addClass('__on'); | |
$('#main_lnb').find('a[href $="goods/detail/437216"]').last().attr('title', '선택됨'); | |
$(".mm_gnb-sub").hover( | |
function() { | |
$(this).prev("a").find("b").addClass('active_bar'); | |
}, | |
function() { | |
$(this).prev("a").find("b").removeClass('active_bar'); | |
} | |
); | |
</script> | |
<!--// gnb --> |
브리즈 모달 끈나시
|