/* MangaPost 共通スタイル
   既存PostMediaネットワーク（gachapost/bungupost）の編集メディア的なデザイン言語
   （eyebrow見出し・facts-box・カードのhover演出・エディトリアルな余白）を踏襲しつつ、
   MangaPost独自のキーカラー（藍色）は維持する。
   MangaPostはページ種類が多いため唯一このサイトのみ外部CSS1ファイルに集約する。
   （ビルドステップなし・静的配信のみという既存方針は維持） */

:root {
  --white:   #FFFFFF;
  --bg:      #F6F7FB;
  --text:    #1A1A2E;
  --sub:     #5C5F6B;
  --muted:   #94969E;
  --border:  #E4E6EE;
  --primary: #3B4CCA;   /* MangaPostキーカラー（本の背表紙をイメージした藍色） */
  --primary-dark: #2C3899;
  --primary-soft: #EEF0FC; /* primaryの淡色版（バッジ・タグ・eyebrow背景用） */
  --confirmed: #1E8E5A; /* 発売日確定 */
  --estimated: #B7791F; /* 目安・未確定 */
  --unknown:   #8A8D98; /* 未定 */
  --shadow-sm: 0 1px 4px rgba(20,20,50,.06);
  --shadow-md: 0 6px 24px rgba(20,20,50,.12);
  --radius:    6px;
  --radius-lg: 10px;
  --wrap:      1180px;
}

* { box-sizing: border-box; }
body {
  margin: 0; font-family: 'Noto Sans JP', 'Inter', sans-serif;
  background: var(--bg); color: var(--text); min-height: 100vh;
  display: flex; flex-direction: column; -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img { max-width: 100%; display: block; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
main { flex: 1; }

/* ── HEADER ── */
.site-header { position: sticky; top: 0; z-index: 200; background: var(--white); border-bottom: 1px solid var(--border); }
.header-inner { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; height: 76px; display: flex; align-items: center; gap: 8px; }
.logo { text-decoration: none; flex-shrink: 0; margin-right: 16px; font-family: 'Inter','Noto Sans JP',sans-serif; font-weight: 900; font-size: 1.45rem; letter-spacing: -.02em; color: var(--text); display: flex; align-items: center; gap: 0; }
.logo .logo-mark { color: var(--primary); }
.header-nav { display: flex; align-items: center; flex: 1; gap: 2px; }
.header-nav a { font-family: 'Inter','Noto Sans JP',sans-serif; font-size: .8rem; font-weight: 600; letter-spacing: .01em; color: var(--sub); text-decoration: none; padding: 0 14px; height: 76px; display: inline-flex; align-items: center; border-bottom: 2px solid transparent; white-space: nowrap; transition: color .15s, border-color .15s; }
.header-nav a:hover { color: var(--primary); }
.header-nav a.is-active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 700; }
.header-actions { display: flex; align-items: center; gap: 4px; margin-left: auto; flex-shrink: 0; }
.btn-icon { width: 38px; height: 38px; border: none; background: transparent; cursor: pointer; color: var(--sub); display: flex; align-items: center; justify-content: center; border-radius: var(--radius); transition: color .15s, background .15s; }
.btn-icon:hover { color: var(--primary); background: var(--primary-soft); }
.hamburger { display: none; flex-direction: column; align-items: center; justify-content: center; gap: 4px; }
.hamburger span { display: block; width: 20px; height: 1.5px; background: var(--text); border-radius: 2px; }
.search-panel { overflow: hidden; max-height: 0; background: var(--white); border-bottom: 1px solid transparent; transition: max-height .25s ease, border-color .25s; }
.search-panel.is-open { max-height: 68px; border-bottom-color: var(--border); }
.search-panel-inner { max-width: var(--wrap); margin: 0 auto; padding: 14px 20px; }
.search-form { display: flex; gap: 8px; }
.search-input { flex: 1; height: 38px; padding: 0 12px; font-size: .9rem; font-family: inherit; border: 1px solid var(--border); border-radius: var(--radius); outline: none; background: var(--bg); }
.search-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(59,76,202,.12); }
.search-submit { height: 38px; padding: 0 18px; font-size: .85rem; font-weight: 700; font-family: inherit; background: var(--primary); color: var(--white); border: none; border-radius: var(--radius); cursor: pointer; transition: background .15s; }
.search-submit:hover { background: var(--primary-dark); }
.mobile-menu { display: none; background: var(--white); border-bottom: 1px solid var(--border); padding: 6px 16px 14px; flex-direction: column; }
.mobile-menu a { padding: 12px 4px; font-size: .92rem; font-weight: 600; color: var(--sub); text-decoration: none; border-bottom: 1px solid var(--border); }
.mobile-menu a.is-active { color: var(--primary); }
@media (max-width: 860px) {
  .header-nav { display: none; }
  .hamburger { display: flex; }
  .mobile-menu.is-open { display: flex; }
  .header-inner { height: 60px; }
  .header-nav a { height: 60px; }
  .logo { font-size: 1.2rem; }
}

