/* 改善事例のカード。一覧(/owner/cases/)とトップで同じ見た目にする(2026-11-06 たいち) */
.cases-list {
  --cases-text: #222826;
  --cases-text-sub: #5b6260;
  --cases-stat: #f2f4f3;
}
.cases-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 20px;
  margin: 47px 0 0;
  padding: 0;
  list-style: none;
}
/* 高さの違う行を横のカードと揃える(カードの中の6段を、外の表の段に合わせる) */
.case-list-card {
  display: grid;
  grid-row: span 6;
  grid-template-rows: subgrid;
  margin-bottom: 28px;
}
.case-list-card[hidden] {
  display: none;
}
.case-list-card > a {
  display: grid;
  grid-row: span 6;
  grid-template-rows: subgrid;
  overflow: hidden;
  border-radius: 12px;
  background: #fff;
  box-shadow:
    0 0 0 1px rgba(30, 50, 70, 0.05),
    0 3px 12px rgba(30, 50, 70, 0.08);
  color: inherit;
  text-decoration: none;
  transition: box-shadow 0.2s;
}
.case-list-card > a:hover {
  box-shadow:
    0 0 0 1px rgba(30, 50, 70, 0.08),
    0 8px 22px rgba(30, 50, 70, 0.14);
}
.case-list-photo {
  position: relative;
  height: 216px;
  overflow: hidden;
}
.case-list-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.case-list-tag {
  position: absolute;
  top: 13px;
  left: 15px;
  padding: 0 13px;
  border-radius: 4px;
  background: var(--brand-green);
  color: var(--color-text);
  font-size: 13px;
  font-weight: 500;
  line-height: 29px;
  letter-spacing: 0.04em;
}
.case-list-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  margin: 0;
  padding: 11px 19px 0;
  color: var(--cases-text);
  font-size: 11.5px;
  letter-spacing: 0;
  line-height: 18px;
}
.case-list-pin {
  width: 14px;
  height: 14px;
  flex: none;
  margin: 2px 6px 0 0;
  fill: var(--color-primary);
}
.case-list-area {
  flex: none;
  font-weight: 500;
}
.case-list-type {
  position: relative;
  margin-left: 14px;
  padding-left: 15px;
  color: var(--cases-text-sub);
}
.case-list-type::before {
  content: "";
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 0;
  width: 1px;
  background: #c9ccd0;
}
.case-list-title {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 52px;
  margin: 11px 0 0;
  padding: 0 19px;
  color: var(--color-text);
  font-family: var(--font-sans);
  font-size: 19.5px;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 0.05em;
}
.case-list-title small {
  color: var(--cases-text);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.5;
}
.case-list-text {
  margin: 12px 0 0;
  padding: 0 19px;
  color: var(--cases-text-sub);
  font-size: 13px;
  letter-spacing: 0.02em;
  line-height: 20px;
}
.case-list-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-self: start;
  /* 字が2行になった時に枠からはみ出さないよう、高さは最低の値にする(2026-11-10 再総点検 g3-5) */
  min-height: 64px;
  margin: 20px 19px 0;
  border-radius: 8px;
  background: var(--cases-stat);
}
.case-list-stats > div {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-width: 0;
  text-align: center;
}
.case-list-stats > div + div::before {
  content: "";
  position: absolute;
  top: 10px;
  bottom: 10px;
  left: 0;
  width: 1px;
  background: #cfd3d1;
}
.case-list-stats dt {
  color: var(--cases-text-sub);
  font-size: 11px;
  letter-spacing: 0.02em;
  font-weight: 400;
  line-height: 18px;
}
.case-list-stats dd {
  margin: 2px 0 0;
  color: var(--color-text);
  font-size: 16px;
  font-weight: 700;
  line-height: 26px;
  white-space: nowrap;
}
.case-list-stats b {
  margin-inline: 1px;
  font-size: 20px;
  font-weight: 700;
}
.case-list-more {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  margin: 0;
  padding: 19px 19px 20px;
  color: var(--cases-text);
  font-size: 13px;
  letter-spacing: 0.02em;
  font-weight: 700;
  line-height: 22px;
}
.case-list-more::after {
  content: "";
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 50%;
  background: var(--color-primary) url("/img/new/icon-arrow-white.svg") center / 12px no-repeat;
}
.case-list-card > a:focus-visible {
  outline: 2px solid var(--brand-green);
  outline-offset: 2px;
}
@media (max-width: 1140px) {
  .cases-list {
    grid-template-columns: 1fr;
    margin-top: 22px;
  }
  .case-list-card {
    margin-bottom: 20px;
  }
  .case-list-photo {
    height: 200px;
  }
  .case-list-stats dd {
    font-size: 15px;
  }
  .case-list-stats b {
    font-size: 19px;
  }
}

/* 建物種別・間取りのかたまり(2026-11-10 再総点検 g3-4・12)。かたまりの中では折れない。エリア名と並びきらない時は、種別ごと次の行へ回る */
.case-list-nw {
  white-space: nowrap;
}
/* 狭い幅では、エリア名の下の行に建物種別を置く(区切りの線を外し、エリア名の字の頭にそろえる)。
   エリア名が長い事例でも、種別が言葉の途中で折れたり、行の頭に区切りの線が残ったりしない(2026-11-10 再総点検 g3-4) */
@media (max-width: 400px) {
  .case-list-type {
    flex-basis: 100%;
    margin: 2px 0 0 20px;
    padding-left: 0;
  }
  .case-list-type::before {
    display: none;
  }
}
