::selection {
  background-color: #ed2e4d; /* your custom green */
  color:             #fff;    /* white text */
}
::-moz-selection {
  background-color: #ed2e4d;
  color:             #fff;
}

/* make sure dark-mode (data-bs-theme="dark") still uses the same style */
[data-bs-theme="dark"] ::selection {
  background-color: #1d5349 !important;
  color:             #fff    !important;
}
[data-bs-theme="dark"] ::-moz-selection {
  background-color: #1d5349 !important;
  color:             #fff    !important;
}/* Redesigned and Renamed Variables CSS */

.team-wrapper {
  padding: 50px 24px !important;
  background-color: #f0f2f5 !important;
  color: #2d2d2d !important;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif !important;
}

.layout-container {
  max-width: 1280px !important;
  margin: 0 auto !important;
}

/* Clean and centered role block layout */
.role-sections {
  display: flex;
  flex-direction: column;
  gap: 32px;
  align-items: center;
}

/* One role block per row */
.role-block {
  width: 100%;
  max-width: 1280px;
  padding: 0 20px;
}

/* Redesigned Role Heading */
.role-heading {
  font-size: 2rem;
  font-weight: 900;
  color: #1d5349;
  text-align: center;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 8px;
}

.role-heading::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background-color: #1d5349;
  border-radius: 2px;
}

/* Default grid behavior */
.profile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
  justify-items: center;
}

.balanced-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  justify-content: center;
}

/* When there are exactly 5 cards — center the 5th */
.balanced-grid > .member-card:nth-child(5):nth-last-child(1) {
  grid-column: 2 / span 2;
}

/* When exactly 6 cards — place 5 and 6 under columns 2 and 3 */
.balanced-grid > .member-card:nth-child(5):nth-last-child(2) {
  grid-column: 2;
}

.balanced-grid > .member-card:nth-child(6):nth-last-child(1) {
  grid-column: 3;
}


.role-block {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
}


/* Uniform card layout */
.member-card {
  width: 100%;
  max-width: 280px;
  min-height: 340px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
  text-align: center;
}

.member-card:hover {
  transform: translateY(-4px);
}

/* Centered avatar */
.profile-image-holder {
  margin-bottom: 16px;
}

/* Avatar style (you already use this) */
.profile-image {
  width: 92px !important;
  height: 92px !important;
  border-radius: 50% !important;
  border: 2px solid rgba(0, 0, 0, 0.5) !important;
  object-fit: cover !important;
}

/* Name & Role Centered */
.person-details {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.display-name {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 6px 0 4px;
}

.role-name {
  font-size: 0.9rem;
  color: #6b7280;
  margin-bottom: 12px;
}

/* Button group */
.social-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

/* Button basics */
.link-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.875rem;
  padding: 6px 12px;
  border-radius: 6px;
  font-weight: 500;
  color: #fff;
  text-decoration: none;
  cursor: default;
}

.discord-link {
  background-color: #5865f2;
}

.steam-link {
  background-color: #171a21;
}



.role-sections {
  display: flex;
  flex-direction: column;
  gap: 48px;
  align-items: center;
}

.role-block {
  width: 100%;
  max-width: 1280px;
}

.profile-image-holder {
  margin-bottom: 14px !important;
}

.profile-image {
  width: 92px !important;
  height: 92px !important;
  border-radius: 50% !important;
  border: none!important;
  object-fit: cover !important;
}

.person-details .display-name {
  font-size: 1.2rem !important;
  font-weight: 600 !important;
  margin: 8px 0 4px !important;
  color: #1f2937 !important;
}

.person-details .role-name {
  font-size: 0.9rem !important;
  color: #6b7280 !important;
  margin-bottom: 14px !important;
}

.social-buttons {
  display: flex !important;
  gap: 10px !important;
  flex-wrap: wrap !important;
  justify-content: center !important;
}

.link-button {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-size: 0.875rem !important;
  padding: 7px 13px !important;
  border-radius: 6px !important;
  text-decoration: none !important;
  font-weight: 500 !important;
  transition: all 0.2s ease-in-out !important;
  color: #ffffff !important;
  cursor: pointer !important;
  transform: scale(1);
}

.link-button:hover {
  transform: scale(1.05);
  opacity: 0.92;
}


.steam-link {
  background-color: #171a21 !important;
}

.steam-link:hover {
  background-color: #1c1e26 !important;
}

.discord-link {
  background-color: #5865f2 !important;
}

.discord-link:hover {
  background-color: #4752c4 !important;
}

/* Dark Mode */
.dark .team-wrapper {
  background-color: #1e1e2f !important;
  color: #e5e7eb !important;
}

.dark .member-card {
  background-color: #2a2d3e !important;
}

.dark .person-details .role-name {
  color: #a1a1aa !important;
}

.dark .link-button {
  color: white !important;
}



@media (max-width: 600px) {
  .role-heading {
    font-size: 1.4rem !important;
  }
  .link-button span {
    display: none !important;
  }
}
