.case-page * {
  box-sizing: border-box;
}

.case-page a {
  text-decoration: none;
}

.case-page img {
  display: block;
  max-width: 100%;
}

.case-inner {
  max-width: 1220px;
  margin: 0 auto;
  padding: 42px 26px 80px;
}

.case-header {
  margin-bottom: 38px;
}

.case-eyebrow {
  letter-spacing: .12em;
  margin: 0 0 8px;
}

.case-title {
  letter-spacing: .08em;
  margin: 0;
}

.case-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 40px;
  align-items: start;
}

.case-layout>section {
  grid-column: 2;
  min-width: 0;
}

.case-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 50px 32px;
}

.case-page .case-grid .case-card {
  min-width: 0;
  width: 100%;
  opacity: 1;
  transform: translateY(0);
  transition: opacity .42s ease, transform .42s ease;
}

.case-page .case-grid .case-card.is-fading-out,
.case-page .case-grid .case-card.is-hidden {
  opacity: 0;
  transform: translateY(6px);
}

.case-page .case-grid .case-card.is-hidden {
  display: none;
}

.case-page .case-grid .case-card>.case-card-link {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  height: 100%;
  min-width: 0;
  padding: 14px 14px 18px;
  border: 1px solid #e7f1f3;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(96, 150, 162, .10);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.case-page .case-grid .case-card>.case-card-link>* {
  flex: 0 0 auto;
  width: 100%;
}

.case-page .case-grid .case-card>.case-card-link:hover {
  border-color: #bddae1;
  box-shadow: 0 14px 32px rgba(96, 150, 162, .16);
  transform: translateY(-3px);
}

.case-page .case-thumb {
  position: relative;
  width: 100%;
  margin: 0;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 10px;
  background: #eef4f5;
}

.case-page .case-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.case-page .case-arrow {
  position: absolute;
  right: 0;
  bottom: 0;
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  background: #fff;
  border-radius: 10px 0 0 0;
  color: #6baebe;
}

.case-page .case-card-title {
  line-height: 1.4;
  margin: 22px 0 10px;
  overflow-wrap: break-word;
  font-size: 18px;
  color: #3f4d50;
}

.case-page .case-tags {
  line-height: 1.7;
  margin: 0 0 15px;
  font-size: 14px;
  color: #c9c9c9;
}

.case-page .case-grid .case-card .case-more {
  display: flex;
  clear: both;
  float: none;
  position: static;
  align-self: center;
  align-items: center;
  justify-content: center;
  margin: auto auto 0;
  min-height: 38px;
  width: 90%;
  padding: 0 10px;
  border: 1px solid #d7c79b;
  border-radius: 4px;
  background: #fbf8ef;
  color: #3f4d50;
  font-size: 13px;
  transition: background .25s ease, color .25s ease, border-color .25s ease;
}

.case-page .case-grid .case-card>.case-card-link:hover .case-more {
  border-color: #b6a064;
  background: #8d7228;;
  color: #fff;
}

.case-page .case-more::after {
  content: "+";
  display: inline-grid;
  font-size: 10px;
  width: 17px;
  height: 17px;
  margin-left: 14px;
  place-items: center;
  border-radius: 50%;
  background: #b6a064;
  color: #fff;
  line-height: 1;
}

.case-filter {
  position: sticky;
  top: 24px;
  grid-column: 1;
  grid-row: 1;
  display: grid;
  gap: 34px;
}

.filter-label {
  display: block;
  margin: 0 0 10px;
}

.filter-select {
  width: 100%;
  min-height: 46px;
  padding: 0 42px 0 16px;
  border: 1px solid #d7c79b;
  border-radius: 23px;
  background-color: #fbf8ef;
  color: #4d4d4d;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 18px) 20px, calc(100% - 13px) 20px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.no-results {
  display: none;
  padding: 70px 0;
  text-align: center;
}

.case-back-link {
  margin: 0 0 26px;
}

.case-detail {
  display: grid;
  grid-template-columns: minmax(260px, 380px) minmax(0, 1fr);
  gap: 70px;
  align-items: start;
}

.detail-photo-list {
  display: grid;
  width: 100%;
  max-width: 380px;
  gap: 36px;
  align-content: start;
}

.detail-photo-list img {
  width: 100%;
  border-radius: 7px;
}

.detail-panel {
  display: grid;
  gap: 25px;
  align-content: start;
}

.detail-section {
  padding: 20px 0;
  border-top: 1px dashed #8fc9d5;
}

.detail-heading {
  margin: 0 0 15px;
  letter-spacing: .08em;
  color: #a1905a;
}

.detail-text {
  margin: 0 0 18px;
}

.detail-meta {
  width: 100%;
  border-collapse: collapse;
}

.detail-meta th {
  width: 96px;
  padding: 0 18px 8px 0;
  text-align: left;
  vertical-align: top;
}

.detail-meta td {
  padding: 0 0 8px;
}

.detail-list {
  margin: 8px 0 0;
}

.price-group {
  margin-bottom: 24px;
}

.detail-subheading {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  font-size: 17px;
  line-height: 1.5;
  color: #7f6a2e;
  letter-spacing: .04em;
}

.detail-subheading::before {
  content: "";
  display: block;
  width: 4px;
  height: 1.2em;
  border-radius: 999px;
  background: #c9b06c;
}

.price-name {
  margin: 0 0 12px;
}

.price-row {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 16px;
  margin: 8px 0;
}

.note {
  margin: 18px 0 0;
  font-size: 13px;
  line-height: 1.7;
  color: #8a999c;
}

@media (max-width: 1150px) {
  .case-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 70px 32px;
  }
}

@media (max-width: 900px) {

  .case-layout,
  .case-detail {
    grid-template-columns: 1fr;
  }

  .case-layout>section,
  .case-filter {
    grid-column: auto;
    grid-row: auto;
  }

  .detail-photo-list {
    justify-self: center;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 560px;
    gap: 18px;
  }

  .detail-photo-list img:first-child {
    grid-column: 1 / -1;
    justify-self: center;
    max-width: 380px;
  }

  .case-filter {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    order: -1;
  }

}

@media (max-width: 640px) {
  .case-inner {
    padding: 30px 18px 58px;
  }

  .case-page .case-card {
    margin-top: 50px;
  }

  .case-layout,
  .case-detail {
    gap: 30px;
  }

  .case-filter,
  .case-grid {
    grid-template-columns: 1fr;
  }

  .case-grid {
    gap: 42px;
  }

  .case-page .case-arrow {
    width: 48px;
    height: 48px;
  }

  .case-page .case-card-title {
    line-height: 1.65;
  }

  .price-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
}
