/**
 * CapeMotion SUPツアー - コンポーネント
 * section-hero.php など template-parts のスタイルを管理
 */


/* ============================================================
 * scroll-reveal ユーティリティ (.js-scroll-reveal)
 * IntersectionObserver で .is-visible を付与してフェードインUP
 * ============================================================ */

.js-scroll-reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 0.6s ease calc(var(--sr-delay, 0s)),
    transform 0.6s ease calc(var(--sr-delay, 0s));
}

.js-scroll-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}


/* ============================================================
 * セクション基本レイアウト (.cm-section)
 * section 自体をフルワイドに、内側コンテンツをコンテンツ幅に制限
 * ============================================================ */

.cm-section {
  margin-inline: calc(50% - 50vw);
  padding-block: var(--cm-section-py);
}

.cm-section__inner {
  max-width: var(--cm-content-max);
  margin-inline: auto;
  padding-inline: var(--cm-container-px);
}

@media (max-width: 768px) {
  .cm-section__inner {
    padding-inline: 0;
  }
}

/* 背景色モディファイア */
.cm-section--white {
  background: #fff;
}

.cm-section--sky {
  background: var(--cm-sky-blue);
}

.cm-section--offwhite {
  background: #F4F7F5;
}

.cm-section--warm {
  background: var(--cm-warm-light);
}

/* テキスト中央揃え */
.cm-section--center .cm-section__inner {
  text-align: center;
}

/* 上辺ウェーブ：sky セクション全体に適用 */
.cm-section--sky {
  position: relative;
  overflow: hidden;
}

.cm-wave-top {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: clamp(40px, 6vw, 72px);
  overflow: hidden;
  pointer-events: none;
}

.cm-wave-top__svg {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: 200%;
  height: 100%;
}

.cm-wave-top__svg--far {
  animation: wave-slide 18s linear infinite;
  animation-delay: -6s;
}

.cm-wave-top__svg--mid {
  animation: wave-slide 11s linear infinite reverse;
  animation-delay: -4s;
}

.cm-wave-top__svg--front {
  animation: wave-slide 7s linear infinite;
  animation-delay: -2s;
}

/* 波の高さ分だけコンテンツを下げる */
.cm-section--sky .cm-section__inner {
  padding-top: clamp(56px, 8vw, 96px);
}


/* ============================================================
 * セクション見出し (.cm-section-heading)
 * ============================================================ */

.cm-section-heading {
  text-align: center;
}

.cm-section-heading__en {
  display: block;
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-small);
  font-weight: 600;
  color: var(--cm-ocean-blue);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.cm-section-heading__ja {
  display: block;
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-h2);
  font-weight: 700;
  color: var(--cm-text-dark);
  line-height: 1.3;
  margin-bottom: 1rem;
}

.cm-section-heading__line {
  display: block;
  width: 48px;
  height: 4px;
  background: var(--cm-ocean-blue);
  border-radius: 2px;
  margin: 0 auto;
  margin-bottom: 20px;
}


/* ============================================================
 * ボタン: セカンダリ (.cm-btn-secondary)
 * 白枠・白テキスト（グラデーション背景上での使用を想定）
 * ============================================================ */

.cm-btn-secondary {
  display: inline-block;
  background: transparent;
  color: #fff;
  font-family: var(--cm-font-heading);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.05em;
  text-decoration: none;
  border: 2px solid rgba(255, 255, 255, 0.85);
  border-radius: var(--cm-radius-button);
  padding: 0.875rem 2.25rem;
  transition: var(--cm-transition);
}

.cm-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: #fff;
  color: #fff;
  transform: translateY(-2px);
}


/* ============================================================
 * USPセクション (.sec-usp)
 * ============================================================ */

.sec-usp {
  background: var(--cm-sky-blue);
  padding-block: var(--cm-section-py);
  margin-inline: calc(50% - 50vw);
}

.sec-usp__inner {
  max-width: 1080px;
  margin-inline: auto;
  padding-inline: var(--cm-container-px);
}

.sec-usp__heading {
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
}

/* 3カラムグリッド */
.sec-usp__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--cm-grid-gap);
}

@media (max-width: 640px) {
  .sec-usp__grid {
    grid-template-columns: 1fr;
  }
}

/* USPカード */
.cm-usp {
  text-align: center;
  padding: 2rem 1.5rem;
  background: #fff;
  border-top: 3px solid var(--cm-ocean-blue);
  border-radius: var(--cm-radius-card);
  box-shadow: var(--cm-shadow-card);
  transition: var(--cm-transition);
}

.cm-usp:hover {
  transform: translateY(-4px);
  box-shadow: var(--cm-shadow-hover);
}

