/* ── PAGE PROFIL PUBLIC ── */

.profil-page {}

/* Hero */
.profil-hero {
  max-width: 860px;
  margin: 0 auto;
  padding: 52px 24px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  animation: profil-fade-up .4s ease both;
}

/* Bannière propriétaire */
.profil-owner-banner {
  background: var(--gold-light);
  border: 1px solid rgba(176, 125, 30, .2);
  border-radius: 12px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  width: 100%;
  max-width: 520px;
  text-align: left;
}
html.dark .profil-owner-banner { background: var(--gold-light); }
.profil-owner-banner-icon { font-size: 18px; flex-shrink: 0; }
.profil-owner-banner-text {
  flex: 1;
  font-size: 13px;
  color: var(--gold);
}
.profil-owner-banner-text strong {
  display: block;
  font-weight: 600;
  margin-bottom: 1px;
}

/* Avatar */
.profil-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green-dark), var(--green-mid));
  color: #fff;
  font-family: var(--serif);
  font-size: 2.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 4px solid var(--card);
  box-shadow: 0 0 0 2px var(--green-mid), 0 8px 32px rgba(61, 107, 42, .25);
  margin-bottom: 18px;
  position: relative;
  flex-shrink: 0;
}
.profil-avatar-badge {
  position: absolute;
  bottom: -4px;
  right: -4px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--gold);
  border: 3px solid var(--card);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  line-height: 1;
}

.profil-pseudo {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 400;
  letter-spacing: -.03em;
  color: var(--text);
  margin: 0 0 10px;
  line-height: 1.1;
}

.profil-level-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent);
  color: var(--green-dark);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 14px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 20px;
}

/* Boutons */
.profil-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 20px;
  border-radius: 999px;
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all .15s;
  text-decoration: none;
}
.profil-btn-primary { background: var(--green); color: #fff; }
.profil-btn-primary:hover { background: var(--green-dark); color: #fff; }
.profil-btn-outline {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--line);
}
.profil-btn-outline:hover { border-color: var(--green-mid); background: var(--accent); }
.profil-btn-gold {
  background: transparent;
  color: var(--gold);
  border: 1.5px solid rgba(176, 125, 30, .35);
  font-size: 11px;
  padding: 7px 14px;
  flex-shrink: 0;
}
.profil-btn-gold:hover { background: var(--gold-light); color: var(--gold); }

.profil-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

/* 3 stats hero */
.profil-stats {
  display: flex;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 48px;
  width: 100%;
  max-width: 520px;
  animation: profil-fade-up .4s .1s ease both;
}
.profil-stat {
  flex: 1;
  padding: 20px 16px;
  text-align: center;
  border-right: 1px solid var(--line);
  transition: background .15s;
}
.profil-stat:last-child { border-right: none; }
.profil-stat:hover { background: var(--accent); }
.profil-stat-val {
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 400;
  letter-spacing: -.03em;
  color: var(--text);
  line-height: 1;
  margin-bottom: 4px;
}
.profil-stat-lab { font-size: 11px; color: var(--muted); }

/* Corps */
.profil-body {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px 80px;
}
.profil-grid {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  align-items: start;
}

/* Blocs */
.profil-block {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 20px;
  animation: profil-fade-up .4s .15s ease both;
}
.profil-block:last-child { margin-bottom: 0; }
.profil-block:nth-child(2) { animation-delay: .2s; }

.profil-block-header {
  padding: 16px 20px 12px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.profil-block-title {
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 400;
  color: var(--text);
  margin: 0;
}
.profil-block-count { font-size: 12px; color: var(--muted); }
.profil-block-body { padding: 18px 20px; }

/* Avis */
.profil-review-list { display: flex; flex-direction: column; }
.profil-review-row {
  padding: 14px 20px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  transition: background .12s;
}
.profil-review-row + .profil-review-row { border-top: 1px solid var(--line); }
.profil-review-row:hover { background: var(--bg); }
.profil-review-icon {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: var(--accent);
  color: var(--green-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.profil-review-info { flex: 1; min-width: 0; }
.profil-review-name {
  font-weight: 500;
  font-size: 13px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-decoration: none;
  display: block;
}
.profil-review-name:hover { text-decoration: underline; }
.profil-review-meta {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 3px;
  flex-wrap: wrap;
}
.profil-stars { display: flex; gap: 1px; }
.profil-review-date { font-size: 11px; color: var(--muted); }
.profil-review-asso {
  font-size: 10px;
  font-weight: 500;
  background: var(--accent);
  color: var(--green-dark);
  border-radius: 999px;
  padding: 2px 7px;
}
.profil-review-text {
  font-size: 12px;
  color: var(--muted);
  margin: 5px 0 0;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.profil-review-tag {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 999px;
  flex-shrink: 0;
  align-self: flex-start;
  background: var(--bg);
  color: var(--muted);
  border: 1px solid var(--line);
  white-space: nowrap;
}

/* Partage */
.profil-share-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}
.profil-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  border: 1.5px solid var(--line);
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  transition: all .15s;
}
.profil-share-btn:hover { border-color: var(--green-mid); background: var(--accent); }

/* Associations */
.profil-asso-list { display: flex; flex-direction: column; gap: 8px; }
.profil-asso-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--bg);
  transition: background .12s;
}
.profil-asso-item:hover { background: var(--accent); }
.profil-asso-icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--green-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
  border: 1.5px solid var(--line);
}
.profil-asso-info { flex: 1; min-width: 0; }
.profil-asso-name {
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.profil-asso-bar-wrap {
  margin-top: 4px;
  height: 3px;
  background: var(--line);
  border-radius: 999px;
  overflow: hidden;
}
.profil-asso-bar {
  height: 100%;
  background: var(--green);
  border-radius: 999px;
  min-width: 3px;
}
.profil-asso-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--green);
  white-space: nowrap;
}

