/* =============================================

   1. パンくずリスト

   ============================================= */

.breadcrumb {
    padding: 240px 5% 15px;
    max-width: 1200px;
    margin: 0 auto;
    box-sizing: border-box;
}

.breadcrumb ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    font-size: 1rem;
    line-height: 1.5;
}

.breadcrumb ul li {
    display: flex;
    align-items: center;
}

.breadcrumb ul li:not(:last-child)::after {
    content: ">";
    margin: 0 10px;
    font-size: 1rem;
}

.breadcrumb ul li a {
    color: #79AD70;
    text-decoration: none;
    font-weight: 500;
}

/* =============================================

   2. メインコンテンツ

   ============================================= */

#contents {
    padding-bottom: 0;
    overflow: visible;
}

/* style.css の「section { margin-bottom: 500px; }」をこのページでは抑え、適度な余白に */
/* 背景装飾：style.css の .news::before / .clinichours::before と同様（絶対配置・100vw・高さ確保で切れず、本文の流れは変えない） */
section.menu {
    position: relative;
    margin-bottom: 150px;
    overflow: visible;
}

.menu-inner {
    overflow: visible;
}

section.menu::before {
    content: "";
    position: absolute;
    top: -180px;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    height: 2200px;
    /* 左：青 / 右：緑＋黄（黄は下層・clinichours の右黄色に近い配置） */
    background-image: url("../svg/haikei_blue.svg"), url("../svg/haikei_green.svg"), url("../svg/haikei_Yellow.svg");
    background-repeat: no-repeat, no-repeat, no-repeat;
    /* 青だけ縦位置を下げる（緑は右の値のまま）／黄は右から */
    background-position: left 62%, right 28%, right 90%;
    background-size: 42%, 42%, 60%;
    z-index: -1;
    pointer-events: none;
}

#menu {
    padding: 20px 5%;
    box-sizing: border-box;
    max-width: 100%;
    margin: 0 auto;
    font-family: "Helvetica Neue", Arial, sans-serif;
    line-height: 1.7;
}

/* 診療案内タイトル */
#menu h2 {
    text-align: center;
    color: #79AD70;
    font-size: 2rem;
    margin: 20px 0 30px;
    position: relative;
    padding-bottom: 10px;
}

/* 胃カメラページのメインタイトル（大見出し） */
.menu-page-title {
    font-size: 2.2rem;
    text-align: center;
    letter-spacing: 0.08em;
    margin: 10px auto 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.6rem;
    width: 100%;
    max-width: 760px;
    position: relative;
    z-index: 2;
}

.menu-page-title img {
    width: 10rem;
    height: auto;
}

/* 各カード：左右の空間の中で白背景を際立たせる */

.menu div {
    border-radius: 12px;
    margin-bottom: 25px;
    padding: 20px;
}

/* 1枚目カード：角丸div内だとSVGが切れるため、角丸なしの外枠（背景は section.menu::before に統一） */
.menu-inner>.menu-first-card {
    position: relative;
    overflow: visible;
    margin-bottom: 25px;
    padding: 0;
    border-radius: 0;
    background: none;
    box-shadow: none;
}

.menu-first-card>div {
    margin-bottom: 0;
}

/* 各画像の共通サイズ設定
*/


div img[src*="iakamera"],
div img[src*="senjyo"] {

    width: 40%;
    height: auto;
    border-radius: 12px;
    object-fit: contain;
    margin-bottom: 0;
}

/* 胃カメラ・洗浄機のカードを横並びに */
.menu-first-card>div,
.menu-inner>div:nth-of-type(2) {
    display: grid;
    align-items: end;
    gap: 20px;
    padding: 20px;
    grid-template-columns: 40% 60%;
    grid-template-rows: auto 1fr;
}

.menu-first-card>div p,
.menu-inner>div:nth-of-type(2) p {
    font-size: 1.2rem;
    line-height: 1.8;
}

/* タイトル（h3）：特徴などと同じく本文色＋破線下線 */
.menu-first-card>div h3,
.menu-inner>div:nth-of-type(2) h3 {
    font-size: 1.4rem;
    margin: 0 0 14px;
    color: inherit;
    border-bottom: 1px dashed currentColor;
    padding-bottom: 0.45em;
}

/* 写真は元のサイズ（40%）のまま、右側（または左側）にタイトルp＋説明pを縦に並べる */
.menu-first-card>div img {
    grid-column: 1;
    grid-row: 1 / -1;
    width: 100%;
}

.menu-first-card>div p {
    margin: 0;
    grid-column: 2;
}

.menu-first-card>div h3 {
    grid-column: 2;
    grid-row: 1;
    align-self: start;
}

.menu-first-card>div p:last-of-type {
    grid-row: 2;
    align-self: end;
}

.menu-inner>div:nth-of-type(2) {
    grid-template-columns: 60% 40%;
}

.menu-inner>div:nth-of-type(2) img {
    grid-column: 2;
    grid-row: 1 / -1;
    width: 100%;
}

.menu-inner>div:nth-of-type(2) p {
    margin: 0;
    grid-column: 1;
}

.menu-inner>div:nth-of-type(2) h3 {
    grid-column: 1;
    grid-row: 1;
    align-self: start;
}

.menu-inner>div:nth-of-type(2) p:last-of-type {
    grid-row: 2;
    align-self: end;
}

/* 診療内容（特徴・症例・注意点）カードの見出し/本文を統一 */
.menu-inner>div:nth-of-type(n+3) h3 {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0 0 14px;
    color: inherit;
    letter-spacing: 0.02em;
    border-bottom: 1px dashed currentColor;
    padding-bottom: 0.45em;
}