.cm-usp__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem;
}

.cm-usp__icon svg {
  width: 100%;
  height: 100%;
  stroke: var(--cm-ocean-blue);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cm-usp__number {
  font-family: var(--cm-font-heading);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--cm-ocean-blue);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.cm-usp__catch {
  font-size: 1rem;
  font-weight: 700;
  color: var(--cm-text-dark);
  margin-bottom: 0.5rem;
}

.cm-usp__desc {
  font-size: 1rem;
  color: var(--cm-text-medium);
  line-height: 1.7;
  margin: 0;
}


/* ============================================================
 * ツアー一覧セクション (.sec-tours)
 * ============================================================ */

.sec-tours {
  background: #fff;
  padding-block: var(--cm-section-py);
  margin-inline: calc(50% - 50vw);
}

.sec-tours__inner {
  max-width: 1080px;
  margin-inline: auto;
  padding-inline: var(--cm-container-px);
}

.sec-tours__heading {
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
}

/* 3カラム → TAB 2列 → SP 1列 */
.sec-tours__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--cm-grid-gap);
  margin-bottom: clamp(2rem, 5vw, 3rem);
  padding-top: 120px; /* 難易度吹き出し（アイコン+吹き出し全体）の飛び出し分 */
}

@media (max-width: 900px) {
  .sec-tours__grid {
    grid-template-columns: repeat(2, 1fr);
    row-gap: 110px; /* 上カードへの吹き出し被り防止 */
  }
}

@media (max-width: 560px) {
  .sec-tours__grid {
    grid-template-columns: 1fr;
    row-gap: 110px;
  }
}

.sec-tours__footer {
  text-align: center;
}

/* ツアーカード */
.cm-tour-card {
  position: relative;
  border-radius: var(--cm-radius-card);
  box-shadow: var(--cm-shadow-card);
  background: #fff;
  transition: var(--cm-transition);
}

.cm-tour-card:has(.cm-tour-card__thumb) {
  background: transparent;
}

/* 詳細ページのカードは子要素の角丸（1.25rem）と親 border の角丸を揃える */
.cm-tour-card:has(.cm-tour-card__img-wrap) {
  border-radius: 1.25rem;
}

.cm-tour-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--cm-shadow-hover);
}

.cm-tour-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

/* サムネイル */
.cm-tour-card__thumb {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--cm-sky-blue);
  border-top-left-radius: var(--cm-radius-card);
  border-top-right-radius: var(--cm-radius-card);
}

.cm-tour-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  border-top-left-radius: var(--cm-radius-card);
  border-top-right-radius: var(--cm-radius-card);
  transition: transform 0.4s ease;
}

.cm-tour-card:hover .cm-tour-card__thumb img {
  transform: scale(1.04);
}

.cm-tour-card__thumb-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--cm-sky-blue) 0%, #E0F2FE 100%);
}

.cm-tour-card__badges {
  position: absolute;
  top: 0.6rem;
  left: 0.6rem;
  right: 0.6rem;
  z-index: 3;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.cm-tour-card__badges:empty {
  display: none;
}

.cm-tour-card__badge {
  font-family: var(--cm-font-heading);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  padding: 0.3rem 0.65rem;
  border-radius: 2rem;
  white-space: nowrap;
  line-height: 1.3;
  background: rgba(255, 255, 255, 0.92);
  color: var(--cm-ocean-blue);
  backdrop-filter: blur(4px);
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.cm-tour-card__badge--campaign {
  background: var(--cm-sunset-orange);
  color: #fff;
  border-color: var(--cm-sunset-orange);
  box-shadow: 0 2px 10px rgba(255, 122, 0, 0.3);
}

/* 難易度バッジ（白吹き出し + 上にアイコン / カード上空に密着配置） */
.cm-tour-card__difficulty-wrap {
  position: absolute;
  bottom: calc(100% - 1px); /* カード上端に密着（1px重ねて隙間消す） */
  right: 14px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  pointer-events: none;
}

.cm-tour-card__difficulty-icon {
  width: 60px;
  height: 60px;
  object-fit: contain;
  margin-left: -10px;
  margin-bottom: -17px;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.2));
}

