/* Story reshares: source author's REAL avatar left, clearly readable CTA.
   Normal camera stories retain their original fullscreen behavior. */
#story-overlay.pati-story-has-source .pati-story-share-card{
 padding:0!important;gap:0!important;
 border-radius:16px!important;overflow:hidden!important;
 border:0!important;
 width:min(79vw,326px)!important;max-height:100%!important;
 background:#fff!important;box-shadow:0 16px 45px #0006!important;
}
#story-overlay.pati-story-has-source .pati-story-share-card-heading{
 display:flex!important;align-items:center!important;
 padding:10px 11px!important;margin:0!important;
 gap:9px!important;min-width:0!important;min-height:58px!important;
 background:#fff!important;color:#181a1e!important;
}
#story-overlay.pati-story-has-source .pati-story-share-profile{
 display:flex!important;align-items:center!important;gap:9px!important;
 min-width:0!important;width:100%!important;max-width:100%!important;
 padding:0!important;margin:0!important;border:0!important;
 background:transparent!important;color:#181a1e!important;text-align:left!important;
 cursor:pointer!important;
}
#story-overlay.pati-story-has-source .pati-story-share-profile>.avatar,
#story-overlay.pati-story-has-source .pati-story-share-profile>.avatar.s,
#story-overlay.pati-story-has-source .pati-story-share-default-avatar{
 display:grid!important;place-items:center!important;
 width:35px!important;height:35px!important;min-width:35px!important;
 flex:0 0 35px!important;border-radius:50%!important;overflow:hidden!important;
 background:#222!important;color:#fff!important;font-size:14px!important;
}
#story-overlay.pati-story-has-source .pati-story-share-profile .avatar img{
 width:100%!important;height:100%!important;object-fit:cover!important;
}
#story-overlay.pati-story-has-source .pati-story-share-profile>span:last-child{
 display:flex!important;flex-direction:column!important;min-width:0!important;gap:3px!important;
}
#story-overlay.pati-story-has-source .pati-story-share-profile strong{
 display:block!important;min-width:0!important;font-weight:850!important;
 color:#1b1b1e!important;font-size:13px!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important;
}
#story-overlay.pati-story-has-source .pati-story-share-profile small{
 display:block!important;color:#71747a!important;font-size:11px!important;
}
#story-overlay.pati-story-has-source .pati-story-share-media{
 width:100%!important;min-height:110px!important;
 height:min(35dvh,315px)!important;max-height:min(35dvh,315px)!important;
 border-radius:0!important;margin:0!important;background:#f2f2f3!important;
}
#story-overlay.pati-story-has-source .pati-story-share-media>img,
#story-overlay.pati-story-has-source .pati-story-share-media>video{
 border-radius:0!important;background:#f2f2f3!important;
 width:100%!important;height:100%!important;object-fit:contain!important;
}
#story-overlay.pati-story-has-source .pati-story-share-post-caption{
 padding:8px 13px 0!important;margin:0!important;color:#4b4d53!important;
 font-size:12px!important;line-height:1.4!important;
}
#story-overlay.pati-story-has-source .pati-story-share-card>.pati-story-shared-source{
 display:flex!important;align-items:center!important;justify-content:space-between!important;
 position:relative!important;inset:auto!important;
 width:calc(100% - 20px)!important;margin:10px!important;
 max-width:100%!important;min-height:44px!important;height:44px!important;
 flex:0 0 44px!important;box-sizing:border-box!important;
 padding:9px 13px!important;border:0!important;border-radius:11px!important;
 background:#111216!important;color:#fff!important;opacity:1!important;
 font-size:13px!important;line-height:1.3!important;letter-spacing:0!important;
 font-weight:850!important;text-shadow:none!important;
 box-shadow:0 4px 12px #00000024!important;
}
#story-overlay.pati-story-has-source .pati-story-share-card>.pati-story-shared-source>span{
 font-size:19px!important;line-height:1!important;color:#fff!important;
}
#story-overlay.pati-story-has-source .pati-story-share-sound{z-index:12!important}
@media(max-width:740px){
 #story-overlay.pati-story-has-source .pati-story-share-card{width:min(80vw,326px)!important}
}
@media(max-height:670px){
 #story-overlay.pati-story-has-source .pati-story-share-media{height:min(29dvh,225px)!important;max-height:min(29dvh,225px)!important}
 #story-overlay.pati-story-has-source .pati-story-share-card>.pati-story-shared-source{min-height:39px!important;height:39px!important;flex-basis:39px!important}
}
/* Tagged/shared post cards in DM: no black outer bubble or black bands around media. 
   Text-only outgoing messages remain black as chosen by the user. */
#main-content .pati-dm-layout .chat-window .chat-history .bubble-chat.pati-dm-shared-message,
#main-content .pati-dm-layout .chat-window .chat-history .bubble-chat.mine.pati-dm-shared-message,
html[data-pati-theme="dark"] #main-content .pati-dm-layout .chat-window .chat-history .bubble-chat.mine.pati-dm-shared-message{
 box-sizing:border-box!important;
 width:min(84vw,375px)!important;max-width:min(88vw,375px)!important;min-width:0!important;
 padding:0!important;margin:0!important;overflow:hidden!important;
 background:transparent!important;border:0!important;box-shadow:none!important;
 color:inherit!important;border-radius:14px!important;
}
#main-content .pati-dm-layout .chat-history .bubble-chat.pati-dm-shared-message>.pati-dm-shared-card{
 width:100%!important;box-sizing:border-box!important;border-radius:14px!important;
 overflow:hidden!important;background:#fff!important;color:#1a1c21!important;
 border:1px solid #e9e9eb!important;
}
html[data-pati-theme="dark"] #main-content .pati-dm-layout .chat-history .bubble-chat.pati-dm-shared-message>.pati-dm-shared-card{
 background:#26272b!important;color:#f3f3f4!important;border-color:#41444c!important;
}
#main-content .pati-dm-layout .pati-dm-shared-media,
#main-content .pati-dm-layout .pati-dm-shared-video-wrap{
 background:transparent!important;
}
#main-content .pati-dm-layout .pati-dm-shared-video{
 object-fit:contain!important;background:transparent!important;
}
#main-content .pati-dm-layout .pati-dm-shared-footer{
 min-height:40px!important;padding:10px 12px!important;
 font-size:13px!important;font-weight:850!important;color:#1683f6!important;
}
#main-content .pati-dm-layout .bubble-chat.pati-dm-shared-message>small{
 background:transparent!important;color:#777e88!important;font-size:10px!important;
 padding:3px 7px!important;text-align:right!important;
}
