/* ==========================================================================
   よるうら — 夜空とネオンの間
   docs/DESIGN.md v2.3「夜の明朝」+ v2.2 リファレンス整合 のトークンを唯一の情報源とする。

   - ダークベース（--yozora）。グラデは夜空の同系縦グラデのみ
   - 見出し・言い切り・訳語は Zen Old Mincho（400/500/600。太字禁止＝600まで）
     大きく・細く・余白で孤立。letter-spacing .08〜.1em
   - UI小物（ボタン・タグ・ナビ）は Zen Kaku Gothic New 500、
     letter-spacing .16〜.22em、角丸2pxの細枠（ピル型はやめる）
   - 逆転階層: 小さな日本語ラベル（.kicker）→ 大きな見出し → 本文
   - 余白スケール: セクション間 padding-block 6rem（SP）/ 10rem（PC）。
     見出し前は見出し後の2倍。言い切りブロックの上下は最低4rem
   - 色の配給制: 1セクション lavender＋もう1色まで。gold は1セクション1箇所
   - 常時モーションは1画面1つ。優先順位: FV動画 > 玉ボケ明滅 > ラメtwinkle(静止)。
     ティッカーは opacity .55 の細字で静音化。CTAシアーは hover 時のみ。
     金の泡は診断結果ページ限定
   - ゴールドは月・点数・強調に限定。面で使わない。小さい文字に使わない
   - 玉ボケはヒーローと診断結果のみ。実写区画は写真＋オーバーレイ＋文字だけ
   - カードは角丸 12〜16px / 地 --yozora-deep / 枠 1px lavender 20%。
     カード表面は訳語＋点数まで（原語は2行目以降）
   - hover は色・下線変化のみ（浮き上がり禁止）
   - スマホ縦（375px）ファースト。メディアクエリはモバイルファースト
   ========================================================================== */

:root {
  /* カラートークン（DESIGN.md v2） */
  --yozora: #0D1030;       /* ベース。夜空 */
  --yozora-deep: #080A20;  /* さらに深い面（フッター・カード内背景） */
  --lavender: #B8A0E8;     /* メインアクセント。見出し・リンク・UI */
  --mauve: #E8A0C8;        /* メイン第2。強調・タグ・グラフ */
  --gold: #E8D5A0;         /* シャンパンゴールド。月・点数・強調に限定 */
  --moji: #F2F0F7;         /* 本文文字 */
  --moji-dim: #9A94B8;     /* 補足・日付・キャプション */

  --line: rgba(184, 160, 232, 0.2);        /* カード枠 1px lavender 20% */
  --line-strong: rgba(184, 160, 232, 0.4); /* 宿曜盤の線 lavender 40% */
  --card-bg: var(--yozora-deep);

  /* タイポグラフィ（v2.3 夜の明朝） */
  --font-disp: "Zen Old Mincho", "Hiragino Mincho ProN", "Yu Mincho", serif; /* 見出し・言い切り・訳語。太字禁止（600まで） */
  --font-body: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", sans-serif; /* 本文 */
  --font-ui: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", sans-serif; /* UI小物（500・広字間・細枠） */
  --font-num: "Prata", "Times New Roman", serif; /* 点数の数字のみ（細セリフ） */

  /* レイアウト */
  --w-article: 680px;
  --w-list: 960px;
  --radius: 14px;
  --radius-s: 12px;
  --radius-ui: 2px;      /* UI小物の角丸（ピル型は廃止） */
  --radius-pill: 999px;  /* LINEトーク風UI（.ui-talk）の再現専用。UI小物には使わない */
}

/* --------------------------------------------------------------------------
   リセット + ベース
   -------------------------------------------------------------------------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  /* 夜空の縦グラデ（同系のみ可） */
  background: linear-gradient(180deg, var(--yozora) 0%, var(--yozora-deep) 100%) fixed var(--yozora);
  color: var(--moji);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.9;
  color-scheme: dark;
}

img,
video,
svg {
  max-width: 100%;
  height: auto;
}

h1, h2, h3, h4 {
  font-family: var(--font-disp);
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.6;
  word-break: keep-all;
  overflow-wrap: anywhere;
  margin: 0;
}

p {
  margin: 0 0 1.2em;
}

a {
  color: var(--lavender);
  text-decoration: underline;
  text-decoration-color: rgba(184, 160, 232, 0.45);
  text-underline-offset: 0.22em;
  transition: color 0.15s ease, text-decoration-color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}

a:hover {
  color: var(--mauve);
  text-decoration-color: currentColor;
}

:focus-visible {
  outline: 2px solid var(--lavender);
  outline-offset: 2px;
  border-radius: 2px;
}

::selection {
  background: rgba(184, 160, 232, 0.35);
}

.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 8px;
  top: -48px;
  z-index: 100;
  padding: 8px 16px;
  background: var(--yozora-deep);
  border: 1px solid var(--line);
  border-radius: var(--radius-ui);
  color: var(--moji);
}

.skip-link:focus {
  top: 8px;
}

.container {
  width: min(100% - 40px, var(--w-list));
  margin-inline: auto;
}

.container--article {
  width: min(100% - 40px, var(--w-article));
}

/* --------------------------------------------------------------------------
   ボタン（hover は色変化のみ）
   -------------------------------------------------------------------------- */

.btn {
  display: inline-block;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.22em;
  line-height: 1;
  padding: 15px 34px 15px calc(34px + 0.22em); /* 字間ぶんの右余りを打ち消して光学中央に */
  border-radius: var(--radius-ui);
  background: var(--lavender);
  color: var(--yozora-deep);
  border: 1px solid var(--lavender);
  text-decoration: none;
  cursor: pointer;
}

.btn:hover {
  background: var(--mauve);
  border-color: var(--mauve);
  color: var(--yozora-deep);
}

.btn--ghost {
  background: transparent;
  color: var(--lavender);
}

.btn--ghost:hover {
  background: transparent;
  color: var(--mauve);
}

/* --------------------------------------------------------------------------
   ヘッダー
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(13, 16, 48, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.site-header__inner {
  width: min(100% - 32px, var(--w-list));
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 0 0;
}

.site-brand {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: 22px;
  letter-spacing: 0.1em;
  color: var(--moji);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
}

.site-brand:hover {
  color: var(--lavender);
}

/* 三日月（CSSシェイプ。絵文字は UI 装飾に使わない） */
.brand-moon {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--gold);
  -webkit-mask-image: radial-gradient(circle at 68% 32%, transparent 54%, #000 56%);
  mask-image: radial-gradient(circle at 68% 32%, transparent 54%, #000 56%);
  flex: none;
}

.site-brand__sub {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 10px;
  letter-spacing: 0.16em;
  color: var(--moji-dim);
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 6px 0 10px;
  display: flex;
  gap: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.site-nav ul::-webkit-scrollbar {
  display: none;
}

.site-nav a {
  display: inline-block;
  white-space: nowrap;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--moji-dim);
  text-decoration: none;
  padding: 6px 12px;
  border-radius: var(--radius-ui);
}

.site-nav a:hover {
  color: var(--moji);
}

.site-nav a[aria-current="page"] {
  color: var(--lavender);
  border-bottom: 1px solid var(--lavender);
}

@media (min-width: 720px) {
  .site-header__inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 0;
  }

  .site-brand {
    padding: 14px 0;
  }

  .site-nav ul {
    padding: 0;
  }

  .site-nav a {
    font-size: 13px;
    padding: 8px 14px;
  }
}

/* --------------------------------------------------------------------------
   玉ボケ（ヒーローと診断結果のみ）
   -------------------------------------------------------------------------- */

