/* R40 profil – the living portrait on /profil (replaces the §6 rules of site-r34.css). See profil.js. */

/* ---------- a bigger photo, still inside its frame and its column (desktop ≈ 360 px instead of 330 px) */
@media (min-width:1101px){
  /* the portrait may reach 8 px into the gap towards the text – the grid itself stays as it is */
  .page-profil .home-hero .portrait{width:min(380px,calc(100% + 8px));max-width:none;justify-self:end}
}
@media (min-width:761px) and (max-width:1100px){
  /* two columns: the portrait reaches 20 px into the gap (gap is 6 % of the width) */
  .page-profil .home-hero .portrait{width:min(372px,calc(100% + 20px));max-width:none;justify-self:end}
}
@media (max-width:760px){
  .page-profil .home-hero .portrait{width:min(310px,86%);max-width:none}
}

/* ---------- the layers: photo without glasses, photo with glasses, the stage with the films, button and mark on top */
.portrait-frame.pf40>.portrait-alt{z-index:1}
.portrait-frame.pf40>img{opacity:0!important;transition:none!important;scale:1!important;translate:none!important;transform:none!important}
.portrait-frame.pf40[data-still=plain]>img:not(.portrait-alt),
.portrait-frame.pf40[data-still=brille]>img[data-variant=brille]{opacity:1!important}
/* while a film shows, data-still already names the photo it will end on; the photos stay hidden underneath (both are
   multiplied onto the paper – two layers would darken the picture) */
.portrait-frame.pf40.pf-filming>img{visibility:hidden}
.portrait-frame>.pf-stage{position:absolute;inset:0;z-index:2;isolation:isolate;mix-blend-mode:multiply;opacity:0;pointer-events:none;visibility:hidden}
.portrait-frame>.pf-stage.is-on{opacity:1;visibility:visible}
.pf-stage>:is(video,canvas,img){position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center;mix-blend-mode:normal;opacity:0;pointer-events:none;scale:1!important;transform:none!important}
.pf-stage>video.is-on{opacity:1}
.pf-stage>canvas.pf-snap{z-index:2}
.pf-stage>canvas.pf-snap.is-on{opacity:1}
.pf-stage>canvas.pf-snap.is-fading{opacity:0;transition:opacity .38s ease}
/* R42 bewegung: the end of the grin – the held last picture fades into the still (0.25 s) */
.pf-stage>img.pf-still{z-index:1}
.pf-stage>img.pf-still.is-on{opacity:1}
.pf-stage>canvas.pf-snap.is-ending{opacity:0;transition:opacity .25s ease}
html[data-theme=dark] .pf-stage>img.pf-still.pf-light,html:not([data-theme=dark]) .pf-stage>img.pf-still.pf-dark{display:none}
.portrait-frame.pf40 .portrait-mark{z-index:3}
/* the fine inner line of the frame lies over photo and film alike (before, the glasses photo covered it) */
.portrait-frame.pf40:after{z-index:3}

/* ---------- dark mode: the dark photos and the dark versions of the films (R45: tools/darkportrait45.py – one keying for
   photo and film, the paper replaced by the dark backdrop, no light seam in the curls). Shown as they are.
   R46 haare46: v46 / -dunkel46 – real hair matte (tools/haare46.py), the curls keep colour and gloss, no dark cape. */
html[data-theme=dark] body.page-profil .portrait-frame>img:not(.portrait-alt){content:url(/assets/r41/profilfoto-dunkel-v50.jpg)}
html[data-theme=dark] body.page-profil .portrait-frame>img[data-variant=brille]{content:url(/assets/r41/profilfoto-brille-dunkel-v50.jpg)}
html[data-theme=dark] .portrait-frame>.pf-stage{mix-blend-mode:normal}
html[data-theme=dark] .pf-stage>video.pf-light,html:not([data-theme=dark]) .pf-stage>video.pf-dark{display:none}

/* ---------- reading mode and reduced motion: only the photos */
html[data-read=on] .portrait-frame>.pf-stage,html.motion-paused .portrait-frame>.pf-stage{display:none}
@media (prefers-reduced-motion:reduce){.portrait-frame>.pf-stage{display:none}}
