/* ベース設定 */
body {
  margin: 0;
  padding: 0;
  font-family: "Yu Gothic", "Meiryo", sans-serif;
  background: url('../images/background.jpg') no-repeat center center fixed;
  background-size: cover;
  background-color: #001f3f; /* fallback dark blue */
  color: #ffffff; /* 完全な白 */
  font-weight: 600; /* 少し太字に */
  text-shadow: 0 0 2px rgba(0,0,0,0.7); /* 黒の影で文字を際立たせる
}

/* バナー部分 */
.banner {
  background-color: rgba(0, 0, 50, 0.8);
  padding: 2em 1em;
  text-align: center;
  border-bottom: 1px solid #3a3a8f;
}

.banner h1 {
  margin: 0 0 0.3em;
  font-size: 2em;
  font-weight: bold;
  color: #fff000;
}

.banner p {
  margin: 0;
  font-size: 1.1em;
  color: #ffffff;
}

/* グループタイトル */
.group > h2 {
  margin: 2em 1em 1em;
  color: #ffffff;
  border-left: 5px solid #3a3a8f;
  padding-left: 0.5em;
  font-weight: 600;
  font-size: 2em;
}

/* グリッドレイアウト */
.container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); /* 180px以上で1fr */
  gap: 1.5em;
  padding: 0 1em 2em;
  max-width: 1200px;
  margin-left: 1em;       /* 左寄せのため余白は左だけ少し空ける */
  justify-content: start; /* グリッドアイテム左寄せ */
}

/* カード */
.card {
  background-color: rgba(0, 0, 50, 0.6);
  border: 1px solid #3a3a8f;
  border-radius: 12px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
  padding: 0.7em;
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

/* アイコン画像 */
.card-icon {
  width: 48px;
  height: 48px;
  object-fit: contain;
  margin-bottom: 0.7em;
  border-radius: 6px;
}

/* 見出し */
.card h3 {
  font-size: 2.0em;
  margin: 0.5em 0;
  color: #ffffff;
}

/* リンク */
.card a {
  color: #90d7ff;
  text-decoration: none;
  font-size: 2em;
  margin-top: auto;
}

.card a:hover {
  text-decoration: underline;
}

/* ホバー効果 */
.card:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 12px rgba(0,0,0,0.5);
  z-index: 10; /* ホバー時の重なりを上に */
}

.link-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: flex-start;
  padding: 1rem;
}

.link-card {
  flex: 0 0 auto;
  width: 300px;
  max-width: 100%;
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  overflow: hidden;
  text-decoration: none;
  color: #003366;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  padding: 1em;
  cursor: pointer;
  box-sizing: border-box;
}

.link-card img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 0.7em;
}

.link-card h3 {
  font-size: 1.2rem;
  margin: 0 0 0.5em;
  font-weight: 600;
}

.link-card p {
  font-size: 1rem;
  margin: 0 0 1em;
  color: #007ACC;
}

.link-card:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

/* レスポンシブ調整（必要に応じて） */
@media (max-width: 600px) {
  .banner h1 {
    font-size: 1.5em;
  }
  .group > h2 {
    font-size: 1.2em;
  }
  .container {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    margin-left: 0.5em;
  }
}