.bokeh {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.bokeh__dot {
  position: absolute;
  border-radius: 50%;
  filter: blur(26px);
  opacity: 0.5;
  animation: bokeh-pulse 9s ease-in-out infinite alternate;
}

.bokeh__dot--1 { width: 130px; height: 130px; left: -30px;  top: 12%;  background: rgba(184, 160, 232, 0.5); }
.bokeh__dot--2 { width: 90px;  height: 90px;  right: 6%;    top: 6%;   background: rgba(232, 160, 200, 0.45); animation-delay: -2s; }
.bokeh__dot--3 { width: 60px;  height: 60px;  right: 22%;   top: 42%;  background: rgba(184, 160, 232, 0.4);  animation-delay: -4s; }
.bokeh__dot--4 { width: 150px; height: 150px; left: 14%;    bottom: -40px; background: rgba(232, 160, 200, 0.32); animation-delay: -6s; }
.bokeh__dot--5 { width: 44px;  height: 44px;  left: 42%;    top: 20%;  background: rgba(232, 213, 160, 0.3);  animation-delay: -3s; }
.bokeh__dot--6 { width: 80px;  height: 80px;  right: -20px; bottom: 16%; background: rgba(184, 160, 232, 0.38); animation-delay: -7s; }

/* 月（ゴールドは月・点数に限定） */
.bokeh__moon {
  position: absolute;
  right: 12%;
  top: 14%;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--gold);
  -webkit-mask-image: radial-gradient(circle at 66% 34%, transparent 55%, #000 57%);
  mask-image: radial-gradient(circle at 66% 34%, transparent 55%, #000 57%);
  opacity: 0.9;
  filter: drop-shadow(0 0 18px rgba(232, 213, 160, 0.35));
}

@keyframes bokeh-pulse {
  from { opacity: 0.32; transform: translateY(0); }
  to   { opacity: 0.62; transform: translateY(-10px); }
}

@media (prefers-reduced-motion: reduce) {
  .bokeh__dot {
    animation: none;
  }
}

/* --------------------------------------------------------------------------
   FV（フロントページ）— 動画ヒーロー + 静的フォールバック
   -------------------------------------------------------------------------- */

.fv {
  position: relative;
  min-height: 82vh;
  min-height: 82svh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.fv__video,
.fv__sky {
  position: absolute;
  inset: 0;
}

.fv__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 動画の上下に文字が乗るための減光（DESIGN.md: CTA用の余白確保） */
/* 動画を殺さない減光: 上下だけ濃く、中央は素通し。
   文字コントラストは下側グラデ（.84）で担保する */
.fv__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13, 16, 48, 0.5) 0%, rgba(13, 16, 48, 0.08) 42%, rgba(13, 16, 48, 0.84) 100%);
  pointer-events: none;
}

/* 言い切りブロック（v2.2 #1）: 小ラベル → 明朝の言い切り1文 → 導入行 → CTA1個+テキストリンク1個。
   viewport 内はこれだけ。上下余白は最低4rem */
.fv__copy {
  position: relative;
  z-index: 1;
  width: min(100% - 40px, var(--w-list));
  margin-inline: auto;
  padding: 7rem 0 4rem;
}

/* 逆転階層の小ラベル（日本語のまま。英語モノスペース復活は禁止） */
.fv__label {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  color: var(--moji-dim);
  margin: 0 0 1.4rem;
}

/* 言い切り（1画面1文。明朝400・大きく・細く。375pxで最大2行） */
.fv__title {
  font-family: var(--font-disp);
  font-weight: 400;
  font-size: clamp(1.9rem, 7vw, 3.5rem);
  letter-spacing: 0.08em;
  line-height: 1.5;
  color: var(--moji);
  margin-bottom: 1.2rem;
}

/* ベネフィット行（本文ゴシック。言い切りの直下に1行） */
.fv__benefit {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: clamp(13px, 3.8vw, 15px);
  letter-spacing: 0.04em;
  color: var(--moji);
  max-width: 32em;
  margin: 0 0 2rem;
}

/* BudouX 適用先（h1〜h3 以外の行。wbr + keep-all で不自然な改行を防ぐ）
   対象セレクタの一覧は assets/js/budoux-apply.js の SELECTORS と対で管理する */
.js-budoux,
[data-budoux],
.section__lead,
.archive-header__desc,
.shindan__lead,
.cta-panel p,
.article-body p,
.article-body li,
.article-body dd,
.article-body blockquote,
.card__excerpt,
.card__lead {
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.fv__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
}

@media (min-width: 720px) {
  .fv__copy {
    padding: 10rem 0 5.5rem;
  }
}

/* --------------------------------------------------------------------------
   セクション
   -------------------------------------------------------------------------- */

/* 余白スケール（v2.2 #3）: セクション間 6rem（SP）/ 10rem（PC）。
   詰まってきたら要素を減らす。余白を削って収めるのは禁止 */
.section {
  padding-block: 6rem;
}

.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 2rem;
}

/* 逆転階層ラベル（v2.2 #2）: 小さい日本語ラベル → 大きい見出し のジャンプ率で品を出す */
.kicker {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  color: var(--moji-dim);
  margin: 0 0 0.7rem;
}

.section__title {
  font-size: clamp(21px, 4.6vw, 28px);
  color: var(--moji);
}

.section__more {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.16em;
  white-space: nowrap;
}

.section__lead {
  color: var(--moji-dim);
  font-size: 14px;
  margin: -1rem 0 2rem;
}

@media (min-width: 720px) {
  .section {
    padding-block: 10rem;
  }
}

/* --------------------------------------------------------------------------
   カード・リスト
   -------------------------------------------------------------------------- */

.card-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.card {
  display: block;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  text-decoration: none;
  color: var(--moji);
}

.card:hover {
  border-color: var(--lavender);
  color: var(--moji);
}

.card:hover .card__title {
  text-decoration: underline;
  text-decoration-color: var(--lavender);
  text-underline-offset: 0.22em;
}

.card--row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.card__date {
  flex: none;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 12px;
  color: var(--moji-dim);
  min-width: 5.4em;
}

.card__topic {
  color: var(--mauve);
  font-size: 11px;
}

/* カード表面は訳語＋点数まで（v2.2 #8）。見出し系なので明朝 */
.card__title {
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.05em;
  line-height: 1.7;
}

.card__main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.card__meta {
  font-size: 12px;
  color: var(--moji-dim);
}

.card__num {
  margin-left: auto;
  flex: none;
  font-size: 12px;
  color: var(--moji-dim);
}

/* 有名人: 宿の頭文字バッジ */
.card__badge {
  flex: none;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 16px;
  color: var(--lavender);
}

/* 相性: 点数（ゴールドは大きな点数のみ） */
.card__score {
  flex: none;
  min-width: 2.4em;
  font-family: var(--font-num);
  font-weight: 400;
  font-size: 34px;
  line-height: 1;
  color: var(--gold);
  text-align: center;
}

.card__score small {
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--moji-dim);
  margin-left: 2px;
}

/* --------------------------------------------------------------------------
   相性ランキング（フロント）
   -------------------------------------------------------------------------- */

.rank-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.rank-list .card--aishou {
  align-items: center;
}

.rank-list__no {
  flex: none;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--moji-dim);
  width: 1.6em;
}

@media (min-width: 720px) {
  .card-list--2col,
  .rank-list--2col {
    grid-template-columns: 1fr 1fr;
  }
}

/* --------------------------------------------------------------------------
   点数ドンのヒーロー（single-aishou / 診断結果）
   表示順は YAKUGO.md: 点数 → 訳語 → 原語（小さく）
   -------------------------------------------------------------------------- */

.score-hero {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 40px 20px 34px;
}

.score-hero__stack {
  position: relative;
  z-index: 1;
}

/* 逆転階層: ペア名は小さなラベルとして点数の上に置く */
.score-hero__pair {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--moji-dim);
  margin-bottom: 10px;
}

.score-hero__score {
  margin: 0;
  line-height: 1;
}

.score-hero__num {
  font-family: var(--font-num);
  font-weight: 400;
  font-size: clamp(88px, 30vw, 150px);
  letter-spacing: 0.01em;
  color: var(--gold);
}

.score-hero__unit {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 0.1em;
  color: var(--moji-dim);
  margin-left: 6px;
}

