/*
 * animeflv-detail.css — the anime page (/anime/{slug}, frontend/anime.blade.php,
 * partials/anime/*). Owned by the ANIME area.
 *
 * The page is animeflv's own markup (reference/anime-*.html), so css.css
 * draws it; this file only adds what the CMS needs on top, every rule under
 * the engine root `#watch-main.anime-page`:
 *   1. the rating stars (main.js Rating's five bare spans instead of
 *      animeflv's reversed `a.fa-star-o` links)
 *   2. the list buttons (the engine's folder drop-down in animeflv's
 *      AGREGAR button), VER EN GRUPO, the followers box when empty
 *   3. "Más información" (animeflv's dormant .MoreInfo / .ListMoreInfo)
 *   4. the episode list (the NO VISTO / VISTO toggle on rows and cards, the
 *      range drop-down for titles with more than 100 episodes, the grid /
 *      list switch and the grid of episode cards)
 *   5. Tráiler, Animes recomendados, Comentarios boxes
 * Nothing here is shared; the comment widget itself is animeflv-comments.css.
 */

/* ---------------------------------------------------------- 0. banner */

/* Every animeflv title had an alt-title line (.TxtAlt, 30px) under the h1;
   the 80px rating block (.vtshr, absolutely centred) relies on that height
   at 767–1019px. A CMS title without alt names keeps the same band height,
   so the stars never slide under the header. */
@media all and (min-width: 767px) {
    .anime-page .Ficha > .Container { min-height: 70px; }
}
@media all and (min-width: 1020px) {
    .anime-page .Ficha > .Container { min-height: 150px; }
}
@media all and (min-width: 1200px) {
    .anime-page .Ficha > .Container { min-height: 250px; }
}

/* ---------------------------------------------------------- 1. rating */

/* animeflv: five `a.fa-star-o(.On|.Hf)` in reverse order under
   direction:rtl, 15px FontAwesome #ffc602, 3px apart, pure-CSS hover.
   main.js Rating: five bare spans (index 0 = star 1, left to right) whose
   class it rewrites to full / half / "" on hover and after a vote. */
