/* Shieldy Welcome/Goodbye preview grouping.
   The wrapper is presentation-only: one Lolka send == one visible message payload. */
#sh-interaction-view-welcome .welcome-preview-message-visual-group{
  display:grid!important;
  grid-template-columns:minmax(0,1fr)!important;
  gap:0!important;
  width:100%!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
}
#sh-interaction-view-welcome .welcome-preview-message-visual-group[hidden]{display:none!important}

/* Existing bundle rules expect Embed/Card to be direct children of the slot.
   V761 intentionally adds a grouping node, so own the sizing here. */
#sh-interaction-view-welcome [data-preview-primary-card-slot]>.welcome-preview-message-visual-group{
  width:calc(100% - 42px)!important;
  max-width:none!important;
  margin:2px 0 0 42px!important;
}
#sh-interaction-view-welcome [data-preview-secondary-card-slot]>.welcome-preview-message-visual-group{
  width:100%!important;
  max-width:none!important;
  margin:0!important;
}
#sh-interaction-view-welcome .welcome-preview-message-visual-group>.welcome-native-embed-shell,
#sh-interaction-view-welcome .welcome-preview-message-visual-group>.welcome-embed-preview{
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  min-width:0!important;
}

/* When both visual components are enabled, make them one continuous payload.
   This removes the false impression that “1 message” is actually two messages. */
#sh-interaction-view-welcome .welcome-preview-message-visual-group[data-preview-component-count="2"]{
  overflow:hidden!important;
  border:1px solid #343d4b!important;
  border-radius:10px!important;
  background:#1b2028!important;
  box-shadow:0 4px 12px rgba(0,0,0,.14)!important;
}
#sh-interaction-view-welcome .welcome-preview-message-visual-group[data-preview-component-count="2"]>.welcome-native-embed-shell{
  border-left-width:4px!important;
  border-top:0!important;
  border-right:0!important;
  border-bottom:0!important;
  border-radius:0!important;
  box-shadow:none!important;
}
#sh-interaction-view-welcome .welcome-preview-message-visual-group[data-preview-component-count="2"]>.welcome-embed-preview{
  border-left:0!important;
  border-right:0!important;
  border-bottom:0!important;
  border-radius:0!important;
  box-shadow:none!important;
}
#sh-interaction-view-welcome .welcome-preview-message-visual-group[data-preview-component-count="2"]>.welcome-native-embed-shell+.welcome-embed-preview{
  border-top:1px solid #343d4b!important;
}

/* Make the single-message boundary explicit without inventing a second author. */
#sh-interaction-view-welcome [data-preview-primary-message][data-preview-delivery="combined"]{
  outline:1px solid rgba(45,164,78,.22)!important;
  outline-offset:-1px!important;
}

@media(max-width:720px){
  #sh-interaction-view-welcome [data-preview-primary-card-slot]>.welcome-preview-message-visual-group{
    width:100%!important;
    margin-left:0!important;
  }
}
