/* Reset and Base Styles */
body,
h1,
h2,
h3,
p,
ul,
li,
form,
input,
textarea,
button {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
}


/* 白背景にしたいセクション */

.hero {
    background-color: #ffffff;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    padding-left: 0;
    padding-right: 0;
}


/* Container Styles */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;

}

/* Header Styles */
/* ヘッダーを固定 */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    height: 150px;
    /* ヘッダー全体の高さ */
}

/* ヘッダー背景を付けるクラス（追加） */
header.scrolled {
    background-color: #ffffff;
    transition: background-color 0.3s ease;
    /* border: 3px solid #4A4E69; */
}

.logo {
    height: 200px;
    margin-right: auto;
}

/* Hero Section */
.hero {
    position: relative;
    width: 100%;
    /* max-width: 1200px; */
    margin: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    background-color: #ffffff;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: right center;
}

/* 左側の白いグラデーション */
.hero-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 60%;
    height: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0.7) 30%, rgba(255, 255, 255, 0) 100%);
    z-index: 1;
}

/* テキスト部分 */
.hero-text {
    position: absolute;
    left: 80px;
    z-index: 2;
    color: #4A4E69;
    text-align: left;
    max-width: 40%;
    margin-left: 350px;
    margin-top: 120px;
}

.hero-text .small-text {
    font-size: 1.5em;
    font-family: "Arial", sans-serif;
    font-weight: normal;
    margin-bottom: 0.5em;
}

.hero-text h1 {
    font-family: 'M PLUS Rounded 1c', 'Noto Sans JP', sans-serif;
    font-size: 4em;
    font-weight: 700;
    line-height: 1.2em;
    letter-spacing: 0.03em;
}


.hero-text .sub-text {
    font-size: 1.8em;
    font-family: "Arial", sans-serif;
    font-weight: normal;
    margin-top: 0.5em;
}

/* ナビゲーションメニュー */
nav ul {
    display: flex;
    align-items: center;
    gap: 15px;
    /* メニュー間の余白 */
    margin: 0 40px;
    padding: 0;
    list-style: none;
}

/* ナビゲーションリンク */
nav ul li a {
    display: flex;
    align-items: center;
    /* 縦方向の中央揃え */
    justify-content: center;
    /* 横方向の中央揃え */
    text-decoration: none;
    color: #4A4E69;
    ;
    font-weight: bold;
    padding: 15px 20px;
    /* 上下位置の調整 */
    border: 3px solid #4A4E69;
    background-color: #fff;
    font-size: 1.2em;
    transition: all 0.3s ease;
    white-space: nowrap;
    border-radius: 40px;
    /* ← ここを追加！ */
    width: 100px;
}


nav ul li a:hover {
    background-color: #4A4E69 !important;
    color: #fff !important;
}


/* Common Buttons (Under Header) */
.common-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 20px auto;
    max-width: 1150px;
    padding: 0 25px;

}

.common-buttons a {
    text-decoration: none;
    color: #4A4E69;
    font-weight: bold;
    padding: 20px 40px;
    border: 3px solid #4A4E69;
    background-color: #fff;
    font-size: 1.3em;
    transition: all 0.3s ease;
    flex: 1;
    text-align: center;
    white-space: nowrap;
    max-width: 250px;
}

.common-buttons a:hover {
    background-color: #4A4E69;
    color: #fff;
}


/* NEWS Section */
.news {
    display: flex;
    align-items: center;
    /* 垂直方向の中央揃え */
    margin: 40px 20px;
    padding: 20px;
    border: 3px solid #4A4E69;
    background-color: #ffffff;
}

/* タイトル */
.news h3 {
    font-size: 3em;
    margin: 0;
    margin: 10px 150px 10px 150px;
    text-align: center;
    font-weight: bold;
    flex-shrink: 0;
    /* タイトルが縮まないように */
    align-self: center;
    /* 縦中央に配置 */
}

/* ニュースアイテム */
.news-items {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: left;
    margin-left: 100px;
    flex-grow: 1;
}

.news-item {
    display: flex;
    align-items: center;
    gap: 20px;
    font-size: 1.5em;
    padding-bottom: 5px;
    position: relative;
    border-bottom: 1px solid #4A4E69;
    /* ← 実線を直接 */
    width: fit-content;
    /* 文字幅に合わせる */
}

/* ボーダーラインを短くする
.news-item::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60%; /* ボーダーラインの長さ */
/* border-bottom: 2px solid #4A4E69;
} */

/* 日付 */
.news-item p {
    margin: 0;
    font-weight: bold;
}

