/* ============================================
   COLLECTIONS — VISUAL COMPONENTS
   Loaded AFTER collections.css

   100% REM-based — ZERO px values
   Dark mode via CSS custom properties
   Mobile-first responsive
   ============================================ */

/* ============================================
   1. VISUAL CARD
   ============================================ */
.visual-card {
  background-color: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  overflow: hidden;
  transition: all var(--transition-smooth);
  position: relative;
}

.visual-card:hover {
  box-shadow: var(--shadow-xl);
  transform: translateY(-0.25rem);
  border-color: var(--border-secondary);
}

.visual-card-image {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  position: relative;
  background-color: var(--bg-tertiary);
}

.visual-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.visual-card:hover .visual-card-image img {
  transform: scale(1.05);
}

.visual-card-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 40%, rgba(0, 0, 0, 0.65));
  pointer-events: none;
  z-index: 1;
}

.visual-card-overlay {
  position: absolute;
  inset: 0;
  background: transparent;
  display: flex;
  align-items: flex-end;
  padding: var(--space-3);
  gap: var(--space-2);
  opacity: 0;
  transition: opacity var(--transition-base);
  z-index: 2;
}

.visual-card:hover .visual-card-overlay {
  opacity: 1;
}

.visual-card-body {
  padding: var(--space-4);
}

.visual-card-title {
  font-weight: var(--font-semibold);
  font-size: var(--text-base);
  color: var(--text-primary);
  line-height: var(--leading-snug);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.visual-card-desc {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: var(--leading-normal);
  margin-top: var(--space-1);
}

.visual-card-badge {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2-5);
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
  color: #FFFFFF;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(0.5rem);
  -webkit-backdrop-filter: blur(0.5rem);
  border-radius: var(--radius-full);
  border: 0.0625rem solid rgba(255, 255, 255, 0.15);
}

.visual-card-stats {
  position: absolute;
  bottom: var(--space-3);
  right: var(--space-3);
  z-index: 3;
  display: flex;
  gap: var(--space-2);
}

.visual-card-footer {
  padding: var(--space-3) var(--space-4);
  border-top: 0.0625rem solid var(--border-primary);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: var(--text-xs);
  color: var(--text-tertiary);
}

/* ============================================
   2. VISUAL CARD PLACEHOLDERS
   Gradient backgrounds when no image present
   ============================================ */
.visual-card-placeholder {
  position: relative;
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.visual-card-placeholder i {
  font-size: var(--text-4xl);
  color: #FFFFFF;
  opacity: 0.6;
}

.visual-card-placeholder.type-COLLECTION {
  background: linear-gradient(135deg, #3B82F6, #8B5CF6);
}

.visual-card-placeholder.type-PHOTO_ALBUM {
  background: linear-gradient(135deg, #8B5CF6, #EC4899);
}

.visual-card-placeholder.type-BOOKMARK {
  background: linear-gradient(135deg, #F59E0B, #EF4444);
}

.visual-card-placeholder.type-WISHLIST {
  background: linear-gradient(135deg, #EC4899, #F43F5E);
}

.visual-card-placeholder.type-INVENTORY {
  background: linear-gradient(135deg, #10B981, #3B82F6);
}

.visual-card-placeholder.type-ARCHIVE {
  background: linear-gradient(135deg, #6B7280, #374151);
}

.visual-card-placeholder.type-PROJECT {
  background: linear-gradient(135deg, #F97316, #EAB308);
}

.visual-card-placeholder.type-SHARE {
  background: linear-gradient(135deg, #06B6D4, #3B82F6);
}

/* ============================================
   3. STAT BADGE (Glassmorphic)
   ============================================ */
.stat-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
  color: #FFFFFF;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(0.5rem);
  -webkit-backdrop-filter: blur(0.5rem);
  border: 0.0625rem solid rgba(255, 255, 255, 0.15);
  line-height: var(--leading-normal);
}

/* ============================================
   4. ACTION BUTTONS ON CARD OVERLAY
   ============================================ */
.visual-action-btn {
  width: var(--touch-target);
  height: var(--touch-target);
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(0.5rem);
  -webkit-backdrop-filter: blur(0.5rem);
  color: #FFFFFF;
  border: 0.0625rem solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: var(--text-sm);
  transition: all var(--transition-fast);
  padding: 0;
  line-height: 1;
}

.visual-action-btn:hover {
  background: rgba(255, 255, 255, 0.35);
  transform: scale(1.1);
}

.visual-action-btn:active {
  transform: scale(0.95);
}

.visual-action-btn.is-bookmarked {
  color: var(--error-500);
}

.visual-action-btn.is-bookmarked:hover {
  background: rgba(239, 68, 68, 0.2);
}

/* ============================================
   5. CAROUSEL SECTION
   ============================================ */
.carousel-section {
  margin-bottom: var(--space-8);
}

.carousel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
}

.carousel-title {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--text-primary);
}

.carousel-nav {
  display: flex;
  gap: var(--space-2);
}

.carousel-nav-btn {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-full);
  background-color: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  padding: 0;
  font-size: var(--text-sm);
}

.carousel-nav-btn:hover {
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
  border-color: var(--border-secondary);
}

.carousel-nav-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.carousel-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  gap: var(--space-4);
  padding-bottom: var(--space-2);
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-card {
  scroll-snap-align: start;
  flex: 0 0 auto;
  width: calc(100% - var(--space-4));
  border-radius: var(--radius-xl);
  overflow: hidden;
  position: relative;
  aspect-ratio: 16 / 9;
  cursor: pointer;
  transition: all var(--transition-smooth);
}

@media (min-width: 40rem) {
  .carousel-card {
    width: calc(50% - var(--space-2));
  }
}

@media (min-width: 64rem) {
  .carousel-card {
    width: calc(33.333% - var(--space-3));
  }
}

@media (min-width: 80rem) {
  .carousel-card {
    width: calc(25% - var(--space-3));
  }
}

.carousel-card:hover {
  transform: translateY(-0.125rem);
  box-shadow: var(--shadow-xl);
}

.carousel-card-image {
  position: absolute;
  inset: 0;
}

.carousel-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.carousel-card:hover .carousel-card-image img {
  transform: scale(1.05);
}

.carousel-card-content {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 30%, rgba(0, 0, 0, 0.75));
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-4);
  color: #FFFFFF;
}

.carousel-card-title {
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  line-height: var(--leading-snug);
  margin-bottom: var(--space-1);
}

.carousel-card-meta {
  font-size: var(--text-xs);
  opacity: 0.85;
}

/* ============================================
   6. SHARE DROPDOWN
   ============================================ */
.share-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: var(--space-2);
  background-color: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  padding: var(--space-2);
  z-index: 50;
  min-width: 14rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-0.5rem);
  transition: all var(--transition-fast);
}

.share-dropdown.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.share-btn {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-lg);
  width: 100%;
  border: none;
  background: none;
  cursor: pointer;
  font-size: var(--text-sm);
  color: var(--text-primary);
  transition: background-color var(--transition-fast);
  font-family: inherit;
}

