/* ベースとヘッダーのスタイル（前回と同じ） */
body {
  margin: 0;
  padding: 0;
  font-family: "Hiragino Kaku Gothic ProN", "Meiryo", sans-serif;
  color: #333;
}

.site-header {
  background-color: rgba(255, 255, 255, 0.9);
  padding: 10px 20px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  position: relative;
  z-index: 10;
}

.logo-area {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

.site-logo {
  height: 50px;
  width: auto;
}

.site-title {
  text-align: left;
}

.sub-title {
  font-size: 0.75rem;
  color: #666;
  margin: 0;
}

.site-title h1 {
  font-size: 1.5rem;
  color: #1b5e20;
  margin: 0;
  letter-spacing: 2px;
}

/* メインビジュアル */
.main-visual {
  /* ここに以前の背景画像のパスを入れてください */
  background-image: url('top/img/kose_index_top.jpg'); 
  background-size: cover;
  background-position: center;
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* 上寄せにして、葉っぱの配置スペースを確保 */
  align-items: center;
  padding: 60px 20px;
  position: relative;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  margin-bottom: 60px; /* 見出しと葉っぱの距離 */
}

.hero-content h2 {
  font-size: 2.5rem;
  color: #004d40;
  text-shadow: 2px 2px 5px rgba(255,255,255,1), 0 0 10px rgba(255,255,255,0.8); /* 白抜き風にして読みやすく */
}

/* 葉っぱのメニュー全体の枠組み */
.leaf-menu {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  max-width: 1000px;
  width: 100%;
}

/* いただいた葉っぱの画像を使うデザイン */
.leaf {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 140px; /* 画像に合わせてサイズを調整 */
  height: 140px;
  /* 画像を背景に設定 */
  background-image: url('leaf_01.gif');
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  /* 背景色は消す */
  background-color: transparent;
  box-shadow: none;
  border-radius: 0;
  
  color: #fff;
  font-weight: bold;
  font-size: 0.9rem;
  text-align: center;
  text-decoration: none;
  line-height: 1.3;
  transition: transform 0.3s ease;
  
  /* 葉っぱの根元（左下）を軸にして揺らす */
  transform-origin: 20% 80%; 
  /* 新しいそよ風アニメーション */
  animation: natural-breeze 6s ease-in-out infinite;
}

/* 文字に影をつけて、葉っぱの模様に負けないようにする */
.leaf span {
  display: inline-block;
  transform: rotate(-15deg); /* 画像の傾きに合わせて文字を調整 */
  text-shadow: 1px 1px 3px rgba(0,0,0,0.8), -1px -1px 3px rgba(0,0,0,0.8);
  padding-bottom: 10px;
  padding-right: 15px;
}

/* マウスを乗せた時の動き（ふわっと浮く） */
.leaf:hover {
  animation-play-state: paused;
  transform: scale(1.1) translateY(-10px) !important;
  z-index: 10;
}

/* 配置のバランスをジグザグにする（高さを互い違いにする） */
.leaf-1 { margin-top: 40px; animation-delay: 0s; }
.leaf-2 { margin-top: -20px; animation-delay: 1.2s; }
.leaf-3 { margin-top: 50px; animation-delay: 2.4s; }
.leaf-4 { margin-top: -10px; animation-delay: 0.8s; }
.leaf-5 { margin-top: 60px; animation-delay: 3.5s; }
.leaf-6 { margin-top: 20px; animation-delay: 1.8s; }

/* よりリアルなそよ風のアニメーション（サワサワと鳴るような強弱） */
@keyframes natural-breeze {
  0% { transform: rotate(0deg); }
  10% { transform: rotate(12deg); }   /* 風が吹いて大きく傾く */
  20% { transform: rotate(-2deg); }   /* 戻る */
  30% { transform: rotate(8deg); }    /* 余韻で揺れる */
  40% { transform: rotate(2deg); }    /* 小刻みに揺れる */
  50% { transform: rotate(5deg); }
  60% { transform: rotate(0deg); }    /* 落ち着く */
  100% { transform: rotate(0deg); }   /* 次の風を待つ */
}

/* フッター */
.site-footer {
  text-align: center;
  padding: 20px;
  background-color: #2e7d32;
  color: white;
}

/* スマホ用のレイアウト調整 */
@media screen and (max-width: 768px) {
  .leaf {
    width: 110px;
    height: 110px;
    font-size: 0.75rem;
  }
  .leaf-menu {
    gap: 5px;
  }
  /* スマホの時はジグザグの幅を少し小さくする */
  .leaf-1 { margin-top: 20px; }
  .leaf-2 { margin-top: 0px; }
  .leaf-3 { margin-top: 20px; }
  .leaf-4 { margin-top: 0px; }
  .leaf-5 { margin-top: 20px; }
  .leaf-6 { margin-top: 0px; }
}