@charset "UTF-8";

/* ===== 基本設定 ===== */
:root {
    --primary-color: #2f6b33; /* 陽の当たる山林の緑（信頼・伝統） */
    --secondary-color: #6e8e5c; /* 杉・ヒノキの葉の緑（枠線・装飾用） */
    --secondary-text: #5c774d;  /* 上と同系色で、文字に使ってもコントラスト比 4.5 以上を満たす濃さ */
    --muted-text: #647184;      /* 注釈・補足の灰色 */
    --accent-color: #ab5f2c;  /* 美作材の温かみのある木肌色 */
    --text-color: #2c3e50;
    --bg-light: #f7faf4;      /* 木漏れ日をイメージした薄い緑白 */
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', sans-serif; line-height: 1.8; color: var(--text-color); background-color: #ffffff; }
.container { width: 90%; max-width: 1100px; margin: 0 auto; }

/* 電話番号などを途中で折り返さないための共通クラス */
.nowrap { white-space: nowrap; }

/* ページ内リンクの飛び先が、上に固定されたヘッダーの下に隠れないようにします。
   ヘッダーの高さ（パソコン約129px）より少し大きい値にしています */
[id] { scroll-margin-top: 145px; }

/* 飛んだ先がひと目で分かるように、その場所を一時的に色付けします */
.news-item:target { background: #fdf9ee; box-shadow: -6px 0 0 var(--accent-color); padding-left: 14px; }
.map-card:target { background: #fdf9ee; box-shadow: 0 0 0 3px var(--accent-color); }

/* 画面が動いたことが分かるよう、なめらかに移動します。
   （動きを減らす設定にしている方の環境では、従来どおり瞬時に移動します） */
@media (prefers-reduced-motion: no-preference) {
    html { scroll-behavior: smooth; }
}

/* ===== ヘッダー ===== */
header { background: linear-gradient(120deg, #ffffff 0%, #eaf3e6 100%); box-shadow: 0 2px 4px rgba(0,0,0,0.05); position: sticky; top: 0; z-index: 100; }
header .container { display: flex; justify-content: space-between; align-items: center; padding: 15px 0; flex-wrap: wrap; row-gap: 10px; }
.logo { font-size: 27px; font-weight: bold; color: var(--primary-color); display: flex; align-items: center; gap: 8px; text-decoration: none; flex-shrink: 0; }
.logo-mark { height: 60px; width: auto; display: block; }
.logo span { font-size: 14px; font-weight: normal; color: #666; display: block; white-space: nowrap; margin-left: 8px; }
nav ul { display: flex; list-style: none; flex-wrap: wrap; justify-content: flex-end; row-gap: 6px; }
nav ul li { margin-left: 22px; }
nav ul li a { text-decoration: none; color: var(--text-color); font-weight: 600; font-size: 15px; transition: color 0.2s; padding-bottom: 4px; white-space: nowrap; }
nav ul li a:hover { color: var(--secondary-text); }
/* 現在表示中のページを示す（各ページで該当リンクに class="current" を付与） */
nav ul li a.current { color: var(--primary-color); border-bottom: 2px solid var(--accent-color); }
/* スマホ用のメニューボタン。パソコン幅では使いません */
.nav-toggle { display: none; }

/* ===== メインビジュアル（トップページ） ===== */
.hero {
    background: url('../images/hero.jpg') no-repeat center center/cover;
    background-color: var(--primary-color);
    color: #ffffff;
    padding: 150px 0;
    text-align: center;
}
/* 背景を明るくしたぶん、白文字の可読性は影を強めて確保する */
.hero h1 { font-size: 42px; margin-bottom: 20px; text-shadow: 0 2px 14px rgba(0,0,0,0.55); letter-spacing: 3px; font-weight: 700; }
.hero p { font-size: 20px; margin-bottom: 35px; text-shadow: 0 1px 8px rgba(0,0,0,0.55); font-weight: 300; }

/* ===== ページヘッダー（下層ページ） ===== */
.page-header {
    background: url('../images/hero.jpg') no-repeat center center/cover;
    background-color: var(--primary-color);
    color: #ffffff;
    padding: 60px 0;
    text-align: center;
    position: relative;
}
/* 写真の明るい部分に白文字が載ると読みにくくなるため、黒を薄く重ねます。
   ページごとの背景写真は .ph-* で background-image だけを差し替えているので、
   重ねる黒は背景ではなく擬似要素で乗せています（差し替えても消えません） */
.page-header::before {
    content: '';
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    background: rgba(0, 0, 0, 0.3);
}
.page-header .container { position: relative; }
.page-header h1 { font-size: 32px; letter-spacing: 2px; text-shadow: 0 2px 12px rgba(0,0,0,0.55); }
/* 小さい英字は影が効きにくいので、こちらにも影を付けます */
.page-header p { font-size: 14px; color: #e6efe3; letter-spacing: 2px; margin-top: 6px; text-transform: uppercase; text-shadow: 0 1px 6px rgba(0,0,0,0.6); }

/* ページごとのヘッダー背景（images/ の画像を差し替えるだけで切り替わります） */
.page-header.ph-services { background-image: url('../images/header-services.jpg'); }
.page-header.ph-owners   { background-image: url('../images/header-owners.jpg'); }
.page-header.ph-recruit  { background-image: url('../images/header-recruit.jpg'); }
.page-header.ph-about    { background-image: url('../images/header-about.jpg'); }
.page-header.ph-news     { background-image: url('../images/header-news.jpg'); }
.page-header.ph-members  { background-image: url('../images/header-members.jpg'); }
.page-header.ph-contact  { background-image: url('../images/header-contact.jpg'); }
.page-header.ph-privacy  { background-image: url('../images/header-privacy.jpg'); }
.page-header.ph-faq      { background-image: url('../images/header-faq.jpg'); }
.page-header.ph-maki     { background-image: url('../images/header-maki.jpg'); }
.page-header.ph-link     { background-image: url('../images/header-about.jpg'); }

/* パンくずリスト */
.breadcrumb { background: var(--bg-light); padding: 12px 0; font-size: 13px; color: var(--muted-text); border-bottom: 1px solid #e2e8f0; }
.breadcrumb a { color: var(--secondary-text); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* ===== ボタン ===== */
.btn { display: inline-block; background: var(--accent-color); color: white; padding: 14px 40px; text-decoration: none; border-radius: 4px; font-weight: bold; box-shadow: 0 4px 6px rgba(0,0,0,0.1); transition: all 0.3s; }
.btn:hover { background: #8f5124; transform: translateY(-2px); }
.btn-outline { background: transparent; border: 2px solid var(--primary-color); color: var(--primary-color); box-shadow: none; }
.btn-outline:hover { background: var(--primary-color); color: #fff; }
button.btn { border: none; cursor: pointer; font-size: 16px; font-family: inherit; }

/* ===== お問い合わせフォーム ===== */
.contact-form { max-width: 680px; margin: 0 auto; text-align: left; }
.form-group { margin-bottom: 24px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 8px; color: var(--text-color); }
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid #ccd5c9;
    border-radius: 4px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text-color);
    background: #fff;
}
.form-group textarea { resize: vertical; }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(110, 142, 92, 0.15);
}
.form-required, .form-optional { display: inline-block; font-size: 11px; font-weight: bold; padding: 2px 7px; border-radius: 3px; margin-left: 6px; vertical-align: middle; }
.form-required { background: #c0392b; color: #fff; }
.form-optional { background: #6a7483; color: #fff; }
.form-checkbox label { display: flex; align-items: flex-start; gap: 8px; font-weight: normal; }
.form-checkbox input[type="checkbox"] { width: auto; margin-top: 4px; }

/* ===== 各セクション共通 ===== */
section { padding: 90px 0; }
section h2 { text-align: center; font-size: 30px; color: var(--primary-color); margin-bottom: 15px; letter-spacing: 1px; }
section h2::after { content: '◆'; display: block; font-size: 12px; color: var(--secondary-color); margin-top: 8px; }
.section-lead { text-align: center; font-size: 16px; color: #4a5568; margin-bottom: 45px; }
.text-center { text-align: center; }
.mt-30 { margin-top: 30px; }
.mt-45 { margin-top: 45px; }

/* ===== 新着情報 ===== */
.news-list { max-width: 850px; margin: 0 auto; list-style: none; }
.news-item { display: flex; padding: 18px 0; border-bottom: 1px solid #e2e8f0; align-items: center; }
.news-date { width: 175px; color: var(--muted-text); font-weight: bold; font-size: 15px; white-space: nowrap; }
.news-category { background: #5f7b50; color: white; padding: 3px 10px; border-radius: 3px; font-size: 11px; margin-right: 20px; font-weight: bold; white-space: nowrap; }
.news-title { flex: 1; text-decoration: none; color: var(--text-color); font-size: 16px; }
a.news-title:hover { color: var(--primary-color); text-decoration: underline; }
/* 本文つきのお知らせ。日付・カテゴリは1行目の高さに揃えます */
.news-item.has-body { align-items: flex-start; }
.news-body { flex: 1; }
.news-body .news-title { display: block; font-weight: bold; }
.news-text { font-size: 14px; color: #4a5568; line-height: 1.9; margin-top: 10px; }
.news-text + .news-text { margin-top: 12px; }
/* 本文中のリンク。ブラウザ既定の青ではなく、サイトの緑（.doc a と同じ）にそろえます */
.news-text a { color: var(--secondary-text); }
/* お知らせ本文の中に置くダウンロードボタン */
.news-dl { margin: 16px 0 6px; }
/* お知らせ本文に載せるチラシ画像。クリックでPDFが開きます */
.news-figs { display: flex; gap: 16px; flex-wrap: wrap; margin: 14px 0 4px; }
.news-figs a { flex: 1 1 200px; max-width: 300px; text-decoration: none; color: var(--muted-text); }
.news-figs img { width: 100%; height: auto; display: block; border: 1px solid #e2e8f0; border-radius: 4px; background: #fff; }
.news-figs a:hover img { border-color: var(--secondary-color); }
.news-figs span { display: block; font-size: 12px; text-align: center; margin-top: 6px; }
.news-figs a:hover span { color: var(--secondary-text); text-decoration: underline; }
.more-link { text-align: center; margin-top: 40px; }

/* ===== カード（事業内容など） ===== */
.services { background: var(--bg-light); }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 30px; }
.card { background: white; padding: 35px; border-radius: 8px; box-shadow: 0 4px 15px rgba(0,0,0,0.03); border-top: 5px solid var(--primary-color); overflow: hidden; }
.card h3 { margin-bottom: 15px; color: var(--primary-color); font-size: 21px; display: flex; align-items: center; gap: 8px; }
.card p { font-size: 15px; color: #4a5568; text-align: justify; }
/* カード上端いっぱいに入るサムネイル画像（padding を打ち消して全幅にする） */
.card-thumb { display: block; width: calc(100% + 70px); height: 190px; object-fit: cover; margin: -35px -35px 22px; background: var(--bg-light); }
/* トップページのメニューカード（各ページへの入口） */
.card-link { display: block; text-decoration: none; color: inherit; transition: all 0.3s; }
.card-link:hover { transform: translateY(-4px); box-shadow: 0 8px 25px rgba(0,0,0,0.08); }
.card-link .read-more, .card .read-more { display: block; margin-top: 15px; color: var(--accent-color); font-weight: bold; font-size: 14px; text-decoration: none; }
.card .read-more:hover { text-decoration: underline; }

/* ===== 画像＋文章の2カラムブロック ===== */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 45px; align-items: center; max-width: 1000px; margin: 0 auto 55px; }
.feature img { width: 100%; height: 100%; max-height: 340px; object-fit: cover; border-radius: 8px; display: block; box-shadow: 0 6px 20px rgba(0,0,0,0.08); background: var(--bg-light); }
.feature-body h3 { color: var(--primary-color); font-size: 22px; margin-bottom: 14px; }
.icon-sickle { vertical-align: -4px; }
.feature-body p { font-size: 15px; color: #4a5568; text-align: justify; }
/* 画像を右側に置きたいときは .feature に .feature-reverse を追加 */
.feature-reverse .feature-figure { order: 2; }

/* ===== 単体の写真（キャプション付き） ===== */

/* ===== 施業の流れ（STEP） ===== */
.flow-list { max-width: 800px; margin: 0 auto; list-style: none; counter-reset: step; }
.flow-item { position: relative; padding: 0 0 35px 70px; border-left: 2px solid #d8e0d5; margin-left: 24px; }
.flow-item:last-child { border-left-color: transparent; padding-bottom: 0; }
.flow-item::before {
    counter-increment: step; content: 'STEP\A' counter(step); white-space: pre;
    position: absolute; left: -25px; top: 0; width: 48px; height: 48px;
    background: var(--primary-color); color: #fff; border-radius: 50%;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    font-size: 9px; font-weight: bold; line-height: 1.3; letter-spacing: 0.5px;
}
.flow-item h3 { color: var(--primary-color); font-size: 19px; margin-bottom: 8px; }
.flow-item p { font-size: 15px; color: #4a5568; }

/* ===== 組合員のご案内 ===== */
.members { background: var(--bg-light); }
.member-card { background: white; padding: 30px; border-radius: 8px; box-shadow: 0 4px 15px rgba(0,0,0,0.03); border-left: 5px solid var(--secondary-color); }
.member-card h3 { color: var(--primary-color); font-size: 20px; margin-bottom: 12px; }
.member-card ul { margin-left: 20px; font-size: 15px; color: #4a5568; }
.member-card li { margin-bottom: 6px; }

/* ===== 様式ダウンロード ===== */
.dl-group { background: #fff; border-radius: 8px; box-shadow: 0 4px 15px rgba(0,0,0,0.03); border-left: 5px solid var(--secondary-color); padding: 26px 30px; }
.dl-group h3 { color: var(--primary-color); font-size: 19px; margin-bottom: 6px; }
.dl-group .dl-note { font-size: 14px; color: #4a5568; margin-bottom: 16px; }
.dl-list { list-style: none; }
.dl-list li { border-top: 1px dashed #e2e8f0; padding: 14px 4px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.dl-list li:first-child { border-top: none; }
.dl-name { flex: 1 1 180px; font-size: 15px; font-weight: 600; color: var(--text-color); }
.dl-actions { flex-shrink: 0; display: flex; gap: 8px; }
.dl-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 110px; padding: 9px 16px; border-radius: 4px; text-decoration: none; font-size: 13px; font-weight: bold; letter-spacing: 0.5px; border: 1px solid transparent; transition: opacity 0.2s; }
.dl-btn:hover { opacity: 0.82; }
.dl-pdf { background: #b3392f; color: #fff; }
.dl-size { font-weight: normal; font-size: 11px; opacity: 0.85; }
.dl-footnote { font-size: 13px; color: #4a5568; text-align: center; margin-top: 30px; }

/* ===== 組合案内テーブル ===== */
.company-table { width: 100%; border-collapse: collapse; margin-top: 20px; background: white; box-shadow: 0 2px 5px rgba(0,0,0,0.02); }
.company-table th, .company-table td { padding: 18px; border-bottom: 1px solid #e2e8f0; text-align: left; vertical-align: top; }
.company-table th { width: 23%; color: var(--primary-color); background: var(--bg-light); font-weight: bold; }

/* 組合概要：本所の写真を背景に透過表示 */
.company-overview { background: linear-gradient(rgba(255,255,255,0.72), rgba(255,255,255,0.72)), url('../images/about-honjo-bg.jpg') no-repeat center center/cover; }
.company-overview .company-table, .company-overview .company-table th { background: rgba(255,255,255,0.8); }

/* 支所情報用サブテーブル */
.branch-table { width: 100%; border-collapse: collapse; margin-top: 5px; }
.branch-table tr:last-child td, .branch-table tr:last-child th { border-bottom: none; }
.branch-table td, .branch-table th { padding: 10px 5px; font-size: 15px; border-bottom: 1px dashed #e2e8f0; text-align: left; }
/* この表は .company-table のセルの中に入れ子で置いているため、
   親の「.company-table th」の背景色と列幅がそのまま効いてしまいます。ここで打ち消します */
.branch-table th { background: none; width: 190px; }
.branch-name { font-weight: bold; color: var(--primary-color); width: 190px; white-space: nowrap; }
.branch-table a { color: var(--text-color); text-decoration: none; }
.branch-table a:hover { color: var(--primary-color); text-decoration: underline; }
.branch-map-link { font-size: 12px; font-weight: normal; color: var(--secondary-text) !important; margin-left: 4px; white-space: nowrap; }
.branch-map-link:hover { color: var(--primary-color) !important; }

/* ===== アクセスマップ ===== */
/* min() を挟まないと、画面が330pxより狭いときに横スクロールが出ます（文字を大きくした時も同じ） */
.map-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(330px, 100%), 1fr)); gap: 30px; }
.map-card { background: white; border-radius: 8px; overflow: hidden; box-shadow: 0 4px 15px rgba(0,0,0,0.05); border-top: 5px solid var(--primary-color); }
.map-card .map-body { padding: 22px 25px 25px; }
.map-card h3 { color: var(--primary-color); font-size: 19px; margin-bottom: 8px; }
.map-card p { font-size: 15px; color: #4a5568; margin-bottom: 4px; }
.map-card .map-tel { font-weight: bold; }
.map-card .map-tel a { color: var(--accent-color); text-decoration: none; }
.map-card .map-tel a:hover { text-decoration: underline; }
.map-card .map-link { display: inline-block; margin-top: 12px; font-size: 14px; color: var(--secondary-text); text-decoration: none; font-weight: bold; }
.map-card .map-link:hover { text-decoration: underline; }

/* アクセスマップ内の小見出し（本所・支所／主要施設 の区切り） */
.sub-heading {
    font-size: 20px; color: var(--primary-color); text-align: center;
    margin: 0 0 25px; padding-bottom: 10px;
    border-bottom: 2px solid #d8e0d5;
}
.sub-heading + .map-grid, .sub-heading + .map-solo { margin-bottom: 55px; }
/* 単独で置く地図カード（グリッドで横幅いっぱいに伸びるのを防ぐ） */
.map-solo { max-width: 540px; margin: 0 auto; }

/* 地図の埋め込み枠（アスペクト比を保ったまま横幅に追従） */
.map-frame { position: relative; width: 100%; aspect-ratio: 4 / 3; background: var(--bg-light); }
.map-frame iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; display: block; }
/* aspect-ratio 非対応ブラウザ向けのフォールバック */
@supports not (aspect-ratio: 4 / 3) {
    .map-frame { height: 0; padding-bottom: 75%; }
}
/* 単独表示用の大きめの地図 */
.map-frame-wide { aspect-ratio: 16 / 7; }
@supports not (aspect-ratio: 16 / 7) {
    .map-frame-wide { height: 0; padding-bottom: 43.75%; }
}

/* 動画の埋め込み枠（アスペクト比を保ったまま横幅に追従） */
.video-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 8px; overflow: hidden; box-shadow: 0 6px 20px rgba(0,0,0,0.08); }
.video-frame iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; display: block; }
@supports not (aspect-ratio: 16 / 9) {
    .video-frame { height: 0; padding-bottom: 56.25%; }
}
.video-credit { font-size: 13px; color: var(--muted-text); margin-top: 10px; }
.video-source { font-size: 12px; line-height: 1.6; color: #67717a; margin-top: 4px; word-break: break-all; }

/* ===== 採用情報 ===== */
.recruit { background: var(--bg-light); }
.recruit-table { width: 100%; max-width: 850px; margin: 0 auto 30px; border-collapse: collapse; background: white; }
.recruit-table th, .recruit-table td { padding: 16px; border-bottom: 1px solid #e2e8f0; text-align: left; vertical-align: top; font-size: 15px; }
.recruit-table th { width: 25%; color: var(--primary-color); background: #fff; font-weight: bold; white-space: nowrap; }

/* ===== よくあるご質問 ===== */
.faq-list { max-width: 850px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid #e2e8f0; padding: 22px 0; }
.faq-q { font-weight: bold; color: var(--primary-color); font-size: 17px; margin-bottom: 10px; }
.faq-q::before { content: 'Q. '; color: var(--secondary-color); }
.faq-a { font-size: 15px; color: #4a5568; padding-left: 24px; }
.faq-a::before { content: 'A. '; color: var(--accent-color); font-weight: bold; margin-left: -24px; }

/* ===== お問い合わせ ===== */
/* 蒜山三座の写真の上に、組合の緑を半透明で重ねています。透過率は白文字が読める濃さに合わせています */
.contact-section {
    background: linear-gradient(135deg, rgba(54,114,57,0.92), rgba(31,77,36,0.94)),
                url('../images/contact-bg.jpg') no-repeat center 78%/165%;
    color: white; text-align: center;
}
.contact-section h2 { color: white; }
.contact-section h2::after { color: var(--secondary-color); }
.contact-lead { font-size: 16px; color: #ebf2e9; margin-bottom: 10px; }
.contact-phone { font-size: 36px; font-weight: bold; color: #fff; margin: 20px 0 5px; letter-spacing: 1px; }
.contact-phone a { color: inherit; text-decoration: none; }
.contact-hours { font-size: 14px; color: #ebf1e9; margin-bottom: 30px; }
.contact-note { font-size: 13px; color: #ebf1e9; margin-top: 25px; }
.contact-note a { color: #ffffff; }

/* 各支所の連絡先カード（お問い合わせページ用） */
.branch-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); gap: 20px; margin-top: 40px; text-align: left; }
/* 緑帯の上に置くカード。白を重ねると背景が明るくなり文字が読みにくいため、黒を薄く重ねて沈ませます */
.branch-card { background: rgba(0,0,0,0.20); border: 1px solid rgba(255,255,255,0.22); border-radius: 6px; padding: 22px; }
.branch-card h3 { color: #fff; font-size: 17px; margin-bottom: 8px; }
.branch-card p { font-size: 14px; color: #dde8da; }
.branch-card a { color: #fff; font-weight: bold; text-decoration: none; font-size: 17px; }
.branch-card .branch-area { font-size: 12px; color: #b9d0b5; margin-top: 8px; }

/* ===== 規約・ポリシーなどの文章ページ ===== */
.doc { max-width: 850px; margin: 0 auto; }
.doc > p { font-size: 15px; color: #4a5568; margin-bottom: 20px; }
/* 条文見出し。section h2 の中央寄せ・◆ 装飾は打ち消して左寄せで表示します */
.doc h2 {
    font-size: 19px; color: var(--primary-color); margin: 45px 0 12px;
    padding-left: 14px; border-left: 4px solid var(--secondary-color);
    text-align: left; letter-spacing: normal;
}
.doc h2::after { content: none; }
.doc h2:first-of-type { margin-top: 0; }
.doc h3 { font-size: 16px; color: var(--primary-color); margin: 22px 0 8px; }
.doc ul, .doc ol { margin: 0 0 20px 24px; font-size: 15px; color: #4a5568; }
.doc li { margin-bottom: 6px; }
.doc a { color: var(--secondary-text); }

/* ===== フッター ===== */
footer { background: #1f4d24; color: #c6d6c2; text-align: center; padding: 40px 0; font-size: 14px; border-top: 1px solid #367239; }
footer p { color: #fff; margin-bottom: 5px; }
.footer-nav { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 20px; margin: 0 0 25px; padding: 0; }
.footer-nav a { color: #c6d6c2; text-decoration: none; font-size: 13px; }
.footer-nav a:hover { color: #fff; text-decoration: underline; }
.footer-badges { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 20px; margin: 0 0 25px; }
.footer-badges .badge { display: block; background: #fff; padding: 8px 14px; border-radius: 6px; line-height: 0; }
.footer-badges img { height: 42px; width: auto; display: block; }
.footer-badges .badge-sgec-wrap { background: none; padding: 0; border-radius: 0; }
.footer-badges img.badge-sgec { height: 92px; }
footer .copyright { color: #b5c8b1; font-size: 13px; margin-top: 15px; margin-bottom: 0; }

/* ===== スマホ対応レスポンシブ ===== */
@media (max-width: 768px) {
    /* ヘッダーは「ロゴ＋メニューボタン」の細い帯にして、画面を本文に使えるようにします */
    header .container { flex-direction: row; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; flex-wrap: wrap; }
    .logo { flex-direction: row; gap: 0; flex: 0 1 auto; min-width: 0; }
    .logo-mark { height: auto; width: auto; max-width: 100%; max-height: 34px; }
    /* 説明文はスマホでは省略（帯を低く保つため。内容は各ページ本文にあります） */
    .logo span { display: none; }

    /* メニューボタン */
    .nav-toggle {
        display: inline-flex; align-items: center; gap: 7px; flex-shrink: 0;
        background: #fff; border: 1px solid #cfdec8; border-radius: 5px;
        padding: 8px 12px; min-height: 40px; cursor: pointer;
        font-family: inherit; font-size: 13px; font-weight: bold; color: var(--primary-color);
    }
    .nav-toggle:focus-visible { outline: 2px solid var(--accent-color); outline-offset: 2px; }
    .nav-toggle-bars { position: relative; display: block; width: 18px; height: 2px; background: currentColor; }
    .nav-toggle-bars::before, .nav-toggle-bars::after {
        content: ''; position: absolute; left: 0; width: 18px; height: 2px; background: currentColor;
    }
    .nav-toggle-bars::before { top: -6px; }
    .nav-toggle-bars::after { top: 6px; }
    /* 開いているときは×印にする */
    .nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
    .nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { top: 0; transform: rotate(45deg); }
    .nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { top: 0; transform: rotate(-45deg); }

    /* JavaScript が動く環境でだけ、ナビをたたみます。
       動かない場合は今までどおり全部並んだ状態で表示されます */
    .js-nav nav#site-nav { display: none; width: 100%; }
    .js-nav nav#site-nav.is-open { display: block; max-height: 72vh; overflow-y: auto; }
    nav#site-nav {
        flex-basis: 100%; order: 3;
        border-top: 1px solid #dbe6d6; margin-top: 8px; padding-top: 4px;
    }
    nav ul { flex-direction: column; align-items: stretch; }
    nav ul li { margin: 0; border-bottom: 1px solid #e6efe2; }
    nav ul li:last-child { border-bottom: none; }
    /* 1項目ずつ縦に並べ、指でタップしやすい高さを確保します */
    nav ul li a { display: block; padding: 13px 4px; text-align: left; }
    nav ul li a.current { border-bottom: none; padding-left: 10px; border-left: 3px solid var(--accent-color); }
    .footer-nav { gap: 2px 20px; }
    .footer-nav a { display: inline-block; padding: 6px 0; }
    .breadcrumb a { display: inline-block; padding: 4px 0; }
    /* スマホのヘッダーは56pxなので、飛び先の余白も小さくします */
    [id] { scroll-margin-top: 72px; }
    /* 電話番号は指で押しやすく（スマホではタップで発信するため） */
    a[href^="tel:"] { display: inline-block; padding: 4px 0; }
    .hero { padding: 100px 0; }
    .hero h1 { font-size: 28px; }
    .hero p { font-size: 16px; }
    .page-header { padding: 45px 0; }
    .page-header h1 { font-size: 24px; }
    section { padding: 60px 0; }
    .card-thumb { width: calc(100% + 70px); height: 200px; }
    .feature { grid-template-columns: 1fr; gap: 25px; margin-bottom: 40px; }
    .feature img { max-height: 240px; }
    /* スマホでは画像を必ず先頭に */
    .feature-reverse .feature-figure { order: 0; }
    .news-item { flex-direction: column; align-items: flex-start; gap: 8px; padding: 15px 0; }
    .news-date { width: auto; }
    .flow-item { padding-left: 55px; margin-left: 20px; }
    .flow-item::before { width: 40px; height: 40px; left: -21px; }
    .company-table th, .company-table td { display: block; width: 100%; }
    .company-table th { background: var(--bg-light); }
    .branch-table td, .branch-table th { display: block; width: 100%; padding: 8px 0; background: none; }
    .branch-name { border-bottom: none; padding-bottom: 2px; width: 100%; white-space: normal; }
    .recruit-table th, .recruit-table td { display: block; width: 100%; }
    .recruit-table th { background: var(--bg-light); }
    .contact-phone { font-size: 28px; }
    /* 縦に長くなるスマホでは、背景写真が帯状にならないよう全面に敷き直す */
    .contact-section { background-size: auto, cover; background-position: center center, center 60%; }
}

/* ===== 木質バイオマス受入カレンダー ===== */
.biomass-calendar { max-width: 560px; margin: 34px auto 0; background: #fff; border: 1px solid #e3ebdf; border-radius: 10px; box-shadow: 0 4px 18px rgba(0,0,0,0.06); padding: 22px 24px 24px; }
/* JavaScript が無効な環境では空の枠が残らないよう隠します */
.biomass-calendar:empty { display: none; }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-bottom: 14px; margin-bottom: 14px; border-bottom: 2px solid var(--primary-color); }
.cal-title { display: flex; flex-direction: column; align-items: center; line-height: 1.35; }
.cal-title strong { font-size: 21px; color: var(--primary-color); letter-spacing: 0.5px; }
.cal-title small { font-size: 12px; color: var(--muted-text); letter-spacing: 0.5px; }
.cal-nav { flex-shrink: 0; background: var(--bg-light); border: 1px solid #cfdec8; border-radius: 6px; width: 38px; height: 38px; cursor: pointer; font-size: 15px; line-height: 1; color: var(--primary-color); transition: background 0.2s, border-color 0.2s; }
.cal-nav:hover { background: var(--primary-color); border-color: var(--primary-color); color: #fff; }
.cal-nav:focus-visible { outline: 2px solid var(--accent-color); outline-offset: 2px; }

.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.cal-dow { text-align: center; font-size: 13px; font-weight: bold; color: #5a6b7d; padding: 4px 0 8px; }
.cal-dow.cal-sun { color: #c0392b; }
.cal-dow.cal-sat { color: #2d6cb0; }

.cal-day { min-height: 62px; border-radius: 6px; border: 1px solid transparent; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 4px 2px; text-align: center; }
.cal-day.cal-empty { visibility: hidden; min-height: 0; }
.cal-day.cal-open { background: #e8f2e3; border-color: #c5dcbb; color: #2f6b33; }
.cal-day.cal-closed { background: #f7ebe9; border-color: #e6c9c4; color: #a8352b; }
.cal-day.cal-today { border-color: var(--accent-color); border-width: 2px; box-shadow: 0 0 0 2px rgba(171,95,44,0.18); }
.cal-date-num { font-size: 17px; font-weight: bold; line-height: 1; }
.cal-status { font-size: 10px; line-height: 1.2; font-weight: 600; word-break: keep-all; }
.cal-day.cal-open .cal-status { color: #477444; font-weight: normal; }

.cal-legend { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; font-size: 12.5px; color: #4a5568; }
.cal-legend li { display: flex; align-items: center; }
.cal-legend-dot { display: inline-block; width: 13px; height: 13px; border-radius: 3px; margin-right: 6px; }
.cal-legend-open { background: #e8f2e3; border: 1px solid #7ea873; }
.cal-legend-closed { background: #f7ebe9; border: 1px solid #c98d84; }
/* 月を切り替えたことを読み上げソフトに伝えるためだけの欄。
   目で見るカレンダーには同じ内容が出ているので、画面上は見えないようにします
   （display:none にすると読み上げもされなくなるため、この書き方にします） */
.cal-live { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.cal-note { max-width: 560px; margin: 14px auto 0; font-size: 12.5px; line-height: 1.75; color: var(--muted-text); text-align: center; }

/* 画面幅の狭い端末でも、ロゴとメニューボタンが1行に収まるようにロゴを一段小さくします */
@media (max-width: 420px) {
    .logo-mark { max-height: 30px; }
    .nav-toggle { padding: 8px 10px; font-size: 12px; gap: 6px; }
}
@media (max-width: 360px) {
    .logo-mark { max-height: 24px; }
}

@media (max-width: 560px) {
    .biomass-calendar { padding: 16px 12px 18px; }
    .cal-grid { gap: 3px; }
    .cal-day { min-height: 50px; gap: 1px; }
    .cal-date-num { font-size: 15px; }
    .cal-status { font-size: 8.5px; }
    .cal-title strong { font-size: 18px; }
    .cal-legend { flex-direction: column; align-items: center; gap: 6px; }
}

/* ===== お問い合わせフォーム（確認・完了・エラー画面） ===== */
/* 迷惑メール対策の項目。利用者には見せず、読み上げ対象からも外します */
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-errors { background: #fdf3f2; border: 1px solid #e6c9c4; border-left: 5px solid #b3392f; border-radius: 6px; padding: 20px 24px; margin-bottom: 30px; }
.form-errors-title { font-weight: bold; color: #a8352b; margin-bottom: 10px; }
.form-errors ul { margin: 0; padding-left: 1.3em; }
.form-errors li { color: #a8352b; margin-bottom: 5px; line-height: 1.7; }
.form-errors p { line-height: 1.9; }
.form-errors p + p { margin-top: 10px; }

.confirm-table { width: 100%; max-width: 760px; margin: 0 auto; border-collapse: collapse; background: #fff; border: 1px solid #e3ebdf; border-radius: 8px; overflow: hidden; }
.confirm-table th, .confirm-table td { padding: 16px 20px; text-align: left; vertical-align: top; border-bottom: 1px solid #eef2ec; line-height: 1.8; }
.confirm-table tr:last-child th, .confirm-table tr:last-child td { border-bottom: none; }
.confirm-table th { width: 34%; background: var(--bg-light); color: var(--primary-color); font-weight: bold; white-space: nowrap; }
.confirm-empty { color: #9aa5ab; }
.confirm-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 34px; }

.form-done { max-width: 700px; margin: 0 auto; background: #fff; border: 1px solid #d7e6d0; border-radius: 8px; padding: 32px 34px; text-align: center; }
.form-done-lead { font-size: 19px; font-weight: bold; color: var(--primary-color); line-height: 1.8; margin-bottom: 18px; }
.form-done p { line-height: 1.95; }
.form-done p + p { margin-top: 14px; }
.form-done-tel { margin-top: 22px; padding-top: 18px; border-top: 1px dashed #d7e6d0; font-weight: bold; }
.form-done-tel a { font-size: 21px; color: var(--accent-color); }

@media (max-width: 600px) {
    .confirm-table th, .confirm-table td { display: block; width: 100%; }
    .confirm-table th { border-bottom: none; padding-bottom: 4px; }
    .confirm-table td { padding-top: 4px; }
    .confirm-actions { flex-direction: column; }
    .form-done { padding: 24px 18px; }
}

/* ===== リンク集 ===== */
.link-list { list-style: none; max-width: 860px; margin: 0 auto; padding: 0; }
.link-list li { background: #fff; border: 1px solid #e3ebdf; border-left: 5px solid var(--secondary-color); border-radius: 6px; padding: 18px 24px; margin-bottom: 14px; transition: box-shadow 0.2s, transform 0.2s; }
.link-list li:hover { box-shadow: 0 5px 18px rgba(0,0,0,0.07); transform: translateY(-2px); }
.link-list li > a { font-size: 17px; font-weight: bold; color: var(--primary-color); text-decoration: none; }
.link-list li > a:hover { text-decoration: underline; }
/* 外部リンクであることを示す矢印（バナー画像のリンクには付けません） */
.link-list li > a::after { content: " ↗"; font-size: 13px; font-weight: normal; color: #67717a; }
.link-note { display: block; font-size: 14px; line-height: 1.8; color: #4a5568; margin-top: 6px; }
.link-footnote { max-width: 860px; margin: 30px auto 0; font-size: 13px; line-height: 1.9; color: var(--muted-text); }

@media (max-width: 768px) {
    .link-list li { padding: 16px 18px; }
    .link-list li > a { font-size: 16px; }
}

/* ===== 印刷用 =====
   紙に出したときに、画面用の飾りやナビを省いて本文を読みやすくします */
@media print {
    /* 画面でしか意味のないものは印刷しない */
    nav, .nav-toggle, .breadcrumb, .footer-nav, .more-link, .btn,
    .map-frame, .video-frame, .dl-btn, .cal-live, .page-header::before { display: none !important; }

    body { background: #fff; color: #000; font-size: 11pt; line-height: 1.6; }
    header { position: static; background: none; box-shadow: none; border-bottom: 1px solid #999; }
    header .container { padding: 6px 0; }
    .container { width: 100%; max-width: none; }
    section { padding: 12px 0; }

    /* 帯は写真をやめて、見出しだけを残す */
    .page-header, .hero { background: none !important; color: #000; padding: 10px 0; text-align: left; }
    .page-header h1, .hero h1 { color: #000; text-shadow: none; font-size: 18pt; }
    .page-header p, .hero p { color: #444; text-shadow: none; }
    section h2 { color: #000; }
    section h2::after { content: none; }

    /* 外部リンクは、紙では行き先が分からないのでURLを添える */
    main a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; color: #444; word-break: break-all; }

    /* 途中で切れると読みにくいものは、なるべく分割しない */
    .card, .news-item, .map-card, .dl-list li, tr, .branch-card { break-inside: avoid; page-break-inside: avoid; }
    h1, h2, h3 { break-after: avoid; page-break-after: avoid; }

    footer { background: none; color: #000; border-top: 1px solid #999; padding: 10px 0; }
    footer p, footer .copyright { color: #000; }
    .footer-badges { display: none; }
}
