/**
 * ゆるりテーマ - ブロックエディター用CSSクラス
 * 
 * 【使い方】
 * ブロックの「高度な設定」→「追加CSSクラス」に以下のクラスを入力
 * 
 * ========================================
 * ■ セクション系
 * ========================================
 * .yururi-section          - 基本セクション（上下余白）
 * .yururi-section-border   - 下線付きセクション
 * .yururi-section-bg       - 背景色付きセクション
 * 
 * ========================================
 * ■ ヘッダー・タイトル系
 * ========================================
 * .yururi-section-header   - セクションヘッダー（中央寄せ）
 * .yururi-label            - 英語ラベル（ROOMS, FACILITIESなど）
 * .yururi-title            - セクションタイトル
 * .yururi-lead             - リード文
 * 
 * ========================================
 * ■ レイアウト系
 * ========================================
 * .yururi-container        - コンテナ（最大幅1000px）
 * .yururi-grid-2           - 2カラムグリッド
 * .yururi-grid-3           - 3カラムグリッド
 * .yururi-grid-4           - 4カラムグリッド
 * .yururi-room-gallery     - お部屋画像（メイン1枚+サブ2枚横並び）
 * .yururi-gallery-main     - ギャラリーメイン画像
 * .yururi-gallery-sub      - ギャラリーサブ画像
 * 
 * ========================================
 * ■ カード系
 * ========================================
 * .yururi-card             - 基本カード
 * .yururi-card-featured    - 強調カード（桜色ボーダー）
 * .yururi-card-image       - カード内画像
 * .yururi-card-content     - カード内コンテンツ
 * 
 * ========================================
 * ■ ナビゲーション系
 * ========================================
 * .yururi-page-nav         - ページ内ナビゲーション
 * 
 * ========================================
 * ■ リスト系
 * ========================================
 * .yururi-tag-list         - タグ風リスト（横並び）
 * .yururi-check-list       - チェックマーク付きリスト
 * .yururi-note-list        - 注意書きリスト（※マーク）
 * 
 * ========================================
 * ■ アイコン系
 * ========================================
 * .yururi-icon-grid        - アイコングリッド
 * .yururi-icon-circle      - 丸アイコン
 * 
 * ========================================
 * ■ ボックス系
 * ========================================
 * .yururi-info-box         - インフォボックス
 * .yururi-time-box         - 時間表示ボックス
 * .yururi-badge            - バッジ
 * 
 * ========================================
 * ■ ボタン系
 * ========================================
 * .yururi-btn-primary      - プライマリボタン
 * .yururi-btn-outline      - アウトラインボタン
 * .yururi-cta              - CTAエリア
 * 
 * ========================================
 * ■ テキスト系
 * ========================================
 * .yururi-text-center      - 中央寄せ
 * .yururi-text-serif       - 明朝体
 * .yururi-text-small       - 小さいテキスト
 * .yururi-text-muted       - 薄いテキスト
 */

/* ========================================
   WordPressブロックエディター デフォルト余白リセット
   ======================================== */
.entry-content figure,
.entry-content .wp-block-image,
.entry-content .wp-block-image figure {
  margin: 0 !important;
  padding: 0 !important;
}

.entry-content figure.aligncenter,
.entry-content figure.alignleft,
.entry-content figure.alignright {
  margin: 0 !important;
}

.entry-content .wp-block-columns {
  margin-bottom: 0 !important;
}

.entry-content .wp-block-column {
  margin-bottom: 0 !important;
}

.entry-content .wp-block-group__inner-container > *:last-child {
  margin-bottom: 0 !important;
}

