/*
=============================================================================
ヘッダー周り
=============================================================================
*/

/* PR表記 */
.c-prNotation {
  margin-right: 8px;
}

/*
=============================================================================
ホテル画像エリア - カードデザインとの統一
=============================================================================
*/

/* ホテル画像コンテナ */
.hotel-image-container {
  position: relative;
  margin-bottom: 30px;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* スライダー画像 */
#hotel-image-slider .swiper-slide img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: transform 0.4s ease;
}

/* スライダーコンテナ */
#hotel-image-slider {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
}

/* 単一画像表示 */
.hotel-image-container .wp-block-image {
  margin: 0;
  border-radius: 4px;
  overflow: hidden;
}

.hotel-image-container .wp-block-image img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  transition: transform 0.4s ease;
}

/* 画像ホバー効果 */
.hotel-image-container:hover img {
  transform: scale(1.05);
}

/* 画像出典表示 */
.hotel-image-credits {
  text-align: right;
  font-size: 12px;
  color: #666;
  margin-top: 10px;
  padding: 0 10px;
}

.hotel-image-credits a {
  color: #667eea;
  text-decoration: none;
}

.hotel-image-credits a:hover {
  text-decoration: underline;
}

/*
=============================================================================
おやこんぱす評価サマリーボックス
=============================================================================
*/

.oyacompass-summary-box {
  background: #f9f9f9;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 20px;
  margin: 30px 0;
  position: relative;
  cursor: help;
}

.oyacompass-summary-box::after {
  content: "あくまでこの評価は乳幼児との宿泊に特化した評価です。\A一般的なホテル・旅館の評価とは異なりますので、その点ご注意ください。";
  position: absolute;
  bottom: 105%;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #fff3e0, #ffcc80);
  color: #f57c00;
  padding: 8px 12px;
  border-radius: 5px;
  font-size: 16px;
  line-height: 24px;
  max-width: 800px;
  word-break: keep-all;
  white-space: pre-line;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
  z-index: 10;
}

.oyacompass-summary-box:hover::after {
  opacity: 1;
  visibility: visible;
}

@media screen and (max-width: 800px) {
  .oyacompass-summary-box::after {
    max-width: calc(100% - 40px);
  }
}

.oyacompass-summary-title {
  text-align: center;
  font-size: 22px;
  margin-top: 0;
  margin-bottom: 20px;
  color: #333;
}

.rating-scores-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

.rating-score-box {
  text-align: center;
}

.rating-score-box h4 {
  margin: 0 0 8px;
  font-size: 16px;
  color: #555;
}

.rating-score-box .score-value {
  font-size: 16px;
  color: #777;
  margin-bottom: 8px;
}

.rating-score-box .score-value span {
  font-size: 32px;
  font-weight: bold;
  line-height: 1;
}

.baby-score .score-value span {
  color: #e67e22; /* ベビー：オレンジ */
}

.kids-score .score-value span {
  color: #3498db; /* キッズ：ブルー */
}

.score-bar {
  background-color: #e0e0e0;
  border-radius: 5px;
  height: 10px;
  overflow: hidden;
}

.score-bar div {
  height: 100%;
  border-radius: 5px;
  transition: width 0.5s ease-in-out;
}

.baby-score .score-bar div {
  background-color: #e67e22;
}

.kids-score .score-bar div {
  background-color: #3498db;
}

.operator-comment {
  margin-top: 25px;
  border-top: 1px dashed #ccc;
  padding-top: 20px;
}

.operator-comment .comment-header {
  font-weight: bold;
  margin-bottom: 10px;
  font-size: 16px;
  color: #444;
}

.operator-comment .comment-body {
  font-size: 16px;
  line-height: 1.8;
}

.operator-comment .comment-body p {
  margin-bottom: 12px;
}

.rating-link {
  font-size: 12px;
  margin-top: 20px;
  text-align: right;
  color: #757575;
}

/*
=============================================================================
こだわり条件
=============================================================================
*/

/* こだわり条件ハッシュタグのスタイル */
.hotel-features-tags {
  display: flex;
  flex-wrap: wrap; /* タグが多場合に折り返す */
  gap: 8px; /* タグ間の余白 */
  margin: 20px 0; /* 上下の余白 */
  padding: 0;
}