.share-btn:hover {
  background-color: var(--surface-hover);
}

.share-btn-icon {
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  font-size: var(--text-sm);
  flex-shrink: 0;
}

.share-btn-icon.facebook {
  background-color: #1877F2;
}

.share-btn-icon.twitter {
  background-color: #000000;
}

.share-btn-icon.linkedin {
  background-color: #0A66C2;
}

.share-btn-icon.pinterest {
  background-color: #E60023;
}

.share-btn-icon.whatsapp {
  background-color: #25D366;
}

.share-btn-icon.email {
  background-color: var(--text-tertiary);
}

.share-btn-icon.copy {
  background-color: var(--brand-500);
}

.share-divider {
  height: 0.0625rem;
  background-color: var(--border-primary);
  margin: var(--space-1) 0;
}

/* ============================================
   7. SHIMMER SKELETON
   ============================================ */
.shimmer-card {
  border-radius: var(--radius-xl);
  overflow: hidden;
  background-color: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
}

.shimmer-image {
  aspect-ratio: 4 / 3;
  background-color: var(--bg-tertiary);
  position: relative;
  overflow: hidden;
}

.shimmer-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 100%
  );
  animation: shimmerSlide 1.5s ease-in-out infinite;
}

@keyframes shimmerSlide {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.shimmer-body {
  padding: var(--space-4);
}

.shimmer-line {
  height: 0.75rem;
  border-radius: var(--radius-sm);
  background-color: var(--bg-tertiary);
  margin-bottom: var(--space-3);
  position: relative;
  overflow: hidden;
}

.shimmer-line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 100%
  );
  animation: shimmerSlide 1.5s ease-in-out infinite;
}

.shimmer-line.w-3-4 {
  width: 75%;
}

.shimmer-line.w-1-2 {
  width: 50%;
}

.shimmer-line.w-1-3 {
  width: 33%;
}

.dark .shimmer-image::after,
.dark .shimmer-line::after {
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.04) 50%,
    transparent 100%
  );
}

/* ============================================
   8. BOOKMARK BUTTON
   ============================================ */
.bookmark-btn {
  position: relative;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  line-height: 1;
}

.bookmark-btn .fa-heart {
  transition: all var(--transition-fast);
}

.bookmark-btn.is-bookmarked .fa-heart {
  color: var(--error-500);
  transform: scale(1.2);
}

.bookmark-btn:hover .fa-heart {
  transform: scale(1.15);
}

@keyframes bookmark-pop {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.4);
  }
  100% {
    transform: scale(1.2);
  }
}

.bookmark-btn.just-bookmarked .fa-heart {
  animation: bookmark-pop 0.3s ease;
}

/* ============================================
   9. COMPACT VIEW GRID
   ============================================ */
