.social-feed-heading, .social-feed-tabs, .social-feed-shell { width: 100%; max-width: 680px; margin-inline: auto; }
.social-feed-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.social-feed-heading h1 { margin: 0; font-size: 26px; letter-spacing: 0; }
.social-context-tabs { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; max-width: 100%; }
.social-context-tabs a { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-width: 44px; min-height: 44px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--card); color: var(--muted); font-size: 13px; line-height: 1.4; letter-spacing: 0; }
.social-context-tabs a .icon { width: 20px; height: 20px; }
.social-context-tabs a:hover { background: var(--raised); color: var(--accent-text); }
.social-context-tabs a[aria-current='page'] { border-color: var(--accent-border); background: var(--accent-soft); color: var(--accent-text); font-weight: 700; }
.social-feed-tabs { display: flex; border-bottom: 1px solid var(--line); gap: 26px; margin-bottom: 18px; }
.social-feed-tabs a { display: inline-flex; align-items: center; min-height: 44px; padding: 9px 2px; color: var(--muted); }
.social-feed-tabs a[aria-current='page'] { color: var(--accent-text); border-bottom: 2px solid var(--gold); font-weight: 700; }
.social-listing-tabs > button { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 9px 2px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: transparent; color: var(--muted); font: inherit; }
.social-listing-tabs > button[aria-current='page'] { color: var(--accent-text); border-bottom-color: var(--gold); font-weight: 700; }
.social-listing-tabs > button .icon { width: 18px; height: 18px; }
.social-listing-create { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; max-width: 680px; margin: 0 auto 18px; }
#social-listing-composer { width: 100%; max-width: 680px; margin-inline: auto; }
.social-listing-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; width: 100%; max-width: 680px; margin: -4px auto 18px; }
.social-listing-filters[hidden] { display: none; }
.social-listing-filters label { display: flex; flex-direction: column; gap: 7px; min-width: 0; color: var(--muted); font-size: 13px; }
.social-listing-filters select { width: 100%; min-width: 0; min-height: 44px; padding: 8px 10px; border: 1px solid var(--control-border); border-radius: 6px; background: var(--card); color: var(--text); }
.social-feed-shell { min-width: 0; }
.social-stream { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.social-home-filters { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 18px; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.social-home-filters button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-width: 44px; min-height: 44px; padding: 8px 14px; border: 1px solid transparent; border-radius: 999px; color: var(--muted); background: transparent; font-size: 15px; }
.social-home-filters button[aria-pressed='true'] { border-color: var(--accent-border); color: var(--accent-text); background: var(--accent-soft); font-weight: 700; }
.social-home-filters button:hover { color: var(--accent-text); background: var(--raised); }
.social-home-filters .icon { width: 24px; height: 24px; flex: 0 0 24px; }
.social-home-filters button:not([aria-pressed='true']) > .icon-filled [fill='#115865'] { fill: #8BB0B7; }
.social-home-filters button:not([aria-pressed='true']) > .icon-filled [fill='#8BB0B7'] { opacity: .55; }
.social-home-filters .social-live-dot { margin-inline-start: 0; flex: 0 0 8px; }
@media (max-width: 959px) {
  .social-home-filters { flex-wrap: nowrap; gap: 4px; }
  .social-home-filters button { flex: 1 1 0; min-width: 44px; padding-inline: 6px; }
  .social-home-filters button[data-home-filter='live'] { flex: 1.4 1 0; white-space: nowrap; }
  .social-home-filter-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
}
.social-stream.recipe-grid.social-home-grid { display: grid; max-width: none; }
.social-home-grid > .social-stream-item { align-self: start; }
.social-home-grid > :is(.social-empty, .social-loading, .social-feed-error) { grid-column: 1 / -1 !important; }
.social-home-grid .social-photo, .social-home-grid .social-native-stage, .social-home-grid .social-native-stage video { max-height: none; }
/* Content determines card height; compact spacing preserves 44px action targets. */
.social-home-grid .social-post-header { padding-bottom: 0; }
.social-home-grid .social-post-body { padding-block: 10px 9px; }
.social-home-grid .social-post-actions { min-height: 44px; padding-block: 0; }
:root[data-theme='light'] .social-home-grid .social-post { padding: 8px 8px 10px; border: 0; border-radius: 24px; }
:root[data-theme='light'] .social-home-grid .social-post-header { padding: 4px 10px 0; }
:root[data-theme='light'] .social-home-grid .social-photo,
:root[data-theme='light'] .social-home-grid .social-album-grid,
:root[data-theme='light'] .social-home-grid .social-native-video,
:root[data-theme='light'] .social-home-grid .social-video-link { border-radius: 16px; overflow: hidden; }
:root[data-theme='light'] .social-home-grid .social-post-body { padding: 10px 10px 9px; }
:root[data-theme='light'] .social-home-grid .social-listing-heading { padding-inline: 10px; }
:root[data-theme='light'] .social-home-grid .social-post-badge { margin: 6px 10px 10px; }
@media (max-width: 600px) {
  :root[data-theme='light'] .social-home-grid .social-post { border-radius: 18px; }
}
.social-post, .social-composer { background: var(--card); border: 1px solid var(--line); border-radius: 8px; min-width: 0; overflow: hidden; }
.social-post-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; padding: 12px 16px 6px; }
.social-author { display: flex; align-items: center; gap: 8px; min-width: 0; }
.social-author-copy { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.social-author-copy strong { font-size: 14px; line-height: 1.3; overflow-wrap: anywhere; }
.social-author-copy .user-name-link { min-height: 24px; }
.social-post-time { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 4px; min-height: 24px; color: var(--muted); font-size: 11px; }
.social-post-time .icon { width: 13px; height: 13px; }
.social-post-tools { display: flex; flex-shrink: 0; align-items: center; }
.social-icon-button, .social-follow-button, .social-reaction { display: inline-flex; justify-content: center; align-items: center; gap: 7px; min-width: 44px; min-height: 44px; padding: 9px; border: 0; border-radius: 6px; background: transparent; color: var(--muted); }
.social-icon-button:hover, .social-follow-button:hover, .social-reaction:hover { color: var(--accent-text); background: var(--raised); }
.social-icon-button.is-active, .social-reaction.is-active { color: var(--accent-text); }
.social-reaction.is-active .icon { fill: var(--accent-soft-strong); }
.social-reaction[data-action="post-like"].is-active { color: var(--red); }
.social-reaction[data-action="post-like"].is-active .icon { fill: currentColor; }
.social-follow-button[aria-pressed='true'] { color: var(--success); }
.social-icon-button:disabled, .social-reaction:disabled { opacity: .5; cursor: default; }
.social-post-body { white-space: pre-wrap; overflow-wrap: anywhere; padding: 10px 18px 16px; font-size: 16px; line-height: 1.55; }
.social-post-body a { color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; }
.social-video-link { display: block; color: var(--text); background: var(--card); border-block: 1px solid var(--line); min-width: 0; }
.social-video-stage { position: relative; width: 100%; aspect-ratio: 16 / 9; min-height: 200px; }
.social-video-thumbnail { position: absolute; inset: 0; display: grid; place-items: center; width: 100%; height: 100%; padding: 0; border: 0; border-radius: 0; background: var(--bg); color: white; cursor: pointer; }
.social-video-thumbnail[hidden] { display: none; }
.social-video-thumbnail img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.social-video-play { position: relative; z-index: 1; display: grid; place-items: center; width: 52px; height: 52px; font-size: 25px; line-height: 1; border-radius: 6px; background: rgba(0,0,0,.82); }
.social-video-stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; min-height: 200px; border: 0; }
.social-video-copy { display: block; padding: 12px 16px; min-width: 0; }
.social-video-copy strong { display: block; font-size: 15px; line-height: 1.4; overflow-wrap: anywhere; color: var(--text); }
.social-video-copy small { display: block; color: var(--muted); margin-top: 5px; overflow-wrap: anywhere; }
.social-video-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; margin-top: 4px; }
.social-video-actions > a { color: var(--accent-text); font-size: 12px; }
.social-video-actions [hidden] { display: none; }
.social-video-thumbnail:focus-visible, .social-video-copy a:focus-visible { outline: 2px solid var(--accent); outline-offset: -3px; }
/* Article previews reserve their image and text space before metadata arrives. */
.social-link-card { display: flex; gap: 14px; padding: 14px 18px; min-width: 0; border-block: 1px solid var(--line); color: var(--text); background: var(--card); text-decoration: none; }
.social-link-card.has-article-preview { display: block; padding: 0; }
.social-link-symbol { display: grid; place-items: center; flex: 0 0 54px; height: 54px; border-radius: 10px; background: var(--bg); color: var(--accent-text); font-size: 24px; }
.social-link-image { position: relative; display: grid; place-items: center; width: 100%; aspect-ratio: 16 / 9; background: var(--bg); color: var(--muted); overflow: hidden; }
.social-link-image > span { font-size: 32px; }
.social-link-image img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.social-link-copy { min-width: 0; }
.has-article-preview .social-link-copy { padding: 12px 16px; }
.social-link-copy small { display: block; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.social-link-copy strong { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; font-size: 15px; line-height: 1.4; }
.has-article-preview .social-link-copy strong { min-height: 2.8em; margin-top: 5px; }
.social-link-copy p { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; overflow-wrap: anywhere; min-height: 4.5em; margin: 6px 0; font-size: 13px; line-height: 1.5; color: var(--muted); }
.social-link-open { display: block; color: var(--accent-text); font-size: 12px; margin-top: 5px; }
.social-link-card:focus-visible { outline: 2px solid var(--accent); outline-offset: -3px; }
.social-composer [data-post-link-preview]:not(:empty) { margin-top: 12px; }
.social-question-label { margin: 10px 18px 0; display: inline-flex; align-items: center; color: var(--accent-text); font-size: 12px; font-weight: 700; }
.social-text-button { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 0; border: 0; background: transparent; color: var(--accent-text); font-size: 13px; }
.social-post > .social-text-button { margin: -14px 18px 2px; }
.social-photo { display: block; width: 100%; padding: 0; border: 0; border-radius: 0; background: var(--raised); aspect-ratio: var(--social-photo-ratio, 4 / 3); overflow: hidden; cursor: zoom-in; }
.social-photo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.social-album-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px; background: var(--bg); }
.social-album-grid .social-photo { position: relative; aspect-ratio: 1; }
.social-album-grid .social-photo img { object-fit: cover; }
.social-album-grid[data-photo-count='3'] .social-photo:last-child { grid-column: 1 / -1; aspect-ratio: 2; }
.social-album-more { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.55); color: white; font-size: 28px; font-weight: 700; }
.social-gallery-stage { display: grid; place-items: center; width: 100%; height: min(68vh, 640px); min-height: 220px; background: var(--raised); }
.social-gallery-stage img { display: block; width: 100%; height: 100%; min-width: 0; object-fit: contain; }
.social-gallery-controls { display: flex; align-items: center; justify-content: center; gap: 20px; min-height: 56px; }
.social-gallery-controls p { min-width: 54px; margin: 0; text-align: center; color: var(--muted); }
.social-native-stage { position: relative; width: 100%; aspect-ratio: var(--native-video-ratio, 16 / 9); max-height: 560px; background: var(--raised); }
.social-native-stage video { display: block; width: 100%; height: 100%; max-height: 560px; object-fit: contain; }
.social-native-cover { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 14px; width: 100%; height: 100%; min-height: 200px; padding: 16px; background: var(--raised); color: var(--text); border: 0; border-radius: 0; }
.social-native-cover .icon { width: 42px; height: 42px; color: var(--accent-text); }
.social-native-cover[hidden], .social-native-controls [hidden] { display: none; }
.social-native-controls { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-inline: 12px; }
.social-native-controls p:empty { display: none; }
.social-native-controls p { margin: 8px 0; color: var(--muted); font-size: 13px; }
.social-post-actions { min-height: 56px; padding: 5px 10px; border-top: 1px solid var(--line); }
.social-post .social-post-actions, .social-post-actions.social-gallery-actions { display: grid; grid-template-columns: repeat(4, minmax(44px, 1fr)) minmax(44px, auto); align-items: center; gap: 4px; }
.social-post-actions > .af-reaction-control > .af-reaction-trigger { grid-column: 1; grid-row: 1; min-width: 44px; padding-inline: 6px; justify-self: center; }
.social-post-actions > [data-action='post-comments'] { position: relative; grid-column: 2; grid-row: 1; justify-self: center; }
.social-post-actions > [data-action='post-comments'] > [data-post-comment-count] { position: absolute; inset-inline-start: 50%; bottom: 0; transform: translateX(-50%); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; line-height: 1; }
.social-post-actions > [data-post-share] { grid-column: 3; grid-row: 1; justify-self: center; }
.social-post-actions > [data-action='post-save'] { grid-column: 4; grid-row: 1; justify-self: center; margin: 0; }
.social-post-actions > .af-reaction-control > .af-reaction-count { grid-column: 5; grid-row: 1; justify-self: end; min-width: 44px; max-width: 100%; margin: 0; padding-inline: 2px; }
.social-post-actions .af-reaction-total { min-width: 0; }
@media (max-width: 360px) {
  .social-post .social-post-actions, .social-post-actions.social-gallery-actions { column-gap: 0; }
}
.social-reaction { font-size: 12px; font-weight: 500; }
.social-composer { margin-bottom: 22px; padding: 16px; }
.social-composer-identity { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-width: 0; margin-bottom: 14px; }
.social-composer-identity small { color: var(--muted); font-size: 11px; overflow-wrap: anywhere; }
.social-composer-identity > select { flex-shrink: 0; max-width: 145px; min-height: 44px; padding: 7px 24px 7px 8px; color: var(--text); background: var(--card); border: 1px solid var(--line); border-radius: 6px; }
.social-composer-top { display: flex; align-items: flex-start; gap: 10px; }
.social-composer-top > textarea { display: block; flex: 1; width: 100%; min-width: 0; min-height: 88px; max-height: 300px; resize: vertical; padding: 8px 4px; border: 0; border-radius: 0; background: transparent; color: var(--text); line-height: 1.65; }
.social-composer-top > textarea::placeholder { color: var(--placeholder); opacity: 1; }
.social-composer-controls { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 8px; border-top: 1px solid var(--line); }
.social-composer-tools { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; }
.social-composer-tools .social-icon-button { border: 1px solid transparent; }
.social-composer-tools .social-icon-button.is-active { border-color: var(--accent-border); background: var(--accent-soft); }
.social-camera-file { display: none; }
.social-link-entry { display: flex; align-items: center; gap: 4px; margin: 10px 0; }
.social-link-entry[hidden] { display: none; }
.social-link-entry input { flex: 1; min-width: 0; width: 100%; min-height: 44px; padding: 8px 10px; border: 1px solid var(--control-border); border-radius: 6px; background: var(--card); color: var(--text); }
.social-camera-panel { margin: 12px 0; padding: 0; min-width: 0; }
.social-camera-panel video { display: block; width: 100%; max-height: 360px; aspect-ratio: 4 / 3; object-fit: contain; background: var(--raised); border-radius: 6px; }
.social-camera-panel p { font-size: 13px; color: var(--muted); margin: 8px 0; }
.social-camera-panel p:empty { display: none; }
.social-camera-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.social-camera-actions .button { min-height: 44px; font-size: 13px; }
.social-camera-modes { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.social-camera-modes .button { min-height: 44px; font-size: 13px; }
.social-camera-modes [aria-pressed='true'] { border-color: var(--accent-text); background: var(--accent-soft); }
.social-camera-panel[data-camera-mode='video'] video { aspect-ratio: 16 / 9; }
.social-camera-panel [hidden] { display: none; }
.social-composer-submit { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; min-width: 0; }
.social-composer-submit > .button { font-size: 13px; min-height: 44px; border-radius: 6px; }
.social-character-count { font-size: 11px; color: var(--muted); margin-inline: 6px; font-variant-numeric: tabular-nums; }
.social-photo-picker { position: relative; cursor: pointer; overflow: hidden; }
.social-photo-picker input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; cursor: pointer; }
.social-composer-tools .social-photo-picker:has(input:focus-visible) { outline: 3px solid var(--accent-text); outline-offset: 2px; }
.social-photo-picker:has(input:disabled) { opacity: .5; cursor: default; }
.social-draft-photo { position: relative; max-width: 100%; margin: 12px 0; background: var(--raised); border-radius: 6px; overflow: hidden; }
.social-draft-photo > img { display: block; max-width: 100%; max-height: 340px; min-height: 100px; margin: auto; object-fit: contain; }
.social-draft-photo .social-icon-button { position: absolute; right: 8px; top: 8px; background: var(--card); color: var(--text); border: 1px solid var(--line); }
.social-draft-photos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-block: 12px; }
.social-draft-photos .social-draft-photo { margin: 0; min-width: 0; }
.social-draft-photos .social-draft-photo > img { width: 100%; height: 140px; min-height: 0; object-fit: cover; }
.social-draft-photo-number { position: absolute; left: 6px; top: 6px; min-width: 24px; padding: 3px 5px; border-radius: 4px; background: var(--card); color: var(--text); font-size: 12px; text-align: center; }
.social-draft-photo-tools { display: flex; justify-content: space-between; gap: 0; background: var(--card); }
.social-draft-photo-tools .social-icon-button { position: static; flex: 1; min-width: 44px; padding: 8px; border: 0; border-radius: 0; }
.social-draft-video { position: relative; margin-block: 12px; min-width: 0; }
.social-draft-video video { display: block; width: 100%; max-height: 320px; background: var(--raised); border-radius: 6px; }
.social-draft-video > span { display: flex; align-items: center; gap: 10px; min-height: 64px; padding: 12px; background: var(--raised); }
.social-draft-video > button { position: absolute; right: 8px; top: 8px; background: var(--card); border: 1px solid var(--line); }
.social-profile-tabs { flex-wrap: wrap; min-width: 0; }
.social-feed-shell.profile-content { width: 100%; max-width: none; margin: 24px 0; }
.profile-content { min-width: 0; margin-top: 24px; }
.profile-collections { min-width: 0; margin-bottom: 28px; }
.profile-collections-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.profile-collections h2, .profile-all-content > h2 { margin: 0 0 14px; font-size: 20px; line-height: 1.4; }
.profile-collections-heading h2 { margin: 0; }
.profile-collections-heading > a { display: inline-flex; align-items: center; gap: 5px; min-height: 44px; color: var(--accent-text); font-size: 13px; }
.profile-collections-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 16px; }
.profile-collections-grid > * { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: var(--card); }
.profile-collections-grid .profile-media-cover { aspect-ratio: 16 / 9; border-radius: 0; }
.profile-collections-grid .profile-media-caption, .profile-collection-copy { padding: 12px 14px; margin: 0; overflow-wrap: anywhere; }
.profile-collection-card { display: block; color: var(--text); text-decoration: none; }
.profile-collection-cover { height: 150px; overflow: hidden; background: var(--raised); }
.profile-collection-cover .recipe-photo { display: block; width: 100%; height: 100%; aspect-ratio: auto; }
.profile-collection-cover .recipe-photo img { width: 100%; height: 100%; object-fit: cover; }
.profile-collection-copy h3 { margin: 0 0 6px; font-size: 16px; line-height: 1.4; }
.profile-collection-copy p, .profile-collections-empty { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.profile-collections-empty { padding: 14px 16px; border: 1px solid var(--line); border-radius: 13px; }
.social-stream.recipe-grid.profile-woven-grid { display: grid; max-width: none; min-width: 0; }
.profile-woven-grid > .profile-woven-item { min-width: 0; align-self: start; }
.profile-woven-grid .social-post { display: flex; flex-direction: column; margin: 0; }
.profile-woven-grid .social-post > .social-post-header { order: 3; padding: 12px 16px; }
.profile-woven-grid .social-post > .social-post-body { order: 2; padding: 13px 16px 4px; font-size: 16px; }
.profile-woven-grid .social-post > .social-text-button { order: 2; margin: 0 16px 4px; }
.profile-woven-grid .social-post > .social-photo,
.profile-woven-grid .social-post > .social-album-grid,
.profile-woven-grid .social-post > .social-native-video,
.profile-woven-grid .social-post > .social-link-preview { order: 1; }
.profile-woven-grid .social-post > .social-post-actions { order: 4; }
.profile-woven-grid .social-native-cover { min-height: 0; }
.profile-woven-grid > .social-empty,
.profile-woven-grid > .social-loading,
.profile-woven-grid > .social-feed-error { grid-column: 1 / -1 !important; grid-row: auto !important; }
@media (max-width: 600px) {
  .profile-collections-heading { align-items: flex-start; }
  .profile-collections h2, .profile-all-content > h2 { font-size: 18px; }
  .profile-collections-heading > a { flex-shrink: 0; font-size: 12px; }
  .profile-collections-grid { grid-template-columns: 1fr; }
}
.profile-media-grid, [data-profile-media-collections] .profile-collections-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.social-stream.profile-media-grid { display: grid; max-width: none; margin: 0; }
.profile-media-item { min-width: 0; }
.profile-media-cover { position: relative; display: block; width: 100%; aspect-ratio: 1; overflow: hidden; border-radius: 6px; background: var(--raised); }
.profile-media-cover > img { display: block; width: 100%; height: 100%; object-fit: cover; }
.profile-media-count { position: absolute; right: 8px; bottom: 8px; display: flex; align-items: center; gap: 5px; padding: 5px 8px; background: var(--card); border-radius: 4px; font-size: 12px; }
.profile-media-count .icon { width: 16px; height: 16px; }
.profile-media-video { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: var(--accent-text); }
.profile-media-video > .icon { width: 36px; height: 36px; }
.profile-media-caption { margin: 8px 0 0; color: var(--muted); overflow-wrap: anywhere; font-size: 13px; line-height: 1.45; }
.profile-media-grid > .social-empty { grid-column: 1 / -1; }
@media (max-width: 600px) {
  .social-draft-photos, .profile-media-grid, [data-profile-media-collections] .profile-collections-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .profile-media-grid { gap: 10px; }
  .social-draft-photos .social-draft-photo > img { height: 120px; }
}
.social-form-status { margin: 4px 0 8px; min-height: 0; font-size: 13px; color: var(--red); overflow-wrap: anywhere; }
.social-form-status:empty { display: none; }
.social-form-status[role='status'] { color: var(--muted); }
.social-auth-note { margin: 12px 0 0; font-size: 13px; color: var(--muted); }
.social-auth-note a { color: var(--accent-text); }
.social-empty { text-align: center; padding: 38px 20px; color: var(--muted); }
.social-empty .icon { width: 30px; height: 30px; margin-bottom: 10px; }
.social-empty p { margin: 0; font-size: 14px; }
.social-loading, .social-feed-error { padding: 18px 8px; color: var(--muted); text-align: center; }
.social-feed-error p { overflow-wrap: anywhere; }
.social-back-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; margin-bottom: 14px; color: var(--accent-text); }
.social-comment-list { margin: 0; padding: 0; list-style: none; }
.social-comment { padding: 8px 0 12px; border-bottom: 0; }
.social-comment-highlight { background: var(--accent-soft); outline: 2px solid var(--accent-border); outline-offset: 3px; }
.social-comment-reply { margin-left: 24px; }
.social-comment-author { display: flex; align-items: center; gap: 7px; min-width: 0; flex-wrap: wrap; }
.social-comment-author > strong { min-width: 0; overflow-wrap: anywhere; font-size: 13px; }
.social-comment-author > time { font-size: 10px; color: var(--muted); margin-inline-start: auto; }
.social-comment-author .user-name-link { min-height: 32px; }
.social-comment-text { margin: 4px 0 0 44px; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; }
.social-reply-reference { margin: 0 0 4px 44px; font-size: 11px; color: var(--muted); overflow-wrap: anywhere; }
.social-comment-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; margin-left: 44px; }
.social-comment-like { display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-height: 44px; min-width: 44px; padding: 4px 6px; border: 0; background: transparent; color: var(--muted); border-radius: 6px; cursor: pointer; }
.social-comment-like .icon { width: 16px; height: 16px; }
.social-comment-like.is-active { color: var(--red); background: var(--accent-soft); }
.social-comment-like.is-active .icon { fill: currentColor; }
.social-comment-like:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.social-comment-like:disabled { opacity: .6; cursor: default; }
.social-comment-form { padding-top: 18px; }
.social-comment-form textarea, [data-form='post-report'] textarea, [data-form='post-report'] select { display: block; width: 100%; min-width: 0; padding: 10px 12px; background: var(--card); color: var(--text); border: 1px solid var(--control-border); border-radius: 6px; }
.social-comment-form textarea { min-height: 92px; resize: vertical; }
.social-comment-submit, .social-comment-replying { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.social-comment-replying { margin: 0 0 10px; font-size: 12px; color: var(--muted); }
[data-form='post-report'] label { display: block; margin: 14px 0 6px; font-size: 13px; }
[data-form='post-report'] .button { margin-top: 16px; }
.social-photo-viewer .social-photo { aspect-ratio: auto; background: transparent; cursor: default; }
.social-photo-viewer .social-photo img { max-height: 75vh; height: auto; object-fit: contain; }
.social-notification { display: flex; align-items: flex-start; gap: 14px; padding: 16px; border-bottom: 1px solid var(--line); }
.social-notification > span { min-width: 0; overflow-wrap: anywhere; font-size: 13px; }
.social-notification small { display: block; color: var(--muted); margin-top: 4px; }
.social-notification.is-unread { background: var(--accent-soft); }
.social-listing-navigation { max-width: 680px; margin: 0 auto 18px; display: flex; flex-direction: column; gap: 8px; }
.social-listing-navigation > div { display: flex; flex-wrap: wrap; gap: 6px; }
.social-listing-navigation a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); }
.social-listing-navigation a[aria-current='page'] { background: var(--accent-soft); color: var(--accent-text); border-color: var(--accent-border); }
.social-listing-fields { display: flex; flex-direction: column; gap: 7px; margin-bottom: 12px; }
.social-listing-fields label { display: flex; flex-direction: column; gap: 7px; color: var(--muted); font-size: 13px; min-width: 0; }
.social-listing-fields input, .social-listing-fields select { width: 100%; min-width: 0; min-height: 44px; padding: 8px 10px; border: 1px solid var(--control-border); border-radius: 6px; background: var(--card); color: var(--text); }
.social-listing-selectors { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.social-listing-heading { padding: 10px 18px 4px; min-width: 0; }
.social-listing-category { color: var(--accent-text); font-size: 12px; }
.social-listing-heading h2 { margin: 7px 0; font-size: 20px; line-height: 1.4; letter-spacing: 0; overflow-wrap: anywhere; }
.social-listing-meta { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px 14px; color: var(--muted); font-size: 13px; }
.social-listing-meta > span { display: inline-flex; align-items: center; gap: 6px; min-width: 0; overflow-wrap: anywhere; }
.social-listing-meta .icon { width: 16px; height: 16px; flex-shrink: 0; }
.social-listing-meta strong { color: var(--text); font-variant-numeric: tabular-nums; }
.social-stream-item { min-width: 0; width: 100%; }
.social-stream .recipe-card { width: 100%; border-radius: 8px; }
.social-stream .recipe-card .photo-link { display: flex; flex-direction: column; overflow: visible; }
.social-stream .recipe-card .card-media { position: relative; }
.social-stream .recipe-card .photo-copy { position: static; padding: 13px 16px 4px; background: transparent; }
.social-stream .recipe-card .card-title { color: var(--text); font-size: 22px; line-height: 1.3; overflow-wrap: anywhere; }
.social-stream .recipe-card .photo-copy p { color: var(--muted); }
.social-stream .recipe-card .recipe-photo { height: auto; aspect-ratio: auto; min-height: 0; }
.social-stream .recipe-card .recipe-photo > img { display: block; width: 100%; height: auto; object-fit: contain; }
.social-stream .recipe-card .card-visibility { top: 12px; right: 12px; bottom: auto; }
@media (max-width: 440px) {
  .social-feed-heading h1 { font-size: 24px; }
  .social-post-header { padding-inline: 10px; }
  .social-post-body { padding-inline: 14px; }
  .social-post-tools { gap: 0; }
  .social-post-tools .social-icon-button, .social-post-tools .social-follow-button { padding-inline: 7px; }
  .social-composer { padding: 12px; }
  .social-composer [data-post-link-preview]:not(:empty) { margin-inline: -12px; }
  .social-composer-identity { gap: 8px; }
  .social-composer-identity > select { max-width: 125px; }
  .social-composer-top { gap: 4px; }
  .social-composer-top > .avatar-button { display: none; }
  .social-composer-controls { gap: 6px; }
  .social-composer-submit { width: 100%; justify-content: flex-end; }
  .social-post-time { font-size: 11px; }
  .social-comment-reply { margin-left: 14px; }
}

/* The approved special purposes use text and fixed contrast in both themes. */
.social-post .social-post-badge { display: inline-flex; align-items: center; max-width: calc(100% - 32px); margin: 14px 16px 0; padding: 5px 11px; border: 1px solid var(--post-label-line); border-radius: 999px; font-size: 12px; line-height: 1.45; font-weight: 700; color: var(--post-label-text); background: var(--post-label-bg); }
.social-post .social-question-label { --post-label-text: #125560; --post-label-bg: #E8F2F4; --post-label-line: #D9E3E6; }
.social-post .social-listing-label { --post-label-text: #80551C; --post-label-bg: #FFF3DF; --post-label-line: #D9E3E6; }
.social-post-purpose { display: flex; flex-wrap: wrap; gap: 8px; margin-block: 12px; }
.social-post-purpose > button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-width: 44px; min-height: 44px; padding: 8px 12px; border: 1px solid transparent; border-radius: 999px; background: transparent; color: var(--muted); cursor: pointer; }
.social-post-purpose > button[aria-pressed="true"] { border-color: var(--accent-border); color: var(--accent-text); background: var(--accent-soft); font-weight: 700; }
.social-post-purpose > button:hover:not(:disabled) { color: var(--accent-text); background: var(--raised); }
.social-post-purpose .icon { width: 24px; height: 24px; flex: 0 0 24px; }
.social-post-purpose .social-live-dot { margin-inline-start: 0; flex: 0 0 8px; }
.social-post-purpose > button:disabled { opacity: .5; cursor: default; }
.social-post-purpose > button:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }
@media (max-width: 560px) {
  .social-post-purpose { flex-wrap: nowrap; gap: 4px; }
  .social-post-purpose > button { min-width: 44px; padding-inline: 6px; }
  .social-post-purpose[role='group'] > button { flex: 1 1 0; }
  .social-post-purpose[role='group'] > button[data-action='live-compose'] { flex: 1.4 1 0; white-space: nowrap; }
  .social-post-purpose-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
}

/* A photo always fits the viewport; only the comments list scrolls. */
#social-dialog[data-purpose='post-gallery'][open] { width: min(1240px, calc(100vw - 32px)); height: calc(100dvh - 32px); max-height: calc(100dvh - 32px); overflow: hidden; display: grid; grid-template-rows: auto minmax(0, 1fr); }
#social-dialog[data-purpose='post-gallery'] > .dialog-header { position: static; padding: 10px 16px; }
#social-dialog[data-purpose='post-gallery'] > .dialog-body { min-height: 0; min-width: 0; overflow: hidden; padding: 0; }
#social-dialog[data-purpose='post-gallery'] .social-gallery { height: 100%; display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 360px); min-height: 0; min-width: 0; }
.social-gallery-media { display: grid; grid-template-rows: minmax(0, 1fr) auto; min-width: 0; min-height: 0; background: var(--raised); }
#social-dialog[data-purpose='post-gallery'] .social-gallery-stage { height: 100%; min-height: 0; min-width: 0; overflow: hidden; padding: 12px; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
#social-dialog[data-purpose='post-gallery'] .social-gallery-stage img { width: 100%; height: 100%; min-height: 0; max-height: 100%; object-fit: contain; }
.social-gallery-details { min-height: 0; min-width: 0; overflow: hidden; display: grid; grid-template-rows: auto auto minmax(0, 1fr); border-left: 1px solid var(--line); }
.social-gallery-author { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 14px 16px; }
.social-gallery-author > div { min-width: 0; overflow-wrap: anywhere; }
.social-gallery-author time { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; }
.social-gallery-actions { padding: 8px 12px; margin: 0; border-block: 1px solid var(--line); }
.social-gallery-details > .social-comment-panel { display: grid; grid-template-rows: minmax(0, 1fr) auto auto; min-height: 0; min-width: 0; overflow: hidden; }
.social-gallery-comments { min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 12px 16px; overflow-wrap: anywhere; }
.social-gallery-comments h3 { font-size: 15px; margin: 0 0 12px; }
.social-gallery-details .social-comment-form { margin: 0; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--card); }
.social-gallery-details .social-comment-form textarea { min-height: 56px; max-height: 96px; resize: none; }
.social-gallery-details .social-comment-submit { gap: 8px; }
.social-gallery-details .social-form-status:empty { display: none; }
.social-gallery-details .social-comment-panel > .note { margin: 0; padding: 0 16px 10px; }
@media (max-width: 700px) {
 #social-dialog[data-purpose='post-gallery'][open] { width: calc(100vw - 12px); max-width: calc(100vw - 12px); height: calc(100dvh - 12px); max-height: calc(100dvh - 12px); border-radius: 12px; }
 #social-dialog[data-purpose='post-gallery'] > .dialog-header { padding: 6px 12px; }
 #social-dialog[data-purpose='post-gallery'] .social-gallery { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) minmax(0, 1.4fr); }
 .social-gallery-details { border-left: 0; border-top: 1px solid var(--line); }
 .social-gallery-author { padding: 6px 12px; }
 .social-gallery-author time { display: none; }
 .social-gallery-details .social-comment-form { padding: 6px 12px; }
 .social-gallery-comments { padding: 8px 12px; }
 .social-gallery-controls { min-height: 44px; }
}