/* 内容 */
.news-item span {
    margin: 0;
    font-weight: normal;
    font-size: 0.9em;
}

/* Footer Styles */
footer {
    text-align: center;
    padding: 20px;
    background-color: #ffffff;
    border-top: 5px solid #4A4E69;
    font-size: 1.2em;
    height: 100px;
}

/* ホームボックス（HOME専用） */
.home-section {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin: 40px 20px;
}

.home-box {
    border: 5px solid #4A4E69;
    padding: 40px;
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.home-box h2 {
    font-size: 3em;
    margin-bottom: 20px;
}

.home-box button {
    padding: 15px 30px;
    border: 3px solid #4A4E69;
    border-radius: 0;
    background-color: #fff;
    font-weight: bold;
    font-size: 1.5em;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
}

.home-box button:hover {
    background-color: #4A4E69;
    color: #fff;
}

/* フッターのフォント設定 */
footer {
    font-family: Arial, Helvetica, sans-serif;
    text-align: center;
    padding: 20px;
    background-color: #fff;
    border-top: 5px solid #4A4E69;
    font-size: 1.2em;
}

/* フッターのリンクスタイル */
.footer-back a {
    font-family: Arial, Helvetica, sans-serif;
    font-weight: normal;
    color: #4A4E69;
    text-decoration: none;
}

.footer-back a:hover {
    color: #555;
}

.footer-links {
    padding-top: 20px;
}

/* フッターのリンクスタイル */
.footer-links a {
    font-family: Arial, Helvetica, sans-serif;
    font-weight: bold;
    /* 太字に変更 */
    color: #4A4E69;
    text-decoration: none;
}

.footer-links a:hover {
    color: #555;
}

/* PC版 */
.hero-image-wrapper {
    position: relative;
    width: 100%;
    height: auto;
    height: 400px;
    /* ★固定値に変更 */
    overflow: hidden;
}

/* 画像の位置調整 */
.hero-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    /* 切り取りながらフィット */
    object-position: center;
    /* 中央寄せで表示 */
}

/* 左下から左方向へ伸びる線 */
.common-buttons a.active::before {
    content: "";
    position: absolute;
    bottom: 0;
    left: -100vw;
    height: 3px;
    width: 100vw;
    background-color: #4A4E69;
}

/* 右下から右方向へ伸びる線 */
.common-buttons a.active::after {
    content: "";
    position: absolute;
    bottom: 0;
    right: -100vw;
    height: 3px;
    width: 100vw;
    background-color: #4A4E69;
}

html,
body {
    overflow-x: hidden;
    /* 横スクロールを防止 */
}

.header-hero-wrapper {
    background-color: #ffffff;
    width: 100%;
}

.white-area {
    background-color: #ffffff;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
}


/* 最優先で背景を白にする */
.header-hero-wrapper,
.white-area,
.hero {
    background-color: #ffffff !important;
}

/* ヘッダーとヒーローを包む白背景ラッパー */
.header-hero-wrapper {
    background-color: #ffffff;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
}

.white-extension {
    background-color: #ffffff;
    width: 100vw;
    /* height: 5px; ← 白くしたい高さに応じて調整 */
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
}

/* .common-buttons::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #ffffff;
  z-index: -1;
} */

.hero {
    position: relative;
    background-color: #ffffff;
    overflow: hidden;
    /* margin-top: 100px; ← ここを調整 */
}

.hero::before {
    content: "";
    position: absolute;
    top: -40px;
    left: 0;
    width: 100%;
    height: 40px;
    background-color: #ffffff;
    z-index: 0;
}


/* 大画面対応 */
@media (min-width: 1200px) {
    .hero-image {
        object-fit: contain;
        /* 全体を表示 */
        object-position: center top;
        /* 上寄せ */
    }
}

@media (min-width: 769px) {

    .common-buttons {
        position: relative;
        z-index: 1;
    }

    .common-buttons a.active {
        position: relative;
        background-color: #D96459;
        border-bottom: none;
        color: #4A4E69;
        margin-bottom: -3px;
        z-index: 2;
    }


    /* 非アクティブボタンの線を消す */
    .common-buttons a:not(.active)::after {
        content: none;
    }
}

@media (max-width: 1000px) {
    header {
        display: flex;
        flex-direction: row !important;
        /* ← 横並びに固定 */
        align-items: center;
        justify-content: space-between;
        height: auto;
        padding: 0px 15px;
        flex-wrap: wrap;
        /* 狭いときに折り返す */
    }

    .logo {
        max-width: 180px;
        height: auto;
        margin-right: 10px;
    }

    nav ul {
        display: flex;
        flex-wrap: wrap;
        /* ← 狭いとき折り返し */
        justify-content: flex-end;
        gap: 10px;
        margin-left: -30px;
        padding: 0;
    }

    nav ul li {
        flex-shrink: 1;
    }

    nav ul li a {
        font-size: 1em;
        padding: 10px 15px;
        width: auto;
        white-space: nowrap;
        font-weight: bold;
    }

}


