HTML5 在线漫画阅读器 (index.html)
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=3,user-scalable=yes">
<title>为美好的世界献上祝福! - 在线漫画阅读器</title>
<style>
*{box-sizing:border-box;margin:0;padding:0}
body{background:#0d0f17;color:#f1f5f9;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;min-height:100vh;display:flex;flex-direction:column}
header{position:sticky;top:0;z-index:50;background:rgba(13,15,23,0.92);backdrop-filter:blur(12px);border-bottom:1px solid rgba(255,255,255,0.09);padding:10px 16px;display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.brand{display:flex;align-items:center;gap:10px}
.badge{background:linear-gradient(135deg,#ec4899,#8b5cf6);color:#fff;font-size:11px;font-weight:700;padding:3px 8px;border-radius:99px}
.title{font-size:16px;font-weight:700;color:#fff}
.controls{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
button{background:rgba(255,255,255,0.08);color:#e2e8f0;border:1px solid rgba(255,255,255,0.14);padding:6px 12px;border-radius:8px;font-size:12px;cursor:pointer;transition:.18s}
button:hover,button.active{background:#ec4899;color:#fff;border-color:#ec4899}
.hero{max-width:920px;margin:16px auto;padding:18px;background:rgba(255,255,255,0.04);border:1px solid rgba(255,255,255,0.08);border-radius:14px;display:flex;gap:18px;align-items:flex-start}
.hero img{width:120px;height:160px;object-fit:cover;border-radius:10px;flex-shrink:0;box-shadow:0 8px 24px rgba(0,0,0,0.45)}
.hero-meta h1{font-size:20px;margin-bottom:6px}
.hero-meta .sub{font-size:13px;color:#94a3b8;margin-bottom:8px}
.tags{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:10px}
.tag{background:rgba(236,72,153,0.16);color:#f472b6;padding:2px 8px;border-radius:6px;font-size:11px}
.desc{font-size:13px;line-height:1.6;color:#cbd5e1}
.reader-wrap{max-width:860px;width:100%;margin:0 auto 40px;padding:0 8px;flex:1}
.scroll-mode .page-card{margin-bottom:10px;background:#161925;border-radius:8px;overflow:hidden;box-shadow:0 6px 20px rgba(0,0,0,0.4)}
.scroll-mode .page-card img{width:100%;height:auto;display:block}
.page-footer{text-align:center;font-size:11px;color:#64748b;padding:4px 0}
.flip-controls{display:none;justify-content:center;align-items:center;gap:14px;margin:14px 0}
.flip-mode .flip-controls{display:flex}
.drawer{display:none;max-width:920px;margin:0 auto 20px;padding:16px;background:rgba(255,255,255,0.04);border-radius:12px;border:1px solid rgba(255,255,255,0.1)}
.drawer.open{display:block}
.chap-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));gap:8px;margin-top:10px}
.chap-item{padding:8px 10px;background:rgba(255,255,255,0.06);border-radius:8px;font-size:12px;color:#e2e8f0;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.chap-item:hover{background:rgba(236,72,153,0.28)}
@media(max-width:600px){.hero{flex-direction:column;align-items:center;text-align:center}.tags{justify-content:center}}
</style>
</head>
<body>
<header>
<div class="brand">
<span class="badge">BILIMANGA · 统一媒体库</span>
<span class="title" id="hdrTitle"></span>
</div>
<div class="controls">
<button id="btnScroll" class="active" onclick="setMode('scroll')">条漫下拉模式</button>
<button id="btnFlip" onclick="setMode('flip')">单页翻页模式</button>
<button onclick="toggleCatalog()">章节目录 (<span id="chapCount">0</span>)</button>
<button onclick="cycleLang()" id="btnLang">繁/簡/EN</button>
</div>
</header>
<section class="hero">
<img id="heroCover" src="" alt="cover">
<div class="hero-meta">
<h1 id="heroTitle"></h1>
<div class="sub" id="heroSub"></div>
<div class="tags" id="heroTags"></div>
<p class="desc" id="heroDesc"></p>
</div>
</section>
<section class="drawer" id="catDrawer">
<h3 style="font-size:14px;margin-bottom:6px">全卷章节目录 (点击切换预览章节)</h3>
<div class="chap-grid" id="chapGrid"></div>
</section>
<div class="reader-wrap scroll-mode" id="readerWrap">
<div class="flip-controls">
<button onclick="stepPage(-1)">◀ 上一页</button>
<span id="pageIndicator" style="font-size:13px;color:#cbd5e1">1 / 1</span>
<button onclick="stepPage(1)">下一页 ▶</button>
</div>
<div id="pagesContainer"></div>
</div>
<script>
const COMIC = {"slug": "bilimanga-625", "mangaid": "625", "zh_title": "为美好的世界献上祝福!", "hant_title": "為美好的世界獻上祝福!", "en_title": "为美好的世界献上祝福! (Bilimanga #625)", "author": "渡真仁 / 暁なつめ / 三嶋くろね", "tags": ["奇幻", "冒险", "异世界", "魔法", "恋爱", "欢乐", "奇幻冒险", "日本漫画"], "zh_desc": "非常喜欢打电动的家里蹲少年・佐藤和真在一次意外中丧命,让他的人生瞬间就迎向了终点…但这时突然有一位自称是女神的美少女现身,游说他转生到异世界!和真讨伐魔王的壮大故事即将开幕…本以为将会如此发展,但没想到他却跟让自己也转生的女神・阿克娅、非常喜欢爆裂魔法的小女孩・惠惠等人,为了满足自己的食衣住而开始卖力工作…!?\n\n📚 作品信息:作者 渡真仁 / 暁なつめ / 三嶋くろね · 评分 10 · 共收录 21 卷 / 122 话章节目录与高清彩页/条漫预览。", "hant_desc": "非常喜歡打電動的家裡蹲少年・佐藤和真在一次意外中喪命,讓他的人生瞬間就迎向了終點…但這時突然有一位自稱是女神的美少女現身,遊說他轉生到異世界!和真討伐魔王的壯大故事即將開幕…本以為將會如此發展,但沒想到他卻跟讓自己也轉生的女神・阿克婭、非常喜歡爆裂魔法的小女孩・惠惠等人,為了滿足自己的食衣住而開始賣力工作…!?\n\n📚 作品資訊:作者 渡真仁 / 暁なつめ / 三嶋くろね · 評分 10 · 共收錄 21 卷 / 122 話章節目錄與高清彩頁/條漫預覽。", "en_desc": "Popular serialized manga '为美好的世界献上祝福!' (為美好的世界獻上祝福!) by 渡真仁 / 暁なつめ / 三嶋くろね. Includes 21 volumes and 122 chapters with full online vertical/page-flip web reader.", "pages": ["https://media.huangguodrama.ai/motion/comics/bilimanga-625/page_01.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-625/page_02.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-625/page_03.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-625/page_04.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-625/page_05.jpg", "https://media.huangguodrama.ai/motion/comics/bilimanga-625/page_06.jpg"], "volumes": [{"title_hant": "為美好的世界獻上祝福! 1", "title_zh": "为美好的世界献上祝福! 1", "cover_id": 1053621, "first_chap_id": 48207, "cover_url": "https://i.motiezw.com/cover/625/1053621.jpg"}, {"title_hant": "為美好的世界獻上祝福! 2", "title_zh": "为美好的世界献上祝福! 2", "cover_id": 1053783, "first_chap_id": 48212, "cover_url": "https://i.motiezw.com/cover/625/1053783.jpg"}, {"title_hant": "為美好的世界獻上祝福! 3", "title_zh": "为美好的世界献上祝福! 3", "cover_id": 1053943, "first_chap_id": 48221, "cover_url": "https://i.motiezw.com/cover/625/1053943.jpg"}, {"title_hant": "為美好的世界獻上祝福! 4", "title_zh": "为美好的世界献上祝福! 4", "cover_id": 1054105, "first_chap_id": 48228, "cover_url": "https://i.motiezw.com/cover/625/1054105.jpg"}, {"title_hant": "為美好的世界獻上祝福! 5", "title_zh": "为美好的世界献上祝福! 5", "cover_id": 1054265, "first_chap_id": 48235, "cover_url": "https://i.motiezw.com/cover/625/1054265.jpg"}, {"title_hant": "為美好的世界獻上祝福! 6", "title_zh": "为美好的世界献上祝福! 6", "cover_id": 1054427, "first_chap_id": 48242, "cover_url": "https://i.motiezw.com/cover/625/1054427.jpg"}, {"title_hant": "為美好的世界獻上祝福! 7", "title_zh": "为美好的世界献上祝福! 7", "cover_id": 1054589, "first_chap_id": 48249, "cover_url": "https://i.motiezw.com/cover/625/1054589.jpg"}, {"title_hant": "為美好的世界獻上祝福! 8", "title_zh": "为美好的世界献上祝福! 8", "cover_id": 1054750, "first_chap_id": 48256, "cover_url": "https://i.motiezw.com/cover/625/1054750.jpg"}, {"title_hant": "為美好的世界獻上祝福! 9", "title_zh": "为美好的世界献上祝福! 9", "cover_id": 1054911, "first_chap_id": 48263, "cover_url": "https://i.motiezw.com/cover/625/1054911.jpg"}, {"title_hant": "為美好的世界獻上祝福! 10", "title_zh": "为美好的世界献上祝福! 10", "cover_id": 1055073, "first_chap_id": 48270, "cover_url": "https://i.motiezw.com/cover/625/1055073.jpg"}, {"title_hant": "為美好的世界獻上祝福! 11", "title_zh": "为美好的世界献上祝福! 11", "cover_id": 1055223, "first_chap_id": 48276, "cover_url": "https://i.motiezw.com/cover/625/1055223.jpg"}, {"title_hant": "為美好的世界獻上祝福! 12", "title_zh": "为美好的世界献上祝福! 12", "cover_id": 1055370, "first_chap_id": 48284, "cover_url": "https://i.motiezw.com/cover/625/1055370.jpg"}], "chapters": [{"cid": "48207", "title": "第一章 與自稱是N神的傢伙一起轉生到異世界!", "title_zh": "第一章 与自称是N神的家伙一起转生到异世界!"}, {"cid": "48208", "title": "第二章 替華M的高階職業帶來愉悅!", "title_zh": "第二章 替华M的高阶职业带来愉悦!"}, {"cid": "48209", "title": "第三章 讓不死生物獲得安息!", "title_zh": "第三章 让不死生物获得安息!"}, {"cid": "48210", "title": "第四章 讓爆裂之道獲得指引!", "title_zh": "第四章 让爆裂之道获得指引!"}, {"cid": "48211", "title": "第五章 讓可嶙的N神獲得救濟!", "title_zh": "第五章 让可嶙的N神获得救济!"}, {"cid": "48212", "title": "第六章 為這片湖獻上自稱N神的聖水!", "title_zh": "第六章 为这片湖献上自称N神的圣水!"}, {"cid": "48213", "title": "第七章 遭到夢幻竹筍偷襲!", "title_zh": "第七章 遭到梦幻竹笋偷袭!"}, {"cid": "48214", "title": "第八章 對這個傲慢的冒險者施加制裁!", "title_zh": "第八章 对这个傲慢的冒险者施加制裁!"}, {"cid": "48215", "title": "第九章 對恐怖的無頭騎士啟動反擊!", "title_zh": "第九章 对恐怖的无头骑士启动反击!"}, {"cid": "48216", "title": "第十章 想辦法T離這種絕望的狀況!", "title_zh": "第十章 想办法T离这种绝望的状况!"}, {"cid": "48217", "title": "第十一章 讓這場毫無意義的戰鬥分出勝負!", "title_zh": "第十一章 让这场毫无意义的战斗分出胜负!"}, {"cid": "48218", "title": "第十二章 為這次的轉生賦予幸運!", "title_zh": "第十二章 为这次的转生赋予幸运!"}, {"cid": "48221", "title": "第十三章 與真正的夥伴進行交易!!", "title_zh": "第十三章 与真正的伙伴进行交易!!"}, {"cid": "48222", "title": "第十四章 讓迷宮的主人獲得安息!", "title_zh": "第十四章 让迷宫的主人获得安息!"}, {"cid": "48223", "title": "第十五章 將這間鬧鬼房子恢復平靜!", "title_zh": "第十五章 将这间闹鬼房子恢复平静!"}, {"cid": "48224", "title": "第十六章 對這位幽靈少N伸出愛的援手!", "title_zh": "第十六章 对这位幽灵少N伸出爱的援手!"}, {"cid": "48225", "title": "第十七章 為M好的店鋪獻上祝福!", "title_zh": "第十七章 为M好的店铺献上祝福!"}, {"cid": "48226", "title": "第十八章 對了,去異世界一趟吧!", "title_zh": "第十八章 对了,去异世界一趟吧!"}, {"cid": "48228", "title": "第十九章 讓蠻橫的要塞燃起終焰?", "title_zh": "第十九章 让蛮横的要塞燃起终焰?"}, {"cid": "48229", "title": "第二十章 讓蠻橫的要塞燃起終焰!?", "title_zh": "第二十章 让蛮横的要塞燃起终焰!?"}, {"cid": "48231", "title": "第二十二章 惠惠•THE•RIPPER", "title_zh": "第二十二章 惠惠•THE•RIPPER"}, {"cid": "48232", "title": "第二十三章 為不正當的審判進行救楥!①", "title_zh": "第二十三章 为不正当的审判进行救楥!①"}, {"cid": "48233", "title": "第二十四章 為不正當的審判進行救楥!②", "title_zh": "第二十四章 为不正当的审判进行救楥!②"}, {"cid": "48235", "title": "第二十五章 跟紅魔N孩交朋友!①", "title_zh": "第二十五章 跟红魔N孩交朋友!①"}, {"cid": "48236", "title": "第二十六章 跟紅魔N孩交朋友!②", "title_zh": "第二十六章 跟红魔N孩交朋友!②"}, {"cid": "48237", "title": "第二十七章 為貴族千金獻上良緣!①", "title_zh": "第二十七章 为贵族千金献上良缘!①"}, {"cid": "48238", "title": "第二十七章 為貴族千金獻上良緣!②", "title_zh": "第二十七章 为贵族千金献上良缘!②"}, {"cid": "48239", "title": "第二十九章 讓戴上面具的騎士服從!①", "title_zh": "第二十九章 让戴上面具的骑士服从!①"}, {"cid": "48240", "title": "第三十章 讓戴上面具的騎士服從!②", "title_zh": "第三十章 让戴上面具的骑士服从!②"}, {"cid": "48242", "title": "第三十一章 向紛紜擾嚷的外界說聲再會!①", "title_zh": "第三十一章 向纷纭扰嚷的外界说声再会!①"}, {"cid": "48243", "title": "第三十二章 向紛紜擾嚷的外界說聲再會!②", "title_zh": "第三十二章 向纷纭扰嚷的外界说声再会!②"}, {"cid": "48244", "title": "第三十三章 赤瞳的新人殺手", "title_zh": "第三十三章 赤瞳的新人杀手"}, {"cid": "48245", "title": "第三十四章 對妄自尊大的慶柴祭出邀請!", "title_zh": "第三十四章 对妄自尊大的庆柴祭出邀请!"}, {"cid": "48246", "title": "第三十五章 在囧不可耐的城鎮進行觀光!①", "title_zh": "第三十五章 在囧不可耐的城镇进行观光!①"}, {"cid": "48247", "title": "第三十六章 在囧不可耐的城鎮進行觀光!②", "title_zh": "第三十六章 在囧不可耐的城镇进行观光!②"}, {"cid": "48249", "title": "第三十七章业 讓這座混浴溫泉替男人帶來滋潤!", "title_zh": "第三十七章业 让这座混浴温泉替男人带来滋润!"}, {"cid": "48250", "title": "第三十八章 對奇怪事件展開救援!①", "title_zh": "第三十八章 对奇怪事件展开救援!①"}, {"cid": "48251", "title": "第三十九章 對奇怪事件展開救援!②", "title_zh": "第三十九章 对奇怪事件展开救援!②"}, {"cid": "48252", "title": "第四十章 為不潔的溫泉城鎮獻上N神!①", "title_zh": "第四十章 为不洁的温泉城镇献上N神!①"}, {"cid": "48253", "title": "第四十一章 為不潔的溫泉城鎮獻上N神!②", "title_zh": "第四十一章 为不洁的温泉城镇献上N神!②"}, {"cid": "48254", "title": "第四十二章 對不淨的史莱姆敲下N神憤怒的鐵鎚!", "title_zh": "第四十二章 对不净的史莱姆敲下N神愤怒的铁锤!"}, {"cid": "48256", "title": "第四十三章 因報憂的信件做出決斷!", "title_zh": "第四十三章 因报忧的信件做出决断!"}, {"cid": "48257", "title": "第四十四章 對安樂少N砍下毫無慈悲的一刀!", "title_zh": "第四十四章 对安乐少N砍下毫无慈悲的一刀!"}, {"cid": "48258", "title": "第四十五章 拯救處男和真的貞操危機!", "title_zh": "第四十五章 拯救处男和真的贞操危机!"}, {"cid": "48259", "title": "第四十六章 在囧不可言的村落稍事休息!①", "title_zh": "第四十六章 在囧不可言的村落稍事休息!①"}, {"cid": "48260", "title": "第四十七章 在囧不可言的村落稍事休息!②", "title_zh": "第四十七章 在囧不可言的村落稍事休息!②"}, {"cid": "48261", "title": "第四十八章 為無法成眠的夜晚找到大義多分!", "title_zh": "第四十八章 为无法成眠的夜晚找到大义多分!"}, {"cid": "48263", "title": "第49話 為這M好的巨汝獻上感謝!", "title_zh": "第49话 为这M好的巨汝献上感谢!"}, {"cid": "48264", "title": "第50話 為這可恨的遺物送上爆炎!①", "title_zh": "第50话 为这可恨的遗物送上爆炎!①"}, {"cid": "48265", "title": "第51話 為這可恨的遣物送上爆炎!②", "title_zh": "第51话 为这可恨的遣物送上爆炎!②"}, {"cid": "48266", "title": "第52話 就送這個氣瘋了的合成怪獸上路!", "title_zh": "第52话 就送这个气疯了的合成怪兽上路!"}, {"cid": "48267", "title": "第53話 想要的是世上最強的魔法師", "title_zh": "第53话 想要的是世上最强的魔法师"}, {"cid": "48268", "title": "第54話 為這明亮的未來舉杯同祝!", "title_zh": "第54话 为这明亮的未来举杯同祝!"}, {"cid": "48270", "title": "第55話 為這位賢明的少N進行再教育!", "title_zh": "第55话 为这位贤明的少N进行再教育!"}, {"cid": "48271", "title": "第56話 成為這位公主殿下的玩伴", "title_zh": "第56话 成为这位公主殿下的玩伴"}, {"cid": "48272", "title": "第57話 這個玉樹臨風的義賊要遭天罰(1)", "title_zh": "第57话 这个玉树临风的义贼要遭天罚(1)"}, {"cid": "48273", "title": "第58話 這個玉樹臨風的義賊要遭天罰(2)", "title_zh": "第58话 这个玉树临风的义贼要遭天罚(2)"}, {"cid": "48274", "title": "第59話 為這個稀奇古怪的道具增加關注", "title_zh": "第59话 为这个稀奇古怪的道具增加关注"}, {"cid": "48276", "title": "第60話 多加註意這稀奇古怪的魔法道具", "title_zh": "第60话 多加注意这稀奇古怪的魔法道具"}, {"cid": "48277", "title": "第61話 多加註意這稀奇古怪的魔法道具(2)", "title_zh": "第61话 多加注意这稀奇古怪的魔法道具(2)"}]};
let lang = 'zh';
let mode = 'scroll';
let curPage = 0;
function renderMeta() {
const t = lang === 'zh' ? COMIC.zh_title : (lang === 'hant' ? COMIC.hant_title : COMIC.en_title);
const d = lang === 'zh' ? COMIC.zh_desc : (lang === 'hant' ? COMIC.hant_desc : COMIC.en_desc);
document.getElementById('hdrTitle').textContent = t;
document.getElementById('heroTitle').textContent = t;
document.getElementById('heroSub').textContent = `${COMIC.author} · 共 ${COMIC.volumes.length} 卷 / ${COMIC.chapters.length} 话`;
document.getElementById('heroDesc').textContent = d;
document.getElementById('heroCover').src = COMIC.pages[0] || '';
document.getElementById('chapCount').textContent = COMIC.chapters.length;
const tg = document.getElementById('heroTags');
tg.innerHTML = '';
(COMIC.tags || []).forEach(x => {
const s = document.createElement('span');
s.className = 'tag';
s.textContent = x;
tg.appendChild(s);
});
}
function renderCatalog() {
const g = document.getElementById('chapGrid');
g.innerHTML = '';
(COMIC.chapters || []).forEach((c, idx) => {
const d = document.createElement('div');
d.className = 'chap-item';
d.textContent = c.title_zh || c.title;
d.onclick = () => {
curPage = idx % COMIC.pages.length;
if (mode === 'flip') renderPages();
else document.querySelectorAll('.page-card')[curPage]?.scrollIntoView({behavior:'smooth'});
document.getElementById('catDrawer').classList.remove('open');
};
g.appendChild(d);
});
}
function renderPages() {
const wrap = document.getElementById('readerWrap');
wrap.className = 'reader-wrap ' + (mode === 'scroll' ? 'scroll-mode' : 'flip-mode');
const box = document.getElementById('pagesContainer');
box.innerHTML = '';
const list = mode === 'scroll' ? COMIC.pages : [COMIC.pages[curPage]];
list.forEach((url, i) => {
const idx = mode === 'scroll' ? i : curPage;
const card = document.createElement('div');
card.className = 'page-card';
card.innerHTML = `<img src="${url}" loading="lazy" alt="Page ${idx+1}"><div class="page-footer">第 ${idx+1} / ${COMIC.pages.length} 页 · ${COMIC.zh_title}</div>`;
if (mode === 'flip') card.onclick = () => stepPage(1);
box.appendChild(card);
});
document.getElementById('pageIndicator').textContent = `${curPage + 1} / ${COMIC.pages.length}`;
}
function setMode(m) {
mode = m;
document.getElementById('btnScroll').classList.toggle('active', m === 'scroll');
document.getElementById('btnFlip').classList.toggle('active', m === 'flip');
renderPages();
}
function stepPage(delta) {
curPage = (curPage + delta + COMIC.pages.length) % COMIC.pages.length;
renderPages();
}
function toggleCatalog() {
document.getElementById('catDrawer').classList.toggle('open');
}
function cycleLang() {
lang = lang === 'zh' ? 'hant' : (lang === 'hant' ? 'en' : 'zh');
renderMeta();
}
renderMeta();
renderCatalog();
renderPages();
</script>
</body>
</html>