/* ==================================
   変数定義
================================== */
:root {
    --color-primary: #007560; /* メインの緑 */
    --color-secondary: #2e9648; /* メインの緑 */
    --color-third: #fff6b4; /* メインの緑 */
    --color-text: #333;
    --color-bg-gray: #f9f9f9;
    --color-bg-blue: #005a9c; /* 元の青は残しておくか、削除 */
    --color-white: #fff;
    --header-height: 70px;
    --header-height-sp: 60px;
    --container-width: 1100px; /* PCでのコンテナ幅を明確化 (hero-image-rightで使うため) */
}
/* ==================================
   共通レイアウト
================================== */
.container {
    width: 92%;
    max-width: 1100px;
    margin-right: auto;
    margin-left: auto;
}

/* 共通セクション余白 */
.section {
    padding: 60px 0;
}
@media (min-width: 768px) {
    .section {
        padding: 90px 0;
    }
}

/* 共通セクションタイトル (例: お知らせ, ごあいさつ) */
.section-title {
    font-size: 2.8rem;
    font-weight: bold;
    text-align: center;
    margin-bottom: 40px;
    color: var(--color-primary);
}
@media (min-width: 768px) {
    .section-title {
        font-size: 3.2rem;
        margin-bottom: 60px;
    }
}
section.section.license {
    padding-top: 0px;
}
section.section.news {
    padding: 50px 0;
}
/* ==================================
   共通ボタン
================================== */
.btn {
    display: inline-block;
    padding: 12px 24px;
    font-size: 1.6rem;
    font-weight: bold;
    border-radius: 4px;
    text-align: center;
    transition: opacity 0.3s;
    cursor: pointer;
    text-decoration: none;
}
.btn:hover {
    opacity: 0.8;
    text-decoration: none;
}
.btn-primary {
    background-color: var(--color-secondary);
    color: var(--color-white);
    border: 1px solid var(--color-secondary);
}
.btn-secondary {
    background-color: var(--color-white);
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
}

/* ==================================
   ヘッダー
================================== */
.header {
    width: 100%;
    height: var(--header-height-sp);
    background-color: var(--color-white);
    border-bottom: 1px solid #eee;
    position: fixed; /* スティッキーヘッダー */
    top: 0;
    left: 0;
    z-index: 1000;
    background: #fffdee;
}
.header-inner {
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 4%; /* スマホでは .container を使わず左右いっぱい */
}

.header-logo a {
    font-size: 2.4rem;
    font-weight: bold;
    color: var(--color-text);
    text-decoration: none;
}
/* ロゴ画像を使う場合 */
/* .header-logo img {
    height: 30px; 
    width: auto;
} */

/* PC用ナビゲーション (スマホでは非表示) */
.header-nav {
    display: none;
}
.header-nav-list {
    display: flex;
    gap: 30px;
}
.header-nav-item a {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--color-text);
    text-decoration: none;
    transition: color 0.3s;
}
.header-nav-item a:hover {
    color: var(--color-primary);
}
.header-buttons {
    display: none; /* スマホでは非表示 */
}

/* ハンバーガーメニュー (スマホのみ表示) */
.hamburger-menu {
    top: 5px;
    display: block;
    width: 37px;
    height: 37px;
    position: relative;
    cursor: pointer;
    z-index: 1001;
    background: none;
    border: none;
}
.hamburger-menu span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--color-primary);
    position: absolute;
    left: 0;
    transition: all 0.3s;
}
.hamburger-menu span:nth-child(1) { top: 0; }
.hamburger-menu span:nth-child(2) { top: 10px; }
.hamburger-menu span:nth-child(3) { bottom: 0; }

/* スマホ用ナビゲーション (ハンバーガー内) */
.sp-nav {
    display: block;
    position: fixed;
    top: 0;
    right: -100%; /* 初期状態は画面外 */
    width: 100%;
    height: 100vh;
    background-color: rgba(255, 255, 255, 0.98);
    padding-top: var(--header-height-sp);
    transition: right 0.4s;
    z-index: 999;
}
.sp-nav-list {
    padding: 30px;
}
.sp-nav-item {
    border-bottom: 1px solid #eee;
}
.sp-nav-item a {
    display: block;
    padding: 20px 10px;
    font-size: 1.6rem;
    font-weight: bold;
    text-decoration: none;
    color: var(--color-text);
}
.sp-nav-buttons {
    padding: 0 30px;
    display: grid;
    gap: 15px;
}
.sp-nav-buttons .btn {
    width: 100%;
}

/* --- メニュー開閉時のスタイル (JSで .is-open を付与) --- */
body.is-open {
    overflow: hidden; /* 背景スクロール禁止 */
}
.hamburger-menu.is-open span:nth-child(1) {
    top: 10px;
    transform: rotate(45deg);
}
.hamburger-menu.is-open span:nth-child(2) {
    opacity: 0;
}
.hamburger-menu.is-open span:nth-child(3) {
    bottom: 10px;
    transform: rotate(-45deg);
}
.sp-nav.is-open {
    right: 0;
}

