.feed-page,
.home-stream-wrap.feed-stream-layout {
  max-width: 720px;
  margin: 0 auto;
}

.feed-page-toolbar {
  margin: 0 0 14px;
  padding: 0 0 8px;
  border-bottom: 1px solid #e2e8f0;
}

.feed-settings-btn {
  flex-shrink: 0;
  width: auto;
  height: auto;
  padding: 0 0 6px;
  margin-bottom: -8px;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 15px;
  line-height: 1.2;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
}

.feed-settings-btn:hover {
  color: #1d4ed8;
  background: transparent;
}

.feed-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 18px;
  margin: 0;
}

.feed-tabs a {
  display: inline-flex;
  align-items: center;
  padding: 0 0 6px;
  margin-bottom: -8px;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  color: #64748b;
  box-shadow: none;
}

.feed-tabs a:hover {
  color: #1e293b;
  background: transparent;
}

.feed-tabs a.active {
  color: #1e293b;
  background: transparent;
  border: 0;
  box-shadow: inset 0 -2px 0 #2563eb;
}

.feed-tab-badge {
  margin-left: 4px;
  font-size: 13px;
  font-weight: 800;
  color: #2563eb;
  line-height: 1;
}

.feed-tab-badge[hidden] {
  display: none;
}

.feed-page-mobile-tight {
  margin-top: 0;
}

@media (max-width: 720px) {
  .feed-page-mobile-tight {
    margin-top: -8px;
  }

  .feed-tabs .feed-tab--extra {
    display: none;
  }
}

.feed-design.adj {
  margin-top: calc(-18px - 1.5rem);
  padding-top: 8px;
}

.feed-design .adj__sheet {
  padding-top: 8px;
}

.feed-design .feed-page {
  width: 100%;
  max-width: none;
}

.feed-design .feed-page-toolbar--adjacent {
  margin: 0 0 16px;
  padding: 0;
  border: 0;
}

.feed-design .feed-switch {
  display: block;
  min-width: 0;
}

.feed-design .feed-switch__links {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 14px;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}

.feed-design .feed-switch__plus {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  line-height: 0;
  text-decoration: none;
}

.feed-design .feed-switch__plus img {
  display: block;
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.feed-design .feed-switch__links::-webkit-scrollbar {
  display: none;
}

.feed-design .feed-switch__link {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 4px;
  color: var(--rdx-muted, #6b736c);
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
}

.feed-design .feed-switch__link.is-active,
.feed-design .feed-switch__link[aria-current="page"] {
  color: var(--rdx-ink, #1a1f1c);
}

.feed-design .feed-switch__count {
  min-width: 18px;
  padding: 1px 5px;
  border-radius: 999px;
  background: rgba(26, 31, 28, 0.08);
  font-size: 0.68rem;
  font-weight: 750;
  line-height: 1.3;
  text-align: center;
}

.feed-design .feed-switch__count[hidden] {
  display: none;
}

.feed-design .feed-switch__link.is-active .feed-switch__count,
.feed-design .feed-switch__link[aria-current="page"] .feed-switch__count {
  background: rgba(26, 31, 28, 0.12);
}

.feed-design .feed-toolbar-tools {
  grid-area: tools;
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
}

.feed-design .feed-create-btn-adjacent {
  white-space: nowrap;
}

.feed-design .feed-settings-btn-adjacent {
  appearance: none;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--rdx-ink, #1a1f1c);
  cursor: pointer;
}

.feed-design .feed-settings-btn-adjacent:hover {
  background: #f3f1eb;
}

.feed-design .feed-stories-strip .stories-grid {
  align-items: flex-start;
  gap: 14px;
  padding: 6px 2px 2px;
}

.feed-design .feed-story-circle {
  display: flex;
  flex: 0 0 72px;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 72px;
  min-width: 72px;
}

.feed-design .feed-story-extra {
  display: none;
}

.feed-design .feed-stories-strip .story-item,
.feed-design .feed-stories-strip .story-item[data-story-id] {
  flex: 0 0 72px;
  width: 72px;
  min-width: 72px;
  max-width: 72px;
  height: 72px;
  min-height: 72px;
  max-height: 72px;
  aspect-ratio: 1 / 1;
  margin: 0;
  border: 0;
  border-radius: 50%;
  overflow: hidden;
  background: #e8ece8;
  box-shadow: none;
}

.feed-design .feed-stories-strip .story-preview,
.feed-design .feed-stories-strip .story-item .story-preview,
.feed-design .feed-stories-strip .story-preview-hit {
  border-radius: 50%;
}

.feed-design .feed-stories-strip .story-overlay,
.feed-design .feed-stories-strip .diary-card-author-badge,
.feed-design .feed-stories-strip .story-strip-manage,
.feed-design .feed-stories-strip .story-strip-manage-controls {
  display: none;
}

.feed-design .feed-story-circle__name {
  display: block;
  max-width: 72px;
  overflow: hidden;
  color: var(--rdx-ink, #1a1f1c);
  font-size: 0.68rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
  text-overflow: ellipsis;
}

@media (max-width: 720px) {
  .feed-design .feed-switch__links {
    gap: 16px;
    padding-bottom: 2px;
  }
}

.feed-design .feed-tab-badge {
  margin-left: 2px;
  color: inherit;
  font-size: 0.68rem;
}

.feed-design .feed-page-body {
  gap: 14px;
}

.feed-design .profile-modal-post-card,
.feed-design .feed-pinned-post {
  border-color: var(--rdx-line, #e8ebe6);
  border-radius: var(--rdx-radius-card, 16px);
  box-shadow: var(--rdx-shadow-card, 0 8px 20px rgba(26, 31, 28, 0.05));
}

.feed-design .profile-modal-post-title,
.feed-design .feed-pinned-post__title {
  color: var(--rdx-ink, #1a1f1c);
  font-family: var(--rdx-serif, "Literata", serif);
  letter-spacing: -0.015em;
}

.feed-design .feed-fallback-divider {
  color: var(--rdx-muted, #6b736c);
}

.feed-design .feed-fallback-divider__line {
  background: var(--rdx-line, #e8ebe6);
}

@media (max-width: 720px) {
  .feed-design {
    padding-inline: 8px;
  }

  .feed-design .feed-page-mobile-tight {
    margin-top: 0;
  }

  .feed-design .adj__sheet {
    padding: 8px 12px 22px;
    border-radius: 20px;
  }

  .feed-design .feed-switch__pill {
    padding: 8px 12px;
    font-size: 0.82rem;
  }

  .feed-design .feed-stories-strip .stories-grid,
  .feed-design .feed-stories-strip [data-stories-track] {
    align-items: flex-start !important;
  }

  .feed-design .feed-story-circle {
    flex: 0 0 72px !important;
    width: 72px !important;
    min-width: 72px !important;
    max-width: 72px !important;
  }

  .feed-design .feed-stories-strip .story-item,
  .feed-design .feed-stories-strip .story-item[data-story-id] {
    flex: 0 0 72px !important;
    width: 72px !important;
    min-width: 72px !important;
    max-width: 72px !important;
    height: 72px !important;
    min-height: 72px !important;
    max-height: 72px !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
  }

  .feed-design .feed-stories-strip .story-preview,
  .feed-design .feed-stories-strip .story-item .story-preview,
  .feed-design .feed-stories-strip .story-preview-hit {
    border-radius: 50% !important;
  }
}
