📅2024. 01. 17 28일차
.fixed {
position: fixed;
}
트랜지션(transition)은 CSS 프로퍼티의 값이 변화할 때, 프로퍼티 값의 변화가 일정 시간(duration)에 걸쳐 일어나도록 하는 것이다.
transition: background-color 2s
,로 걸어준다.opacity로 요소의 투명도를 정할 수 있다.
기본값 : 1
상속 : No
애니메이션 : Yes
opacity: number | initial | inherit
div:after {...}
div:before {...}

<nav class="menu_box_1 ">
<!--980-->
<ul class="row">
<!--980-->
<li class="cell"><a href="#">BRAND</a></li>
<li class="cell"><a href="#">VISUAL</a></li>
<li class="cell"><a href="#">STYLE</a></li>
<li class="cell"><a href="#">MEDIA</a></li>
<li class="cell"><a href="#">NEWS</a></li>
<li class="cell"><a href="#">STORE</a></li>
<li class="cell"><a href="#">CUSTOMER</a></li>
</ul>
</nav>
/* 노말라이즈 */
body,
ul,
li {
margin: 0;
padding: 0;
list-style: none;
}
a {
color: inherit;
text-decoration: none;
}
/* 라이브러리 */
.font_size_0 {
font-size: 0;
}
.font_size_0 > * {
font-size: 1rem;
}
.row::after {
content: "";
clear: both;
display: block;
}
.cell {
float: left;
}
/* 커스텀 */
.menu_box_1 {
margin-top: 50px;
border: 10px solid red;
width: 980px;
margin-left: auto;
margin-right: auto;
}
.menu_box_1 > ul {
background-color: #afafaf;
}
.menu_box_1 > ul > li {
background-color: pink;
width: 14.2858%;
}
.menu_box_1 > ul > li > a {
display: block;
padding: 5px 0;
font-weight: bold;
background-color: gold;
text-align: center;
}

