/* 推しにゅ〜 WEB版（スマートニュース級の情報密度 × アップルらいくの質感） */

/* ページ遷移のクロスフェード（スワイプでのタブ移動を滑らかに見せる。
   View Transitions対応ブラウザのみ・視差効果を減らす設定では無効） */
@media (prefers-reduced-motion: no-preference) {
    @view-transition { navigation: auto; }
    ::view-transition-old(root), ::view-transition-new(root) { animation-duration: 0.18s; }
}

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--label);
    line-height: 1.5;
    font-size: 15px;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ---- ヘッダ（すりガラス・52px固定） ---- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: color-mix(in srgb, var(--surface) 85%, transparent);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 0.5px solid var(--separator);
}
.site-header__inner {
    display: flex;
    align-items: center;
    height: 84px;
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 16px;
}
.brand { display: inline-flex; align-items: center; font-size: 28px; font-weight: 800; color: var(--accent); }
.brand__img { height: 72px; width: auto; display: block; }

/* ---- チャンネルタブ（スマートニュース式の色付きタブブロック） ---- */
.tab-strip {
    position: sticky;
    top: 84px;
    z-index: 90;
    background: var(--bg);
    border-bottom: 0.5px solid var(--separator);
}
.tab-strip__inner {
    display: flex;
    gap: 8px;
    max-width: 1080px;
    margin: 0 auto;
    padding: 8px 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
/* モバイル: 横スクロール（スクロールバーは細く表示して切れていないことを分からせる） */
.tab-strip__inner::-webkit-scrollbar { height: 3px; }
.tab-strip__inner::-webkit-scrollbar-thumb { background: var(--fill); border-radius: 2px; }
/* デスクトップ: 折り返して全タブを常時表示（マウスでは横スクロールしづらいため） */
@media (min-width: 768px) {
    .tab-strip__inner { flex-wrap: wrap; overflow-x: visible; }
}
.tab-block {
    flex: 0 0 auto;
    background: var(--tab-color, var(--accent));
    color: #fff;
    font-size: 15px;
    font-weight: 800;
    padding: 11px 17px;
    border-radius: 10px;
    white-space: nowrap;
    opacity: 0.7;
    transition: opacity 0.12s ease-out, box-shadow 0.12s ease-out;
}
.tab-block.is-active {
    opacity: 1;
    box-shadow: 0 2px 12px color-mix(in srgb, var(--tab-color, var(--accent)) 55%, transparent);
}
.tab-block:active { opacity: 0.9; }

/* ---- 2カラムレイアウト（本文＋サイドバー） ---- */
.layout {
    display: flex;
    gap: 20px;
    max-width: 1080px;
    margin: 0 auto;
    padding: 12px 16px 0;
}
.feed-main {
    flex: 1;
    min-width: 0;
    background: var(--surface);
    border-radius: 12px;
    padding: 0 14px;
    overflow: hidden;
}
.sidebar { display: none; }
@media (min-width: 1024px) {
    .sidebar { display: block; width: 300px; flex: 0 0 300px; }
}
@media (max-width: 679px) {
    .layout { padding: 0; }
    .feed-main { border-radius: 0; }
}

/* ---- ヒーローカード ---- */
.hero-card { display: block; padding: 12px 0; border-bottom: 0.5px solid var(--separator); }
.hero-card__image {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 12px;
    background: var(--fill);
}
.hero-card__title { font-size: 21px; font-weight: 800; line-height: 1.38; margin-top: 10px; }
.hero-card:active { opacity: 0.7; }

/* ---- ブロック区切り（背景色の帯） ---- */
.block-divider { height: 8px; background: var(--bg); margin: 0 -14px; }

/* ---- タイルグリッド（2列・スマートニュース式モザイク） ---- */
.tile-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px 12px;
    padding: 12px 0;
}
.tile-card { display: block; min-width: 0; }
.tile-card:active { opacity: 0.7; }
.tile-card__image {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 10px;
    background: var(--fill);
}
.tile-card__image--ph {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--accent-soft), var(--fill));
    color: var(--accent);
    font-size: 13px;
    font-weight: 800;
}
.tile-card__title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
    margin-top: 7px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.tile-card__meta {
    font-size: 11px;
    color: var(--secondary-label);
    margin-top: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ---- 記事行（スマートニュース式: 太字見出し＋右サムネ） ---- */
.list-block { border-top: 0.5px solid var(--separator); }
.article-card {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 14px 0;
    border-bottom: 0.5px solid var(--separator);
}
.list-block .article-card:last-child { border-bottom: none; }
.article-card:active { opacity: 0.7; }
.article-card__body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 84px;
}
.article-card__title {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.42;
    letter-spacing: 0.01em;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.article-card__thumb {
    flex: 0 0 116px;
    width: 116px;
    height: 84px;
    object-fit: cover;
    border-radius: 8px;
    background: var(--fill);
}
.card-meta {
    display: flex;
    align-items: center;
    margin-top: 8px;
    font-size: 12px;
    color: var(--secondary-label);
    white-space: nowrap;
    overflow: hidden;
}
.card-meta__source {
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ---- サイドバー ---- */
.side-box {
    background: var(--surface);
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 16px;
}
.side-box__title {
    font-size: 15px;
    font-weight: 800;
    padding-left: 10px;
    border-left: 3px solid var(--accent);
    margin-bottom: 10px;
}
.side-box__text { font-size: 13px; color: var(--secondary-label); }
.rank-row {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 8px 0;
    border-bottom: 0.5px solid var(--separator);
}
.rank-row:last-child { border-bottom: none; }
.rank-row:active { opacity: 0.7; }
.rank-row__num {
    flex: 0 0 20px;
    font-size: 16px;
    font-weight: 800;
    font-style: italic;
    color: var(--tertiary-label);
    text-align: center;
}
.rank-row__num.is-top { color: var(--accent); }
.rank-row__title {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ---- 記事・タレントページ（読み物は1カラム幅） ---- */
.narrow { max-width: 680px; margin: 0 auto; padding: 16px; }

.article-page__breadcrumb { font-size: 13px; color: var(--secondary-label); margin-bottom: 14px; }
.article-page__breadcrumb a { color: var(--accent); }
.article-page__title { font-size: 25px; font-weight: 800; line-height: 1.35; margin-bottom: 8px; }
.article-page__image {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 12px;
    margin: 14px 0;
    background: var(--fill);
}
.article-page__summary { font-size: 16px; line-height: 1.7; margin-bottom: 20px; }

.btn-primary {
    display: block;
    text-align: center;
    background: var(--accent);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    padding: 14px 24px;
    border-radius: 999px;
    margin: 20px 0;
    transition: opacity 0.1s ease-out;
}
.btn-primary:active { opacity: 0.7; }

.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.talent-chip {
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 13px;
    font-weight: 700;
}

.section-title {
    font-size: 17px;
    font-weight: 800;
    padding-left: 10px;
    border-left: 3px solid var(--accent);
    margin: 26px 0 6px;
}
.related { border-top: 0.5px solid var(--separator); margin-top: 18px; }

.talent-header { padding: 14px 0; border-bottom: 0.5px solid var(--separator); }
.talent-header__name { font-size: 26px; font-weight: 800; }
.talent-header__meta { color: var(--secondary-label); font-size: 14px; margin-top: 2px; }
.talent-header__agency { color: var(--accent); font-weight: 600; }
.talent-header__agency:active { opacity: 0.7; }

/* ---- 箱（事務所）ページ ---- */
.agency-name { padding-left: 12px; border-left: 4px solid var(--agency-color, var(--accent)); }
.agency-official { color: var(--accent); font-weight: 600; }
.talent-group__link { color: inherit; }
.talent-group__link:active { opacity: 0.7; }

.stream-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 0.5px solid var(--separator);
}
.stream-row:active { opacity: 0.7; }
.stream-row__badge {
    flex: 0 0 auto;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    background: var(--fill);
    color: var(--secondary-label);
}
.stream-row__badge.is-live { background: var(--live); color: #fff; }
.stream-row__title {
    flex: 1;
    min-width: 0;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.stream-row__time { font-size: 12px; color: var(--secondary-label); }

/* ---- 記事本文（独自記事・AI生成記事の共通タイポグラフィ／Apple風の上品なトーン。
       h1は使わない＝ページ見出し(.article-page__title)がh1、本文はh2からの階層） ---- */
.content-body { font-size: 16px; line-height: 1.9; color: var(--label); margin-bottom: 24px; overflow-wrap: anywhere; }
.content-body > :first-child { margin-top: 0; }

/* 見出し階層: h2=章見出し（ブランドピンクのアクセントバー＋下罫・上マージン広め）/ h3=節見出し / h4=小見出し */
.content-body h2 {
    font-size: 22px;
    font-weight: 800;
    line-height: 1.4;
    letter-spacing: 0.01em;
    margin: 1.9em 0 0.7em;
    padding: 0 0 0.4em 14px;
    border-left: 4px solid var(--accent);
    border-bottom: 0.5px solid var(--separator);
}
.content-body h3 {
    font-size: 19px;
    font-weight: 800;
    line-height: 1.45;
    margin: 1.6em 0 0.5em;
    padding-left: 11px;
    border-left: 3px solid color-mix(in srgb, var(--accent) 50%, var(--separator));
}
.content-body h4 { font-size: 16.5px; font-weight: 700; line-height: 1.5; margin: 1.3em 0 0.4em; }
.content-body h5, .content-body h6 { font-size: 15px; font-weight: 700; margin: 1.2em 0 0.3em; color: var(--secondary-label); }

.content-body p { margin: 0.9em 0; }
.content-body ul, .content-body ol { margin: 0.9em 0; padding-left: 1.5em; }
.content-body li { margin: 0.4em 0; }
.content-body ul li::marker { color: var(--accent); }
.content-body ol li::marker { color: var(--accent); font-weight: 700; }
.content-body dl { margin: 0.9em 0; }
.content-body dt { font-weight: 700; margin-top: 0.6em; }
.content-body dd { margin: 0.2em 0 0.6em 1.2em; color: var(--secondary-label); }

.content-body a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.content-body a:active { opacity: 0.7; }
.content-body strong, .content-body b { font-weight: 700; }
.content-body em, .content-body i { font-style: italic; }
.content-body small { font-size: 0.86em; color: var(--secondary-label); }

.content-body img { max-width: 100%; height: auto; border-radius: var(--radius-thumb); margin: 1em 0; }
.content-body figure { margin: 1em 0; }
.content-body figure img { margin: 0 auto; }
.content-body figcaption { font-size: 13px; color: var(--secondary-label); text-align: center; margin-top: 6px; }

.content-body blockquote {
    margin: 1.1em 0;
    padding: 0.7em 14px;
    border-left: 4px solid var(--accent);
    border-radius: 0 8px 8px 0;
    background: var(--accent-soft);
    color: var(--secondary-label);
}
.content-body blockquote p:first-child { margin-top: 0; }
.content-body blockquote p:last-child { margin-bottom: 0; }

.content-body pre { margin: 0.9em 0; padding: 12px 14px; background: var(--fill); border-radius: 8px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.content-body code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.92em; }
.content-body :not(pre) > code { background: var(--fill); border-radius: 4px; padding: 0.1em 0.4em; }

/* 表: 罫線・ヘッダ背景・横スクロール対応（このtable自体がスワイプJSの除外対象＝display:block/overflow-xを維持する） */
.content-body table {
    border-collapse: collapse;
    margin: 1.1em 0;
    max-width: 100%;
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    font-size: 14px;
}
.content-body table th, .content-body table td { border: 0.5px solid var(--separator); padding: 8px 12px; text-align: left; vertical-align: top; }
.content-body table th { background: var(--accent-soft); font-weight: 700; white-space: nowrap; }
.content-body table caption { font-size: 13px; color: var(--secondary-label); text-align: left; margin-bottom: 6px; }
.content-body table tbody tr:nth-child(2n) td { background: color-mix(in srgb, var(--fill) 35%, transparent); }
.content-body hr { border: none; border-top: 0.5px solid var(--separator); margin: 1.6em 0; }

/* ---- 広告カード（「広告」表記は自動付与・ステマ規制対応） ---- */
.ad-card {
    display: block;
    padding: 12px 0;
    border-bottom: 0.5px solid var(--separator);
}
.ad-card:active { opacity: 0.8; }
.ad-card__img {
    width: 100%;
    border-radius: 12px;
    background: var(--fill);
}
.ad-card__html { overflow: hidden; border-radius: 12px; }
.ad-card__label {
    display: inline-block;
    margin-top: 6px;
    font-size: 11px;
    color: var(--secondary-label);
    border: 0.5px solid var(--separator);
    border-radius: 4px;
    padding: 1px 6px;
}
.side-box--ad { padding: 10px 12px; }
.side-box--ad .ad-card { padding: 0; border-bottom: none; }

/* ---- 広告クッションページの注記 ---- */
.ad-article-note {
    font-size: 12px;
    color: var(--secondary-label);
    text-align: center;
    margin-bottom: 24px;
}

/* ---- 記事風（ネイティブ）広告のPR表記 ---- */
.ad-pr-label {
    flex: 0 0 auto;
    margin-right: 6px;
    font-size: 10px;
    font-weight: 700;
    color: var(--secondary-label);
    border: 0.5px solid var(--separator);
    border-radius: 4px;
    padding: 0 5px;
    line-height: 1.6;
}

/* ---- 空状態・ページネーション・フッタ ---- */
.empty-state { text-align: center; padding: 48px 16px; }
.empty-state__title { font-size: 16px; font-weight: 700; }
.empty-state__text { font-size: 13px; color: var(--secondary-label); margin-top: 4px; }

.pagination { display: flex; justify-content: space-between; gap: 12px; padding: 16px 0 20px; }
.pagination__btn {
    flex: 1;
    text-align: center;
    padding: 10px;
    border-radius: 10px;
    background: var(--bg);
    font-size: 14px;
    font-weight: 700;
    color: var(--accent);
}
.pagination__btn.is-disabled { color: var(--tertiary-label); pointer-events: none; }

.site-footer {
    max-width: 1080px;
    margin: 24px auto 0;
    padding: 20px 16px calc(32px + env(safe-area-inset-bottom));
    border-top: 0.5px solid var(--separator);
    text-align: center;
}
.site-footer__note { font-size: 12px; color: var(--secondary-label); }
.site-footer__nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px 16px;
    margin-top: 12px;
    font-size: 12px;
    font-weight: 600;
    color: var(--secondary-label);
}
.site-footer__nav a:active { opacity: 0.7; }
.site-footer__sponsor { font-size: 11px; color: var(--tertiary-label); margin-top: 12px; }
.site-footer__copy { font-size: 11px; color: var(--tertiary-label); margin-top: 6px; }

/* ---- ヘッダ検索（すりガラスヘッダ右側のピル型入力） ---- */
.header-search { margin-left: auto; flex: 0 1 220px; min-width: 0; }
.header-search__input {
    width: 100%;
    height: 36px;
    padding: 0 14px;
    border: none;
    border-radius: 999px;
    background: var(--fill);
    color: var(--label);
    font-size: 14px;
    font-family: var(--font-body);
    -webkit-appearance: none;
    appearance: none;
}
.header-search__input:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.header-search__input::placeholder { color: var(--secondary-label); }

/* ---- ヘッダ歯車（マイページ導線・検索の右隣） ---- */
.header-gear {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
    width: 36px;
    height: 36px;
    margin-left: 8px;
    border-radius: 999px;
    background: var(--fill);
    color: var(--secondary-label);
}
.header-gear svg { width: 20px; height: 20px; }
.header-gear:hover { color: var(--accent); }
.header-gear:focus-visible { outline: 2px solid var(--accent); outline-offset: 0; }

/* ---- 検索ページ ---- */
.search-form { display: flex; gap: 8px; margin: 8px 0 4px; }
.search-form__input {
    flex: 1;
    min-width: 0;
    height: 44px;
    padding: 0 16px;
    border: none;
    border-radius: 12px;
    background: var(--surface);
    color: var(--label);
    font-size: 16px;
    font-family: var(--font-body);
    -webkit-appearance: none;
    appearance: none;
}
.search-form__input:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.search-form__btn {
    flex: 0 0 auto;
    padding: 0 20px;
    border: none;
    border-radius: 12px;
    background: var(--accent);
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    font-family: var(--font-body);
    cursor: pointer;
}
.search-form__btn:active { opacity: 0.8; }

/* ---- ページ導入文・週間ランキング ---- */
.page-lead { font-size: 13px; color: var(--secondary-label); margin: 4px 0 8px; }
.ranking-row { display: flex; gap: 12px; align-items: flex-start; }
.ranking-row__num {
    flex: 0 0 28px;
    padding-top: 16px;
    font-size: 22px;
    font-weight: 800;
    font-style: italic;
    color: var(--tertiary-label);
    text-align: center;
}
.ranking-row__num.is-top { color: var(--accent); }
.ranking-row__card { flex: 1; min-width: 0; }

/* ---- タレント一覧（箱ごとのグループ＋2列グリッド） ---- */
.talent-group__title {
    font-size: 15px;
    font-weight: 800;
    padding-left: 10px;
    border-left: 3px solid var(--accent);
    margin: 24px 0 10px;
}
.talent-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
@media (min-width: 680px) {
    .talent-grid { grid-template-columns: 1fr 1fr 1fr; }
}
.talent-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: var(--surface);
    border-radius: 12px;
    padding: 12px 14px;
}
.talent-cell:active { opacity: 0.7; }
.talent-cell__name { font-size: 14px; font-weight: 700; }
.talent-cell__meta { font-size: 11px; color: var(--secondary-label); }

/* ---- 固定ページ（利用規約・プライバシーポリシー等の読み物） ---- */
.prose { background: var(--surface); border-radius: 12px; padding: 20px 18px 24px; font-size: 15px; line-height: 1.8; }
.prose h1 { font-size: 22px; font-weight: 800; margin-bottom: 14px; }
.prose h2 { font-size: 16px; font-weight: 800; margin: 1.6em 0 0.5em; padding-left: 10px; border-left: 3px solid var(--accent); }
.prose p { margin: 0.6em 0; }
.prose ul, .prose ol { margin: 0.6em 0; padding-left: 1.6em; }
.prose li { margin: 0.3em 0; }
.prose a { color: var(--accent); text-decoration: underline; }
.prose-table { width: 100%; border-collapse: collapse; margin: 0.8em 0; }
.prose-table th, .prose-table td { border-bottom: 0.5px solid var(--separator); padding: 10px 8px; text-align: left; font-size: 14px; vertical-align: top; }
.prose-table th { white-space: nowrap; color: var(--secondary-label); font-weight: 600; width: 7em; }
/* 特商法・料金一覧など項目名が長い表（「交換および返品に関するポリシー」等）は見出し列を折り返す */
.prose-table--wide th { white-space: normal; width: 9em; }
@media (max-width: 480px) {
    .prose-table--wide th, .prose-table--wide td { display: block; width: auto; border-bottom: 0; padding: 4px 0; }
    .prose-table--wide td { padding-bottom: 12px; border-bottom: 0.5px solid var(--separator); }
    .prose-table--wide th { padding-top: 12px; }
}
.prose-date { font-size: 13px; color: var(--secondary-label); margin-top: 2em; }
.contact-email { text-align: center; font-size: 18px; font-weight: 700; margin: 1.2em 0; }

/* ---- 会員（ログイン・コード入力・マイページ） ---- */
.auth-card { background: var(--surface); border-radius: 12px; padding: 24px 18px 26px; }
.auth-title { font-size: 22px; font-weight: 800; margin-bottom: 12px; }
.auth-lead { font-size: 14px; color: var(--secondary-label); line-height: 1.8; margin-bottom: 18px; }
.auth-lead strong { color: var(--label); font-weight: 700; }
.auth-form { display: flex; flex-direction: column; gap: 12px; }
.auth-field { display: flex; flex-direction: column; gap: 6px; }
.auth-label { font-size: 13px; font-weight: 600; color: var(--secondary-label); }
.auth-input {
    width: 100%;
    height: 48px;
    padding: 0 14px;
    border: 0.5px solid var(--separator);
    border-radius: 10px;
    background: var(--bg);
    color: var(--label);
    font-size: 16px;
    font-family: var(--font-body);
    -webkit-appearance: none;
    appearance: none;
}
.auth-input:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: transparent; }
.auth-input::placeholder { color: var(--tertiary-label); }
.auth-input--code { font-size: 24px; font-weight: 700; letter-spacing: 0.25em; text-align: center; }
.auth-btn {
    width: 100%;
    height: 48px;
    border: none;
    border-radius: 10px;
    background: var(--accent);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    font-family: var(--font-body);
    cursor: pointer;
    margin-top: 4px;
}
.auth-btn:active { opacity: 0.8; }
.auth-btn--ghost { background: var(--fill); color: var(--label); }
.auth-error { font-size: 13px; color: var(--danger); margin: 2px 0 0; }
.auth-note { font-size: 12px; color: var(--secondary-label); line-height: 1.7; margin-top: 16px; }
.auth-note a { color: var(--accent); text-decoration: underline; }
.auth-flash { font-size: 14px; color: var(--success); margin-bottom: 14px; }

.account-list { margin: 4px 0 18px; }
.account-row { display: flex; gap: 12px; padding: 12px 0; border-bottom: 0.5px solid var(--separator); }
.account-row dt { flex: 0 0 8.5em; font-size: 14px; color: var(--secondary-label); font-weight: 600; }
.account-row dd { flex: 1; min-width: 0; font-size: 15px; word-break: break-all; }
.account-badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--fill); color: var(--secondary-label); }
.account-badge--on { background: color-mix(in srgb, var(--success) 16%, transparent); color: var(--success); }
/* 解禁済みバッジ横の使い方案内 */
.account-hint { display: block; margin-top: 6px; font-size: 13px; color: var(--secondary-label); line-height: 1.6; }
.account-purchase:empty { display: none; }
.account-logout { margin-top: 22px; }