@media (max-width: 700px) {
 .social-gallery-actions { padding: 0 8px; }
 .social-gallery-details .social-comment-form textarea { height: 56px; }
 .social-gallery-details .social-comment-submit { margin-top: 6px; flex-wrap: nowrap; }
 .social-gallery-details .social-comment-submit > .note { font-size: 11px; }
}
@media (max-width: 700px) and (min-width: 560px) and (max-height: 500px) {
 #social-dialog[data-purpose='post-gallery'] .social-gallery { grid-template-columns: minmax(0, 1fr) minmax(260px, 300px); grid-template-rows: minmax(0, 1fr); }
 .social-gallery-details { border-left: 1px solid var(--line); border-top: 0; }
}

/* Comments expand with their draft; no fixed character counter. */
.social-comment-form textarea { max-height: 184px; overflow-y: auto; resize: none; }
.social-comment-submit { justify-content: flex-end; }
.social-gallery-details .social-comment-form textarea { height: 56px; max-height: 112px; }
@media (max-width: 700px) {
 #social-dialog[data-purpose='post-gallery'] .social-gallery[data-comment-expanded='true'] { grid-template-rows: minmax(0, .65fr) minmax(0, 1.6fr); }
}
@media (max-width: 559px) and (max-height: 500px) {
 #social-dialog[data-purpose='post-gallery'] .social-gallery[data-comment-expanded='true'] { grid-template-rows: minmax(0, .35fr) minmax(0, 1.65fr); }
}
@media (max-width: 700px) and (max-height: 500px) {
 .social-gallery[data-comment-expanded='true'] .social-gallery-author { display: none; }
}
@media (max-width: 700px) and (min-width: 560px) and (max-height: 500px) {
 #social-dialog[data-purpose='post-gallery'] .social-gallery[data-comment-expanded='true'] { grid-template-rows: minmax(0, 1fr); }
}

