/* 共通スタイル */
* {
  margin: 0;
}
html,
body {
  overflow-x: hidden;
}

h2 {
  text-align: center;
  font-size: 32px;
  margin-bottom: 72px;
  color: #383e45;
}

.section {
  padding: 50px 0;
}

/* ヘッダー */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 124px;
}

h1 {
  font-size: 28px;
  background-color: #000000;
  color: #ffffff;
  padding: 12px 24px;
}

nav ul {
  display: flex;
  gap: 30px;
  list-style: none;
}

nav a {
  color: #24292e;
  text-decoration: none;
  transition: background 0.2s ease;
}

/* ヒーローセクション */
.hero {
  margin-bottom: 30px;
}
.hero img {
  width: 100%;
  height: 90vh; /* 画面高さの60%くらいに調整 */
  object-fit: cover; /* 余白なく切り取り */
}

/* aboutセクション */
.about-contents {
  display: flex;
  gap: 24px;
  text-align: center;
  align-items: center;
  justify-content: center;
}
.about-img img {
  border-radius: 50%;
  object-fit: cover;
}
.about-info {
  display: flex;
  flex-direction: column; /* 縦並び */
  width: 400px;
}
.about-name {
  text-align: left;
  font-weight: bold;
  font-size: 16px;
  margin-bottom: 10px;
}
.about-text {
  font-size: 14px;
  text-align: left;
  line-height: 1.6;
}

/* futsalセクション */
.futsal-contents {
  display: grid;
  grid-template-columns: repeat(4, 200px); /* PC・タブレットでは4列固定 */
  gap: 16px;
  justify-content: center;
}
.futsal-item {
  text-align: center;
  cursor: pointer;
}
.futsal-item img {
  width: 100%;
  aspect-ratio: 4 / 3; /* 4:3の比率を維持 */
  object-fit: cover; /* はみ出した部分はトリミング */
  border-radius: 8px;
  display: block;
}
/* モーダル全体 */
.modal {
  position: fixed;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
  z-index: 999;
}
.modal.open {
  opacity: 1;
  visibility: visible;
}

/* モーダル中身 */
.modal-content {
  position: relative; /* 追加 */
  background: #fff;
  padding: 24px;
  border-radius: 8px;
  width: 90%;
  max-width: 600px;
  text-align: center;
}

/* 閉じるボタン */
.modal-close {
  position: absolute;
  top: 2px;
  right: 2px;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #666;
}

/* 画像は横幅いっぱい */
.modal-content img {
  width: 100%; /* 横幅いっぱい */
  height: auto; /* 縦横比は維持 */
  max-height: 80vh; /* 画面の縦の80%までに制限 */
  object-fit: contain; /* はみ出さず全体表示 */
}

/* タイトル、日付、説明 */
.modal-header {
  display: flex;
  justify-content: space-between; /* タイトルと日付を左右に分ける */
  align-items: center; /* 高さを揃える */
  margin-bottom: 16px; /* 下に余白 */
}

.modal-header h3 {
  font-size: 20px;
  margin: 0;
}

.modal-header time {
  font-size: 14px;
  color: #666;
}
.modal-content p {
  font-size: 16px;
  line-height: 1.6;
  text-align: left;
}

/* フッター */
footer {
  margin: 50px 0;
  font-size: 8px;
  text-align: center;
}

/* --------------------
  レスポンシブ調整
-------------------- */
@media (max-width: 1000px) {
  /* タブレット表示 */
}

@media (max-width: 640px) {
  /* SP表示 */

  /* 共通 */
  .section {
    padding: 50px 14px;
  }
  h2 {
    margin-bottom: 48px;
  }

  /* ヘッダー */
  header {
    padding: 16px;
  }
  nav ul {
    gap: 12px;
    padding: 0;
  }

  /* aboutセクション */
  .about-contents {
    flex-direction: column;
    gap: 16px;
  }
  .about-info {
    width: 100%;
    padding: 0 16px;
  }
  .about-text {
    font-size: 14px;
    text-align: left;
  }

  /* futsalセクション */
  .futsal-contents {
    grid-template-columns: 1fr; /* スマホは1列 */
    padding: 0 24px;
  }
}