.compact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
}

@media (min-width: 40rem) {
  .compact-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 64rem) {
  .compact-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.compact-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background-color: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  transition: all var(--transition-smooth);
}

.compact-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-0.0625rem);
}

.compact-card-image {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background-color: var(--bg-tertiary);
}

.compact-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.compact-card-body {
  padding: var(--space-2) var(--space-3);
}

.compact-card-title {
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-card-meta {
  font-size: 0.625rem;
  color: var(--text-tertiary);
  margin-top: var(--space-0-5);
}

/* ============================================
   10. DETAIL HERO BANNER
   ============================================ */
.detail-hero-banner {
  position: relative;
  min-height: 12rem;
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: var(--space-6);
}

@media (min-width: 40rem) {
  .detail-hero-banner {
    min-height: 16rem;
  }
}

.detail-hero-banner-bg {
  position: absolute;
  inset: 0;
}

.detail-hero-banner-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-hero-banner-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 20%, rgba(0, 0, 0, 0.7));
}

.detail-hero-banner-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: inherit;
  padding: var(--space-6);
}

.detail-hero-banner-title {
  font-size: var(--text-2xl);
  font-weight: var(--font-bold);
  color: #FFFFFF;
  margin-bottom: var(--space-2);
}

@media (min-width: 40rem) {
  .detail-hero-banner-title {
    font-size: var(--text-3xl);
  }
}

.detail-hero-banner-desc {
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.85);
  max-width: 36rem;
  margin-bottom: var(--space-4);
  line-height: var(--leading-normal);
}

.detail-hero-banner-stats {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.detail-hero-stat {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(0.25rem);
  -webkit-backdrop-filter: blur(0.25rem);
  padding: var(--space-1-5) var(--space-3);
  border-radius: var(--radius-full);
}

/* ============================================
   11. SOCIAL SHARE ROW (Detail Page)
   ============================================ */
.share-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) 0;
  border-bottom: 0.0625rem solid var(--border-primary);
  margin-bottom: var(--space-6);
}

.share-row-label {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-secondary);
  white-space: nowrap;
}

.share-row-buttons {
  display: flex;
  gap: var(--space-2);
  flex-wrap: wrap;
}

.share-circle {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0.0625rem solid var(--border-primary);
  background-color: var(--bg-secondary);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
  font-size: var(--text-sm);
  padding: 0;
}

.share-circle:hover {
  transform: scale(1.1);
}

.share-circle.facebook:hover {
  background-color: #1877F2;
  color: #FFFFFF;
  border-color: #1877F2;
}

.share-circle.twitter:hover {
  background-color: #000000;
  color: #FFFFFF;
  border-color: #000000;
}

.share-circle.linkedin:hover {
  background-color: #0A66C2;
  color: #FFFFFF;
  border-color: #0A66C2;
}

.share-circle.pinterest:hover {
  background-color: #E60023;
  color: #FFFFFF;
  border-color: #E60023;
}

.share-circle.whatsapp:hover {
  background-color: #25D366;
  color: #FFFFFF;
  border-color: #25D366;
}

.share-circle.email:hover {
  background-color: var(--text-secondary);
  color: #FFFFFF;
  border-color: var(--text-secondary);
}

.share-circle.copy:hover {
  background-color: var(--brand-500);
  color: #FFFFFF;
  border-color: var(--brand-500);
}

/* ============================================
   12. VISUAL CARD ANIMATION (Scroll Reveal)
   ============================================ */
.visual-card-enter {
  opacity: 0;
  transform: translateY(1rem);
}

.visual-card-enter.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition: all var(--transition-smooth);
}

/* ============================================
   13. INDEX PAGE LAYOUT
   Three-panel: sidebar + search + content
   ============================================ */
.index-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  max-width: 90rem;
  margin: 0 auto;
  padding: var(--space-4) var(--space-4);
}

@media (min-width: 48rem) {
  .index-layout {
    grid-template-columns: 16rem 1fr;
    padding: var(--space-6) var(--space-6);
  }
}

@media (min-width: 80rem) {
  .index-layout {
    grid-template-columns: 18rem 1fr;
    padding: var(--space-6) var(--space-8);
  }
}

/* ============================================
   14. INDEX SIDEBAR
   ============================================ */
.index-sidebar {
  display: none;
}

@media (min-width: 48rem) {
  .index-sidebar {
    display: block;
    position: sticky;
    top: 4.5rem;
    max-height: calc(100vh - 5rem);
    overflow-y: auto;
    padding-right: var(--space-2);
    -ms-overflow-style: none;
    scrollbar-width: thin;
    scrollbar-color: var(--border-secondary) transparent;
  }
}

.index-sidebar-title {
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  padding: var(--space-2) var(--space-3);
  margin-bottom: var(--space-1);
}

