/* ---------------------------------- リセット ---------------------------------- */
#pi_tracking_opt_in_div {
  display: none !important;
  visibility: hidden !important;
}

#header2025,
.fixed-header {
  line-height: 1.5;
  letter-spacing: 0em;
  font-family: "Noto Sans JP", sans-serif;

  /* 表示切替 */
  .sp {
    display: block;
  }

  .pc {
    display: none !important;
  }

  *,
  ::before,
  ::after {
    box-sizing: border-box;
  }

  h1,
  h2,
  h3,
  h4,
  h5,
  h6,
  p {
    margin: 0;
    line-height: 1.5;
    letter-spacing: 0;
    color: #000;
  }

  ol,
  ul {
    padding: 0;
    margin: 0;
  }

  small,
  em,
  span,
  strong {
    font-style: normal;
    font-weight: inherit;
    color: inherit;
  }

  p {
    font-size: 3.6vw;
  }
}

/* -------------------------------- Header(SP) -------------------------------- */
#header2025 {
  position: relative;
  z-index: 1002;
}

/* 固定ヘッダー用のスタイル */
.fixed-header {
  border-top: 5px solid #fff;
  border-image: linear-gradient(to right, #38a1d7, #153c7b);
  border-image-slice: 1;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1002;
  transform: translateY(-100%);
  transition: transform 0.3s ease;

  &.show {
    transform: translateY(0);
  }

  .header__nav {
    background-color: #1b2951;

    .header__wrapper-l {
      display: flex;
      justify-content: end;
      align-items: center;
      flex-flow: row wrap;
    }
  }
}

#header2025,
.fixed-header {
  /* position: relative; */
  /* position: fixed; */
  inset: 0 0 auto 0;
  box-shadow: 0 4px 4px 0 #00000040;

  .sec_cta {
    margin-bottom: 20.51vw;
  }

  .header__wrapper-l {
    width: min(100%, 1920px);
    margin-inline: auto;
  }

  .header__topbar,
  .header__nav,
  .header__menu {
    * {
      color: #fff;
    }
  }

  /* .header__tobar,
  .header__nav {
    position: fixed;
    z-index: 100000;
  } */

  .header__topbar {
    /* inset: 0 auto 0 0;
    width: 100%;
    height: fit-content; */

    background: linear-gradient(to right, #38a1d7, #153c7b);
    padding: calc((6 / 390) * 100vw) 4.1vw;

    .header__wrapper-l {
      display: flex;
      justify-content: end;
      align-items: center;
      flex-flow: row wrap;
    }

    .header__topbar-button {
      padding-bottom: 1.03vw;
      span {
        font-size: 12px;
        font-weight: 400;
        position: relative;
        padding-right: 4.1vw;

        &::before {
          content: "";
          position: absolute;
          inset: 0 0 0 auto;
          margin-block: auto;
          width: 16px;
          height: 16px;
          background: no-repeat center / contain
            url("/assets/images/header_2025/header_deco1.webp");
        }
      }
    }
  }

  .header__nav {
    /* display: fixed;
    inset: 0 0 auto 0; */
    background-color: #1b2951;
    /* padding-block: 4.1vw; */
    position: relative;

    .header__wrapper-l {
      display: flex;
      justify-content: space-between;
      align-items: center;
      flex-flow: row nowrap;
      gap: 4.1vw;
      padding-inline: 4.1vw 0;
    }

    .header__logo {
      line-height: 0;
    }

    .header__button {
      flex-shrink: 0;
      width: 188px;
      height: 45px;
      background-color: #ff544b;
      display: flex;
      justify-content: center;
      align-items: center;
      border-radius: 1.03vw;

      span {
        color: inherit;
        font-size: 20px;
        font-weight: 700;
        padding-left: 8.21vw;
        letter-spacing: 0;
        position: relative;

        &::before {
          content: "";
          position: absolute;
          inset: 0 auto 0 0;
          margin-block: auto;
          width: 21px;
          height: 16px;
          background: no-repeat center / contain
            url("/assets/images/header_2025/header_deco3.webp");
        }
      }
    }
  }

  .header__tel {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-flow: row nowrap;
    gap: 2.05vw;

    .header__tel-text,
    .header__tel-call {
      font-weight: 700;
      letter-spacing: 0;
      color: #fff;
    }

    .header__tel-text {
      font-size: 15px;
      line-height: 1.3;

      span {
        letter-spacing: 0.39em;
      }
    }

    .header__tel-call {
      font-size: 6.67vw;
      position: relative;
      padding-left: 10.26vw;

      &::before {
        content: "";
        position: absolute;
        inset: 0 auto 0 0;
        margin-block: auto;
        width: 34px;
        height: 34px;
        background: no-repeat center / contain
          url("/assets/images/header_2025/header_tel2.webp");
      }
    }
  }

  .header__menu {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-flow: row nowrap;

    .header__menu-tel,
    .header__menu-faq,
    .header__menu-contact,
    .header__menu-drawer {
      width: calc((54 / 390) * 100vw);
      height: calc((42 / 390) * 100vw);
      display: flex;
      justify-content: center;
      align-items: center;
      flex-flow: column nowrap;
      gap: calc((6 / 390) * 100vw);

      span {
        color: #fff;
        font-weight: 400;
        text-align: center;
        font-size: calc((10 / 390) * 100vw);
        line-height: 1;
        letter-spacing: 0;
        white-space: nowrap;
        @media screen and (max-width: 350px) {
          zoom: 0.8;
        }
      }
      img {
        img {
          width: 12px;
          height: 12px;
          object-fit: contain;
        }
      }
    }

    .header__menu-tel {
      background-color: #ff544b;
    }

    .header__menu-drawer {
      border: none;
      outline: none;
      background-color: transparent;
      /* background: #28427b; */

      &:hover {
        cursor: pointer;
      }

      &.active {
        /* background: #130b30; */
        background: #28427b;
      }
    }
  }

  .header__list {
    /* height: 70px; */
    flex-shrink: 0;
    margin-inline: auto clamp(20px, 0.5vw, 10.26vw);
    display: flex;
    justify-content: center;
    align-items: center;
    flex-flow: row nowrap;
    gap: 8.21vw;
  }

  .header__item {
    height: 100%;

    .header__item-link {
      display: block;
      height: inherit;
      display: flex;
      justify-content: start;
      align-items: center;

      span {
        white-space: nowrap;
        font-size: calc((20 / 390) * 100vw);
        font-weight: 700;
        letter-spacing: 0;
        /* padding-bottom: 2.05vw; */
        position: relative;
        /* @media screen and (max-width: 1600px) {
          font-size: 1vw;
        } */
        /* &::before {
          content: "";
          position: absolute;
          inset: auto 0 0 0;
          margin-inline: auto;
          width: 16px;
          height: 8px;
          background: no-repeat center / contain
            url("/assets/images/header_2025/header_deco2.webp");
          transform: translateY(50%);
        } */
      }
    }
  }

  .header__item--solo {
    .header__item-link {
      span {
        &::before {
          content: none;
        }
      }
    }
  }
}

.navigation__close {
  z-index: 1001;
  display: none;
  position: fixed;
  inset: auto 0 0 0;
  padding: 5vw 0 0vw 0;
  width: 100%;
  height: calc((60 / 390) * 100vw);

  border-bottom: 20px solid rgba(27, 41, 81, 1);
  background: linear-gradient(
    180deg,
    rgba(27, 41, 81, 0) 0%,
    rgba(27, 41, 81, 0.6) 50%,
    rgba(27, 41, 81, 1) 100%
  );

  .navigation__close-button {
    display: block;
    width: fit-content;
    height: fit-content;
    margin-inline: auto;
    border: none;
    outline: none;
    background: transparent;
    /* transform: translateY(calc((20 / 390) * 100vw));
    opacity: 0;
    transition: all 2.5s ease; */

    &:hover {
      cursor: pointer;
    }

    span {
      font-size: 3.6vw;
      color: #fff;
      font-weight: 700;
      line-height: 1;
      letter-spacing: 0;
      position: relative;
      padding-left: 8.21vw;

      &::before {
        content: "";
        position: absolute;
        inset: 0 auto 0 0;
        margin-block: auto;
        width: calc((26 / 390) * 100vw);
        height: calc((26 / 390) * 100vw);
        background: no-repeat center / contain
          url("/assets/images/header_2025/sp-header_icon9.webp");
      }
    }
  }
}

.navigation__close.active {
  display: block;

  .navigation__close-button {
  }
}

/* --------------------------------- ナビゲーション -------------------------------- */
/* PC版のflexレイアウトを完全に無効化 */
.megamenu {
  display: block !important;
  flex-direction: column !important;
}

.megamenu__left,
.megamenu__right {
  display: none !important;
}

/* PC版のsubmenuのwidth指定を上書き */
.megamenu > .submenu {
  width: 100% !important;
  margin: 0;
  padding: 0;
}

/* ===== 表示制御 ===== */
/* .pc {
      display: none !important;
    }

    .sp {
      display: block !important;
    } */

/* ===== ハンバーガーメニューボタン ===== */
/* .header__menu {
      position: fixed;
      top: 20px;
      right: 20px;
      z-index: 1000;
      display: flex;
      gap: 10px;
    } */

/* .header__menu-contact,
    .header__menu-drawer {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      width: 50px;
      height: 50px;
      background: #28427B;
      border-radius: 8px;
      color: #fff;
      text-decoration: none;
      font-size: 10px;
      transition: all 0.3s ease;
      gap: 4px;
    }

    .header__menu-contact:hover,
    .header__menu-drawer:hover {
      background: #1e3960;
    }

    .header__menu-contact img,
    .header__menu-drawer img {
      width: auto;
      height: auto;
    }

    .header__menu-contact span,
    .header__menu-drawer span {
      color: #fff;
      font-size: 10px;
      font-weight: normal;
    } */

/* .header__menu-drawer.active {
      background: #130b30;
    } */

/* ===== オーバーレイ ===== */
.menu-overlay {
  display: none !important; /* SPでは完全に非表示 */
}

/* ===== ナビゲーションメニュー ===== */
.navigation {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  /* background: #1b2951; */
  background: #28427b;
  z-index: 1001;
  overflow-y: auto;
  overflow-x: hidden;
  transition: all 0.3s ease;
  padding: 4.1vw 4.1vw 20.51vw 4.1vw;
  -webkit-overflow-scrolling: touch;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
}

.navigation.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* スクロールバー */
.navigation {
  scrollbar-gutter: stable both-edges;
}

.navigation::-webkit-scrollbar {
  width: 6px;
}

.navigation::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
}

.navigation::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
}

