/* ── PROFIL MEMBRE — Charte V2 ── */
/* Force dark theme on profile pages regardless of system preference */

/* Force dark theme on all profile panels */
.panel--profile {
  background: var(--jumor-dark, #1D3557) !important;
  color: #fff !important;
  border-color: rgba(255,255,255,0.1) !important;
}

.panel--profile * {
  color: inherit;
}

.panel--profile a {
  color: var(--jumor-ice, #A8DADC);
}

.panel--profile .btn {
  color: #fff;
}

.panel--profile .btn--negative {
  color: var(--jumor-red, #E63946);
}

.panel--profile select,
.panel--profile input,
.panel--profile textarea {
  color: #fff !important;
  background: rgba(255,255,255,0.06) !important;
  border-color: rgba(255,255,255,0.15) !important;
}

.panel--profile select option {
  color: #000;
  background: #fff;
}

/* Hero card */
.profile-hero {
  position: relative;
  background: linear-gradient(135deg, var(--jumor-dark, #1D3557) 0%, var(--deep-teal, #264653) 100%);
  border-radius: 16px;
  padding: 32px 24px 24px;
  text-align: center;
}

.profile-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 100px;
  background: linear-gradient(135deg, var(--jumor-red, #E63946) 0%, #c1121f 100%);
  border-radius: 16px 16px 0 0;
}

.profile-avatar-wrapper {
  position: relative;
  width: 112px;
  height: 112px;
  margin: 0 auto 16px;
  overflow: visible;
}

.profile-avatar-ring {
  width: 112px;
  height: 112px;
  margin: 0 auto;
  border-radius: 50%;
  padding: 3px;
  background: linear-gradient(135deg, var(--jumor-ice, #A8DADC), var(--jumor-red, #E63946));
  overflow: hidden;
}

.profile-avatar-ring img,
.profile-avatar-ring .avatar,
.profile-avatar-ring > * {
  width: 100% !important;
  height: 100% !important;
  border-radius: 50% !important;
  object-fit: cover;
  border: 3px solid var(--jumor-dark, #1D3557);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Ensure monogram text is visible and centered */
.profile-avatar-ring .avatar-monogram {
  font-size: 2.5rem;
  font-weight: 700;
  color: #fff;
}

/* Same technique as .directory-online-dot but on the left */
.profile-flag-badge {
  position: absolute;
  bottom: 2px;
  left: 2px;
  font-size: 22px;
  line-height: 1;
  z-index: 10;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.4));
}

.profile-name {
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
}

.profile-city {
  font-size: 0.88rem;
  color: var(--jumor-ice, #A8DADC);
  margin-bottom: 12px;
}

.profile-bio {
  font-size: 0.92rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.5;
  margin-bottom: 16px;
  max-width: 360px;
  margin-inline: auto;
}

.profile-socials {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 16px;
}

.profile-social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  color: #fff;
  text-decoration: none;
  font-size: 0.9rem;
  border: 1px solid rgba(255,255,255,0.15);
  transition: background 0.15s;
}

.profile-social-btn:hover { background: rgba(255,255,255,0.2); }
.profile-social-btn img {
  width: 18px;
  height: 18px;
  filter: brightness(0) invert(1);
  /* Force white color on SVG icons */
}

.profile-social-btn svg {
  width: 18px;
  height: 18px;
  stroke: #fff;
  fill: none;
}

.profile-member-since {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.45);
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.1);
}

/* Ping button */
.btn-ping {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 24px;
  background: var(--jumor-red, #E63946);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  margin-bottom: 16px;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
}

.btn-ping:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(230, 57, 70, 0.4);
  color: #fff;
}

/* Stats grid */
.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.profile-stat {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 16px 8px;
  text-align: center;
}

.profile-stat--highlight {
  background: linear-gradient(135deg, rgba(230, 57, 70, 0.15), rgba(230, 57, 70, 0.05));
  border-color: rgba(230, 57, 70, 0.3);
}

.profile-stat-number {
  font-family: 'Bebas Neue', var(--font-family-sans, sans-serif);
  font-size: 2rem;
  color: var(--jumor-ice, #A8DADC);
  line-height: 1;
}

.profile-stat--highlight .profile-stat-number {
  color: var(--jumor-red, #E63946);
}

.profile-stat-label {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.5);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Badges */
.profile-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.profile-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 600;
}

.profile-badge--founder {
  background: linear-gradient(135deg, rgba(244, 162, 97, 0.2), rgba(244, 162, 97, 0.1));
  border: 1px solid rgba(244, 162, 97, 0.3);
  color: var(--amber-warning, #F4A261);
}

.profile-badge--streak {
  background: linear-gradient(135deg, rgba(42, 157, 143, 0.2), rgba(42, 157, 143, 0.1));
  border: 1px solid rgba(42, 157, 143, 0.3);
  color: var(--teal-success, #2A9D8F);
}

.profile-badge--rank {
  background: linear-gradient(135deg, rgba(168, 218, 220, 0.2), rgba(168, 218, 220, 0.1));
  border: 1px solid rgba(168, 218, 220, 0.3);
  color: var(--jumor-ice, #A8DADC);
}

/* Section titles */
.profile-section-title {
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--jumor-ice, #A8DADC);
  margin: 24px 0 12px;
}

/* Rooms chips */
.profile-rooms {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.profile-room-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  transition: all 0.15s;
}

.profile-room-chip:hover {
  background: rgba(168, 218, 220, 0.15);
  border-color: var(--jumor-ice, #A8DADC);
  color: #fff;
}

/* Messages cards */
.profile-messages {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.profile-message {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  padding: 12px 16px;
  text-decoration: none;
  color: inherit;
  transition: background 0.15s;
}

.profile-message:hover { background: rgba(255,255,255,0.1); }

.profile-message-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.profile-message-room {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--jumor-ice, #A8DADC);
  background: rgba(168, 218, 220, 0.15);
  padding: 2px 8px;
  border-radius: 9999px;
}

.profile-message-time {
  font-size: 0.73rem;
  color: rgba(255,255,255,0.4);
}

.profile-message-text {
  font-size: 0.87rem;
  color: rgba(255,255,255,0.7);
  line-height: 1.4;
}

.profile-see-all {
  display: block;
  text-align: center;
  color: var(--jumor-blue, #457B9D);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  padding: 12px;
}

.profile-see-all:hover { color: var(--jumor-ice, #A8DADC); }

/* ── EDIT PROFILE ── */
.profile-edit-section {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 16px;
}

.profile-edit-section-title {
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--jumor-ice, #A8DADC);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.profile-edit-field {
  margin-bottom: 12px;
}

.profile-edit-field label {
  display: block;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(255,255,255,0.5);
  margin-bottom: 6px;
  font-weight: 600;
}

.profile-admin-email {
  font-size: 0.95rem;
  color: var(--jumor-ice, #A8DADC);
  padding: 4px 0;
}

.profile-admin-email a {
  color: var(--jumor-ice, #A8DADC);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.profile-edit-field .input {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  color: #fff;
  padding: 10px 14px;
  font-size: 0.92rem;
  width: 100%;
  transition: border-color 0.15s;
}

.profile-edit-field .input:focus {
  outline: none;
  border-color: var(--jumor-ice, #A8DADC);
}

.profile-edit-field .input::placeholder {
  color: rgba(255,255,255,0.3);
}

.profile-edit-field textarea.input {
  resize: vertical;
  min-height: 80px;
}

.btn-save-profile {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 32px;
  background: var(--jumor-red, #E63946);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  width: 100%;
  transition: transform 0.15s, box-shadow 0.15s;
}

.btn-save-profile:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(230, 57, 70, 0.4);
}

/* Avatar edit overlay (camera button) */
.profile-edit-avatar-overlay {
  position: absolute;
  bottom: 4px;
  right: 4px;
  width: 36px;
  height: 36px;
  background: var(--jumor-red, #E63946);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 2px solid var(--jumor-dark, #1D3557);
  z-index: 2;
  font-size: 1rem;
  line-height: 1;
}

/* Delete avatar button */
.profile-delete-avatar-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  background: rgba(155, 34, 38, 0.3);
  border: 1px solid rgba(155, 34, 38, 0.5);
  border-radius: 8px;
  color: #ff6b6b;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  margin-top: 12px;
  transition: background 0.15s;
}

.profile-delete-avatar-btn:hover {
  background: rgba(155, 34, 38, 0.5);
}

/* ── ADMIN PAGE — Matching profile design ── */
.admin-name-form {
  position: relative;
  z-index: 1;
  margin-top: 8px;
}

.admin-name-input {
  background: rgba(255,255,255,0.1) !important;
  border: 1px solid rgba(255,255,255,0.2) !important;
  border-radius: 8px !important;
  color: #fff !important;
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-size: 1.2rem;
  font-weight: 700;
  text-align: center;
  padding: 8px 16px;
  max-width: 280px;
}

.admin-name-input::placeholder {
  color: rgba(255,255,255,0.4);
}

.admin-name-input:focus {
  outline: none;
  border-color: var(--jumor-ice, #A8DADC) !important;
}

.admin-name-save {
  color: #fff;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.admin-name-save:hover {
  background: rgba(255,255,255,0.2);
}

.admin-members-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.admin-members-list li {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 8px 12px;
  transition: background 0.15s;
}

.admin-members-list li:hover {
  background: rgba(255,255,255,0.08);
}

.admin-member-empty {
  text-align: center;
  color: rgba(255,255,255,0.4);
  font-size: 0.88rem;
  padding: 16px 12px;
}

/* Override invite section for dark theme */
.panel--profile .invite-label {
  color: var(--jumor-ice, #A8DADC);
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-size: 0.88rem;
}

.panel--profile .input--actor {
  background: rgba(255,255,255,0.06) !important;
  border: 1px solid rgba(255,255,255,0.15) !important;
  border-radius: 8px;
}

.panel--profile .input--actor input {
  background: transparent !important;
  border: none !important;
  color: #fff !important;
  font-size: 0.85rem;
}

.panel--profile .input--actor img,
.panel--profile .btn--regenerate img {
  filter: brightness(0) invert(1);
}

.panel--profile .btn--regenerate {
  color: #fff;
}

.panel--profile .profile-edit-section .colorize--black {
  filter: brightness(0) invert(1);
}

/* ── QUICK PROFILE (popup avatar menu) ── */
.quick-profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
  color: #fff;
}

.quick-profile__name {
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
  line-height: 1.3;
}

.quick-profile__name a {
  color: #fff;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.3);
  text-underline-offset: 3px;
}

.quick-profile__name a:hover {
  text-decoration-color: #fff;
}

.quick-profile__bio {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
  line-height: 1.4;
  word-break: break-word;
}

.quick-profile__joined {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.4);
  margin: 0;
}

.quick-profile__socials {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-block-start: 4px;
}

.quick-profile__socials a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.quick-profile__socials a:hover {
  background: rgba(255, 255, 255, 0.15);
}

.quick-profile__socials img {
  width: 16px;
  height: 16px;
  filter: brightness(0) invert(1);
}

.quick-profile__website {
  font-size: 0.8rem;
  margin: 0;
}

.quick-profile__website a {
  color: var(--jumor-ice, #A8DADC);
}

.quick-profile__stats {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.85);
  margin-block-start: 8px;
  padding-block-start: 8px;
  border-block-start: 1px solid rgba(255, 255, 255, 0.08);
  width: 100%;
}

.quick-profile__dm {
  width: 100%;
  margin-block-start: 8px;
  --btn-background: #E63946;
  --btn-color: #fff;
  --btn-border-color: transparent;
  border-radius: 8px;
  padding: 10px;
}

.quick-profile__dm img {
  filter: brightness(0) invert(1);
}

.quick-profile__all-messages {
  font-size: 0.78rem;
  margin: 0;
}

.quick-profile__all-messages a {
  color: var(--jumor-ice, #A8DADC);
  text-decoration: none;
}

.quick-profile__all-messages a:hover {
  text-decoration: underline;
}

.quick-profile__inactive {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin: 0;
}

/* ── DIRECTORY PAGE ── */
.directory-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.directory-member {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  padding: 12px 16px;
  transition: background 0.15s;
}

.directory-member:hover {
  background: rgba(255,255,255,0.08);
}

.directory-member--alumni {
  opacity: 0.55;
}

.directory-member-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}

.directory-member-avatar {
  position: relative;
  flex-shrink: 0;
  overflow: visible;
}

.directory-flag-badge {
  position: absolute;
  bottom: 0;
  left: -2px;
  font-size: 14px;
  line-height: 1;
  z-index: 10;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.3));
  pointer-events: none;
}

.directory-online-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 12px;
  height: 12px;
  background: var(--teal-success, #2A9D8F);
  border: 2px solid var(--jumor-dark, #1D3557);
  border-radius: 50%;
}

.directory-member-info {
  flex: 1;
  min-width: 0;
}

.directory-member-name {
  font-family: 'Sora', var(--font-family-sans, sans-serif);
  font-weight: 700;
  font-size: 0.95rem;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.directory-member-bio {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.directory-member-meta {
  margin-top: 4px;
}

.directory-member-seniority {
  font-size: 0.75rem;
  color: var(--jumor-ice, #A8DADC);
  font-weight: 500;
}

.directory-member-stats {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

.directory-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 40px;
}

.directory-stat-number {
  font-family: 'Bebas Neue', var(--font-family-sans, sans-serif);
  font-size: 1.2rem;
  color: var(--jumor-ice, #A8DADC);
  line-height: 1;
}

.directory-stat-label {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
