/* ===========================================================
   会员风采：企业图文卡片 / 详情
   依赖 style.css 的配色变量，不重复定义设计语言
   =========================================================== */

/* ---------- 列表 ---------- */
.mem-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.mem-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  color: inherit;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.mem-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: #c9dff5;
  color: inherit;
}

/* 封面固定 16:9，无图时用品牌渐变兜底，避免出现破图图标 */
.mem-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #0b4f9e 0%, #2d8cf0 100%);
  overflow: hidden;
}
/* 绝对定位压住首字占位；onerror 移除后占位自动露出 */
.mem-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .5s;
}
.mem-card:hover .mem-cover img { transform: scale(1.04); }

/* 无封面图时的文字占位：取企业名首字，视觉上不空 */
.mem-cover-ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 54px;
  font-weight: 700;
  color: rgba(255, 255, 255, .92);
  letter-spacing: 2px;
}

.mem-body {
  position: relative;
  padding: 26px 22px 22px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.mem-body h3 {
  font-size: 17px;
  line-height: 1.45;
  color: var(--brand-dark);
  margin: 0 0 10px;
}

/* logo 圆形压在封面上，无图时退化为首字母块 */
.mem-logo {
  position: absolute;
  top: -28px;
  left: 22px;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  border: 3px solid #fff;
  background: #fff;
  box-shadow: 0 6px 16px rgba(13, 52, 105, .14);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-weight: 700;
  color: var(--brand);
  font-size: 20px;
}
.mem-logo img { width: 100%; height: 100%; object-fit: contain; }

.mem-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

.mem-summary {
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.75;
  margin: 0 0 16px;
  /* 两行截断，保持卡片等高 */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mem-more {
  margin-top: auto;
  font-size: 13.5px;
  color: var(--brand);
  font-weight: 600;
}
.mem-more::after { content: " →"; transition: transform .2s; }
.mem-card:hover .mem-more::after { display: inline-block; transform: translateX(3px); }

/* ---------- 详情 ---------- */
.mem-detail-head {
  display: flex;
  gap: 22px;
  align-items: flex-start;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line-2);
  margin-bottom: 26px;
}
.mem-detail-logo {
  flex: 0 0 92px;
  width: 92px;
  height: 92px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--brand-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 34px;
  font-weight: 700;
  color: var(--brand);
}
.mem-detail-logo img { width: 100%; height: 100%; object-fit: contain; }
.mem-detail-head h1 {
  font-size: 26px;
  line-height: 1.4;
  color: var(--brand-dark);
  margin: 4px 0 10px;
}
.mem-lead {
  color: var(--text-2);
  font-size: 15px;
  line-height: 1.8;
  margin: 10px 0 0;
}

.mem-detail-cover {
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 28px;
  aspect-ratio: 21 / 9;
  background: linear-gradient(135deg, #0b4f9e 0%, #2d8cf0 100%);
}
.mem-detail-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 荣誉资质：小标题 + 胶囊列表 */
.mem-honors { margin: 30px 0 0; }
.mem-honors h3, .mem-gallery h3 {
  font-size: 17px;
  color: var(--brand-dark);
  margin: 0 0 14px;
  padding-left: 12px;
  border-left: 4px solid var(--brand);
  line-height: 1.2;
}

.mem-gallery { margin: 30px 0 0; }
.mem-gallery-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.mem-gallery-strip img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-s);
  border: 1px solid var(--line);
}

.mem-actions {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line-2);
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ---------- 响应式 ---------- */
@media (max-width: 980px) {
  .mem-grid { grid-template-columns: repeat(2, 1fr); }
  .mem-gallery-strip { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 640px) {
  .mem-grid { grid-template-columns: 1fr; }
  .mem-detail-head { flex-direction: column; gap: 14px; }
  .mem-detail-cover { aspect-ratio: 16 / 9; }
  .mem-gallery-strip { grid-template-columns: repeat(2, 1fr); }
}
