/* 制作事例 */

.case {
  position: relative;
  width: 100%;
  margin-top: 137px;
  padding-bottom: 44px;
}

.case__back-left {
  width: 11.6%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
}

.case__back-right {
  width: 11.6%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  right: 0;
}

.case__inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 10;
  background-color: #fff;
}

.case__sub-ttl {
  font-size: 40px;
  font-family: "Shippori Mincho B1", serif;
  font-weight: 600;
  line-height: 1.65;
  letter-spacing: 0.04em;
  text-align: center;
  color: #1b1464;
  margin-top: 41px;
}

.case__first-col-ttl-box {
  width: 44.9%;
  margin: 0 auto;
  padding-bottom: 13.2%;
  position: relative;
  background-image: url(../images/case/case-h3-back001.png);
  background-size: contain;
  background-repeat: no-repeat;
}

.case__first-col-ttl {
  font-size: 30px;
  font-family: "Shippori Mincho B1", serif;
  font-weight: 700;
  line-height: 135%;
  letter-spacing: 0.14em;
  color: #4d4d4d;
  white-space: nowrap;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
}

.case__first-col-lead {
  font-size: 18px;
  color: #4d4d4d;
  line-height: 200%;
  margin: 2rem 0;
  text-align: center;
}

.case__first-col-content {
  font-size: 17px;
  font-weight: 500;
  line-height: 200%;
  color: #4d4d4d;
  font-feature-settings: "palt";
  margin-top: 40px;
}

.case__first-col-img {
  width: 100%;
  height: auto;
  margin-top: 36px;
}

.case__first-col-ttl-box_width {
  width: 59%;
  background-image: url(../images/case/case-h3-back002.png);
}

.case__sub-ttl_margintop {
  margin-top: 81px;
}

.case__last-cols {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 44px;
  gap: 60px 30px;
}

.case__last-col {
  width: 30%;
}

.case__last-col-img-box {
  width: 100%;
}

.case__last-col-img {
  width: 100%;
  height: 93%;
  object-fit: contain;
  object-position: center center;
}

.case__last-col-ttl {
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 0.04em;
  font-feature-settings: "palt";
  text-align: center;
  white-space: nowrap;
  margin-top: 5px;
}

.case__last-col:nth-of-type(4) > .case__last-col-ttl {
  position: relative;
  left: -8.5%;
}

/* ----------------------------------------------------- */

/* レスポンシブ */

/* ----------------------------------------------------- */

@media screen and (max-width: 1500px) {
  .case__back-right {
    width: 2.6%;
  }

  .case__back-left {
    width: 2.6%;
  }
}

@media screen and (max-width: 1300px) {
  .case__back-right {
    width: 0%;
  }

  .case__back-left {
    width: 0%;
  }
}

@media screen and (max-width: 1240px) {
  .case__first-col {
    width: 100%;
    margin: 5% 0;
  }
  .case__last-col:nth-of-type(4) {
    margin-top: 5vw;
  }

  .case__last-col:last-of-type {
    margin-top: 5vw;
  }

  .case__last-col-ttl {
    font-size: 1.4vw;
  }
}

@media screen and (max-width: 1150px) {
  .case__first-col-ttl {
    font-size: 2.4vw;
  }

  .case__first-col-lead {
    font-size: 16px;
  }
  .case__first-col-content {
    font-size: 16px;
  }

  .case__first-col {
    width: 100%;
    margin-right: 0;
  }

  .case__first-col:last-of-type {
    animation-delay: 0s !important;
    margin-top: 55px;
  }
}

@media screen and (max-width: 768px) {
  .case {
    margin-top: 20px;
    padding-bottom: 25px;
  }

  .case__first-cols {
    justify-content: center;
  }

  .case__first-col {
    width: 100%;
    margin-right: 0;
  }

  .case__first-col-ttl {
    font-size: 30px;
  }

  .case__first-col-lead {
    font-size: 14px;
  }

  .case__first-col-content {
    font-size: 14px;
  }

  .case__last-cols {
    gap: 40px;
  }

  .case__last-col {
    max-width: 500px;
    width: 100%;
    animation-delay: 0s !important;
  }

  .case__last-col:nth-of-type(3),
  .case__last-col:nth-of-type(4) {
    margin-top: 60px;
  }

  .case__last-col:last-of-type {
    max-width: 480px;
    width: 100%;
    margin-top: 60px;
    margin-right: 0;
  }

  .case__last-col-ttl {
    font-size: 14px;
  }

  .case__last-col:nth-of-type(4) > .case__last-col-ttl {
    left: -0.5%;
  }
}

@media screen and (max-width: 715px) {
  .case__last-col {
    max-width: 500px;
  }

  .case__last-col:nth-of-type(3),
  .case__last-col:nth-of-type(4) {
    margin-top: 0px;
  }

  .case__last-col:last-of-type {
    margin-top: 0px;
  }

  .case__last-cols .case__last-col {
    margin-top: 35px;
  }
}

@media screen and (max-width: 605px) {
  .case__first-col-ttl {
    font-size: 6.1vw;
  }

  .case__first-col-ttl-box {
    width: 55.9%;
    padding-bottom: 16.2%;
  }

  .case__sub-ttl {
    font-size: 30px;
  }

  .case__first-col-ttl-box_width {
    width: 73.1%;
  }

  .case__last-cols {
    margin-top: 0px;
  }
}

/* gridレイアウト変更 20250627 */

.case__list {
  font-size: 16px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px; /* カラムの間隔（調整可） */
  align-items: stretch;
  padding: 0;
  margin: 2.5em 0 0;
  text-align: center;
}

/* カード全体をリンクにした場合の<a>タグ用スタイル */
.case__list-link {
  display: block; /* ブロックにしてカード全体をクリック可能に */
  overflow: hidden;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

a.case__list-link:hover,
a.case__list-link:focus {
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  transform: translateY(-6px);
  outline: none;
}

.case__list-link:focus-visible {
  outline: 2px solid #005fcc;
  outline-offset: 2px;
}

.case__list-img {
  width: 95%;
  height: auto;
  border-bottom: 1px solid #efefef;
  padding-top: 0.5rem;
}

.case__list-ttl {
  font-size: 1.125em;
  font-weight: bold;
  text-align: center;
  line-height: 150%;
  margin-top: 0.5em;
  padding: 0 1em;
}

.case__list-desc {
  line-height: 150%;
  font-size: 1em;
}

.case__list-side {
  margin-top: 0.25em;
  padding: 0 1em;
  padding: 0 1em 1em;
  list-style: none;
  color: #555;
}

.case__list-side li {
  line-height: 150%;
  text-align: center;
  margin-bottom: 0.3em;
}

/* タブレット対応（2カラム） */
@media (max-width: 1024px) {
  .case__list {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* @media (max-width: 768px) {
  .case__list,
  .case__first-cols {
    grid-template-columns: 1fr;
    font-size: 14px;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .case__list,
  .case__first-cols {
    grid-template-columns: repeat(2, 1fr);
    gap: 40px; /* 統一 *
    font-size: 16px;
  }
} */

/* スマホ対応（1カラム） */
@media (max-width: 640px) {
  .case__list {
    grid-template-columns: 1fr;
    font-size: 14px;
  }
}

/* 20250630グリッドレイアウトに */
.case__first-cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 80px;
  align-items: start;
}

@media (max-width: 768px) {
  .case__first-cols {
    grid-template-columns: 1fr;
  }
}
