@charset "UTF-8";
/* CSS Document */


/* ハンバーガーアイコン */
.hamburger {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1100;
  width: 30px;
  height: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
}


.hamburger span {
  display: block;
  width: 100%;
  height: 3px;
  background: #000;
  border-radius: 2px;
  transition: 0.4s;
  position: absolute;
  left: 0;
  transform-origin: center;
}

/* ナビゲーションメニュー（初期状態では画面外） */
.nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  height: 100vh;
  background: #444;
  transition: right 0.5s ease;
  padding-top: 4rem;
  z-index: 1000;
}

/* アクティブ状態でスライドイン */
.nav.active {
  right: 0;
}

.nav ul {
  list-style: none;
}

.nav li {
  border-bottom: 1px solid #666;
}

.nav a {
  display: block;
  padding: 1rem;
  color: white;
  text-decoration: none;
  transition: background 0.3s;
}

.nav a:hover {
  background: #555;
}

/* 各線の初期位置 */
.hamburger span:nth-child(1) {
  top: 0;
}

.hamburger span:nth-child(2) {
  top: 50%;
  transform: translateY(-50%);
}

.hamburger span:nth-child(3) {
  bottom: 0;
}

/* active時（バツ） */
.hamburger.active span  {
	background-color: #FFF;
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg);
  top: 50%;
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg);
  bottom: auto;
  top: 50%;
}