/* 1. 基本設定：配色・文字・余白 */
:root {
  --ink: #20383b;
  --muted: #496366;
  --accent: #087873;
  --green: #52782e;
  --pale: #edf7f4;
  --line: #cbded9;
  --width: 1080px;
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: #fff; font-family: system-ui, -apple-system, "Hiragino Sans", "Yu Gothic", Meiryo, sans-serif; font-size: 16px; line-height: 1.85; }
a { color: var(--accent); text-underline-offset: .2em; overflow-wrap: anywhere; }
a:hover { color: var(--green); }
a:focus-visible { outline: 3px solid #a06b00; outline-offset: 4px; }
h1, h2, h3 { line-height: 1.45; margin: 0 0 1rem; }
p { margin: 0 0 1rem; }
.wrap { width: min(var(--width), calc(100% - 2.5rem)); margin-inline: auto; }
.skip { position: absolute; left: 1rem; top: -5rem; background: white; padding: .5rem; z-index: 2; }
.skip:focus { top: 1rem; }
/* 2. ヘッダーとナビゲーション */
header { border-bottom: 1px solid var(--line); }
.header-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; padding-block: 1.2rem; }
.brand { font-weight: 750; color: var(--ink); text-decoration: none; }
.brand-logo { display: block; width: 200px; max-width: 100%; height: auto; object-fit: contain; object-position: left center; pointer-events: none; }
nav ul { display: flex; flex-wrap: wrap; gap: .35rem 1.2rem; list-style: none; padding: 0; margin: 0; }
nav a { font-size: .9rem; text-decoration: none; font-weight: 600; }
/* 3. メインビジュアル：現行サイトの公式背景画像をローカル参照 */
.hero {
  background: #d8efeb url("images/main02.png") center bottom / cover no-repeat;
  border-bottom: 1px solid var(--line);
  padding: clamp(3rem, 8vw, 7rem) 0;
}
.hero-inner { position: relative; text-align: center; }
.hero h1 { font-size: clamp(1.8rem, 4.5vw, 3.35rem); letter-spacing: .025em; }
.hero p { max-width: 44em; margin-inline: auto; }
.hero-inner > p, .hero h1 { text-shadow: 0 1px 5px #e3f5ed; }
.tagline { color: #174c4e; font-weight: 700; font-size: 1.2rem; }
@media (max-width: 760px) {
  .hero { background-size: auto 100%; }
  .hero-inner { background: rgba(255,255,255,.82); padding: 1.2rem; border-radius: 6px; }
}
/* 4. 共通セクションとカード */
.section { padding-block: clamp(2.6rem, 6vw, 5rem); border-bottom: 1px solid var(--line); }
.tinted { background: var(--pale); }
.eyebrow { color: var(--accent); font-size: .82rem; font-weight: 700; letter-spacing: .12em; margin-bottom: .4rem; }
h2 { font-size: clamp(1.5rem, 3vw, 2.15rem); }
h3 { font-size: 1.15rem; }
.lead { max-width: 48em; color: var(--muted); }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.card { padding: 1.4rem; background: #fff; border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: 6px; }
.card p { margin: 0; }
.news { padding: 1.5rem 0; border-bottom: 1px solid var(--line); }
.news .wrap { display: flex; align-items: baseline; gap: 1.2rem; flex-wrap: wrap; }
.news h2 { font-size: .9rem; color: var(--accent); margin: 0; }
.news p { margin: 0; }
.activity-list { padding-left: 1.5rem; max-width: 54em; }
.activity-list li { padding: .6rem 0; border-bottom: 1px solid var(--line); }
/* 5. 役員一覧と会則 */
.people { width: 100%; border-collapse: collapse; margin-bottom: 2rem; text-align: left; }
.people th, .people td { padding: .8rem .7rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.people thead { background: var(--pale); }
.people tbody th { font-weight: 500; }
.rule-content { max-width: 52em; }
.rule-content h3 { border-left: 4px solid var(--accent); padding-left: .75rem; margin-top: 2rem; }
.rule-content h4 { margin-bottom: .5rem; }
.rule-content ul { padding-left: 1.4rem; }
.rule-toc { background: var(--pale); padding: 1.2rem 1.6rem; border-radius: 6px; }
.notice { border-left: 4px solid var(--green); padding: .8rem 1rem; background: #f4f7ec; }
/* 6. フッター */
footer { background: #174c4e; color: white; padding: 2.5rem 0; }
footer a { color: white; }
footer a:hover { color: #d7f0c6; }
footer p:last-child { margin-bottom: 0; }
/* 7. 小さい画面と印刷 */
@media (max-width: 760px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .cards { grid-template-columns: 1fr; } .wrap { width: calc(100% - 2rem); } .people th, .people td { padding: .5rem .25rem; font-size: .88rem; overflow-wrap: anywhere; } .people th:first-child { width: 4.5em; } .people td:nth-child(2) { width: 5.5em; } }
@media print { header, footer, .skip { display: none; } .section, .hero { padding: 1rem 0; background: white; } .card, tr { break-inside: avoid; } .cards { display: block; } }

/* 8. 活動写真・イラスト */
.section-intro, .activities-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 320px); gap: 2rem; align-items: center; }
.community-photo { display: block; width: 100%; height: auto; border-radius: 6px; }
.activities-image { display: block; width: 100%; max-width: 260px; height: auto; border-radius: 6px; justify-self: center; }
@media (max-width: 760px) { .section-intro, .activities-layout { grid-template-columns: 1fr; gap: 1rem; } .community-photo { max-width: 480px; } .activities-image { max-width: 220px; } }

/* 9. 会員一覧・会則 */
.member-list { columns: 3 240px; column-gap: 2rem; padding-left: 1.3rem; }
.member-list li { break-inside: avoid; padding: .2rem 0; }
#member h3 { margin-top: 2rem; border-bottom: 1px solid var(--line); padding-bottom: .5rem; }
.rule-content .clause-list { list-style: none; padding: 0; }
.clause-list li { margin-bottom: .5rem; }
.rule-content h4 { margin-top: 1.5rem; }
@media print { .member-list { columns: 2; } }

/* 会員一覧・会則：見出しの共通設定。背景画像は用途別に指定 */
#member .eyebrow, #regulations .eyebrow { margin: 0; }
#member h2, #regulations h2 { padding: 1.5rem 1rem; border-radius: 6px; }
/* 会則専用画像は未提供のため、暫定的にトップ画像を使用 */
#regulations h2 { background: #d8efeb url("images/main02.png") center / cover no-repeat; }
.rule-content .clause-list li { overflow-wrap: anywhere; }
@media (max-width: 520px) { .member-list { columns: 1; } }

/* 会員限定ページ */
.member-content { max-width: 58rem; overflow-wrap: anywhere; }
.member-content h2, .member-content h3 { margin-top: 2rem; }
.member-content li { margin-block: .4rem; }
.member-content .member-project { padding: 1.25rem; margin: 1rem 0; border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 6px; }
.member-project h2 { font-size: 1.25rem; margin: 0 0 .5rem; }


/* 会員一覧と会員限定ページの公式背景画像（共通） */
#member h2, .member-banner {
  background: #b1d8c8 url("images/member-background.png") left bottom / cover no-repeat;
  text-align: right;
}
#member h2 { padding: clamp(2rem, 6vw, 4rem) 1.5rem; }
.page-banner {
  min-height: clamp(160px, 24vw, 260px);
  padding: clamp(1.25rem, 4vw, 3rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-radius: 6px;
  margin-bottom: 2rem;
}
.page-banner h1 { margin-bottom: 0; font-size: clamp(1.5rem, 3vw, 2.4rem); }
.member-banner { align-items: flex-end; }
.project-banner {
  background: #e7f6ff url("images/pjcommunity.png") center right / cover no-repeat;
  align-items: flex-start;
}
.page-banner h1, .page-banner .eyebrow {
  background: rgba(255,255,255,.92);
  padding: .25rem .65rem;
  border-radius: 4px;
  max-width: 100%;
  overflow-wrap: anywhere;
}
@media (max-width: 600px) {
  .page-banner { min-height: 180px; background-position: center; }
  #member h2 { background-position: center; }
}
@media print { .page-banner, #member h2, #regulations h2 { background: none; min-height: 0; } }

/* 10. プロジェクトコミュニティ詳細・設置申請 */
.project-detail .project-block { margin: 0 0 2rem; }
.project-detail h2 { font-size: 1.35rem; border-bottom: 1px solid var(--line); padding-bottom: .5rem; }
.project-detail h3 { font-size: 1.1rem; border-left: 3px solid var(--accent); padding-left: .65rem; }
.project-detail a { overflow-wrap: anywhere; }
