/* 全ページ共通スタイル（元HTML各ページの <style> の共通部分。値は同一、色は tokens.css の変数参照） */
body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: "Hiragino Kaku Gothic ProN", "Noto Sans JP", Meiryo, "Inter", sans-serif;
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* 日本語を文字単位で詰めず、語句の区切りで改行する。
     未対応ブラウザは keep-all。はみ出す語だけ break-word で折る。 */
  word-break: keep-all;
  overflow-wrap: break-word;
  word-break: auto-phrase;
}

/* 見出しは記号（｜・）や語句の区切りで改行し、店名や語の末尾1文字だけを落とさない */
h1, h2, h3 {
  word-break: auto-phrase;
  line-break: strict;
  overflow-wrap: break-word;
}

/* 狭い画面の表。語句単位の改行のまま幅を伸ばすと、角丸の overflow:hidden で右端が隠れる。
   列幅は既存の w-1/4 などを維持し、セル内で折り返す。 */
@media (max-width: 767px) {
  table {
    table-layout: fixed;
    width: 100%;
  }
  th, td {
    word-break: break-word;
    overflow-wrap: anywhere;
  }
}

/* （旧 .ocean-subtle-grid ドット背景は廃止。クラス名のみ互換のため残す） */
.ocean-subtle-grid {
  background-image: none;
}

/* 主要CTA：丸ピル（高さ44px以上） */
.btn-pill {
  border-radius: var(--radius-btn);
  min-height: 44px;
}

/* 発送目安などの黄色タグ */
.tag-lead {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  background: var(--color-tag);
  color: var(--color-text);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
  border-radius: 2px;
}

/* カテゴリ丸タグ（ヘッダー下・トップ） */
.cat-pill {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  min-height: 36px;
  padding: 6px 16px;
  border-radius: 9999px;
  background: #EFF3F4;
  color: var(--color-text);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  transition: background-color 150ms, color 150ms;
}
.cat-pill:hover {
  background: var(--color-teal-light);
  color: var(--color-navy);
}
.cat-pill[aria-current="true"] {
  background: var(--color-navy);
  color: #fff;
}

/* 横スクロールのタグ行：スクロールバーは隠す */
.scroll-x {
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.scroll-x::-webkit-scrollbar { display: none; }


.ui-transition {
  transition: all 200ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

:focus-visible {
  outline: 2px solid var(--color-teal);
  outline-offset: 2px;
}

/* 場面写真。比率は枠で固定し、中の画像だけ object-fit で差し替えられる */
.scene-frame {
  position: relative;
  overflow: hidden;
  margin: 0;
  border-radius: var(--radius-card);
  border: 1px solid var(--color-border);
  background: #e7eef0;
}

.scene-frame--flush {
  border: 0;
  border-radius: 0;
}

.scene-frame--16x9 { aspect-ratio: 16 / 9; }
.scene-frame--4x3 { aspect-ratio: 4 / 3; }
.scene-frame--4x5 { aspect-ratio: 4 / 5; }
.scene-frame--3x4 { aspect-ratio: 3 / 4; }
.scene-frame--1x1 { aspect-ratio: 1 / 1; }
.scene-frame--21x9 { aspect-ratio: 21 / 9; }

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

.scene-img--center { object-position: center; }
.scene-img--left { object-position: 18% center; }
.scene-img--right { object-position: right center; }
.scene-img--low { object-position: center 78%; }

.scene-note {
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--color-subtext);
}

.scene-footer {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.scene-footer .scene-frame {
  border: 0;
  border-radius: 0;
  aspect-ratio: 16 / 8;
  max-height: 168px;
}

.scene-footer-note {
  margin: 0;
  padding: 8px 16px 0;
  background: var(--color-navy);
  color: rgba(255, 255, 255, 0.72);
  font-size: 11px;
  line-height: 1.5;
  text-align: center;
}

@media (min-width: 768px) {
  .scene-footer {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
