.rmc {
  width: 100%;
  padding: var(--rmc-pad-top, 28px) 20px var(--rmc-pad-bottom, 28px);
  background: var(--rmc-section-bg, #ffffff);
  box-sizing: border-box;
}

.rmc__inner {
  width: 100%;
  max-width: var(--rmc-max-width, 1440px);
  margin: 0 auto;
}

.rmc__head {
  margin-bottom: 18px;
}

.rmc__title {
  margin: 0;
  color: var(--rmc-title, #214f2f);
  font-size: var(--rmc-title-size, 28px);
  font-weight: 700;
  line-height: 1.2;
}

.rmc__subtitle {
  margin: 6px 0 0;
  color: #7a847c;
  font-size: 13px;
  line-height: 1.4;
}

.rmc__row {
  display: grid;
  grid-template-columns: repeat(var(--rmc-cols, 5), minmax(0, 1fr));
  gap: var(--rmc-gap, 14px);
}

.rmc__slide {
  min-width: 0;
}

.rmc__card {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--rmc-card-border, #ebe6de);
  border-radius: var(--rmc-radius, 18px);
  box-shadow: 0 4px 14px rgba(33, 79, 47, 0.04);
}

.rmc__media {
  position: relative;
  z-index: 0;
  aspect-ratio: 1 / 1.05;
  overflow: hidden;
  background: var(--rmc-media-bg, #f4ebe3);
}

.rmc__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rmc__body {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 42px 14px 18px;
  background: #fff;
}

/* 背包主体：默认纯 CSS 绘制；有上传图时改显示图片 */
.rmc__bag {
  --rmc-bag-w: var(--rmc-bag-size, 88px);
  position: absolute;
  top: 0;
  left: 50%;
  z-index: 2;
  width: var(--rmc-bag-w);
  height: calc(var(--rmc-bag-w) * 0.78);
  pointer-events: none;
  background: #f0d0c6;
  border-radius: 10px 10px 12px 12px;
  box-shadow: 0 8px 18px rgba(90, 55, 40, 0.14);
  transform: translate(-50%, -50%);
  /* 必须 visible，否则提手 ::before 会被裁掉 */
  overflow: visible;
}

/* 提手拱形 */
.rmc__bag::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -62%;
  width: 78%;
  height: 78%;
  border: calc(var(--rmc-bag-w) * 0.095) solid #e7c2b7;
  border-bottom: 0;
  border-radius: 999px 999px 0 0;
  box-sizing: border-box;
  transform: translateX(-50%);
}

/* 品牌字 */
.rmc__bag::after {
  content: "LovinPet";
  position: absolute;
  left: 50%;
  top: 52%;
  color: #836151;
  font-family: Georgia, "Times New Roman", serif;
  font-size: calc(var(--rmc-bag-w) * 0.145);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1;
  white-space: nowrap;
  transform: translate(-50%, -50%);
}

.rmc__bag--image {
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border-radius: 0;
  box-shadow: none;
}

.rmc__bag--image::before,
.rmc__bag--image::after {
  content: none;
}

.rmc__bag img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.rmc__card-title {
  margin: 0;
  color: #1f2a24;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  text-align: center;
}

.rmc__card-quote {
  margin: 0;
  color: #7a847c;
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

@media (max-width: 991.98px) {
  .rmc__row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .rmc {
    padding-inline: 16px;
  }

  .rmc__row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
