/*
Theme Name: My Original Theme
Theme URI: http://example.com/
Author: あなたの名前
Author URI: http://example.com/
Description: 最初のオリジナルテーマ
Version: 1.0
*/


/* style.css の一番上に追記 */
@import url('https://fonts.googleapis.com/css2?family=M+PLUS+1p:wght@500;800&family=Mochiy+Pop+One&display=swap');

/* ===============================
   基本のレスポンシブ調整(スマホ用に調整) 
   =============================== */

body.home {
  background: url('img/background.png') repeat;
  background-size: cover;
  background-attachment: scroll; /* fixed ではなく scroll にする */
}
   
/* 横スクロール防止 & 基本のbox-sizing */
html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

/* 画像・動画を親要素にフィットさせる */
img{
  max-width: 100%;
  height: auto;
  display: block;
}

/* セクション全体に余白を確保 */
section {
  padding: 40px 20px;
}

/* スマホ時のフォントサイズ調整 */
@media (max-width: 600px) {
  body {
    font-size: 1rem;
  }
  h2 {
    font-size: 1.8rem;
  }
}


/* 全体に適用 */
body {
  font-family: "M PLUS 1p", sans-serif;
  font-size: 1.3rem;
  padding-top: 60px; /* ヘッダーの高さ分だけ空ける */
  font-weight: 500;

}

/* フロントページだけ背景適用 */
body.home {
  background: url('img/background.png') repeat;
    background-attachment: fixed; /* 背景を固定 */
  background-size: cover;
}


/*見出しサイズ*/
h2 {

  font-family: "M PLUS 1p", sans-serif;

  font-size: 3.5rem;
  /* ← 好みで数字を調整すればいい */
  text-align: center;
  /* ← 中央揃え */
  margin: 40px 0;
  /* ← 上下の余白（必要に応じて） */
  font-weight: 800;
  /* ← 太字（好みで） */
}

.ndccolor {
  color: rgb(0, 153, 255);
  /* 好きな色でOK */
}

.ndctext {
  width: 900px;
  /* 好きな幅でOK */
  margin: 0 auto;
  /* ボックス自体を中央に配置！ */
  text-align: left;
  /* 中の文章は左揃え！ */
  padding-left: 200px;
  line-height: 2;
  font-size: 1.3rem;
}

/*要素揺らす*/
@keyframes shake {
  0% {
    transform: translate(0);
  }

  25% {
    transform: translate(2px, 0);
  }

  50% {
    transform: translate(-2px, 0);
  }

  75% {
    transform: translate(2px, 0);
  }

  100% {
    transform: translate(0);
  }
}

.shake-on-hover:hover{
  animation: shake 0.3s ease-in-out;
}




/*===============================
ページトップの余白
=================================*/
.empty-space {
  width: 100%;
  height: 100vh;
  /* ← 画面1枚分の高さ */
}


/*トップキャラ画像*/

.top-overlay {
   position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-width: 80vw;   /* 画面幅の80%以内 */
  max-height: 80vh;  /* 画面高さの80%以内 */
  width: auto;
  height: auto;
  opacity: 0;
  transition: opacity 1s ease;
  z-index: 2;
}

.top-overlay img {
  max-width: 50vw;
  max-height: 50vh;
  width: auto;
  height: auto;
  display: block;
  margin: 0 auto;
}

.topbackground-image {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;   /* ← 100vwを100%に変更 */
    height: 100dvh; /* ← dynamic viewport height */
  object-fit: cover;
  z-index: -5;
  transition: opacity 0.5s ease-in-out;
  overflow: hidden;
}

.top-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -200%);
  font-size: 5rem;
  color: white;
  opacity: 0;
  transition: opacity 0.8s ease;
  z-index: -3;
  font-family: "Mochiy Pop One", sans-serif;
  white-space: nowrap; /* ←これで改行禁止 */

   /* 太め＆くっきり縁取り */
  -webkit-text-stroke: 2px black; /* くっきり太い黒縁 */
  text-shadow:
    0 0 2px #000,
    1px 1px 1px #000,
   -1px -1px 1px #000;
}

.top-text.up {
  animation: floatUp 1s ease forwards;
}

/* PC用 */
@keyframes floatUp-pc {
  from { transform: translate(-50%, -200%); }
  to   { transform: translate(-140%, -40vh); }
}

/* スマホ用 */
@keyframes floatUp-sp {
  from { transform: translate(-50%, -50%); }
  to   { transform: translate(-50%, -30vh); }
}

/* デフォルトはPC用 */
.top-text.up {
  animation: floatUp-pc 1s ease forwards;
}

/* スマホだけ切り替え */
@media (max-width: 600px) {
  .top-text.up {
    margin: 0; 
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%); /* ←これで上下左右中央 */
    color: white;
    opacity: 0;
    transition: opacity 0.8s ease;
    z-index: -3;
    font-family: "Mochiy Pop One", sans-serif;

    animation: floatUp-sp 1s ease forwards;
    text-align: center; /* 複数行でも中央寄せ */
     white-space: nowrap; /* ←これで改行禁止 */
  }
}