.index-sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.index-sidebar-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2-5) var(--space-3);
  border-radius: var(--radius-lg);
  cursor: pointer;
  color: var(--text-secondary);
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  transition: all var(--transition-fast);
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  font-family: inherit;
  min-height: var(--touch-target);
}

.index-sidebar-item:hover {
  background-color: var(--surface-hover);
  color: var(--text-primary);
}

.index-sidebar-item.active {
  background-color: var(--brand-50);
  color: var(--brand-600);
  font-weight: var(--font-semibold);
}

.dark .index-sidebar-item.active {
  background-color: rgba(59, 130, 246, 0.1);
  color: var(--brand-500);
}

.index-sidebar-item i {
  width: 1.25rem;
  text-align: center;
  font-size: var(--text-sm);
  flex-shrink: 0;
}

.index-sidebar-children {
  list-style: none;
  padding: 0 0 0 var(--space-6);
  margin: 0;
  overflow: hidden;
  max-height: 0;
  transition: max-height var(--transition-smooth);
}

.index-sidebar-children.is-expanded {
  max-height: 62.5rem;
}

.index-sidebar-toggle {
  margin-left: auto;
  width: 1.5rem;
  height: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: transform var(--transition-fast);
  font-size: 0.625rem;
  color: var(--text-tertiary);
  flex-shrink: 0;
}

.index-sidebar-toggle.is-expanded {
  transform: rotate(90deg);
}

.index-sidebar-divider {
  height: 0.0625rem;
  background-color: var(--border-primary);
  margin: var(--space-3) var(--space-3);
}

/* ============================================
   15. INDEX MOBILE CATEGORIES
   Horizontal scrollable chips on mobile
   ============================================ */
.index-mobile-categories {
  display: flex;
  gap: var(--space-2);
  overflow-x: auto;
  padding-bottom: var(--space-2);
  -ms-overflow-style: none;
  scrollbar-width: none;
  margin-bottom: var(--space-4);
}

.index-mobile-categories::-webkit-scrollbar {
  display: none;
}

@media (min-width: 48rem) {
  .index-mobile-categories {
    display: none;
  }
}

.index-category-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  background-color: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
  white-space: nowrap;
  cursor: pointer;
  transition: all var(--transition-fast);
  font-family: inherit;
  min-height: var(--touch-target);
}

.index-category-chip:hover {
  border-color: var(--border-secondary);
  color: var(--text-primary);
}

.index-category-chip.active {
  background-color: var(--brand-600);
  border-color: var(--brand-600);
  color: #FFFFFF;
}

.index-category-chip i {
  font-size: var(--text-xs);
}

/* ============================================
   16. INDEX SEARCH BAR
   ============================================ */
.index-search-container {
  margin-bottom: var(--space-6);
}

.index-search-bar {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.index-search-input-wrap {
  position: relative;
  flex: 1;
}

.index-search-input-wrap .search-icon {
  position: absolute;
  left: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  pointer-events: none;
  font-size: var(--text-base);
}

.index-search-input {
  width: 100%;
  height: 3.25rem;
  padding: 0 var(--space-12) 0 var(--space-10);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  background-color: var(--bg-secondary);
  color: var(--text-primary);
  font-size: var(--text-base);
  font-family: inherit;
  transition: all var(--transition-fast);
}

.index-search-input:focus {
  outline: none;
  border-color: var(--brand-500);
  box-shadow: 0 0 0 0.1875rem rgba(59, 130, 246, 0.15);
}

.index-search-input::placeholder {
  color: var(--text-tertiary);
}

.index-search-clear {
  position: absolute;
  right: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-tertiary);
  cursor: pointer;
  padding: var(--space-1);
  display: none;
  font-size: var(--text-sm);
}

.index-search-clear.visible {
  display: block;
}

.index-search-advanced-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-lg);
  border: 0.0625rem solid var(--border-primary);
  background-color: var(--bg-secondary);
  color: var(--text-secondary);
  font-size: var(--text-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
  font-family: inherit;
  white-space: nowrap;
  min-height: var(--touch-target);
}

.index-search-advanced-toggle:hover {
  background-color: var(--surface-hover);
  color: var(--text-primary);
}

.index-search-advanced-toggle.active {
  background-color: var(--brand-50);
  border-color: var(--brand-500);
  color: var(--brand-600);
}

.dark .index-search-advanced-toggle.active {
  background-color: rgba(59, 130, 246, 0.1);
  color: var(--brand-500);
}

/* ============================================
   17. INDEX SEARCH SUGGESTIONS DROPDOWN
   ============================================ */
.index-suggestions-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: var(--space-2);
  background-color: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  z-index: var(--z-dropdown, 50);
  max-height: 25rem;
  overflow-y: auto;
  display: none;
}

.index-suggestions-dropdown.is-open {
  display: block;
}

.index-suggestions-group {
  padding: var(--space-2);
}

.index-suggestions-group-title {
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  padding: var(--space-1) var(--space-3);
  margin-bottom: var(--space-1);
}