.cm-tour-card__difficulty {
  position: relative;
  z-index: 1;
  display: inline-block;
  padding: 0.7rem 1.3rem;
  background: #fff;
  color: var(--cm-sunset-orange);
  font-family: var(--cm-font-heading);
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  line-height: 1.3;
  white-space: nowrap;
  border-radius: 16px;
  border: 2.5px solid var(--cm-sunset-orange);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

/* 吹き出しのしっぽ（下方向にオレンジ枠の三角／二重で枠線つなぎ） */
.cm-tour-card__difficulty::before,
.cm-tour-card__difficulty::after {
  content: "";
  position: absolute;
  left: auto;
  right: 28px;
  width: 0;
  height: 0;
  border-style: solid;
}

.cm-tour-card__difficulty::before {
  bottom: -30px;
  border-width: 30px 11px 0 11px;
  border-color: var(--cm-sunset-orange) transparent transparent transparent;
}

.cm-tour-card__difficulty::after {
  bottom: -24px;
  right: 31px;
  border-width: 26px 8px 0 8px;
  border-color: #fff transparent transparent transparent;
}

/* 詳細ページは少し大きめ */
.cm-tour-card:has(.cm-tour-card__img-wrap) .cm-tour-card__difficulty-wrap {
  right: 20px;
}

.cm-tour-card:has(.cm-tour-card__img-wrap) .cm-tour-card__difficulty-icon {
  width: 78px;
  height: 78px;
  margin-left: -12px;
  margin-bottom: -23px;
}

.cm-tour-card:has(.cm-tour-card__img-wrap) .cm-tour-card__difficulty {
  font-size: 1.05rem;
  padding: 0.8rem 1.5rem;
}

.cm-tour-card:has(.cm-tour-card__img-wrap) .cm-tour-card__difficulty::before {
  bottom: -38px;
  border-width: 38px 13px 0 13px;
}

.cm-tour-card:has(.cm-tour-card__img-wrap) .cm-tour-card__difficulty::after {
  bottom: -31px;
  right: 30px;
  border-width: 33px 10px 0 10px;
}

/* ボディ */
.cm-tour-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 1.25rem 1.5rem 1.5rem;
  gap: 0.5rem;
  background: #fff;
  border-bottom-left-radius: var(--cm-radius-card);
  border-bottom-right-radius: var(--cm-radius-card);
}

.cm-tour-card__title {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-h3);
  font-weight: 700;
  color: var(--cm-text-dark);
  line-height: 1.4;
  margin: 0;
}

.cm-tour-card__excerpt {
  font-size: 0.85rem;
  color: var(--cm-text-medium);
  line-height: 1.7;
  margin: 0;
}

.cm-tour-card__meta {
  list-style: none;
  padding: 0;
  margin: 0.25rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}

.cm-tour-card__meta-item {
  display: flex;
  align-items: center;
  gap: 0.3em;
  font-size: 0.8rem;
  color: var(--cm-text-medium);
}

.cm-tour-card__meta-item--price {
  font-family: var(--cm-font-heading);
  font-weight: 700;
  font-size: 1rem;
  color: var(--cm-ocean-blue);
}

.cm-tour-card__more {
  margin-top: auto;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--cm-ocean-blue);
  padding-top: 0.75rem;
}


/* ============================================================
 * フォトギャラリーCTAセクション (.sec-gallery-cta)
 * ============================================================ */

.sec-gallery-cta {
  position: relative;
  background: var(--cm-gradient-sunset);
  padding-block: clamp(3rem, 6vw, 5rem);
  margin-inline: calc(50% - 50vw);
  overflow: hidden;
}

.sec-gallery-cta__wave {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: clamp(72px, 9vw, 130px);
  /* コンテナ高さを明示してabsolute子要素を収める */
  overflow: hidden;
  pointer-events: none;
}

/* SVGを200%幅にして左へ-50%スライドでシームレスループ */
.sec-gallery-cta__wave-svg {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: 200%;
  height: 100%;
}

/* 最奥：小振幅・薄・最遅・順方向 / 位相を6s先行させてズレを演出 */
.sec-gallery-cta__wave-svg--far {
  animation: wave-slide 18s linear infinite;
  animation-delay: -6s;
}

/* 中間：中振幅・中透明・中速・逆方向 / 位相を4s先行 */
.sec-gallery-cta__wave-svg--mid {
  animation: wave-slide 11s linear infinite reverse;
  animation-delay: -4s;
}

/* 手前：大振幅・不透明・速・順方向 / 位相を2s先行 */
.sec-gallery-cta__wave-svg--front {
  animation: wave-slide 7s linear infinite;
  animation-delay: -2s;
}

@keyframes wave-slide {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-50%);
  }
}

.sec-gallery-cta__inner {
  position: relative;
  /* 波(absolute)より前面に */
  z-index: 1;
  max-width: 680px;
  margin-inline: auto;
  padding-inline: var(--cm-container-px);
  padding-top: clamp(80px, 10vw, 144px);
  /* 波の高さ分だけ下げる */
  text-align: center;
}

/* 上部テキスト */
.sec-gallery-cta__top {
  margin-bottom: 2rem;
}

.sec-gallery-cta__en {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-small);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0 0 0.5rem;
}

