/* Frameway Community, Discover, Detail & Publication dialogs: Apple neutral + deep teal */
.welcome-screen [hidden], .publication-dialog [hidden] { display: none !important; }

/* Segmented navigation tabs (Desktop in nav + Mobile below nav) */
.welcome-nav-links button, .community-mobile-tabs button {
  min-height: 34px;
  padding: 6px 14px;
  border-radius: 980px;
  color: var(--welcome-muted);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: -0.01em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  white-space: nowrap;
  transition: background var(--welcome-duration) var(--welcome-ease), color var(--welcome-duration) var(--welcome-ease), box-shadow var(--welcome-duration) var(--welcome-ease);
}
.nav-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 980px;
  background: var(--welcome-accent-soft);
  color: var(--welcome-accent);
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.welcome-nav-links button:hover, .community-mobile-tabs button:hover { color: var(--welcome-ink); }
[data-community-tab][aria-pressed="true"] {
  background: var(--welcome-paper);
  color: var(--welcome-ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 0.5px 1px rgba(0, 0, 0, 0.04);
}
.community-mobile-tabs {
  display: none;
  padding: 3px;
  border-radius: 980px;
  background: var(--welcome-surface);
}

/* Status & notices */
.community-message {
  color: var(--welcome-accent);
  font-size: 13.5px;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.community-message:empty { display: none; }
.community-message:not(:empty) {
  margin-bottom: 18px;
  padding: 11px 16px;
  border-radius: 12px;
  background: var(--welcome-accent-soft);
}
.community-message.is-error {
  background: var(--welcome-danger-soft);
  color: var(--welcome-danger);
}

/* Discover feed */
.community-feed-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 8px 0 14px;
}
.community-feed-heading h1 {
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--welcome-ink);
}
.community-section-sub {
  margin-top: 8px;
  font-size: 13.5px;
  color: var(--welcome-muted);
}
.community-channel-scroll {
  margin: 0 0 14px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
}
.community-channels {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: max-content;
  padding: 2px 0;
}
.community-channels button {
  min-height: 40px;
  padding: 8px 16px;
  border-radius: 980px;
  white-space: nowrap;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--welcome-muted);
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease);
}
.community-channels button:hover {
  background: var(--welcome-surface);
  color: var(--welcome-ink);
}
.community-channels button[aria-pressed="true"] {
  background: var(--welcome-accent-soft);
  color: var(--welcome-accent);
  font-weight: 500;
}
.community-filter-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 12px;
  margin-bottom: 18px;
}
/* Both filters use the same trigger, option rows and focus treatment. */
.community-filter { position: relative; width: 176px; max-width: 100%; }
.community-filter-trigger {
  width: 100%; height: 48px; display: flex; align-items: center; gap: 10px;
  padding: 0 16px; border: 1px solid transparent; border-radius: 980px;
  background: var(--welcome-surface); color: var(--welcome-ink);
  font: inherit; font-size: 14px; font-weight: 500; text-align: left;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}