/* is-layout-constrained のデフォルト余白を削除 */
.entry-content .is-layout-constrained > * {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.entry-content .is-layout-constrained > * + * {
  margin-top: 1rem !important;
}

/* wp-block-image のデフォルト余白削除 */
.entry-content .wp-block-image {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.entry-content .wp-block-image img {
  display: block;
}

/* ========================================
   セクション系
   ======================================== */
.yururi-section {
  padding: 3rem 0;
  scroll-margin-top: 100px;
}

.yururi-section-border {
  padding: 3rem 0;
  border-bottom: 1px solid #E8E4E0;
  scroll-margin-top: 100px;
}

.yururi-section-bg {
  padding: 3rem 1.5rem;
  background: var(--washi);
  border-radius: 1rem;
  margin-bottom: 2rem;
}

/* ========================================
   ヘッダー・タイトル系
   ======================================== */
.yururi-section-header {
  text-align: center;
  margin-bottom: 2rem;
}

.yururi-label,
.entry-content .yururi-label {
  display: inline-block;
  font-size: 0.75rem !important;
  letter-spacing: 0.15em;
  color: var(--matcha);
  margin-bottom: 0.5rem;
  font-weight: 400;
}

.yururi-title,
.entry-content .yururi-title {
  font-family: 'Noto Serif JP', serif;
  font-size: 1.5rem !important;
  font-weight: 400 !important;
  color: var(--sumi);
  margin-bottom: 0.5rem;
}

.yururi-title-large,
.entry-content .yururi-title-large {
  font-family: 'Noto Serif JP', serif;
  font-size: 1.75rem !important;
  font-weight: 400 !important;
  color: var(--sumi);
  margin-bottom: 0.75rem;
}

.yururi-lead,
.entry-content .yururi-lead {
  font-size: 0.9rem !important;
  color: var(--text-secondary);
  line-height: 1.8;
}

/* ========================================
   レイアウト系
   ======================================== */
.yururi-container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.yururi-container-narrow {
  max-width: 700px;
  margin: 0 auto;
}

/* グリッドレイアウト */
.yururi-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.yururi-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.yururi-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

@media (max-width: 768px) {
  .yururi-grid-2,
  .yururi-grid-3 {
    grid-template-columns: 1fr;
  }
  
  .yururi-grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ギャラリーレイアウト */
.yururi-gallery {
  display: grid;
  gap: 1rem;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .yururi-gallery {
    grid-template-columns: 2fr 1fr;
  }
}

/* ========================================
   お部屋画像ギャラリー（メイン1枚 + サブ2枚横並び）
   使い方：グループに「yururi-room-gallery」クラスを追加
   ======================================== */
.yururi-room-gallery {
  margin-bottom: 2rem;
}

/* メイン画像（1枚目） */
.yururi-room-gallery > .wp-block-image:first-child,
.yururi-room-gallery > figure:first-child {
  margin-bottom: 0.75rem !important;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.yururi-room-gallery > .wp-block-image:first-child img,
.yururi-room-gallery > figure:first-child img {
  width: 100%;
  height: auto;
  aspect-ratio: 16/10;
  object-fit: cover;
}

/* サブ画像コンテナ（2枚目以降を横並び） */
.yururi-room-gallery > .wp-block-image:not(:first-child),
.yururi-room-gallery > figure:not(:first-child) {
  display: inline-block;
  width: calc(50% - 0.375rem);
  margin: 0 !important;
  vertical-align: top;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.yururi-room-gallery > .wp-block-image:nth-child(2),
.yururi-room-gallery > figure:nth-child(2) {
  margin-right: 0.75rem !important;
}

.yururi-room-gallery > .wp-block-image:not(:first-child) img,
.yururi-room-gallery > figure:not(:first-child) img {
  width: 100%;
  height: auto;
  aspect-ratio: 4/3;
  object-fit: cover;
}

.yururi-gallery-main,
.entry-content .yururi-gallery-main,
.wp-block-column.yururi-gallery-main {
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

.yururi-gallery-main figure,
.yururi-gallery-main .wp-block-image,
figure.yururi-gallery-main,
.wp-block-column.yururi-gallery-main figure {
  margin: 0 !important;
  padding: 0 !important;
  height: 100%;
}

.yururi-gallery-main img,
figure.yururi-gallery-main img,
.wp-block-column.yururi-gallery-main img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
}

.yururi-gallery-sub {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 1rem;
}

/* 右側カラム（サブ画像2枚が入るカラム）のスタイル */
.wp-block-columns:has(.yururi-gallery-main) > .wp-block-column:not(.yururi-gallery-main) {
  display: flex !important;
  flex-direction: column !important;
  gap: 1rem !important;
}

.wp-block-columns:has(.yururi-gallery-main) > .wp-block-column:not(.yururi-gallery-main) > figure {
  flex: 1 !important;
  margin: 0 !important;
  min-height: 0 !important;
}

.yururi-gallery-sub-item,
.entry-content .yururi-gallery-sub-item,
figure.yururi-gallery-sub-item {
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  margin: 0 !important;
  padding: 0 !important;
}

.yururi-gallery-sub-item figure,
.yururi-gallery-sub-item .wp-block-image {
  margin: 0 !important;
  padding: 0 !important;
  height: 100%;
}

.yururi-gallery-sub-item img,
figure.yururi-gallery-sub-item img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
}

/* ========================================
   共用スペース等の単体画像
   ======================================== */
.yururi-image-rounded,
.wp-block-image.yururi-image-rounded,
div.wp-block-image.yururi-image-rounded {
  margin: 0 !important;
  padding: 0 !important;
}

.yururi-image-rounded figure,
.wp-block-image.yururi-image-rounded figure,
.yururi-image-rounded figure.aligncenter {
  margin: 0 !important;
  padding: 0 !important;
  max-width: 100% !important;
}

.yururi-image-rounded img,
.wp-block-image.yururi-image-rounded img {
  width: 100% !important;
  height: auto !important;
  border-radius: 1rem;
  display: block;
  margin: 0 !important;
}

.yururi-image-shadow,
.wp-block-image.yururi-image-shadow {
  box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

/* ========================================
   カード系
   ======================================== */
.yururi-card,
.entry-content .yururi-card {
  background: white;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
  transition: transform 0.3s, box-shadow 0.3s;
}

.yururi-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.1);
}

.yururi-card-featured,
.entry-content .yururi-card-featured {
  border: 2px solid var(--sakura);
}

.yururi-card-image {
  aspect-ratio: 4/3;
  overflow: hidden;
}

.yururi-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.yururi-card-content {
  padding: 1.25rem;
}

.yururi-card-content h3 {
  font-family: 'Noto Serif JP', serif;
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--sumi);
  margin-bottom: 0.5rem;
}

.yururi-card-content p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ========================================
   ナビゲーション系
   ======================================== */
.yururi-page-nav,
.entry-content .yururi-page-nav {
  margin-bottom: 3rem;
  padding: 1rem;
  background: var(--washi);
  border-radius: 0.75rem;
  overflow-x: auto;
}

.yururi-page-nav ul {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  min-width: max-content;
}

.yururi-page-nav li {
  margin: 0 !important;
  padding: 0 !important;
}

.yururi-page-nav li::before {
  display: none !important;
}

.yururi-page-nav a {
  display: block;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 50px;
  transition: all 0.3s;
  white-space: nowrap;
}

.yururi-page-nav a:hover {
  background: white;
  color: var(--sumi);
}

/* ========================================
   リスト系
   ======================================== */
.yururi-tag-list,
.entry-content .yururi-tag-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.yururi-tag-list li {
  background: var(--washi);
  padding: 0.5rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin: 0 !important;
}

.yururi-tag-list li::before {
  display: none !important;
}

.yururi-check-list,
.entry-content .yururi-check-list {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.yururi-check-list li {
  padding: 0.4rem 0 !important;
  padding-left: 1.5rem !important;
  position: relative;
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 0 !important;
}

.yururi-check-list li::before {
  content: '✓' !important;
  position: absolute;
  left: 0;
  color: var(--matcha);
  font-size: 0.85rem;
  background: none !important;
  width: auto !important;
  height: auto !important;
  border-radius: 0 !important;
}

.yururi-note-list,
.entry-content .yururi-note-list {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.yururi-note-list li {
  padding: 0.6rem 0 !important;
  padding-left: 1.5rem !important;
  position: relative;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  margin: 0 !important;
}

.yururi-note-list li:last-child {
  border-bottom: none;
}

.yururi-note-list li::before {
  content: '※' !important;
  position: absolute;
  left: 0;
  color: var(--sakura-deep);
  background: none !important;
  width: auto !important;
  height: auto !important;
  border-radius: 0 !important;
}

/* ========================================
   アイコン系
   ======================================== */
.yururi-icon-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  max-width: 700px;
  margin: 0 auto;
}

@media (max-width: 640px) {
  .yururi-icon-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.yururi-icon-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem;
  text-align: center;
}

.yururi-icon-circle {
  width: 56px;
  height: 56px;
  background: var(--washi);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  margin: 0 auto 0.5rem;
}

.yururi-icon-circle svg {
  stroke: var(--matcha);
}

.yururi-icon-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* ========================================
   ボックス系
   ======================================== */
.yururi-info-box,
.entry-content .yururi-info-box {
  background: var(--washi);
  padding: 2rem;
  border-radius: 1rem;
}

.yururi-time-box {
  text-align: center;
  padding: 1.25rem;
  background: white;
  border-radius: 0.75rem;
}

.yururi-time-box h3,
.yururi-time-box .yururi-time-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  font-weight: 400;
}

.yururi-time-value {
  font-family: 'Noto Serif JP', serif;
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--sumi);
}

.yururi-badge,
.entry-content .yururi-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: var(--sakura);
  border-radius: 50px;
  font-size: 0.7rem;
  color: var(--tsugaru-blue);
  margin-bottom: 0.5rem;
}