.top-text2 {
   font-size: 6rem;
  position: absolute;
  top: 50%; 
  left: 50%;
  color: #000;
  font-weight: bold;
  opacity: 0;
  transition: opacity 0.8s ease, transform 1s ease;
  z-index: 2;
  font-family: "Mochiy Pop One", sans-serif;
  white-space: nowrap;
  transform: translate(-300%, 50%) rotate(-10deg); /* 初期位置（PC） */
}

/* アニメーションON時（デフォルトはPC） */
.top-text2.slide {
  animation: floatSlide2-pc 1s ease forwards;
}

/* PC用アニメーション */
@keyframes floatSlide2-pc {
  from { transform: translate(-300%, 50%) rotate(-10deg); opacity: 0; }
  to   { transform: translate(-10%, 20%) rotate(-10deg); opacity: 1; }
}

/* スマホ用アニメーション */
@keyframes floatSlide2-sp {
  from { transform: translate(-300%, 300%) rotate(-10deg); opacity: 0; }
  to   { transform: translate(-50%, 160%) rotate(-10deg); opacity: 1; }
}

@media (max-width: 600px) {
  .top-text2 {
     font-size: clamp(2rem, 10vw, 5rem);
    transform: translate(-300%, 300%) rotate(-10deg);
  }

  .top-text2.slide {
    font-size: clamp(2rem, 10vw, 5rem);
    animation: floatSlide2-sp 1s ease forwards;
  }
}


/* トップ画像 */
.top-image {
  position: absolute;
  top: 37%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-width: 160vw;
  max-height: 160vh;
  width: auto;
  height: auto;
  opacity: 0;
  transition: opacity 1s ease;
  z-index: -1;
}

@media (max-width: 600px) {
  .top-image {
    top: 45%;
    max-width: 90vw;
    max-height: 50vh;
  }
}

/*===============================
お知らせ掲載用スクロールボックス
=================================*/
.box-title {
  text-align: center;
  margin-top: 0;
  margin-bottom: 10px;
  font-size: 24px;
  font-weight: bold;
  color: #222;
  border-bottom: 2px solid #000;
  padding-bottom: 5px;
}

.box-container {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
  flex-wrap: wrap;
}


.news-box,
.side-box {
  width: 30vw;
  /* 画面幅の45% */
  height: 30vh;
  /* 画面高さの30% */
  border: 2px solid #ddd;
  border-radius: 8px;
  padding: 20px;
  overflow-y: auto;
  background-color: #f9f9f9;

  -ms-overflow-style: none;
  /* Internet Explorer/Edge 用 */
  scrollbar-width: none;
  /* Firefox 用 */
}

.news-box::-webkit-scrollbar {
  display: none;
  /* Chrome, Safari 用 */
}

/* お知らせリスト */
/* リンク全体 */
.news-list li a {
  display: flex;                     /* 日付とタイトルを横並び */
  gap: 1em;                           /* 間隔をあける */
  padding: 10px 15px;
  text-decoration: none;              /* 下線を消す */
  color: #00a2ff;
  border-bottom: 1px solid #ddd;      /* 区切り線 */
  transition: background 0.3s, color 0.3s;
}

/* ホバー時の装飾 */
.news-list li a:hover {
  background: #f5f5f5;
  color: #0095da; /* WordPressっぽい青 */
}

/* 日付 */
.news-list .news-date {
  font-size: 0.9rem;
  color: #999;
  min-width: 6em;     /* 幅を固定して整列 */
}

/* タイトル */
.news-list .news-title {
  font-weight: bold;
  font-size: 1.3rem;
}

/* ボタン */
.news-btn,
.side-btn {
  width: 20vw;               /* 横幅を30%にする */
  display: block;            /* ブロック要素化 */
  margin: 16px auto 0;       /* 左右をautoにして中央寄せ */
  padding: 10px 20px;
  background: #ff41df;
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  font-weight: bold;
  transition: background 0.2s;
  text-align: center;
}

.news-btn:hover,
.side-btn:hover {
  background: #ff81ea;
}


/* スマホ：縦1列に変更 */
@media (max-width: 600px) {
  .box-container {
    flex-direction: column;  /* 縦並びに切り替え */
    align-items: center;     /* 中央寄せ */
    gap: 16px;               /* 各ボックスの間隔を確保 */
    padding: 0 10px;         /* 画面端に少し余白をつける */
  }

  .news-box,
  .side-box {
    width: 90vw;             /* 画面幅の90%にして余白を少し残す */
    max-width: 500px;        /* タブレットでも広がりすぎないように制御 */
    height: auto;            /* 高さは中身に合わせる */
    max-height: none;        /* スマホは基本スクロールに任せる */
  }

  .news-btn,
  .side-btn {
    width: 70vw;             /* ボタンも幅広めに */
    margin: 12px auto;       /* 中央寄せ */
  }
}



/*===============================
画像のアニメーション
================================*/
.fade-img {
  opacity: 0;
  transform: translateY(40px) translateX(-50px) scale(0.7);
  transition: all 0.5s ease-out;
}