/* 訳語（シグネチャ）: Zen Old Mincho 600。太字にしない */
.score-hero__gloss {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: clamp(22px, 6.4vw, 32px);
  letter-spacing: 0.08em;
  line-height: 1.5;
  color: var(--moji);
  margin: 10px 0 0;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

/* 結果表示時に JS がフォーカスを移す（tabindex=-1）。スクショ=シェア素材なので
   プログラム由来のフォーカス輪郭は消す（.unsei-widget__gloss:focus と同じ扱い） */
.score-hero__gloss:focus {
  outline: none;
}

.score-hero__origin {
  font-size: 13px;
  color: var(--moji-dim);
  margin: 6px 0 0;
}

.score-hero__hitokoto {
  font-size: 15px;
  color: var(--moji);
  margin: 18px 0 0;
}

/* --------------------------------------------------------------------------
   記事ヘッダー / 本文
   -------------------------------------------------------------------------- */

.article-header {
  padding: 3.5rem 0 6px;
}

.article-header__title {
  font-size: clamp(24px, 6.4vw, 34px);
  line-height: 1.5;
}

.article-header__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 13px;
  color: var(--moji-dim);
}

/* タグ: 角丸2pxの細枠（ピル型廃止）。mauve はタグ限定の配給（v2.2 #4） */
.pill {
  display: inline-block;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.18em;
  line-height: 1;
  padding: 6px 10px 6px calc(10px + 0.18em);
  border: 1px solid rgba(232, 160, 200, 0.45);
  border-radius: var(--radius-ui);
  color: var(--mauve);
  text-decoration: none;
}

a.pill:hover {
  border-color: var(--mauve);
  color: var(--mauve);
}

/* 記事本文（v2.3 夜の明朝）: Zen Kaku Gothic New 400・17px/1.9・最大幅は
   .container--article（680px）が担保。見出しだけ明朝、本文は砕けたゴシックのまま */
.article-body {
  padding: 18px 0 40px;
  font-size: 17px;
  line-height: 1.9;
}

/* 導入文（点数先出しの言い切り）: 少しだけ大きく。明朝にはしない（言葉まできれいにしない） */
.article-body > p:first-child {
  font-size: 19px;
  line-height: 1.85;
}

/* H2: 章の切れ目。上余白は下の2倍以上（v2.2 余白規律）+
   直前の細い罫（Co-Star「細線は句読点」）で章を区切る */
.article-body h2 {
  font-size: clamp(21px, 5.8vw, 24px);
  margin: 3.2em 0 1em;
}

.article-body h2::before {
  content: "";
  display: block;
  width: 44px;
  height: 1px;
  background: var(--line-strong);
  margin-bottom: 1.6em;
}

.article-body h3 {
  font-size: 18px;
  margin: 2.2em 0 0.7em;
}

.article-body ul,
.article-body ol {
  padding-left: 1.4em;
  margin: 0 0 1.2em;
}

.article-body li {
  margin-bottom: 0.4em;
}

.article-body blockquote {
  margin: 1.4em 0;
  padding: 14px 18px;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  color: var(--moji);
}

.article-body blockquote p:last-child {
  margin-bottom: 0;
}

/* 宿曜データ表（全記事に入る）: 夜空トーン。線は lavender 20% の水平線のみ */
.article-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  margin: 2em 0;
}

.article-body th,
.article-body td {
  padding: 11px 16px 11px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.article-body th {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--moji-dim);
}

/* 行ラベル（tbody 1列目「生年月日」など）も見出し側の扱いにする */
.article-body tbody td:first-child {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--moji-dim);
}

/* スマホは横スクロールでなく縦積み（2〜3列の宿曜データ表を想定した幅設計）。
   行ラベルを上に、値（1〜2列）をその下に並べる */
@media (max-width: 559px) {
  .article-body table,
  .article-body thead,
  .article-body tbody {
    display: block;
  }

  .article-body tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px 18px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
  }

  .article-body th,
  .article-body td {
    display: block;
    padding: 0;
    border: 0;
  }

  .article-body thead tr {
    padding: 0 0 10px;
  }

  /* 「項目」列の見出しは行ラベルが兼ねるので落とす */
  .article-body thead th:first-child {
    display: none;
  }

  .article-body tbody td:first-child {
    grid-column: 1 / -1;
  }

  /* ラベル+値1つの2列テーブルは値を全幅に。見出し行ごと省く */
  .article-body td:nth-child(2):last-child,
  .article-body thead th:nth-child(2):last-child {
    grid-column: 1 / -1;
  }

  .article-body thead tr:has(th:nth-child(2):last-child) {
    display: none;
  }
}

/* よくある質問: marked の実HTML「<p><strong>Q. …</strong> 回答…</p>」を検知して
   Q を明朝ブロック・回答を dim 側に落とす（CSSのみ） */
.article-body p:has(> strong:first-child) {
  font-size: 15px;
  color: var(--moji-dim);
  margin: 0 0 1.6em;
}

.article-body p:has(> strong:first-child) > strong:first-child {
  display: block;
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 17px;
  letter-spacing: 0.06em;
  line-height: 1.7;
  color: var(--moji);
  margin-bottom: 0.3em;
}

/* 記事末の「参考: 媒体名」行（functions.php の the_content フィルタが付与） */
.article-body .entry-ref {
  margin: 2.5em 0 0;
  font-size: 12px;
  color: var(--moji-dim);
}

.article-body img {
  border-radius: var(--radius-s);
}

.entry-disclaimer {
  margin-top: 3em;
  padding-top: 1.2em;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--moji-dim);
}

/* --------------------------------------------------------------------------
   点数ミニヒーロー（single-news: score/relation メタがあるときタイトル下に）
   点数 → 訳語 → 原語の順は YAKUGO.md と同じ。1画面に収まる高さに抑える
   -------------------------------------------------------------------------- */

.score-mini {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-top: 22px;
  padding: 18px 20px;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.score-mini__score {
  flex: none;
  display: flex;
  align-items: baseline;
  margin: 0;
  line-height: 1;
}

.score-mini__num {
  font-family: var(--font-num);
  font-weight: 400;
  font-size: 54px;
  letter-spacing: 0.01em;
  color: var(--gold);
}

.score-mini__unit {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--moji-dim);
  margin-left: 5px;
}

.score-mini__body {
  min-width: 0;
}

/* 訳語が主役（明朝600。太字にしない） */
.score-mini__gloss {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: 18px;
  letter-spacing: 0.08em;
  line-height: 1.5;
  color: var(--moji);
  margin: 0;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.score-mini__gloss .heart {
  vertical-align: -0.06em;
}

.score-mini__pair {
  font-size: 12px;
  color: var(--moji-dim);
  margin: 4px 0 0;
}

/* --------------------------------------------------------------------------
   データシート（celebrity ほか）
   -------------------------------------------------------------------------- */

.datasheet {
  display: grid;
  gap: 0;
  margin: 20px 0;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.datasheet > div {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 12px 16px;
}

.datasheet > div + div {
  border-top: 1px solid var(--line);
}

.datasheet dt {
  flex: none;
  width: 6em;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--moji-dim);
}

.datasheet dd {
  margin: 0;
  font-size: 15px;
  letter-spacing: 0.03em;
}

/* 宿の値だけ明朝で少し立てる（v2.3 夜の明朝トーン） */
.datasheet__shuku {
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 0.08em;
}

/* --------------------------------------------------------------------------
   パンくず / ページ送り
   -------------------------------------------------------------------------- */

.breadcrumb {
  padding: 14px 0 0;
  font-size: 12px;
}

.breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 0;
  padding: 0;
  color: var(--moji-dim);
}

.breadcrumb li + li::before {
  content: "/";
  margin-right: 4px;
  color: var(--moji-dim);
}

.breadcrumb a {
  color: var(--moji-dim);
}

.breadcrumb a:hover {
  color: var(--lavender);
}

.pagination {
  padding: 24px 0 48px;
  font-family: var(--font-ui);
  font-weight: 500;
}

.pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pagination .page-numbers {
  display: inline-block;
  min-width: 40px;
  text-align: center;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  text-decoration: none;
  color: var(--moji);
}

.pagination .page-numbers.current {
  background: var(--lavender);
  border-color: var(--lavender);
  color: var(--yozora-deep);
}

.pagination a.page-numbers:hover {
  border-color: var(--lavender);
  color: var(--lavender);
}

/* --------------------------------------------------------------------------
   アーカイブヘッダー
   -------------------------------------------------------------------------- */

.archive-header {
  padding: 4rem 0 1.5rem;
}

.archive-header__title {
  font-size: clamp(24px, 6.4vw, 32px);
}

.archive-header__desc {
  margin: 10px 0 0;
  font-size: 14px;
  color: var(--moji-dim);
  max-width: 38em;
}

