/* ═══════════════════════════════════════════
   Elvera — Public Profile Page
   Dark canvas, gold accents, Fraunces/Montserrat
   ═══════════════════════════════════════════ */


/* ── PAGE ── */
.profile-page {
  background: var(--dark-deep);
  color: var(--c-cream);
  min-height: 100vh;
  padding-top: 100px;
  padding-bottom: var(--section-pad);
}


/* ═══════════════════════════════════════════
   PROFILE HEADER
   ═══════════════════════════════════════════ */
.profile-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
  padding: 0 var(--side-pad);
}

/* Avatar */
.profile-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  border: 2px solid rgba(241,234,222,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 28px;
  color: var(--c-cream);
  letter-spacing: 1px;
  margin-bottom: 20px;
  overflow: hidden;
}
.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

/* Name */
.profile-name {
  font-family: var(--serif);
  font-weight: 400;
  font-size: var(--h3);
  color: var(--c-cream);
  line-height: 1.2;
  margin-bottom: 4px;
}

/* Number */
.profile-number {
  font-family: var(--sans);
  font-weight: 800;
  font-size: var(--h6);
  color: var(--gold);
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

/* Essence */
.profile-essence {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.6;
  color: rgba(241,234,222,0.6);
  max-width: 440px;
  margin-bottom: 24px;
}

/* Stats */
.profile-stats {
  display: flex;
  gap: 32px;
  margin-bottom: 24px;
}
.profile-stats span {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  color: rgba(241,234,222,0.5);
  letter-spacing: 0.02em;
}
.profile-stats .stat-value {
  font-weight: 700;
  color: var(--c-cream);
}

/* Traits */
.profile-traits {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 16px;
}
.trait-chip {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 500;
  padding: 5px 14px;
  border-radius: 50px;
  background: var(--gold-soft);
  color: var(--gold);
  letter-spacing: 0.02em;
}

/* Divider */
.profile-divider {
  width: 100%;
  max-width: 600px;
  height: 1px;
  background: rgba(241,234,222,0.08);
  margin: 40px auto;
}


/* ═══════════════════════════════════════════
   POSTS GRID
   ═══════════════════════════════════════════ */
.profile-posts {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 var(--side-pad);
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

@media (max-width: 768px) {
  .posts-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}
@media (max-width: 480px) {
  .posts-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

/* Post card */
.post-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(241,234,222,0.08);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.2s, transform 0.15s var(--ease-fast);
  cursor: default;
}
.post-card:hover {
  border-color: rgba(241,234,222,0.16);
  transform: translateY(-2px);
}

/* Post type badge */
.post-type-badge {
  display: inline-flex;
  align-self: flex-start;
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  background: var(--gold-soft);
  padding: 3px 10px;
  border-radius: 50px;
}

/* Post body */
.post-body {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 300;
  line-height: 1.7;
  color: rgba(241,234,222,0.8);
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Media preview */
.post-media {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255,255,255,0.03);
  aspect-ratio: 4 / 3;
}
.post-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Play overlay for voice/video */
.post-media .play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.35);
}
.post-media .play-overlay svg {
  width: 40px;
  height: 40px;
  color: var(--c-cream);
  opacity: 0.9;
}

/* Post footer */
.post-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}
.post-save-count {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 400;
  color: rgba(241,234,222,0.35);
  display: flex;
  align-items: center;
  gap: 5px;
}
.post-save-count svg {
  width: 14px;
  height: 14px;
  opacity: 0.6;
}
.post-date {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 400;
  color: rgba(241,234,222,0.25);
}

/* Load more */
.load-more {
  display: block;
  margin: 40px auto 0;
  background: transparent;
  border: 1.5px solid rgba(241,234,222,0.2);
  color: rgba(241,234,222,0.6);
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  padding: 12px 36px;
  border-radius: 50px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.load-more:hover {
  border-color: rgba(241,234,222,0.4);
  color: var(--c-cream);
}


/* ═══════════════════════════════════════════
   EMPTY & LOADING STATES
   ═══════════════════════════════════════════ */
.profile-loading,
.profile-error,
.profile-empty {
  text-align: center;
  padding: 80px var(--side-pad);
  max-width: 480px;
  margin: 0 auto;
}
.profile-loading p,
.profile-error p,
.profile-empty p {
  font-family: var(--sans);
  font-size: 15px;
  color: rgba(241,234,222,0.4);
  line-height: 1.6;
}
.profile-error p {
  color: rgba(241,234,222,0.5);
}

/* Skeleton pulse */
.skeleton {
  background: rgba(255,255,255,0.06);
  border-radius: 8px;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}
@keyframes skeleton-pulse {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 0.3; }
}
.skeleton-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  margin: 0 auto 20px;
}
.skeleton-name {
  width: 200px;
  height: 28px;
  margin: 0 auto 8px;
}
.skeleton-number {
  width: 80px;
  height: 18px;
  margin: 0 auto 12px;
}
.skeleton-essence {
  width: 320px;
  height: 40px;
  margin: 0 auto 24px;
}
.skeleton-card {
  height: 200px;
  border-radius: 16px;
}


/* ═══════════════════════════════════════════
   CTA BANNER
   ═══════════════════════════════════════════ */
.profile-cta {
  text-align: center;
  margin-top: 60px;
  padding: 48px var(--side-pad);
  border-top: 1px solid rgba(241,234,222,0.06);
}
.profile-cta p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: rgba(241,234,222,0.5);
  margin-bottom: 20px;
}
.profile-cta .btn-gold {
  font-size: 15px;
  padding: 14px 36px;
}