.feature-tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  background-color: #eef5fa; /* 背景色 */
  color: #005f9e; /* 文字色 */
  border-radius: 20px; /* 角を丸くする */
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  border: 1px solid #d0e3f1; /* 枠線 */
}

.feature-tag .fas {
  margin-right: 6px; /* アイコンと文字の間の余白 */
  font-size: 1.1em; /* アイコンを少し大きく */
}

/*
=============================================================================
見出しスタイル - 一覧ページとの統一
=============================================================================
*/

/* メイン見出し */
.post_content h2 {
  font-size: 20px;
  margin: 40px 0 20px 0;
  color: #333;
  border-bottom: none;
  border-left: 5px solid var(--color_main);
  border-top: 2px solid var(--color_main);
  border-bottom: 2px solid var(--color_main);
  padding-left: 20px;
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  padding: 15px 20px;
  border-radius: 4px;
}

/*
=============================================================================
テーブルスタイル - カードデザインとの統一
=============================================================================
*/

/* テーブル全体のスタイル */
.wp-block-table {
  margin: 20px 0;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  background: white;
}

.wp-block-table table {
  width: 100%;
  border-collapse: collapse;
  margin: 0;
}

/* テーブルヘッダー */
.wp-block-table th {
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  color: #333;
  font-weight: 600;
  padding: 15px 20px;
  border: 1px solid #dee2e6;
  text-align: left;
  min-width: 150px;
  vertical-align: top;
  width: 200px !important;
}

@media screen and (max-width: 767px) {
  .wp-block-table th {
    width: 120px !important;
  }
}

/* テーブルデータ */
.wp-block-table td {
  padding: 15px 20px;
  border: 1px solid #dee2e6;
  line-height: 1.6;
  color: #555;
  vertical-align: top;
}

/* テーブル行のホバー効果 */
.wp-block-table tr:hover {
  background: rgba(102, 126, 234, 0.05);
}

/*
=============================================================================
レビューセクション - カードデザインとの統一
=============================================================================
*/

/* お客様の声ボックス */
.post_content div[style*="background: #f9f9f9"] {
  background: linear-gradient(135deg, #e8f4fd, #d1ecf1) !important;
  border: 1px solid #bee5eb !important;
  border-left: 5px solid var(--color_main) !important;
  border-radius: 4px !important;
  padding: 20px !important;
  margin: 20px 0 !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08) !important;
}

.post_content div[style*="background: #f9f9f9"] h4 {
  color: #333 !important;
  margin-top: 0 !important;
  margin-bottom: 15px !important;
  font-size: 1.1em !important;
}

/*
=============================================================================
子連れ情報タブ - 機能タグとの統一
=============================================================================
*/

/* タブリスト */
.swell-block-tab .c-tabList {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 25px;
  border: none;
  background: none;
}