/* ── FOOTER ── */
.site-footer { margin-top: auto; background: var(--text); color: rgba(255,255,255,.72); padding: 44px 0 26px; }
.footer-inner { display: flex; flex-direction: column; align-items: center; gap: 20px; text-align: center; }
.footer-logo { font-family: 'Inter','Noto Sans JP',sans-serif; font-weight: 900; font-size: 1.15rem; letter-spacing: -.02em; color: var(--white); text-decoration: none; }
.footer-logo .logo-mark { color: #8A96F0; }
.footer-tagline { font-size: .76rem; color: rgba(255,255,255,.45); margin-top: -10px; }
.footer-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 20px; font-size: .78rem; }
.footer-nav a { color: rgba(255,255,255,.68); text-decoration: none; transition: color .15s; }
.footer-nav a:hover { color: var(--white); }
.footer-divider { width: 44px; height: 1px; background: rgba(255,255,255,.16); }
.footer-credit { font-size: .72rem; color: rgba(255,255,255,.45); margin: 0; }
.footer-credit a { color: rgba(255,255,255,.7); text-decoration: underline; }
.footer-credit a:hover { color: var(--white); }
.footer-credit-badge { font-size: .72rem; margin: -4px 0 0; }
.footer-credit-badge a { color: rgba(255,255,255,.55); text-decoration: none; }
.footer-credit-badge a:hover { color: var(--white); text-decoration: underline; }
.footer-copy { font-size: .7rem; color: rgba(255,255,255,.38); letter-spacing: .02em; }

/* ── COMMON COMPONENTS ── */
.breadcrumb { padding: 10px 0; font-size: .78rem; color: var(--muted); }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; margin: 0; padding: 0; gap: 4px; }
.breadcrumb li:not(:last-child)::after { content: '/'; margin-left: 4px; color: var(--border); }
.breadcrumb a { color: var(--sub); text-decoration: none; }
.breadcrumb a:hover { color: var(--primary); }

.badge { display: inline-flex; align-items: center; gap: 4px; font-size: .72rem; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.badge-confirmed { background: rgba(30,142,90,.12); color: var(--confirmed); }
.badge-estimated { background: rgba(183,121,31,.12); color: var(--estimated); }
.badge-unknown   { background: rgba(138,141,152,.14); color: var(--unknown); }

.card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; transition: box-shadow .2s, transform .2s; }
a.card { display: block; text-decoration: none; color: inherit; }
a.card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
a.card img { transition: transform .4s ease; }
a.card:hover img { transform: scale(1.04); }

/* eyebrow風の見出し（左に短いアクセントバー）。サイト全体で共通使用 */
.section-title { display: flex; align-items: center; gap: 10px; font-size: .95rem; font-weight: 800; letter-spacing: .01em; color: var(--text); margin: 0 0 16px; padding: 0; border: none; }
.section-title::before { content: ''; display: inline-block; width: 4px; height: 16px; background: var(--primary); border-radius: 2px; flex-shrink: 0; }