.sec-gallery-cta__heading {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-h2);
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
  margin: 0;
}

/* 写真3枚エリア */
.sec-gallery-cta__photos {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  margin-bottom: 2rem;
}

.sec-gallery-cta__photo {
  flex: 1;
  border-radius: var(--cm-radius-card);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.15);
  /* 画像挿入前のプレースホルダー */
}

.sec-gallery-cta__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.sec-gallery-cta__photo--side {
  height: 180px;
}

.sec-gallery-cta__photo--center {
  height: 260px;
}

/* 下部テキスト + CTA */
.sec-gallery-cta__bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
}

.sec-gallery-cta__sub {
  font-size: clamp(0.875rem, 2vw, 1rem);
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.8;
  margin: 0 0 1.5rem;
}


/* ============================================================
 * scroll-reveal JS 初期化
 * functions.php で wp_footer アクションからインライン出力するか
 * 専用 JS ファイルに切り出してください。
 * ============================================================ */


/* ============================================================
 * ヒーローセクション (.cm-hero)
 * ============================================================ */

.cm-hero {
  position: relative;
  width: 100vw;
  margin-inline: calc(50% - 50vw);
  margin-top: calc(-1 * var(--cm-header-h));
  /* #body_wrap の padding-top を相殺 */
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

@media (max-width: 767px) {
  .cm-hero {
    margin-top: calc(-1 * var(--cm-header-h-sp));
  }
}

/* SP: svh で iOS Safari のアドレスバーを考慮 */
@supports (height: 100svh) {
  .cm-hero {
    height: 100svh;
  }
}


/* ---- 背景スライダー ---- */

.cm-hero__slider {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.cm-hero__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.2s ease, visibility 0s linear 1.2s;
  will-change: opacity;
  backface-visibility: hidden;
  transform: translateZ(0);
}

.cm-hero__slide.is-active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
  transition-delay: 0s;
}

.cm-hero__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.06) translateZ(0);
  transition: transform 7.2s ease-out;
  will-change: transform;
  backface-visibility: hidden;
}

.cm-hero__slide.is-active img {
  transform: scale(1) translateZ(0);
}


/* ---- オーバーレイ ---- */

.cm-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: none;
}


/* ---- テキストコンテンツ ---- */

.cm-hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
  padding-inline: var(--cm-container-px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

/* フェードイン: 各要素に連番 delay */
.cm-hero__company,
.cm-hero__sub,
.cm-hero__heading,
.cm-hero__body,
.cm-hero__content .cm-btn-primary {
  opacity: 0;
  animation: cm-fadein-up 0.7s ease forwards;
}

.cm-hero__company {
  animation-delay: 0.1s;
}

.cm-hero__sub {
  animation-delay: 0.3s;
}

.cm-hero__heading {
  animation-delay: 0.5s;
}

.cm-hero__body {
  animation-delay: 0.7s;
}

.cm-hero__content .cm-btn-primary {
  animation-delay: 0.9s;
}

@keyframes cm-fadein-up {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.cm-hero__company {
  font-family: var(--cm-font-heading);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: -0.25rem;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.cm-hero__sub {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-small);
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 2px 12px rgba(0, 0, 0, 0.6);
}

.cm-hero__heading {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-hero);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.04em;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8), 0 4px 24px rgba(0, 0, 0, 0.6);
  margin: 0;
}

.cm-hero__heading-break {
  display: none;
}

@media (max-width: 767px) {
  .cm-hero__heading-break {
    display: inline;
  }
}

.cm-hero__body {
  font-size: clamp(1rem, 2vw, 1.125rem);
  font-weight: 400;
  line-height: 1.7;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 2px 16px rgba(0, 0, 0, 0.6);
}


/* ---- CTAボタン（ヒーロー内） ---- */

.cm-btn-primary {
  display: inline-block;
  background-color: var(--cm-sunset-orange);
  color: #fff;
  font-family: var(--cm-font-heading);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--cm-radius-button);
  box-shadow: var(--cm-shadow-button);
  transition: var(--cm-transition);
}

.cm-btn-primary:hover {
  background-color: var(--cm-golden-hour);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(232, 115, 42, 0.45);
}

.cm-btn-lg {
  padding: 1rem 2.5rem;
  font-size: 1.0625rem;
  letter-spacing: 0.05em;
}

.cm-btn-sm {
  padding: 0.4rem 1rem;
  font-size: 0.8125rem;
  letter-spacing: 0.03em;
  white-space: nowrap;
}


/* ---- スクロールアロー ---- */

.cm-hero__scroll-arrow {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.8);
  padding: 0.5rem;
  animation: cm-bounce 1.8s ease-in-out infinite;
  transition: color 0.2s ease;
}