.community-filter-trigger:hover { background: var(--welcome-surface-hover); }
.community-filter-trigger[aria-expanded="true"] { background: var(--welcome-paper); border-color: #c8d5d2; }
.community-filter-trigger.is-active { background: var(--welcome-accent-soft); color: var(--welcome-accent); }
.community-filter-trigger > .fw-icon { width: 18px; height: 18px; flex: 0 0 18px; color: var(--welcome-muted); }
.community-filter-trigger.is-active > .fw-icon { color: var(--welcome-accent); }
.community-filter-value { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.community-filter-trigger .community-filter-chevron { width: 16px; height: 16px; flex-basis: 16px; transition: transform 160ms ease; }
.community-filter-trigger[aria-expanded="true"] .community-filter-chevron { transform: rotate(180deg); }
.welcome-screen .community-filter-trigger:focus-visible { outline: 2px solid var(--welcome-accent); outline-offset: 3px; box-shadow: none; }
.community-filter-popover {
  position: absolute; z-index: 30; top: calc(100% + 8px); left: 0;
  width: 256px; max-width: calc(100vw - 32px); padding: 8px;
  border: 1px solid var(--welcome-line); border-radius: 16px;
  background: var(--welcome-paper); box-shadow: 0 8px 28px rgba(0,0,0,.10);
}
.community-filter-popover.is-above { top: auto; bottom: calc(100% + 8px); }
.community-filter-heading { margin: 0; padding: 8px 12px 10px; font-size: 12px; line-height: 18px; color: var(--welcome-muted); }
.community-filter-options { max-height: 264px; overflow-y: auto; overscroll-behavior: contain; scroll-padding: 4px; }
.community-filter-option {
  width: 100%; min-height: 44px; display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 10px; color: var(--welcome-ink);
  font: inherit; font-size: 14px; line-height: 1.5; font-weight: 400; text-align: left;
  transition: background 120ms ease, color 120ms ease;
}
.community-filter-option:hover, .community-filter-option:focus-visible { background: var(--welcome-surface); }
.welcome-screen .community-filter-option:focus-visible { outline: 2px solid var(--welcome-accent); outline-offset: -2px; }
.community-filter-option[aria-selected="true"] { background: var(--welcome-accent-soft); color: var(--welcome-accent); font-weight: 500; }
.community-filter-option-label { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.community-filter-option-count { flex-shrink: 0; color: var(--welcome-muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.community-filter-option > .fw-icon { width: 16px; height: 16px; flex: 0 0 16px; opacity: 0; }
.community-filter-option[aria-selected="true"] > .fw-icon { opacity: 1; }
.community-filter-reset { min-height: 48px; padding-inline: 12px; color: var(--welcome-accent); }
.community-filter-reset:hover { background: var(--welcome-accent-soft); color: var(--welcome-accent-hover); }
@media (max-width: 600px) {
  .community-filter-bar { gap: 12px; }
  .community-filter { width: calc((100% - 12px) / 2); }
  .community-filter-trigger { padding-inline: 12px; gap: 8px; }
  .community-filter[data-filter="days"] .community-filter-popover,
  .community-filter[data-filter="sort"] .community-filter-popover { left: auto; right: 0; }
}
.community-status {
  color: var(--welcome-muted);
  padding-bottom: 20px;
  font-size: 14px;
}
.community-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}
.community-card {
  position: relative;
  overflow: hidden;
  background: var(--welcome-paper);
  border: 1px solid rgba(0, 0, 0, 0.07);
  border-radius: var(--welcome-radius);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  min-width: 0;
  transition: transform 240ms var(--welcome-ease), box-shadow 240ms var(--welcome-ease), border-color 240ms var(--welcome-ease);
}
.community-card:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 0, 0, 0.12);
  box-shadow: 0 14px 32px -14px rgba(0, 0, 0, 0.12), 0 2px 6px rgba(0, 0, 0, 0.04);
}
.community-card-link { display: block; overflow: hidden; }
.community-card-cover { position: relative; overflow: hidden; background: var(--welcome-surface); }
.community-bookmark-overlay {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  color: var(--welcome-ink);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease), transform 220ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.community-bookmark-overlay:hover { background: #ffffff; color: var(--welcome-accent); }
.community-bookmark-overlay:active { transform: scale(0.92); }
.community-bookmark-overlay[aria-pressed="true"] { color: var(--welcome-accent); }
.community-bookmark-overlay[aria-pressed="true"] .fw-icon { fill: currentColor; }
.community-bookmark-overlay .fw-icon { width: 18px; height: 18px; }
.community-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 2px 20px 6px;
}
.community-card-tags button {
  color: var(--welcome-accent);
  font-size: 12px;
  font-weight: 500;
  padding: 2px 0;
  min-height: 26px;
}
.community-card-tags button:hover { text-decoration: underline; text-underline-offset: 3px; }
.community-card-link img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: var(--welcome-surface);
  transition: transform 420ms var(--welcome-ease);
}
.community-card-certs {
  position: absolute;
  left: 12px;
  bottom: 12px;
  right: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  pointer-events: none;
}
.community-card-certs .fw-v-pill {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.14);
}
.community-card:hover .community-card-link img { transform: scale(1.02); }
.community-card-link h3 {
  padding: 16px 20px 6px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.45;
  color: var(--welcome-ink);
  overflow-wrap: anywhere;
}
.community-card-meta { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.community-card-author {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--welcome-subtle);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.community-card-author .fw-v-mark { width: 14px; height: 14px; vertical-align: 0; }
.community-card-foot {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 2px 14px 12px 20px;
  color: var(--welcome-muted);
  font-size: 13px;
}
.community-metrics, .community-views, .community-like { display: inline-flex; align-items: center; gap: 5px; }
.community-metrics { gap: 6px; }
.community-views .fw-icon, .community-like .fw-icon { width: 16px; height: 16px; }
.community-like {
  min-height: 36px;
  min-width: 36px;
  padding: 6px 10px;
  border-radius: 980px;
  color: var(--welcome-muted);
  font-size: 13px;
  font-weight: 500;
  transition: background var(--welcome-duration) var(--welcome-ease), color var(--welcome-duration) var(--welcome-ease);
}
.community-like:hover { background: var(--welcome-surface); color: var(--welcome-ink); }
.community-like[aria-pressed="true"] { color: var(--welcome-danger); background: var(--welcome-danger-soft); }
.community-like[aria-pressed="true"] .fw-icon { fill: currentColor; }
.community-like:disabled { opacity: 0.55; cursor: wait; }

.community-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  margin-top: 38px;
  font-size: 13px;
  color: var(--welcome-muted);
}
.community-pagination button:disabled { opacity: 0.4; cursor: not-allowed; }

/* Community editorial detail view */
#community-detail { max-width: 880px; margin-inline: auto; }
#community-back { color: var(--welcome-accent); padding-inline: 12px; margin-left: -12px; }
#community-back:hover { background: var(--welcome-accent-soft); color: var(--welcome-accent-hover); }
.community-detail-cover {
  width: 100%;
  height: auto;
  max-height: 500px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 24px;
  background: var(--welcome-surface);
  display: block;
  margin-block: 16px 28px;
  box-shadow: 0 18px 42px -20px rgba(0, 0, 0, 0.16);
}
.community-detail-heading h1 {
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.18;
  color: var(--welcome-ink);
  overflow-wrap: anywhere;
}
.community-detail-heading p { margin-top: 10px; font-size: 15px; color: var(--welcome-muted); display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.community-detail-author { display: inline-flex; align-items: center; gap: 5px; color: var(--welcome-ink); font-weight: 500; }
.community-detail-author .fw-v-mark { width: 16px; height: 16px; vertical-align: 0; }
.community-detail-certs {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  margin-top: 14px;
}
.community-detail-cert-item {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.community-detail-cert-meta {
  font-size: 12.5px;
  color: var(--welcome-muted);
  font-variant-numeric: tabular-nums;
}
.community-detail-certs .fw-v-pill {
  padding: 5px 12px 5px 8px;
  font-size: 12.5px;
}
.community-detail-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-block: 22px 34px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--welcome-line);
}
.community-detail-actions .welcome-button { min-height: 42px; padding-inline: 18px; font-size: 14px; }
.community-detail-actions .community-like { min-height: 42px; padding-inline: 14px; background: var(--welcome-surface); }
.community-detail-actions .community-like[aria-pressed="true"] { background: var(--welcome-danger-soft); }
.community-detail-actions .community-views { padding-inline: 8px; color: var(--welcome-muted); font-size: 13.5px; }

