@charset "utf-8";

body {
  background-color: rgb(225, 225, 225);
}

/* フェードインアニメーション（コンテナ以外用） */
.fade-in:not(.container) {
  opacity: 0;
  animation: fadeIn 1.5s ease-in-out forwards;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ヘッダーロゴのフェードイン */
.logo img.fade-in {
  animation-delay: 0.1s;
}

/* バウンスアニメーション用 */
.bouncer {
  position: fixed;
  width: 10vw;
  height: auto;
  z-index: 9999;
  pointer-events: none;
  will-change: transform;
}

img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

/* メインコンテンツの画像の最適化 */
.container .item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.container .item img {
  width: 100%;
  height: auto;
  border-radius: 0;
  box-shadow: 0 0.5vw 1vw rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

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

/* メインコンテナのフェードイン */
.container {
  width: 90vw;
  margin-right: auto;
  margin-left: auto;
  margin-bottom: 5vh;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 5vw;
  padding: 2vh 2vw;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1s ease-in-out, transform 1s ease-in-out;
}

.container.fade-in {
  opacity: 1;
  transform: translateY(0);
}

/* ロゴ画像は親コンテナと一緒にフェードイン */
.logo-image {
  opacity: 1;
}

.header {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 160px;
}

@media screen and (max-width: 768px) {
  .header {
    /* height: 100px; */
  }
}

.logo {
  text-align: center;
}

.logo img {
  display: inline-block;
  width: 11vw;
}

@media screen and (max-width: 768px) {
  .logo img {
    width: 180px;
  }
}

.footer {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 200px;
}

@media screen and (max-width: 768px) {
  .footer {
    height: 80px;
  }
}

.parity {
  text-align: center;
}

.parity a {
  display: block;
  min-height: 44px;
}

.parity img {
  display: inline-block;
  height: 3vw;
}

@media screen and (max-width: 768px) {
  .parity img {
    width: 100px;
    height: 100%;
  }
}

/* デスクトップ（1024px以上） */
@media (min-width: 1025px) {
  .container {
    grid-template-columns: repeat(2, 1fr);
    gap: 5vw;
  }
}

/* iPad/タブレット（1024px以下） */
@media (max-width: 1024px) {
  .bouncer {
    width: 8vw;
  }

  img {
    display: block;
    width: 100%;
    max-width: 100%;
  }

  .container {
    grid-template-columns: 1fr;
  }
}

.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 1000;
}

.modal:hover {
  box-shadow: none;
  transform: translateY(5px);
  cursor: pointer;
}

/* モーダルのコンテンツ部分 */
.modal-content {
  background-color: white;
  padding: 20px 20px 20px 20px;
  border-radius: 8px;
  width: 50%;
  max-width: 50vw;
  height: 340px;
  max-height: 40%;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  margin: 0px;
  overflow-y: scroll;
  text-align: center;
}

@media screen and (max-width: 768px) {
  .modal-content {
    width: 90%;
    max-width: 90vw;
    max-height: 80%;
  }
}

/* モーダルが開いたときのスタイル */
.modal-overlay.active {
  display: block;
}

/* モーダルを開くボタン */
.open-button {
  position: fixed !important;
  top: 2vh !important;
  right: 2vw !important;
  z-index: 999 !important;
  background: none !important;
  border: none !important;
  cursor: pointer !important;
  padding: 0 !important;
  width: 4vw !important;
  max-width: 60px !important;
  min-width: 40px !important;
  display: block !important;
  visibility: visible !important;
  overflow: visible !important;
  margin: 0 !important;
}

.open-button img {
  width: 100% !important;
  height: auto !important;
  display: block !important;
  visibility: visible !important;
  margin: 0 !important;
}

.modal-icon {
  width: 100%;
  height: auto;
  transition: transform 0.3s ease;
}

.open-button:hover .modal-icon {
  transform: scale(1.1);
}

.close {
  display: inline-block;
  margin-top: 10px;
}

.h1 {
  font-weight: bold;
  text-align: center;
  margin-top: 3%;
  font-size: 100%;
}

.h2 {
  line-height: 1.8;
  font-size: 100%;
  margin-top: 5%;
  margin-bottom: 2%;
  margin-left: 8%;
  margin-right: 8%;
  padding: 0px;
  text-align: center;
}

@media screen and (max-width: 768px) {
  .h2 {
    margin: 0;
    font-size: 14px;
  }
}

.no-posts-message {
  line-height: 1.5;
  text-align: center;
}

.container:has(.no-posts-message) {
  grid-template-columns: 1fr;
}

.bouncer-wrapper {
  display: block;
  position: relative;
  z-index: 9999;
}