/* Real Laravel feed preview integration.
   Only dynamically injected cards use these additions; the original demo
   remains available as fallback when no real posts are returned. */
.post-list.is-loading-real-feed {
  opacity: .72;
  transition: opacity .16s ease;
}

/* As soon as real Laravel posts are present, the static template cards no
   longer mix into the live feed. They remain in the markup as a visual
   fallback/reference for future content types. */
.post-list:has(> [data-real-feed-post]) > .social-post:not([data-real-feed-post]) {
  display: none;
}

.real-feed-post {
  position: relative;
}

.real-feed-post .post-head {
  align-items: center;
}

.real-feed-post .real-feed-author-avatar {
  width: 38px;
  height: 38px;
  min-width: 38px;
  display: block;
  flex: 0 0 38px;
  overflow: hidden;
  border-radius: 50%;
  text-decoration: none;
}

.real-feed-post .real-feed-author-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: inherit;
  object-fit: cover;
  object-position: center;
}

.real-feed-post .post-author a {
  color: inherit;
  text-decoration: none;
}

.real-feed-post .post-body > p {
  white-space: normal;
  overflow-wrap: anywhere;
}

.real-feed-pinned {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 500;
  white-space: nowrap;
}

.real-post-media-grid {
  display: grid;
  width: 100%;
  margin-top: 18px;
  gap: 8px;
  overflow: hidden;
  border-radius: 28px;
  background: rgba(48,48,46,.06);
}

.real-post-media-grid.real-post-media-count-1 {
  grid-template-columns: minmax(0, 1fr);
}

.real-post-media-grid.real-post-media-count-2,
.real-post-media-grid.real-post-media-count-3,
.real-post-media-grid.real-post-media-count-4 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.real-post-media-item {
  position: relative;
  min-height: 210px;
  overflow: hidden;
  background: rgba(48,48,46,.10);
  text-decoration: none;
}

/* Single media stays deliberately flatter in the feed. The complete image
   will later open uncropped in the media/comments modal. */
.real-post-media-count-1 .real-post-media-item {
  height: clamp(240px, 28vw, 420px);
  min-height: 0;
}

.real-post-media-count-3 .real-post-media-item:first-child {
  grid-row: span 2;
}

.real-post-media-item img,
.real-post-media-item video {
  width: 100%;
  height: 100%;
  min-height: inherit;
  display: block;
  object-fit: cover;
  object-position: center;
}

.real-post-video-item {
  background: #111;
}

.real-post-file-item {
  display: grid;
  place-items: center;
  color: var(--ink);
  font-weight: 600;
}

.real-post-media-more {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(24,24,22,.62);
  color: #fff;
  font-size: 28px;
  font-weight: 600;
}

.real-feed-poll {
  margin-top: 18px;
}

.real-feed-poll-question {
  display: block;
  margin-bottom: 10px;
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
}

.real-feed-following-mode .post-list > .social-post:not([data-real-feed-post]) {
  display: none;
}

@media (max-width: 899px) {
  .real-feed-pinned {
    display: none;
  }

  .real-post-media-grid {
    border-radius: 20px;
  }

  .real-post-media-item {
    min-height: 150px;
  }

  .real-post-media-count-1 .real-post-media-item {
    height: min(62vw, 360px);
    min-height: 220px;
  }
}