.index-suggestion-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2-5) var(--space-3);
  border-radius: var(--radius-lg);
  cursor: pointer;
  color: var(--text-primary);
  font-size: var(--text-sm);
  transition: background-color var(--transition-fast);
  text-decoration: none;
}

.index-suggestion-item:hover {
  background-color: var(--surface-hover);
}

.index-suggestion-item i {
  width: 1.25rem;
  text-align: center;
  color: var(--text-tertiary);
  flex-shrink: 0;
}

.index-suggestion-item img {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-md);
  object-fit: cover;
  flex-shrink: 0;
}

/* ============================================
   18. INDEX ADVANCED SEARCH PANEL
   ============================================ */
.index-advanced-panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-smooth), padding var(--transition-smooth);
  background-color: var(--bg-secondary);
  border: 0.0625rem solid transparent;
  border-radius: var(--radius-xl);
}

.index-advanced-panel.is-open {
  max-height: 31.25rem;
  padding: var(--space-4) var(--space-5);
  border-color: var(--border-primary);
  margin-top: var(--space-3);
}

.index-advanced-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 40rem) {
  .index-advanced-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 64rem) {
  .index-advanced-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.index-advanced-field label {
  display: block;
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  color: var(--text-secondary);
  margin-bottom: var(--space-1-5);
}

.index-advanced-actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-3);
  margin-top: var(--space-4);
  padding-top: var(--space-4);
  border-top: 0.0625rem solid var(--border-primary);
}

/* ============================================
   19. INDEX CAROUSEL ROW SECTION
   Wrapper for each row on the index page
   ============================================ */
.index-carousel-row {
  margin-bottom: var(--space-8);
}

.index-carousel-row .carousel-header {
  padding: 0 var(--space-1);
}

.index-carousel-row .carousel-title {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.index-carousel-row .carousel-subtitle {
  font-size: var(--text-sm);
  color: var(--text-tertiary);
  margin-top: var(--space-1);
  font-weight: var(--font-normal);
}

/* ============================================
   20. INDEX SEARCH RESULTS GRID
   ============================================ */
.index-results-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: var(--space-4);
}

@media (min-width: 40rem) {
  .index-results-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 64rem) {
  .index-results-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 80rem) {
  .index-results-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.index-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
}

.index-results-count {
  font-size: var(--text-sm);
  color: var(--text-secondary);
}

.index-results-back {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--brand-500);
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
  padding: var(--space-2);
  border-radius: var(--radius-md);
  transition: background-color var(--transition-fast);
}

.index-results-back:hover {
  background-color: var(--surface-hover);
}

/* ============================================
   21. INDEX PERSONALIZED SECTION
   ============================================ */
.index-personalized-section {
  margin-top: var(--space-8);
  padding-top: var(--space-6);
  border-top: 0.0625rem solid var(--border-primary);
}

.index-personalized-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-1) var(--space-2-5);
  border-radius: var(--radius-full);
  background-color: var(--warning-50);
  color: var(--warning-600);
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  margin-bottom: var(--space-4);
}

.dark .index-personalized-badge {
  background-color: rgba(245, 158, 11, 0.1);
  color: var(--warning-500);
}

/* ============================================
   22. INDEX HERO SECTION (Optional top banner)
   ============================================ */
.index-hero {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: var(--space-6);
  min-height: 10rem;
  background: linear-gradient(135deg, var(--brand-600), var(--brand-800));
}

@media (min-width: 48rem) {
  .index-hero {
    min-height: 12rem;
  }
}

.index-hero-content {
  position: relative;
  z-index: 2;
  padding: var(--space-8) var(--space-6);
  color: #FFFFFF;
}

.index-hero-title {
  font-size: var(--text-2xl);
  font-weight: var(--font-bold);
  margin-bottom: var(--space-2);
}

@media (min-width: 48rem) {
  .index-hero-title {
    font-size: var(--text-3xl);
  }
}

.index-hero-subtitle {
  font-size: var(--text-base);
  opacity: 0.85;
  max-width: 32rem;
}

/* ============================================
   23. INDEX LOADING STATES
   ============================================ */
.index-sidebar-skeleton {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-3);
}

.index-sidebar-skeleton-item {
  height: 2.5rem;
  border-radius: var(--radius-lg);
  background-color: var(--bg-tertiary);
  position: relative;
  overflow: hidden;
}

.index-sidebar-skeleton-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 100%
  );
  animation: shimmerSlide 1.5s ease-in-out infinite;
}

.index-row-skeleton {
  margin-bottom: var(--space-8);
}

.index-row-skeleton-title {
  height: 1.5rem;
  width: 12rem;
  border-radius: var(--radius-md);
  background-color: var(--bg-tertiary);
  margin-bottom: var(--space-4);
  position: relative;
  overflow: hidden;
}

.index-row-skeleton-title::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 100%
  );
  animation: shimmerSlide 1.5s ease-in-out infinite;
}