/* --------------------------------------------------------------------------
   二十七宿グリッド
   -------------------------------------------------------------------------- */

.shuku-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.shuku-grid a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  padding: 12px 4px;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  text-decoration: none;
}

.shuku-grid a:hover {
  border-color: var(--lavender);
}

.shuku-grid__name {
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.08em;
  color: var(--moji);
}

.shuku-grid a:hover .shuku-grid__name {
  color: var(--lavender);
}

.shuku-grid__reading {
  font-size: 10px;
  color: var(--moji-dim);
}

@media (min-width: 720px) {
  .shuku-grid {
    grid-template-columns: repeat(9, 1fr);
  }
}

/* --------------------------------------------------------------------------
   はじめての人向けガイド（宿曜って？ + 使い方3ステップ）
   前提知識ゼロで進める低リテラシー導線。lavender 1色配給・gold なし。
   -------------------------------------------------------------------------- */

.guide__intro {
  max-width: var(--w-article);
  margin-bottom: 3rem;
}

.guide__title {
  margin-bottom: 0.8rem;
}

.guide__lead {
  color: var(--moji-dim);
  font-size: 15px;
  line-height: 1.9;
  margin: 0;
}

.guide__steps-label {
  margin-bottom: 1.2rem;
}

/* ステップ: カード乱発を避け、細い罫（Co-Star「細線は句読点」）で区切る。
   モバイルは 番号+アイコン | 本文 の横並び1行。 */
.steps {
  list-style: none;
  margin: 0 0 2.5rem;
  padding: 0;
}

.step {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 16px;
  padding: 20px 0;
  border-top: 1px solid var(--line);
}

.steps > .step:first-child {
  border-top: 0;
  padding-top: 0;
}

.step__no {
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 2rem;
  line-height: 1;
  color: var(--lavender);
  letter-spacing: 0.02em;
}

.step__icon {
  display: inline-flex;
  color: var(--lavender);
}

.step__body {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.step__title {
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  color: var(--moji);
}

.step__text {
  font-size: 14px;
  line-height: 1.75;
  color: var(--moji-dim);
}

.guide__cta {
  text-align: center;
}

.guide__cta-note {
  margin: 12px 0 0;
  font-family: var(--font-ui);
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--moji-dim);
}

/* 大きく押しやすい診断CTA（タップ領域を広く） */
.btn--lg {
  font-size: 15px;
  padding: 18px 40px 18px calc(40px + 0.22em);
}

@media (min-width: 720px) {
  .steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
  }

  .step {
    grid-template-columns: 1fr;
    align-items: start;
    row-gap: 10px;
    padding: 0;
    border-top: 0;
  }

  .steps > .step:first-child {
    padding-top: 0;
  }

  .step__no {
    font-size: 2.4rem;
  }
}

/* --------------------------------------------------------------------------
   二十七宿イラスト索引（.shuku-cards）
   各宿＝擬人化イラスト＋宿名＋読み。rensa 型の網羅性を視覚で見せる。
   モバイル2列 → 3列 → 4列。画像は 3:2、CLS防止に aspect-ratio 固定。
   -------------------------------------------------------------------------- */

.shuku-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.shuku-card {
  display: block;
  overflow: hidden;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  text-decoration: none;
  color: var(--moji);
}

.shuku-card__media {
  display: block;
  aspect-ratio: 3 / 2;
  background: var(--yozora-deep);
}

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

.shuku-card__name {
  display: block;
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.08em;
  text-align: center;
  padding: 10px 6px 0;
}

.shuku-card__reading {
  display: block;
  font-size: 10px;
  color: var(--moji-dim);
  text-align: center;
  padding: 1px 6px 12px;
}

.shuku-card:hover {
  border-color: var(--lavender);
}

.shuku-card:hover .shuku-card__name {
  color: var(--lavender);
}

@media (min-width: 560px) {
  .shuku-cards {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 900px) {
  .shuku-cards {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
  }
}

/* --------------------------------------------------------------------------
   宿ページのイラストヒーロー（single-shuku 本文先頭）
   宿曜盤の前に擬人化イラストを大きく。宿名/読みを添える。
   -------------------------------------------------------------------------- */

.shuku-hero {
  margin: 1.5rem 0 2rem;
}

.shuku-hero__img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--yozora-deep);
}

.shuku-hero__caption {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 12px;
}

.shuku-hero__name {
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 1.25rem;
  letter-spacing: 0.08em;
  color: var(--moji);
}

.shuku-hero__reading {
  font-size: 13px;
  color: var(--moji-dim);
}

/* --------------------------------------------------------------------------
   CTAパネル
   -------------------------------------------------------------------------- */

/* 中央寄せは言い切りブロックと点数だけ（v2.2 #1）。CTAパネルは左寄せ */
/* 対話形式の吹き出し（相談者＝左／よるうら＝右🌙）。わかりやすさ重視 */
.dialogue {
  margin: 36px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.bubble {
  display: flex;
  gap: 12px;
  max-width: 90%;
}

.bubble--q {
  align-self: flex-start;
}

.bubble--a {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.bubble__ava {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 21px;
  background: rgba(232, 213, 160, 0.12);
  border: 1px solid rgba(232, 213, 160, 0.4);
}

.bubble__body {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 11px 16px;
  min-width: 0;
}

.bubble--a .bubble__body {
  background: rgba(232, 213, 160, 0.08);
  border-color: rgba(232, 213, 160, 0.28);
}

.bubble__who {
  display: block;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--moji-dim);
  margin-bottom: 3px;
}

.bubble__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.8;
}

/* メール購読オプトイン（週刊・宿曜の運勢） */
.optin {
  margin: 40px 0;
  padding: 22px 20px;
  border: 1px solid rgba(184, 160, 232, 0.35);
  border-radius: var(--radius);
  background: rgba(184, 160, 232, 0.07);
}

.optin__lead {
  margin: 0 0 14px;
  font-size: 15px;
  line-height: 1.9;
  color: var(--moji);
}

.optin-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.optin__birth,
.optin__email {
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--card-bg);
  color: inherit;
  font-size: 16px;
  width: 100%;
  box-sizing: border-box;
}

.optin__btn {
  padding: 13px;
  border: 0;
  border-radius: 10px;
  background: #e8d5a0;
  color: #0d1030;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
}

.optin__note {
  margin: 0;
  font-size: 11px;
  color: var(--moji-dim);
}

.optin__msg {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--moji-dim);
}

/* 記事末の電話占いテキスト CTA（バナーより高 CTR 狙い・文脈に溶かす） */
.affiliate-cta {
  margin: 36px 0 8px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(232, 213, 160, 0.06);
}

.affiliate-cta__label {
  display: block;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--moji-dim);
  margin-bottom: 8px;
}

.affiliate-cta__lead {
  margin: 0 0 8px;
  font-size: 15px;
  line-height: 1.9;
  color: var(--moji-dim);
}

.affiliate-cta__link {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.7;
}

.affiliate-cta__link a {
  color: #e8d5a0;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 記事末の PR 枠（A8 バナー等）。控えめに、でも広告と分かるように */
.ad-slot {
  margin: 40px 0 8px;
  text-align: center;
}

.ad-slot__label {
  display: block;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--moji-dim);
  margin-bottom: 8px;
}

.ad-slot__body img {
  max-width: 100%;
  height: auto;
}

.cta-panel {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 26px;
  margin: 4rem 0;
  text-align: left;
}

.cta-panel__title {
  font-size: 19px;
  margin-bottom: 8px;
}

.cta-panel p {
  font-size: 14px;
  color: var(--moji-dim);
}

.cta-panel .btn {
  margin-top: 6px;
}

/* --------------------------------------------------------------------------
   グイ卦バナー（.gui-banner）— 姉妹サイトへの誘導
   常時モーションなし。gold は盤の指標1点のみ（DESIGN.md 色の配給制）
   -------------------------------------------------------------------------- */

.gui-banner {
  margin: 4rem 0;
}

/* セクションの間に直接置くとき。前後のセクション余白が効くので自前の余白は持たない */
.gui-banner--flush {
  margin: 0;
}

.gui-banner__link {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 22px;
  text-decoration: none;
  color: inherit;
}