.navigation::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.5);
}

/* ===== バナーボタン ===== */
.navigation__button {
  display: block;
  width: fit-content;
  margin: 0 auto 6.15vw auto;
}

/* ===== ヘッダーリスト ===== */
.header__list {
  justify-content: flex-start !important;
  flex-direction: column !important;
  gap: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  min-height: auto;
}

.header__item {
  width: 100%;
  height: auto !important;
  /* border-bottom: 1px solid #647bac; */
  /* border-bottom: 1px solid #fff; */
  flex-shrink: 0;
  margin-bottom: 8.21vw;

  &:not(:last-child) {
    /* margin-bottom: 8.21vw; */
  }
}

.header__item:last-child {
  border-bottom: none;
  margin-bottom: 20px;
}

/* ===== ヘッダーアイテムリンク ===== */
.header__item-link {
  display: flex !important;
  justify-content: space-between;
  align-items: center;
  /* padding: 18px 24px !important; */
  padding: 2.05vw 0;
  font-size: calc((20 / 390) * 100vw);
  font-weight: bold;
  color: #fff;
  text-decoration: none;
  background: none;
  transition: background-color 0.3s ease;
  border-bottom: 1px solid #fff;
}

.header__item-link:hover,
.header__item-link.active {
  /* background-color: #130b30; */
}

