/* ===============================
   レイアウト基本（フッター下固定）
================================ */

html, body {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
}

.main-content {
  flex: 1;
}

/* ===============================
   Portfolio
================================ */

.portfolio-section {
  padding-top: 120px;
}

/* タイトル */
.title-wrap {
  display: flex;
  justify-content: center;
}

.page-title {
  font-size: 2rem;
  font-family: 'Cormorant Garamond', serif;
  color: #000;
  border-left: 3px solid #2e7344;
  padding-left: 1rem;
  margin-bottom: 3rem;
  width: fit-content;
}

/* ===============================
   ギャラリー
================================ */

.gallery {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto 4rem;
}

.gallery-item {
  width: calc(33.333% - 1.5rem);
  cursor: pointer;
  overflow: hidden;
  border-radius: 6px;
  position: relative;
}

/* 縦横比が違っても整える */
.gallery-item img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
  transition: transform 0.3s;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

/* 撮影年月日 */
.photo-date {
  font-size: 0.85rem;
  color: #555;
  margin-top: 0.4rem;
  text-align: right;
}

/* ===============================
   レスポンシブ
================================ */

@media (max-width: 900px) {
  .gallery-item {
    width: calc(50% - 1.5rem);
  }
}

@media (max-width: 600px) {
  .gallery-item {
    width: 100%;
  }
}

/* ===============================
   ライトボックス
================================ */

.lightbox {
  display: none;
  position: fixed;
  z-index: 10000;
  inset: 0;
  background-color: rgba(0,0,0,0.85);
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.lightbox-content {
  max-width: 90%;
  max-height: 80%;
  margin-bottom: 1rem;
  border-radius: 6px;
}

.lightbox-nav {
  display: flex;
  justify-content: space-between;
  width: 100%;
  max-width: 800px;
}

.lightbox-nav span {
  color: white;
  font-size: 3rem;
  cursor: pointer;
  padding: 0 1rem;
}

.lightbox .close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 3rem;
  color: white;
  cursor: pointer;
}