/* --- PC表示のスタイル --- */
@media (min-width: 992px) {
    .header {
        height: var(--header-height);
        background: #fffdee;
        border: none;
    }
    .header-inner {
        padding: 0; /* PCでは .container を使う */
        max-width: 1100px; /* .container と合わせる */
        margin: 0 auto;
        width: 92%;
    }
    .hamburger-menu {
        display: none;
    }
    .sp-nav {
        display: none;
    }
    .header-nav {
        display: block;
        margin-left: auto; 
    }
    .header-buttons {
        display: flex;
        gap: 15px;
        margin-left: 30px;
    }
    /* ヘッダーボタンのデザイン調整 */
    .header-buttons .btn {
        padding: 8px 16px;
        font-size: 1.4rem;
    }
    .header-buttons .btn-primary {
        background-color: var(--color-primary);
    }
    .header-buttons .btn-secondary {
        background-color: var(--color-secondary);
        color: var(--color-white);
        border-color: var(--color-secondary);
    }
}

/* --- スティッキーヘッダーのスタイル (JSで .is-sticky を付与) --- */
.header.is-sticky {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}


/* ==================================
   フッター (★修正版★)
================================== */
.footer {
    background-color: #333; /* フッター全体のベース色（コピーライト部） */
    color: #eee;
    /* padding-top: 60px 0 0; を削除 */
}

.footer-top {
    /* "お問い合わせ" セクション */
    background-color: var(--color-primary); /* デザインカンプの青背景 */
    padding: 50px 0;
}
.footer-cta {
    text-align: center;
    color: var(--color-white);
}
.footer-cta-title {
    font-size: 2.4rem;
    font-weight: bold;
    margin-bottom: 10px;
}
.footer-cta-text {
    font-size: 1.5rem;
    margin-bottom: 30px;
}
.footer-cta-buttons {
    display: flex;
    flex-direction: column; /* スマホでは縦積み */
    gap: 15px;
    align-items: center;
}
.footer-cta-buttons .btn {
    width: 280px; /* ボタン幅を統一 */
}
/* お問い合わせボタン */
.footer-cta-buttons .btn-tel {
    background-color: var(--color-white);
    color: var(--color-primary);
    border: 1px solid var(--color-white);
}
/* メールボタン */
.footer-cta-buttons .btn-mail {
    background-color: var(--color-secondary);
    color: var(--color-white);
    border: 1px solid var(--color-secondary);
}

/* フッター本体 */
.footer-main {
    background-color: var(--color-bg-gray); /* デザインカンプの青背景 */
    padding: 60px 0;
}

/* ★修正: .footer-main ではなく .footer-grid をGridコンテナにする */
.footer-grid {
    display: grid;
    grid-template-columns: 1fr; /* スマホは1カラム */
    gap: 40px;
}

.footer-info-address {
    font-size: 1.5rem;
    line-height: 1.8;
    font-style: normal;
    color: var(--color-text); /* ★文字色を白に */
}
.footer-logo {
    font-size: 2.4rem;
    font-weight: bold;
    color: var(--color-text);
    margin-bottom: 15px;
}
.footer-nav {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}
.footer-nav-title {
    font-size: 1.6rem;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--color-white); /* ★文字色を白に */
}
.footer-nav-item {
    margin-bottom: 10px;
}
.footer-nav-item,
.footer-nav-item a {
    color: #333;
    font-size: 1.5rem;
}
.footer-nav-item a:hover {
    text-decoration: underline;
}
.footer-map img {
    width: 100%;
    height: auto;
    border: 1px solid #555;
}

/* --- フッターのPC表示 --- */
@media (min-width: 768px) {
    .footer-cta-buttons {
        flex-direction: row; /* PCでは横並び */
        justify-content: center;
    }
    
    /* ★修正: .footer-grid で3カラムレイアウトを指定 */
    .footer-grid {
        /* [Info(1fr)], [Navs(1.5fr)], [Map(1fr)] の3カラム */
        grid-template-columns: 2fr 1.2fr 3fr;
        gap: 50px;
    }

    .footer-nav {
        /* PCでは .footer-grid の子として振る舞うため、grid設定を解除 */
        display: flex;
        gap: 40px;
    }
}

/* コピーライト */
.footer-bottom {
    background-color: #222;
    padding: 20px 0;
    text-align: center;
}
.copyright {
    font-size: 1.2rem;
    color: #aaa;
}



/* 共通線 */
.hamburger-menu::before,
.hamburger-menu::after,
.hamburger-menu span {
  content: "";
    position: absolute;
    left: 0px;
    width: 40px;
    height: 4px;
    background: #0a6c5d;
    transition: transform 1.3s, opacity 0.3s;
}

/* ハンバーガー */
.hamburger-menu::before {
  top: 12px;
}
.hamburger-menu span {
  top: 15px;
}
.hamburger-menu::after {
  top: 25px;
}

/* × に変形 */
.hamburger-menu.is-open::before {
  transform: rotate(45deg);
  top: 15px;
}
.hamburger-menu.is-open::after {
  transform: rotate(-45deg);
  top: 15px;
}
.hamburger-menu.is-open span {
  opacity: 0;
}

.to-top{
  position: fixed;
  right: 16px;
  bottom: 16px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;

  border-radius: 5px;
  background: #0b6b57; /* サイトの緑に合わせて */
  color: #fff;
  text-decoration: none;

  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity .2s, transform .2s, visibility .2s;

  z-index: 9999; /* これ大事 */
}

.to-top.is-show{
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* スムーススクロール（任意） */
html{ scroll-behavior: smooth; }