/* ---- タブ追加ボタン（タブバー末尾の丸ボタン） ---- */
.tab-add {
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border: none;
    border-radius: 10px;
    background: var(--fill);
    color: var(--secondary-label);
    font-size: 20px;
    line-height: 1;
    font-family: var(--font-body);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.12s ease-out, color 0.12s ease-out;
}
.tab-add:hover { background: var(--accent-soft); color: var(--accent); }
.tab-add:active { opacity: 0.7; }

/* マイタブ（キーワード収集）で注入されたタブ */
.tab-block--mytab { font-weight: 700; opacity: 0.75; }
.tab-block--mytab.is-active { opacity: 1; }

/* ---- タブ設定モーダル（下からのシート／デスクトップは中央カード） ---- */
.tab-modal { display: none; position: fixed; inset: 0; z-index: 1000; }
.tab-modal.is-open { display: block; }
.tab-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
    animation: tabModalFade 0.2s ease-out;
}
.tab-modal__sheet {
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 100%;
    max-width: 560px;
    max-height: 88vh;
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border-radius: var(--radius-sheet) var(--radius-sheet) 0 0;
    box-shadow: 0 -8px 40px rgba(0, 0, 0, 0.22);
    animation: tabSheetUp 0.26s cubic-bezier(0.22, 1, 0.36, 1);
    padding-bottom: env(safe-area-inset-bottom);
}
@media (min-width: 680px) {
    .tab-modal__sheet {
        bottom: auto;
        top: 50%;
        transform: translate(-50%, -50%);
        border-radius: var(--radius-sheet);
        max-height: 82vh;
        animation: tabSheetPop 0.22s cubic-bezier(0.22, 1, 0.36, 1);
    }
}
@keyframes tabModalFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes tabSheetUp { from { transform: translate(-50%, 100%); } to { transform: translate(-50%, 0); } }
@keyframes tabSheetPop { from { opacity: 0; transform: translate(-50%, -46%); } to { opacity: 1; transform: translate(-50%, -50%); } }
@media (prefers-reduced-motion: reduce) {
    .tab-modal__backdrop, .tab-modal__sheet { animation: none; }
}

