/* Optional homepage replacement for Madara's default latest-chapter list. */
body.mgcr-latest-theme-1.home #loop-content,
body.mgcr-latest-theme-1.home .c-blog-listing .wp-pagenavi,
body.mgcr-latest-theme-1.home .c-blog-listing .navigation-ajax { display: none; }

.mgcr-latest-chapters { --mgcr-latest-red:#ef1a29; margin:26px 0 34px; color:#f6f6fa; contain:layout paint; }
.mgcr-latest-chapters__head { display:flex; align-items:center; justify-content:space-between; gap:14px; margin:0 0 18px; padding:0 0 10px; border-bottom:1px solid rgba(255,255,255,.16); }
.mgcr-latest-chapters__head h2 { margin:0; font-size:22px; line-height:1.2; font-weight:800; color:inherit; }
.mgcr-latest-chapters__head h2 a { color:inherit; text-decoration:none; }
.mgcr-latest-chapters__head h2:after { content:'›'; display:inline-block; margin-left:7px; color:var(--mgcr-latest-red); }
.mgcr-latest-chapters__head span { padding:5px 10px; border-radius:999px; background:rgba(239,26,41,.14); color:#ff9da5; font-size:12px; font-weight:700; }
.mgcr-latest-chapters__grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(145px,1fr)); gap:26px 16px; }
.mgcr-latest-card { position:relative; min-width:0; padding:6px; border:1px solid var(--mgcr-latest-card-accent,rgba(239,26,41,.78)); border-radius:13px; box-shadow:0 0 20px -2px var(--mgcr-latest-card-glow,rgba(239,26,41,.62)),inset 0 0 12px -9px var(--mgcr-latest-card-glow,rgba(239,26,41,.62)); transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease; }
.mgcr-latest-card:hover { box-shadow:0 0 27px -1px var(--mgcr-latest-card-glow,rgba(239,26,41,.62)),inset 0 0 15px -8px var(--mgcr-latest-card-glow,rgba(239,26,41,.62)); }
.mgcr-latest-card__cover { position:relative; display:block; aspect-ratio:7 / 10; overflow:hidden; border-radius:10px; background:#22232c; box-shadow:0 8px 24px rgba(0,0,0,.34); color:#fff; }
.mgcr-latest-card__cover img { display:block; width:100%; height:100%; object-fit:cover; transition:transform .28s ease,filter .28s ease; }
.mgcr-latest-card__shade { position:absolute; inset:0; background:linear-gradient(180deg,transparent 30%,rgba(0,0,0,.18) 50%,rgba(0,0,0,.92) 100%); pointer-events:none; }
.mgcr-latest-card__badge { position:absolute; z-index:6; inset:0; overflow:visible; pointer-events:none; }
.mgcr-latest-card__badge:empty,.mgcr-latest-card__badge-ribbon:empty { display:none; }
.mgcr-latest-card__badge-ribbon { position:static; display:block; width:auto; height:auto; transform:none !important; }
.mgcr-latest-card__badge-ribbon > a { position:static; display:contents; color:inherit !important; text-decoration:none !important; transform:none !important; }
.mgcr-latest-card__badge-ribbon .manga-title-badges { position:absolute !important; top:0 !important; left:50% !important; display:inline-flex !important; width:auto !important; min-height:0 !important; height:auto !important; align-items:center; justify-content:center; margin:0 !important; padding:0 6px !important; border:0 !important; border-radius:0 0 7px 7px !important; background:var(--mgcr-static-badge-color,#92000a) !important; background-image:linear-gradient(to bottom,rgba(255,255,255,0) 0,var(--mgcr-static-badge-color,#92000a) 100%,#fff 0%) !important; color:#fff !important; font-size:var(--mgcr-static-badge-size,10px) !important; font-weight:800 !important; line-height:normal !important; text-align:center; text-shadow:0 1px 2px #000; white-space:nowrap !important; transform:translate(-50%,0) !important; box-shadow:0 2px 8px rgba(0,0,0,.35); }
.mgcr-latest-card__badge-ribbon .manga-title-badges .text { color:inherit !important; font:inherit !important; }
.mgcr-latest-card__hover { position:absolute; z-index:3; left:0; right:0; bottom:0; display:flex; flex-direction:column; gap:6px; padding:22px 12px 13px; transform:translateY(12px); opacity:0; transition:opacity .22s ease,transform .22s ease; pointer-events:none; }
.mgcr-latest-card__hover-status { align-self:flex-start; padding:4px 8px; border-radius:5px; background:var(--mgcr-hover-status-color,#2196f3); color:#fff !important; font-size:var(--mgcr-hover-status-size,10px); font-weight:800; line-height:1.1; text-shadow:none; text-transform:uppercase; }
.mgcr-latest-card__hover strong { color:#fff !important; font-size:var(--mgcr-hover-title-size,15px); line-height:1.24; text-shadow:0 1px 3px rgba(0,0,0,.9); }
.mgcr-latest-card__hover em { display:block; overflow:hidden; color:#ffd1d5; font-size:var(--mgcr-hover-genre-size,12px); font-style:normal; line-height:1.3; text-overflow:ellipsis; white-space:nowrap; }
@media (hover:hover) { .mgcr-latest-card__cover:hover img { transform:scale(1.055); filter:brightness(.68); } .mgcr-latest-card__cover:hover .mgcr-latest-card__hover { opacity:1; transform:translateY(0); } .mgcr-latest-card:hover h3,.mgcr-latest-card:hover .mgcr-latest-card__chapters { transform:translateY(-3px); } }
.mgcr-latest-card h3 { display:block !important; height:2.6em !important; min-height:2.6em !important; max-height:2.6em !important; margin:13px 0 2px; overflow:hidden !important; color:inherit; font-size:14px; font-weight:800; line-height:1.3 !important; text-align:center; transition:transform .18s ease; }.mgcr-latest-card h3 a { display:-webkit-box !important; box-sizing:border-box; width:100%; height:2.6em !important; max-height:2.6em !important; min-width:0; overflow:hidden !important; color:inherit; line-height:1.3 !important; text-align:center; text-overflow:ellipsis; white-space:normal !important; -webkit-box-orient:vertical !important; -webkit-line-clamp:2 !important; }.mgcr-latest-card h3 a:hover { color:#ff6975; }
.mgcr-latest-card__chapters { margin:0; padding:0; list-style:none; transition:transform .18s ease; }
.mgcr-latest-card__chapters li { min-width:0; margin:0 -5px; padding:0; border:1px solid transparent; border-radius:8px; font-size:12px; line-height:1.3; transition:border-color .16s ease,background .16s ease,transform .16s ease; }
.mgcr-latest-card__chapters li:hover { border-color:rgba(255,255,255,.9); background:rgba(255,255,255,.06); transform:translateY(-2px); }
.mgcr-latest-card__chapters a { display:flex; align-items:center; justify-content:space-between; gap:7px; min-height:30px; padding:5px; color:#eeeef3; font-weight:700; text-decoration:none; }.mgcr-latest-card__chapters a > span { min-width:0; overflow:hidden; color:inherit; text-overflow:ellipsis; white-space:nowrap; }.mgcr-latest-card__chapters a:hover,.mgcr-latest-card__chapters a:hover > span { color:#ff6975; }.mgcr-latest-card__chapters a:visited,.mgcr-latest-card__chapters a:visited > span,.mgcr-latest-card__chapters a.is-read,.mgcr-latest-card__chapters a.is-read > span { color:#ef1a29 !important; }.mgcr-latest-card__chapters a:visited b,.mgcr-latest-card__chapters a.is-read b { color:#fff; }
.listing-chapters_wrap .wp-manga-chapter.mgcr-is-read > a { color:#ef1a29 !important; }
.mgcr-latest-card__chapters b { flex:none; padding:2px 5px; border-radius:3px; background:#bd260b; color:#fff; font-size:9px; font-weight:800; text-transform:uppercase; }.mgcr-latest-card__chapters time { flex:none; color:#a4a4b0; font-size:10px; white-space:nowrap; }
.mgcr-latest-card__chapters a { min-height:44px; }.mgcr-latest-card h3 { margin-top:15px; }.listing-chapters_wrap .wp-manga-chapter > a { display:flex; align-items:center; min-height:44px; }
.mgcr-latest-card__cover:focus-visible,.mgcr-latest-card h3 a:focus-visible,.mgcr-latest-card__chapters a:focus-visible,.mgcr-latest-pagination a:focus-visible{outline:3px solid #fff;outline-offset:3px;box-shadow:0 0 0 5px #ef1a29}
.mgcr-latest-pagination { display:flex; flex-wrap:wrap; justify-content:center; gap:6px; margin:30px 0 4px; }.mgcr-latest-pagination a,.mgcr-latest-pagination span { display:inline-flex; align-items:center; justify-content:center; min-width:34px; height:34px; padding:0 9px; border:1px solid rgba(255,255,255,.45); color:#f7f7fa; font-weight:800; text-decoration:none; }.mgcr-latest-pagination .current { border-color:var(--mgcr-latest-red); background:var(--mgcr-latest-red); color:#fff; }.mgcr-latest-pagination a:hover { border-color:#fff; background:rgba(255,255,255,.12); }
@media (hover:none),(pointer:coarse) { .mgcr-latest-card__cover.is-expanded .mgcr-latest-card__hover { opacity:1; transform:translateY(0); } }
@media (max-width:767px) { .mgcr-latest-chapters { margin-top:20px; }.mgcr-latest-chapters__head h2 { font-size:18px; }.mgcr-latest-chapters__grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:21px 12px; }.mgcr-latest-card { padding:5px; border-radius:11px; }.mgcr-latest-card h3 { font-size:13px; }.mgcr-latest-card__chapters li { font-size:11px; }.mgcr-latest-card__hover { padding:18px 9px 10px; }.mgcr-latest-card__hover strong { font-size:13px; }.mgcr-latest-card__badge-ribbon { transform:none !important; }.mgcr-latest-pagination { gap:4px; }.mgcr-latest-pagination a,.mgcr-latest-pagination span { min-width:31px; height:31px; padding:0 7px; } }
/* Keep chapter links comfortably tappable on small screens without altering desktop cards. */
@media(max-width:767px){.mgcr-latest-card__chapters li{margin:1px -5px;font-size:11px}.mgcr-latest-card__chapters a,.listing-chapters_wrap .wp-manga-chapter>a{display:flex!important;align-items:center;min-height:44px!important;padding:10px 8px!important}.mgcr-latest-card h3 a{display:flex;align-items:center;justify-content:center;min-height:44px}.mgcr-latest-card__chapters a{gap:4px}}
.mgcr-latest-chapter-lock{display:inline-block;margin-left:4px;font-style:normal;font-size:.9em;line-height:1;vertical-align:middle}