/* Static Live marker; decorative, not an availability or unread indicator. */
.social-live-dot { display: inline-block; width: 8px; height: 8px; margin-inline-start: 6px; border-radius: 50%; background: #A43141; vertical-align: .08em; }
.discussion-closed-badge { display: flex; gap: 6px; align-items: center; width: fit-content; margin: 0 18px 12px; padding: 5px 9px; border: 1px solid var(--line); border-radius: 8px; font-size: 12px; color: var(--muted); background: var(--raised); }
.discussion-closed-badge .icon { width: 15px; height: 15px; }
.discussion-closed-message { margin: 14px 0 0; padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--raised); color: var(--muted); line-height: 1.5; }
.social-comment-actions button[aria-disabled='true'] { opacity: .55; cursor: default; }

/* Compact article previews reuse the feed's validated title and proxy thumbnail. */
.rising-article-preview { display: flex; align-items: flex-start; gap: 8px; min-width: 0; }
.rising-article-copy { flex: 1; min-width: 0; }
.rising-article-copy > strong { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.rising-article-copy > small:empty { display: none; }
.rising-thumb { display: block; flex: 0 0 64px; width: 64px; height: 48px; overflow: hidden; border-radius: 8px; background: var(--raised); }
.rising-thumb[hidden] { display: none; }
.rising-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* Ordinary comments: only the bounded list scrolls, never the header/composer. */
html.social-comments-open, html.social-comments-open body { overflow: hidden; overscroll-behavior: none; }
#social-dialog[data-purpose='post-comments'][open] {
 --post-comments-frame-height: min(760px, calc(var(--post-comments-vh, 100dvh) - 32px));
 position: fixed; inset: auto 0 auto; top: calc(var(--post-comments-top, 0px) + (var(--post-comments-vh, 100dvh) - var(--post-comments-frame-height)) / 2);
 width: min(480px, calc(100vw - 32px)); max-width: none; height: var(--post-comments-frame-height); max-height: var(--post-comments-frame-height);
 margin: 0 auto; padding: 0; overflow: hidden; overscroll-behavior: none; display: grid; grid-template-rows: auto minmax(0, 1fr);
}
#social-dialog[data-purpose='post-comments'] > .dialog-header { position: static; min-width: 0; padding: 10px 16px; border-bottom: 1px solid var(--line); }
#social-dialog[data-purpose='post-comments'] > .dialog-header h2 { min-width: 0; overflow-wrap: anywhere; }
#social-dialog[data-purpose='post-comments'] > .dialog-header > button { flex: 0 0 auto; }
#social-dialog[data-purpose='post-comments'] > .dialog-body { min-height: 0; min-width: 0; padding: 0; overflow: hidden; }
#social-dialog[data-purpose='post-comments'] [data-post-comments-panel] { display: grid; grid-template-rows: minmax(0, 1fr) auto; height: 100%; min-height: 0; min-width: 0; }
#social-dialog[data-purpose='post-comments'] .social-comments-scroll { min-height: 0; min-width: 0; overflow: auto; overscroll-behavior: contain; overflow-anchor: none; padding: 4px 18px 14px; scrollbar-gutter: stable; }
#social-dialog[data-purpose='post-comments'] [data-post-comments-page] { display: grid; justify-items: start; gap: 10px; }
#social-dialog[data-purpose='post-comments'] [data-post-comments-page]:empty, #social-dialog[data-purpose='post-comments'] [data-post-status]:empty { display: none; }
#social-dialog[data-purpose='post-comments'] .social-comments-footer { min-width: 0; padding: 12px 18px max(12px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--card); }
#social-dialog[data-purpose='post-comments'] .social-comment-form { margin: 0; padding: 0; }
#social-dialog[data-purpose='post-comments'] .social-comment-form textarea { height: 92px; min-height: 36px; max-height: 184px; overscroll-behavior: contain; }
#social-dialog[data-purpose='post-comments'] .social-comment-submit { flex-wrap: nowrap; margin-top: 8px; gap: 8px; }
#social-dialog[data-purpose='post-comments'] .social-comment-submit > button { flex: 0 0 auto; }
#social-dialog[data-purpose='post-comments'] .social-comment-replying { flex-wrap: nowrap; gap: 8px; margin: 0 0 6px; }
#social-dialog[data-purpose='post-comments'] .social-comment-replying > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#social-dialog[data-purpose='post-comments'] .social-comment-replying > button { flex: 0 0 auto; }
#social-dialog[data-purpose='post-comments'] .social-comments-footer > .note { margin: 8px 0 0; font-size: 12px; }
#social-dialog[data-purpose='post-comments'] .discussion-closed-message { margin: 0; padding: 10px 12px; }
#social-dialog[data-purpose='post-comments'] .af-reaction-picker { box-sizing: border-box; max-height: calc(var(--post-comments-vh, 100dvh) - 20px); overflow-y: auto; overscroll-behavior: contain; }
#social-dialog[data-purpose='post-comments'][data-comments-compact='true'] > .dialog-header { padding-block: 4px; }
#social-dialog[data-purpose='post-comments'][data-comments-compact='true'] .social-comments-footer { padding-block: 6px; }
#social-dialog[data-purpose='post-comments'][data-comments-compact='true'] .social-comment-submit { margin-top: 4px; }
#social-dialog[data-purpose='post-comments'][data-comments-compact='true'] .social-comment-replying { margin-bottom: 4px; }
@media (max-width: 700px), (max-width: 1000px) and (max-height: 500px) {
 #social-dialog[data-purpose='post-comments'][open] { --post-comments-frame-height: var(--post-comments-vh, 100dvh); top: var(--post-comments-top, 0px); width: 100%; margin: 0; border: 0; border-radius: 0; }
 #social-dialog[data-purpose='post-comments'] > .dialog-header { padding-top: max(6px, env(safe-area-inset-top)); }
 #social-dialog[data-purpose='post-comments'] .social-comments-scroll { padding-inline: 12px; }
 #social-dialog[data-purpose='post-comments'] .social-comments-footer { padding-inline: 12px; }
}
