@charset "UTF-8";

/****************************************/

/* ページレイアウト */

/****************************************/

main {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 0 16px;
  background: #fff;
  color: #333;
  line-height: 1.5;
  box-sizing: border-box !important;
}

main .product-wrapper {
  padding: 60px 0;
}

/****************************************/

/* 商品一覧 */

/****************************************/

/* .product-title {
  font-size: 28px;
  font-weight: bold;
  margin-bottom: 3rem;
  text-align: center;
} */

h2.h2_ttl03 img {
  width: 100%;
  max-width: 290px;
}
h2.h2_ttl03 {
  margin-bottom: 3rem;
  text-align: center;
  background: none;
  border-radius: 0;
  padding: 0;
  color: inherit;
  font-size: inherit;
  font-size: 22px;
}

.product-filter {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.filter-button {
  position: relative;
  padding: 0.5rem 1rem;
  font-size: 16px;
  background: none;
  border: none;
  color: #333;
  cursor: pointer;
  font-weight: normal;
}
.filter-button::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 1px; /* ← 非アクティブ時 */
  background-color: #ccc;
  transition: all 0.3s ease;
}
.filter-button:hover {
  opacity: 1;
}

.filter-button:hover::after {
  background-color: #333;
  height: 2px;
}

.filter-button.active {
  font-weight: bold;
}
.filter-button.active::after {
  background-color: #333;
  height: 3px; /* ← 非アクティブ時 */
}

.product-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.product-item {
  display: block;
  text-decoration: none;
  color: inherit;
  border: 1px solid #fff;
  padding: 1rem;
  transition: box-shadow 0.3s;
  transition: opacity 0.3s;
}

.product-item:hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  opacity: 0.8;
}

.product-item img {
  width: 100%;
  height: auto;
  object-fit: cover;
  aspect-ratio: 1 / 1;
  margin-bottom: 0.8rem;
}

.product-category {
  font-size: 12px;
  color: #a81e19;
  margin-bottom: 0.3rem;
}

.product-name {
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.product-description {
  font-size: 14px;
  color: #555;
}

/* 売り切れバッジ */
main .product-wrapper .badge-soldout {
  display: inline-block;
  background: #a81e18;
  color: #fff;
  border-radius: 9999px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  vertical-align: middle;
  margin-right: 2px;
}
main .product-wrapper .product-item.is-soldout {
  opacity: 0.9;
  cursor: not-allowed;
}

/****************************************/

/* レスポンシブ対応*/

/****************************************/

@media (max-width: 767px) {
  h2.h2_ttl03 img {
    width: 60%;
    max-width: 290px;
  }
  h2.h2_ttl03 {
    margin-bottom: 5vw;
    font-size: 16px;
    text-align: center;
    line-height: 1.5;
  }
  .product-filter {
    gap: 1rem 1.5rem;
  }
  .filter-button {
    font-size: 14px;
    width: calc(35% - 1rem);
  }
  .product-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .product-item {
    padding: 8px;
  }
  .product-description {
    font-size: 12px;
  }
}

@media (max-width: 640px) {
  main .product-wrapper {
    padding: 30px 0 60px;
  }
}

@media (max-width: 500px) {
  .filter-button {
    font-size: 14px;
    width: calc(40% - 1rem);
  }
}