/* .header-hero-wrapper 全幅強制をオフ */
.header-hero-wrapper {
    width: 100% !important;
    margin: 0 auto !important;
    overflow-x: hidden;
}

/* .white-area や .white-extension も調整 */
.white-area,
.white-extension {
    width: 100% !important;
    margin: 0 auto !important;
}

/* ==============================
   Responsive Styles (スマホ対応)
============================== */
@media (max-width: 768px) {

    /* コンテナ */
    .container {
        width: 100%;
        border-left: none;
        border-right: none;
    }

    header {
        display: flex;
        align-items: center;
        background-color: #ffffff;
        /* border-bottom: 5px solid #4A4E69; */
        padding: 0px 20px;
        justify-content: space-between;
        height: 100px;
    }

    .logo {
        height: 100px;
    }

    nav ul {
        flex-direction: column;
        gap: 10px;
    }

    nav ul li a {
        font-size: 1em;
        padding: 10px 15px;
    }

    /* ヒーローセクション */
    .hero {
        flex-direction: column;
        width: 100%;
        align-items: center;
        text-align: center;
        padding: 60px 0 40px 0;
        /* ← 下方向の余白を足す */
        padding-left: -40px;
        position: relative;
    }

    .hero-image-wrapper {
        width: 100%;
        height: auto;
        max-height: 250px;
        /* 高すぎると見えなくなるので上限を絞る */
        overflow: hidden;
    }

    .hero-image {
        width: 100%;
        height: auto;
        object-fit: cover;
        object-position: center top;
    }

    .hero-text {
        position: relative;
        left: auto;
        /* ← 左位置指定を解除 */
        margin: 0 auto;
        /* ← 完全中央寄せ */
        padding: 40px 0 20px 0;
        background-color: rgba(255, 255, 255, 0.9);
        /* 背景白で可読性向上 */
        text-align: left;
        max-width: 95%;
        /* ← より余白を広くする */
    }

    .hero-text h1 {
        font-size: 2.2em;
        margin-bottom: 10px;
        line-height: 1.3;
    }

    .hero-text .small-text,
    .hero-text .sub-text {
        font-size: 1.1em;
    }


    /* ボタン */
    .common-buttons {
        flex-direction: column;
        gap: 10px;
        padding: 0;
        margin: 20px 0;
    }

    .common-buttons a {
        font-size: 1em;
        padding: 15px 20px;
        width: 100%;
    }


    /* ニュースセクション */
    .news h3 {
        font-size: 3em;
    }

    .news-item {
        font-size: 1.2em;
        gap: 10px;
    }

    .news-item span {
        font-size: 0.9em;
    }

    /* ホームボックス */
    .home-box {
        padding: 20px;
        margin: 20px 0;
    }

    .home-box h2 {
        font-size: 2em;
    }

    .home-box button {
        font-size: 1em;
        padding: 10px 20px;
        margin-top: 15px;
    }

    /* フッター */
    footer {
        padding: 15px;
        font-size: 1em;
    }

    .footer-links a {
        font-size: 0.9em;
        margin: 5px;
    }
}

/* ==============================
   ハンバーガーメニュー - モバイル専用修正
============================== */
/* ハンバーガーメニュー */
.menu-toggle {
    display: none;
    font-size: 2em;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    margin-right: 40px;
    margin-left: auto;
    z-index: 1001;
    color: #4A4E69;
}

/* モバイル専用（ハンバーガーメニュー表示） */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
        /* モバイルで表示 */
        align-self: center;
        /* ロゴと垂直位置を揃える */
    }

    nav ul {
        display: none;
        position: absolute;
        top: 80px;
        left: 50%;
        transform: translateX(-30%);
        width: fit-content;
        background-color: #fff;
        border: 1px solid #4A4E69;
        padding: 20px;
        z-index: 1000;
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }


    nav ul.active {
        display: flex;
    }

    nav ul li {
        width: 100%;
        text-align: center;
    }

    nav ul li a {
        display: block;
        padding: 15px;
        font-size: 1.2em;
        /* border-bottom: 1px solid #ddd; */
        color: #4A4E69;
        text-decoration: none;
        border-radius: 40px;
        /* ← これを追加 */
        margin-bottom: 10px;
        /* 下の余白で切れないように */
        background-color: #fff;
    }

    nav ul li a:hover {
        background-color: #4A4E69;
        color: #fff;
    }
}