<!-- 유용한 링크 -->
<!-- cdnsj : https://cdnjs.com/ -->
<!-- 폰트어썸 아이콘 리스트 : https://fontawesome.com/icons?d=gallery&m=free -->
<!-- 구글 폰트 불러오기 -->
<!-- rotobo(400/700/900), notosanskr(400/600/900) -->
<link href="https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@400;700;900&family=Roboto:wght@400;700;900&display=swap" rel="stylesheet">
<!-- 폰트어썸 불러오기 -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css">
<!-- 제이쿼리 불러오기 -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.1/jquery.min.js"></script>
<div class="top_bar flex flex-jc-sa">
<a href="#" class="logo flex flex-ai-c">
<i class="fa-brands fa-android"></i>
</a>
<nav class="menu_box_1 ">
<ul class="flex height-100p ">
<li class=" padding10"><a class="flex flex-ai-c height-100p" href="#">1차 메뉴 아이템 1</a></li>
<li class="padding10"><a class="flex flex-ai-c height-100p" href="#">1차 메뉴 아이템 2</a></li>
<li class="padding10"><a class="flex flex-ai-c height-100p" href="#">1차 메뉴 아이템 3</a></li>
<li class="padding10"><a class="flex flex-ai-c height-100p" href="#">1차 메뉴 아이템 4</a></li>
</ul>
</nav>
</div>
@import url(//fonts.googleapis.com/earlyaccess/notosanskr.css);
html {
/* 영문이면 roboto가 적용되고, 한글이면 Noto Sans KR가 적용되도록 아래와 같은 순서로 배치 */
font-family: "Roboto", "Noto Sans KR", sans-serif;
}
/* 노말라이즈 */
body,
ul,
li,
h1 {
margin: 0;
padding: 0;
list-style: none;
}
a {
color: inherit;
text-decoration: none;
}
label[for] {
cursor: pointer;
user-select: none;
}
/* 라이브러리 */
.block {
display: block;
}
.inline-block {
display: inline-block;
}
.absolute-left {
position: absolute;
left: 0;
}
.absolute-right {
position: absolute;
right: 0;
}
.absolute-bottom {
position: absolute;
bottom: 0;
}
.absolute-top {
position: absolute;
top: 0;
}
.absolute-center {
position: absolute;
left: 50%;
transform: translateX(-50%);
}
.absolute-middle {
position: absolute;
top: 50%;
transform: translateY(-50%);
}
.absolute-middle.absolute-center {
position: absolute;
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
}
.relative {
position: relative;
}
.cell {
float: left;
box-sizing: border-box;
}
.cell-right {
float: right;
box-sizing: border-box;
}
.row::after {
content: "";
display: block;
clear: both;
}
.clear-both {
clear: both;
}
.img-box > img {
width: 100%;
display: block;
}
.con {
margin-left: auto;
margin-right: auto;
}
.margin-0-auto {
margin-left: auto;
margin-right: auto;
}
.text-align-center {
text-align: center;
}
.text-align-right {
text-align: right;
}
.line-height-0 {
line-height: 0;
}
.line-height-0 > * {
line-height: normal;
}
.width-30px {
width: 30px;
}
.width-35px {
width: 35px;
}
.width-40px {
width: 35px;
}
.width-45px {
width: 35px;
}
.width-50px {
width: 50px;
}
.width-80px {
width: 80px;
}
.width-100px {
width: 100px;
}
.width-100p {
width: 100%;
}
.width-60p {
width: 60%;
}
.width-55p {
width: 55%;
}
.width-50p {
width: 50%;
}
.width-45p {
width: 45%;
}
.width-40p {
width: 40%;
}
.width-30p {
width: 30%;
}
.width-35p {
width: 35%;
}
.width-100p-except-30px {
width: calc(100% - 30px);
}
.width-100p-except-35px {
width: calc(100% - 35px);
}
.width-100p-except-40px {
width: calc(100% - 40px);
}
.width-100p-except-50px {
width: calc(100% - 50px);
}
.width-100p-except-80px {
width: calc(100% - 80px);
}
.width-100p-except-100px {
width: calc(100% - 100px);
}
.height-100p {
height: 100%;
}
.height-50p {
height: 50%;
}
.border-box {
box-sizing: border-box;
}
.font-size-dot-8rem {
font-size: 0.8rem;
}
.table-row {
display: table;
}
.table-row.row::after {
display: inline;
clear: non;
}
.table-row > .cell {
float: none;
display: table-cell;
}
.border-red {
border: 10px solid red;
}
.border-green {
border: 10px solid green;
}
.border-blue {
border: 10px solid blue;
}
.border-gold {
border: 10px solid gold;
}
.border-pink {
border: 10px solid pink;
}
.padding10 {
padding: 10px;
}
/* 라이브러리 - flex */
* > .flex {
display: flex;
}
* > .flex-grow-1 {
flex-grow: 1;
}
* > .flex-jc-c {
justify-content: center;
}
* > .flex-jc-s {
justify-content: flex-start;
}
* > .flex-jc-e {
justify-content: flex-end;
}
* > .flex-jc-sb {
justify-content: space-between;
}
* > .flex-jc-sa {
justify-content: space-around;
}
* > .flex-ai-c {
align-items: center;
}
* > .flex-ai-s {
align-items: flex-start;
}
* > .flex-ai-e {
align-items: flex-end;
}
* > .flex-as-s {
align-self: stretch;
}
* > .flex-as-c {
align-self: center;
}
* > .flex-as-s {
align-self: flex-start;
}
* > .flex-as-e {
align-self: flex-end;
}
* > .flex-column-nowrap {
flex-flow: column nowrap;
}
* > .flex-column-wrap {
flex-flow: column wrap;
}
* > .flex-row-wrap {
flex-flow: row wrap;
}
.flex-ch-basis-0 > * {
flex-basis: 0;
}
* > .flex-1-0-0 {
flex: 1 0 0;
}
* > .bg-red {
background-color: red;
}
/* 커스텀 */
.top_bar {
background-color: black;
color: white;
height: 500px; /*임시*/
}
.top_bar > .logo {
font-size: 6rem;
}