.sec-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.sec-head .section-title { margin-bottom: 0; }
.sec-more { font-size: .78rem; font-weight: 600; color: var(--primary); text-decoration: none; white-space: nowrap; }
.sec-more:hover { text-decoration: underline; }

/* ページ見出し（eyebrow + h1 + リード文）。index/series.php独自の大きなヒーローとは別に、
   series_list.php等の一覧ページで共通利用する軽量版。値をここに集約し、ページごとに
   インラインstyleで再実装しない。 */
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-family: 'Inter','Noto Sans JP',sans-serif; font-size: .68rem; font-weight: 700; letter-spacing: .1em; color: var(--primary); margin: 0 0 8px; }
.eyebrow::before { content: ''; width: 16px; height: 2px; background: var(--primary); display: inline-block; flex-shrink: 0; }
.page-header { margin: 8px 0 26px; }
.page-header h1 { font-size: 1.6rem; font-weight: 900; letter-spacing: -.01em; margin: 0; }
.page-header p { font-size: .86rem; color: var(--sub); margin: 8px 0 0; }

/* ── book-tile：単行本カード／作品カード共通の最小単位。cover(表紙)は常に3:4.2固定比率、
   ttlは2行クランプ、vol/metaは1行のみで高さを揃える（カードごとの縦バラつき防止）。 ── */