/* Official / Travel Officer Route Certification Callout on Discover Detail */
.community-cert-callout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  margin-bottom: 24px;
  border-radius: 18px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  background: var(--welcome-surface);
}
.community-cert-callout.is-blue {
  background: rgba(0, 113, 227, 0.06);
  border-color: rgba(0, 113, 227, 0.16);
}
.community-cert-callout.is-red {
  background: rgba(215, 0, 21, 0.05);
  border-color: rgba(215, 0, 21, 0.14);
}
.community-cert-callout-copy { min-width: 0; flex: 1; }
.community-cert-callout-title {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 15px;
  font-weight: 600;
  color: var(--welcome-ink);
  letter-spacing: -0.015em;
}
.community-cert-callout-title .fw-v-mark { width: 17px; height: 17px; vertical-align: 0; }
.community-cert-callout-desc {
  margin-top: 4px;
  font-size: 13px;
  color: var(--welcome-muted);
  line-height: 1.55;
}
.community-cert-cta {
  min-height: 42px;
  padding-inline: 18px;
  font-size: 14px;
  color: #ffffff;
  flex-shrink: 0;
}
.community-cert-cta.is-blue { background: #0071e3; }
.community-cert-cta.is-blue:hover { background: #0062c4; }
.community-cert-cta.is-red { background: #d70015; }
.community-cert-cta.is-red:hover { background: #b80012; }
@media (max-width: 640px) {
  .community-cert-callout { flex-direction: column; align-items: stretch; }
  .community-cert-cta { width: 100%; min-height: 44px; }
}

/* Interactive Route Map Schematic on Shared Itinerary Detail */
.community-map-card {
  margin-bottom: 26px;
  border: 1px solid rgba(0, 0, 0, 0.07);
  border-radius: var(--welcome-radius);
  background: var(--welcome-paper);
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}
.community-map-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--welcome-line);
  background: var(--welcome-paper);
}
.community-map-days {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px;
  padding: 3px;
  border-radius: 980px;
  background: var(--welcome-surface);
}
.community-map-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 5px 13px;
  border-radius: 980px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--welcome-muted);
  transition: background var(--welcome-duration) var(--welcome-ease), color var(--welcome-duration) var(--welcome-ease), box-shadow var(--welcome-duration) var(--welcome-ease);
}
.community-map-tab:hover { color: var(--welcome-ink); }
.community-map-tab[aria-pressed="true"] {
  background: var(--welcome-paper);
  color: var(--welcome-ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}
.community-map-tab-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex: 0 0 auto;
}
.community-map-summary {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--welcome-muted);
}
.community-map-viewport {
  position: relative;
  height: 360px;
  overflow: hidden;
  user-select: none;
  touch-action: none;
  cursor: grab;
  background-color: #eef2f6;
  background-image:
    linear-gradient(to right, rgba(29, 29, 31, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(29, 29, 31, 0.04) 1px, transparent 1px);
  background-size: 40px 40px;
}
.community-map-viewport.is-dragging { cursor: grabbing; }
.community-map-tiles,
.community-map-svg,
.community-map-pins {
  position: absolute;
  inset: 0;
}
.community-map-tiles,
.community-map-svg { pointer-events: none; }
.community-map-tile {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  transition: opacity 200ms ease;
  filter: saturate(0.82) contrast(0.97);
}
.community-map-tile.loaded { opacity: 1; }
.community-map-pins { pointer-events: none; }
.community-map-pin {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 4px;
  transition: transform 160ms var(--welcome-ease), opacity 160ms var(--welcome-ease);
}
.community-map-pin:hover,
.community-map-pin.is-selected {
  z-index: 30;
  transform: translate(-50%, -50%) scale(1.1);
}
.community-map-dot {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2.5px solid #ffffff;
  color: #ffffff;
  font-size: 11.5px;
  font-weight: 700;
  display: grid;
  place-items: center;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.22);
}
.community-map-pin.is-selected .community-map-dot {
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.35), 0 4px 12px rgba(0, 0, 0, 0.26);
}
.community-map-label {
  max-width: 132px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 2px 8px;
  border-radius: 980px;
  background: rgba(29, 29, 31, 0.84);
  color: #ffffff;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.35;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.16);
}
.community-map-pin.is-muted { z-index: 4; opacity: 0.55; }
.community-map-pin.is-muted .community-map-dot { width: 12px; height: 12px; border-width: 2px; }

