/* ========================================
   Header — 共通ヘッダー/ナビ/ドロップダウン/モバイルメニュー
   ======================================== */

:root {
  --header-h: 70px;
}

/* --- ヘッダー本体 --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--header-h);
  background: #fff;
  overflow: visible;
}
.header::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(
    90deg,
    #c72a80 0%,
    #fb833f 35%,
    #5b5ada 70%,
    #273992 100%
  );
}

.header-inner {
  max-width: 1440px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  padding: 10px 40px;
  height: 100%;
}

/* --- ロゴ --- */
.logo {
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
  flex-shrink: 0;
}
.logo-icon {
  height: 50px;
  width: auto;
}
.logo-title {
  font-family: "M PLUS 1", sans-serif;
  font-weight: 700;
  font-size: 18px;
  background: linear-gradient(180deg, #c72a80, #fb833f);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  white-space: nowrap;
}

/* --- ナビゲーション --- */
.nav {
  display: flex;
  align-items: center;
  gap: 0;
  margin-left: auto;
  margin-right: 24px;
}

/* --- 親要素（判定エリア） --- */
.nav-parent {
  position: relative;
  display: flex;
  align-items: center;
  height: 100%;
}

/* --- トリガー（リンク） --- */
.nav-link,
.nav-parent > .nav-trigger {
  font-size: 13px;
  font-weight: 500;
  color: #555;
  padding: 0 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 100%;
  transition: color 0.15s;
}
.nav-link:hover,
.nav-parent:hover > .nav-trigger {
  color: #222;
}

/* 下線アニメーション */
.nav-link::after,
.nav-parent > .nav-trigger::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 14px;
  right: 14px;
  height: 3px;
  background: linear-gradient(90deg, #c72a80, #fb833f);
  transform: scaleX(0);
  transition: transform 0.2s ease;
}
.nav-link:hover::after {
  transform: scaleX(1);
}

/* --- シェブロン --- */
.chev {
  width: 10px;
  height: 10px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.2s;
}
.nav-parent:hover .chev {
  transform: rotate(180deg);
}

/* --- ドロップダウン本体 --- */
.dropdown {
  position: absolute;
  top: calc(70% + 20px);
  left: 50%;
  transform: translateX(-50%) translateY(5px);
  width: 200px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  padding: 10px 0;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease,
    transform 0.25s ease;
  transition-delay: 0.2s;
  pointer-events: none;
  z-index: 100;
  border-top: 3px solid transparent;
  border-image: linear-gradient(90deg, #c72a80, #fb833f) 1;
}

.dropdown::before {
  content: "";
  position: absolute;
  top: -20px;
  left: -20px;
  width: calc(100% + 40px);
  height: 20px;
  display: block;
}

.nav-parent:hover .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
  transition-delay: 0.05s;
}

/* --- ドロップダウンアイテム --- */
.dd-item {
  display: block;
  padding: 14px 20px;
  text-decoration: none;
  color: #333;
  transition: background 0.1s;
  border-left: 3px solid transparent;
}
.dd-item:hover {
  background: #fafafa;
  border-left-color: #c72a80;
}
.dd-name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
}
.dd-sub {
  font-size: 11px;
  color: #999;
  margin-top: 2px;
}

/* --- CTAボタン --- */
.header-cta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.cta-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 28px;
  border-radius: 50px;
  text-decoration: none;
  font-family: "M PLUS 1", sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  transition:
    opacity 0.2s,
    transform 0.2s;
}
.cta-pill:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}
.cta-pill:active {
  transform: translateY(0);
  opacity: 1;
}
.cta-pill svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.cta-consult {
  background: linear-gradient(180deg, #c72a80, #fb833f);
}
.cta-contact {
  background: linear-gradient(180deg, #5b5ada, #273992);
}

/* ========================================
   Mobile Menu
   ======================================== */
.m-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 44px;
  height: 44px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-left: auto;
}
.m-toggle i {
  display: block;
  width: 20px;
  height: 2px;
  background: #333;
  border-radius: 1px;
  transition: all 0.3s;
  transform-origin: center;
}
.m-toggle.open i:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.m-toggle.open i:nth-child(2) {
  opacity: 0;
}
.m-toggle.open i:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.m-drawer {
  display: none;
  position: fixed;
  top: 45px;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  z-index: 999;
  padding: 0 0 108px;
  overflow-y: auto;
  flex-direction: column;
}
.m-drawer.open {
  display: flex;
}
.m-drawer a,
.m-drawer span {
  display: block;
  text-decoration: none;
  color: #444;
  font-size: 15px;
  font-weight: 500;
  padding: 18px 24px;
  border-bottom: 1px solid #f0f0f0;
  transition: background 0.1s;
}
.m-drawer a:active {
  background: #fafafa;
}
.m-drawer .m-parent {
  font-weight: 700;
  color: #222;
}
.m-drawer .m-child {
  padding-left: 48px;
  font-size: 14px;
  color: #888;
  position: relative;
}
.m-drawer .m-child::before {
  content: "—";
  position: absolute;
  left: 28px;
  color: #ddd;
  font-size: 12px;
}
.m-cta-area {
  margin-top: auto;
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-top: 1px solid #f0f0f0;
}
.m-cta-area a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px;
  border-radius: 50px;
  font-family: "M PLUS 1", sans-serif;
  font-weight: 700;
  font-size: 15px;
  color: #fff;
  border: none;
}
.m-cta-area svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* --- スティッキーバー --- */
.sticky-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 998;
  background: #fff;
  border-top: 1px solid #eee;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
}
.sticky-bar-inner {
  display: flex;
  gap: 8px;
  max-width: 400px;
  margin: 0 auto;
}
.sticky-bar a {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px;
  font-family: "M PLUS 1", sans-serif;
  font-size: 13px;
  font-weight: 700;
  border-radius: 50px;
  text-decoration: none;
  color: #fff;
}
.sticky-bar svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* --- レスポンシブ --- */
@media (max-width: 1080px) {
  .nav,
  .header-cta {
    display: none;
  }
  .m-toggle {
    display: flex;
  }
  .sticky-bar {
    display: block;
  }
  .header-inner {
    padding: 0 16px;
  }
}
@media (min-width: 1081px) and (max-width: 1320px) {
  .nav-link,
  .nav-parent > .nav-trigger {
    font-size: 12px;
    padding: 24px 10px;
  }
  .cta-pill {
    font-size: 12px;
    padding: 10px 20px;
  }
  .header-inner {
    padding: 0 24px;
    gap: 20px;
  }
  .logo-title {
    font-size: 15px;
  }
}
