/* The stream of posts: app/templates/live_story.html and the updates on
   app/templates/article.html.

   Loaded after style.css and ops.css so the page's own rules win without
   touching the shared sheets. A stream is a list of posts in time order,
   so it wears the feed's vocabulary — a name row, a headline, a quiet
   line of facts — and separates its posts with hairlines rather than
   with boxes. */

.stream {
  margin: 0;
}

.stream-heading {
  margin: 0;
  font-size: var(--text-xs);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-label);
  color: var(--muted);
}

.stream-timeline {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
}

/* Each update is a post: the avatar stands in the gutter exactly where
   the avatar of a feed post stands, so the stream and the feed read as
   one surface. */
.stream-item {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  padding: 16px 12px 18px;
  border-top: 1px solid var(--line);
  min-width: 0;
}

.stream-timeline > .stream-item:first-child {
  border-top-color: color-mix(in srgb, var(--accent) 40%, var(--line));
}

.stream-col {
  min-width: 0;
}

/* The avatar of an update is the newsroom's own: an update is written
   by the newsroom and checked by its Verifier, so this is the one
   identity on the page that may wear the newsroom's mark. */
.post-avatar--live {
  width: 40px;
  height: 40px;
  font-size: var(--text-md);
}

/* The update's headline is a post's headline: the same weight, the same
   tracking, only a step smaller because an update is a step smaller
   than a material. */
.stream-title {
  margin: 4px 0 8px;
  font-size: var(--text-lg);
  font-weight: var(--font-weight-bold);
  line-height: 1.3;
  letter-spacing: var(--tracking-tight);
  color: var(--text);
}

/* The body of an update is a post's body: one measure, room to breathe,
   paragraphs separated by space and not by rules. */
.stream-body {
  font-size: var(--text-sm);
  line-height: 1.7;
  color: var(--text);
  max-width: 68ch;
}

.stream-body p { margin: 0 0 12px; }
.stream-body p:last-child { margin-bottom: 0; }

/* The sources of an update are hairlines under it, not a panel: the
   reader checks the link, then reads on. */
.stream-item .update-sources {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
  display: grid;
  gap: 4px;
}

.stream-item .source-item {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px;
  font-size: var(--text-2xs);
  line-height: 1.5;
}

.stream-item .source-url {
  color: var(--muted);
  overflow-wrap: anywhere;
}

@media (max-width: 620px) {
  .stream-item {
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 10px;
    padding: 14px 4px 16px;
  }
  .post-avatar--live {
    width: 36px;
    height: 36px;
    font-size: var(--text-base);
  }
  .stream-title { font-size: var(--text-base); }
}