.cm-hero__scroll-arrow:hover {
  color: #fff;
}

@keyframes cm-bounce {

  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  50% {
    transform: translateX(-50%) translateY(8px);
  }
}


/* ============================================================
 * お知らせセクション (.cm-news)
 * ============================================================ */

.cm-news {
  padding-block: var(--cm-section-py);
  background: #fff;
  margin-inline: calc(50% - 50vw);
}

.cm-news__inner {
  max-width: 860px;
  margin-inline: auto;
  padding-inline: var(--cm-container-px);
}

.cm-news__header {
  text-align: center;
  margin-bottom: clamp(2rem, 4vw, 3rem);
}

.cm-news__label {
  font-family: var(--cm-font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--cm-sunset-orange);
  margin-bottom: 0.5rem;
}

.cm-news__heading {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-h2);
  font-weight: 800;
  color: var(--cm-text-dark);
  line-height: 1.3;
}

.cm-news__body {
  font-size: var(--cm-text-body);
  color: var(--cm-text-dark);
  line-height: 1.9;
}


/* ============================================================
 * 予約CTAバナー (.cm-reserve-cta)
 * ============================================================ */

.cm-reserve-cta {
  padding: var(--cm-section-py) var(--cm-container-px);
  background: var(--cm-deep-sea);
  color: #fff;
}

/* フルワイド＋背景画像 */
.cm-reserve-cta--full {
  position: relative;
  width: 100vw;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  padding-left: 0;
  padding-right: 0;
  background-image: url('https://capemotion.net/wp-content/uploads/2026/03/3775e14c-e982-40bb-90ed-9efe2f2bffc6-e1774789173559.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  isolation: isolate;
}

.cm-reserve-cta--full::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 20, 40, 0.55);
  z-index: 0;
}

.cm-reserve-cta--full .cm-reserve-cta__inner {
  position: relative;
  z-index: 1;
  padding-left: var(--cm-container-px);
  padding-right: var(--cm-container-px);
}

.cm-reserve-cta__inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(2rem, 5vw, 4rem);
}

.cm-reserve-cta__text {
  flex: 1;
}

.cm-reserve-cta__label {
  font-family: var(--cm-font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 0.5rem;
}

.cm-reserve-cta__heading {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-h2);
  font-weight: 800;
  color: #fff;
  line-height: 1.3;
  margin-bottom: 0.75rem;
}

.cm-reserve-cta__body {
  font-size: var(--cm-text-small);
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.8;
}

.cm-reserve-cta__btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 768px) {
  .cm-reserve-cta__inner {
    flex-direction: column;
    text-align: center;
    align-items: center;
  }
}


/* ============================================================
 * SP スティッキーCTA (.cm-sticky-cta)
 * ============================================================ */

.cm-sticky-cta {
  display: none;
  /* PC: 非表示 */
}

@media (max-width: 768px) {
  .cm-sticky-cta {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 200;
    padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom));
    background: rgba(8, 79, 114, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    justify-content: center;
    box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.15);
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease, transform 0.4s ease;
    pointer-events: auto;
  }

  .cm-sticky-cta.is-animated-ready {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
  }

  .cm-sticky-cta.is-animated-ready.is-visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  .cm-sticky-cta.is-hidden {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
  }

  .cm-sticky-cta .cm-btn-primary {
    width: 100%;
    max-width: 400px;
    text-align: center;
    padding: 0.9rem 2rem;
    font-size: 1rem;
  }
}


/* ============================================================
 * ページヘッダー (.cm-page-hero)
 * 全下層ページのページヘッダーとして使用
 * ============================================================ */

.cm-page-hero {
  width: 100vw;
  margin-inline: calc(50% - 50vw);
  margin-top: calc(-1 * var(--cm-header-h));
  /* #body_wrap の padding-top を相殺 */
  height: clamp(200px, 30vw, 360px);
  background: url('/wp-content/uploads/2026/03/49760862-f305-4541-a508-1e6a9c7678a3-e1774791381929.webp') center / cover no-repeat;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  position: relative;
  padding: var(--cm-container-px);
}

@media (max-width: 767px) {
  .cm-page-hero {
    margin-top: calc(-1 * var(--cm-header-h-sp));
  }
}

/* ocean_blue オーバーレイ（ほとんどのページ） */
.cm-page-hero--blue::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(11, 110, 158, 0.55) 0%, rgba(8, 79, 114, 0.55) 100%);
}

/* sunset オーバーレイ（ギャラリーページ） */
.cm-page-hero--sunset::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--cm-gradient-sunset);
  opacity: 0.55;
}