/* ==============================
   NEWSセクション - モバイル専用修正
============================== */
@media (max-width: 768px) {
    .news {
        flex-direction: column;
        padding: 20px 15px;
    }

    .news h3 {
        font-size: 3em;
        text-align: center;
        margin-bottom: 15px;
    }

    .news-items {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }

    .news-item {
        display: flex;
        flex-direction: column;
        gap: 5px;
        border-bottom: 1px solid #4A4E69;
        padding-bottom: 15px;
        margin-bottom: 15px;
        font-size: 1.2em;
        width: 100%;
        text-align: left;
    }

    .news-item p {
        margin: 0;
        font-weight: bold;
    }

    .news-item span {
        margin: 0;
        font-size: 1em;
    }

    .news-item:last-child {
        border-bottom: none;
        margin-bottom: 0;
    }
}

/* ==============================
   common-buttons - PC版
============================== */
.common-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 20px auto;
    max-width: 1150px;
    padding: 0 25px;
}

/* PC版ボタンスタイル */
.common-buttons a {
    text-decoration: none;
    color: #4A4E69;
    font-weight: bold;
    padding: 20px 40px;
    border-top: 3px solid #4A4E69;
    border-bottom: none;
    border-left: 3px solid #4A4E69;
    border-right: 3px solid #4A4E69;
    background-color: #fff;
    font-size: 1.3em;
    transition: all 0.3s ease;
    text-align: center;
    white-space: nowrap;
    flex: 1;
    max-width: 250px;
    border-radius: 40px 40px 0 0;
    /* ← ここを追加！ */
}


/* ==============================
   common-buttons - モバイル版
============================== */
@media (max-width: 768px) {
    .common-buttons {
        display: flex;
        flex-wrap: nowrap;
        gap: 5px;
        /* ボタン間の余白 */
        overflow-x: auto;
        padding: 0 5px;
        margin: 10px 0;
    }

    .common-buttons a {
        flex: 0 0 auto;
        padding: 10px 15px;
        white-space: nowrap;
        text-align: center;
        box-sizing: border-box;
        margin: 0 5px;
        max-width: calc(20% - 10px);
        /* 5つで100% */
    }

    .common-buttons {
        display: none;
    }
}

/* 1001px以上（すでに対応済み：4列） */

/* 769px〜1000px：2列×2段 */
@media (max-width: 1000px) and (min-width: 769px) {
  .home-section {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin: 40px 20px;
  }

  .home-box {
    display: flex;
    flex-direction: column;
    border: 3px solid #4A4E69;
    border-radius: 20px;
    overflow: hidden;
    background-color: #fff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 0;
    text-align: center;
  }

  .home-box img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border: none;
  }

  .home-box .content {
    padding: 20px;
  }

  .home-box h2 {
    font-size: 1.8em;
  }

  .home-box button {
    font-size: 1em;
    padding: 10px 20px;
    margin-top: 15px;
    border-radius: 40px;
  }
}

/* 1000px以下：2列×2段に変更 */
@media (max-width: 1000px) and (min-width: 769px) {
  .home-section {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* 768px以下：縦並び */
@media (max-width: 768px) {
  .home-section {
    display: flex !important;
    flex-direction: column;
    gap: 30px;
    padding: 20px;
  }
}

/* デフォルト：4列（PC向け） */
.home-section {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  margin: 60px 40px;
}



/* 768px以下：縦1列に変更 */
@media (max-width: 768px) {
  .home-section {
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding: 20px;
  }
}

/* 共通（PC＆タブレット） */
.hero-text {
  position: absolute;
  top: 40%;
  left: 60px;
  transform: translateY(-50%);
  padding: 0 20px;
  width: 100%;
  text-align: left;
  color: #4A4E69;
  z-index: 2;
}

/* タブレット（769px〜960px） */
@media (max-width: 1500px) and (min-width: 769px) {
  .hero-text {
    left: -200px;
    top: 40%;
    transform: translateY(-50%);
    text-align: left;
  }
}

/* モバイル（〜768px） */
@media (max-width: 768px) {
  .hero-text {
    position: relative;
    top: auto;
    left: auto;
    transform: none;
    text-align: center;
    margin: 0 auto;
    padding: 40px 20px 20px 20px;
    z-index: 2;
    background-color: rgba(255, 255, 255, 0.85);
    max-width: 90%;
  }

  .hero-text h1 {
    font-size: 3em;
    line-height: 1.3;
  }
}






