/* ==========================================================
   トップページ(ログイン前)専用のデザイン
   2026-07-07 のデザインモック(トップページ)を移植したもの。
   共通の style.css の後に読み込み、このページだけ上書きする。
   ========================================================== */
:root {
  --gold: #f7a81b;         /* 接点の色(申込ボタンなど) */
  --azure: #0067c8;        /* テキストリンク */
  --hinata-paper: #f8f6f1; /* ひなたの紙色(帯の背景) */
  --top-text: #333333;     /* 本文 */
  --serif: "Hiragino Mincho ProN", "Yu Mincho", "BIZ UDMincho", serif;
}

html { scroll-behavior: smooth; }

body {
  background: #fff;
  color: var(--top-text);
  font-size: 18px;
  line-height: 1.9;
}

a { color: var(--azure); }

.inner { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
section { padding: 52px 0; }

h2 {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--red);
  font-size: 27px;
  line-height: 1.5;
  margin-bottom: 24px;
}
@media (min-width: 768px) {
  h2 { font-size: 33px; }
}

/* --- 金色ボタン(見学申込などの「接点」だけに使う) --- */
.btn-gold {
  display: inline-block;
  background: var(--gold);
  color: var(--red);
  border: 1px solid var(--red);
  font-weight: bold;
  font-size: 19px;
  padding: 13px 32px;
  min-height: 48px;
  border-radius: 6px;
  text-decoration: none;
  text-align: center;
}
.btn-gold:hover { filter: brightness(1.05); }

