@charset "UTF-8";
/* ==========================================================================
   header.css（header.php）
   ========================================================================== */
/* PC：最初はページと一緒にスクロールして画面外へ出て、上で待機（top＝ヘッダーの高さ：線7＋本体143）
   ファーストビューを過ぎると .is-fixed で上からスライドして表示（common.js） */
.l-header {
  position: sticky;
  top: calc(-150 * var(--vw));
  z-index: 100;
  background: var(--c-white);
  border-top: calc(7 * var(--vw)) solid var(--c-blue);
}

.l-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1920px;
  height: calc(143 * var(--vw));
  margin: 0 auto;
  padding: 0 calc(60 * var(--vw));
}

.l-header__logo {
  transition: opacity 0.3s;
}

.l-header__logo:hover {
  opacity: 0.7;
}

.l-header__toggle {
  display: none;
}

.l-header__nav {
  display: flex;
  align-items: center;
  gap: calc(30 * var(--vw));
}

.l-header__list {
  display: flex;
  align-items: center;
  gap: calc(30 * var(--vw));
}

.l-header__link {
  display: flex;
  align-items: center;
  gap: 0.3em;
  font-size: calc(17 * var(--vw));
  font-weight: 700;
  line-height: normal;
  white-space: nowrap;
  transition: color 0.3s;
}

.l-header__link:hover {
  color: var(--c-blue);
}

.l-header__link-arrow {
  display: inline-block;
  transition: transform 0.4s var(--ease-out);
}

.l-header__link:hover .l-header__link-arrow {
  transform: translate(0.18em, -0.18em);
}

.l-header__cta {
  width: calc(235 * var(--vw));
  height: calc(76 * var(--vw));
}

/* 追従（PC）
   .is-away ：ヘッダーが画面外に出ている間だけアニメーション（トップへ一気に戻ったときにずれないように）
   .is-fixed：追従表示 */
@media screen and (min-width: 768px) {
  .l-header.is-away {
    transition: transform 0.5s var(--ease-out), box-shadow 0.5s;
  }

  .l-header.is-fixed {
    transform: translateY(100%);
    box-shadow: 0 4px 20px rgba(36, 45, 51, 0.08);
  }
}

/* ==========================================================================
   SP
   ========================================================================== */
@media screen and (max-width: 767px) {
  .l-header {
    position: sticky;
    top: 0;
    z-index: 100;
    border-top-width: 4px;
  }

  .l-header.is-scrolled {
    box-shadow: 0 2px 12px rgba(36, 45, 51, 0.08);
  }

  .l-header__inner {
    height: 56px;
    padding: 0 0 0 16px;
  }

  .l-header__logo.c-logo {
    --u: 0.4px;
  }

  /* ハンバーガー */
  .l-header__toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 56px;
    height: 56px;
  }

  .l-header__toggle-line {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--c-ink);
    transition: transform 0.4s var(--ease-out), opacity 0.3s;
  }

  .is-menu-open .l-header__toggle-line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .is-menu-open .l-header__toggle-line:nth-child(2) {
    opacity: 0;
  }

  .is-menu-open .l-header__toggle-line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  /* ドロワー */
  .l-header__nav {
    position: fixed;
    inset: 60px 0 0;
    z-index: 99;
    flex-direction: column;
    align-items: stretch;
    gap: 32px;
    padding: 24px 20px 40px;
    overflow-y: auto;
    background: #f5f9fb;
    visibility: hidden;
    opacity: 0;
    transform: translateY(-12px);
    transition: opacity 0.4s var(--ease-out), transform 0.5s var(--ease-out), visibility 0s 0.5s;
  }

  .is-menu-open .l-header__nav {
    visibility: visible;
    opacity: 1;
    transform: none;
    transition: opacity 0.4s var(--ease-out), transform 0.5s var(--ease-out);
  }

  .l-header__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .l-header__link {
    justify-content: space-between;
    padding: 18px 4px;
    font-size: 16px;
    border-bottom: 1px solid var(--c-line);
  }

  .l-header__cta {
    width: 100%;
    height: 64px;
  }

  /* 背景スクロール固定（bodyに指定するとstickyが外れるためhtmlのみ） */
  html.is-menu-open {
    overflow: hidden;
  }
}

/* WordPressログイン時：管理バー（783px〜は高さ32px、601〜782pxは46pxで固定表示）の下にヘッダーを出す */
@media screen and (min-width: 783px) {
  .admin-bar .l-header {
    top: calc(32px - 150 * var(--vw));
  }
}

@media screen and (min-width: 768px) and (max-width: 782px) {
  .admin-bar .l-header {
    top: calc(46px - 150 * var(--vw));
  }
}

@media screen and (min-width: 601px) and (max-width: 767px) {
  .admin-bar .l-header {
    top: 46px;
  }

  .admin-bar .l-header__nav {
    inset: 106px 0 0;
  }
}