.index-row-skeleton-track {
  display: flex;
  gap: var(--space-4);
  overflow: hidden;
}

.index-row-skeleton-card {
  flex: 0 0 auto;
  width: calc(100% - var(--space-4));
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-xl);
  background-color: var(--bg-tertiary);
  position: relative;
  overflow: hidden;
}

@media (min-width: 40rem) {
  .index-row-skeleton-card {
    width: calc(50% - var(--space-2));
  }
}

@media (min-width: 64rem) {
  .index-row-skeleton-card {
    width: calc(33.333% - var(--space-3));
  }
}

@media (min-width: 80rem) {
  .index-row-skeleton-card {
    width: calc(25% - var(--space-3));
  }
}

.index-row-skeleton-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 100%
  );
  animation: shimmerSlide 1.5s ease-in-out infinite;
}

/* ============================================
   24. CAROUSEL ROW HEADER — ENHANCED
   Avatar, filter, social icons, subscribe btn
   ============================================ */
.carousel-header-left {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 0;
  flex: 1;
}

.carousel-header-right {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-shrink: 0;
}

.carousel-row-avatar {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 0.125rem solid var(--border-primary);
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
}

.carousel-row-info {
  min-width: 0;
}

.carousel-row-info .carousel-title {
  margin: 0;
}

/* --- Row Filter --- */
.carousel-row-filter-wrap {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.carousel-row-filter-btn {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-full);
  border: 0.0625rem solid var(--border-primary);
  background-color: var(--bg-secondary);
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  padding: 0;
  font-size: var(--text-xs);
}

.carousel-row-filter-btn:hover,
.carousel-row-filter-btn.active {
  background-color: var(--brand-50);
  color: var(--brand-600);
  border-color: var(--brand-500);
}

.dark .carousel-row-filter-btn:hover,
.dark .carousel-row-filter-btn.active {
  background-color: rgba(59, 130, 246, 0.1);
  color: var(--brand-400);
}

.carousel-row-filter-input {
  width: 0;
  max-width: 0;
  height: 2.25rem;
  padding: 0;
  border: 0.0625rem solid transparent;
  border-radius: var(--radius-lg);
  background-color: var(--bg-secondary);
  color: var(--text-primary);
  font-size: var(--text-sm);
  font-family: inherit;
  transition: all var(--transition-smooth);
  opacity: 0;
  overflow: hidden;
}

.carousel-row-filter-input.is-open {
  width: 10rem;
  max-width: 10rem;
  padding: 0 var(--space-3);
  border-color: var(--border-primary);
  opacity: 1;
}

.carousel-row-filter-input:focus {
  outline: none;
  border-color: var(--brand-500);
  box-shadow: 0 0 0 0.125rem rgba(59, 130, 246, 0.15);
}

/* --- Row Social Icons --- */
.carousel-row-social {
  display: flex;
  gap: var(--space-1);
  align-items: center;
}

.carousel-row-social .social-icon {
  width: 1.75rem;
  height: 1.75rem;
  border-radius: var(--radius-full);
  border: 0.0625rem solid var(--border-primary);
  background-color: var(--bg-secondary);
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  padding: 0;
  font-size: 0.625rem;
}

.carousel-row-social .social-icon:hover {
  transform: scale(1.1);
}

.carousel-row-social .social-icon.facebook:hover {
  background-color: #1877F2;
  color: #FFFFFF;
  border-color: #1877F2;
}

.carousel-row-social .social-icon.twitter:hover {
  background-color: #000000;
  color: #FFFFFF;
  border-color: #000000;
}

.carousel-row-social .social-icon.linkedin:hover {
  background-color: #0A66C2;
  color: #FFFFFF;
  border-color: #0A66C2;
}

.carousel-row-social .social-icon.pinterest:hover {
  background-color: #E60023;
  color: #FFFFFF;
  border-color: #E60023;
}

.carousel-row-social .social-icon.email:hover {
  background-color: var(--text-secondary);
  color: #FFFFFF;
  border-color: var(--text-secondary);
}

/* --- Row Subscribe Button --- */
.carousel-row-subscribe {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1-5);
  padding: var(--space-1-5) var(--space-3);
  border-radius: var(--radius-full);
  border: 0.0625rem solid var(--border-primary);
  background-color: var(--bg-secondary);
  color: var(--text-secondary);
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  cursor: pointer;
  transition: all var(--transition-fast);
  font-family: inherit;
  white-space: nowrap;
  min-height: 2.25rem;
}

.carousel-row-subscribe:hover {
  background-color: var(--surface-hover);
  color: var(--text-primary);
  border-color: var(--border-secondary);
}

.carousel-row-subscribe.is-following {
  background-color: var(--brand-600);
  border-color: var(--brand-600);
  color: #FFFFFF;
}

.carousel-row-subscribe.is-following:hover {
  background-color: var(--brand-700);
}

