/* ─── Shared (editor + public) ──────────────────────────────────────── */

.lexxy-content action-text-attachment:has(.attachment--embed) {
  display: flex;
  flex-direction: column;
  position: relative;
}

.lexxy-content .attachment--embed {
  margin: 0;
  position: relative;
  inline-size: 100%;
  max-inline-size: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  overflow: hidden;
}

.lexxy-content .attachment--embed iframe {
  position: absolute;
  inset: 0;
  inline-size: 100%;
  block-size: 100%;
  border: 0;
}

.lexxy-content p:has(.attachment--embed),
.lexxy-content .attachment--embed {
  text-align: start;
}

.lexxy-content action-text-attachment:has(.attachment--embed) .attachment__caption {
  text-align: center;
}

/* ─── Public only ───────────────────────────────────────────────────── */

.lexxy-content:not(lexxy-editor) action-text-attachment:has(.attachment--embed) {
  gap: 0.5rem;
}