.cm-page-hero--blue>*,
.cm-page-hero--sunset>* {
  position: relative;
  z-index: 1;
}

.cm-page-hero__subtitle {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-small);
  letter-spacing: 0.15em;
  opacity: 0.8;
  margin-bottom: 0.5rem;
}

.cm-page-hero__title {
  font-size: var(--cm-text-h1);
  font-weight: 800;
  line-height: 1.2;
  margin: 0;
}

.cm-page-hero__breadcrumb {
  position: absolute;
  bottom: 1rem;
  font-size: var(--cm-text-small);
  opacity: 0.7;
}

.cm-page-hero__breadcrumb a {
  color: #fff;
  text-decoration: none;
}
}


/* ============================================================
 * ギャラリーページ: 利用方法ステップ (.cm-gallery-steps)
 * ============================================================ */

.cm-gallery-steps {
  list-style: none;
  padding: 0;
  margin: clamp(2rem, 4vw, 3rem) auto 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  max-width: 560px;
}

.cm-gallery-step {
  width: 100%;
  background: #fff;
  border-radius: var(--cm-radius-card);
  box-shadow: var(--cm-shadow-card);
  padding: 2.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
}

.cm-gallery-step__arrow {
  display: block;
  text-align: center;
  color: var(--cm-sunset-orange);
  font-size: 1.1rem;
  padding: 20px 0;
}

.cm-gallery-step__number {
  font-family: var(--cm-font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1;
  color: var(--cm-sunset-orange);
  letter-spacing: 0.04em;
}

.cm-gallery-step__title {
  font-family: var(--cm-font-heading);
  font-size: var(--cm-text-h3);
  font-weight: 700;
  color: var(--cm-text-dark);
  margin: 0;
  line-height: 1.4;
}

.cm-gallery-step__desc {
  font-size: var(--cm-text-small);
  color: var(--cm-text-medium);
  line-height: 1.8;
  margin: 0;
}


/* ============================================================
 * ギャラリーページ: 公開終了バッジ
 * ============================================================ */

.cm-gallery-card--expired {
  opacity: 0.75;
}

.cm-gallery-card--expired:hover {
  transform: none;
  box-shadow: var(--cm-shadow-card);
  cursor: default;
}

.cm-gallery-card__expired-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  font-family: var(--cm-font-heading);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.cm-gallery-card__badge-expired {
  display: inline-block;
  background: #b0bec5;
  color: #fff;
  font-family: var(--cm-font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  border-radius: 50px;
  padding: 0.4em 1.2em;
  cursor: default;
}


/* ============================================================
 * ギャラリー写真ページ: 写真グリッド (.cm-gallery-grid)
 * 子ページ（ブロックエディタ）に挿入する写真用
 * ============================================================ */

.cm-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

@media (max-width: 767px) {
  .cm-gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.cm-gallery-grid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--cm-radius-image);
  cursor: zoom-in;
  transition: var(--cm-transition);
}

.cm-gallery-grid img:hover {
  opacity: 0.85;
}

.cm-gallery-expiry {
  text-align: center;
  color: var(--cm-text-medium);
  font-size: var(--cm-text-small);
  margin-bottom: 1.5rem;
}
/* ============================================================
 * ツアー写真 個別ページ: フォトグリッド (.cm-photo-gallery)
 * ============================================================ */
.cm-photo-gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
}

@media (max-width: 768px) {
  .cm-photo-gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}

.cm-photo-gallery__item a {
  display: block;
  overflow: hidden;
  border-radius: var(--cm-radius-image, 4px);
}

.cm-photo-gallery__item img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  display: block;
  transition: opacity .2s;
}

.cm-photo-gallery__item img:hover {
  opacity: 0.85;
}

.cm-photo-gallery__item--video {
  border-radius: var(--cm-radius-image, 4px);
  overflow: hidden;
  background: #000;
}

.cm-video-tile {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: #000;
  cursor: pointer;
  border-radius: var(--cm-radius-image, 4px);
  overflow: hidden;
}

.cm-video-tile video {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  display: block;
  background: #000;
  pointer-events: none;
}

.cm-video-tile__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 18px;
  line-height: 44px;
  text-align: center;
  padding-left: 4px;
  transition: background 0.2s, transform 0.2s;
  pointer-events: none;
}

.cm-video-tile:hover .cm-video-tile__play,
.cm-video-tile:focus-visible .cm-video-tile__play {
  background: rgba(0, 0, 0, 0.75);
  transform: translate(-50%, -50%) scale(1.08);
}

/* lightbox オーバーレイ */
.cm-video-lightbox {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  background: #000 !important;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 99999 !important;
  margin: 0 !important;
}