/* 表示されたときに発動 */
.fade-img.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/*リンク先のある画像*/
.url-img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}


.scroll-image-inner {
  background: rgba(0, 0, 0, 0.4);
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  max-width: 800px;
  font-size: clamp(1rem, 2.5vw, 1.2rem);
}


/*===============================
スライドインする区切りバー
================================*/
.multi-bar-group {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  margin: 200px 0;
  /* gap: 40px; 削除 */
}

.slide-bar-wrapper {
  position: relative;
  height: 10px;
  overflow: hidden;
  width: 100%;
  max-width: none;
  margin: 0;
  /* 余白なし */
}

.slide-bar-bg {
  position: absolute;
  height: 100%;
  width: 100%;
  background-color: #333;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1s ease-out;
  z-index: 1;
}

.slide-bar-text {
  position: relative;
  color: #fff;
  font-size: 24px;
  z-index: 2;
  display: block;
  width: fit-content;
  margin: 0 auto;
  padding-top: 20px;
}

.slide-bar-wrapper.visible .slide-bar-bg {
  transform: scaleX(1);
}

.middle-text {
  background-color: #fff;
  padding: 20px 40px;
  color: #333;
  font-size: 18px;
  max-width: 100vw;
  box-sizing: border-box;
  text-align: center;
  margin: 0;
  /* 余白なし */
  border-radius: 0;
  /* 角丸なし */
  box-shadow: none;
  /* 影なし */

   display: flex;
  align-items: center;
  gap: 20px; /* 画像とテキストの間の余白 */
}


.rotating-image {
  animation: spin 20s linear infinite;
  border-radius: 10px;
  width: 100%;    /* 親の30%の幅 */
  height: auto;  /* 比率そのまま */
  max-width: 500px;  /* 最大サイズの上限 */
}

/* 回転アニメーション */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(-360deg);
  }
}


.member-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* PCで4列 */
  gap: 20px;
  margin-top: 20px;
}

.member-item {
  text-align: center;
}

.member-image {
  width: 100%;
  max-width: 500px;
  height: auto;
  border-radius: 10px;
}

.member-name {
  margin-top: 10px;
  font-size: 1.2rem;
  font-weight: bold;
  color: #333;
}

/* タブレット (2列) */
@media (max-width: 1024px) {
  .member-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* スマホ (1列) */
@media (max-width: 600px) {
  .member-grid {
    grid-template-columns: 1fr;
  }
}


.calendar-small {
   transform: scale(0.7);       /* 縮小率（縦横まとめて） */
  transform-origin: top center; /* 上中央を基準に縮小 */
}




/* ===============================
 スマホ用（幅600px以下）
=============================== */
@media (max-width: 600px) {

  body {
    font-size: 1rem; /* 全体の文字サイズ少し小さめ */
  }

  h2 {
    font-size: 1.8rem;  /* 見出し縮小 */
    margin: 20px 0;     /* 上下余白も少なめ */
  }

  .ndctext {
    width: 90%;          /* 横幅を広く（はみ出さないように） */
    padding-left: 10px;  /* 左の余白も少なめ */
    font-size: 1rem;
  }

  .top-text {
    font-size: 2rem; /* NDCサークルの文字をスマホサイズに */
  }

  .top-text2 {
    font-size: 1.5rem; /* このサークルめっちゃええねん！の文字 */
  }

  .box-title {
    font-size: 18px; /* ボックスの見出し */
  }

  .news-list li {
    font-size: 14px; /* お知らせリスト */
  }

  .middle-text {
    flex-direction: column; /* 画像とテキストを縦並び */
    gap: 10px;
    font-size: 0.9rem;
    padding: 10px;
  }

  .rotating-image {
    max-width: 200px; /* ロゴ縮小 */
  }

  .member-name {
    font-size: 1rem; /* メンバー名＆説明文を少し小さめ */
  }

  .calendar-small {
    transform: scale(0.9); /* カレンダーを少し縮小 */
  }
}
.ndctext p {
  white-space: pre-line; /* HTML の改行や <br> をそのまま反映 */
}


/*スクロールでズーム演出*/
.scroll-zoom {
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.scroll-zoom.show,
.member-item.show {
  opacity: 1;
  transform: scale(1);
}

/*スケジュール*/
.schedule {
  width: 90%;
  max-width: 900px;
  margin: 0 auto;
}

.event-box, .month-box {
  background: #f7f7f7;
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 30px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.event-list li, .schedule-list li {
  margin-bottom: 10px;
}


/* ニュースリスト全体 */
.event-list {
  list-style: none;     /* 先頭の点を消す */
  padding: 0;
  margin: 0;
}

.event-list li a {
 display: flex;                     /* 日付とタイトルを横並び */
  gap: 1em;                           /* 間隔をあける */
  padding: 10px 15px;
  text-decoration: none;              /* 下線を消す */
  color: #00a2ff;
  border-bottom: 1px solid #ddd;      /* 区切り線 */
  transition: background 0.3s, color 0.3s;
}
.event-list li a:hover {
   background: #f5f5f5;
  color: #0095da; /* WordPressっぽい青 */
}
