/* マナメキシリーズ公式サイト 共通スタイル */
/* 見出しの字は宣伝動画と同じモッチーポップ(サイトで使う文字だけに絞ったもの。データ更新.ps1 で作り直す) */
@font-face {
  font-family: "MochiyPop";
  src: url("fonts/MochiyPopOne-subset.ttf") format("truetype");
  font-display: swap;
}
:root {
  --font-head: "MochiyPop", "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", sans-serif;
  --bg: #fdf8ee;
  --bg-2: #f6eedc;
  --card: #ffffff;
  --ink: #2b2a33;
  --sub: #6b6675;
  --line: #e7dcc6;
  --blue: #2f86d6;
  --blue-deep: #1d5fa3;
  --orange: #f07a1a;
  --orange-soft: #fff1e3;
  --navy: #22305a;
  --st-hp: #d94a4a;
  --st-int: #3a62c4;
  --st-charm: #d0548f;
  --st-luck: #2f9a5b;
  --st-money: #c08a12;
  --shadow: 0 2px 0 rgba(60, 40, 10, .08), 0 6px 18px rgba(60, 40, 10, .06);
  --radius: 14px;
  --font: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "Hiragino Sans", "BIZ UDPGothic", "Meiryo", "Yu Gothic", sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1b1a20; --bg-2: #24222b; --card: #2a2832; --ink: #ece8f2; --sub: #aaa4b6; --line: #3b3845;
    --blue: #5aa6ee; --blue-deep: #8cc2f5; --orange: #ff9a45; --orange-soft: #3a2a1d; --navy: #c8d3ff;
    --st-hp: #ff7a7a; --st-int: #8aa8ff; --st-charm: #ff8dc0; --st-luck: #6fd39a; --st-money: #f0c050;
    --shadow: 0 2px 0 rgba(0,0,0,.3), 0 6px 18px rgba(0,0,0,.25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #1b1a20; --bg-2: #24222b; --card: #2a2832; --ink: #ece8f2; --sub: #aaa4b6; --line: #3b3845;
  --blue: #5aa6ee; --blue-deep: #8cc2f5; --orange: #ff9a45; --orange-soft: #3a2a1d; --navy: #c8d3ff;
  --st-hp: #ff7a7a; --st-int: #8aa8ff; --st-charm: #ff8dc0; --st-luck: #6fd39a; --st-money: #f0c050;
  --shadow: 0 2px 0 rgba(0,0,0,.3), 0 6px 18px rgba(0,0,0,.25);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.85;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue-deep); text-underline-offset: 3px; }
a:hover { color: var(--orange); }
h1, h2, h3 { line-height: 1.4; }
.pixel { image-rendering: pixelated; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }

