/* RedFeed — video/foto deitado ou quadrado: formato original, inteiro e no meio (sem zoom).
   Em pe continua preenchendo (regras do feed/reels). O atributo vem de rf-media-fit.js.
   Atributo repetido = mais especificidade que as regras "cover" do feed (rf-feed-instagram-media.css). */

/* —— Cartao do feed: a caixa assume a proporcao da propria midia —— */
html body .rf-post-media[data-rf-media-shape="wide"][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape] {
  aspect-ratio: var(--rf-media-ratio, 16 / 9) !important;
  height: auto !important;
  max-height: min(82vh, 820px) !important;
  background: #000 !important;
}

html body .rf-post-media[data-rf-media-shape="wide"][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape] video,
html body .rf-post-media[data-rf-media-shape="wide"][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape] img,
html body .rf-post-media[data-rf-media-shape="wide"][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape][data-rf-media-shape] .rf-feed-vid-poster {
  object-fit: contain !important;
  object-position: center center !important;
  background: #000 !important;
}

/* —— Tela cheia (feed, Explorar e perfil): midia deitada inteira, centralizada —— */
#rfFeedReelsViewer .rf-feed-reels-media-wrap[data-rf-media-shape="wide"] video,
#rfFeedReelsViewer .rf-feed-reels-media-wrap[data-rf-media-shape="wide"] img,
#rfFeedReelsViewer .rf-feed-reels-media-wrap[data-rf-media-shape="wide"] .rf-reels-poster-cover,
#rfFeedReelsViewer .rf-feed-reels-media-wrap video[data-rf-media-shape="wide"],
#rfFeedReelsViewer .rf-feed-reels-media-wrap img[data-rf-media-shape="wide"],
#rfProfileReelsViewer .rf-feed-reels-media-wrap[data-rf-media-shape="wide"] video,
#rfProfileReelsViewer .rf-feed-reels-media-wrap[data-rf-media-shape="wide"] img,
#rfProfileReelsViewer .rf-feed-reels-media-wrap[data-rf-media-shape="wide"] .rf-reels-poster-cover,
#rfProfileReelsViewer .rf-feed-reels-media-wrap video[data-rf-media-shape="wide"],
#rfProfileReelsViewer .rf-feed-reels-media-wrap img[data-rf-media-shape="wide"] {
  object-fit: contain !important;
  object-position: center center !important;
  transform: none !important;
  background: #000 !important;
}