.community-map-controls {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 35;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.community-map-ctrl {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  color: var(--welcome-ink);
  font-size: 15px;
  font-weight: 600;
  display: grid;
  place-items: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: background 160ms var(--welcome-ease);
}
.community-map-ctrl:hover { background: #ffffff; }

.community-map-popover {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 44px 12px 16px;
  border-radius: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  box-shadow: 0 12px 28px -8px rgba(0, 0, 0, 0.18);
}
.community-map-popover-copy { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.community-map-popover-kicker { font-size: 11.5px; font-weight: 600; }
.community-map-popover-copy strong { font-size: 14.5px; font-weight: 600; color: var(--welcome-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.community-map-popover-sub { font-size: 12px; color: var(--welcome-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.community-map-popover-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.community-map-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 980px;
  background: var(--welcome-surface);
  color: var(--welcome-ink);
  font-size: 12.5px;
  font-weight: 500;
  white-space: nowrap;
}
.community-map-action:hover { background: var(--welcome-surface-hover); }
.community-map-action.is-primary { background: var(--welcome-accent); color: #ffffff; }
.community-map-action.is-primary:hover { background: var(--welcome-accent-hover); }
.community-map-dismiss {
  position: absolute;
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--welcome-muted);
}
.community-map-dismiss .fw-icon { width: 14px; height: 14px; }
.community-map-dismiss:hover { background: var(--welcome-surface); color: var(--welcome-ink); }

.community-place-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 6px;
}
.community-place-links .community-text-link { margin-top: 0; }
.community-place.is-highlighted {
  border-radius: 12px;
  background: var(--welcome-accent-soft);
  padding-inline: 12px;
  margin-inline: -12px;
  transition: background 600ms ease;
}

.community-route { display: grid; gap: 22px; }
.community-day {
  background: var(--welcome-paper);
  padding: 28px;
  border: 1px solid rgba(0, 0, 0, 0.07);
  border-radius: var(--welcome-radius);
}
.community-day h2 {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--welcome-ink);
  margin-bottom: 14px;
}
.community-place {
  padding: 20px 0;
  border-top: 1px solid var(--welcome-line);
  overflow-wrap: anywhere;
}
.community-place:last-child { padding-bottom: 0; }
.community-place h3 { font-size: 17px; font-weight: 600; letter-spacing: -0.015em; color: var(--welcome-ink); }
.community-place p { margin-top: 8px; font-size: 14.5px; line-height: 1.65; white-space: pre-wrap; }
.community-place-note { color: var(--welcome-muted); font-size: 13.5px !important; }
.community-text-link {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  margin-top: 6px;
  color: var(--welcome-accent) !important;
  font-size: 13.5px;
  font-weight: 500;
  text-decoration: none !important;
}
.community-text-link:hover { text-decoration: underline !important; text-underline-offset: 4px; }
.community-place-photos { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 14px; }
.community-photo { position: relative; width: min(100%, 340px); align-self: flex-start; border-radius: 14px; overflow: hidden; }
.community-photo img { display: block; width: 100%; height: auto; border-radius: 14px; }
.community-photo svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }

/* Card publish row */
.trip-publish-row { padding: 0 16px 12px; }
.trip-publish-row button {
  min-height: 38px;
  width: 100%;
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--welcome-ink);
  font-size: 13px;
  font-weight: 500;
  background: var(--welcome-surface);
  transition: background var(--welcome-duration) var(--welcome-ease), color var(--welcome-duration) var(--welcome-ease);
}
.trip-publish-row button:hover { background: var(--welcome-surface-hover); color: var(--welcome-accent); }

/* Publication & Report dialogs (inheriting .account-dialog Apple shell) */
.publication-dialog { width: min(680px, calc(100vw - 32px)); }
.publication-dialog select,
#community-report-dialog select,
#community-report-dialog textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  margin-top: 6px;
  padding: 11px 14px;
  border: 1px solid var(--acc-border, #d2d2d7);
  border-radius: 12px;
  background: #ffffff;
  color: var(--acc-ink, #1d1d1f);
  font: inherit;
  font-size: 16px;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}
.publication-dialog select:focus,
#community-report-dialog select:focus,
#community-report-dialog textarea:focus {
  border-color: var(--acc-accent, #0f766e);
  box-shadow: 0 0 0 4px var(--acc-accent-ring, rgba(15, 118, 110, 0.22));
  outline: none;
}
.publish-file-label input[type="file"] {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--acc-surface, #f5f5f7);
  font-size: 13px;
  color: var(--acc-muted, #6e6e73);
}
.publish-fields { display: grid; grid-template-columns: 2fr 1fr; gap: 14px; }
.publish-cover { display: grid; grid-template-columns: 168px 1fr; gap: 18px; margin-bottom: 18px; align-items: start; }
.publish-cover img { width: 168px; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 14px; background: var(--acc-surface, #f5f5f7); }
.publish-cover img[hidden] + div { grid-column: 1 / -1; }
.publish-options {
  display: grid;
  gap: 2px;
  margin-bottom: 14px;
  padding: 6px 14px;
  border-radius: 14px;
  background: var(--acc-surface, #f5f5f7);
}
.publication-dialog .publish-options label,
.publication-dialog .publish-place,
.publication-dialog .publish-confirm {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-height: 42px;
  margin: 0;
  padding: 9px 0;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--acc-ink, #1d1d1f);
}
.publication-dialog input[type="checkbox"] {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--acc-accent, #0f766e);
}
.publish-spots {
  border: 1px solid var(--acc-hairline, rgba(0, 0, 0, 0.08));
  border-radius: 14px;
  padding: 4px 14px;
  margin-bottom: 14px;
}
.publish-place + .publish-place { border-top: 1px solid var(--acc-hairline, rgba(0, 0, 0, 0.08)); }
.publish-place > span { min-width: 0; }
.publish-place strong, .publish-place > span > span { display: block; overflow-wrap: anywhere; white-space: pre-wrap; }
.publish-place strong { font-weight: 600; font-size: 13.5px; }
.publish-place > span > span { margin-top: 3px; font-size: 12.5px; color: var(--acc-muted, #6e6e73); }
.publish-private-note { color: var(--acc-danger, #d70015) !important; }
.publish-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.publish-actions button { flex: 1; min-width: 130px; margin: 0; }

/* Shareable Poster Preview Dialog */
.poster-dialog { width: min(560px, calc(100vw - 24px)); }
.poster-private-options { margin-bottom: 12px; }
.poster-private-options .account-note { margin-bottom: 8px; }
.poster-private-options .publish-options { margin-bottom: 0; }
.poster-preview-stage {
  max-height: min(58vh, 520px);
  overflow-y: auto;
  padding: 12px;
  border-radius: 16px;
  background: var(--welcome-surface);
  border: 1px solid rgba(0, 0, 0, 0.06);
  text-align: center;
}
.poster-preview-stage img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
  box-shadow: 0 12px 32px -12px rgba(0, 0, 0, 0.16);
}
.poster-actions { margin-top: 14px; }
.poster-actions button { margin-top: 0; }

@media (max-width: 850px) {
  .community-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
  .community-mobile-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2px; margin: 0 0 20px; }
  .community-mobile-tabs button { min-height: 40px; padding: 6px 8px; font-size: 13px; }
}

/* Stage 1 Detail Tags, Copy Metric, Bottom Dock, Comments & Publish Theme Picker */
#community-detail { padding-bottom: 96px; }
.community-detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 12px;
}
.community-detail-tags button {
  min-height: 36px;
  padding: 4px 0;
  color: var(--welcome-accent);
  font-size: 13.5px;
  font-weight: 500;
}
.community-detail-tags button:hover { text-decoration: underline; text-underline-offset: 3px; }
.community-detail-copy-meta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: var(--welcome-muted);
}
.community-detail-copy-meta .fw-icon { width: 15px; height: 15px; }

.community-detail-dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 35;
  border-top: 1px solid var(--welcome-line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  padding: 12px 24px max(12px, env(safe-area-inset-bottom));
}
.community-dock-inner {
  max-width: 880px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.community-dock-social {
  display: flex;
  align-items: center;
  gap: 10px;
}
.community-dock-action {
  min-height: 44px;
  padding: 6px 12px;
  border-radius: 980px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--welcome-muted);
  font-size: 13px;
  font-weight: 500;
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease);
}
.community-dock-action:hover { background: var(--welcome-surface); color: var(--welcome-ink); }
.community-dock-action[aria-pressed="true"] { color: var(--welcome-accent); background: var(--welcome-accent-soft); }
.community-dock-action.is-like[aria-pressed="true"] { color: var(--welcome-danger); background: var(--welcome-danger-soft); }
.community-dock-action[aria-pressed="true"] .fw-icon { fill: currentColor; }
.community-dock-action .fw-icon { width: 18px; height: 18px; }
.community-dock-right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.community-dock-hint {
  font-size: 12.5px;
  color: var(--welcome-muted);
  white-space: nowrap;
}

/* Route Comments (路线交流) */
.community-comments {
  margin-top: 42px;
  padding-top: 30px;
  border-top: 1px solid var(--welcome-line);
}
.community-comments-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.community-comments-head h2 {
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--welcome-ink);
}
.community-comments-head > span { font-size: 12.5px; color: var(--welcome-muted); }
.community-guest-composer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px;
  border-radius: 20px;
  background: var(--welcome-surface);
  margin-bottom: 12px;
}
.community-guest-composer p { font-size: 13.5px; color: var(--welcome-muted); }
.community-comment-composer {
  padding: 20px;
  border-radius: 20px;
  background: var(--welcome-surface);
  margin-bottom: 12px;
  transition: box-shadow 160ms var(--welcome-ease);
}
.community-comment-composer:focus-within {
  box-shadow: 0 0 0 2px var(--welcome-accent-ring);
}
.community-composer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.community-composer-top label { font-size: 14px; font-weight: 500; color: var(--welcome-ink); }
.community-composer-top small { font-size: 12px; color: var(--welcome-muted); font-variant-numeric: tabular-nums; }
.community-comment-types {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}
.community-comment-types button {
  min-height: 36px;
  padding: 6px 13px;
  border-radius: 980px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--welcome-muted);
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease), box-shadow 160ms var(--welcome-ease);
}
.community-comment-types button:hover { color: var(--welcome-ink); }
.community-comment-types button[aria-pressed="true"] {
  background: #ffffff;
  color: var(--welcome-accent);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}
.community-comment-composer textarea {
  display: block;
  width: 100%;
  min-height: 88px;
  max-height: 220px;
  resize: vertical;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--welcome-ink);
  font-size: 15px;
  line-height: 1.7;
}
.community-comment-composer textarea::placeholder { color: var(--welcome-subtle); }
.community-composer-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 12px;
}
.community-composer-foot > span { font-size: 12px; color: var(--welcome-muted); }
.community-comment-error { margin-top: 8px; font-size: 12.5px; color: var(--welcome-danger); }
.community-comment-error:empty { display: none; }
.community-comments-empty { padding: 28px 0; text-align: center; font-size: 13.5px; color: var(--welcome-muted); }
.community-comment-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 20px 0;
  border-bottom: 1px solid var(--welcome-line);
}
.community-comment-row:last-child { border-bottom: 0; }
.community-comment-avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--welcome-surface);
  color: var(--welcome-accent);
  font-size: 13px;
  font-weight: 600;
}
.community-comment-main { min-width: 0; flex: 1; }
.community-comment-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.community-comment-author {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--welcome-ink);
}
.community-comment-author .fw-v-mark { width: 15px; height: 15px; vertical-align: 0; }
.community-comment-type {
  font-size: 11px;
  font-weight: 500;
  color: var(--welcome-accent);
  background: var(--welcome-accent-soft);
  padding: 2px 8px;
  border-radius: 980px;
}
.community-comment-body {
  margin-top: 7px;
  font-size: 14px;
  line-height: 1.75;
  color: var(--welcome-ink);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.community-comment-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--welcome-muted);
}
.community-comment-meta button {
  min-height: 32px;
  padding: 4px 8px;
  border-radius: 980px;
  font-size: 12px;
  color: var(--welcome-muted);
}
.community-comment-meta button:hover { color: var(--welcome-accent); background: var(--welcome-surface); }
.community-comment-meta button.is-danger:hover { color: var(--welcome-danger); background: var(--welcome-danger-soft); }

/* Publish dialog theme picker */
.publish-tags-section { margin: 14px 0 12px; }
.publish-tags-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 500;
  color: var(--acc-ink, #1d1d1f);
  margin-bottom: 10px;
}
.publish-tags-head small { font-size: 12px; color: var(--acc-muted, #6e6e73); font-weight: 400; font-variant-numeric: tabular-nums; }
.publish-tag-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.publish-tag-picker button {
  min-height: 38px;
  padding: 6px 14px;
  border: 1px solid var(--acc-border, #d2d2d7);
  border-radius: 980px;
  background: #ffffff;
  color: var(--acc-muted, #6e6e73);
  font-size: 12.5px;
  font-weight: 500;
  transition: background 150ms ease, border-color 150ms ease, color 150ms ease;
}
.publish-tag-picker button:hover { background: #f5f5f7; color: #1d1d1f; }
.publish-tag-picker button[aria-pressed="true"] {
  background: rgba(15, 118, 110, 0.08);
  border-color: #0f766e;
  color: #0f766e;
}
.publish-tag-hint {
  margin-top: 8px;
  font-size: 12px;
  color: var(--acc-muted, #6e6e73);
}

@media (max-width: 650px) {
  .community-dock-hint { display: none; }
  .community-dock-action { padding: 6px 8px; font-size: 12px; }
  .community-guest-composer { flex-direction: column; align-items: flex-start; }
  .community-comment-composer textarea { font-size: 16px; }
}
@media (max-width: 600px) {
  .community-mobile-tabs button { min-height: 44px; font-size: 14px; }
  .community-grid { grid-template-columns: 1fr; gap: 18px; }
  .community-feed-heading { flex-direction: column; align-items: stretch; gap: 14px; }
  .community-feed-heading .library-search { width: 100%; }
  .community-like { min-height: 44px; min-width: 44px; }
  .community-detail-cover { border-radius: 18px; }
  .community-detail-actions { gap: 8px; }
  .community-detail-actions .welcome-button { font-size: 13.5px; padding-inline: 14px; min-height: 44px; }
  .community-map-viewport { height: 280px; }
  .community-map-tab { min-height: 38px; padding-inline: 11px; }
  .community-map-ctrl { width: 40px; height: 40px; }
  .community-map-popover { flex-direction: column; align-items: stretch; padding: 12px 38px 12px 14px; }
  .community-map-dismiss { top: 10px; transform: none; }
  .community-map-popover-actions { width: 100%; }
  .community-map-action { flex: 1; min-height: 38px; }
  .community-day { padding: 20px; }
  .trip-publish-row button { min-height: 44px; }
  .publish-fields { grid-template-columns: 1fr; gap: 0; }
  .publish-cover { grid-template-columns: 1fr; }
  .publish-cover img { width: min(100%, 240px); }
}
@media (prefers-reduced-motion: reduce) {
  .community-card:hover, .community-card:hover .community-card-link img { transform: none; }
}

/* ==================== Stage 2: Follow Scope, Creator Bar & Profile (/u/<username>) ==================== */
.community-feed-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.community-feed-scope {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border-radius: 980px;
  background: var(--welcome-surface);
}
.community-feed-scope button {
  min-height: 34px;
  padding: 6px 16px;
  border-radius: 980px;
  font-size: 13px;
  font-weight: 500;
  color: var(--welcome-muted);
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease), box-shadow 160ms var(--welcome-ease);
}
.community-feed-scope button:hover { color: var(--welcome-ink); }
.community-feed-scope button[aria-selected="true"] {
  background: var(--welcome-paper);
  color: var(--welcome-ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.community-following-creators-wrap {
  margin: 0 0 18px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
}
.community-following-creators {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: max-content;
  padding: 2px 0;
}
.community-creator-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 5px 14px 5px 6px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 980px;
  background: var(--welcome-paper);
  color: var(--welcome-ink);
  font-size: 13px;
  font-weight: 500;
  transition: background 160ms var(--welcome-ease), border-color 160ms var(--welcome-ease);
}
.community-creator-chip:hover {
  background: var(--welcome-surface);
  border-color: rgba(0, 0, 0, 0.14);
}
.community-creator-chip-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--welcome-accent-soft);
  color: var(--welcome-accent);
  font-size: 12px;
  font-weight: 600;
}
.community-creator-chip .fw-v-mark { width: 14px; height: 14px; vertical-align: 0; }

a.community-card-author:hover,
a.community-comment-author:hover {
  color: var(--welcome-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Detail creator bar with follow button */
.community-detail-creator {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  padding: 14px 18px;
  border-radius: 18px;
  background: var(--welcome-surface);
}
.community-detail-creator-link {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}
.community-detail-creator-avatar {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--welcome-paper);
  color: var(--welcome-accent);
  font-size: 16px;
  font-weight: 600;
  border: 1px solid rgba(0, 0, 0, 0.06);
}
.community-detail-creator-copy { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.community-detail-creator-name {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--welcome-ink);
}
.community-detail-creator-link:hover .community-detail-creator-name { color: var(--welcome-accent); }
.community-detail-creator-bio {
  font-size: 12.5px;
  color: var(--welcome-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.community-follow-btn {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0 18px;
  border-radius: 980px;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid transparent;
  background: var(--welcome-accent);
  color: #ffffff;
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease), border-color 160ms var(--welcome-ease);
}
.community-follow-btn:hover { background: var(--welcome-accent-hover); }
.community-follow-btn[aria-pressed="true"] {
  background: var(--welcome-paper);
  color: var(--welcome-ink);
  border-color: var(--welcome-line-strong);
}
.community-follow-btn[aria-pressed="true"]:hover {
  background: var(--welcome-surface-hover);
}

/* Creator Profile View (/u/<username>) */
#community-profile { max-width: 1120px; margin: 0 auto; }
#community-profile-back { margin-bottom: 18px; }
.community-profile-hero {
  background: var(--welcome-surface);
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: 26px;
  padding: 32px 36px;
  margin-bottom: 28px;
}
.community-profile-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.community-profile-identity {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  min-width: 0;
  flex: 1;
}
.community-profile-avatar {
  width: 68px;
  height: 68px;
  flex: 0 0 68px;
  border-radius: 22px;
  display: grid;
  place-items: center;
  background: var(--welcome-paper);
  color: var(--welcome-accent);
  font-size: 26px;
  font-weight: 600;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}
.community-profile-info { min-width: 0; flex: 1; }
.community-profile-name-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.community-profile-name-row h1 {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--welcome-ink);
  line-height: 1.2;
}
.community-profile-bio {
  margin-top: 8px;
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--welcome-muted);
  max-width: 640px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.community-profile-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.community-profile-bio-editor {
  margin-top: 16px;
  padding: 16px;
  border-radius: 16px;
  background: var(--welcome-paper);
  border: 1px solid var(--welcome-line-strong);
  max-width: 640px;
}
.community-profile-bio-editor textarea {
  display: block;
  width: 100%;
  min-height: 72px;
  border: 0;
  outline: 0;
  resize: vertical;
  background: transparent;
  font: inherit;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--welcome-ink);
}
.community-profile-bio-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--welcome-line);
}
.community-profile-bio-foot small {
  font-size: 12px;
  color: var(--welcome-muted);
  font-variant-numeric: tabular-nums;
}
.community-profile-bio-btns { display: flex; align-items: center; gap: 8px; }

.community-profile-stats {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px 32px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--welcome-line);
}
.community-profile-stat {
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.community-profile-stat strong {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  color: var(--welcome-ink);
}
.community-profile-stat span {
  font-size: 13px;
  color: var(--welcome-muted);
}

.community-profile-tabs-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.community-profile-tabs {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border-radius: 980px;
  background: var(--welcome-surface);
}
.community-profile-tabs button {
  min-height: 38px;
  padding: 6px 18px;
  border-radius: 980px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--welcome-muted);
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease), box-shadow 160ms var(--welcome-ease);
}
.community-profile-tabs button:hover { color: var(--welcome-ink); }
.community-profile-tabs button[aria-selected="true"] {
  background: var(--welcome-paper);
  color: var(--welcome-ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.community-cert-footprint-note {
  margin: 0 20px 10px;
  padding: 8px 12px;
  border-radius: 12px;
  background: var(--welcome-surface);
  font-size: 12px;
  color: var(--welcome-muted);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

@media (max-width: 600px) {
  .community-profile-hero { padding: 22px 18px; border-radius: 22px; }
  .community-profile-avatar { width: 54px; height: 54px; flex-basis: 54px; border-radius: 16px; font-size: 22px; }
  .community-profile-actions { width: 100%; }
  .community-profile-actions .community-follow-btn,
  .community-profile-actions .welcome-button { flex: 1; min-height: 44px; justify-content: center; }
  .community-detail-creator { padding: 12px 14px; }
  .community-follow-btn { min-height: 42px; padding: 0 16px; }
  .community-profile-bio-editor textarea { font-size: 16px; }
}

/* ==================== Avatars, Handles, Follow List Dialog & In-App Notifications ==================== */
.community-card-avatar,
.community-creator-chip-avatar,
.community-detail-creator-avatar,
.community-profile-avatar,
.community-comment-avatar,
.follow-list-avatar,
.notif-avatar {
  overflow: hidden;
}
.community-card-avatar img,
.community-creator-chip-avatar img,
.community-detail-creator-avatar img,
.community-profile-avatar img,
.community-comment-avatar img,
.follow-list-avatar img,
.notif-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.community-card-avatar {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  background: var(--welcome-accent-soft);
  color: var(--welcome-accent);
  font-size: 10px;
  font-weight: 600;
}
.community-profile-handle {
  margin-top: 4px;
  font-size: 13px;
  color: var(--welcome-subtle);
}
.community-profile-stat.is-clickable {
  padding: 6px 10px;
  margin: -6px -10px;
  border-radius: 12px;
  cursor: pointer;
  transition: background 160ms var(--welcome-ease), color 160ms var(--welcome-ease);
}
.community-profile-stat.is-clickable:hover {
  background: rgba(0, 0, 0, 0.045);
}
.community-profile-stat.is-clickable:hover strong,
.community-profile-stat.is-clickable:hover span {
  color: var(--welcome-accent);
}
.community-profile-bio-editor input[type="text"] {
  display: block;
  width: 100%;
  min-height: 40px;
  margin-bottom: 10px;
  padding: 6px 0 10px;
  border: 0;
  border-bottom: 1px solid var(--welcome-line);
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--welcome-ink);
}

/* Topbar notification bell button */
.community-notif-btn {
  position: relative;
  min-width: 36px;
  padding: 0 10px !important;
}
.community-notif-btn .fw-icon { width: 17px; height: 17px; }
.community-notif-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  font-size: 10px;
  background: var(--welcome-danger);
  color: #ffffff;
}

/* Follow List & Notifications Dialogs */
.follow-list-dialog,
.notifications-dialog {
  width: min(560px, calc(100vw - 24px));
}
.follow-list-tabs,
.notif-filter-tabs {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border-radius: 980px;
  background: var(--acc-surface, #f5f5f7);
}
.follow-list-tabs { margin-bottom: 14px; }
.follow-list-tabs button,
.notif-filter-tabs button {
  min-height: 34px;
  padding: 5px 16px;
  border-radius: 980px;
  font-size: 13px;
  font-weight: 500;
  color: var(--acc-muted, #6e6e73);
  transition: background 160ms ease, color 160ms ease, box-shadow 160ms ease;
}
.follow-list-tabs button:hover,
.notif-filter-tabs button:hover { color: var(--acc-ink, #1d1d1f); }
.follow-list-tabs button[aria-selected="true"],
.notif-filter-tabs button[aria-selected="true"] {
  background: #ffffff;
  color: var(--acc-ink, #1d1d1f);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}
.follow-list-status {
  padding-bottom: 10px !important;
  font-size: 13px !important;
}
.follow-list-items,
.notifications-list {
  max-height: min(54vh, 440px);
  overflow-y: auto;
  overscroll-behavior: contain;
  border-top: 1px solid var(--acc-hairline, rgba(0, 0, 0, 0.08));
}
.follow-list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 4px;
  border-bottom: 1px solid var(--acc-hairline, rgba(0, 0, 0, 0.08));
}
.follow-list-row:last-child { border-bottom: 0; }
.follow-list-user {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
  text-decoration: none;
  color: inherit;
}
.follow-list-avatar {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--acc-surface, #f5f5f7);
  color: var(--acc-accent, #0f766e);
  font-size: 15px;
  font-weight: 600;
}
.follow-list-copy { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.follow-list-name {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  font-size: 14px;
  font-weight: 600;
  color: var(--acc-ink, #1d1d1f);
}
.follow-list-user:hover .follow-list-name { color: var(--acc-accent, #0f766e); }
.follow-list-name .fw-v-mark { width: 14px; height: 14px; vertical-align: 0; }
.follow-list-handle {
  font-size: 12px;
  font-weight: 400;
  color: var(--acc-subtle, #86868b);
}
.follow-list-bio {
  font-size: 12.5px;
  color: var(--acc-muted, #6e6e73);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.follow-list-pagination {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--acc-hairline, rgba(0, 0, 0, 0.08));
}

.notifications-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 12px;
}
.notifications-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.notif-row {
  width: 100%;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 10px;
  border-bottom: 1px solid var(--acc-hairline, rgba(0, 0, 0, 0.08));
  border-radius: 12px;
  text-align: left;
  background: transparent;
  transition: background 150ms ease;
}
.notif-row:hover { background: var(--acc-surface, #f5f5f7); }
.notif-row.is-unread { background: rgba(15, 118, 110, 0.045); }
.notif-row.is-unread:hover { background: rgba(15, 118, 110, 0.085); }
.notif-avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--acc-surface, #f5f5f7);
  color: var(--acc-accent, #0f766e);
  font-size: 14px;
  font-weight: 600;
}
.notif-main { min-width: 0; flex: 1; }
.notif-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.notif-actor {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--acc-ink, #1d1d1f);
}
.notif-actor .fw-v-mark { width: 14px; height: 14px; vertical-align: 0; }
.notif-time {
  font-size: 11.5px;
  color: var(--acc-subtle, #86868b);
  white-space: nowrap;
}
.notif-summary {
  margin-top: 3px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--acc-ink, #1d1d1f);
}
.notif-excerpt {
  margin-top: 4px;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--acc-muted, #6e6e73);
  overflow-wrap: anywhere;
}
.notif-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  margin-top: 6px;
  border-radius: 50%;
  background: var(--acc-accent, #0f766e);
}
@media (max-width: 600px) {
  .community-notif-btn { min-width: 44px; min-height: 44px; }
  .community-profile-stat.is-clickable { min-height: 44px; align-items: center; }
}
