/* ヘッダー共通 */
.header {
  position: relative;
  padding-left: 20px;
  padding-top: 20px;
  padding-bottom: 20px;
}

/* HPロゴ */
.logo {
  font-size: 24px;
  font-weight: bold;
  color: rgb(0, 0, 0);
  text-decoration: none; /* aタグの下線を消す */
}

/* ハンバーガーボタン */
.hamburger {
  position: fixed;
  top: 15px;
  right: 20px;
  z-index: 100;
  width: 48px;
  height: 48px;
  border: none;
  background: transparent;
  cursor: pointer;
}

.hamburger__line {
  position: absolute;
  left: 11px;
  width: 26px;
  height: 2px;
  background-color: #333;
  transition: all 0.4s;
}

.hamburger__line:nth-of-type(1) {
  top: 14px;
}
.hamburger__line:nth-of-type(2) {
  top: 23px;
}
.hamburger__line:nth-of-type(3) {
  top: 32px;
}

/* メニューオープン時 */
.hamburger.active .hamburger__line:nth-of-type(1) {
  transform: translateY(9px) rotate(-45deg);
}
.hamburger.active .hamburger__line:nth-of-type(2) {
  opacity: 0;
}
.hamburger.active .hamburger__line:nth-of-type(3) {
  transform: translateY(-9px) rotate(45deg);
}

/* メニュー */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 300px;
  height: 100vh;
  background-color: #fff;
  box-shadow: 2px 0 4px rgba(0, 0, 0, 0.1);
  transform: translateX(-100%);
  transition: transform 0.4s;
  z-index: 90;
}

.nav.active {
  transform: translateX(0);
}

.nav__list {
  margin: 0;
  padding: 80px 0 0;
  list-style: none;
}

.nav__item {
  padding: 0 20px;
}

.nav__link {
  display: block;
  padding: 15px 0;
  color: #333;
  text-decoration: none;
  border-bottom: 1px solid #eee;
}

/* PC画面（幅768px以上）だけ横並びにする */
@media (min-width: 768px) {
  .nav {
    display: flex;
    position: static; /* 固定解除 */
    width: auto; /* 横幅自動 */
    height: auto; /* 高さ自動 */
    transform: none; /* スライド無効 */
    box-shadow: none; /* 影なし */
    align-items: center;
    background-color: transparent;
    padding: 5px; /* 余白リセット */
    margin: 0; /* 余白リセット */
    justify-content: space-evenly; /*中央揃え*/
    text-align:center;
    background-color: rgb(52, 145, 189);
  }

  .nav__link {
    display: block;
    padding: 0;
    color: #ffffff;
    text-decoration: none;
    border-bottom: none;
  }

  .nav ul {
    flex-direction: row; /* 横並び */
    gap: 10px; /* メニュー間隔 */
    padding: 0 0; /* 上下余白リセット */
    margin: 0;
  }

  .nav li {
    display: inline-block;
  }

  .nav a:hover {
  /*background-color: #f0f0f0; /* 背景色が変わる */
  /* color: #007bff;           文字色が変わる */
  text-decoration: underline;
  }

  .nav li:not(:last-child){
    border-right:2px solid #b2b9c6;
  }

  .hamburger {
    display: none; /* PCではハンバーガー非表示 */
  }
}