.gui-banner__link:hover {
  border-color: var(--line-strong);
}

/* 左の宿曜盤。lavender の細線、指標だけ gold */
.gui-banner__plate {
  flex: none;
  width: 78px;
  color: var(--lavender);
}

.gui-banner__plate svg {
  display: block;
  width: 100%;
  height: auto;
}

.gui-banner__mark {
  fill: var(--gold);
}

.gui-banner__glyph {
  font-family: var(--font-disp);
  font-size: 26px;
  fill: var(--moji);
  letter-spacing: 0.04em;
}

.gui-banner__body {
  display: block;
  min-width: 0;
}

.gui-banner__title {
  display: block;
  /* 親リンクの hover 色を継がせない。反応するのは CTA だけにする */
  color: var(--moji);
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 19px;
  line-height: 1.6;
  letter-spacing: 0.08em;
  word-break: keep-all;
  overflow-wrap: anywhere;
  margin-top: 2px;
}

.gui-banner__lead {
  display: block;
  font-size: 13.5px;
  line-height: 1.9;
  color: var(--moji-dim);
  margin-top: 8px;
}

.gui-banner__cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.18em;
  color: var(--lavender);
  margin-top: 14px;
}

.gui-banner__link:hover .gui-banner__cta {
  color: var(--mauve);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.gui-banner__ext {
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--moji-dim);
  border: 1px solid var(--line);
  border-radius: var(--radius-ui);
  padding: 2px 6px;
}

@media (max-width: 559px) {
  .gui-banner__link {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 22px 18px;
  }

  .gui-banner__plate {
    width: 58px;
  }

  .gui-banner__title {
    font-size: 17px;
  }
}

/* 診断ボタン + 関連リンク（同じ宿のページ等）を1パネルにまとめる横並び */
.cta-panel__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  margin-top: 6px;
}

.cta-panel__actions .btn {
  margin-top: 0;
}

.cta-panel__link {
  font-size: 13px;
  letter-spacing: 0.04em;
}

/* --------------------------------------------------------------------------
   通知画面風UI（.ui-notif）— スマホ通知カード
   yoru 記事・診断結果・シェア画像の鉄板フォーマット
   -------------------------------------------------------------------------- */

.ui-notif {
  background: rgba(242, 240, 247, 0.08);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(242, 240, 247, 0.12);
  border-radius: 16px;
  padding: 12px 14px;
  max-width: 420px;
  margin: 1.6em auto;
  font-family: var(--font-body);
}

.ui-notif__head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.ui-notif__icon {
  width: 18px;
  height: 18px;
  border-radius: 5px;
  background: var(--yozora);
  border: 1px solid var(--line-strong);
  display: grid;
  place-items: center;
  flex: none;
}

.ui-notif__icon::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  -webkit-mask-image: radial-gradient(circle at 68% 32%, transparent 52%, #000 54%);
  mask-image: radial-gradient(circle at 68% 32%, transparent 52%, #000 54%);
}

.ui-notif__app {
  font-size: 11px;
  color: var(--moji-dim);
  letter-spacing: 0.04em;
}

.ui-notif__time {
  margin-left: auto;
  font-size: 11px;
  color: var(--moji-dim);
}

/* 通知風UIはスマホOSの再現なので本文ゴシックのまま（明朝にしない） */
.ui-notif__title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.6;
  color: var(--moji);
  margin: 0 0 2px;
}

.ui-notif__body {
  font-size: 13px;
  line-height: 1.7;
  color: var(--moji);
  margin: 0;
}

/* --------------------------------------------------------------------------
   LINEトーク風UI（.ui-talk）— 既読スルー再現など
   -------------------------------------------------------------------------- */

.ui-talk {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 420px;
  margin: 1.6em auto;
  padding: 16px 14px;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: 16px;
}

.ui-talk__day {
  align-self: center;
  font-size: 10px;
  color: var(--moji-dim);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  padding: 2px 10px;
}

.ui-talk__row {
  display: flex;
  align-items: flex-end;
  gap: 6px;
}

.ui-talk__row--out {
  flex-direction: row-reverse;
}

.ui-talk__bubble {
  max-width: 78%;
  padding: 9px 14px;
  border-radius: 16px;
  font-size: 13px;
  line-height: 1.7;
}

.ui-talk__row--in .ui-talk__bubble {
  background: rgba(242, 240, 247, 0.1);
  color: var(--moji);
  border-bottom-left-radius: 4px;
}

.ui-talk__row--out .ui-talk__bubble {
  background: var(--lavender);
  color: var(--yozora-deep);
  border-bottom-right-radius: 4px;
}

.ui-talk__stamp {
  font-size: 10px;
  line-height: 1.5;
  color: var(--moji-dim);
  text-align: right;
  flex: none;
}

/* --------------------------------------------------------------------------
   宿曜盤（ring.js）— 夜空トーン
   線 = lavender 40% / 点 = mauve / 中央 = 訳語主体
   -------------------------------------------------------------------------- */

.ring {
  display: block;
  width: 100%;
  height: auto;
}

.ring__circle {
  fill: none;
  stroke: var(--line-strong);
  stroke-width: 1;
}

.ring__tick {
  stroke: var(--line-strong);
  stroke-width: 1;
}

.ring__label {
  fill: var(--moji-dim);
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 22px;
  text-anchor: middle;
  dominant-baseline: central;
}

.ring__label--lit {
  fill: var(--mauve);
  font-weight: 600;
}

.ring__label--dim {
  opacity: 0.4;
}

.ring__hit {
  fill: transparent;
}

a:hover > .ring__label {
  fill: var(--lavender);
}

.ring__chord {
  stroke: var(--mauve);
  stroke-width: 2;
}

.ring__node {
  fill: var(--mauve);
}

.ring__center-name {
  fill: var(--moji);
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: 44px;
  text-anchor: middle;
  dominant-baseline: central;
}

.ring__center-name--long {
  font-size: 34px;
}

.ring__center-sub {
  fill: var(--moji-dim);
  font-family: var(--font-body);
  font-size: 20px;
  text-anchor: middle;
  dominant-baseline: central;
}

/* draw-in（初回のみ。reduced-motion 尊重は ring.js 側で判定） */
.ring.is-drawing .ring__circle {
  stroke-dasharray: var(--ring-c);
  stroke-dashoffset: var(--ring-c);
  animation: ring-draw 1.2s ease-out forwards;
}

.ring.is-drawing .ring__tick,
.ring.is-drawing .ring__label,
.ring.is-drawing .ring__chord,
.ring.is-drawing .ring__node,
.ring.is-drawing .ring__center-name,
.ring.is-drawing .ring__center-sub {
  opacity: 0;
  animation: ring-fade 0.5s ease-out forwards;
  animation-delay: calc(0.55s + var(--i, 0) * 0.028s);
}

@keyframes ring-draw {
  to { stroke-dashoffset: 0; }
}

@keyframes ring-fade {
  to { opacity: 1; }
}

.ring.is-drawing .ring__label--dim {
  animation-name: ring-fade-dim;
}

@keyframes ring-fade-dim {
  to { opacity: 0.4; }
}

.ring-holder {
  width: min(100%, 320px);
  margin: 24px auto 8px;
}

/* --------------------------------------------------------------------------
   診断（/shindan/）— 生年月日ふたつだけ・1画面
   -------------------------------------------------------------------------- */

.shindan {
  padding-bottom: 40px;
}

.shindan__lead {
  font-size: 15px;
  color: var(--moji);
  margin: 8px 0 20px;
}

.shindan__form {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 18px;
}

.shindan__persons {
  display: grid;
  gap: 14px;
}

.shindan__field label {
  display: block;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.1em;
  margin-bottom: 6px;
}

.field-note {
  display: block;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 11px;
  color: var(--moji-dim);
}

.shindan__field input[type="date"] {
  width: 100%;
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--moji);
  background: var(--yozora);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-s);
  color-scheme: dark;
}

.shindan__field input[type="date"]:focus-visible {
  outline: 2px solid var(--lavender);
  outline-offset: 1px;
}

.shindan__actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 16px;
}

.shindan__actions .btn {
  flex: 1;
  text-align: center;
}

.shindan__privacy {
  font-size: 11px;
  color: var(--moji-dim);
  margin: 10px 0 0;
}

