/* Wrapper */
.cgm-credentials-wrapper {
  width: 100%;
  margin: 0 auto;
}

/* --- HEADER STYLES --- */
.cgm-creds-header {
  text-align: center;
  margin-bottom: 50px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Eyebrow */
.cgm-eye {
  display: block;
  color: var(--h-eye-c);
  font-size: var(--h-eye-s);
  letter-spacing: var(--h-eye-ls);
  font-weight: var(--h-eye-w);
  text-transform: uppercase;
  margin-bottom: 15px;
}

/* Heading */
.cgm-head {
  color: var(--h-head-c);
  font-size: var(--h-head-s);
  font-family: "Playfair Display", serif;
  margin-bottom: 20px;
  font-weight: 500;
  line-height: 1.2;
}

/* Description */
.cgm-desc {
  color: var(--h-desc-c);
  font-size: var(--h-desc-s);
  line-height: 1.6;
  max-width: 100%;
  margin: 0 auto 30px auto;
}

/* Divider Line */
.cgm-divider {
  width: var(--h-div-w);
  height: 3px;
  background-color: var(--h-div-c);
  margin: 0 auto;
  border-radius: 2px;
}

/* --- GRID STYLES --- */
.cgm-credentials-grid {
  display: grid;
  grid-template-columns: repeat(var(--cgm-cols), 1fr);
  gap: 30px;
  width: 100%;
}

.cgm-cred-card {
  background-color: var(--cgm-card-bg);
  color: var(--cgm-text);
  padding: 30px 25px;
  border-radius: 15px;
  text-align: center;
  border: 1px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.cgm-cred-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* Default Circular Badge (For Acronyms) */
.cgm-cred-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  background-color: rgba(231, 129, 143, 0.1);
  color: var(--cgm-accent);
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 20px;
  border: 1px solid var(--cgm-accent);
  overflow: hidden;
}

/* NEW: Logo Override (Removes circle, allows wide images) */
.cgm-cred-badge.has-logo {
  width: 100%;
  height: 60px; /* Fixed height to keep cards aligned */
  background-color: transparent;
  border: none;
  border-radius: 0;
  overflow: visible;
}

.cgm-cred-badge.has-logo img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 55px; /* Restricts height so it doesn't get too tall */
  object-fit: contain;
  padding: 0;
}

.cgm-cred-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 8px 0;
  color: var(--cgm-text);
  font-family: "Playfair Display", serif;
}

.cgm-cred-detail {
  font-size: 0.9rem;
  opacity: 0.7;
  margin: 0;
  line-height: 1.4;
}

/* Mobile Responsive */
@media (max-width: 900px) {
  .cgm-credentials-grid {
    grid-template-columns: 1fr;
  }
  .cgm-head {
    font-size: 2rem;
  }
}
