/* ============================================================
   小青田產後護理之家 — 字型搭配（兩套字型）
   英數 (en) : Cactus Classical Serif  ← 自架，只取拉丁分片
   中文 (zh) : Noto Serif HK
   日文 (ja) : Cactus Classical Serif（完整版，含假名與漢字）

   為什麼只取拉丁分片：
   Cactus Classical Serif 本身也含中日漢字，若整套掛上去，
   中文會被它接手並顯示為 Classical 舊字形（青→靑、為→爲、真→眞），
   品牌名「小青田」會變成「小靑田」。
   因此這裡只自架它的 latin / latin-ext 兩個分片（約 33 KB），
   並改名為 CactusLatin，讓漢字自然回退給 Noto Serif HK。
   ============================================================ */

/* ---------- Cactus Classical Serif：拉丁分片（自架） ---------- */
@font-face {
  font-family: 'CactusLatin';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/cactus-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'CactusLatin';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/cactus-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
                 U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF,
                 U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root{
  /* 中文站：英數走 CactusLatin，漢字與全形標點回退 Noto Serif HK */
  --cyan-font: "CactusLatin", "Noto Serif HK", system-ui, -apple-system,
               "PingFang TC", "Microsoft JhengHei", sans-serif;
}

/* 日文區塊（任何 lang="ja" 元素）：完整 Cactus 接手假名與漢字。
   CSS 自訂變數會向下繼承，子孫元素無需個別指定。
   完整字型只在 /ja/ 頁面由 functions.php 載入。 */
:lang(ja){
  --cyan-font: "CactusLatin", "Cactus Classical Serif", "Noto Serif HK", serif;
}

/* 套用到主要文字元素（刻意避開 icon／SVG 元素） */
html body,
h1, h2, h3, h4, h5, h6,
p, li, dt, dd, blockquote, figcaption, cite,
a, label, button, input, select, optgroup, textarea,
.wp-block-button__link,
.entry-title, .entry-content, .post-title,
.site-title, .ct-headline,
.ct-menu-link, .menu-item, .ct-breadcrumbs, .ct-meta-element{
  font-family: var(--cyan-font) !important;
}

/* 同步餵給 Blocksy 主題自身的字型變數，覆蓋更完整 */
:root{
  --theme-font-family: var(--cyan-font);
  --theme-button-font-family: var(--cyan-font);
  --theme-headings-font-family: var(--cyan-font);
}