.anime-page .Votes .Strs.af-stars { direction: ltr; unicode-bidi: normal; }
.anime-page .Votes .Strs.af-stars > span {
    display: inline-block; vertical-align: top; width: auto; height: 15px; padding-right: 3px;
    color: #ffc602; font-size: 15px; line-height: 15px; cursor: pointer; transition: .2s linear;
}
.anime-page .Votes .Strs.af-stars > span:last-child { padding-right: 0; }
.anime-page .Votes .Strs.af-stars > span:before {
    content: '\f006'; display: inline-block; vertical-align: top; margin: 0;
    font-family: FontAwesome; font-style: normal; font-weight: 400;
    -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
.anime-page .Votes .Strs.af-stars > span.full:before { content: '\f005'; }
.anime-page .Votes .Strs.af-stars > span.half:before { content: '\f123'; }
/* The engine writes English hover labels ("Masterpiece") here; animeflv has none. */
.anime-page .Votes .af-rate-msg { display: none; }

/* ------------------------------------------------ 2. sidebar buttons */

/* The left button opens the engine's folder menu (.favourite.dropdown;
   main.js puts .show on the div and slides the menu). */
.anime-page .ListAnmBnts .af-fav { position: relative; }
.anime-page .ListAnmBnts .af-fav > .BtnNw { cursor: pointer; }
.anime-page .ListAnmBnts .af-fav > .BtnNw em { font-style: normal; }
/* Two lines, like animeflv's buttons, whatever the folder name. */
.anime-page .ListAnmBnts .af-fav > .BtnNw span,
.anime-page .ListAnmBnts .af-fav > .BtnNw em { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.anime-page .ListAnmBnts .af-fav > .dropdown-menu {
    top: 100%; left: 0; right: auto; z-index: 20; margin-top: -8px; min-width: 100%;
}
.anime-page .ListAnmBnts .af-fav.show > .dropdown-menu { display: block; }
.anime-page .ListAnmBnts .af-fav .dropdown-item {
    display: block; padding: 6px 15px; line-height: 20px; white-space: nowrap; cursor: pointer;
}
.anime-page .ListAnmBnts .af-fav .dropdown-item .fa-solid { margin-right: 6px; }
.anime-page .ListAnmBnts .af-fav .dropdown-item.active .text-danger { color: #fff; }
.anime-page .ListAnmBnts > li > a,
.anime-page #add_pending > a, .anime-page #remove_pending > a { cursor: pointer; }

/* VER EN GRUPO (Watch2gether): LISTA DE ESPERA's shape in the brand blue. */
.anime-page .BtnNw.Pndng.af-w2g-btn:before { color: #01bcf3; box-shadow: inset 0 0 0 1px #01bcf3; }
.anime-page .BtnNw.Pndng.af-w2g-btn:hover { color: #01bcf3; }
.anime-page .BtnNw.Pndng.af-w2g-btn:hover:before { background-color: #01bcf3; color: #fff; }

/* Seguidores: square 70px avatars (css.css), any source image. */
.anime-page .ListImgrnd > li > a img { object-fit: cover; }
.anime-page .WdgtCn.Sm .af-anime-nofollow { margin: 0; font-size: 12px; line-height: 20px; color: #9da1a4; }

/* ------------------------------------------------- 3. Más información */

/* animeflv's dormant pair: the grey bar toggles the list (.show). The bar
   sits on a hairline and the list ends flush with the box. */
.anime-page .MoreInfo.af-moreinfo { margin-top: 15px; border-top: 1px solid #efefef; border-radius: 0 0 3px 3px; }
.anime-page .ListAnmRel + .MoreInfo.af-moreinfo { margin-top: 20px; }
.anime-page .MoreInfo.af-moreinfo[aria-expanded="true"] { border-radius: 0; }
.anime-page .MoreInfo.af-moreinfo:hover, .anime-page .MoreInfo.af-moreinfo:focus { color: #90a4ae; text-decoration: none; }
.anime-page .ListMoreInfo.af-moreinfo-list { margin-bottom: -20px; color: #666; }
.anime-page .ListMoreInfo.af-moreinfo-list strong { color: #3b4248; }
.anime-page .ListMoreInfo.af-moreinfo-list a { color: #3b4248; }
.anime-page .ListMoreInfo.af-moreinfo-list a:hover { color: #00bcf2; }
.anime-page .ListMoreInfo.af-moreinfo-list li:before { margin-right: 0; }

/* ------------------------------------------------------- 4. episodes */

/* NO VISTO / VISTO is a real toggle (css.css draws the switch: input:checked
   + .Stts, li.Visto); keyboard users get the switch outline. */
.anime-page .ListCaps > li > a > figure img { display: block; }
.anime-page .ListCaps .opivw { -webkit-user-select: none; user-select: none; }

/* Grid / list switch (CMS extra): animeflv's profile `.ChngVw` pair (dark
   pill, active icon #ffc107) after Buscar. css.css pins .ChngVw to the box
   corner and hides it below 1020px; here it is the third item of the tools
   row at every width, 34px high like its neighbours. The row keeps
   animeflv's 150px sort + 176px Buscar from 1020px up; at 667–1019px Buscar
   gives up the switch's width, so the absolute row covers no more of the
   title than animeflv's own did (DECISIONS 16); ≤666px it is the static
   full-width row (icon-only sort, Buscar fills the rest). */
.anime-page .af-episodes .lstopt-frm.af-ep-tools { display: flex; align-items: flex-start; }
.anime-page .af-episodes .lstopt-frm.af-ep-tools:after { display: none; }
.anime-page .af-episodes .af-ep-tools > .order-lst { flex: none; }
/* animeflv's sort control is an invisible checkbox laid over the two
   buttons (css.css: absolute, 100% x 100%, opacity 0). A later checkbox rule
   shrank it to 13px in the corner, so a click on "Mayor a menor" hit the
   button and never toggled it. Spread it over the whole control again. */
.anime-page .order-lst > input#sortEpisodes { left: 0; top: 0; width: 100%; height: 100%; margin: 0; z-index: 2; }
.anime-page .af-episodes .af-ep-tools > input { flex: none; float: none; width: 176px; margin-left: 10px; }
.anime-page .af-episodes .af-ep-tools > .ChngVw.af-ep-view {
    display: block; position: static; flex: none; width: 68px; height: 34px; margin-left: 10px; line-height: 34px;
}
.anime-page .af-episodes .ChngVw.af-ep-view > span {
    width: 34px; height: 34px; line-height: 34px; color: #fff; transition: color .2s;
}
.anime-page .af-episodes .ChngVw.af-ep-view > span:hover { color: rgba(255, 193, 7, .7); }
.anime-page .af-episodes .ChngVw.af-ep-view > span:focus { outline: 0; }
.anime-page .af-episodes .ChngVw.af-ep-view > span:focus-visible { outline: 2px solid #01bcf3; outline-offset: -2px; border-radius: 3px; }
.anime-page .af-episodes:not(.af-grid) .ChngVw.af-ep-view > .fa-th-list,
.anime-page .af-episodes.af-grid .ChngVw.af-ep-view > .fa-th-large { color: #ffc107; cursor: default; }
@media all and (min-width: 667px) and (max-width: 1019px) {
    .anime-page .af-episodes .af-ep-tools > input { width: 98px; }
}
@media all and (max-width: 666px) {
    .anime-page .af-episodes .af-ep-tools > input { flex: 1 1 auto; width: auto; min-width: 0; }
}

/* With the range drop-down (.af-has-ranges) the row keeps to one line next
   to the title from 1200px; 1020–1199px the sort control is icon-only (as
   css.css draws it on phones) and the pill drops its "Episodios" word;
   667–1019px the row moves under the title (static, full width: pill, sort
   icon, Buscar filling the rest, grid switch); ≤666px the pill takes a line
   of its own above animeflv's phone row. */
@media all and (max-width: 1199px) {
    .anime-page .af-has-ranges .order-lst .btn { width: 50px; }
    .anime-page .af-has-ranges .order-lst .btn i { margin-right: 0; }
    .anime-page .af-has-ranges .order-lst .btn span { display: none; }
}
@media all and (min-width: 667px) and (max-width: 1199px) {
    .anime-page .af-has-ranges .af-ep-range > .af-ep-range-btn b { display: none; }
}
@media all and (min-width: 1020px) and (max-width: 1199px) {
    .anime-page .af-episodes.af-has-ranges .af-ep-tools > input { width: 176px; }
}
@media all and (max-width: 1019px) {
    .anime-page .af-episodes.af-has-ranges .lstopt-frm.af-ep-tools { position: static; padding-top: 10px; }
    .anime-page .af-episodes.af-has-ranges .af-ep-tools > input { flex: 1 1 auto; width: auto; min-width: 0; margin-bottom: 0; }
    .anime-page .af-episodes.af-has-ranges .Top { margin-bottom: 15px; }
    .anime-page .af-episodes.af-has-ranges .af-ep-grid.Rows { margin-top: -20px; }
}
/* the tools (and the open range menu) stay above the cards' top padding */
.anime-page .af-episodes.af-has-ranges .Top { position: relative; z-index: 5; }
@media all and (max-width: 666px) {
    .anime-page .af-episodes.af-has-ranges .lstopt-frm.af-ep-tools { flex-wrap: wrap; }
    .anime-page .af-episodes.af-has-ranges .af-ep-tools > .af-ep-range { flex: 1 0 100%; margin: 0 0 10px; }
    .anime-page .af-episodes.af-has-ranges .af-ep-tools > input { flex: 1 1 0; }
    .anime-page .af-episodes.af-has-ranges .af-ep-range > .af-ep-range-btn { position: relative; width: 100%; padding-right: 34px; }
    .anime-page .af-episodes.af-has-ranges .af-ep-range > .af-ep-range-btn i { position: absolute; right: 12px; top: 0; margin: 0; line-height: 32px; }
    .anime-page .af-episodes.af-has-ranges .af-ep-range > .af-ep-range-menu { right: 0; }
}

/* The two lists: one shown at a time. */
.anime-page .af-episodes.af-grid #episodeList,
.anime-page .af-episodes:not(.af-grid) .af-ep-grid { display: none; }

/* Grid: the home's "Últimos episodios" cards with the home's own columns
   (Rows A06 C04 D03 — css.css: 4 a row from 1200px, 3 at 1020–1199px, 2
   below, 1 on phones; owner), in the same 1000px scroll box as the list,
   edge to edge in the box like ListCaps so the scrollbar sits on the box
   edge. */
.anime-page .af-episodes .af-ep-grid.Rows { margin: -20px -20px -20px; padding: 0 10px 20px; }
/* ≤666px Buscar keeps its 15px bottom margin under the static tools row. */
@media all and (max-width: 666px) {
    .anime-page .af-episodes .af-ep-grid.Rows { margin-top: -35px; }
}
.anime-page .af-ep-grid > li { position: relative; }
.anime-page .af-ep-grid .Capi { white-space: nowrap; }
/* VISTO on a card: the list row's switch scaled down, in a dark pill on the
   picture's top-left corner (the play circle has the top-right one);
   "NO VISTO" grey track, "VISTO" the brand blue, as css.css's .Stts. The
   label is the card link's sibling (no control inside the link). */
.anime-page .af-ep-grid .af-ep-sw {
    position: absolute; top: 28px; left: 18px; z-index: 4; display: block; height: 22px; margin: 0; padding: 0 8px 0 5px;
    border-radius: 11px; background-color: rgba(30, 34, 38, .72); color: rgba(255, 255, 255, .85);
    font-size: 9px; font-weight: 700; line-height: 22px; text-transform: uppercase; white-space: nowrap; cursor: pointer;
    -webkit-user-select: none; user-select: none; transition: background-color .2s;
}
.anime-page .af-ep-grid .af-ep-sw:hover { background-color: rgba(30, 34, 38, .9); }
.anime-page .af-ep-grid .af-ep-sw > input { position: absolute; width: 1px; height: 1px; margin: 0; padding: 0; opacity: 0; pointer-events: none; }
.anime-page .af-ep-grid .af-ep-sw-txt { position: relative; display: block; padding-left: 30px; }
/* track + knob (css.css .Stts:after / :before, 24 x 12 here) */
.anime-page .af-ep-grid .af-ep-sw-txt:after {
    content: ''; position: absolute; left: 0; top: 5px; width: 24px; height: 12px; border-radius: 6px;
    background-color: rgba(255, 255, 255, .3); transition: background-color .2s;
}
.anime-page .af-ep-grid .af-ep-sw-txt:before {
    content: ''; position: absolute; z-index: 2; left: 2px; top: 7px; width: 8px; height: 8px; margin: 0; border-radius: 50%;
    background-color: #fff; transition: left .2s;
}
.anime-page .af-ep-grid .af-ep-sw > input:checked + .af-ep-sw-txt > span { display: none; }
.anime-page .af-ep-grid .af-ep-sw > input:checked + .af-ep-sw-txt:after { background-color: #00bcf2; }
.anime-page .af-ep-grid .af-ep-sw > input:checked + .af-ep-sw-txt:before { left: 14px; }
.anime-page .af-ep-grid .af-ep-sw > input:focus-visible + .af-ep-sw-txt:after { box-shadow: 0 0 0 2px #01bcf3; }
.anime-page .af-ep-grid > li.af-seen .af-ep-sw { background-color: #fff; color: #00bcf2; }
.anime-page .af-ep-grid > li.af-seen .af-ep-sw-txt:after { background-color: #00bcf2; }
/* a seen card: picture a little dimmed, like a watched thumbnail */
.anime-page .af-ep-grid > li.af-seen > a .Image img { opacity: .65; }
.anime-page .af-ep-grid > li.af-seen > a:hover .Image img { opacity: .8; }

/* Range drop-down (owner: titles with more than 100 episodes): a select-like
   pill in Buscar's box (white, #ccc hairline, 34px, radius 4) with
   animeflv's filter caret (blue chevron), opening a BS3 `.open`
   .dropdown-menu drawn like animeflv's filter drop-downs (zoomIn, round
   radio marks, the active one blue). */
.anime-page .af-episodes .af-ep-tools > .af-ep-range { position: relative; flex: none; margin-right: 10px; }
.anime-page .af-ep-range > .af-ep-range-btn {
    display: block; height: 34px; margin: 0; padding: 0 12px; border: 1px solid #ccc; border-radius: 4px;
    background-color: #fff; box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075); color: #3b4248;
    font-size: 14px; font-weight: 700; line-height: 32px; text-align: left; white-space: nowrap; cursor: pointer;
    transition: border-color .15s, box-shadow .15s;
}
.anime-page .af-ep-range > .af-ep-range-btn b { font-weight: 400; color: #9da1a4; }
.anime-page .af-ep-range > .af-ep-range-btn i { display: inline-block; vertical-align: top; margin-left: 8px; color: #00bcf2; font-size: 11px; transition: transform .2s; }
.anime-page .af-ep-range > .af-ep-range-btn i:before { margin: 0; vertical-align: baseline; }
.anime-page .af-ep-range > .af-ep-range-btn:hover,
.anime-page .af-ep-range.open > .af-ep-range-btn { border-color: #01bcf3; }
.anime-page .af-ep-range > .af-ep-range-btn:focus { outline: 0; }
.anime-page .af-ep-range > .af-ep-range-btn:focus-visible { border-color: #01bcf3; box-shadow: 0 0 0 2px rgba(1, 188, 243, .35); }
.anime-page .af-ep-range.open > .af-ep-range-btn i { transform: rotate(180deg); }
.anime-page .af-ep-range > .af-ep-range-menu {
    top: 100%; left: 0; right: auto; z-index: 30; min-width: 100%; max-height: 312px; margin: 10px 0 0; padding: 6px 0;
    overflow-y: auto; border: 0; border-radius: 4px; background-color: #fff; box-shadow: 0 2px 12px rgba(0, 0, 0, .18);
    list-style: none; font-size: 13px; text-align: left;
    animation-duration: .25s; animation-fill-mode: both; animation-name: zoomIn; transform-origin: 20px 0;
}
.anime-page .af-ep-range.open > .af-ep-range-menu { display: block; }
.anime-page .af-ep-range > .af-ep-range-menu > li { margin: 0; padding: 0; }
.anime-page .af-ep-range > .af-ep-range-menu > li > a {
    position: relative; display: block; padding: 5px 18px 5px 34px; color: #3b4248; line-height: 20px; white-space: nowrap;
}
.anime-page .af-ep-range > .af-ep-range-menu > li > a:before {
    content: '\f111'; position: absolute; left: 12px; top: 5px; margin: 0; font-family: FontAwesome; font-size: 13px; line-height: 20px;
    color: rgba(47, 53, 58, .15); transition: color .2s;
}
.anime-page .af-ep-range > .af-ep-range-menu > li > a:hover,
.anime-page .af-ep-range > .af-ep-range-menu > li > a:focus { background-color: #f5f7f8; color: #3b4248; outline: 0; }
.anime-page .af-ep-range > .af-ep-range-menu > li.active > a { color: #00bcf2; font-weight: 700; }
.anime-page .af-ep-range > .af-ep-range-menu > li.active > a:before { content: '\f058'; color: #00bcf2; }
/* the white arrow on the menu's top edge (animeflv's filter menus) */
.anime-page .af-ep-range.open:after {
    content: ''; position: absolute; left: 16px; top: 100%; z-index: 31; margin-top: 5px;
    border-left: 5px solid transparent; border-right: 5px solid transparent; border-bottom: 5px solid #fff;
}
/* PROXIMO EPISODIO: the list's green row as a card (the title's art under
   a green veil, the date as the title line). */
.anime-page .af-ep-grid .af-ep-next .Image:after {
    content: ''; position: absolute; top: 0; right: 0; bottom: 0; left: 0; z-index: 2;
    border-radius: 5px; background-color: rgba(0, 176, 70, .82);
}
.anime-page .af-ep-grid .af-ep-next > a { cursor: default; }
.anime-page .af-ep-grid .af-ep-next > a:hover:before { right: 10px; }
.anime-page .af-ep-grid .af-ep-next > a:hover img { transform: none; opacity: 1; }
.anime-page .af-ep-grid .af-ep-next .Capi { background-color: #fff; color: #00b046; }
.anime-page .af-ep-grid .af-ep-next .Title { font-size: 16px; font-weight: 700; }
/* No search hit: the list's red-icon message across the row. */
.anime-page .af-episodes .af-ep-grid.Rows > li.af-ep-none { width: 100%; padding: 30px 10px 10px; }
.anime-page .af-ep-grid > li.af-ep-none:before {
    display: inline-block; margin-right: 5px; font-size: inherit; line-height: inherit; color: #fb3447; opacity: 1;
}

/* --------------------------------------- 5. trailer, recommended, comments */

.anime-page .af-trailer-media { position: relative; margin: 0 -20px -20px; overflow: hidden; border-radius: 0 0 3px 3px; background: #000; }
.anime-page .af-trailer-media:before { content: ''; display: block; padding-top: 56.25%; }
.anime-page .af-trailer-media > a, .anime-page .af-trailer-media > iframe {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0;
}
.anime-page .af-trailer-media > a > img { width: 100%; height: 100%; object-fit: cover; opacity: .8; transition: .2s linear; }
.anime-page .af-trailer-media > a:hover > img { opacity: 1; }
.anime-page .af-trailer-btn {
    position: absolute; top: 50%; left: 50%; width: 70px; height: 70px; margin: -35px 0 0 -35px;
    border-radius: 50%; background-color: #01bcf3; color: #fff; text-align: center;
    box-shadow: 0 0 30px rgba(0, 0, 0, .3); transition: .2s linear;
}
.anime-page .af-trailer-btn:before { margin: 0 0 0 5px; font-size: 26px; line-height: 70px; }
.anime-page .af-trailer-media > a:hover .af-trailer-btn { background-color: #00aeed; transform: scale(1.08); }

.anime-page .af-recommended .ListAnimes { margin-bottom: -10px; }
/* css.css puts one card per row below 468px (home, browse); twelve
   full-width posters under the episode list would be ~6000px of scrolling,
   so this CMS box keeps two per row there. */
@media all and (max-width: 467px) {
    .anime-page .af-recommended .ListAnimes.Rows > li { width: 50%; }
}

.anime-page .af-comments .af-cm-load { padding: 10px 0 0; text-align: center; }

/* Reaction bar fallback, until animeflv-comments.css (watch area) draws it:
   zero / element-level specificity (:where), so any class rule there wins. */
:where(.anime-page .cm-reactions-inner) { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 15px; }
:where(.anime-page .cm-reactions-inner) button {
    display: inline-flex; align-items: center; gap: 6px; height: auto; margin: 0; padding: 4px 10px 4px 4px;
    border: 0; border-radius: 20px; background: rgba(0, 0, 0, .04); color: #3b4248; font-size: 12px; line-height: 20px;
}
:where(.anime-page .cm-reactions-inner) img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
:where(.anime-page .cm-reactions-inner) span:empty { display: none; }
