/* Shared Narzan geometry; only media fitting and article-specific layering. */
#blagodat-theatre .article-hero-figure { position:relative; z-index:6; }
#blagodat-theatre .story-g__hero-background { object-position:50% 50%; }
#blagodat-theatre .story-g__hero-front { object-position:50% 45%; }
#blagodat-theatre .article-hero-figure figcaption { position:relative; margin-top:20px; padding:6px 10px; border-radius:8px; width:fit-content; max-width:100%; background:var(--g-paper); }
#blagodat-theatre .article-opening .article-photo { position:relative; }
#blagodat-theatre .story-g__slide > img { object-fit:contain; }
#blagodat-theatre .narzan-side-photo figcaption { margin-top:8px; font:400 var(--article-caption-size)/var(--article-caption-leading) var(--article-body-font); }
#blagodat-theatre a { text-decoration:none; }
#blagodat-theatre a:focus-visible { outline:2px solid currentColor; outline-offset:3px; }
.g-readable #blagodat-theatre a { text-decoration:underline; }
/* Same non-focused skip-link clipping as the approved Yaroshenko article. */
body[data-article-sample="blagodat-theatre-local-v8"] .g-skip:not(:focus) { clip-path:inset(50%); }
@media (max-width:639px) {
 #blagodat-theatre .narzan-side-photo { transform-origin:center 60px; }
 #blagodat-theatre .narzan-side-photo--left .story-g__pin { left:8px; }
 #blagodat-theatre .narzan-side-photo--right .story-g__pin { right:8px; }
 #blagodat-theatre .narzan-side-photo figcaption { transform-origin:top center; text-align:center; }
 #blagodat-theatre .narzan-side-photo--left figcaption { transform:rotate(15deg); }
 #blagodat-theatre .narzan-side-photo--right figcaption { transform:rotate(-15deg); }
}
/* Restore the approved people illustration role above the generic icon adapter. */
#blagodat-theatre .article-paper-icon.narzan-paper-icon--people { width:110px; right:-4px; top:-56px; }
@media (min-width:640px) { #blagodat-theatre .article-paper-icon.narzan-paper-icon--people { width:140px; right:-12px; top:-64px; } }
@media (min-width:1024px) { #blagodat-theatre .article-paper-icon.narzan-paper-icon--people { width:150px; } }
/* Contained photos retain their own rounded visible edge, as in Yaroshenko. */
#blagodat-theatre .story-g__slide:not([hidden]) { display:grid; grid-template-columns:minmax(0,1fr); grid-template-rows:var(--article-gallery-photo-height) auto; }
#blagodat-theatre .story-g__slide > img { width:auto; height:auto; max-width:100%; max-height:100%; aspect-ratio:auto; place-self:center; object-fit:contain; }

/* Accepted vertical video player and caption styling. */
#blagodat-theatre .article-video {
  position: relative;
  width: min(100%, 420px);
  margin: 0 auto;
}


.article-video-frame {
  position: relative;
  container-type: inline-size;
  width: 100%;
  aspect-ratio: var(--video-aspect, 9 / 16);
  border-radius: var(--article-photo-radius);
  overflow: hidden;
  background: #17241b;
}

.article-video-play,
.article-video-play img,
.article-video-frame > video {
  display: block;
  width: 100%;
  height: 100%;
}

.article-video-play {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.article-video-play:focus-visible,
.article-video-frame > video:focus-visible {
  outline: 3px solid white;
  outline-offset: -4px;
}

.article-video-play img {
  object-fit: cover;
}

.article-video-play-icon {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: rgb(61 50 138 / 86%);
  color: white;
}

.article-video > .story-g__pin {
  pointer-events: none;
}

.article-video-frame[data-playing] + .story-g__pin {
  visibility: hidden;
}

.article-video-frame video::cue {
  color: white;
  background-color: rgb(0 0 0 / 76%);
}

.article-video-frame video.has-caption-layer:not(:fullscreen)::cue {
  opacity: 0;
  color: transparent;
  background-color: transparent;
  text-shadow: none;
}

.article-video-caption-layer {
  position: absolute;
  inset-inline: .5rem;
  inset-inline: clamp(.25rem, 2cqw, .7rem);
  inset-block-end: clamp(3.75rem, 14%, 7rem);
  display: grid;
  justify-items: center;
  pointer-events: none;
}

.article-video-caption-layer[hidden] {
  display: none;
}

.article-video-caption {
  box-sizing: border-box;
  max-inline-size: 100%;
  padding: .46em .9em .5em;
  padding-inline: clamp(.4rem, 3.6cqw, .9em);
  border-radius: .56rem;
  background: rgb(61 50 138 / 72%);
  color: #fffaf0;
  font-family: "PT Sans Local", system-ui, sans-serif;
  font-size: 1rem;
  font-size: clamp(.875rem, 4.85cqw, 1.25rem);
  font-weight: 400;
  line-height: 1.22;
  text-align: center;
  white-space: pre-line;
  overflow-wrap: anywhere;
}

.article-video figcaption {
  margin-top: 10px;
  text-align: center;
}


#blagodat-theatre .article-photo.photo-natural>img:first-child{aspect-ratio:auto;object-fit:contain}
#blagodat-theatre .article-photo.photo-document>img:first-child{object-fit:contain}

/* Direct media adjustments requested by Marina on 20 November; shared text/paper tokens preserved. */
#revival .photo-vitraz { width:86%; margin-inline:auto!important; }
#revival .photo-vitraz>img:first-child { aspect-ratio:1116/1269; object-fit:cover; object-position:50% 0%; }
#research .photo-books-view { aspect-ratio:16/9; overflow:hidden; border-radius:var(--article-photo-radius); }
#research .photo-books-view>img { display:block; width:100%; height:100%; object-fit:cover; object-position:50% 0%; transform:rotate(-1deg) scale(1.035); filter:brightness(.92); }
#today .photo-salon { width:86%; margin-inline:auto!important; }
#today .photo-salon>img:first-child { aspect-ratio:3918/4662; object-fit:cover; object-position:50% 100%; }
#blagodat-theatre .paper-book { width:110px; top:-42px; right:-4px; }
#blagodat-theatre .paper-book img { max-height:none; }
#ending .narzan-today-copy p { font:400 var(--article-body-size)/var(--article-body-leading) var(--article-body-font); }
@media(min-width:640px) { #blagodat-theatre .paper-book { width:140px; top:-50px; right:-12px; } }
@media(min-width:1024px) {
 #today .article-split { align-items:start; }
 #today .article-photo { align-self:start; }
 #blagodat-theatre .paper-book { width:150px; }
}

/* Marina's v4: a lower, wider star oval and a larger, closer institution acknowledgement. */
#star { padding-top:72px; }
#star .article-ending-copy { max-width:940px; }
#star .article-final-note { max-width:none; padding:54px 44px; }
#star .article-final-note p { max-width:740px; margin-inline:auto; }
#institution-thanks .narzan-thanks { gap:12px; }
#institution-thanks .narzan-thanks p { justify-self:start; }
#institution-thanks .institution-thanks-logo img { max-height:120px; }
@media(max-width:639px) {
 #star .article-final-note { padding:54px 28px; }
 #institution-thanks .institution-thanks-logo img { max-height:100px; }
}

/* Marina's v5: compact transitions and a balanced acknowledgement with more breathing room. */
#blagodat-theatre #park-gallery { padding-bottom:24px; }
#blagodat-theatre #park-gallery figcaption { min-block-size:2.5em; }
#star { padding-bottom:12px; }
#ending { padding-top:0; padding-bottom:28px; }
#ending .narzan-today-copy { align-self:start; }
#ending .narzan-side-photo { margin-bottom:0!important; }
#ending .narzan-side-photo--right { margin-top:48px!important; }
#institution-thanks { padding-top:16px; }
#institution-thanks .narzan-thanks { gap:18px; }
@media(max-width:639px) {
 #institution-thanks .narzan-thanks p { justify-self:center; text-align:center; }
}
@media(min-width:640px) {
 #institution-thanks .narzan-thanks { grid-template-columns:181px fit-content(360px); column-gap:32px; justify-content:center; align-items:center; }
}
@media(min-width:1024px) { #ending .narzan-side-photo--right { margin-top:64px!important; } }

/* Marina: the bold phrase in the central closing text uses the brand blue. */
.g-page:not(.g-readable) #ending .narzan-today-copy strong { color:#3d328a; }
