@charset "UTF-8";

/* ==========================================================================
   case page
   ========================================================================== */

.case {
  font-family: "Noto Sans JP", sans-serif;
  font-weight: 400;
}

.case .red {
  color: #e60012;
}

/* --- MV --- */
.case__mv .swiper-slide img {
  width: 100%;
  height: auto;
  aspect-ratio: 977/338;
  object-fit: cover;
}
.case__mv-main {
  font-size: clamp(22px, 14px + 2.2vw, 40px);
  line-height: 1.4;
  letter-spacing: 0.12em;
}
.case__mv-below {
  margin-top: 18px;
  font-size: clamp(12px, 10px + 0.5vw, 18px);
  line-height: 1.4;
  letter-spacing: 0.1em;
  font-weight: 300;
}

/* --- Intro --- */
.case-about01 {
  padding-top: 80px;
  padding-bottom: 40px;
}
.case-about01 .case__ttl {
  letter-spacing: 0.08em;
}
.case-about01 .case__desc {
  margin-top: 20px;
  font-family: "Noto Serif JP", serif;
  letter-spacing: 0.05em;
}
.case-about01 .case__text {
  margin-top: 44px;
  text-align: center;
  line-height: 2.2;
}

/* --- Section --- */
.case-section {
  padding: 72px 0;
}
.case-section--bg {
  background-color: #f5f2f0;
}

/* --- Category title --- */
.case__category-ttl {
  position: relative;
  font-family: "Noto Serif JP", serif;
  font-size: clamp(22px, 16px + 0.8vw, 24px);
  color: #000;
  padding-left: 20px;
  margin-bottom: 24px;
  line-height: 1.4;
}
.case__category-ttl::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  width: 1px;
  height: 40px;
  background-color: #707070;
}
.case__category-text {
  font-size: 16px;
  line-height: 2;
  color: #000;
  margin-bottom: 16px;
  padding-left: 16px;

}

/* --- Case item --- */
.case__item {
  margin-top: 56px;
  padding: 40px 0px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
  grid-template-rows: min-content 1fr;
  grid-template-areas:
    "media info"
    "patient info";
  column-gap: 48px;
  row-gap: 24px;
  align-items: start;
}
.case__item:first-of-type {
  margin-top: 16px;
}
.case__item + .case__item {
  margin-top: 48px;
}

/* --- Figure (single image) --- */
.case__figure {
  grid-area: media;
  margin: 0;
  max-width: 100%;
}
.case__figure img {
  display: block;
  width: 100%;
  height: auto;
}

/* --- Figures grid (multiple separate images) --- */
.case__figures {
  grid-area: media;
  display: grid;
  gap: 12px;
  max-width: 100%;
}
.case__figures--2 {
  grid-template-columns: 1fr 1fr;
}
.case__figures .case__figure {
  grid-area: auto;
  max-width: 100%;
}

/* --- Captions (directly below image, colored by before/after) --- */
.case__captions {
  display: flex;
  gap: 0;
  padding: 0;
  width: 100%;
}
.case__captions > span {
  flex: 1 1 0;
  min-width: 0;
  text-align: center;
  padding: 3px 6px;
  font-family: "Noto Sans JP", sans-serif;
  font-size: 12px;
  line-height: 1.4;
  letter-spacing: 0.05em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
}
/* before: white bg + green text */
.case__captions > span:first-child,
.case__figures > .case__figure:first-child .case__captions > span {
  background-color: #fff;
  color: #007e63;
}
/* after: green bg + white text */
.case__captions > span:nth-child(n+2),
.case__figures > .case__figure:nth-child(n+2) .case__captions > span {
  background-color: #007e63;
  color: #fff;
  border: 1px solid #007e63;
}

/* --- Detail block (dissolved into case__item grid) --- */
.case__detail {
  display: contents;
}
.case__patient {
  grid-area: patient;
  align-self: start;
}
.case__info {
  grid-area: info;
  margin: 0;
  letter-spacing: 0.1em;
}
.case__detail-ttl {
  font-family: "Noto Sans JP", serif;
  font-size: 16px;
  font-weight: 500;
  color: #84563d;
  letter-spacing: 0.04em;
}
.case__detail-text {
  font-size: 16px;
  line-height: 1.95;
  margin: 0;
}

.case__info dt {
  font-family: "Noto Sans JP", serif;
  font-size: 16px;
  color: #84563d;
  margin-top: 18px;
  padding-bottom: 6px;
  letter-spacing: 0.04em;
}
.case__info dt:first-child {
  margin-top: 0;
}
.case__info dd {
  font-size: 16px;
  line-height: 1.95;
  color: #000;
}

/* --- Responsive --- */
@media (max-width: 780px) {
  .case-section {
    padding: 48px 0;
  }
  .case__item {
    padding: 24px 18px;
    margin-top: 32px;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "media"
      "patient"
      "info";
    column-gap: 0;
    row-gap: 20px;
  }
  .case__item + .case__item {
    margin-top: 32px;
  }
  .case__captions {
    gap: 4px;
  }
  .case__captions > span {
    font-size: 12px;
    padding: 3px 2px;
    letter-spacing: 0;
  }
  .case__category-ttl {
    font-size: 20px;
    padding-left: 14px;
  }
  .case__category-ttl::before {
    width: 2px;
  }
  .case__category-text {
    font-size: 16px;
    line-height: 1.9;
  }
  .case__figures--2 {
    gap: 10px;
  }
  .case-about01 {
    padding-top: 56px;
  }
  .case-about01 .case__text {
    text-align: left;
    line-height: 2;
  }
  .case__detail-ttl {
    font-size: 16px;
  }
  .case__detail-text,
  .case__info dd {
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  .case__captions--3 > span {
    font-size: 11px;
  }
}