/* Streak mini */
.profil-streak-labels {
  display: flex;
  gap: 5px;
  justify-content: center;
  margin-bottom: 6px;
}
.profil-streak-labels span {
  width: 28px;
  text-align: center;
  font-size: 9px;
  color: var(--muted);
  font-weight: 500;
}
.profil-streak-mini {
  display: flex;
  gap: 5px;
  align-items: center;
  justify-content: center;
  padding: 4px 0 6px;
}
.profil-streak-dot {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
}
.profil-streak-dot.active { background: var(--green); color: #fff; }
.profil-streak-dot.today {
  background: var(--accent);
  color: var(--green-dark);
  border: 2px solid var(--green);
}
.profil-streak-info { text-align: center; padding: 8px 0 0; }
.profil-streak-info strong {
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--text);
}
.profil-streak-info p { margin: 2px 0 0; font-size: 11px; color: var(--muted); }

/* Badges */
.profil-badges-row { display: flex; flex-wrap: wrap; gap: 7px; }
.profil-badge-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--accent);
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text);
  transition: border-color .15s;
  cursor: default;
}
.profil-badge-chip:hover { border-color: var(--green-mid); }
.profil-badge-chip span { font-size: 14px; line-height: 1; }

/* CTA rejoindre */
.profil-cta {
  background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 100%);
  border-radius: var(--radius);
  padding: 24px;
  color: #fff;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.profil-cta::before {
  content: '';
  position: absolute;
  right: -40px;
  bottom: -40px;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .06);
  pointer-events: none;
}
.profil-cta h3 {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 400;
  margin: 0 0 8px;
  letter-spacing: -.02em;
}
.profil-cta p { font-size: 13px; opacity: .8; margin: 0 0 18px; line-height: 1.6; }
.profil-cta-btn {
  background: #fff;
  color: var(--green-dark);
  border: none;
  border-radius: 999px;
  padding: 11px 22px;
  font-size: 13px;
  font-weight: 600;
  font-family: var(--sans);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  transition: background .15s;
  text-decoration: none;
}
.profil-cta-btn:hover { background: var(--accent); }

/* État vide */
.profil-empty {
  padding: 20px;
  text-align: center;
  font-size: 13px;
  color: var(--muted);
}

/* Animation */
@keyframes profil-fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Responsive */
@media (max-width: 720px) {
  .profil-grid { grid-template-columns: 1fr; }
  .profil-hero { padding: 36px 20px 0; }
}
@media (max-width: 480px) {
  .profil-stats { flex-direction: column; }
  .profil-stat { border-right: none; border-bottom: 1px solid var(--line); }
  .profil-stat:last-child { border-bottom: none; }
}