/* --- Mobile responsive --- */
@media (max-width: 47.99rem) {
  .carousel-row-social {
    display: none;
  }

  .carousel-row-filter-input.is-open {
    width: 100%;
    max-width: 100%;
  }

  .carousel-row-subscribe .subscribe-label {
    display: none;
  }

  .carousel-header {
    flex-wrap: wrap;
    gap: var(--space-2);
  }

  .carousel-header-right {
    width: 100%;
    justify-content: flex-end;
  }
}

/* --- Hidden card (filter) --- */
.carousel-card.filter-hidden {
  display: none;
}


/* ============================================================================
   25. COLLECTION PROFILE PAGE
   ============================================================================ */

/* --- Full-Bleed Cover Hero --- */
.profile-cover {
  position: relative;
  width: 100%;
  min-height: 16rem;
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: var(--space-6);
}

@media (min-width: 48rem) {
  .profile-cover {
    min-height: 22rem;
  }
}

.profile-cover-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-cover-gradient {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 70%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, transparent 100%);
  pointer-events: none;
}

.profile-cover-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-6);
  z-index: 2;
  color: white;
}

.profile-cover-title {
  font-size: var(--text-2xl);
  font-weight: var(--font-bold);
  margin-bottom: var(--space-2);
  text-shadow: 0 0.0625rem 0.25rem rgba(0, 0, 0, 0.4);
}

@media (min-width: 48rem) {
  .profile-cover-title {
    font-size: var(--text-3xl);
  }
}

.profile-cover-badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}

.profile-cover-owner {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}

.profile-cover-owner-avatar {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--brand-500);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--font-bold);
  font-size: var(--text-sm);
  border: 0.125rem solid rgba(255, 255, 255, 0.5);
}

.profile-cover-owner-name {
  font-size: var(--text-sm);
  opacity: 0.9;
}

.profile-cover-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  opacity: 0.15;
}

.profile-cover-placeholder.type-COLLECTION {
  background: linear-gradient(135deg, var(--brand-500), var(--brand-700));
}

.profile-cover-placeholder.type-SHARE {
  background: linear-gradient(135deg, var(--success-500), var(--success-700));
}

.profile-cover-placeholder.type-PUBLIC {
  background: linear-gradient(135deg, var(--warning-500), var(--warning-700));
}

/* --- Stats Ribbon --- */
.profile-stats-ribbon {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  background: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  margin-bottom: var(--space-6);
}

.profile-stat-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  color: var(--text-secondary);
}

.profile-stat-item i {
  font-size: var(--text-xs);
  color: var(--text-tertiary);
}

.profile-stat-value {
  font-weight: var(--font-semibold);
  color: var(--text-primary);
}

/* --- CTA Buttons Row --- */
.profile-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}

/* --- About / Bio Section --- */
.profile-about {
  background: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  margin-bottom: var(--space-6);
}

.profile-about-title {
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  color: var(--text-primary);
  margin-bottom: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.profile-about-title i {
  color: var(--text-tertiary);
}

.profile-about-desc {
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-4);
}

.profile-about-meta {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
}

@media (max-width: 47.99rem) {
  .profile-about-meta {
    grid-template-columns: 1fr;
  }
}

.profile-meta-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--text-xs);
  padding: var(--space-2) var(--space-3);
  background: var(--bg-tertiary);
  border-radius: var(--radius-md);
}

.profile-meta-label {
  color: var(--text-tertiary);
  min-width: 5rem;
}

.profile-meta-value {
  color: var(--text-primary);
  font-weight: var(--font-medium);
}

/* --- Tags --- */
.profile-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
}

.profile-tag {
  display: inline-flex;
  align-items: center;
  padding: var(--space-1) var(--space-3);
  background: var(--brand-50);
  color: var(--brand-700);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
  transition: var(--transition-fast);
}

.dark .profile-tag {
  background: var(--brand-900);
  color: var(--brand-200);
}

/* --- Stat Cards --- */
.profile-stat-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

@media (min-width: 48rem) {
  .profile-stat-cards {
    grid-template-columns: repeat(4, 1fr);
  }
}

.profile-stat-card {
  background: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  padding: var(--space-5);
  text-align: center;
  transition: var(--transition-normal);
}

.profile-stat-card:hover {
  transform: translateY(-0.125rem);
  box-shadow: var(--shadow-md);
}

.profile-stat-card-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-3);
  font-size: var(--text-lg);
}

.profile-stat-card-icon.items {
  background: var(--brand-100);
  color: var(--brand-600);
}

.dark .profile-stat-card-icon.items {
  background: var(--brand-900);
  color: var(--brand-300);
}

.profile-stat-card-icon.members {
  background: var(--success-100);
  color: var(--success-600);
}

.dark .profile-stat-card-icon.members {
  background: var(--success-900);
  color: var(--success-300);
}

.profile-stat-card-icon.children {
  background: var(--warning-100);
  color: var(--warning-600);
}

