/* ====== フォント読み込み ====== */
@font-face {
  font-family: 'PopRumCute';
  src: url('./fonts/PopRumCute.otf') format('opentype');
  font-weight: normal;
  font-style: normal;
}

/* ====== ベース ====== */
body {
  font-family: 'PopRumCute', 'M PLUS Rounded 1c', sans-serif;
  background-color: #fff0fa;
  background-image:
    radial-gradient(#ffddee 1.5px, transparent 1.5px),
    radial-gradient(#ffddee 1.5px, transparent 1.5px);
  background-position: 0 0, 10px 10px;
  background-size: 20px 20px;
  color: #a0446f;
  margin: 0;
  padding: 0;
  text-align: center;
  line-height: 1.6;
}

/* ====== ヘッダー ====== */
header {
  background: #fff5fb;
  padding: 50px 20px 30px;
  border-bottom: 3px dotted #ffddee;
  box-shadow: 0 4px 10px #ffe6f3;
}

header h1 {
  font-size: 2.2rem;
  color: #d63384;
  text-shadow: 0 1px 3px #fff;
  background: #fff5fb;
  display: inline-block;
  padding: 12px 28px;
  border-radius: 40px;
  box-shadow: 0 0 20px #ffc1e3;
  border: 3px double #ffddee;
  animation: glowTitle 6s ease-in-out infinite;
}

@keyframes glowTitle {
  0%, 100% { box-shadow: 0 0 20px #ffc1e3; }
  50% { box-shadow: 0 0 30px #ff99cc, 0 0 40px #ffcce6; }
}

/* ====== ギャラリー ====== */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  justify-items: center;
  padding: 40px 20px 80px;
}

.gallery img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-radius: 25px;
  box-shadow: 0 0 20px #ffc1e3;
  cursor: pointer;
  border: 6px double #ffddee;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  background: #fff;
}

.gallery img:hover {
  transform: scale(1.04) rotate(-1deg);
  box-shadow: 0 0 30px #ff99cc;
}

/* ====== モーダル ====== */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(255, 240, 250, 0.95);
  backdrop-filter: blur(8px);
  justify-content: center;
  align-items: center;
  z-index: 1000;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal-content {
  display: block;
  max-width: 90%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 25px;
  border: 8px double #ffddee;
  box-shadow: 0 0 30px #ffb3d9, 0 0 60px #ffcce6;
  background: #fff;
  animation: popUp 0.3s ease;
}

@keyframes popUp {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ====== 閉じるボタン ====== */
.close {
  position: absolute;
  top: 30px;
  right: 40px;
  color: #d63384;
  font-size: 48px;
  font-weight: 400;
  cursor: pointer;
  text-shadow: 0 0 10px #fff, 0 0 20px #ffb3da;
  transition: transform 0.2s, opacity 0.2s;
}

.close:hover {
  transform: rotate(8deg) scale(1.1);
  opacity: 0.7;
}

/* ====== 戻るボタン ====== */
.back-button {
  display: inline-block;
  margin-top: 30px;
  text-decoration: none;
  color: #d63384;
  background: #ffe6f3;
  border: 2px solid #ffb3d9;
  border-radius: 30px;
  padding: 8px 18px;
  font-size: 0.9rem;
  transition: all 0.25s ease;
}

.back-button:hover {
  background: #ffd1eb;
  color: #a0225f;
  transform: scale(1.05);
}

/* ====== フッター ====== */
footer {
  text-align: center;
  font-size: 0.9rem;
  color: #a0446f;
  background: #fff5fb;
  padding: 40px 0 60px;
  border-top: 3px dotted #ffddee;
  box-shadow: 0 -4px 12px #ffe6f3;
  margin-top: 60px;
}