/* --- 固定ヘッダー --- */
.top-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--red);
  color: #fff;
  padding: 10px 0;
}
.top-header .inner {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.top-header .brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: bold;
  font-size: 20px;
}
.top-header .brand a { color: #fff; text-decoration: none; }
.top-header .brand .logo { height: 44px; width: auto; display: block; }
.top-header nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.top-header nav a {
  color: #fff;
  text-decoration: none;
  font-size: 14px;   /* クラブ名と1列に収めるため小さめ */
  padding: 6px 2px;
  white-space: nowrap;
}
.top-header nav a:hover { text-decoration: underline; }

/* --- スマホ用メニューボタン(ハンバーガー)。PCでは非表示 --- */
.menu-btn {
  display: none;
  margin-left: auto;
  background: none;
  border: none;
  color: #fff;
  font-size: 27px;
  line-height: 1;
  padding: 4px 8px;
  cursor: pointer;
}
@media (max-width: 720px) {
  .menu-btn { display: block; margin-left: 0; flex-shrink: 0; }
  /* クラブ名と☰ボタンを必ず1行に収める:ロゴと文字を少し小さくし、
     クラブ名側が残り幅いっぱいまで使う(入りきらない分は…で省略) */
  .top-header .brand {
    flex: 1;
    min-width: 0;
    gap: 8px;
    font-size: 17px;
  }
  .top-header .brand .logo { height: 34px; }
  .top-header .brand a {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  /* メニューはふだん隠し、ボタンで .menu-open を付けたときだけ
     ヘッダーの下に縦並びで開く(index.js 参照) */
  .top-header nav {
    display: none;
    flex-basis: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 6px 0 4px;
  }
  .top-header.menu-open nav { display: flex; }
  .top-header nav a {
    padding: 12px 4px;
    border-top: 1px solid rgba(255, 255, 255, .25);
  }
}

/* --- ファーストビュー(写真をそのまま表示。グラデーションなし) ---
   aspect-ratio で領域の高さを写真の縦横比(1133x633)に合わせているため、
   スマホでも下に余白(紺の帯)が出ない。max-width は高さが675pxを
   超えないための値(それ以上の広い画面では写真を中央に置く) */
.top-hero {
  max-width: 1208px;
  margin: 0 auto;
  aspect-ratio: 1133 / 633;
  background-image: url("../img/top-photo.png");
  background-size: 100% 100%;
  background-repeat: no-repeat;
  position: relative;
  overflow: hidden;
}

/* 管理者が登録したスライド写真(index.js が生成。横に流れる) */
.top-hero .hero-track {
  position: absolute;
  inset: 0;
  display: flex;
  transition: transform 0.8s ease;
}
.top-hero .hero-slide {
  flex: 0 0 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* --- キャッチコピーの帯(紺地) --- */
.meeting-bar {
  background: var(--red);
  color: #fff;
  padding: 26px 0 30px;
  text-align: center;
}
.meeting-bar .catch {
  font-family: var(--serif);
  font-size: 31px;
  line-height: 1.6;
  letter-spacing: .06em;
  margin: 0;
}
@media (min-width: 768px) {
  .meeting-bar .catch { font-size: 35px; }
}
.meeting-bar .catch-sub {
  font-size: 16px;
  opacity: .92;
  margin-top: 6px;
}

/* --- 数字の帯 --- */
.stats { background: #fff; padding: 44px 0; }
.stats .grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  text-align: center;
}
.stats .num {
  font-family: var(--serif);
  font-size: 31px;
  color: var(--red);
  font-weight: 600;
  line-height: 1.3;
}
.stats .cap { font-size: 16px; color: #555555; }

/* --- リンクボタン(四角い枠。中央寄せ。index.js が生成)。
   上の数字の帯と同じくらいの高さに収める --- */
.link-buttons { padding: 24px 0; background: #e8eefb; }  /* 薄い青の帯 */
.link-buttons .grid {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
}
.link-buttons a { display: block; transition: transform 0.1s; }
.link-buttons a:hover { transform: translateY(-3px); }
.link-buttons img {
  height: 120px;
  width: auto;            /* 横長の画像も切らずに全体を表示する */
  max-width: 336px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(27, 42, 68, .18);
  display: block;
  background: #fff;
}

/* --- クラブ概要 --- */
.about { background: var(--hinata-paper); }

/* --- クラブ概況報告書 ---
   内容のかたまり(文章・添付)を中央に配置する。
   文字の行ぞろえ自体は左のまま(text-align は変えない) */
#overview-section .inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}
#overview-section .inner > * {
  text-align: left;
  /* 内容が横幅いっぱいに広がると中央寄せに見えないため、幅を絞る */
  max-width: 760px;
  width: 100%;
}
#overview-section .inner > h2 {
  align-self: stretch;   /* 見出しは従来どおり左端の位置 */
}

/* --- 会長メッセージ --- */
.president .wrap {
  display: flex;
  gap: 28px;
  align-items: flex-start;   /* 写真を本文の先頭にそろえる */
  flex-wrap: wrap;
}
.president .face {
  width: 225px;
  height: 225px;
  border-radius: 14px;   /* 角丸の四角 */
  object-fit: cover;
  object-position: center top;
  border: 3px solid #fff;
  box-shadow: 0 1px 6px rgba(27, 42, 68, .2);
  flex-shrink: 0;
}
.president .msg { flex: 1; min-width: 260px; }
.president .motto {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  color: var(--red);
  line-height: 1.7;
  margin-bottom: 12px;
}
.president .name { font-weight: bold; margin-top: 10px; }

/* --- 活動報告(サンプル表示) --- */
.top-blog { background: var(--hinata-paper); }
.blog-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 20px;
}
@media (max-width: 720px) {
  .blog-grid { grid-template-columns: 1fr; }
}
.top-blog .blog-card {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(27, 42, 68, .08);
}
.top-blog .thumb { height: 180px; position: relative; }
.top-blog .hero-card .thumb { height: 280px; }
/* 活動報告:添付リンク付きの記事のカード(押すとリンク先が開く) */
.blog-card-link {
  display: block;
  color: inherit;
  text-decoration: none;
  transition: transform 0.1s;
}
.blog-card-link:hover { transform: translateY(-3px); }

/* 活動報告:4件目以降(「過去の活動報告を見る」ボタンで開閉 → index.js) */
.old-reports-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.thumb-a { background: linear-gradient(140deg, #cfe0f5 0%, #9fc0e8 50%, #5d84b8 100%); }
.thumb-b { background: linear-gradient(140deg, #f5e9c8 0%, #e3cf9a 60%, #b39b62 100%); }
.thumb-c { background: linear-gradient(140deg, #d9e8d5 0%, #a8c8a0 60%, #6f9868 100%); }
.top-blog .thumb .ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, .9);
  font-size: 14px;
  text-align: center;
  padding: 10px;
}
.top-blog .blog-card .body { padding: 16px 18px 20px; }
.top-blog .blog-card .date {
  font-family: var(--serif);
  font-size: 23px;
  color: var(--red);
  font-weight: 600;
}
.top-blog .hero-card .date { font-size: 27px; }
.top-blog .blog-card h3 {
  font-size: 18px;
  line-height: 1.6;
  margin-top: 4px;
}
.blog-sub { display: grid; gap: 20px; }

/* --- はじめての方へ(3ステップ+よくある質問) --- */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 28px 0 36px;
}
.step {
  background: var(--hinata-paper);
  border-radius: 8px;
  padding: 22px 18px;
}
.step .no {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  font-weight: bold;
  font-size: 19px;
  margin-bottom: 10px;
}
.step h3 { font-size: 19px; margin-bottom: 6px; color: var(--red); }
.step p { font-size: 17px; line-height: 1.8; }
.faq dt { font-weight: bold; color: var(--red); margin-top: 18px; }
.faq dt::before { content: "Q. "; }
.faq dd::before { content: "A. "; font-weight: bold; color: #8a6d1c; }

/* --- 締めの案内 --- */
.closing { background: var(--hinata-paper); text-align: center; }
.closing .form-note { font-size: 15px; color: #4a5568; margin-top: 14px; }

/* --- フッター(例会・事務局) --- */
.top-footer {
  background: var(--red);
  color: #fff;
  padding: 48px 0 40px;
}
.top-footer .cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
}
.top-footer .cols > div {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.top-footer h3 {
  font-size: 21px;
  letter-spacing: .12em;
  margin-bottom: 12px;
  border-left: 4px solid var(--gold);
  padding-left: 10px;
}
.top-footer p { font-size: 18px; line-height: 1.9; }
.top-footer .tel { font-size: 27px; font-weight: bold; }
.top-footer a { color: #fff; }
.top-footer .btn-map {
  display: inline-block;
  margin-top: 14px;
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .75);
  font-size: 16px;
  font-weight: bold;
  padding: 9px 20px;
  border-radius: 6px;
  text-decoration: none;
}
.top-footer .btn-map:hover { background: rgba(255, 255, 255, .12); }
.top-footer .club-line {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, .25);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  flex-wrap: wrap;
}
.top-footer .club-line p { font-size: 16px; margin: 0; }
.top-footer .links a { color: #cdd9ef; font-size: 16px; }