/* メタ情報 */
.yururi-meta {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.yururi-meta-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.yururi-meta-item svg {
  stroke: var(--matcha);
}

/* ========================================
   ボタン系
   ======================================== */
/* プライマリボタン */
.wp-block-button.yururi-btn-primary {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
}

.wp-block-button.yururi-btn-primary .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, var(--sakura), var(--sakura-deep)) !important;
  border: none !important;
  border-radius: 50px !important;
  font-size: 0.9rem;
  color: var(--sumi) !important;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s;
}

.wp-block-button.yururi-btn-primary .wp-block-button__link:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 15px rgba(212,165,165,0.4);
}

/* アウトラインボタン */
.wp-block-button.yururi-btn-outline {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
}

.wp-block-button.yururi-btn-outline .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  background: transparent !important;
  border: 1px solid #ccc !important;
  border-radius: 50px !important;
  font-size: 0.9rem;
  color: var(--text-secondary) !important;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s;
}

.wp-block-button.yururi-btn-outline .wp-block-button__link:hover {
  border-color: var(--sumi) !important;
  color: var(--sumi) !important;
}

.yururi-cta,
.entry-content .yururi-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-top: 3rem;
  padding-top: 3rem;
  border-top: 1px solid #E8E4E0;
}

/* CTAエリア内のボタン余白をリセット */
.yururi-cta .wp-block-button {
  margin: 0 !important;
}