.cm-video-lightbox.is-open {
  display: flex !important;
}

.cm-video-lightbox__inner {
  position: relative;
  width: 100%;
  max-width: 1200px;
  max-height: 90vh;
}

.cm-video-lightbox__video {
  display: block;
  width: 100%;
  max-height: 90vh;
  background: #000;
}

.cm-video-lightbox__close {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  padding: 0;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  border: 2px solid #fff;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, transform 0.15s;
  z-index: 10000;
}

.cm-video-lightbox__close:hover,
.cm-video-lightbox__close:focus-visible {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.08);
  outline: none;
}

.cm-video-lightbox__close svg {
  display: block;
}

body.cm-lightbox-open {
  overflow: hidden;
}

body.cm-lightbox-open .sup-float {
  z-index: -1 !important;
}

.cm-photo-gallery__note {
  text-align: center;
  font-size: 0.85rem;
  color: var(--cm-text-medium, #666);
  line-height: 1.8;
}

/* パスワードフォーム */
.cm-gallery-password {
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
}

.cm-gallery-password__lead {
  margin-bottom: 1.5rem;
  line-height: 1.8;
}


/* ============================================================
 * お知らせ（NEWS）— フロントページ・一覧・個別
 * ============================================================ */

/* フロントページ: お知らせリスト */
.cm-news-list {
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.cm-news-list__item {
  border-left: 3px solid var(--cm-ocean-blue);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(12, 74, 110, 0.06);
  transition: var(--cm-transition);
}

.cm-news-list__link {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  padding: 1rem 1.2rem;
  text-decoration: none;
  color: var(--cm-text-dark);
  transition: var(--cm-transition);
}

.cm-news-list__item:hover {
  border-left-color: var(--cm-sunset-orange);
  transform: translateX(3px);
}

.cm-news-list__link:hover {
  background-color: var(--cm-warm-light);
}

.cm-news-list__date {
  flex-shrink: 0;
  display: inline-block;
  background: var(--cm-sky-blue);
  padding: 0.2rem 0.7rem;
  border-radius: 4px;
  font-size: 0.8rem;
  color: var(--cm-text-medium);
  font-family: var(--cm-font-heading);
}

.cm-news-list__title {
  font-size: var(--cm-text-body);
  font-weight: 500;
}

.cm-news-list__new {
  display: inline-block;
  background: var(--cm-sunset-orange);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  margin-left: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  vertical-align: middle;
}

.cm-news__more {
  text-align: center;
  margin-top: 2rem;
}

/* お知らせアーカイブ一覧 */
.cm-news-archive {
  list-style: none;
  padding: 0;
  margin: 0 auto;
  max-width: 800px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.cm-news-archive__item {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 12px rgba(12, 74, 110, 0.06);
  border-left: 3px solid var(--cm-ocean-blue);
  overflow: hidden;
  transition: var(--cm-transition);
}

.cm-news-archive__item:hover {
  transform: translateX(4px);
  box-shadow: 0 4px 20px rgba(12, 74, 110, 0.12);
  border-left-color: var(--cm-sunset-orange);
}

.cm-news-archive__link {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding: 1.2rem 1.5rem;
  text-decoration: none;
  color: var(--cm-text-dark);
}

.cm-news-archive__date {
  flex-shrink: 0;
  display: inline-block;
  background: var(--cm-sky-blue);
  padding: 0.2rem 0.7rem;
  border-radius: 4px;
  font-size: 0.8rem;
  color: var(--cm-text-medium);
  font-family: var(--cm-font-heading);
}

.cm-news-archive__title {
  font-size: var(--cm-text-body);
  font-weight: 500;
}

.cm-news-archive__new {
  display: inline-block;
  background: var(--cm-sunset-orange);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  margin-left: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  vertical-align: middle;
}

.cm-news-archive__empty {
  text-align: center;
  padding: 3rem 0;
  color: var(--cm-text-medium);
}


/* ============================================================
 * 記事個別ページ（お知らせ・ブログ共通）
 * ============================================================ */

.cm-article {
  max-width: 800px;
  margin: 0 auto;
}

.cm-article__header {
  padding-left: 1.5rem;
  border-left: 4px solid var(--cm-ocean-blue);
  margin-bottom: 2.5rem;
}

.cm-article__date {
  display: inline-block;
  background: var(--cm-sky-blue);
  padding: 0.25rem 0.8rem;
  border-radius: 4px;
  font-size: 0.8rem;
  color: var(--cm-text-medium);
  font-family: var(--cm-font-heading);
  margin-bottom: 0.75rem;
}

.cm-article__title {
  font-size: var(--cm-text-h2);
  font-weight: 700;
  color: var(--cm-text-dark);
  line-height: 1.4;
  position: relative;
  padding-bottom: 1rem;
}

.cm-article__title::after {
  content: '';
  display: block;
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 3px;
  background: linear-gradient(to right, var(--cm-ocean-blue), var(--cm-sunset-orange));
  border-radius: 2px;
}

.cm-article__thumbnail {
  margin: 0 0 2rem;
}

.cm-article__thumbnail img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(12, 74, 110, 0.1);
}

.cm-article__categories {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.cm-article__category {
  display: inline-block;
  font-size: 0.75rem;
  background: var(--cm-sky-blue);
  color: var(--cm-deep-sea);
  padding: 0.2rem 0.7rem;
  border-radius: 20px;
}

.cm-article__body {
  line-height: 1.9;
  font-size: var(--cm-text-body);
  color: var(--cm-text-dark);
  margin-bottom: 3rem;
}

.cm-article__body p {
  margin-bottom: 1.5em;
}

.cm-article__body img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.cm-article__body h2 {
  font-size: var(--cm-text-h3);
  font-weight: 700;
  color: var(--cm-text-dark);
  padding-left: 1rem;
  border-left: 3px solid var(--cm-ocean-blue);
  margin: 2.5rem 0 1rem;
}

.cm-article__body h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--cm-text-dark);
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--cm-sky-blue);
  margin: 2rem 0 0.8rem;
}

