/* FancyNews — fancynews.com 全ページ共通のスタイル（手書き）。正本: docs/DESIGN.md
   夜の地（藍）に、あかりの琥珀を1色。語り口の札の4色は札と点にだけ使う。影は使わず、線と面の明るさで段を付ける。
   ⚠ プレーヤーの幕（.vp__curtain）は上に「覆う」だけ（pointer-events:none）。動画要素を visibility / display で隠さない（iPhone で自動再生が止まる・LSN-0239） */
:root {
  --bg: #12152b; --bg2: #171b38; --surface: #1c2142; --raised: #272d5a; --line: #343b6e; --line2: #4d5596;
  --ink: #f4eedc; --ink2: #b9bddb; --ink3: #8f94bd;
  --amber: #ffc24b; --amber-ink: #2a2150; --amber-soft: rgba(255, 194, 75, .13);
  --violet: #a99bff; --pink: #ffb3c1; --red: #ff7a6b;
  --tone-p: #6fd6c8; --tone-x: #8fb8ff; --tone-k: #c8e56a; --tone-e: #e3a6ff;
  --r: 18px; --r2: 12px; --pad: clamp(14px, 2.4vw, 28px); --max: 1360px; --hd: 64px;
  --font: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", "Hiragino Sans", "Yu Gothic UI", "Meiryo", system-ui, sans-serif;
  --font-en: "Fredoka", "Zen Maru Gothic", system-ui, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink); font: 500 16px/1.7 var(--font); overflow-wrap: anywhere;
  background-image:
    radial-gradient(1px 1px at 12% 9%, rgba(244, 238, 220, .55) 50%, transparent 51%),
    radial-gradient(1px 1px at 31% 22%, rgba(244, 238, 220, .35) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 58% 6%, rgba(255, 194, 75, .5) 50%, transparent 51%),
    radial-gradient(1px 1px at 77% 17%, rgba(244, 238, 220, .4) 50%, transparent 51%),
    radial-gradient(1px 1px at 91% 31%, rgba(169, 155, 255, .6) 50%, transparent 51%),
    radial-gradient(1px 1px at 6% 38%, rgba(244, 238, 220, .3) 50%, transparent 51%),
    radial-gradient(60vw 420px at 70% -120px, rgba(169, 155, 255, .13), transparent 70%),
    radial-gradient(50vw 360px at 8% -80px, rgba(255, 194, 75, .07), transparent 70%);
  background-repeat: no-repeat; background-size: 100% 900px;
}
html[lang="ja"] [data-l="en"], html[lang="en"] [data-l="ja"] { display: none !important; }
html[lang="en"] body { font-family: var(--font-en); font-weight: 500; }
img { max-width: 100%; height: auto; }
a { color: var(--amber); text-underline-offset: 3px; }
a:hover { color: #ffd98a; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--amber); color: var(--amber-ink); padding: 8px 14px; border-radius: 10px; }
.skip:focus { left: 8px; }
h1, h2, h3, h4 { line-height: 1.35; margin: 0; font-weight: 700; }

/* ── ヘッダー ── */
.hd { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 14px; min-height: var(--hd); padding: 8px var(--pad);
  background: rgba(18, 21, 43, .92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); min-width: 0; }
.brand img { width: 44px; height: 44px; flex: none; }
.brand__name { font: 700 24px/1 var(--font-en); letter-spacing: .01em; }
.brand__name b { color: var(--amber); font-weight: 700; }
.brand__tag { font-size: 12.5px; color: var(--ink2); white-space: nowrap; }
.search { flex: 1 1 320px; max-width: 520px; margin-left: auto; }
.search input { width: 100%; height: 42px; padding: 0 16px 0 40px; border-radius: 999px; border: 1px solid var(--line2); background: var(--surface) no-repeat 14px 50% / 17px
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b9bddb' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.6-3.6'/%3E%3C/svg%3E"); }
.search input::placeholder { color: var(--ink3); }
.search input:focus { outline: none; border-color: var(--amber); background-color: var(--raised); }
.hd__nav { display: flex; align-items: center; gap: 4px 16px; margin-left: auto; font-size: 14.5px; white-space: nowrap; }
.search + .hd__nav { margin-left: 0; }
.hd__nav a { color: var(--ink); text-decoration: none; font-weight: 700; }
.hd__nav a:hover { color: var(--amber); }
.langsw, .seg { display: inline-flex; border: 1px solid var(--line2); border-radius: 999px; overflow: hidden; flex: none; }
.langsw button, .seg button { border: 0; background: transparent; padding: 5px 13px; font-size: 13px; font-weight: 700; color: var(--ink2); }
.langsw button[aria-pressed="true"], .seg button[aria-pressed="true"] { background: var(--amber); color: var(--amber-ink); }
.seg button span { font-weight: 500; opacity: .75; margin-left: 2px; }

/* ── 共通の部品 ── */
main { max-width: var(--max); margin: 0 auto; padding: 18px var(--pad) 40px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; padding: 6px 15px; border-radius: 999px; border: 1px solid var(--line2);
  background: var(--surface); color: var(--ink); font-weight: 700; font-size: 14px; text-decoration: none; white-space: nowrap; }
.btn:hover { border-color: var(--amber); color: var(--ink); }
.btn--main { background: var(--amber); border-color: var(--amber); color: var(--amber-ink); }
.btn--main:hover { background: #ffd070; color: var(--amber-ink); }
.btn--glow { background: var(--amber-soft); border-color: var(--amber); color: var(--amber); }
.btn--icon { width: 40px; padding: 0; font-size: 19px; }
.btn--icon[aria-pressed="true"] { color: var(--amber); border-color: var(--amber); }
.btn--more { display: flex; margin: 18px auto 0; min-width: 220px; }
.sec__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 0 0 12px; }
.sec__head h2 { font-size: clamp(20px, 2.2vw, 25px); padding-left: 14px; position: relative; }
.sec__head h2::before { content: ""; position: absolute; left: 0; top: .18em; bottom: .18em; width: 5px; border-radius: 3px; background: var(--amber); }
.sec__more { font-size: 14px; font-weight: 700; }
.chip__n { font: 500 12px/1 var(--font-en); color: var(--ink3); margin-left: 4px; }
.tone { display: inline-block; font-style: normal; font-size: 11.5px; font-weight: 700; line-height: 1; padding: 4px 8px; border-radius: 999px; border: 1px solid currentColor; white-space: nowrap; flex: none; }
.tone--p { color: var(--tone-p); } .tone--x { color: var(--tone-x); } .tone--k { color: var(--tone-k); } .tone--e { color: var(--tone-e); }
.dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: currentColor; flex: none; }
.av { position: relative; display: inline-grid; place-items: center; border-radius: 50%; overflow: hidden; background: var(--raised); color: var(--ink2); font-weight: 700; flex: none; border: 1px solid var(--line2); }
.av--44 { width: 44px; height: 44px; font-size: 18px; } .av--40 { width: 40px; height: 40px; font-size: 16px; } .av--28 { width: 28px; height: 28px; font-size: 12px; }
.av img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.av img.is-broken { display: none; }

/* ── プレーヤーと注目の新着 ── */
.stage { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; align-items: start; }
.stage__main { min-width: 0; }
.vp { position: relative; aspect-ratio: 16 / 9; background: #070914; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line2); }
#player-host, #player-host > * { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.vp__curtain { position: absolute; inset: 0; display: grid; place-items: center; background: #0b0d1d; pointer-events: none; opacity: 0; transition: opacity .35s; }
.vp__curtain img { width: min(34%, 190px); height: auto; }
.vp[data-curtain="on"] .vp__curtain { opacity: 1; }
.vp[data-curtain="on"][data-state="tuning"] .vp__curtain img { animation: float 2.6s ease-in-out infinite; }
.now { display: flex; align-items: center; gap: 12px; margin-top: 12px; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); min-width: 0; }
.now__txt { display: grid; min-width: 0; flex: 1 1 auto; line-height: 1.4; }
.now__label { justify-self: start; font-size: 11.5px; font-weight: 700; color: var(--amber-ink); background: var(--amber); padding: 1px 9px; border-radius: 999px; }
.now[data-state="live"] .now__label { background: var(--red); color: #fff; }
.now[data-state="tuning"] .now__label, .now[data-state="error"] .now__label { background: var(--raised); color: var(--ink2); }
.now__name { font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.now__title { font-size: 13.5px; color: var(--ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.now__act { display: flex; gap: 8px; flex: none; flex-wrap: wrap; justify-content: flex-end; }
.now__msg { display: flex; align-items: center; gap: 10px; margin: 10px 0 0; padding: 8px 14px; background: var(--amber-soft); border: 1px solid rgba(255, 194, 75, .4); border-radius: var(--r2); font-size: 14.5px; }
.now__msg img { width: 48px; height: 48px; flex: none; }
.info { margin: 12px 4px 0; font-size: 14.5px; color: var(--ink2); }
.info p { margin: 0 0 6px; }
.info__tone { display: flex; gap: 8px; align-items: baseline; color: var(--ink); }
.info__tone .tone { transform: translateY(-1px); }
.info__links { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.info__links a { font-weight: 700; text-decoration: none; }
.info__links a.is-quiet { color: var(--ink3); font-weight: 500; text-decoration: underline; }
.noscript { margin: 12px 0 0; padding: 12px 14px; border: 1px dashed var(--line2); border-radius: var(--r2); }

.picks { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; }
.js .picks__fallback { display: none; }
.js .picks__fallback.is-shown { display: block; }
.picks__head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.picks__head img { width: 48px; height: 48px; flex: none; }
.picks__head h2 { font-size: 19px; }
.picks__rule { margin: 0; font-size: 12.5px; color: var(--ink3); line-height: 1.4; }
.picks__list { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x proximity; padding-bottom: 6px; scrollbar-color: var(--line2) transparent; }
.picks__list > * { flex: 0 0 min(72vw, 250px); scroll-snap-align: start; }

/* 動画のカード（描くのは app.js。題名と絵は運営者のもの） */
.vc { display: grid; gap: 8px; align-content: start; text-decoration: none; color: var(--ink); padding: 6px; border-radius: var(--r2); border: 1px solid transparent; min-width: 0; }
.vc:hover { background: var(--raised); color: var(--ink); }
.vc[aria-current="true"] { background: var(--amber-soft); border-color: var(--amber); }
.vc__th { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; background: #0b0d1d; }
.vc__th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vc__th img.is-broken { visibility: hidden; }
.vc[aria-current="true"] .vc__th::after { content: "▶"; position: absolute; left: 6px; bottom: 6px; font-size: 11px; line-height: 1; padding: 5px 8px; border-radius: 999px; background: var(--amber); color: var(--amber-ink); }
.vc__b { display: grid; gap: 3px; min-width: 0; }
.vc__t { font-size: 14px; font-weight: 700; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vc__m { font-size: 12px; color: var(--ink2); display: flex; gap: 6px; align-items: center; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vc__m .tone { font-size: 10.5px; padding: 3px 7px; }

/* チャンネルのカード */
.ch { position: relative; display: flex; align-items: center; min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r2); }
.ch:hover { border-color: var(--line2); background: var(--raised); }
.ch[aria-current="true"] { border-color: var(--amber); background: var(--amber-soft); }
.ch__a { display: flex; align-items: center; gap: 11px; flex: 1 1 auto; min-width: 0; padding: 9px 4px 9px 11px; text-decoration: none; color: var(--ink); }
.ch__b { display: grid; gap: 4px; min-width: 0; }
.ch__n { font-weight: 700; font-size: 15px; line-height: 1.35; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ch__m { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--ink2); min-width: 0; }
.ch__m > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.ch__fav { flex: none; width: 42px; height: 42px; border: 0; background: transparent; font-size: 19px; color: var(--ink3); border-radius: 50%; }
.ch__fav[aria-pressed="true"] { color: var(--amber); }
.ch.is-dormant .ch__n { color: var(--ink2); }
.picks .ch { background: transparent; border-color: transparent; }
.picks .ch:hover { background: var(--raised); }

/* ── あいさつときぶん ── */
.hello { margin-top: 30px; padding: 18px; background: linear-gradient(180deg, var(--bg2), var(--surface)); border: 1px solid var(--line); border-radius: calc(var(--r) + 6px); }
.hello__who { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.mosha { flex: none; border: 0; background: none; padding: 0; width: 112px; height: 112px; border-radius: 50%; }
.mosha img { width: 100%; height: 100%; display: block; animation: float 5s ease-in-out infinite; }   /* 押す的（ボタン）は動かさず、中の絵だけを揺らす */
.mosha.is-poked img { animation: poke .5s ease; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes poke { 0% { transform: scale(1); } 35% { transform: scale(1.12, .9) translateY(4px); } 70% { transform: scale(.95, 1.07) translateY(-8px); } 100% { transform: scale(1); } }
.bubble { position: relative; flex: 1 1 auto; min-width: 0; background: var(--raised); border: 1px solid var(--line2); border-radius: var(--r); padding: 12px 16px; }
.bubble::before { content: ""; position: absolute; left: -9px; top: 34px; width: 16px; height: 16px; background: var(--raised); border-left: 1px solid var(--line2); border-bottom: 1px solid var(--line2); transform: rotate(45deg); }
.bubble h2 { font-size: clamp(18px, 2vw, 22px); }
.bubble p { margin: 4px 0 0; font-size: 14.5px; color: var(--ink2); }
.moods { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x proximity; scrollbar-color: var(--line2) transparent; }
.mood { flex: 0 0 150px; scroll-snap-align: start; display: grid; justify-items: center; gap: 4px; text-align: center; padding: 12px 8px 12px; text-decoration: none; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--r); transition: transform .15s, border-color .15s; }
.mood img { width: 104px; height: 104px; }
.mood__t { font-weight: 700; font-size: 14px; line-height: 1.4; }
.mood__n { font: 500 12px/1 var(--font-en); color: var(--ink3); }
.mood:hover { border-color: var(--amber); transform: translateY(-3px); color: var(--ink); }

/* ── 選ぶ ── */
.guide { margin-top: 34px; scroll-margin-top: calc(var(--hd) + 8px); }
.tabs { display: flex; gap: 6px; overflow-x: auto; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.tabs button { flex: none; border: 0; background: none; padding: 9px 16px; font-weight: 700; font-size: 15px; color: var(--ink2); border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--amber); }
.entry__note { margin: 0 0 10px; font-size: 14px; color: var(--ink2); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 42px; padding: 5px 13px 5px 7px; border-radius: 999px; border: 1px solid var(--line2); background: var(--surface); color: var(--ink); text-decoration: none; font-weight: 700; font-size: 14px; }
.chip img { width: 30px; height: 30px; flex: none; }
.chip .dot { margin: 0 3px 0 8px; }
.chip:hover { border-color: var(--amber); color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--amber); border-color: var(--amber); color: var(--amber-ink); }
.chip[aria-pressed="true"] .chip__n { color: var(--amber-ink); opacity: .75; }
.chips--foot { margin-top: 28px; }
.chips--foot .chip { padding-left: 14px; }
.shelf { margin-top: 18px; }
.shelf__head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.shelf__head > img { width: 64px; height: 64px; flex: none; }
.shelf__txt { flex: 1 1 240px; min-width: 0; }
.shelf__txt h3 { font-size: 20px; }
.shelf__txt p { margin: 2px 0 0; font-size: 14px; color: var(--ink2); }
.shelf__n { font-size: 13.5px; color: var(--ink2); font-weight: 700; white-space: nowrap; }
.rail { margin: 0 0 16px; padding: 12px 12px 6px; background: var(--bg2); border: 1px solid var(--line); border-radius: var(--r); }
.rail h4 { font-size: 15px; margin: 0 0 6px 4px; color: var(--amber); }
.rail__l { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x proximity; scrollbar-color: var(--line2) transparent; }
.rail__l > * { flex: 0 0 min(64vw, 228px); scroll-snap-align: start; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: 9px; }
.grid .grp { grid-column: 1 / -1; font-size: 15px; color: var(--ink2); margin: 12px 0 0; padding-top: 10px; border-top: 1px dashed var(--line); }
.grid .grp:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.guide__empty { grid-column: 1 / -1; display: flex; align-items: center; gap: 14px; padding: 16px; border: 1px dashed var(--line2); border-radius: var(--r); color: var(--ink2); margin: 0; }
.guide__empty img { width: 96px; height: 96px; flex: none; }

/* ── 語り口の札 ── */
.tones { margin-top: 38px; }
.tones__lead { margin: 0 0 14px; color: var(--ink2); max-width: 62em; font-size: 15px; }
.tones__l { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 10px; }
.tonecard { display: grid; gap: 6px; align-content: start; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-top: 4px solid currentColor; border-radius: var(--r2); text-decoration: none; }
.tonecard__h { display: flex; align-items: center; gap: 8px; font-size: 16px; }
.tonecard__h b { color: var(--ink); }
.tonecard__d { color: var(--ink2); font-size: 14px; line-height: 1.6; }
.tonecard:hover { background: var(--raised); }

/* ── 読みもの ── */
.reads { margin-top: 38px; }
.reads__l { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 12px; list-style: none; padding: 0; margin: 0; }
.read { display: grid; gap: 6px; align-content: start; text-decoration: none; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 10px; }
.read img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 10px; }
.read__t { font-weight: 700; line-height: 1.45; } .read__s { font-size: 13.5px; color: var(--ink2); } .read__d { font-size: 12px; color: var(--ink3); }
.read:hover { border-color: var(--amber); color: var(--ink); }

/* ── コメント（配置だけ。中身の見た目は中央のテーマ） ── */
.talk-tab { position: fixed; right: 14px; bottom: calc(14px + env(safe-area-inset-bottom)); z-index: 45; min-height: 46px; padding: 8px 18px; border-radius: 999px; border: 0; background: var(--amber); color: var(--amber-ink); font-weight: 700; }
.talk { position: fixed; z-index: 60; right: 0; bottom: 0; left: 0; height: min(78vh, 640px); display: flex; flex-direction: column; background: var(--surface); border-top: 1px solid var(--line2); border-radius: var(--r) var(--r) 0 0; }
.talk__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.talk__tabs { display: inline-flex; border: 1px solid var(--line2); border-radius: 999px; overflow: hidden; }
.talk__tabs button { border: 0; background: none; padding: 7px 14px; font-weight: 700; font-size: 14px; color: var(--ink2); }
.talk__tabs button[aria-pressed="true"] { background: var(--amber); color: var(--amber-ink); }
.talk__slot { flex: 1 1 auto; overflow: auto; padding: 12px; }

/* ── キーボードの案内・トースト ── */
.keys { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; background: rgba(7, 9, 20, .7); padding: 16px; }
.keys__in { background: var(--surface); border: 1px solid var(--line2); border-radius: var(--r); padding: 20px 22px; max-width: 420px; width: 100%; }
.keys dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 14px 0 18px; }
.keys dt { font: 700 14px/1.6 var(--font-en); background: var(--raised); border: 1px solid var(--line2); border-radius: 8px; padding: 0 9px; justify-self: start; }
.keys dd { margin: 0; color: var(--ink2); }
.toast { position: fixed; left: 50%; bottom: 76px; transform: translateX(-50%); z-index: 90; margin: 0; padding: 9px 18px; border-radius: 999px; background: var(--amber); color: var(--amber-ink); font-weight: 700; font-size: 14px; }

/* ── フッター ── */
.ft { border-top: 1px solid var(--line); background: var(--bg2); margin-top: 30px; }
.ft__in { max-width: var(--max); margin: 0 auto; padding: 26px var(--pad) calc(34px + env(safe-area-inset-bottom)); display: grid; gap: 10px; }
.ft__brand { display: flex; align-items: center; gap: 12px; margin: 0; font-size: 15px; }
.ft__brand img { width: 64px; height: 64px; }
.ft__note { margin: 0; font-size: 13.5px; color: var(--ink2); max-width: 70em; }
.ft__nav { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14px; font-weight: 700; }
.ft__nav a { text-decoration: none; }
.ft__bottom { margin: 0; font-size: 12.5px; color: var(--ink3); }

/* ── 文書のページ（全チャンネル・このサイトについて・記事） ── */
.doc { max-width: 960px; }
.doc--about { max-width: 820px; }
.crumb { margin: 0 0 8px; font-size: 14px; }
.doc__head { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; }
.doc__head img { flex: none; }
.doc__head h1 { font-size: clamp(24px, 3.4vw, 32px); }
.doc__head p { margin: 4px 0 0; color: var(--ink2); }
.doc__n { font: 500 13px/1 var(--font-en); color: var(--ink3); margin-left: 6px; }
.doc h2 { font-size: 21px; margin: 34px 0 10px; padding-left: 14px; position: relative; }
.doc h2::before { content: ""; position: absolute; left: 0; top: .18em; bottom: .18em; width: 5px; border-radius: 3px; background: var(--amber); }
.doc h2.grp { font-size: 17px; margin-top: 26px; }
.doc ul, .doc ol { padding-left: 1.3em; }
.doc li { margin: 6px 0; }
.doc__hero { display: block; width: 100%; border-radius: var(--r); border: 1px solid var(--line); margin: 6px 0 12px; }
.doc__date { color: var(--ink3); font-size: 13px; margin-top: 30px; }
.doc__tones { display: grid; gap: 8px; padding: 0 !important; list-style: none; }
.doc__tones li { display: flex; gap: 10px; align-items: baseline; margin: 0; }
.rows { list-style: none; padding: 0 !important; margin: 0; display: grid; gap: 8px; }
.row { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r2); padding: 11px 13px; margin: 0 !important; scroll-margin-top: calc(var(--hd) + 10px); }
.row:target { border-color: var(--amber); background: var(--amber-soft); }
.row__h { display: flex; align-items: center; gap: 11px; }
.row__n { display: block; line-height: 1.4; }
.row__m { display: block; font-size: 12.5px; color: var(--ink2); }
.row__why { margin: 8px 0 4px; font-size: 14px; color: var(--ink2); }
.row__l { margin: 0; font-size: 14px; font-weight: 700; }
.cats { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 10px; }
.cats li { margin: 0; }
.cats a { display: grid; grid-template-columns: 64px 1fr; gap: 2px 12px; align-items: center; padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); text-decoration: none; color: var(--ink); height: 100%; }
.cats a img { grid-row: 1 / span 3; }
.cats a span { font-size: 13px; color: var(--ink2); line-height: 1.5; }
.cats a:hover { border-color: var(--amber); }
.article { max-width: 760px; }
.article h1 { font-size: clamp(25px, 3.6vw, 34px); margin: 6px 0 12px; }
.article figure { margin: 18px 0; }
.article figure img { width: 100%; border-radius: var(--r); }
.article .yt { position: relative; aspect-ratio: 16 / 9; margin: 18px 0; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line2); }
.article .yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.article blockquote { margin: 16px 0; padding: 10px 16px; border-left: 4px solid var(--amber); background: var(--surface); border-radius: 0 var(--r2) var(--r2) 0; }
.pr { font-size: 13px; color: var(--ink2); border: 1px solid var(--line2); border-radius: var(--r2); padding: 8px 12px; }

/* ── 広い画面 ── */
@media (min-width: 1040px) {
  .stage { grid-template-columns: minmax(0, 1fr) 372px; }
  .picks { position: relative; align-self: stretch; padding: 12px 6px 12px 12px; }
  .picks__live, .picks__fallback { position: absolute; inset: 12px 6px 12px 12px; display: flex; flex-direction: column; }
  .js .picks__fallback.is-shown { display: flex; }
  .picks__list { flex: 1 1 auto; flex-direction: column; gap: 4px; overflow: hidden auto; padding: 0 6px 0 0; scroll-snap-type: none; }
  .picks__list > * { flex: none; }
  .picks .vc { grid-template-columns: 150px minmax(0, 1fr); gap: 10px; align-items: start; }
  .picks .vc__t { -webkit-line-clamp: 3; font-size: 13.5px; }
  .moods { display: grid; grid-template-columns: repeat(auto-fit, minmax(132px, 1fr)); overflow: visible; }
  .mood { flex: none; }
  .talk { left: auto; top: 0; height: auto; width: min(420px, 100vw); border-top: 0; border-left: 1px solid var(--line2); border-radius: 0; }
  .talk-tab { right: 22px; bottom: 22px; }
}
/* ── 狭い画面: プレーヤーを上に貼り付ける（ヘッダーは流す） ── */
@media (max-width: 1039.98px) {
  .hd { position: static; flex-wrap: wrap; gap: 8px 10px; padding-top: 6px; padding-bottom: 8px; min-height: 0; }
  .brand__tag { display: none; }
  .search { order: 3; flex: 1 1 100%; max-width: none; margin: 0; }
  .search input { height: 40px; }
  .hd__nav { gap: 4px 12px; font-size: 13.5px; margin-left: auto; }
  /* .stage と .stage__main を「無いもの」にして、プレーヤーを main の直下に置いたのと同じにする。
     こうしないと、貼り付きが .stage の中でしか効かず、一覧まで繰るとプレーヤーが流れていく（2026-11-24 実測・LSN-0536） */
  .stage, .stage__main { display: contents; }
  .vp { position: sticky; top: 0; z-index: 30; border-radius: 0 0 var(--r2) var(--r2); margin: 0 calc(var(--pad) * -1); width: auto;
    aspect-ratio: auto; height: min(56.25vw, 46vh); }      /* 横向きの電話など背の低い画面では、高さを抑える（中の映像は YouTube が黒帯で合わせる） */
  .now { margin-top: 12px; flex-wrap: wrap; }
  .now__act { flex: 1 1 100%; justify-content: flex-start; }
  .now__msg, .info, .noscript, .picks { margin-top: 12px; }
  .guide { scroll-margin-top: calc(min(56.25vw, 46vh) + 8px); }
  .row { scroll-margin-top: 12px; }
  .hello__who { align-items: flex-start; }
  .mosha { width: 84px; height: 84px; }
  .bubble::before { top: 26px; }
  main { padding-top: 0; }
  .doc { padding-top: 16px; }
}
@media (max-width: 520px) {
  .brand { gap: 6px; }
  .brand__name { font-size: 20px; }
  .brand img { width: 36px; height: 36px; }
  .hd__nav { gap: 4px 9px; }
  .hd__nav a { font-size: 12.5px; }
  .hd__about { display: none; }                    /* 狭い画面ではフッターから（ヘッダーを2段に収めて、プレーヤーを上に寄せる） */
  .langsw button { padding: 5px 9px; font-size: 12.5px; }
  .now__act .btn { min-height: 38px; padding: 5px 12px; font-size: 13px; }
  .shelf__head > img { width: 52px; height: 52px; }
  .seg { margin-left: auto; }
  .doc__head img { width: 60px; height: 60px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ===== 読みもの: YouTube 動画の記事の部品(methods/youtube_blog/templates/article_snippets.html のクラス名のまま) ===== */
.article .lede { font-size: 17px; color: var(--ink); }
.article .video-pick { margin: 22px 0; }
.article .video-frame { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line2); background: #000; }
.article .video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.article .video-pick figcaption { margin-top: 8px; font-size: 13px; color: var(--ink2); }
.article .video-link { font-size: 14px; color: var(--ink2); }
.article blockquote.yt-quote p { margin: 4px 0; }
.article .yt-quote .yt-src { font-size: 13px; color: var(--ink2); }
.article q.yt-quote { color: var(--ink); }
.article .yt-sources { margin-top: 34px; padding-top: 6px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink2); }
.article .yt-sources h2 { font-size: 18px; }
.article .article-illust img { border: 1px solid var(--line); }
.article .kw-pr-note { font-size: 13px; color: var(--ink2); border: 1px solid var(--line2); border-radius: var(--r2); padding: 8px 12px; }

/* ===== 図解(class="yt-fig")。本体は methods/youtube_blog/templates/yt-fig.css の写し(2026-11-25・DEC-0022)。色だけ下の上書きで夜の地に合わせる ===== */
/* 図解ブロック(class="yt-fig")の見た目。FIGURES.md §5。部品の形は templates/figure_snippets.html。
   - サイトの CSS に 1 回だけ入れる(生成器のあるサイトはサイトの CSS へ。手書きのサイトは記事の <style> へ)。
   - 色はこの 8 つの変数だけで決まる。サイトの色に合わせるときは、サイトの CSS で .yt-fig の --fig-* を上書きする。
     ここの値そのものは書き換えない(tools/figure_shot.py が、この既定の値で 390px と 1440px の見え方を確かめてある)。
   - クラス名と data- 属性は tools/figure_check.py と tools/figure_shot.py が見ているので変えない。
   - JS なし・外部の画像やフォントなし。文字はすべて本物の文字(画像にしない)。 */
.yt-fig {
  --fig-ink: #2a2621;        /* 文字 */
  --fig-ink-2: #5c554a;      /* 注記・出所 */
  --fig-line: #d9d3c7;       /* 罫線・枠 */
  --fig-surface: #ffffff;    /* 図の地 */
  --fig-wash: #f2eee6;       /* 薄い面(棒の溝・見出しの行) */
  --fig-mute: #a29a8c;       /* 目立たせない棒 */
  --fig-accent: #4a6b2a;     /* 目立たせる 1 つ */
  --fig-accent-wash: #eaf0df;
  margin: 2em 0; padding: 16px; box-sizing: border-box; max-width: 100%;
  border: 1px solid var(--fig-line); border-radius: 10px;
  background: var(--fig-surface); color: var(--fig-ink);
  font-size: 14px; line-height: 1.6; overflow-wrap: anywhere;
}
.yt-fig *, .yt-fig *::before, .yt-fig *::after { box-sizing: border-box; }
.yt-fig .fig-title { display: block; margin: 0 0 12px; font-size: 16px; font-weight: 700; line-height: 1.5; color: var(--fig-ink); }
.yt-fig .fig-body { margin: 0; padding: 0; }
.yt-fig .fig-note, .yt-fig .fig-src { margin: 10px 0 0; font-size: 12px; line-height: 1.6; color: var(--fig-ink-2); }
.yt-fig .fig-src { margin-top: 4px; }
figure.yt-fig p, figure.yt-fig li { font-size: inherit; line-height: inherit; }   /* サイトの「.read p」などに負けないよう figure を付けてある */
.yt-fig ul, .yt-fig ol { list-style: none; margin: 0; padding: 0; }
.yt-fig b { font-weight: 700; }
.yt-fig .fig-tag { display: block; margin-bottom: 4px; font-size: 12px; font-weight: 700; color: var(--fig-ink-2); }
.yt-fig [data-em] > .fig-tag { color: var(--fig-accent); }

/* 1. meter — 数量・割合を比べる。棒は 0 から。長さ = --v ÷ --max(既定 100) */
.yt-fig .fig-meter { display: grid; gap: 10px; }
.yt-fig .fig-meter .fig-row { display: grid; grid-template-columns: minmax(0, 11em) minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; }
.yt-fig .fig-meter .fig-name { min-width: 0; }
.yt-fig .fig-meter .fig-name small { display: block; font-size: 12px; font-weight: 400; color: var(--fig-ink-2); }   /* 分母・時点など、行ごとに違う条件 */
.yt-fig .fig-meter .fig-bar { display: block; min-width: 0; height: 14px; background: var(--fig-wash); border-radius: 0 4px 4px 0; }
.yt-fig .fig-meter .fig-bar i { display: block; height: 100%; width: calc(var(--v) / var(--max, 100) * 100%); max-width: 100%;
  background: var(--fig-mute); border-radius: 0 4px 4px 0; }
.yt-fig .fig-meter .fig-row[data-em] .fig-bar i { background: var(--fig-accent); }
.yt-fig .fig-meter .fig-row[data-em] .fig-name { font-weight: 700; }
.yt-fig .fig-meter .fig-val { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; text-align: right; min-width: 3.5em; }

/* 2. compare / matrix — 表。列は見出しの列を入れて 4 つまで(390px で読める幅)。横スクロールさせない */
.yt-fig table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: inherit; }
.yt-fig th, .yt-fig td { padding: 8px; border-top: 1px solid var(--fig-line); text-align: left; vertical-align: top; font-weight: 400; }
.yt-fig thead th { border-top: 0; background: var(--fig-wash); font-size: 12px; font-weight: 700; color: var(--fig-ink-2); }
.yt-fig tbody th { font-weight: 700; width: 26%; }
.yt-fig td[data-em], .yt-fig th[data-em] { background: var(--fig-accent-wash); }
.yt-fig .fig-matrix td { border: 1px solid var(--fig-line); }
.yt-fig .fig-matrix thead th, .yt-fig .fig-matrix tbody th { text-align: center; vertical-align: middle; background: var(--fig-wash); font-size: 12px; color: var(--fig-ink-2); border: 1px solid var(--fig-line); }

/* 3. steps / timeline — 順番。番号(steps)か、時点(timeline) */
.yt-fig .fig-steps { counter-reset: figstep; display: grid; gap: 0; }
.yt-fig .fig-steps > li { counter-increment: figstep; position: relative; padding: 0 0 14px 40px; min-height: 28px; }
.yt-fig .fig-steps > li:last-child { padding-bottom: 0; }
.yt-fig .fig-steps > li::before { content: counter(figstep); position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 50%;
  background: var(--fig-accent); color: #fff; font-size: 13px; font-weight: 700; line-height: 26px; text-align: center; font-variant-numeric: tabular-nums; }
.yt-fig .fig-steps > li::after { content: ""; position: absolute; left: 12px; top: 28px; bottom: 2px; width: 2px; background: var(--fig-line); }
.yt-fig .fig-steps > li:last-child::after { display: none; }
.yt-fig .fig-steps b, .yt-fig .fig-steps time { display: block; }
.yt-fig .fig-steps time { font-size: 12px; font-weight: 700; color: var(--fig-ink-2); font-variant-numeric: tabular-nums; }
.yt-fig .fig-steps.fig-timeline > li { padding-left: 28px; }
.yt-fig .fig-steps.fig-timeline > li::before { content: ""; left: 3px; top: 5px; width: 12px; height: 12px; }
.yt-fig .fig-steps.fig-timeline > li::after { left: 8px; top: 19px; }

/* 4. scope — 範囲。中にあるもの(実線・色つき)と、外にあるもの(点線・地のまま) */
/* 5. pair — 対。2 つを並べる(読みがちな読み方と実際・前と後・言い分と資料) */
.yt-fig .fig-scope, .yt-fig .fig-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.yt-fig .fig-in, .yt-fig .fig-out, .yt-fig .fig-side { min-width: 0; padding: 12px; border-radius: 8px; }
.yt-fig .fig-in { border: 2px solid var(--fig-accent); background: var(--fig-accent-wash); }
.yt-fig .fig-in > .fig-tag { color: var(--fig-accent); }
.yt-fig .fig-out { border: 2px dashed var(--fig-mute); }
.yt-fig .fig-scope li { position: relative; padding-left: 1.1em; }
.yt-fig .fig-scope li::before { content: "・"; position: absolute; left: 0; }
.yt-fig .fig-side { border: 1px solid var(--fig-line); background: var(--fig-wash); }
.yt-fig .fig-side[data-em] { border: 2px solid var(--fig-accent); background: var(--fig-accent-wash); }
.yt-fig .fig-side p { margin: 0; }
.yt-fig .fig-pair[data-arrow] { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; }
.yt-fig .fig-pair .fig-arrow { font-size: 18px; color: var(--fig-ink-2); line-height: 1; }
.yt-fig .fig-pair .fig-arrow::before { content: "→"; }

/* 6. flow — つながり。矢印は「だから・すると・次に」が台帳にある所だけ(FIGURES.md §4)。fan は 1 つから複数へ */
.yt-fig .fig-flow { display: flex; flex-wrap: wrap; align-items: stretch; gap: 8px 0; }
.yt-fig .fig-flow > li { display: flex; align-items: center; min-width: 0; }
.yt-fig .fig-node { display: block; min-width: 0; padding: 8px 12px; border: 1px solid var(--fig-line); border-radius: 8px; background: var(--fig-wash); }
.yt-fig .fig-node[data-em] { border: 2px solid var(--fig-accent); background: var(--fig-accent-wash); font-weight: 700; }
.yt-fig .fig-flow > li + li::before { content: "→"; padding: 0 8px; color: var(--fig-ink-2); font-size: 16px; line-height: 1; }
.yt-fig .fig-fan { display: grid; grid-template-columns: minmax(0, auto) auto minmax(0, 1fr); align-items: center; gap: 12px; }
.yt-fig .fig-fan > .fig-arrow::before { content: "→"; font-size: 18px; color: var(--fig-ink-2); }
.yt-fig .fig-fan > ul { display: grid; gap: 8px; }

/* 7. formula — 式。何を何で割った数か、のように数え方を見せる */
.yt-fig .fig-formula { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.yt-fig .fig-term { display: block; min-width: 0; padding: 8px 12px; border-radius: 8px; background: var(--fig-wash); font-weight: 700; text-align: center; }
.yt-fig .fig-term[data-em] { background: var(--fig-accent-wash); border: 2px solid var(--fig-accent); }
.yt-fig .fig-term small { display: block; font-size: 12px; font-weight: 400; color: var(--fig-ink-2); }
.yt-fig .fig-op { font-size: 18px; font-weight: 700; color: var(--fig-ink-2); }
.yt-fig .fig-opgroup { display: flex; align-items: center; gap: 8px; min-width: 0; }   /* 記号と次の項を離さない */

/* 8. number — 1 つの数字。数字の横に、何を数えた数かを必ず書く */
.yt-fig .fig-number { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 16px; }
.yt-fig .fig-big { font-size: 44px; font-weight: 700; line-height: 1.1; color: var(--fig-accent); white-space: nowrap; }
.yt-fig .fig-big small { font-size: 20px; }
.yt-fig .fig-what { min-width: 0; }

/* 9. svg — 上の部品で描けない形だけ。文字は <text>、色は currentColor と変数 */
.yt-fig svg { display: block; width: 100%; height: auto; max-width: 400px; margin: 0 auto; color: var(--fig-ink); }   /* viewBox の幅は 360 前後に。広げると文字まで大きくなる */
.yt-fig svg text { font-family: inherit; fill: currentColor; }

@media (max-width: 520px) {
  .yt-fig { padding: 12px; }
  .yt-fig .fig-meter .fig-row { grid-template-columns: minmax(0, 1fr) auto; }
  .yt-fig .fig-meter .fig-name { grid-column: 1 / -1; }
  .yt-fig .fig-scope, .yt-fig .fig-pair, .yt-fig .fig-pair[data-arrow], .yt-fig .fig-fan { grid-template-columns: minmax(0, 1fr); }
  .yt-fig .fig-pair .fig-arrow, .yt-fig .fig-fan > .fig-arrow { text-align: center; }
  .yt-fig .fig-pair .fig-arrow::before, .yt-fig .fig-fan > .fig-arrow::before { content: "↓"; }
  .yt-fig .fig-flow { flex-direction: column; gap: 0; }
  .yt-fig .fig-flow > li { flex-direction: column; align-items: stretch; }
  .yt-fig .fig-flow > li + li::before { content: "↓"; padding: 4px 0; text-align: center; }
  .yt-fig .fig-number { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .yt-fig th, .yt-fig td { padding: 6px; }
  .yt-fig tbody th { width: 24%; }
}

/* 図解の色: FancyNews の夜の地に合わせる(8 つの変数だけを上書き) */
.yt-fig {
  --fig-ink: var(--ink); --fig-ink-2: var(--ink2); --fig-line: var(--line2); --fig-surface: var(--surface);
  --fig-wash: var(--raised); --fig-mute: var(--ink3); --fig-accent: var(--amber); --fig-accent-wash: rgba(169, 155, 255, .22);
}