/* タブボタン */
.c-tabList__button {
  padding: 12px 20px;
  border: none;
  border-radius: 4px;
  background: linear-gradient(135deg, #f5f5f5, #e0e0e0);
  color: #333;
  font-weight: 600;
  transition: all 0.3s ease;
  cursor: pointer;
}

/* アクティブタブ */
.c-tabList__button[aria-selected="true"] {
  background: var(--color_main);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* タブボタンホバー */
.c-tabList__button:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* タブコンテンツエリア */
.c-tabBody {
  background: white;
  border-radius: 4px;
  padding: 25px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/*
=============================================================================
アコーディオン項目 - 機能タグデザインとの統一
=============================================================================
*/

/* アコーディオンコンテナ */
.family-items-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* アコーディオン項目 */
.family-item {
  margin-bottom: 0;
  border: none;
  border-radius: 4px;
  background: white;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  overflow: hidden;
}

/* アコーディオン項目ホバー */
.family-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* アコーディオンヘッダー */
.family-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  cursor: pointer;
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  border-radius: 4px 16px 0 0;
  transition: all 0.3s ease;
  border: none;
}

/* ヘッダーホバー */
.family-item-header:hover {
  background: linear-gradient(135deg, #e9ecef, #dee2e6);
}

/* アコーディオンタイトル */
.family-item-title {
  font-weight: 600;
  margin: 0;
  color: #333;
  font-size: 14px;
}

/* ステータス表示 - 機能タグと同じスタイル */
.family-item-status {
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 4px;
  font-weight: 600;
  margin-right: 10px;
  white-space: nowrap;
  transition: all 0.3s ease;
}

/* ステータス色分け - 機能タグカラーを参考 */
.status-good {
  background: linear-gradient(135deg, #e8f5e8, #c8e6c9);
  color: #388e3c;
}

.status-warning {
  background: linear-gradient(135deg, #fff3e0, #ffcc80);
  color: #f57c00;
}

.status-unavailable {
  background: linear-gradient(135deg, #ffebee, #ffcdd2);
  color: #d32f2f;
}

.status-unknown {
  background: linear-gradient(135deg, #f5f5f5, #e0e0e0);
  color: #757575;
  border: 2px dashed #bdbdbd;
}

/* トグルアイコン */
.family-item-toggle {
  font-size: 18px;
  font-weight: bold;
  color: #667eea;
  transition: transform 0.3s ease;
  min-width: 24px;
  text-align: center;
}

.family-item.expanded .family-item-toggle {
  transform: rotate(45deg);
  color: #5a67d8;
}

/* 詳細コンテンツ */
.family-item-details {
  display: none;
  padding: 20px;
  border-top: 1px solid #e0e0e0;
  background: white;
  animation: slideDown 0.3s ease;
}

.family-item.expanded .family-item-details {
  display: block;
}

/* 詳細テキスト */
.family-item-notes {
  color: #555;
  line-height: 1.6;
  margin-bottom: 15px;
  font-size: 14px;
}

/* ソースリンク - ボタンデザインとの統一 */
.family-source-link {
  display: inline-block;
  margin-top: 8px;
  padding: 8px 16px;
  background: var(--color_cta);
  color: #333;
  text-decoration: none;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  transition: all 0.3s ease;
}

.family-source-link:hover {
  background: var(--color_main);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/*
=============================================================================
OTAボタンコンテナ（枠線ロゴスタイル）
=============================================================================
*/

/* 予約ボタンコンテナ */
.ota-links-container-bordered {
  /* display: flex; などの設定を削除 (ボタンラッパーに移動) */
  margin: 40px 0 !important;
  padding: 30px;
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  border-radius: 4px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08) !important;
  text-align: center;
}

/* ★ 新規追加：コンテナタイトル */
.ota-links-container-title {
  font-size: 20px;
  font-weight: 600;
  color: #333;
  margin-top: 0;
  margin-bottom: 25px; /* タイトルとボタンの間の余白 */
  text-align: center;
  padding-bottom: 15px;
  border-bottom: 2px solid #e0e0e0; /* 薄い下線 */
  position: relative;
}

/* ★ 新規追加：タイトルの装飾下線 */
.ota-links-container-title::after {
  content: "";
  position: absolute;
  bottom: -2px; /* border-bottomと重ねる */
  left: 50%;
  transform: translateX(-50%);
  width: 80px; /* 装飾線の幅 */
  height: 2px;
  background-color: var(--color_main, #667eea); /* SWELLのメインカラー */
}

/* ★ 新規追加：ボタンラッパー（flex設定をこちらに移動） */
.ota-links-buttons-wrapper {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  align-items: stretch;
}

/*
=============================================================================
OTAボタン ブランドカラー（テキスト枠線スタイル）
=============================================================================
*/

/* ★ テキスト入りボタンの独自スタイル */
.ota-link-bordered {
  display: flex;
  align-items: center;
  justify-content: center; /* ★ 両端揃え → 中央揃え に変更 */
  padding: 12px 40px 12px 16px; /* ★ 右側に矢印用の余白(40px)を確保 */
  position: relative; /* ★ 矢印を絶対配置するための基準 */
  background: #ffffff;
  border: 2px solid;
  border-radius: 4px;
  text-decoration: none;
  color: #333333;
  transition: all 0.3s ease;
  min-width: 220px;
  flex-grow: 1;
  max-width: 320px;
  box-sizing: border-box;
}

/* ブランド名のスタイル */
.ota-link-bordered .ota-brand-name {
  font-weight: 700;
  font-size: 15px;
  margin-right: 0.25em;
  color: #333;
  transition: color 0.3s ease;
}

/* テキストのスタイル */
.ota-link-bordered .ota-text {
  font-size: 14px;
  color: #555;
  transition: color 0.3s ease;
}

/* 矢印のスタイル (CSSで描画) */
.ota-link-bordered .ota-arrow {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-top: 2px solid #555;
  border-right: 2px solid #555;
  transition: all 0.3s ease;
  position: absolute;
  right: 16px;
  top: 50%;
  transform: rotate(45deg) translateY(-50%);
  margin-top: 0;
}

/* --- ホバーエフェクト --- */
.ota-link-bordered:hover {
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}
.ota-link-bordered:hover .ota-brand-name,
.ota-link-bordered:hover .ota-text {
  color: #ffffff; /* テキストを白抜きに */
}
.ota-link-bordered:hover .ota-arrow {
  border-color: #ffffff; /* 矢印を白に */
}

/* --- 個別ブランドカラー（枠線とホバー背景） --- */

/* 楽天トラベル */
.ota-link-bordered.ota-link-rakuten-plan,
.ota-link-bordered.ota-link-rakuten-info {
  border-color: #bf0000;
}
.ota-link-bordered.ota-link-rakuten-plan:hover,
.ota-link-bordered.ota-link-rakuten-info:hover {
  background: #bf0000;
  border-color: #bf0000;
}

/* じゃらん */
.ota-link-bordered.ota-link-jalan {
  border-color: #ff9a00;
}
.ota-link-bordered.ota-link-jalan:hover {
  background: #ff9a00;
  border-color: #ff9a00;
}
/* じゃらんのホバーテキスト色（背景が明るいため） */
.ota-link-bordered.ota-link-jalan:hover .ota-brand-name,
.ota-link-bordered.ota-link-jalan:hover .ota-text {
  color: #333; /* 白抜きではなく濃い色にする */
}
.ota-link-bordered.ota-link-jalan:hover .ota-arrow {
  border-color: #333;
}

/* Yahoo!トラベル */
.ota-link-bordered.ota-link-yahoo {
  border-color: #ff0033;
}
.ota-link-bordered.ota-link-yahoo:hover {
  background: #ff0033;
  border-color: #ff0033;
}

/* 一休 */
.ota-link-bordered.ota-link-ikyu {
  border-color: #002d5b;
}
.ota-link-bordered.ota-link-ikyu:hover {
  background: #002d5b;
  border-color: #002d5b;
}

/* Agoda */
.ota-link-bordered.ota-link-agoda {
  border-color: #5339f5;
}
.ota-link-bordered.ota-link-agoda:hover {
  background: #5339f5;
  border-color: #5339f5;
}

/* JTB */
.ota-link-bordered.ota-link-jtb {
  border-color: #c80025;
}
.ota-link-bordered.ota-link-jtb:hover {
  background: #c80025;
  border-color: #c80025;
}

/* スマホ表示の調整 */
@media (max-width: 768px) {
  .ota-links-container-bordered {
    padding: 20px;
  }

  .ota-links-buttons-wrapper {
    flex-direction: column;
    gap: 12px;
  }

  .ota-link-bordered {
    min-width: 100%;
    max-width: 100%;
  }
}

/*
=============================================================================
アニメーション
=============================================================================
*/

@keyframes slideDown {
  from {
    opacity: 0;
    max-height: 0;
    padding-top: 0;
    padding-bottom: 0;
  }
  to {
    opacity: 1;
    max-height: 500px;
    padding-top: 20px;
    padding-bottom: 20px;
  }
}

/*
=============================================================================
レスポンシブ対応
=============================================================================
*/

@media (max-width: 768px) {
  /* タブボタンの調整 */
  .c-tabList {
    justify-content: center;
  }

  .c-tabList__button {
    padding: 10px 16px;
    font-size: 14px;
  }

  /* タブコンテンツの調整 */
  .c-tabBody {
    padding: 20px;
  }

  /* アコーディオンの調整 */
  .family-item-header {
    padding: 12px 15px;
  }

  .family-item-details {
    padding: 15px;
  }

  /* 予約ボタンコンテナの調整 */
  div[style*="text-align:center"] {
    padding: 20px;
  }

  .swell-block-button__link {
    flex-grow: 1;
    min-width: 180px;
    padding: 12px 20px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  /* ホテル画像の調整 */
  .hotel-image-container {
    border-radius: 4px;
  }

  /* テーブルの調整 */
  .wp-block-table {
    border-radius: 4px;
  }

  .wp-block-table th,
  .wp-block-table td {
    padding: 12px 15px;
  }

  /* タブの調整 */
  .c-tabBody {
    border-radius: 4px;
    padding: 15px;
  }

  /* アコーディオンの調整 */
  .family-item {
    border-radius: 4px;
  }

  .family-item-header {
    border-radius: 4px 12px 0 0;
  }
}

/*
=============================================================================
関連ホテル (Slickスライダー)
=============================================================================
*/

/* 関連ホテルコンテナ */
.related-hotels-container {
  margin-top: 48px;
  border-top: 2px solid #f2f2f2;
  overflow: hidden;
  order: 3;
}

.related-hotels-container h2 {
  font-size: 20px;
  margin: 40px 0 20px 0;
  color: #333;
  padding: 15px 20px;
  text-align: center;
  font-weight: bold;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.8em;
}

/* スライダー内の各アイテム（Slickが生成するラッパー間）の余白調整 */
.related-hotel-slide-item {
  padding: 0 10px;
  box-sizing: border-box;
}

/* カード本体のスタイル */
.related-hotel-item {
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  transition: box-shadow 0.3s ease;
  background: #fff;
  margin-bottom: 10px;
}

.related-hotel-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.related-hotel-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

/* ホテル画像エリア */
.related-hotel-image {
  width: 100%;
  aspect-ratio: 16 / 9;
}

.related-hotel-image img {
  width: 100%;
  height: auto;
  object-fit: cover;
  aspect-ratio: 16 / 9;
}

/* ホテル情報エリア */
.related-hotel-content {
  padding: 15px;
}

/* 類似理由ラベル */
.related-reason-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 10px;
}

.related-reason-badge {
  background-color: #ffeaa7;
  color: #a07d00;
  font-size: 11px;
  font-weight: bold;
  padding: 4px 8px;
  border-radius: 4px;
  line-height: 1;
}

.related-hotel-meta {
  font-size: 14px;
  color: #555;
}

.related-hotel-price {
  font-size: 16px;
  font-weight: bold;
  color: #d9534f;
  margin-bottom: 5px;
}

/* Slickスライダーの矢印（左右）の調整 */
.related-hotels-slider .slick-prev,
.related-hotels-slider .slick-next {
  width: 40px;
  height: 40px;
}
.related-hotels-slider .slick-prev {
  left: 10px;
  z-index: 10;
}
.related-hotels-slider .slick-next {
  right: 10px;
}

.related-hotels-slider .slick-prev:before,
.related-hotels-slider .slick-next:before {
  font-size: 40px;
  opacity: 1;
}

/* スマホ表示 */
@media (max-width: 767px) {
  .related-hotel-title {
    font-size: 16px;
    min-height: 0;
  }

  /* スマホでは矢印を非表示 (スワイプ操作がメインのため) */
  .related-hotels-slider .slick-prev,
  .related-hotels-slider .slick-next {
    display: none !important;
  }
}

/* Slickスライダーのトラック自体をFlexbox化（高さ揃えの核） */
.related-hotels-slider .slick-track {
  display: flex;
}
.related-hotels-slider .slick-track .slick-slide {
  height: auto;
  display: flex;
}
.related-hotels-slider .slick-track .slick-slide > div {
  height: 100%;
  width: 100%;
}

/* スライドのパディング調整 */
.related-hotel-slide-item {
  padding: 0 10px;
  box-sizing: border-box;
  height: 100%;
}

/* カード本体をFlexコンテナ化 */
.related-hotel-item {
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  margin-bottom: 10px;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* リンクも高さを継承 */
.related-hotel-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

/* ホテル情報エリア（テキスト部分） */
.related-hotel-content {
  padding: 15px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

/* 類似理由ラベル */
.related-reason-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 10px;
  min-height: 19px;
}

/* タイトル */
.related-hotel-title {
  font-size: 17px;
  font-weight: bold;
  margin: 0 0 10px 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.8em;
}

/* メタ情報（価格とエリア） */
.related-hotel-meta {
  font-size: 14px;
  color: #555;
  margin-top: auto;
}
