/* 1.13.0 メダカの本（/mendelbook）を第十三版 13「メダカの本」の見本に合わせる。
   本のページはテーマを使わない独立のページなので、出来上がった HTML に印（html.eapur-book）と、この決まりを足す。本のプログラムは1行も変えない。
   決まり：外まわり（表紙・道具の段・検索・章の見出し・項目の名前の札）は墨と金。読む中身（開いた項目の本文・説明の段・参考文献）は和紙の地に濃い字のまま
   （図・表・写真は白い地の前提で描かれているので、暗くすると読めなくなる。第十三版のほかの画面でも「和紙の札」は明るいまま）。
   色は :root の --eapur-*（設定の6色）から使う。 */
.eapur-book{--eapur-washi:#f4ead6;--eapur-washi-ink:#2a2116;--eapur-washi-line:#c9ad7a}
.eapur-book body{background:transparent !important;color:var(--eapur-text,#fff1d4) !important}
.eapur-book .eapmtl-reading-progress-fixed{background:linear-gradient(90deg,var(--eapur-gold,#e8bb66),#b98a3e) !important}

/* 表紙：背景の書庫が見えるように、白い光を消して下だけ暗く。題は金の明朝、説明は生成り */
.eapur-book .eapmtl-hero{background:linear-gradient(180deg,rgba(11,9,6,.15) 0%,rgba(11,9,6,.55) 55%,rgba(11,9,6,.9) 100%) !important;color:var(--eapur-text,#fff1d4) !important}
.eapur-book .eapmtl-hero h1,.eapur-book .eapmtl-hero h1 *{color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important;font-family:"Hiragino Mincho ProN","Yu Mincho","Noto Serif JP",serif !important;text-shadow:0 2px 10px rgba(0,0,0,.85) !important}
.eapur-book .eapmtl-hero-desc,.eapur-book .eapmtl-hero-desc *{color:var(--eapur-text,#fff1d4) !important;-webkit-text-fill-color:var(--eapur-text,#fff1d4) !important;text-shadow:0 1px 4px rgba(0,0,0,.9) !important}
.eapur-book .eapmtl-hero-eyebrow{background:rgba(18,14,9,.85) !important;border-color:var(--eapur-line,#ac8448) !important;color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important}

/* 墨の札（表紙の数・お店の3枚・目次・道具の段・検索・章の見出し） */
.eapur-book .eapmtl-stat,.eapur-book .eapmtl-brand-card,.eapur-book .eapmtl-rail-card,.eapur-book .eapmtl-reader-tools,.eapur-book .eapmtl-search,.eapur-book .eapmtl-chapter-head,.eapur-book .eapmtl-book-mobile-nav{background:linear-gradient(180deg,#1c150d,var(--eapur-ink,#120e09)) !important;border:1px solid var(--eapur-line,#ac8448) !important;box-shadow:0 6px 18px rgba(0,0,0,.45) !important;color:var(--eapur-text,#fff1d4) !important}
.eapur-book .eapmtl-book-mobile-nav{border-width:0 0 1px !important;border-radius:0 !important}
.eapur-book :is(.eapmtl-stat,.eapmtl-brand-card,.eapmtl-rail-card,.eapmtl-reader-tools,.eapmtl-search,.eapmtl-chapter-head,.eapmtl-book-mobile-nav) :is(div,p,span,strong,h2,h3,label,small,li){color:var(--eapur-text,#fff1d4) !important;-webkit-text-fill-color:var(--eapur-text,#fff1d4) !important}
.eapur-book :is(.eapmtl-brand-kicker,.eapmtl-rail-label,.eapmtl-rail-no,.eapmtl-search-kicker,.eapmtl-chapter-kicker,.eapmtl-counted,.eapmtl-reader-tools-title),.eapur-book .eapmtl-chapter-head .eapmtl-cat{color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important}
.eapur-book .eapmtl-chapter-head .eapmtl-cat{font-family:"Hiragino Mincho ProN","Yu Mincho","Noto Serif JP",serif !important}
.eapur-book :is(.eapmtl-hero-desc,.eapmtl-chapter-desc,.eapmtl-reader-tools-help,.eapmtl-reader-tools-note,.eapmtl-search-count,.eapmtl-search-hint,.eapmtl-lang-label,.eapmtl-progress-meta,.eapmtl-progress-value,.eapmtl-reader-menu-value){color:var(--eapur-sub,#d2c4a9) !important;-webkit-text-fill-color:var(--eapur-sub,#d2c4a9) !important}
.eapur-book .eapmtl-rail-link,.eapur-book .eapmtl-rail-link *{color:var(--eapur-text,#fff1d4) !important;-webkit-text-fill-color:var(--eapur-text,#fff1d4) !important}
.eapur-book .eapmtl-rail-link .eapmtl-rail-no{color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important}
.eapur-book .eapmtl-chapter-count{background:var(--eapur-ink,#120e09) !important;border-color:var(--eapur-line,#ac8448) !important;color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important}
.eapur-book :is(.eapmtl-progress-track,.eapmtl-reader-menu-track){background:#2a2116 !important}
.eapur-book :is(.eapmtl-progress-bar,.eapmtl-reader-menu-bar){background:linear-gradient(90deg,#b98a3e,var(--eapur-gold,#e8bb66)) !important}

/* ボタン：主は金の地に墨の字、ほかは墨の地に金のふち（第十三版の「続きから読む」「全部開く」と同じ） */
.eapur-book :is(.eapmtl-hero-primary,.eapmtl-search-primary,.eapmtl-lang-btn[aria-pressed="true"],.eapmtl-lang-btn.is-active,.eapmtl-lang-btn.active){background:linear-gradient(180deg,var(--eapur-gold,#e8bb66),#b98a3e) !important;border:1px solid var(--eapur-btn-edge,#ffdf9a) !important;color:var(--eapur-btn-text,#1a1005) !important;-webkit-text-fill-color:var(--eapur-btn-text,#1a1005) !important;text-shadow:none !important}
.eapur-book :is(.eapmtl-hero-primary,.eapmtl-search-primary,.eapmtl-lang-btn[aria-pressed="true"],.eapmtl-lang-btn.is-active,.eapmtl-lang-btn.active) *{color:var(--eapur-btn-text,#1a1005) !important;-webkit-text-fill-color:var(--eapur-btn-text,#1a1005) !important}
.eapur-book :is(.eapmtl-hero-secondary,.eapmtl-search-secondary,.eapmtl-q-chip,.eapmtl-lang-btn,.eapmtl-chapter-next,.eapmtl-chapter-prev){background:var(--eapur-ink,#120e09) !important;border:1px solid var(--eapur-line,#ac8448) !important;color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important;min-height:44px}
.eapur-book :is(.eapmtl-hero-secondary,.eapmtl-search-secondary,.eapmtl-q-chip,.eapmtl-chapter-next,.eapmtl-chapter-prev) *{color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important}
.eapur-book .eapmtl-search-inputwrap{background:var(--eapur-washi) !important;border-color:var(--eapur-washi-line) !important}
.eapur-book .eapmtl-search-inputwrap input{color:var(--eapur-washi-ink) !important;-webkit-text-fill-color:var(--eapur-washi-ink) !important;background:transparent !important}
.eapur-book .eapmtl-search-inputwrap input::placeholder{color:#6b5a40 !important;-webkit-text-fill-color:#6b5a40 !important}
.eapur-book :is(a,button,summary):focus-visible{outline:2px solid #fff1d4 !important;outline-offset:2px !important}

/* 項目の名前の札（閉じている時）：墨の地・生成りの題・金の「読む」。開くと、本文は和紙の地 */
.eapur-book :is(details.eapmtl-entry,details.eapmtl-reference-entry){background:linear-gradient(180deg,#1c150d,var(--eapur-ink,#120e09)) !important;border:1px solid var(--eapur-line,#ac8448) !important;color:var(--eapur-text,#fff1d4) !important}
.eapur-book :is(details.eapmtl-entry,details.eapmtl-reference-entry) > summary,.eapur-book :is(details.eapmtl-entry,details.eapmtl-reference-entry) > summary *{color:var(--eapur-text,#fff1d4) !important;-webkit-text-fill-color:var(--eapur-text,#fff1d4) !important}
.eapur-book :is(details.eapmtl-entry,details.eapmtl-reference-entry) > summary .eapmtl-entry-state{background:var(--eapur-ink,#120e09) !important;border-color:var(--eapur-line,#ac8448) !important;color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important}
.eapur-book :is(details.eapmtl-entry,details.eapmtl-reference-entry) > summary .eapmtl-badge{background:#3a2a12 !important;color:#ffe2a0 !important;-webkit-text-fill-color:#ffe2a0 !important}
/* 本文（読む中身）＝和紙。中の字は本の色（濃い字）のまま。受け継いだ明るい塗りは外す */
.eapur-book :is(.eapmtl-body,.eapmtl-book-section,.eapmtl-biblio-section,.eapmtl-note,.eapmtl-lesson-sources){background:var(--eapur-washi) !important;color:var(--eapur-washi-ink) !important;-webkit-text-fill-color:currentColor !important;border-radius:10px}
.eapur-book .eapmtl-body{border-top:1px solid var(--eapur-washi-line) !important}
.eapur-book :is(.eapmtl-book-section,.eapmtl-biblio-section){padding:16px !important;border:1px solid var(--eapur-washi-line) !important;margin-bottom:16px !important}
.eapur-book :is(.eapmtl-body,.eapmtl-book-section,.eapmtl-biblio-section,.eapmtl-note,.eapmtl-lesson-sources) *{-webkit-text-fill-color:currentColor !important}
.eapur-book :is(.eapmtl-body,.eapmtl-book-section,.eapmtl-biblio-section) details.eapmtl-reference-entry > summary,.eapur-book :is(.eapmtl-body,.eapmtl-book-section,.eapmtl-biblio-section) details.eapmtl-reference-entry > summary *{-webkit-text-fill-color:var(--eapur-text,#fff1d4) !important}
.eapur-book .eapmtl-book-section .eapmtl-reference-entry .eapmtl-body{border-radius:0 0 10px 10px}
/* 章の並び（章そのものの箱）は透明のまま＝背景の書庫が見える。章の「前へ・次へ」は墨の札 */
.eapur-book .eapmtl-foot,.eapur-book .eapmtl-foot *{color:var(--eapur-sub,#d2c4a9) !important;-webkit-text-fill-color:var(--eapur-sub,#d2c4a9) !important}
/* 開いた項目の名前の札：本は開くと札を白くするので、開いても墨のまま（生成りの題が読めなくなるため） */
.eapur-book :is(details.eapmtl-entry,details.eapmtl-reference-entry)[open] > summary{background:linear-gradient(180deg,#241a10,#1c150d) !important;border-bottom:1px solid var(--eapur-line,#ac8448) !important}
/* 上の章の札（スマホ）：墨の地に金のふち、いまの章は金の地 */
.eapur-book .eapmtl-book-mobile-nav a{background:var(--eapur-ink,#120e09) !important;border:1px solid var(--eapur-line,#ac8448) !important;color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important;min-height:40px}
.eapur-book .eapmtl-book-mobile-nav a.is-active{background:linear-gradient(180deg,var(--eapur-gold,#e8bb66),#b98a3e) !important;border-color:var(--eapur-btn-edge,#ffdf9a) !important;color:var(--eapur-btn-text,#1a1005) !important;-webkit-text-fill-color:var(--eapur-btn-text,#1a1005) !important}
/* 道具の段の「全部開く・全部閉じる・読んだ印を消す」：墨の地に金のふち（白い地に生成りの字で読めなかった） */
.eapur-book .eapmtl-reader-tools-actions button{background:var(--eapur-ink,#120e09) !important;border:1px solid var(--eapur-line,#ac8448) !important;color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important;min-height:44px}
.eapur-book .eapmtl-reader-tools-actions button *{color:var(--eapur-gold,#e8bb66) !important;-webkit-text-fill-color:var(--eapur-gold,#e8bb66) !important}
.eapur-book .eapmtl-search-inputwrap span,.eapur-book .eapmtl-search-inputwrap svg{color:var(--eapur-washi-ink) !important;-webkit-text-fill-color:var(--eapur-washi-ink) !important}
.eapur-book .eapmtl-book-section .eapmtl-chapter-desc{color:#4a3c28 !important;-webkit-text-fill-color:#4a3c28 !important}
/* 和紙と白い札の上の、薄い灰色の小さな字（本のもとの色で差が3前後）を少し濃く。言葉・並びはそのまま */
.eapur-book :is(.eapmtl-mini-label,.eapmtl-mini-label *,.eapmtl-evidence-source small,.eapmtl-evidence-source span,.eapmtl-mini-rule span,.eapmtl-evidence-index-item span,.eapmtl-evidence-index-item small,.eapmtl-over-title small,.eapmtl-small,.eapmtl-mini-muted,.eapmtl-related-label,.eapmtl-label){color:#4f5b66 !important;-webkit-text-fill-color:#4f5b66 !important}
.eapur-book .eapmtl-variety-stat span{color:#4f5b66 !important;-webkit-text-fill-color:#4f5b66 !important}
.eapur-book :is(.eapmtl-mini-kicker,.eapmtl-section-kicker,.eapmtl-subcat){color:#7a5a1c !important;-webkit-text-fill-color:#7a5a1c !important}
@media (prefers-reduced-motion:reduce){.eapur-book *{transition:none !important}}