.tab-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px 12px;
    border-bottom: 0.5px solid var(--separator);
    background: var(--surface);
    border-radius: inherit;
}
.tab-modal__title { font-size: 18px; font-weight: 800; }
.tab-modal__close {
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 50%;
    background: var(--fill);
    color: var(--secondary-label);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.tab-modal__close:active { opacity: 0.7; }
.tab-modal__body { overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 0 18px 22px; }

.tab-modal__section { padding: 18px 0; border-bottom: 0.5px solid var(--separator); }
.tab-modal__section:last-child { border-bottom: none; }
.tab-modal__section-title { font-size: 15px; font-weight: 800; margin-bottom: 4px; padding-left: 10px; border-left: 3px solid var(--accent); }
.tab-modal__note, .tab-modal__hint { font-size: 12px; color: var(--secondary-label); margin: 6px 0; line-height: 1.6; }
.tab-modal__empty { font-size: 13px; color: var(--secondary-label); padding: 10px 0; }

/* チャンネル（カタログ）チェックリスト */
.tab-catalog-list { list-style: none; margin: 8px 0 0; padding: 0; }
.tab-catalog-item { border-bottom: 0.5px solid var(--separator); }
.tab-catalog-item:last-child { border-bottom: none; }
.tab-catalog-label { display: flex; align-items: center; gap: 10px; padding: 11px 2px; cursor: pointer; }
.tab-catalog-check { width: 20px; height: 20px; accent-color: var(--accent); flex: 0 0 auto; }
.tab-catalog-swatch { width: 12px; height: 12px; border-radius: 3px; background: var(--tab-color, var(--accent)); flex: 0 0 auto; }
.tab-catalog-name { font-size: 15px; font-weight: 600; }

/* マイタブ一覧 */
.mytab-list { list-style: none; margin: 6px 0 12px; padding: 0; }
.mytab-list:empty { display: none; }
.mytab-row { display: flex; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 0.5px solid var(--separator); }
.mytab-row__body { flex: 1; min-width: 0; }
.mytab-row__name { font-size: 15px; font-weight: 700; }
.mytab-row__q { font-size: 12px; color: var(--secondary-label); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mytab-row__del { flex: 0 0 auto; border: none; background: none; color: var(--danger); font-size: 13px; font-weight: 700; cursor: pointer; padding: 6px 8px; }
.mytab-row__del:active { opacity: 0.6; }

.mytab-form { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.suggest-form { display: flex; gap: 8px; margin-top: 8px; }
.suggest-form .tab-modal__input { flex: 1; min-width: 0; }
.tab-modal__input {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border: 0.5px solid var(--separator);
    border-radius: 10px;
    background: var(--bg);
    color: var(--label);
    font-size: 16px;
    font-family: var(--font-body);
    -webkit-appearance: none;
    appearance: none;
}
.tab-modal__input:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: transparent; }
.tab-modal__input::placeholder { color: var(--tertiary-label); }
.tab-modal__btn {
    flex: 0 0 auto;
    height: 44px;
    padding: 0 18px;
    border: none;
    border-radius: 10px;
    background: var(--accent);
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    font-family: var(--font-body);
    cursor: pointer;
}
.tab-modal__btn:active { opacity: 0.8; }
.tab-modal__btn:disabled { opacity: 0.5; cursor: default; }
.mytab-form .tab-modal__btn { align-self: flex-end; padding: 0 24px; }
.tab-modal__msg { font-size: 13px; margin-top: 10px; padding: 8px 10px; border-radius: 8px; line-height: 1.5; }
.tab-modal__msg.is-ok { background: color-mix(in srgb, var(--success) 16%, transparent); color: var(--success); }
.tab-modal__msg.is-err { background: color-mix(in srgb, var(--danger) 12%, transparent); color: var(--danger); }

/* タブの並び替え・非表示（購入者のみ・JS で #tabEditList に行を描画） */
.tab-edit-list { list-style: none; margin: 10px 0 0; padding: 0; }
.tab-edit-list:empty { display: none; }
.tab-edit-row { display: flex; align-items: center; gap: 10px; padding: 9px 2px; border-bottom: 0.5px solid var(--separator); }
.tab-edit-row:last-child { border-bottom: none; }
.tab-edit-row.is-hidden { opacity: 0.5; }
.tab-edit-row__swatch { width: 12px; height: 12px; border-radius: 3px; background: var(--accent); flex: 0 0 auto; }
.tab-edit-row__name { flex: 1; min-width: 0; font-size: 15px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tab-edit-row__btns { flex: 0 0 auto; display: flex; align-items: center; gap: 6px; }
.tab-edit-hide {
    border: 0.5px solid var(--separator);
    background: var(--surface);
    color: var(--secondary-label);
    font-size: 12px;
    font-weight: 700;
    font-family: var(--font-body);
    border-radius: 8px;
    padding: 5px 10px;
    cursor: pointer;
    white-space: nowrap;
}
.tab-edit-hide.is-on { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.tab-edit-hide:active { opacity: 0.7; }
.tab-edit-move {
    width: 32px;
    height: 32px;
    border: 0.5px solid var(--separator);
    background: var(--surface);
    color: var(--label);
    font-size: 16px;
    line-height: 1;
    font-family: var(--font-body);
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.tab-edit-move:active { opacity: 0.7; }
.tab-edit-move:disabled { opacity: 0.3; cursor: default; }

/* 未購入/未ログインのロック表示（買い切りで解禁） */
.tab-edit-lock { background: var(--bg); border-radius: 12px; padding: 16px; margin-top: 8px; }
.tab-edit-lock__head { font-size: 14px; font-weight: 800; display: flex; align-items: center; gap: 6px; }
.tab-edit-lock__icon { font-size: 15px; }
.tab-edit-lock__text { font-size: 13px; color: var(--secondary-label); line-height: 1.7; margin: 8px 0 12px; }
.tab-edit-lock__text strong { color: var(--label); font-weight: 800; }
.tab-edit-lock__form { margin: 0; }
.tab-edit-lock__btn { width: 100%; text-align: center; text-decoration: none; box-sizing: border-box; }

/* モーダル下部のログイン状態 */
.tab-modal__account { padding: 16px 0 2px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.tab-modal__account-text { font-size: 12px; color: var(--secondary-label); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.tab-modal__account-link { font-size: 13px; font-weight: 700; color: var(--accent); text-decoration: none; flex: 0 0 auto; }
.tab-modal__account-link:active { opacity: 0.7; }

/* マイページの購入導線・復元ボタンのラッパー（account.blade） */
.account-purchase-lead { font-size: 14px; color: var(--secondary-label); line-height: 1.8; margin-bottom: 12px; }
.account-purchase-form { margin: 0 0 12px; }
.account-restore { margin: 0; }