.book-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.book-tile { text-decoration: none; color: inherit; display: block; }
.book-tile .cover { position: relative; aspect-ratio: 3/4.2; overflow: hidden; border-radius: var(--radius); box-shadow: var(--shadow-sm); background: var(--border); transition: box-shadow .18s, transform .18s; }
.book-tile .cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.book-tile:hover .cover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.book-tile:hover .cover img { transform: scale(1.06); }
.book-tile .vol { font-family: 'Inter','Noto Sans JP',sans-serif; font-size: .72rem; font-weight: 600; color: var(--primary); margin-top: 8px; }
.book-tile .ttl { font-size: .82rem; font-weight: 600; line-height: 1.4; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.book-tile .meta { font-size: .74rem; color: var(--sub); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.book-tile .chip-today { display: inline-block; font-size: .62rem; font-weight: 700; letter-spacing: .04em; color: var(--white); background: var(--primary); padding: 2px 7px; border-radius: 3px; margin-bottom: 6px; }

.series-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (min-width: 560px)  { .book-grid, .series-grid { grid-template-columns: repeat(3, 1fr); gap: 18px; } }
@media (min-width: 760px)  { .book-grid, .series-grid { grid-template-columns: repeat(4, 1fr); gap: 20px; } }
@media (min-width: 980px)  { .book-grid, .series-grid { grid-template-columns: repeat(5, 1fr); } }
@media (min-width: 1180px) { .book-grid, .series-grid { grid-template-columns: repeat(6, 1fr); } }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 11px 20px; border-radius: var(--radius); font-weight: 700; font-size: .85rem; text-decoration: none; border: none; cursor: pointer; transition: background .15s, opacity .15s; }
.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { background: var(--white); color: var(--primary); border: 1px solid var(--primary); }
.btn-outline:hover { background: var(--primary-soft); }

/* ── HOME HERO（雑誌の表紙のような編集メディア風。企業的なグラデーションバナーにはしない） ── */
.hero { background: linear-gradient(180deg, var(--white) 0%, var(--bg) 100%); border-bottom: 1px solid var(--border); padding: 48px 0 44px; text-align: center; }
.hero .eyebrow { display: inline-flex; align-items: center; gap: 10px; font-family: 'Inter','Noto Sans JP',sans-serif; font-size: .7rem; font-weight: 700; letter-spacing: .16em; color: var(--primary); margin-bottom: 16px; text-transform: uppercase; }
.hero .eyebrow::before, .hero .eyebrow::after { content: ''; width: 22px; height: 2px; background: var(--primary); opacity: .55; }
.hero h1 { font-size: 1.7rem; font-weight: 900; margin: 0 0 10px; letter-spacing: -.01em; line-height: 1.35; }
.hero p { margin: 0; color: var(--sub); font-size: .92rem; }
@media (min-width: 640px) { .hero h1 { font-size: 2.3rem; } }

.search-box { max-width: 560px; margin: -24px auto 0; padding: 0 20px; position: relative; z-index: 10; }
.search-box form { display: flex; gap: 8px; background: var(--white); padding: 8px; border-radius: var(--radius-lg); box-shadow: var(--shadow-md); border: 1px solid var(--border); }
.search-box input { flex: 1; border: none; outline: none; padding: 10px 12px; font-size: .95rem; font-family: inherit; background: transparent; }
.search-box button { background: var(--primary); color: var(--white); border: none; border-radius: var(--radius); padding: 0 22px; font-weight: 700; cursor: pointer; transition: background .15s; }
.search-box button:hover { background: var(--primary-dark); }

table.data-table { width: 100%; border-collapse: collapse; font-size: .85rem; }
table.data-table th, table.data-table td { padding: 10px 10px; border-bottom: 1px solid var(--border); text-align: left; }
table.data-table th { color: var(--muted); font-weight: 700; font-size: .72rem; letter-spacing: .04em; text-transform: uppercase; }

/* ── トップページ「次巻発売予定」：PCはtable、スマホはカード型リストに出し分ける
   （テーブルをそのまま縮小すると作品名・巻数・日付・バッジが折り返して読みづらくなるため）。
   .data-table自体はadmin.php/release.phpとも共有する汎用クラスなので、ここでは
   .upcoming-table-wrap/.upcoming-table/.upcoming-listにスコープしたルールのみ追加する。 ── */
.upcoming-table-wrap { overflow-x: auto; }
.upcoming-table td, .upcoming-table th { white-space: nowrap; }
.upcoming-table td:first-child, .upcoming-table th:first-child { white-space: normal; }
.upcoming-list { display: none; }
@media (max-width: 640px) {
  .upcoming-table-wrap { display: none; }
  .upcoming-list { display: flex; flex-direction: column; gap: 12px; }
  .upcoming-item {
    display: block; background: var(--white); border: 1px solid var(--border);
    border-radius: var(--radius-lg); box-shadow: var(--shadow-sm);
    padding: 16px 18px; text-decoration: none; color: inherit;
    transition: box-shadow .15s, transform .15s;
  }
  .upcoming-item:active { box-shadow: var(--shadow-md); }
  .upcoming-item .upcoming-title {
    font-size: .95rem; font-weight: 700; line-height: 1.45; margin-bottom: 12px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .upcoming-item .upcoming-row { display: flex; align-items: baseline; gap: 10px; font-size: .86rem; margin-bottom: 7px; }
  .upcoming-item .upcoming-label { flex: 0 0 76px; color: var(--muted); font-size: .74rem; font-weight: 600; }
  .upcoming-item .upcoming-value { font-weight: 700; white-space: nowrap; }
  .upcoming-item .badge { margin-top: 6px; }
}

.info-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.info-table th { width: 110px; text-align: left; color: var(--muted); font-weight: 600; padding: 8px 10px 8px 0; vertical-align: top; }
.info-table td { padding: 8px 0; vertical-align: top; }

.pagination { display: flex; justify-content: center; gap: 6px; margin: 24px 0; }
.pagination a, .pagination span { padding: 8px 12px; border-radius: var(--radius); font-size: .85rem; text-decoration: none; border: 1px solid var(--border); color: var(--sub); }
.pagination .is-current { background: var(--primary); color: var(--white); border-color: var(--primary); }

/* 一覧見出し直下などに置く小さな補助テキスト（既刊登録数の注記等）。目立たせない。 */
.section-note { font-size: .78rem; color: var(--muted); margin: 0 0 14px; }

.empty-state { text-align: center; padding: 60px 20px; color: var(--muted); }

/* ── 作品ページ：マガジン風ヒーロー ── */
.series-hero { padding: 24px 0 4px; }
.series-hero .eyebrow { display: inline-flex; align-items: center; gap: 8px; font-family: 'Inter','Noto Sans JP',sans-serif; font-size: .68rem; font-weight: 700; letter-spacing: .1em; color: var(--primary); margin: 0 0 10px; }
.series-hero .eyebrow::before { content: ''; width: 16px; height: 2px; background: var(--primary); }
.series-hero h1 { font-size: 1.55rem; font-weight: 900; line-height: 1.35; margin: 0 0 12px; letter-spacing: -.01em; }
@media (min-width: 640px) { .series-hero h1 { font-size: 2.05rem; } }
.hero-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: .84rem; color: var(--sub); margin: 0 0 22px; }
.hero-meta a { color: var(--sub); font-weight: 700; text-decoration: none; }
.hero-meta a:hover { color: var(--primary); }
.hero-meta .dot { color: var(--border); }

/* ── facts-box：ファーストビューの主役（表紙・最新刊・発売日・CTA）だけをまとめる唯一の場所。
   価格・既刊登録数はここに置かない（既刊一覧セクションのsection-noteへ移動済み）。 ── */
.facts-box { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); padding: 22px; display: flex; gap: 20px; align-items: flex-start; margin-bottom: 28px; }
.facts-box .facts-eyebrow { font-size: .68rem; font-weight: 700; letter-spacing: .08em; color: var(--primary); margin: 0 0 12px; display: flex; align-items: center; gap: 4px; }
.facts-box .facts-cover { flex-shrink: 0; width: 92px; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.facts-box .facts-cover img { width: 100%; display: block; }
.facts-box .facts-main { flex: 1; min-width: 0; }
.facts-box .facts-vol { font-size: 1.2rem; font-weight: 800; margin: 0 0 6px; line-height: 1.3; }
.facts-box .facts-caveat { font-size: .72rem; color: var(--muted); margin: -2px 0 6px; }
.facts-box .facts-date { font-size: .86rem; color: var(--sub); margin: 0 0 16px; }
.facts-box .btn { margin-top: 2px; }

/* スマホ：表紙は左、LATEST VOLUME/巻数/発売日/CTAは右に並べる横並びのまま（縦積み中央寄せは
   表紙だけが浮いてバランスが悪いため不採用）。表紙はデスクトップの92px幅より一回り大きくする。 */
@media (max-width: 640px) {
  .hero-meta { margin-bottom: 28px; }
  .facts-box { padding: 18px; gap: 16px; }
  .facts-box .facts-cover { width: 122px; }
}

/* ── 次巻情報カード（コンパクトなfacts風） ── */
.next-vol-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 18px 20px; }
.next-vol-card p { margin: 10px 0 0; font-size: .92rem; line-height: 1.7; }

/* ── 関連特集：横並びサムネイルリスト ── */
.related-strip { display: flex; flex-direction: column; gap: 2px; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.related-strip a { display: flex; align-items: center; gap: 14px; padding: 12px 16px; text-decoration: none; color: inherit; border-bottom: 1px solid var(--border); transition: background .15s; }
.related-strip a:last-child { border-bottom: none; }
.related-strip a:hover { background: var(--bg); }
.related-strip img { width: 64px; height: 44px; object-fit: cover; border-radius: 4px; flex-shrink: 0; background: var(--border); }
.related-strip .rel-title { font-size: .85rem; font-weight: 600; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ── 編集部特集カードグリッド（トップページ用） ── */
.feature-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 20px; }
.feature-grid .card-body { padding: 14px 16px; }
.feature-grid .card-body h3 { font-size: .92rem; font-weight: 700; line-height: 1.55; margin: 0; }
.feature-grid .card-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }

