/* ==========================================================================
   Avezz Profile Page (1:1 UI/profile.html two-column layout)
   ========================================================================== */

.prof-page {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
  min-height: calc(100dvh - var(--nav-h, 108px));
}

/* Left Sticky Sidebar */
.prof-sidebar {
  padding: 28px 26px 40px;
  border-right: 1px solid var(--border);
  position: sticky;
  top: var(--nav-h, 108px);
  align-self: start;
  max-height: calc(100dvh - var(--nav-h, 108px));
  overflow-y: auto;
  scrollbar-width: none;
}

.prof-sidebar::-webkit-scrollbar { display: none; }

.prof-head {
  display: block;
  margin-bottom: 12px;
}

.prof-head-info {
  min-width: 0;
}

.prof-avatar-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  overflow: hidden;
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
  box-shadow: var(--shadow-sm);
  margin-bottom: 18px;
  display: grid;
  place-items: center;
}

.prof-avatar-wrap img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
}

.prof-avatar-fallback {
  font-size: 54px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.02em;
  z-index: 1;
}

.prof-name-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}

.prof-identity {
  min-width: 0;
  flex: 1 1 auto;
}

.prof-name {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--text);
  margin: 0;
  word-break: break-word;
}

.prof-handle {
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.prof-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.prof-primary-btn {
  height: 32px;
  padding: 0 11px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  background: var(--pill-active-bg, #1c1f24);
  color: var(--pill-active-text, #ffffff);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  transition: opacity 0.15s ease, background 0.15s ease;
}

.prof-primary-btn:hover { opacity: 0.9; }

.prof-primary-btn.is-following {
  background: var(--surface-alt);
  color: var(--text);
  border: 1px solid var(--border-strong);
}

.prof-icon-btn {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s ease, color 0.15s ease;
}

.prof-icon-btn:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.prof-icon-btn--danger:hover {
  color: var(--danger, #ef4444);
  border-color: color-mix(in srgb, var(--danger, #ef4444) 35%, var(--border));
}

.prof-quick-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 6px;
  margin-bottom: 16px;
}

.prof-quick-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 30px;
  padding: 0 8px;
  border-radius: 8px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 11.5px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.prof-quick-pill:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.prof-bio {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0 0 10px;
  word-break: break-word;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.prof-meta-summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
}

.prof-conn-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  min-width: 0;
}

.prof-mid-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  text-align: center;
  min-width: 0;
}

.prof-coins-val {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  text-decoration: none;
}

a.prof-coins-val:hover {
  color: var(--accent);
}

.prof-rating-col {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
  background: none;
  border: 0;
  padding: 0 2px;
  border-radius: 8px;
  cursor: pointer;
  text-align: right;
  flex-shrink: 0;
  transition: background 0.15s ease;
}

.prof-rating-col:hover {
  background: var(--surface-alt);
}

.prof-rating-col:hover .prof-meta-label {
  color: var(--text);
}

.prof-meta-label {
  background: none;
  border: 0;
  padding: 0;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: color 0.15s ease;
}

.prof-meta-label:hover {
  color: var(--text);
}

.prof-rating-inline {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 26px;
}

.prof-rating-inline .star-rating {
  font-size: 14px;
}

.prof-tags-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
}

.prof-tag-link {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.1;
  cursor: pointer;
  transition: transform 0.12s ease, opacity 0.15s ease, box-shadow 0.15s ease;
}

.prof-tag-link:hover {
  transform: translateY(-1px);
  opacity: 0.92;
}

.prof-tag--blue    { background: var(--tag-blue-bg, rgba(37, 99, 235, 0.12));    color: var(--tag-blue-txt, #1d4ed8);    border-color: var(--tag-blue-bd, rgba(37, 99, 235, 0.25)); }
.prof-tag--emerald { background: var(--tag-emerald-bg, rgba(16, 185, 129, 0.12)); color: var(--tag-emerald-txt, #047857); border-color: var(--tag-emerald-bd, rgba(16, 185, 129, 0.25)); }
.prof-tag--orange  { background: var(--tag-orange-bg, rgba(249, 115, 22, 0.12));  color: var(--tag-orange-txt, #c2410c);  border-color: var(--tag-orange-bd, rgba(249, 115, 22, 0.25)); }
.prof-tag--purple  { background: var(--tag-purple-bg, rgba(139, 92, 246, 0.12));  color: var(--tag-purple-txt, #6d28d9);  border-color: var(--tag-purple-bd, rgba(139, 92, 246, 0.25)); }
.prof-tag--rose    { background: var(--tag-rose-bg, rgba(244, 63, 94, 0.12));     color: var(--tag-rose-txt, #be123c);    border-color: var(--tag-rose-bd, rgba(244, 63, 94, 0.25)); }

.prof-tag-link.is-active {
  color: var(--pill-active-text, #ffffff);
  background: var(--pill-active-bg, #1c1f24);
  border-color: var(--pill-active-bg, #1c1f24);
}

/* People-card style overlapping round connections stack */
.prof-conn-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0 2px;
}

.prof-conn-stack {
  display: flex;
  align-items: center;
}

.prof-conn-av {
  position: relative;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid var(--surface);
  background: var(--surface-alt);
  color: var(--text-muted);
  font-size: 9.5px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-left: -9px;
  text-decoration: none;
  flex-shrink: 0;
  transition: transform 0.15s ease, z-index 0.15s ease;
}

.prof-conn-av:first-child { margin-left: 0; }
.prof-conn-av:hover { transform: translateY(-2px); z-index: 3; }

.prof-conn-av img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
}

.prof-conn-av span { z-index: 1; }

.prof-conn-more {
  min-width: 26px;
  height: 26px;
  padding: 0 6px;
  border-radius: 999px;
  border: 2px solid var(--surface);
  background: var(--pill-active-bg, #1c1f24);
  color: var(--pill-active-text, #ffffff);
  font-size: 9.5px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: -9px;
  flex-shrink: 0;
}

.prof-conn-label {
  background: none;
  border: 0;
  padding: 4px 8px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.prof-conn-label:hover {
  background: var(--surface-alt);
  color: var(--text);
}

/* Right Main Column */
.prof-main {
  padding: 28px 36px 64px;
  min-width: 0;
}

.prof-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.prof-section-title {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0;
}

.prof-select-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.prof-pill-select {
  appearance: none;
  height: 30px;
  padding: 0 28px 0 13px;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  outline: none;
}

.prof-pill-select:hover {
  background: var(--surface-hover);
  border-color: var(--border-strong);
}

.prof-select-wrap .icon {
  position: absolute;
  right: 9px;
  pointer-events: none;
  color: var(--text-muted);
}

/* Badges Showcase (above Featured) */
.prof-badges-showcase {
  margin-bottom: 30px;
}

.prof-section-count {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-muted);
  margin-left: 4px;
}

.prof-section-link {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  transition: background 0.15s ease, color 0.15s ease;
}

.prof-section-link:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.prof-badges-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

/* Featured Strip */
.prof-featured { margin-bottom: 36px; }

.prof-featured-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.prof-featured-card {
  position: relative;
  aspect-ratio: 9 / 14.5;
  border-radius: 12px;
  overflow: hidden;
  background: var(--surface-alt);
  box-shadow: var(--shadow-sm);
  display: block;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.prof-featured-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.prof-featured-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.prof-featured-card:hover img { transform: scale(1.04); }

.prof-featured-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.12) 42%, transparent 65%);
  pointer-events: none;
}

.prof-featured-type {
  position: absolute;
  top: 9px;
  left: 9px;
  z-index: 2;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  color: #ffffff;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(6px);
}

.prof-featured-title {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 12px;
  z-index: 2;
  color: #ffffff;
  font-size: 12.5px;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Content Tabs Header */
.prof-tabs-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
}

.prof-tabs-bar {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  min-width: 0;
}

.prof-tabs-bar::-webkit-scrollbar { display: none; }

.prof-tab-btn {
  position: relative;
  padding: 10px 12px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-muted);
  background: none;
  border: 0;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: color 0.15s ease;
}

.prof-tab-btn:hover { color: var(--text); }
.prof-tab-btn.is-active { color: var(--text); }

.prof-tab-btn.is-active::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 0;
  height: 2.5px;
  border-radius: 3px 3px 0 0;
  background: var(--text);
}

.prof-tab-count {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-tertiary, var(--text-muted));
}

.prof-active-tag-bar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 12.5px;
  font-weight: 600;
  margin-bottom: 16px;
}

.prof-active-tag-bar button {
  background: none;
  border: 0;
  color: inherit;
  cursor: pointer;
  font-size: 15px;
  line-height: 1;
}

/* Grids */
.prof-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.prof-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

/* Shared Card Actions Footer */
.prof-card-actions {
  margin-top: auto;
  padding-top: 8px;
}

.prof-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 4px;
}

.prof-mini-tag {
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
}

.prof-mini-tag:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.prof-cover-fallback {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  background: var(--surface-alt);
  color: var(--text-muted);
}

/* Photos */
.prof-photo-card {
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.prof-photo-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.prof-photo-link {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--surface-alt);
}

.prof-photo-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.prof-photo-overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: 20px 10px 8px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
}

.prof-photo-title {
  color: #ffffff;
  font-size: 12.5px;
  font-weight: 600;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.prof-photo-card .prof-card-actions {
  padding: 6px 8px 8px;
}

/* Posts & Shared */
.prof-post-card {
  display: flex;
  flex-direction: column;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.prof-post-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.prof-post-media {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--surface-alt);
}

.prof-post-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.prof-post-body {
  padding: 13px 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.prof-post-title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
  text-decoration: none;
}

.prof-post-title:hover { color: var(--accent); }

.prof-post-text {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
  margin: 0;
}

/* Galleries & Packs */
.prof-gallery-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.prof-gallery-stack {
  position: relative;
  display: block;
  padding-top: 10px;
  text-decoration: none;
}

.prof-stack-l2,
.prof-stack-l1 {
  position: absolute;
  left: 12px;
  right: 12px;
  height: 14px;
  border-radius: 10px 10px 0 0;
  border: 1px solid var(--border);
}

.prof-stack-l2 { top: 0; left: 20px; right: 20px; background: var(--surface-hover); }
.prof-stack-l1 { top: 5px; background: var(--surface-alt); }

.prof-gallery-cover {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
  background: var(--surface-alt);
  border: 1px solid var(--border);
}

.prof-gallery-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.prof-gallery-pill {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.65);
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  backdrop-filter: blur(6px);
}

.prof-gallery-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Articles & Forums */
.prof-article-card {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 13px;
  padding: 12px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.prof-article-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.prof-article-thumb {
  width: 112px;
  height: 112px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--surface-alt);
}

.prof-article-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.prof-article-cat {
  font-size: 11px;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.prof-article-title {
  font-size: 14.5px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
  text-decoration: none;
}

.prof-article-excerpt {
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
}

/* Books */
.prof-book-card {
  display: flex;
  flex-direction: column;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.prof-book-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.prof-book-cover {
  position: relative;
  aspect-ratio: 3 / 4;
  background: var(--surface-alt);
  overflow: hidden;
  display: block;
}

.prof-book-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.prof-book-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  background: rgba(15, 23, 42, 0.65);
  color: #ffffff;
  backdrop-filter: blur(6px);
}

.prof-book-body {
  padding: 12px 13px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.prof-book-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}

.prof-book-sub {
  font-size: 12px;
  color: var(--text-muted);
}

/* Market */
.prof-market-card {
  display: flex;
  flex-direction: column;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.prof-market-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.prof-market-media {
  display: block;
  aspect-ratio: 4 / 3;
  background: var(--surface-alt);
  overflow: hidden;
}

.prof-market-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.prof-market-body {
  padding: 12px 13px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.prof-market-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.prof-market-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}

.prof-price-pill {
  padding: 2px 8px;
  border-radius: 7px;
  font-size: 11.5px;
  font-weight: 700;
  color: #059669;
  background: rgba(16, 185, 129, 0.14);
  flex-shrink: 0;
}

.prof-market-desc {
  font-size: 12.5px;
  color: var(--text-muted);
  margin: 0;
}

/* Profile Comments Tab (Image-Scroll Compact Theme + Inline Rating Bar) */
.prof-comments-wrap {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 720px;
}

.prof-rate-bar {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.prof-rate-bar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.prof-rate-bar-label {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
}

.prof-rate-bar .disc-composer {
  padding: 4px 6px;
  border-radius: 8px;
}

.prof-rate-bar .disc-composer textarea {
  font-size: 12.5px;
  padding: 4px 6px;
  min-height: 28px;
}

.prof-rate-bar .disc-btn-post {
  height: 28px;
  font-size: 11.5px;
}

/* Empty States */
.prof-empty {
  text-align: center;
  padding: 46px 20px;
  border: 1px dashed var(--border-strong);
  border-radius: 14px;
  color: var(--text-muted);
}

.prof-empty h3 {
  font-size: 15px;
  color: var(--text);
  margin: 0 0 6px;
}

.prof-empty-sm {
  text-align: center;
  padding: 24px 12px;
  color: var(--text-muted);
  font-size: 13px;
}

/* Friends Modal */
.prof-friends-modal {
  max-width: 480px;
  width: 100%;
  padding: 18px 20px 20px;
  display: grid;
  gap: 14px;
}

.prof-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.prof-modal-head h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
}

.prof-friends-tabs {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
}

.prof-ftab {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--surface-alt);
  color: var(--text-muted);
  font-size: 12.5px;
  font-weight: 600;
  border: 0;
  cursor: pointer;
}

.prof-ftab.is-active {
  background: var(--pill-active-bg, #1c1f24);
  color: var(--pill-active-text, #ffffff);
}

.prof-friends-body {
  max-height: 56dvh;
  overflow-y: auto;
}

.prof-fpanel { display: none; gap: 8px; }
.prof-fpanel.is-active { display: grid; }

.prof-friend-row {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 8px 10px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--text);
  transition: background 0.15s ease;
}

.prof-friend-row:hover { background: var(--surface-alt); }

.prof-friend-avatar {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.prof-friend-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.prof-friend-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.prof-friend-meta strong { font-size: 13.5px; }
.prof-friend-meta span { font-size: 12px; color: var(--text-muted); }

/* Responsive */
@media (max-width: 1080px) {
  .prof-page { grid-template-columns: 256px minmax(0, 1fr); }
  .prof-main { padding: 24px 24px 48px; }
}

@media (max-width: 860px) {
  .prof-page { grid-template-columns: 1fr; }

  .prof-sidebar {
    position: static;
    max-height: none;
    border-right: 0;
    border-bottom: 1px solid var(--border);
    padding: 18px 16px 20px;
  }

  .prof-head {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr);
    align-items: start;
    gap: 14px;
    margin-bottom: 14px;
  }

  .prof-head-info {
    display: flex;
    flex-direction: column;
  }

  .prof-avatar-wrap {
    width: 88px;
    height: 88px;
    margin-bottom: 0;
  }

  .prof-avatar-fallback { font-size: 30px; }
  .prof-name { font-size: 17px; }
  .prof-handle { font-size: 12px; }
  .prof-meta-summary { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
  .prof-primary-btn { height: 30px; padding: 0 10px; font-size: 11.5px; gap: 4px; }
  .prof-icon-btn { width: 30px; height: 30px; }

  .prof-main { padding: 20px 16px 48px; }

  .prof-badges-strip {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
    gap: 10px;
    padding-bottom: 4px;
  }

  .prof-badges-strip::-webkit-scrollbar { display: none; }
  .prof-badge-showcase-card { flex: 0 0 144px; }

  .prof-featured-grid {
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
    gap: 12px;
    padding-bottom: 4px;
  }

  .prof-featured-grid::-webkit-scrollbar { display: none; }
  .prof-featured-card { flex: 0 0 132px; }

  .prof-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .prof-grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  .prof-grid-3 { gap: 10px; }
  .prof-article-card { grid-template-columns: 88px minmax(0, 1fr); }
  .prof-article-thumb { width: 88px; height: 88px; }
}

/* ==========================================================================
   Dedicated Friends & Connections Page (/friends)
   ========================================================================== */
.fr-page {
  max-width: 1060px;
  margin: 0 auto;
  padding: 28px 20px 64px;
}

.fr-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.fr-title {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 4px;
  color: var(--text);
}

.fr-sub {
  font-size: 13.5px;
  color: var(--text-muted);
  margin: 0;
}

.fr-search-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  min-width: 220px;
}

.fr-search {
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 13px;
  width: 100%;
}

.fr-tabs {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 12px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  margin-bottom: 22px;
}

.fr-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 14px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.fr-tab:hover { color: var(--text); }

.fr-tab.is-active {
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-sm);
}

.fr-tab-cnt {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
}

.fr-panel { display: none; }
.fr-panel.is-active { display: block; }

.fr-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.fr-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.fr-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

.fr-card-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.fr-avatar {
  position: relative;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  text-decoration: none;
}

.fr-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
}

.fr-avatar span { z-index: 1; }

.fr-meta {
  flex: 1;
  min-width: 0;
}

.fr-name-line {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.fr-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fr-name:hover { text-decoration: underline; }

.fr-badge {
  display: inline-flex;
  align-items: center;
  height: 19px;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 10.5px;
  font-weight: 700;
}

.fr-reason-pill {
  display: inline-flex;
  align-items: center;
  height: 19px;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 10.5px;
  font-weight: 600;
}

.fr-handle {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 1px;
}

.fr-bio {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--text-muted);
  margin: 5px 0 0;
  word-break: break-word;
}

.fr-follow-btn {
  height: 30px;
  padding: 0 12px;
  border-radius: 8px;
  border: 0;
  background: var(--pill-active-bg, #1c1f24);
  color: var(--pill-active-text, #ffffff);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  flex-shrink: 0;
  transition: opacity 0.15s ease, background 0.15s ease;
}

.fr-follow-btn:hover { opacity: 0.9; }

.fr-follow-btn.is-following {
  background: var(--surface-alt);
  color: var(--text);
  border: 1px solid var(--border-strong);
}

.fr-quick-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 6px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.fr-quick-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 30px;
  padding: 0 8px;
  border-radius: 8px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 11.5px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.fr-quick-btn:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.fr-global-section {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
}

.fr-global-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.fr-global-title {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
  color: var(--text);
}

.fr-global-status {
  font-size: 12.5px;
  color: var(--text-muted);
}

@media (max-width: 720px) {
  .fr-grid { grid-template-columns: 1fr; }
  .fr-search-wrap { width: 100%; }
  .fr-tabs { flex-wrap: wrap; }
}