.menu-inner>div:nth-of-type(n+3) p {
    margin: 0;
    font-size: 1.1rem;
    line-height: 1.85;
}

.menu-inner>div:nth-of-type(n+3) p strong {
    font-size: 2rem;
    display: inline-block;
    margin-bottom: 6px;
}

/* 検査前の注意点：前夜・当日を横並び */
.menu-inner>div:nth-of-type(5) {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: flex-start;
}

.menu-inner>div:nth-of-type(5) h3 {
    width: 100%;
}

.menu-inner>div:nth-of-type(5) p {
    flex: 1;
    min-width: 220px;
    background-color: #DDEAEB;
    border-radius: 12px;
    padding: 14px 16px;
}

/* 前夜・当日の見出しの後ろに月・太陽のマーク */
.menu-inner>div:nth-of-type(5) p:first-of-type strong::after {
    content: " \2605";
    margin-left: 0.2em;
    font-weight: 400;
    font-size: 0.95em;
}

.menu-inner>div:nth-of-type(5) p:last-of-type strong::after {
    content: " \2600";
    margin-left: 0.2em;
    font-weight: 400;
    font-size: 0.95em;
}

/* 診療案内ボタン＋上のマスコット */
.menu .shinryouannai-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 8px;
    margin-bottom: 0;
    padding: 0;
    border-radius: 0;
    background-color: transparent;
}

.shinryouannai-bird {
    width: clamp(72px, 22vw, 120px);
    height: auto;
    display: block;
    margin-bottom: -6px;
    pointer-events: none;
    user-select: none;
}

/* 診療案内ボタンの基本スタイル */
.shinryouannai {
    text-align: center;
    margin: 0;
}

.shinryouannai a {
    display: inline-flex;
    /* inline-block からこれに変更 */
    align-items: center;
    /* 縦の中央 */
    justify-content: center;
    /* 横の中央 */

    background-color: #79AD70;
    color: #fff;
    padding: 10px 55px;
    border-radius: 30px;
    transition: 0.3s;
    text-decoration: none;
    line-height: 1;
}

.shinryouannai a:hover {
    background-color: #9AD37F;
    transform: translateY(-2px);
}

/* ボタン〜フッター間を詰める（このCSSは胃カメラページのみ読み込み） */
.footer {
    margin-top: 24px;
}



/* =============================================

   3. PC版レイアウト（1200px以上）

   ============================================= */

@media (min-width: 1200px) {

    /* style.css の .news::before PC調整と同様 */
    section.menu::before {
        background-size: 20%, 20%, 30%;
        background-position: left 900px, right 460px, right 1300px;
        height: 2600px;
    }

    /* h2 は section 直下で全幅。本文のみ .menu-inner で max-width（背景は section.menu::before のまま） */
    /* 1 列でモバイル同様に縦積み（胃カメラ／洗浄機を横並びにしない） */
    .menu-inner {
        display: grid;
        grid-template-columns: 1fr;
        gap: 40px;
        max-width: 1000px;
        margin-left: auto;
        margin-right: auto;
        padding-left: 5%;
        padding-right: 5%;
        box-sizing: border-box;
    }

    .breadcrumb {
        padding-top: 300px;
        padding-bottom: 20px;
        padding-left: 5%;
        padding-right: 5%;
    }

    .breadcrumb ul {
        font-size: 0.9rem;
        margin-left: 0;
    }

    #menu {
        max-width: none;
        padding: 40px 0;
    }

    #menu h2 {
        font-size: 2.2rem;
        margin-bottom: 50px;
    }

    /* カード内の並びはベース（モバイル）と同じ。余白だけ少し広げる */
    .menu-first-card>div,
    .menu-inner>div:nth-of-type(2) {
        gap: 20px;
        padding: 30px;
    }

    .menu-first-card>div img,
    .menu-inner>div:nth-of-type(2) img {
        width: 100%;
        border-radius: 12px;
        object-fit: contain;
    }

    .footer-logo-area,
    .footer-main,
    .footer-tel,
    .copyright {
        width: 100%;
        max-width: 1000px;
        margin-left: auto;
        margin-right: auto;
        padding-left: 0;
        padding-right: 0;
    }

    .footer-main {
        margin-top: 40px;
        margin-bottom: 60px;
    }

    .footer-nav {
        flex: 1;
    }

    .footer-nav ul {
        display: grid;
        grid-template-columns: repeat(3, max-content);
        justify-content: start;
        gap: 28px 40px;
    }

    .footer-nav li {
        white-space: nowrap;
    }
}

@media (max-width: 1199px) {

    .menu p,
    .menu li,
    .menu th,
    .menu td,
    .menu a,
    .menu span,
    .menu strong,
    .menu em,
    .menu b,
    .menu label {
        font-size: 2rem;
    }

    .breadcrumb ul {
        font-size: max(2rem, 1rem);
    }

    .breadcrumb ul li:not(:last-child)::after {
        font-size: max(2rem, 1rem);
    }

    .menu-first-card>div p,
    .menu-inner>div:nth-of-type(2) p,
    .menu-inner>div:nth-of-type(n+3) p,
    #kinen>div p,
    #okusuri>div:first-child p,
    #kenshin>div p {
        font-size: 2rem;
    }

    .menu-first-card>div h3,
    .menu-inner>div:nth-of-type(2) h3,
    .menu-inner>div:nth-of-type(n+3) h3,
    #kenshin>div h3 {
        font-size: max(2rem, 1.6rem);
    }
}