@charset "utf-8";
/* CSS Document */

/* 共通カードリスト */
.card-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px; /* カード間の隙間 */
  justify-content: center;
  box-sizing: border-box;
}

.card-item {
  background-color: #fff;
  border: 1px solid #e0d8ce;
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  box-sizing: border-box;
}

.card-item img {
  width: 100%;   /* 横幅いっぱいにフィット */
  height: auto;  /* 縦横比を保って縮小 */
  display: block; /* 下の余白をなくす */
  border-radius: 4px; /* 画像の角を少し丸める（不要なら削除OK） */
}

/* ===============================
   メインカラム全体（幅制限）
   =============================== */
.main-column {
  max-width: 1100px;   /* 最大幅を指定 */
  margin: 55px auto;   /* 上下55px、左右中央寄せ */
  padding: 20px;
  box-sizing: border-box;
}

/* 行列パターン */
/* 1列 */
.card-list.one-column .card-item {
  width: 100%;
}

/* 1行2列 */
.card-list.one-row-two-columns .card-item {
  width: calc((100% - 16px) / 2);
}

/* 2行3列 */
.card-list.two-rows-three-columns .card-item,
.card-list.three-rows-three-columns .card-item {
  width: calc((100% - 32px) / 3); /* gap × (列数-1) = 16×2 */
}

/* 2行4列 */
.card-list.two-rows-four-columns .card-item {
  width: calc((100% - 48px) / 4); /* gap × (列数-1) = 16×3 */
}

/* 3行3列 */
.card-list.three-rows-three-columns .card-item {
  width: calc((100% - 32px) / 3);
}

/* 1行4列 */
.card-list.one-row-four-columns .card-item {
  width: calc((100% - 48px) / 4);
}

/* 背景色パターン */
.main-column.beige {
  background-color: #f8f2e9;
  padding: 20px 20px 40px 20px; 
  border-radius: 16px;
  overflow: hidden;
}

.main-column.white {
  background-color: #FFFFff;
  padding: 20px 20px 40px 20px;
}

.main-column.gray {
  background-color: #f2f2f2;
  padding: 20px 20px 40px 20px;
}

.main-column.img {
  background-image: url('https://www.theblacklab.co.jp/main/craft01.jpg');
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
}

/* セクションタイトル */
.main-column .section-title {
  font-size: 1.5rem;
  margin-bottom: 25px;
  color: #5a4a3f;
}

.section-title-img {
  display: block;
  width: 100%;
  max-width: 600px; /* 好きなサイズに調整 */
  margin: 0 auto 30px; /* 下の余白30px */
}

/* 枠無し画像グリッド */
.image-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.image-item {
  flex: calc((100% - 32px)/3);
  text-align: center;
}

.image-item img {
  width: 100%;
  height: auto;
  display: block;
}

.image-caption {
  margin-top: 8px;
  font-size: 0.9rem;
  color: #5a4a3f;
}

/* トピック左右大画像 */
.topic-left-big, .topic-right-big {
  display: flex;
  gap: 24px;
  align-items: stretch;
}

.topic-left-big .topic-item.big,
.topic-right-big .topic-item.big {
  flex: 1.2;
  display: flex;
  flex-direction: column;
}

.topic-left-big .topic-item.big img,
.topic-right-big .topic-item.big img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.topic-left-big .topic-item.small-grid,
.topic-right-big .topic-item.small-grid {
  flex: 1;
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 24px;
}

.small-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.small-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 新着・右カラム */
.new-restock-section {
  display: flex;
  gap: 20px;
  justify-content: center;
  align-items: flex-start;
  flex-wrap: wrap;
}

.left-column {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  max-width: 540px;
}

.restock-item img {
  width: 100%;
  height: auto;
  display: block;
}

.restock-item p {
  margin: 10px 0;
  line-height: 1.4;
  font-size: 0.9rem;
  text-align: center;
}

.right-column {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  max-width: 260px;
}