.shindan__error {
  color: var(--mauve);
  font-size: 13px;
  margin: 10px 0 0;
}

.shindan__error:empty {
  display: none;
}

@media (min-width: 720px) {
  .shindan__persons {
    grid-template-columns: 1fr 1fr;
  }
}

/* 診断結果（点数+ひとこと先出し。玉ボケ可） */
.shindan-result {
  position: relative;
  overflow: hidden;
  margin-top: 18px;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 8px 18px 22px;
}

.shindan-result__title {
  font-size: clamp(20px, 5.6vw, 26px);
  text-align: center;
  margin: 16px 0 0;
}

.shindan-result__ring {
  width: min(100%, 300px);
  margin: 18px auto 6px;
  position: relative;
  z-index: 1;
}

.shindan-result__persons {
  display: grid;
  gap: 10px;
  margin: 14px 0;
  position: relative;
  z-index: 1;
}

.shindan-result__person {
  background: var(--yozora);
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  padding: 12px 14px;
}

.shindan-result__person h3 {
  font-size: 16px;
  margin: 2px 0;
}

.shindan-result__person p {
  font-size: 12px;
  color: var(--moji-dim);
  margin: 0;
}

.shindan-result__label {
  font-size: 11px;
  color: var(--moji-dim);
  letter-spacing: 0.06em;
}

.shindan-result__note {
  position: relative;
  z-index: 1;
  font-size: 14px;
}

.shindan-result__sukui {
  position: relative;
  z-index: 1;
  font-size: 13px;
  color: var(--moji-dim);
}

@media (min-width: 720px) {
  .shindan-result__persons {
    grid-template-columns: 1fr 1fr;
  }
}

/* --------------------------------------------------------------------------
   診断結果 v1.5（SHINDAN_PLAN.md）
   FV 4:5 / 並置比較 / 詳細章 / シェア行 / 有料レポートパネル
   -------------------------------------------------------------------------- */

/* FV（点数+盤）はスクショ=シェア素材。縦4:5 に収まる余白（v1.5-6）。
   中身が超える時だけ自然に伸びる（aspect-ratio は望ましい比率として効く） */
.shindan-result__fv {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  aspect-ratio: 4 / 5;
  padding: 16px 0 6px;
}

.shindan-result__fv .score-hero__pair {
  margin-bottom: 6px;
}

.shindan-result__fv .score-hero__num {
  font-size: clamp(76px, 25vw, 132px);
}

.shindan-result__fv .score-hero__hitokoto {
  margin-top: 12px;
}

.shindan-result__fv .shindan-result__ring {
  width: min(48vw, 210px);
  margin: 14px auto 0;
}

@media (min-width: 720px) {
  .shindan-result__fv .shindan-result__ring {
    width: 240px;
  }
}

/* 章見出し（ふたりの並置・読み詳細）。カード内の静かな区切り */
.shindan-result__h {
  position: relative;
  z-index: 1;
  font-size: 17px;
  margin: 2.6rem 0 0.9rem;
}

/* 並置カードの増強: 宿の性格1行 + タグ（タグの mauve は v2.2 #4 の配給内） */
.shindan-result__person p.shindan-result__person-line {
  font-size: 13px;
  color: var(--moji);
  line-height: 1.8;
  margin: 8px 0 0;
}

.shindan-result__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

/* ここが似てる / ここが違う（タグの共通・差分から機械生成） */
.shindan-compare {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
  margin: 0 0 14px;
}

.shindan-compare__row {
  background: var(--yozora);
  border: 1px solid var(--line);
  border-radius: var(--radius-s);
  padding: 12px 14px;
}

.shindan-compare__label {
  display: block;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.18em;
  color: var(--lavender);
  margin-bottom: 4px;
}

.shindan-compare__row p {
  font-size: 13px;
  line-height: 1.8;
  margin: 0;
}

/* 詳細スクロール章「かみ合うとき」「こじれるとき」 */
.shindan-chapters {
  position: relative;
  z-index: 1;
}

.shindan-chapter {
  margin-top: 1.7rem;
}

.shindan-chapter__title {
  font-size: 16px;
  margin-bottom: 6px;
}

.shindan-chapter p {
  font-size: 14px;
  line-height: 2;
  margin: 0;
}

.shindan-chapter p.shindan-chapter__atsukai {
  font-size: 13px;
  color: var(--moji-dim);
  margin-top: 6px;
}

/* シェアボタン行（読み終えた直後の位置。FV直下には置かない） */
.share-row {
  position: relative;
  z-index: 1;
  margin-top: 2.6rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}

.share-row__label {
  font-family: var(--font-disp);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.08em;
  margin: 0 0 12px;
}

.share-row__btns {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.share-btn {
  display: inline-block;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.16em;
  line-height: 1;
  color: var(--moji);
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-ui);
  padding: 11px 16px 11px calc(16px + 0.16em);
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.share-btn:hover,
.share-btn:focus-visible {
  color: var(--lavender);
  border-color: var(--lavender);
}

.share-btn[disabled] {
  opacity: 0.5;
  cursor: default;
}

/* 有料レポートパネル（form[data-report-url] 設定時のみ表示。緊急性演出なし。
   gold はこのセクションでは価格の1箇所だけ=v2.2 #4 の配給内） */
.report-panel {
  position: relative;
  z-index: 1;
  background: var(--yozora);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 26px 22px;
  margin-top: 2.2rem;
}

.report-panel__kicker {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.22em;
  color: var(--moji-dim);
  margin: 0 0 8px;
}

.report-panel__title {
  font-size: 19px;
  margin: 0 0 10px;
}

.report-panel__lead {
  font-size: 13px;
  color: var(--moji-dim);
  margin: 0 0 14px;
}

.report-panel__list {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: grid;
  gap: 8px;
}

.report-panel__list li {
  position: relative;
  padding-left: 16px;
  font-size: 14px;
  line-height: 1.8;
}

.report-panel__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lavender);
  opacity: 0.7;
}

.report-panel__price {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 14px;
}

.report-panel__price-num {
  font-family: var(--font-num);
  font-size: 30px;
  letter-spacing: 0.02em;
  color: var(--gold);
}

.report-panel__price-note {
  font-size: 12px;
  color: var(--moji-dim);
}

/* 購入ボタン直下の注記（メール配送・届かない時の連絡先）。小さく静かに */
.report-panel__note {
  font-size: 11px;
  line-height: 1.9;
  color: var(--moji-dim);
  margin: 12px 0 0;
}

/* 結果カード内の CTA / レポートパネルは下余白を締める（カードの padding と重ねない） */
.shindan-result .cta-panel {
  margin: 2.2rem 0 0.6rem;
}

/* --------------------------------------------------------------------------
   検索・404
   -------------------------------------------------------------------------- */

.search-form {
  display: flex;
  gap: 8px;
  margin: 16px 0 28px;
}

.search-form input[type="search"] {
  flex: 1;
  min-width: 0;
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--moji);
  background: var(--card-bg);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-ui);
}

.notfound {
  padding: 60px 0 80px;
  text-align: center;
}

.notfound__title {
  font-size: clamp(22px, 6vw, 30px);
  margin: 8px 0 14px;
}

.notfound p {
  color: var(--moji-dim);
  font-size: 14px;
}

/* --------------------------------------------------------------------------
   フッター
   -------------------------------------------------------------------------- */

.site-footer {
  margin-top: 40px;
  background: var(--yozora-deep);
  border-top: 1px solid var(--line);
  padding: 44px 0 32px;
}

.site-footer__inner {
  width: min(100% - 40px, var(--w-list));
  margin-inline: auto;
}

.site-footer__brand {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.1em;
  color: var(--moji);
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 4px;
}

.site-footer__tagline {
  font-size: 12px;
  color: var(--moji-dim);
  margin: 0 0 20px;
}

.site-footer__nav ul {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
}

.site-footer__nav a {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--moji-dim);
  text-decoration: none;
}

.site-footer__nav a:hover {
  color: var(--lavender);
}

.site-footer__policies {
  list-style: none;
  margin: 0 0 14px;
  padding: 14px 0 0;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  font-size: 12px;
}

.site-footer__policies a {
  color: var(--moji-dim);
}

