.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 4列に変更 */
  grid-gap: 10px;
}


.gallery-grid img {
  width: 100%;
  aspect-ratio: 1/1;/* アスペクト比を1:1に設定 */
  
  object-fit: cover; /* 画像がコンテナにフィットするようにする */
  display: block;/* ブロックレベル要素として表示 */
}

@media (min-width: 700px) {
  .gallery-grid {
    grid-template-columns: repeat(4, 1fr); /* 中くらいの画面でも4列 */
  }
  .gallery-grid img {
  width: 100%;
  height: 200px;
  
  object-fit: cover; /* 画像がコンテナにフィットするようにする */
  display: block;
  }

}


@media (min-width: 1200px) 
{
  .gallery-grid {
    grid-template-columns: repeat(5, 1fr); /* 大きな画面では5列 */
  }
	.gallery-grid img {
  width: 100%;
  height: 300px;
  
  object-fit: cover; /* 画像がコンテナにフィットするようにする */
  display: block;
  }
}
/* モーダルウィンドウのスタイル */
.modal {
  display: none; /* 最初は非表示にする */
  position: fixed;
  z-index: 1;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.781);
  align-items: center; /* 垂直方向の中央揃え */
  justify-content: center; /* 水平方向の中央揃え */
}
/* モーダルコンテンツのスタイル */
.modal-content {
  display: block;
  max-width: 90%; /* 画像の最大幅を設定 */
  max-height: 80vh; /* 画像の最大高さを設定 */
  margin: auto; /* 中央揃え */
  object-fit: contain; /* 画像がコンテナに収まるようにする */
}
/* モーダルコンテンツのテキストスタイル */
.modal-text {
  text-align: center;
}


/* クローズボタンのスタイル */
.close {
  position: absolute;
  top: 80px;
  right: 20px;
  color: #aaa;
  font-size: 50px;
}

/* 前のボタンのスタイル */
.prev {
  cursor: pointer;
  position: absolute;
  top: 50%;
  left: 0px; /* 左側に配置 */
  transform: translateY(-50%); /* 垂直方向の中央揃え */
  width: auto;
  padding: 16px;
  color: white;
  font-weight: bold;
  font-size: 20px;
  transition: 0.6s ease;
  border-radius: 3px 0 0 3px;
  user-select: none;
  -webkit-user-select: none;
}

/* 次のボタンのスタイル */
.next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  right: 0px; /* 右側に配置 */
  transform: translateY(-50%); /* 垂直方向の中央揃え */
  width: auto;
  padding: 16px;
  color: white;
  font-weight: bold;
  font-size: 20px;
  transition: 0.6s ease;
  border-radius: 0 3px 3px 0;
  user-select: none;
  -webkit-user-select: none;
}

  .prev:hover, .next:hover {
    background-color: rgba(255, 255, 255, 0.548);
  }

/* ドロップダウンメニューのスタイル */
#folderSelect {
  display: block;
  width: 50%; /* メニューの幅 */
  max-width: 500px;
  margin: 20px auto 20px; /* 上下のマージンと中央揃え */
  padding: 10px; /* 内側の余白 */
  font-size: 1.2em; /* 文字の大きさ */
  cursor: pointer;
  border: 2px solid #444; /* 枠線のスタイル */
  border-radius: 5px; /* 角丸の半径 */
  appearance: none; /* デフォルトのスタイルを無効にする */
  -webkit-appearance: none;
  -moz-appearance: none;
  background-color: #fff; /* 背景色 */
  color: #444; /* 文字色 */
}

/* ドロップダウンメニューの矢印をカスタムスタイルにする */
#folderSelect::-ms-expand {
  display: none;
}

/* ドロップダウンメニューのフォーカス時のスタイル */
#folderSelect:focus {
  outline: none; /* アウトラインを消す */
  border-color: #777; /* フォーカス時の枠線の色 */
}

/* ドロップダウンメニューのホバー時のスタイル */
#folderSelect:hover {
  border-color: #888; /* ホバー時の枠線の色 */
}
#folderSelect {
  /* 以前のスタイルは省略 */
  text-align: center; /* テキストを中央揃えにする */
}

#gallerypage {
	padding: 25px 5%;
}
#catchcopy2 {
	padding: 10px 0 0 0;
}

