/* ==========================================================================
   Photo covers for article, module and author cards.
   Loaded after style.css and aurora.css. Every card still has its gradient + icon
   underneath, so a card without a picture (or whose picture fails to load) looks as before.
   ========================================================================== */

/* ---------- covers (article + module cards) ---------- */
.a-card .cover,.m-card .cover{height:auto;aspect-ratio:16/9;border-radius:0}
.cover .cv-img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;transition:transform .9s cubic-bezier(.2,.7,.2,1),filter .5s}
.cover.has-img{background:#0b1437}
.cover.has-img::before{display:none}                 /* the dotted pattern is only for picture-less covers */
.cover.has-img .cover-ic{display:none}
.cover .cv-scrim{position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(180deg,rgba(6,10,24,.42) 0%,rgba(6,10,24,0) 36%,rgba(6,10,24,0) 58%,rgba(6,10,24,.5) 100%)}
.cover.has-img+.a-body,.cover.has-img+.m-body{position:relative}
.a-card:hover .cv-img,.m-card:hover .cv-img{transform:scale(1.07)}
.cover .chip{z-index:2;top:14px;left:14px;font-size:.7rem;letter-spacing:.04em;text-transform:uppercase;padding:5px 12px;
  background:rgba(8,14,32,.55);border:1px solid rgba(255,255,255,.22);box-shadow:0 4px 14px rgba(0,0,0,.25)}
.a-card,.m-card{border-radius:18px}
.a-card .a-body{padding:18px 22px 22px}
.a-card .a-body h3{font-size:1.14rem;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.m-card .m-body h3{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.a-card .a-by .av{box-shadow:0 0 0 2px #fff,0 2px 8px rgba(10,22,40,.18)}

/* ---------- home hero slider: the featured article's picture ---------- */
.hs-slide>.hs-photo{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.hs-slide .hs-ov{background:linear-gradient(0deg,rgba(6,10,24,.94) 0%,rgba(6,10,24,.55) 38%,rgba(6,10,24,.18) 70%,rgba(6,10,24,.45) 100%)}

/* ---------- journal issue / archive text cards: slim picture banner ---------- */
.jcard.has-img{padding:0;overflow:hidden}
.jcard .jc-img{display:block;aspect-ratio:16/7;overflow:hidden;background:#0b1437}
.jcard .jc-img img{width:100%;height:100%;object-fit:cover;display:block;transition:transform .8s cubic-bezier(.2,.7,.2,1)}
.jcard:hover .jc-img img{transform:scale(1.06)}
.jcard.has-img>:not(.jc-img){margin-left:18px;margin-right:18px}
.jcard.has-img>.chip-soft{display:inline-block;margin-top:14px}
.jcard.has-img>div:last-child{margin-bottom:16px}

/* ---------- authors: the profile photo becomes a soft, blurred backdrop ---------- */
.bgph{position:absolute;inset:0;z-index:0;pointer-events:none;overflow:hidden}
.bgph::before{content:"";position:absolute;inset:-24px;background:var(--bg) center 25%/cover no-repeat;filter:blur(26px) saturate(1.25);opacity:.34;transform:scale(1.15)}
.bgph::after{content:"";position:absolute;inset:0;background:linear-gradient(180deg,rgba(255,255,255,.25),rgba(255,255,255,.55))}
.has-photo{position:relative;overflow:hidden}
.has-photo>:not(.bgph){position:relative;z-index:1}

/* top-author rows */
.au-row{padding:10px 14px;margin-bottom:10px;border-radius:16px;border:1px solid var(--line,rgba(11,143,127,.14));background:var(--card,#fff);
  transition:transform .35s cubic-bezier(.2,.7,.2,1),box-shadow .35s}
.rank-row.au-row+.rank-row{border-top:1px solid var(--line,rgba(11,143,127,.14))}
.au-row:last-child{margin-bottom:0}
.au-row:hover{transform:translateX(4px);box-shadow:0 8px 22px rgba(10,22,40,.12)}
.au-row .av{border:2px solid #fff;box-shadow:0 3px 12px rgba(10,22,40,.25)}
.au-row .au-txt{min-width:0}.au-row .au-txt .fw-semibold{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

/* star of the month */
.spot.has-photo{background:var(--card,#fff)}
.spot.has-photo .bgph::before{opacity:.5;filter:blur(30px) saturate(1.35)}
.spot.has-photo .bgph::after{background:linear-gradient(180deg,rgba(255,248,230,.2),rgba(255,255,255,.72))}

/* public profile hero + "about the author" boxes */
.page-hero.has-photo{overflow:hidden}
.page-hero .bgph::before{opacity:.45;filter:blur(34px) saturate(1.3);background-position:center 30%}
.page-hero .bgph::after{background:linear-gradient(135deg,rgba(10,22,40,.72),rgba(17,34,64,.55))}
.page-hero.has-photo .container{position:relative;z-index:1}
.page-hero .profile-head .av{box-shadow:0 10px 30px rgba(0,0,0,.35);border-color:rgba(255,255,255,.55)}
.bio.has-photo .bgph::before{opacity:.22}
.bio.has-photo .bgph::after{background:linear-gradient(90deg,rgba(255,255,255,.82),rgba(255,255,255,.6))}

/* ---------- dark theme ---------- */
html[data-theme=dark] .cover.has-img{background:#060914}
html[data-theme=dark] .cover .chip{background:rgba(6,9,20,.6);border-color:rgba(255,255,255,.18)}
html[data-theme=dark] .a-card .a-by .av{box-shadow:0 0 0 2px rgba(255,255,255,.2),0 2px 8px rgba(0,0,0,.4)}
html[data-theme=dark] .bgph::after{background:linear-gradient(180deg,rgba(8,12,30,.5),rgba(8,12,30,.82))}
html[data-theme=dark] .bgph::before{opacity:.4}
html[data-theme=dark] .au-row{background:rgba(255,255,255,.04);border-color:rgba(255,255,255,.09)}
html[data-theme=dark] .rank-row.au-row+.rank-row{border-top-color:rgba(255,255,255,.09)}
html[data-theme=dark] .au-row .av{border-color:rgba(255,255,255,.3)}
html[data-theme=dark] .au-row:hover{box-shadow:0 8px 24px rgba(0,0,0,.45)}
html[data-theme=dark] .spot.has-photo{background:rgba(13,20,48,.6)}
html[data-theme=dark] .spot.has-photo .bgph::after{background:linear-gradient(180deg,rgba(8,12,30,.35),rgba(8,12,30,.8))}
html[data-theme=dark] .bio.has-photo .bgph::after{background:linear-gradient(90deg,rgba(8,12,30,.85),rgba(8,12,30,.65))}
html[data-theme=dark] .jcard .jc-img{background:#060914}

/* ---------- small screens, reduced motion ---------- */
@media (max-width:575px){.a-card .a-body{padding:16px 18px 18px}.au-row{padding:9px 12px}.bgph::before{filter:blur(18px)}}
@media (prefers-reduced-motion:reduce){.cover .cv-img,.jcard .jc-img img,.au-row{transition:none}.a-card:hover .cv-img,.m-card:hover .cv-img,.jcard:hover .jc-img img{transform:none}}