.site-footer__policies a:hover {
  color: var(--lavender);
}

.site-footer__disclaimer {
  font-size: 11px;
  color: var(--moji-dim);
  margin: 0 0 10px;
  max-width: 44em;
}

.site-footer__copy {
  font-size: 11px;
  color: var(--moji-dim);
  margin: 0;
}

/* ==========================================================================
   v2.1 刺さるレイヤー（DESIGN.md v2.1 / 照準 2026-07-12 改訂: 深夜の恋愛女子全般）
   実写素材（assets/img/*.webp）+ あしらい + アニメーション。
   - 実写の上には必ず rgba(13,16,48,.55〜.75) のオーバーレイ
   - 発光素材（glitter）は mix-blend-mode: screen で重ねる
   - champagne / butterfly-glow は不使用（水商売シグナルのため。DESIGN.md）
   - 動きは全部ゆっくり（6s以上）。すべて末尾の prefers-reduced-motion で無効化される
   ========================================================================== */

/* ── FV 実写フォールバック（bokeh-portrait SP / bokeh-wide PC） ── */

.fv--photo .fv__sky {
  background: url("../img/bokeh-portrait.webp") center / cover no-repeat var(--yozora);
}

/* 実写の上の基礎オーバーレイ（.fv__shade の縦グラデと合算で下部 .55〜.9）。
   動画再生時は .fv__shade のみ（中央 .5 未満で動画が見える）。 */
.fv--photo .fv__sky::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(13, 16, 48, 0.45);
}

@media (min-width: 720px) {
  .fv--photo .fv__sky {
    /* 横位置。左が暗くテキスト向き */
    background-image: url("../img/bokeh-wide.webp");
  }
}

/* FV用の追い玉ボケ（実写の上に screen で少しだけ。明滅用） */
.fv__dot {
  position: absolute;
  border-radius: 50%;
  filter: blur(24px);
  mix-blend-mode: screen;
  animation: bokeh-pulse 9s ease-in-out infinite alternate;
}

.fv__dot--a { width: 110px; height: 110px; left: 6%;  top: 30%; background: rgba(184, 160, 232, 0.5); }
.fv__dot--b { width: 70px;  height: 70px;  right: 24%; top: 52%; background: rgba(232, 160, 200, 0.45); animation-delay: -4s; }

/* ── 発光あしらい（純黒素材は必ず screen で夜空に重ねる） ── */

/* ラメ（glitter.webp）。v2.2 #6: 常時モーションは1画面1つ。
   FV では玉ボケ明滅（.fv__dot）を優先し、ラメは静止テクスチャにする */
.glow-glitter {
  position: absolute;
  inset: 0;
  background: url("../img/glitter.webp") repeat;
  background-size: 560px;
  mix-blend-mode: screen;
  opacity: 0.38;
  pointer-events: none;
}

.glow-glitter--soft {
  opacity: 0.28;
}

/* FV のペイン行（小ラベルと言い切りの間に1行。mauve・小さめ・ゴシック） */
.fv__intro {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: clamp(13px, 3.8vw, 15px);
  letter-spacing: 0.06em;
  color: var(--mauve);
  margin: 0 0 1rem;
}

/* ── 訳語ティッカー（ヘッダー下。core の訳語で数十件、hover で一時停止）
   v2.2 #6: サイトで唯一の常時モーション。opacity .55・細字で静かに流す ── */

.yakugo-ticker {
  overflow: hidden;
  white-space: nowrap;
  background: var(--yozora-deep);
  border-bottom: 1px solid var(--line);
  padding: 7px 0;
  opacity: 0.55;
}

.yakugo-ticker__track {
  display: inline-block;
  white-space: nowrap;
  animation: ticker-run 60s linear infinite;
}

.yakugo-ticker__copy {
  display: inline-block;
  font-family: var(--font-ui);
  font-weight: 400;
  font-size: 11px;
  line-height: 1.5;
  letter-spacing: 0.14em;
  color: var(--moji-dim);
}

.yakugo-ticker:hover .yakugo-ticker__track {
  animation-play-state: paused;
}

@keyframes ticker-run {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ── CTAシアー（v2.2 #6 で hover 時のみに降格。常時は動かさない。ghost には出さない） ── */

.btn {
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: "";
  position: absolute;
  top: -4px;
  bottom: -4px;
  left: -60%;
  width: 36%;
  background: linear-gradient(105deg, transparent, rgba(232, 213, 160, 0.4), transparent);
  transform: skewX(-20deg);
  pointer-events: none;
}

.btn:hover::after,
.btn:focus-visible::after {
  animation: btn-shear 0.9s ease-out 1;
}

.btn--ghost::after {
  content: none;
}

@keyframes btn-shear {
  from { left: -60%; }
  to   { left: 130%; }
}

/* ── 相性ランキング帯（bokeh-wide + glitter(screen) + 強めオーバーレイ）
   v2.2 #6: 金の泡（.band-bubble）は診断結果ページ限定。フロントの帯は静止背景のみ ── */

.section--sparkle {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.section--sparkle::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background-color: var(--yozora-deep);
  background-image:
    linear-gradient(180deg, rgba(13, 16, 48, 0.78), rgba(13, 16, 48, 0.84)),
    url("../img/glitter.webp"),
    url("../img/bokeh-wide.webp");
  background-repeat: no-repeat, repeat, no-repeat;
  background-size: auto, 560px, cover;
  background-position: center, 0 0, center;
  /* glitter は下の bokeh-wide に screen で乗せる（純黒地が透けて光だけ残る） */
  background-blend-mode: normal, screen, normal;
}

.band-bubbles {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

/* 舞い上がるラメ（金のCSS円をゆっくり上昇。JS が位置・delay を散らす。診断結果ページ限定） */
.band-bubble {
  position: absolute;
  bottom: -16px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 32%, rgba(232, 213, 160, 0.9), rgba(232, 213, 160, 0.15));
  mix-blend-mode: screen;
  animation: bubble-rise 12s linear infinite;
}

@keyframes bubble-rise {
  from {
    transform: translateY(0);
    opacity: 0;
  }
  8% {
    opacity: 0.8;
  }
  90% {
    opacity: 0.5;
  }
  to {
    transform: translateY(-560px);
    opacity: 0;
  }
}

/* ── /yoru/ 導線（hand-phone.webp 横並び。実写にはオーバーレイ必須） ── */

.yoru-duct {
  display: grid;
  gap: 16px;
}

.yoru-media {
  position: relative;
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  height: 170px;
  border: 1px solid var(--line);
}

.yoru-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 32%;
  display: block;
}

.yoru-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13, 16, 48, 0.55), rgba(13, 16, 48, 0.25) 55%, rgba(13, 16, 48, 0.6));
}

/* 実写区画は写真＋オーバーレイ＋文字だけ（v2.2 #7）。装飾は重ねない */
.yoru-media__caption {
  position: absolute;
  left: 14px;
  bottom: 10px;
  z-index: 1;
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  color: var(--moji);
  letter-spacing: 0.14em;
}

@media (min-width: 720px) {
  .yoru-duct {
    grid-template-columns: 264px 1fr;
    gap: 20px;
    align-items: start;
  }

  .yoru-media {
    height: 100%;
    min-height: 300px;
  }

  .yoru-media img {
    object-position: center 40%;
  }
}

/* ── 診断結果: 実写背景（bokeh-portrait + オーバーレイ + ラメ） ── */

.shindan-result--photo {
  isolation: isolate;
}

.shindan-result__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(13, 16, 48, 0.7), rgba(13, 16, 48, 0.75)),
    url("../img/bokeh-portrait.webp") center / cover no-repeat var(--yozora-deep);
  pointer-events: none;
}

/* ── ハート（細線SVG。スコア84以上の表示にだけ小さく添える） ── */

.heart {
  width: 14px;
  height: 14px;
  color: var(--mauve);
  vertical-align: 0.05em;
  margin-left: 4px;
  flex: none;
}

.score-hero__score .heart {
  width: 20px;
  height: 20px;
  margin-left: 8px;
}

/* ── スクロール出現（IntersectionObserver。8px フェードアップ） ── */