.header__item-link {
  position: relative;

  &::before {
    content: "";
    position: absolute;
    inset: 0 0 0 auto;
    margin-block: auto;
    background: no-repeat center / contain;

    width: calc((24 / 390) * 100vw);
    height: calc((24 / 390) * 100vw);
    /* width: calc((18 / 390) * 100vw);
      height: calc((18 / 390) * 100vw); */
    background-image: url("/assets/images/header_2025/sp-header_icon6.webp");
  }

  &:has(+ .megamenu) {
    &::before {
      /* width: calc((24 / 390) * 100vw);
        height: calc((24 / 390) * 100vw); */
      background-image: url("/assets/images/header_2025/sp-header_icon7.webp");

      /* //TODO!: Rotate when active */
      transform: rotate(180deg);
      transition: transform 0.3s ease;
    }
  }
}

.header__item-link.active {
  &::before {
    transform: rotate(0deg);
  }
}

/* ===== トグルボタン ===== */
.toggle-btn {
  width: calc((20 / 390) * 100vw);
  height: calc((20 / 390) * 100vw);
  position: relative;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.toggle-btn::before,
.toggle-btn::after {
  content: "";
  position: absolute;
  background: #000;
  transition: all 0.3s ease;
}

.toggle-btn::before {
  width: calc((20 / 390) * 100vw);
  height: calc((2 / 390) * 100vw);
  top: 50%;
  left: 0;
  transform: translateY(-50%);
}

.toggle-btn::after {
  width: calc((2 / 390) * 100vw);
  height: calc((20 / 390) * 100vw);
  top: 0;
  left: 50%;
  transform: translateX(-50%);
}

.header__item-link.active .toggle-btn::after {
  transform: translateX(-50%) rotate(90deg);
}

/* ===== メガメニュー（SP版ではサブメニュー） ===== */
.header__item--has-sub .megamenu {
  display: none !important;
}

.megamenu {
  position: static !important;
  width: 100% !important;
  min-height: auto !important;
  /* background: #130b30 !important; */
  flex-direction: column !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
  transition: none !important;
  pointer-events: auto !important;
  overflow: visible !important;
  margin: 0;
  padding: 0;
  display: block !important;
}

.megamenu.show {
  display: block !important;
}

/* ===== サブメニュー ===== */
.submenu {
  position: static !important;
  display: block !important;
  width: 100% !important;
  padding: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  /* margin: 0; */
}

.submenu.level-2 {
  /* background: #130b30 !important; */
  /* width: 100% !important; */
  width: calc(100% - 4.1vw) !important;
  margin: 4.1vw 0 0 4.1vw !important;
}

.submenu.level-3 {
  /* background: #0f0825 !important; */
  display: none !important;
  width: 100% !important;
  overflow: hidden;
}

/* ===== サブメニューアイテム ===== */
.submenu__item {
  /* border-bottom: 1px solid #647bac; */
  margin: 0;

  &:not(:last-child) {
    margin-bottom: 4.1vw;
  }
}

.submenu__item:last-child {
  border-bottom: none;
}

.submenu__item a {
  display: flex !important;
  justify-content: space-between;
  align-items: center;
  /* padding: 14px 24px !important; */
  /* font-size: calc((18 / 390) * 100vw) !important; */
  font-weight: normal !important;
  /* color: #fff; */
  text-decoration: none;
  background: none !important;
  /* transition: background-color 0.3s ease; */
  gap: 0 !important;
  margin: 0;
}

.submenu__item a:hover {
  opacity: 1 !important;
  /* background-color: rgba(255, 255, 255, 0.1) !important; */
}

/* PC版のafter/beforeを無効化 */
.submenu__item a::after,
.submenu__item a::before {
  /* display: none !important; */
}

.submenu__item a {
  &::after {
    display: block;
    content: "";
    position: relative;
    margin: auto auto auto 2.05vw;
    width: calc((18 / 390) * 100vw);
    height: calc((18 / 390) * 100vw);
    background: no-repeat center / contain
      url("/assets/images/header_2025/submenu_level-3_icon.webp");
    transform: translateY(calc((2 / 390) * 100vw));
  }
}

.submenu.level-2 .submenu__item a {
  font-size: calc((17 / 390) * 100vw);
}

/* ===== 3階層目を持つ項目 ===== */
.submenu__item a:has(+ .submenu.level-3) {
  justify-content: start;
  background-color: #fff !important;
  padding: 2.05vw !important;
  color: #000 !important;
  font-weight: 700 !important;
  font-size: calc((17 / 390) * 100vw) !important;
  letter-spacing: 0 !important;

  &::before {
    content: "";
    position: relative;
    display: block;
    inset: 0 auto 0 0;
    margin: auto 1.03vw auto 0;
    width: calc((26 / 390) * 100vw);
    height: calc((26 / 390) * 100vw);
    background: no-repeat center / contain
      url("/assets/images/header_2025/sp-header_icon8.webp");
  }

  &::after {
    display: none;
  }
}

.submenu__item.has-submenu > a {
  position: relative;
}

.submenu__item.has-submenu > a .toggle-btn {
  margin-inline: auto 0;
  width: calc((16 / 390) * 100vw);
  height: calc((16 / 390) * 100vw);
}

.submenu__item.has-submenu > a .toggle-btn::before {
  width: calc((16 / 390) * 100vw);
  height: calc((2 / 390) * 100vw);
}

.submenu__item.has-submenu > a .toggle-btn::after {
  width: calc((2 / 390) * 100vw);
  height: calc((16 / 390) * 100vw);
}

.submenu__item.has-submenu.active > a .toggle-btn::after {
  transform: translateX(-50%) rotate(90deg);
}

.submenu__item.has-submenu.active .submenu.level-3 {
  display: block !important;
}

/* ===== 3階層目のスタイル ===== */
.submenu.level-3 a {
  padding: 4.1vw 0 0 calc((20 / 390) * 100vw) !important;
  font-size: 4.1vw !important;
  position: relative !important;

  &::before {
    content: "";
    position: absolute;
    inset: 0 auto auto 0;
    width: calc((16 / 390) * 100vw);
    height: calc((41 / 390) * 100vw);
    background: no-repeat center / contain
      url("/assets/images/header_2025/sp-header_deco1.webp");
    transform: translateY(-30%);
  }
}

/* ナビ - DDFが選ばれる理由 */
.submenu__item--noIcon {
  &::after {
    display: none !important;
  }
}

.submenu2 {
  padding-left: calc((2 / 390) * 100vw) !important;
  margin-bottom: 4.1vw !important;

  .submenu__item a {
    padding-left: calc((20 / 390) * 100vw) !important;
    position: relative !important;

    &::before {
      content: "";
      position: absolute;
      inset: 0 auto auto 0;
      width: calc((16 / 390) * 100vw);
      height: calc((41 / 390) * 100vw);
      background: no-repeat center / contain
        url("/assets/images/header_2025/sp-header_deco1.webp");
      transform: translateY(-58%);
    }
  }
}

/* ===== ボディ固定（メニュー開時） ===== */
body.menu-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
  height: 100%;
}

/* ===== SPメニュー 開いた状態バージョン用スタイル ===== */
.header__item-link.sp-always-open {
  pointer-events: none; /* クリックを無効化 */

  /* メガメニューを持つ項目のアイコンを非表示 */
  &:has(+ .megamenu) {
    &::before {
      display: none !important;
    }
  }
}