.dark .profile-stat-card-icon.children {
  background: var(--warning-900);
  color: var(--warning-300);
}

.profile-stat-card-icon.activity {
  background: var(--info-100);
  color: var(--info-600);
}

.dark .profile-stat-card-icon.activity {
  background: var(--info-900);
  color: var(--info-300);
}

.profile-stat-card-number {
  font-size: var(--text-2xl);
  font-weight: var(--font-bold);
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.profile-stat-card-label {
  font-size: var(--text-xs);
  color: var(--text-tertiary);
}

/* --- Activity Timeline --- */
.profile-activity {
  background: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  margin-bottom: var(--space-6);
}

.profile-activity-title {
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  color: var(--text-primary);
  margin-bottom: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.profile-activity-title i {
  color: var(--text-tertiary);
}

.profile-timeline {
  position: relative;
  padding-left: var(--space-6);
}

.profile-timeline::before {
  content: '';
  position: absolute;
  left: 0.5rem;
  top: 0;
  bottom: 0;
  width: 0.125rem;
  background: var(--border-primary);
}

.profile-timeline-item {
  position: relative;
  padding-bottom: var(--space-4);
}

.profile-timeline-item:last-child {
  padding-bottom: 0;
}

.profile-timeline-dot {
  position: absolute;
  left: calc(-1 * var(--space-6) + 0.25rem);
  top: 0.125rem;
  width: 0.625rem;
  height: 0.625rem;
  border-radius: 50%;
  background: var(--brand-500);
  border: 0.125rem solid var(--bg-secondary);
}

.profile-timeline-dot.invited {
  background: var(--brand-500);
}

.profile-timeline-dot.role_changed {
  background: var(--warning-500);
}

.profile-timeline-dot.removed {
  background: var(--error-500);
}

.profile-timeline-dot.item_added {
  background: var(--success-500);
}

.profile-timeline-text {
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: 1.5;
}

.profile-timeline-time {
  font-size: 0.625rem;
  color: var(--text-tertiary);
  margin-top: var(--space-1);
}

/* --- Members Row --- */
.profile-members-row {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-6);
}

.profile-member-avatar {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  border: 0.125rem solid var(--bg-primary);
  margin-left: -0.5rem;
  transition: var(--transition-fast);
}

.profile-member-avatar:first-child {
  margin-left: 0;
}

.profile-member-avatar:hover {
  transform: scale(1.1);
  z-index: 1;
}

.profile-member-more {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--brand-100);
  color: var(--brand-600);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  margin-left: -0.5rem;
}

.dark .profile-member-more {
  background: var(--brand-900);
  color: var(--brand-300);
}

/* --- Hierarchy Breadcrumb --- */
.profile-hierarchy-crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  font-size: var(--text-xs);
}

.profile-hierarchy-crumb {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-2);
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition-fast);
}

.profile-hierarchy-crumb:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
}

.profile-hierarchy-separator {
  color: var(--text-tertiary);
  font-size: 0.625rem;
}

/* --- Section Titles (shared) --- */
.profile-section-title {
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  color: var(--text-primary);
  margin-bottom: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.profile-section-title i {
  color: var(--text-tertiary);
}

/* --- Items Masonry Grid --- */
.profile-items-masonry {
  columns: 2;
  column-gap: var(--space-4);
}

@media (min-width: 48rem) {
  .profile-items-masonry {
    columns: 3;
  }
}

@media (min-width: 64rem) {
  .profile-items-masonry {
    columns: 4;
  }
}

.profile-items-masonry .visual-card {
  break-inside: avoid;
  margin-bottom: var(--space-4);
}

/* --- Load More Button --- */
.profile-load-more {
  display: flex;
  justify-content: center;
  padding: var(--space-6) 0;
}

/* --- Chart Container --- */
.profile-chart-container {
  position: relative;
  width: 100%;
  max-width: 12rem;
  margin: 0 auto;
}

/* --- Sub-Collection Cards --- */
.profile-subcollection-card {
  background: var(--bg-secondary);
  border: 0.0625rem solid var(--border-primary);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-4);
  transition: var(--transition-normal);
  text-decoration: none;
  color: inherit;
}

.profile-subcollection-card:hover {
  transform: translateY(-0.125rem);
  box-shadow: var(--shadow-md);
  border-color: var(--brand-300);
}

.profile-subcollection-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: var(--text-lg);
}

.profile-subcollection-info {
  flex: 1;
  min-width: 0;
}

.profile-subcollection-name {
  font-weight: var(--font-semibold);
  font-size: var(--text-sm);
  color: var(--text-primary);
  margin-bottom: var(--space-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.profile-subcollection-meta {
  font-size: var(--text-xs);
  color: var(--text-tertiary);
}

.profile-depth-badge {
  font-size: 0.625rem;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--bg-tertiary);
  color: var(--text-tertiary);
  font-weight: var(--font-semibold);
}