.reveal {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

/* JS が動かない環境では隠したままにしない */
.no-js .reveal {
  opacity: 1;
  transform: none;
}

/* --------------------------------------------------------------------------
   モーション設定の尊重
   -------------------------------------------------------------------------- */

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

  /* シアーと泡は途中で止まると残像になるので消す */
  .btn::after,
  .band-bubble {
    display: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* --------------------------------------------------------------------------
   週間運勢（unsei）
   - .unsei-toc: 27宿のページ内アンカー目次（single-unsei）
   - .article-body--unsei table: 週間表（4列）。スマホは日付を行ラベルにした縦積み
   - .unsei-widget: front-page「今日の運勢」（生年月日1つ→ブラウザ内計算）
   -------------------------------------------------------------------------- */

.unsei-toc {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 18px 14px;
  margin-bottom: 28px;
}

.unsei-toc__label {
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--moji-dim);
  margin: 0 0 10px;
}

.unsei-toc__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: 6px;
}

.unsei-toc__list a {
  display: block;
  text-align: center;
  padding: 8px 4px;
  font-family: var(--font-disp);
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--moji);
  background: var(--yozora);
  border: 1px solid var(--line);
  border-radius: var(--radius-ui);
  text-decoration: none;
}

.unsei-toc__list a:hover,
.unsei-toc__list a:focus-visible {
  border-color: var(--line-strong);
}

.unsei-toc__note {
  font-size: 12px;
  color: var(--moji-dim);
  margin: 12px 0 0;
}

/* 週間表: 27宿ぶんスクロールするので目次から飛べる前提。行間は詰めすぎない */
.article-body--unsei h2 {
  scroll-margin-top: 80px;
}

.article-body--unsei table {
  font-size: 13px;
}

.article-body--unsei th,
.article-body--unsei td {
  padding: 9px 12px 9px 0;
}

/* ランク★（4列表の3列目）はゴールド。:has 非対応ブラウザは通常色のまま */
.article-body--unsei tr:has(td:nth-child(4)) td:nth-child(3) {
  font-family: var(--font-num);
  color: var(--gold);
  letter-spacing: 2px;
  white-space: nowrap;
}

@media (max-width: 559px) {
  /* 汎用の縦積み（2〜3列想定）を4列の週間表向けに上書き:
     日付=行ラベル（全幅）→ 関係+★を1行→ ひとことは全幅で下に */
  .article-body--unsei thead {
    display: none;
  }

  .article-body--unsei tr {
    grid-template-columns: 1fr auto;
    gap: 3px 14px;
  }

  .article-body--unsei tr > td:last-child {
    grid-column: 1 / -1;
    font-size: 12px;
    color: var(--moji-dim);
  }
}

/* 今日の運勢ウィジェット（front-page ヒーロー直下） */
.unsei-widget {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 18px;
}

.unsei-widget__row {
  display: grid;
  gap: 14px;
}

.unsei-widget__field {
  display: block;
  min-width: 0; /* グリッド項目の min-width:auto を解除（iOSのdate入力が縮まず溢れるのを防ぐ） */
  font-family: var(--font-ui);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.1em;
}

.unsei-widget__field input[type="date"] {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0; /* iOS Safari の date 入力は固有最小幅を持つため明示的に縮める */
  margin-top: 6px;
  padding: 12px 14px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--moji);
  background: var(--yozora);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-s);
  color-scheme: dark;
  -webkit-appearance: none;
  appearance: none;
}

.unsei-widget__field input[type="date"]:focus-visible {
  outline: 2px solid var(--lavender);
  outline-offset: 1px;
}

.unsei-widget .btn {
  width: 100%;
  text-align: center;
}

@media (min-width: 720px) {
  .unsei-widget__row {
    grid-template-columns: 1fr auto;
    align-items: end;
  }

  .unsei-widget .btn {
    width: auto;
  }
}

.unsei-widget__result {
  margin-top: 14px;
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 18px;
}

.unsei-widget__head {
  font-size: 14px;
  color: var(--moji-dim);
  margin: 0 0 6px;
}

.unsei-widget__label {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
  margin: 0 0 10px;
}

.unsei-widget__gloss {
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: clamp(22px, 6vw, 28px);
  letter-spacing: 0.06em;
  color: var(--moji);
}

.unsei-widget__gloss:focus {
  outline: none;
}

.unsei-widget__stars {
  font-family: var(--font-num);
  font-size: 15px;
  letter-spacing: 2px;
  color: var(--gold);
}

.unsei-widget__origin {
  font-size: 12px;
  color: var(--moji-dim);
}

.unsei-widget__text {
  font-size: 15px;
  line-height: 2;
  margin: 0;
}

.unsei-widget__special {
  font-size: 13px;
  color: var(--gold);
  margin: 10px 0 0;
}

.unsei-widget__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 14px 0 0;
  font-size: 13px;
}

/* ══ 夜恋タイプ診断（/yorutype/） ══ */
.yorutype { padding-bottom: 48px; }
.yt-form { margin-top: 28px; }
.yt-form__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.yt-form__lead { color: var(--moji-dim); font-size: 0.95rem; }
.yt-form__progress { color: var(--gold); font-family: var(--font-num); font-size: 0.95rem; }
.yt-q { border: 1px solid var(--line); border-radius: var(--radius-s); background: var(--card-bg); padding: 16px 16px 14px; margin: 14px 0; }
.yt-q__t { font-family: var(--font-body); font-weight: 600; font-size: 1.02rem; padding: 0 4px; }
.yt-q__num { color: var(--lavender); font-family: var(--font-num); margin-right: 8px; }
.yt-q__choices { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
@media (max-width: 560px) { .yt-q__choices { grid-template-columns: 1fr; } }
.yt-choice { display: block; cursor: pointer; }
.yt-choice input { position: absolute; opacity: 0; }
.yt-choice span { display: flex; align-items: center; justify-content: center; text-align: center; min-height: 52px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-s); background: rgba(184, 160, 232, 0.06); font-size: 0.95rem; line-height: 1.5; transition: border-color .15s, background .15s; }
.yt-choice input:checked + span { border-color: var(--lavender); background: rgba(184, 160, 232, 0.18); color: var(--moji); }
.yt-choice input:focus-visible + span { outline: 2px solid var(--lavender); outline-offset: 2px; }
.yt-form__meta { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 22px 0 6px; }
@media (max-width: 560px) { .yt-form__meta { grid-template-columns: 1fr; } }
.yt-form__meta select { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-s); background: var(--card-bg); color: var(--moji); font-size: 1rem; }
.yt-card { border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--card-bg); padding: 26px 22px; margin: 26px 0 18px; text-align: center; }
.yt-card__label { color: var(--moji-dim); font-size: 0.85rem; letter-spacing: 0.12em; }
.yt-card__code { color: var(--gold); font-family: var(--font-num); font-size: 1.05rem; letter-spacing: 0.3em; margin: 6px 0 2px; }
.yt-card__name { font-family: var(--font-disp); font-weight: 600; font-size: 1.7rem; color: var(--moji); margin: 4px 0 6px; }
.yt-card__catch { color: var(--lavender); font-size: 1.02rem; margin-bottom: 14px; }
.yt-card__desc { text-align: left; line-height: 1.9; margin: 0 auto 12px; max-width: 34em; }
.yt-card__advice { text-align: left; color: var(--gold); line-height: 1.8; margin: 0 auto 4px; max-width: 34em; }
.yt-card__spice { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 14px; text-align: left; }
.yt-card__spice-t { color: var(--moji-dim); font-size: 0.85rem; letter-spacing: 0.1em; margin-bottom: 6px; }
.yt-card__spice-line { font-size: 0.95rem; line-height: 1.8; margin: 4px 0; }
.yt-card__match { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 14px; text-align: left; }
.yt-card__match p { margin: 6px 0; font-size: 0.98rem; }
.yt-card__match-l { color: var(--moji-dim); font-size: 0.88rem; margin-right: 8px; }
.yt-share { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 14px 0; }
.yt-next { text-align: center; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 16px; margin: 22px 0; background: rgba(184, 160, 232, 0.05); }
.yt-next__lead { line-height: 1.9; margin-bottom: 14px; }
.yt-retry { text-align: center; margin: 10px 0 4px; }
.yt-retry a { color: var(--lavender); }