.cm-article__footer {
  text-align: center;
  padding: 2.5rem 0;
  border-top: 2px solid #f0f7ff;
  margin-top: 1rem;
}

.cm-article__footer .cm-btn-outline-blue::before {
  content: '\2190\0020';
}


/* ============================================================
 * よみもの（BLOG）— カード一覧
 * ============================================================ */

/* セクション背景: ライトグレー */
.cm-section--light {
  background: #f8fafc;
}

.cm-blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .cm-blog-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
}

@media (min-width: 1200px) {
  .cm-blog-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.cm-blog-grid--front {
  max-width: 960px;
  margin-inline: auto;
}

.cm-blog-grid--front .cm-blog-card:only-child {
  grid-column: 1 / -1;
  max-width: 340px;
  justify-self: center;
}

.cm-blog__more {
  text-align: center;
  margin-top: 2rem;
}

.cm-blog-card {
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 12px rgba(12, 74, 110, 0.08);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.cm-blog-card:hover {
  box-shadow: 0 6px 24px rgba(12, 74, 110, 0.14);
  transform: translateY(-4px);
}

.cm-blog-card__link {
  display: block;
  text-decoration: none;
  color: var(--cm-text-dark);
}

.cm-blog-card__thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--cm-sky-blue);
}

.cm-blog-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.cm-blog-card:hover .cm-blog-card__thumb img {
  transform: scale(1.05);
}

.cm-blog-card__no-image {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 50%, #e0f7fa 100%);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--cm-ocean-blue);
  letter-spacing: 0.1em;
  opacity: 0.8;
}
.cm-blog-card__no-image::before {
  content: '';
  display: block;
  width: 40px;
  height: 40px;
  border: 2px solid var(--cm-ocean-blue);
  border-radius: 8px;
  opacity: 0.4;
  background: linear-gradient(135deg, transparent 40%, rgba(14, 165, 233, 0.15) 100%);
}

.cm-blog-card__body {
  padding: 1rem 1.2rem 1.4rem;
}

.cm-blog-card__date {
  display: block;
  font-size: var(--cm-text-small);
  color: var(--cm-text-medium);
  font-family: var(--cm-font-heading);
  margin-bottom: 0.4rem;
}

.cm-blog-card__title {
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.5;
  margin: 0 0 0.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cm-blog-card__excerpt {
  font-size: var(--cm-text-small);
  color: var(--cm-text-medium);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.cm-blog-grid__empty {
  text-align: center;
  padding: 3rem 0;
  color: var(--cm-text-medium);
  grid-column: 1 / -1;
}

/* ページネーション共通 */
.cm-pagination,
.nav-links {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}

.cm-pagination .page-numbers,
.nav-links .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 0.5rem;
  border-radius: 8px;
  font-size: var(--cm-text-small);
  font-family: var(--cm-font-heading);
  text-decoration: none;
  color: var(--cm-text-medium);
  background: #fff;
  border: 1px solid var(--cm-sky-blue);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.cm-pagination .page-numbers.current,
.nav-links .page-numbers.current {
  background: var(--cm-ocean-blue);
  color: #fff;
  border-color: var(--cm-ocean-blue);
}

.cm-pagination .page-numbers:hover:not(.current),
.nav-links .page-numbers:hover:not(.current) {
  background: var(--cm-warm-light);
}