@media (min-width: 480px) {
  .yururi-cta {
    flex-direction: row;
    justify-content: center;
  }
}

/* ========================================
   テキスト系
   ======================================== */
.yururi-text-center {
  text-align: center;
}

.yururi-text-serif {
  font-family: 'Noto Serif JP', serif;
}

.yururi-text-small {
  font-size: 0.85rem;
}

.yururi-text-muted {
  color: var(--text-muted);
}

.yururi-description {
  max-width: 700px;
  margin: 0 auto 2rem;
  text-align: center;
  color: var(--text-secondary);
  line-height: 1.9;
}

/* ========================================
   カテゴリボックス（アメニティ用）
   ======================================== */
.yururi-category-box,
.entry-content .yururi-category-box {
  background: var(--washi);
  padding: 1.5rem;
  border-radius: 1rem;
}

.yururi-category-box h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'Noto Serif JP', serif;
  font-size: 1rem;
  font-weight: 500;
  color: var(--sumi);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(0,0,0,0.1);
}

/* ========================================
   画像スタイル
   ======================================== */
.yururi-image-rounded,
.entry-content .yururi-image-rounded img {
  border-radius: 1rem;
  overflow: hidden;
}

.yururi-image-shadow,
.entry-content .yururi-image-shadow img {
  box-shadow: 0 10px 40px rgba(0,0,0,0.1);
}

/* ========================================
   特殊スタイル
   ======================================== */

/* ルームヘッダー */
.yururi-room-header {
  text-align: center;
  margin-bottom: 2rem;
}

/* 区切り線 */
.yururi-divider {
  border: none;
  border-top: 1px solid #E8E4E0;
  margin: 3rem 0;
}

/* スペーサー */
.yururi-spacer-sm { height: 1rem; }
.yururi-spacer-md { height: 2rem; }
.yururi-spacer-lg { height: 3rem; }