/* ---------- ヘッダー ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 12px; min-height: 60px; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--ink); font-weight: 800; font-size: 1.15rem; letter-spacing: .04em; }
.brand img { width: 34px; height: 34px; }
.brand small { font-weight: 600; font-size: .72rem; color: var(--sub); letter-spacing: 0; }
.nav { margin-left: auto; display: flex; gap: 4px; flex-wrap: wrap; }
.nav a {
  text-decoration: none; color: var(--ink); font-weight: 700; font-size: .92rem;
  padding: 8px 12px; border-radius: 999px; min-height: 40px; display: inline-flex; align-items: center;
}
.nav a:hover, .nav a[aria-current="page"] { background: var(--orange-soft); color: var(--orange); }
.nav-toggle { display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: 10px; width: 44px; height: 44px; color: var(--ink); font-size: 1.3rem; cursor: pointer; }
@media (max-width: 720px) {
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 60px; background: var(--bg); border-bottom: 1px solid var(--line); flex-direction: column; padding: 8px 16px 16px; }
  .nav.open { display: flex; }
  .nav a { min-height: 48px; }
}

/* ---------- ヒーロー ---------- */
.hero { position: relative; overflow: hidden; color: #fff; background: #3b2a4a; }
.hero img.bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center right; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(25,20,45,.78) 0%, rgba(25,20,45,.45) 50%, rgba(25,20,45,0) 75%); }
.hero .wrap { position: relative; z-index: 1; padding-top: 72px; padding-bottom: 72px; }
.hero h1 { font-size: clamp(2rem, 6vw, 3.4rem); margin: 0 0 8px; letter-spacing: .06em; text-shadow: 0 3px 0 rgba(0,0,0,.35); }
.hero p { max-width: 30em; margin: 0 0 20px; font-weight: 600; text-shadow: 0 2px 6px rgba(0,0,0,.5); }
.hero .eyebrow { display: inline-block; font-size: .8rem; font-weight: 800; letter-spacing: .12em; background: var(--orange); color: #fff; padding: 2px 12px; border-radius: 999px; margin-bottom: 12px; }
@media (max-width: 720px) {
  .hero::after { background: linear-gradient(180deg, rgba(25,20,45,.25) 0%, rgba(25,20,45,.85) 100%); }
  .hero .wrap { padding-top: 160px; padding-bottom: 40px; }
  .hero img.bg { object-position: 80% center; }
}

/* シリーズトップのヒーロー: 夕焼けのグラデーション + ナビの2人(バナー画像は文字入りなので使わない) */
.hero.series { background: linear-gradient(160deg, #3b2a5a 0%, #7a4a78 45%, #e48a5a 85%, #f6c27a 100%); }
.hero.series::after { display: none; }
.hero.series .wrap { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 16px; padding-top: 56px; padding-bottom: 56px; }
.hero .duo { display: flex; align-items: flex-end; gap: 4px; }
.hero .duo img { width: 150px; image-rendering: pixelated; filter: drop-shadow(0 6px 10px rgba(0,0,0,.3)); }
.hero .duo img + img { margin-bottom: 24px; }
@media (max-width: 720px) {
  .hero.series .wrap { grid-template-columns: 1fr; padding-top: 32px; padding-bottom: 40px; }
  .hero .duo { order: -1; justify-content: center; }
  .hero .duo img { width: 104px; }
}

/* 作品ページのヒーロー: 文字入りバナーをそのまま見せて、説明はその下に置く */
.banner-hero { background: linear-gradient(180deg, #3b2a5a, #2a2040); color: #fff; padding: 24px 0 36px; }
.banner-hero img { width: 100%; border-radius: 16px; box-shadow: 0 10px 30px rgba(0,0,0,.35); }
.banner-hero p { margin: 18px 0; font-weight: 600; }
.banner-hero .eyebrow { display: inline-block; font-size: .8rem; font-weight: 800; letter-spacing: .12em; background: var(--orange); color: #fff; padding: 2px 12px; border-radius: 999px; margin-top: 20px; }

/* ---------- ボタン(ゲーム内のつやボタン風) ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 10px 22px; border-radius: 999px; border: 0;
  font-family: inherit; font-weight: 800; font-size: 1rem; text-decoration: none; cursor: pointer;
  color: #fff; background: linear-gradient(180deg, #5db4f5 0%, var(--blue) 55%, #1f6fbf 100%);
  box-shadow: inset 0 2px 0 rgba(255,255,255,.45), 0 3px 0 #17508a;
}
.btn:hover { color: #fff; filter: brightness(1.06); }
.btn.orange { background: linear-gradient(180deg, #ffad5a 0%, var(--orange) 55%, #d9600a 100%); box-shadow: inset 0 2px 0 rgba(255,255,255,.45), 0 3px 0 #a84a08; }
.btn.ghost { background: transparent; color: inherit; box-shadow: inset 0 0 0 2px currentColor; }
.btn[aria-disabled="true"] { opacity: .75; cursor: default; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- セクション ---------- */
section.block { padding: 56px 0; }
section.block.alt { background: var(--bg-2); }
.section-title { font-size: clamp(1.35rem, 3.5vw, 1.75rem); margin: 0 0 8px; display: flex; align-items: center; gap: 10px; }
.section-title::before { content: ""; width: 10px; height: 26px; border-radius: 4px; background: var(--orange); flex: none; }
.lead { color: var(--sub); margin: 0 0 28px; }

.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 20px;
}
.card h3 { margin: 0 0 6px; font-size: 1.08rem; }
.card p { margin: 0; }
.card .icon { font-size: 1.6rem; line-height: 1; margin-bottom: 8px; display: block; }
a.card { display: block; text-decoration: none; color: inherit; transition: transform .15s; }
a.card:hover { transform: translateY(-2px); color: inherit; border-color: var(--orange); }

/* ゲーム紹介カード(シリーズトップ) */
.game-card, a.card.game-card { display: grid; grid-template-columns: 260px 1fr; gap: 0; padding: 0; overflow: hidden; }
.game-card .thumb { background: #3b2a4a; }
.game-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.game-card .body { padding: 20px 22px; }
.game-card .tag { display: inline-block; font-size: .75rem; font-weight: 800; padding: 1px 10px; border-radius: 999px; background: var(--orange-soft); color: var(--orange); margin-bottom: 6px; }
.game-card.soon { opacity: .8; }
.game-card.soon .thumb { display: grid; place-items: center; font-size: 3rem; color: #fff; background: linear-gradient(135deg, #8a7fb0, #4d4570); }
@media (max-width: 600px) { .game-card, a.card.game-card { grid-template-columns: 1fr; } .game-card .thumb { aspect-ratio: 1024 / 500; } .game-card.soon .thumb { aspect-ratio: auto; height: 88px; } }

/* ナビゲーターの吹き出し */
.talk { display: flex; gap: 12px; align-items: flex-end; margin: 20px 0; }
.talk img { width: 72px; flex: none; image-rendering: pixelated; }
.talk .bubble { position: relative; background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 12px 16px; font-weight: 600; }
.talk .bubble b { display: block; font-size: .78rem; color: var(--sub); }
.talk.meki .bubble { border-color: #f2b56a; }
.talk.mana .bubble { border-color: #9cc0ea; }

/* スクリーンショット */
.shots { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 14px; }
.shots figure { margin: 0; flex: 0 0 200px; scroll-snap-align: start; }
.shots img { border-radius: 16px; border: 3px solid var(--card); box-shadow: var(--shadow); aspect-ratio: 9 / 16; object-fit: cover; }
.shots figcaption { text-align: center; font-size: .85rem; font-weight: 700; color: var(--sub); margin-top: 6px; }

/* 一生の流れ */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.timeline li { display: grid; grid-template-columns: 110px 1fr; gap: 12px; align-items: start; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; }
.timeline .age { font-weight: 800; color: var(--orange); }
.timeline .ttl { font-weight: 800; }
.timeline small { color: var(--sub); display: block; }
@media (max-width: 520px) { .timeline li { grid-template-columns: 1fr; gap: 2px; } }

/* 能力のラベル */
.st { display: inline-block; font-weight: 800; font-size: .8rem; padding: 0 8px; border-radius: 6px; color: var(--st-text, #fff); line-height: 1.7; white-space: nowrap; }
.st.hp { background: var(--st-hp); } .st.int { background: var(--st-int); } .st.charm { background: var(--st-charm); } .st.luck { background: var(--st-luck); } .st.money { background: var(--st-money); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --st-text: #1b1a20; } }
:root[data-theme="dark"] { --st-text: #1b1a20; }

/* ---------- 攻略ページ ---------- */
.page-head { padding: 36px 0 8px; }
.page-head h1 { margin: 0 0 4px; font-size: clamp(1.5rem, 4.5vw, 2.1rem); }
.breadcrumb { font-size: .85rem; color: var(--sub); margin-bottom: 8px; }
.breadcrumb a { color: var(--sub); }
.guide-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; padding: 16px 0 64px; }
.guide-side { position: sticky; top: 76px; align-self: start; }
.guide-side ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.guide-side a { display: block; padding: 8px 12px; border-radius: 10px; text-decoration: none; color: var(--ink); font-weight: 700; font-size: .92rem; }
.guide-side a:hover, .guide-side a[aria-current="page"] { background: var(--orange-soft); color: var(--orange); }
.guide-side .side-title { font-size: .75rem; font-weight: 800; color: var(--sub); letter-spacing: .1em; padding: 0 12px 4px; }
@media (max-width: 860px) {
  .guide-layout { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .guide-side { position: static; min-width: 0; }
  .guide-side ul { display: flex; overflow-x: auto; gap: 6px; padding-bottom: 6px; }
  .guide-side a { white-space: nowrap; border: 1px solid var(--line); background: var(--card); }
  .guide-side .side-title { display: none; }
}
.article h2 { font-size: 1.3rem; margin: 40px 0 12px; padding-bottom: 6px; border-bottom: 2px solid var(--line); scroll-margin-top: 76px; }
.article h2:first-child { margin-top: 8px; }
.article h3 { font-size: 1.08rem; margin: 28px 0 8px; }
.article ul, .article ol { padding-left: 1.4em; }
.article li { margin: 4px 0; }
.note { background: var(--orange-soft); border-left: 5px solid var(--orange); border-radius: 10px; padding: 12px 16px; margin: 16px 0; }
.note.tip { background: color-mix(in srgb, var(--st-luck) 12%, var(--card)); border-left-color: var(--st-luck); }
.note b:first-child { display: block; }
.updated { color: var(--sub); font-size: .85rem; }

/* 表 */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--card); margin: 12px 0 20px; }
table { border-collapse: collapse; width: 100%; font-size: .92rem; }
th, td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--bg-2); font-weight: 800; white-space: nowrap; position: sticky; top: 0; }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
td .st { margin: 1px 2px 1px 0; }
.muted { color: var(--sub); }
.nowrap { white-space: nowrap; }

/* 絞り込み */
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin: 8px 0; }
.filters label { font-size: .85rem; font-weight: 700; color: var(--sub); }
.filters select, .filters input {
  font-family: inherit; font-size: .95rem; padding: 8px 12px; min-height: 44px;
  border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--ink);
}
.chip { display: inline-block; font-size: .75rem; font-weight: 800; padding: 0 8px; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line); white-space: nowrap; }
.chip.rare { background: #e8f0ff; border-color: #a8c0f0; color: #2a4a9a; }
.chip.legendary { background: #fff3cf; border-color: #e9c45a; color: #8a6400; }
.chip.bad { background: #ffe9e9; border-color: #f0b0b0; color: #a33; }

details.spoiler { background: var(--card); border: 1px dashed var(--orange); border-radius: 12px; padding: 12px 16px; margin: 16px 0; }
details.spoiler summary { cursor: pointer; font-weight: 800; color: var(--orange); min-height: 28px; }

/* ---------- フッター ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 32px 0 40px; color: var(--sub); font-size: .88rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; align-items: center; }
.site-footer nav { display: flex; gap: 16px; flex-wrap: wrap; }
.site-footer a { color: var(--sub); }
.footer-mail { flex-basis: 100%; font-size: .75rem; opacity: .75; order: 9; }

/* みんなの声 */
.card.voice { padding: 16px 20px; }
.voice-meta { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: .85rem; }
.voice-text { margin: 10px 0 2px !important; font-size: 1.02rem; white-space: pre-wrap; }
.voice-name { margin: 0 !important; font-size: .85rem; }
.card.voice .talk { margin: 12px 0 0; }
.card.voice .talk img { width: 56px; }

.theme-btn { background: none; border: 1px solid var(--line); color: var(--sub); border-radius: 999px; padding: 6px 14px; font-family: inherit; font-size: .85rem; cursor: pointer; min-height: 36px; }

.center { text-align: center; }
.mt0 { margin-top: 0; }

/* 文字はすべてモッチーポップ(宣伝動画と同じ)。このフォントは1太さだけなので、太字の指定は無効にして字がつぶれないようにする */
body, body *, input, select, button { font-family: var(--font-head); }
body * { font-weight: 400 !important; }
body { letter-spacing: .02em; }
