@charset "UTF-8";
header.corprate {
  height: auto;
}
.head-wrapper {
  width: 100%;
  height: 85px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 250;
  transition:
    background-color 0.3s ease, box-shadow 0.3s ease;
}
@media screen and (max-width: 768px) {
.recruit .head-wrapper{
	background: #fff;
}
}
.head-left {
  margin-left: 7.3%;
  width: 230px;
  height: 57px;
  aspect-ratio: 230/57;
}
@media (min-width: 769px) and (max-width: 1370px) {
  .head-left {
    margin-left: 3.6%;
  }
}
@media screen and (max-width: 768px) {
  .head-left {
    height: auto;
    display: flex;
    align-items: center;
    margin-left: 0;
  }
}
.head-left img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* --- 既存のコードを一部修正 --- */
.header-nav {
  margin-right: 9.5%;
  width: 898px;
  height: 65px;
  border-radius: 51px;
  /* 初期状態：透明、または少し薄い色にする場合 */
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  background-color: #fff;
  /* アニメーションを滑らかにする */
  transition:
    background-color 0.3s ease, box-shadow 0.3s ease;
}
@media (min-width: 1248px) and (max-width: 1370px) {
  .header-nav {
    margin-right: 4.75%;
  }
}
@media screen and (max-width: 1247px) {
  .header-nav {
    display: none;
  }
}
.header-nav ul {
  display: flex;
  gap: 30px;
  align-items: center;
}
.header-nav ul li a {
  color: var(--color-black);
  font-family: var(--font-jp);
  font-size: 15px;
  font-style: normal;
  font-weight: 600;
  line-height: 160%;
  letter-spacing: 0.45px;
  padding-bottom: 10px;
  border-bottom: 1px solid #fff;
}
.header-nav ul li a:hover {
  color: #003894;
  border-bottom: 1px solid #136CFA;
  padding-bottom: 10px;
}
/* --- スクロール時に付与されるクラス --- */
.head-wrapper.is-scrolled {
  background: var(--color-white); /* スクロール後に白くする */
}
/* 背景が白くなった時に文字色も変えたい場合は以下も追加 */
.header-nav.is-scrolled ul li a {
  /* 必要に応じて文字色を調整 */
  /* color: #000; */
  color: var(--color-black);
}
/* ==========================================================================
   PC用環境（1248px以上）でのデフォルト非表示設定
   ========================================================================== */
@media (min-width: 1248px) {
  .menu-btn, .drawer-nav {
    display: none !important;
  }
}
/* ==========================================================================
   スマートフォン・タブレット用スタイル（1247px以下で有効）
   ========================================================================== */
@media (max-width: 1247px) {
  /* PC用ナビゲーションを非表示 */
  .header-nav {
    display: none;
  }
  /* スマホ用ヘッダー：z-indexを圧倒的に高くして最前面に */
  .corprate {
    position: relative;
    z-index: 99999;
    background-color: #ffffff;
  }
  /* メニュー展開時、ヘッダーを上部に完全固定 */
  body.is-drawer-open .corprate {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
  }
  .head-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
  }
  .head-left img {
    max-height: 44px;
    width: auto;
    display: block;
  }
  /* ハンバーガーボタン（ヘッダーよりさらに前面へ） */
  .menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    aspect-ratio: 1 / 1;
    background-color: #003894;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    padding: 0;
    position: relative;
    z-index: 100000;
  }
  .menu-btn__bars {
    display: block;
    width: 18px;
    height: 8px;
    position: relative;
  }
  .menu-btn__bar {
    position: absolute;
    left: 0;
    width: 18px;
    height: 2px;
    background-color: #ffffff;
    border-radius: 1px;
    transition: transform 0.3s ease, top 0.3s ease, bottom 0.3s ease;
  }
  .menu-btn__bar:nth-child(1) {
    top: 0;
  }
  .menu-btn__bar:nth-child(2) {
    bottom: 0;
  }
  .menu-btn.is-active .menu-btn__bar:nth-child(1) {
    top: 3px;
    transform: rotate(45deg);
  }
  .menu-btn.is-active .menu-btn__bar:nth-child(2) {
    bottom: 3px;
    transform: rotate(-45deg);
  }
  /* ------------------------------------------------------------------------
     ドロワーメニュー（すり抜け・ズレを完全に防ぐ設定）
     ------------------------------------------------------------------------ */
  .drawer-nav {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh; /* アドレスバーの変化に対応 */
    background-color: #ffffff;
    z-index: 99998; /* ヘッダーのすぐ後ろに配置 */
    padding-top: 90px; /* ヘッダーに被らないよう余白を固定 */
    /* メニュー自体が長い場合は、メニューの中だけをスクロールさせる */
    overflow-y: auto;
    -webkit-overflow-scrolling: touch; /* iOSでのスクロールを滑らかにする */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
  }
  .drawer-nav.is-open {
    opacity: 1;
    visibility: visible;
  }
  .drawer-nav__list {
    list-style: none;
    padding: 0 20px 60px 20px; /* スクロールしきった最下部に余裕を持たせる */
    margin: 0;
  }
  .drawer-nav__item {
    border-bottom: 1px solid #BEBEBE;
  }
  .drawer-nav__link {
    display: flex;
    align-items: center;
    padding: 15px 0 15px 22px;
    text-decoration: none;
    position: relative;
    color: #191E2E;
    font-family: "Noto Sans JP";
    font-size: 18px;
    font-style: normal;
    font-weight: 500;
    line-height: 160%; /* 28.8px */
    letter-spacing: 0.54px;
  }
  .drawer-nav__link::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 14px;
    height: 14px;
    background-color: #003894;
    border-radius: 50%;
  }
  .drawer-nav__link::after {
    content: "";
    width: 4px;
    height: 7px;
    aspect-ratio: 4/7;
    background-image: url("../image/common/spmenuicon.svg");
    position: absolute;
    right: auto;
    bottom: auto;
    left: 5px;
    top: 26px;
  }
  .drawer-nav__child-list {
    list-style: none;
    padding: 0 0 12px 0;
    margin: 0;
  }
  .drawer-nav__child-link {
    display: flex;
    align-items: center;
    padding: 0 0 10px 20px;
    text-decoration: none;
    position: relative;
    color: #191E2E;
    font-family: "Noto Sans JP";
    font-size: 16px;
    font-style: normal;
    font-weight: 500;
    line-height: 160%; /* 25.6px */
    letter-spacing: 0.48px;
  }
  .drawer-nav__child-link::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 38%;
    transform: translateY(-50%);
    width: 10px;
    height: 2px;
    background-color: #003894;
  }
}
/* ==========================================
   メガメニューの追加スタイル（PC用）
   ========================================== */
