:root {
  /* --- Theme tokens (editor) ---
     フロント側の変数を editor iframe 内でも使えるように定義
  */
  --green: #006240;
  --yellow: #ffad3c;
  --orange: #d96028;
  --blue: #05438b;
  --t-black: #292d38;
  --text: #212121;

  --color-border: #ddd;
  --color-surface: #fff;
  --color-surface-2: #f5f5f5;
  --color-danger: #d60000;
  --color-muted: #666;
}

/**
 * Block Editor Style (for News / Content pages)
 * クライアントが書く記事を、フロントの見た目に近づけるための最低限スタイル
 * ※ レイアウトや色はフロント側SCSSが正とする
 */

.editor-styles-wrapper {
  font-family: inherit;
  line-height: 1.8;
  color: var(--text);
}

/* Link（編集画面内のリンクが見やすいように） */
.editor-styles-wrapper a {
  color: var(--blue);
  text-decoration: underline;
}

.editor-styles-wrapper a:hover {
  opacity: 0.85;
}

/* Button（パターン内の店舗URLボタン等） */
.editor-styles-wrapper .wp-block-button__link {
  background: var(--orange);
  color: var(--color-surface);
  border-radius: 999px;
  padding: 0.65em 1.1em;
}

.editor-styles-wrapper .wp-block-button__link:hover {
  opacity: 0.9;
}

/* =========================
   Headings
   ========================= */

.editor-styles-wrapper h2 {
  margin: 2.6em 0 1em;
  font-size: 1.5rem;
  line-height: 1.6;
  font-weight: 700;
}

.editor-styles-wrapper h3 {
  margin: 2.2em 0 0.9em;
  font-size: 1.3rem;
  line-height: 1.6;
  font-weight: 700;
}

.editor-styles-wrapper h4 {
  margin: 1.8em 0 0.8em;
  font-size: 1.1rem;
  line-height: 1.7;
  font-weight: 700;
}

.editor-styles-wrapper h5 {
  margin: 1.5em 0 0.7em;
  font-size: 1rem;
  line-height: 1.7;
  font-weight: 700;
}

/* =========================
   Text / Paragraph
   ========================= */

.editor-styles-wrapper p {
  margin: 0 0 1.4em;
}

/* =========================
   List
   ========================= */

.editor-styles-wrapper ul,
.editor-styles-wrapper ol {
  margin: 0 0 1.6em 1.5em;
}

.editor-styles-wrapper li {
  margin: 0.4em 0;
}

/* =========================
   Image
   ========================= */

.editor-styles-wrapper figure {
  margin: 2em 0;
}

.editor-styles-wrapper figcaption {
  margin-top: 0.5em;
  font-size: 0.85rem;
  color: var(--color-muted);
}

/* =========================
   Table
   ========================= */

.editor-styles-wrapper table {
  width: 100%;
  border-collapse: collapse;
  margin: 2em 0;
}

.editor-styles-wrapper th,
.editor-styles-wrapper td {
  padding: 0.8em;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
}

/* 営業時間テーブル：行ボーダーを1pxに統一 */
.editor-styles-wrapper table.time-table td {
  border-width: 1px;
}

.editor-styles-wrapper th {
  background: rgba(255, 173, 60, 0.12); /* default: soft yellow */
  font-weight: 700;
}


/* =========================
   News utility (patterns)
   ========================= */

/* 重要帯（黄色） */
.editor-styles-wrapper .news-highlight {
  background: rgba(255, 173, 60, 0.25);
  border-left: 6px solid var(--orange);
  padding: 18px 18px;
  font-weight: 700;
  margin: 1.8em 0;
}

.editor-styles-wrapper .news-highlight p {
  margin: 0;
}

/* 営業時間テーブル（お知らせ用） */
.editor-styles-wrapper table.time-table {
  margin: 1.5em 0;
  border: 1px solid var(--color-border);
}

.editor-styles-wrapper table.time-table thead {
  background-color: var(--orange);
}

.editor-styles-wrapper table.time-table thead th {
  background: rgba(217, 96, 40, 0.92);
  color: var(--color-surface);
  border-color: rgba(217, 96, 40, 0.92);
  text-align: center;
}

.editor-styles-wrapper table.time-table th,
.editor-styles-wrapper table.time-table td {
  text-align: center;
}

/* 曜日（thead）＝背景オレンジ／文字白／ボーダーもオレンジ寄せ */
.editor-styles-wrapper table.time-table thead th {
  background: var(--orange);
  color: var(--color-surface);
  border-color: var(--orange);
}

/* ボーダーは1pxで統一（ユーザー要望） */
.editor-styles-wrapper table.time-table th,
.editor-styles-wrapper table.time-table td {
  border-width: 1px;
}

/* 先頭列（営業時間）を読みやすく */
.editor-styles-wrapper table.time-table th:first-child,
.editor-styles-wrapper table.time-table td:first-child {
  text-align: left;
  white-space: nowrap;
  background: var(--orange);
  color: var(--color-surface);
  font-weight: 700;
}

.editor-styles-wrapper table.time-table tbody tr:nth-child(even) td {
  background: rgba(255, 173, 60, 0.05);
}

/* 店舗情報テーブル（新規開局用） */
.editor-styles-wrapper table.store-info-table {
  border: 1px solid var(--orange);
}

.editor-styles-wrapper table.store-info-table th {
  width: 7em;
  background: var(--orange);
  color: var(--color-surface);
  font-weight: 800;
  white-space: nowrap;
  border-color: var(--orange);
}

.editor-styles-wrapper table.store-info-table td {
  background: var(--orange);
  color: var(--color-surface);
  font-weight: 700;
  border-color: var(--orange);
}

/* 営業時間変更：赤字表現（エディタ用の簡易表示） */
.editor-styles-wrapper .is-red {
  color: var(--color-danger);
  font-weight: 700;
}

/* 営業時間カレンダー 記号カラー */
.editor-styles-wrapper table.time-table td {
  font-weight: 700;
}

/* 営業時間カレンダー（●/○/休）
   ※CSSだけで文字（●/○/休）を判定して色分けすることはできないため、
     パターン側で <span class="cal cal--open">●</span> のようにクラス付与して運用する。
*/
.editor-styles-wrapper .cal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.6em;
  line-height: 1;
  font-weight: 900;
}

.editor-styles-wrapper .cal--open {
  color: var(--orange);
}

.editor-styles-wrapper .cal--half {
  color: var(--yellow);
}

.editor-styles-wrapper .cal--close {
  color: var(--color-danger);
}

.wp-block-table thead {
  border-bottom: 1px solid var(--green);
}