/* ホバーされる親のli（位置固定の基準にはしないため、敢えてrelativeは不要） */
.has-mega {
  /* JSでの制御用、ホバー時の挙動を安定させるため */
}
/* メガメニュー全体の帯（画面横幅いっぱい） */
.mega-menu {
  position: fixed;
  top: 85px; /* .head-wrapper の高さに合わせる */
  left: 0;
  width: 100vw;
  background-color: #ffffff;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
  border-top: 1px solid #eef2f6; /* 必要に応じて境界線 */
  z-index: 240; /* ヘッダー(250)より少し下に */
  /* 初期状態は非表示（JSでふわっと出す） */
  display: none;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
/* JSで .is-active がついた時のアニメーション挙層 */
.mega-menu.is-active {
  display: block; /* JSのfadeInと併用するため、ベースはblockに */
  opacity: 1;
  transform: translateY(0);
}
/* メガメニューの内側（デザインの枠幅制限：画像2枚目の赤枠内を再現） */
.mega-menu__inner {
  max-width: 1200px; /* サイトの共通コンテンツ幅に合わせて調整してください */
  margin: 0 auto;
  padding: 40px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
/* 左側：タイトルエリア */
.mega-menu__title-area {
  width: 25%;
}
.mega-menu__title-area h2 {
  font-size: 20px;
  color: #003894; /* 濃いブルー */
  font-weight: 700;
  margin-bottom: 5px;
  letter-spacing: 0.05em;
}
.mega-menu__title-area .en {
  color: #003894;
  font-family: Montserrat;
  font-size: 16px;
  font-style: normal;
  font-weight: 600;
  line-height: normal;
}
/* 右側：4カラムのグリッド */
.mega-menu__grid {
  width: 72%;
  display: flex;
  gap: 20px;
}
.mega-menu__grid a:hover {
  border: none !important;
}
/* 各カードのスタイル */
.mega-menu__card {
  flex: 1;
  text-decoration: none;
  color: var(--color-black);
  transition: transform 0.2s ease;
}
.mega-menu__card:hover {
  border: none;
}
/* 画像ラッパー */
.mega-menu__img {
  width: 100%;
  aspect-ratio: 4 / 3; /* 画像の比率を固定 */
  border-radius: 8px;
  overflow: hidden;
  background-color: #f0f0f0;
  margin-bottom: 12px;
}
.mega-menu__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}
.mega-menu__card:hover .mega-menu__img img {
  transform: scale(1.05); /* ホバー時に画像を少しズーム */
}
/* カードのテキスト部分（矢印含む） */
.mega-menu__card-txt {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  font-weight: 600;
  color: #333;
  padding-right: 5px;
}
.mega-menu__card-txt .arrow {
  color: #003894;
  font-weight: bold;
  transition: transform 0.2s ease;
  margin-right: 20px;
  transition: margin 0.3s ease;
}
.mega-menu__card:hover .mega-menu__card-txt .arrow {
  margin-right: 0;
}
/* スマホ等（1247px以下）ではメガメニューを完全に非表示（既存のナビ非表示に合わせる） */
@media screen and (max-width: 1247px) {
  .mega-menu {
    display: none !important;
  }
}
.is-drawer-open .head-wrapper {
  background: #fff;
}
@media screen and (min-width: 769px) {
  .recruit .head-wrapper {
    background: #fff;
  }
}