/* indexページ専用 ヘッダーのロゴ・メニューを少し小さく */
.header h1 {
    font-size: 1.0rem !important;
}

.header nav ul li a {
    font-size: 0.85rem !important;
}

.main {
    margin-bottom: 0 !important;
}

/* index全体の背景をserviceと同じ淡いベージュ色＋格子模様に */
body {
    background-color: #ffffff !important;
    background-image: url('data:image/svg+xml;utf8,<svg width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg"><rect x="0" y="0" width="8" height="8" fill="%23ffffff"/><rect x="0" y="0" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="2" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="4" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="6" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="2" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="4" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="6" y="0" width="1" height="8" fill="%23f5f5f5"/></svg>') !important;
    background-size: 8px 8px !important;
}

.section-news ol li:first-child {
    margin-top: 14px;
}

/* NEWS & TOPICS / NOTICE セクションのみ白背景（横余白込み） */
.section-news {
    position: relative;
    z-index: 0;
    padding-top: 20px;
    padding-bottom: 20px;
}

.section-news::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 100vw;
    transform: translateX(-50%);
    background-color: #fff;
    z-index: -1;
}

/* NEWS & TOPICS区切り線 */
.section-news-divider-wrapper {
    max-width: 800px;
    margin: 0 auto 0 auto;
    width: 100%;
    box-sizing: border-box;
    padding-left: 8px;
    padding-right: 8px;
}

.section-news-divider {
    border: none;
    border-top: 1.5px solid #222;
    margin: 0;
    width: 100%;
}

/* NEWS見出し直上の線だけ非表示 */
.section-news>.section-news-divider-wrapper {
    display: none;
}

/* 動画直前の区切り線だけ非表示（見た目の黒ライン対策） */
.section-service+.section-news-divider-wrapper {
    display: none;
}

.section-news ol li:nth-child(2) h3 {
    color: #005b96;
}

.section-news ol li:nth-child(2) {
    margin-top: 18px;
    margin-bottom: 14px;
}

.section-news h3 a {
    color: #005b96 !important;
}

/* section-top sp */
.section-top {
    padding-top: 30px;
}

/* スマホ画面で画像がヘッダーに隠れないように余白を広げる */
@media (max-width: 799px) {
    .main {
        margin-top: 100px !important;
    }
}

.section-top__image {
    padding-left: 8px;
    padding-right: 8px;
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    box-sizing: border-box;
    margin-bottom: 2px;
    height: auto;
}

/* 799px以上でスライド画像の最大サイズを制限 */
@media (min-width: 799px) {
    .top-slideshow img {
        max-width: 799px;
        max-height: 799px;
        width: 100%;
        height: auto;
        display: block;
        margin: 0 auto;
        object-fit: contain;
    }
}



.section-top__image-filter {
    /* overlay removed: keep element available if needed but hidden */
    display: none;
}

.section-top__image-message {
    display: none;
}

/*section-news sp*/


.section-news ol {
    list-style: none;
    margin-bottom: 8px;
}

/* .section-news ol li {
    display: none;
    color: #72acff;
} */

.section-news ol li a {
    color: #72acff;
    text-decoration: none;
}

.section-news ol li:first-child {
    display: block;
}

.section-news__category {
    color: #000;
    font-weight: 600;
}

.section-news h3 {
    font-weight: 500;
    font-size: 12px;
}

.section-news ol li {
    font-size: 0.8rem;
}


.section-news__more-link a {
    text-decoration: none;
    color: #72acff;
    font-size: 12px;
}



/* section-service sp */
.section-service {
    display: block;
    padding: 40px calc(50vw - 50%) 110px;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    background-color: #ffffff;
    background-image: url('data:image/svg+xml;utf8,<svg width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg"><rect x="0" y="0" width="8" height="8" fill="%23ffffff"/><rect x="0" y="0" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="2" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="4" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="6" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="2" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="4" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="6" y="0" width="1" height="8" fill="%23f5f5f5"/></svg>');
    background-size: 8px 8px;
}

.section-service h2 {
    margin-bottom: 40px;
}

.section-service ul {
    margin: 0 24px;
    list-style: none;
}

.section-service ul li {
    max-width: 480px;
    margin: 2px auto 0 auto;
    background-color: #d6d1c4;
    background-image: url('data:image/svg+xml;utf8,<svg width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg"><rect x="0" y="0" width="8" height="8" fill="%23d6d1c4"/><rect x="0" y="0" width="8" height="1" fill="%23b3ad9e"/><rect x="0" y="2" width="8" height="1" fill="%23b3ad9e"/><rect x="0" y="4" width="8" height="1" fill="%23b3ad9e"/><rect x="0" y="6" width="8" height="1" fill="%23b3ad9e"/><rect x="0" y="0" width="1" height="8" fill="%23b3ad9e"/><rect x="2" y="0" width="1" height="8" fill="%23b3ad9e"/><rect x="4" y="0" width="1" height="8" fill="%23b3ad9e"/><rect x="6" y="0" width="1" height="8" fill="%23b3ad9e"/></svg>');
    background-size: 8px 8px;
    margin-bottom: 40px;
    text-align: left;
    border-radius: 6px;
}

.section-service__picture {
    width: 100%;
    height: 154px;
    object-fit: cover;
    object-position: center;
    border-radius: 6px 6px 0 0;
}

.section-service__title {
    padding: 10px 20px;
    display: block;
    text-decoration: inherit;
    color: #333;
    font-size: 1.3rem;
}

.section-service__title h3 {
    display: inline;
    font-size: 1.6rem;
}

.section-service__description {
    padding: 0 20px 20px 20px;
}

.section-service__video {
    display: block;
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    padding-top: 48px;
    box-sizing: content-box;
    aspect-ratio: 16 / 9;
    background: transparent;
}

.section-service__video-wrap {
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
    padding: 0;
    background: transparent;
}

.section-service__video-embed {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    border: 0;
    background: #000;
}

@media (max-width: 1160px) {
    .section-service {
        padding-top: 32px;
        padding-bottom: 72px;
    }

    .section-service__video-wrap {
        margin-top: 0;
        padding-top: 0;
        padding-left: 12px;
        padding-right: 12px;
        box-sizing: border-box;
    }
}




/* Crossfade slideshow images placed inside .top-slideshow */
.section-top__image {
    position: relative;
    /* ensure absolutely positioned slides align */
}

.top-slideshow {
    position: absolute;
    inset: 0;
    /* top:0; right:0; bottom:0; left:0; */
    overflow: hidden;
}

/* prevent slideshow container from blocking clicks/inputs beneath it */
.top-slideshow {
    pointer-events: none;
}

/* When a slideshow is present, disable the container background image
   so slideshow images take precedence */
.section-top__image.has-slideshow {
    background-image: none !important;
}

/* slideshow area without white background - let images fill naturally */
.top-slideshow {
    z-index: 2;
}

.top-slideshow img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    object-position: 60% center;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
    will-change: opacity;
}

/* スマホ画面でのトップ画像サイズを画面全体に */
@media (max-width: 1160px) {

    .main {
        margin-top: 100px;
    }

    .section-top {
        padding-top: 30px;
    }


    .section-top__image,
    .top-slideshow {
        height: 100vh;
        max-height: 568px;
    }

    .top-slideshow img {
        height: 100vh;
        max-height: 568px;
        object-fit: cover;
        object-position: 60% center;
    }

    /* images shouldn't capture pointer events either */
    .top-slideshow img {
        pointer-events: none;
    }

    /* make each image block-level without white background */
    .top-slideshow img {
        display: block;
        z-index: 3;
    }

    .top-slideshow img.active {
        opacity: 1;
    }

    /* overlay text that appears during crossfades - moved to bottom-left */
    .top-slideshow .slideshow-overlay {
        position: absolute;
        left: 24px;
        bottom: 24px;
        /* don't stretch full inset; size to content */
        width: auto;
        height: auto;
        display: block;
        pointer-events: none;
        z-index: 4;
        font-weight: 900;
        /* half the previous desktop size */
        font-size: 4rem;
        color: #fff;
        /* thin black stroke for emphasis */
        -webkit-text-stroke: 1px #000;
        text-shadow:
            -0.6px -0.6px 0 #000,
            0.6px -0.6px 0 #000,
            -0.6px 0.6px 0 #000,
            0.6px 0.6px 0 #000;
        opacity: 0;
        transform: scale(1);
        transition: opacity 0.2s ease-in-out, transform 0.2s ease-in-out;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        text-align: left;
    }

    .top-slideshow .slideshow-overlay.visible {
        opacity: 1;
        transform: scale(1.03);
    }

    /* smaller overlay on narrower screens */
    @media (max-width: 1160px) {
        .top-slideshow .slideshow-overlay {
            /* half the previous mobile size */
            font-size: 2rem;
            letter-spacing: 0.06em;
            left: 16px;
            bottom: 16px;
        }
    }

    /* top-left variant for the first overlay text */
    .top-slideshow .slideshow-overlay.top-left {
        align-items: flex-start;
        justify-content: flex-start;
        padding: 28px;
        text-align: left;
        /* slightly smaller on desktop when top-left to avoid touching edges */
    }

    @media (min-width: 1161px) {
        .top-slideshow .slideshow-overlay.top-left {
            padding: 40px;
            font-size: 6rem;
            /* reduce when top-left so it fits neatly */
        }
    }
}

@media (min-width: 1161px) {
    .section-top__image {
        width: 799px;
        max-width: 799px;
        height: 568px;
        margin-left: auto;
        margin-right: auto;
    }

    .top-slideshow {
        height: 568px;
    }

    .top-slideshow img {
        max-width: 799px;
        width: 100%;
        height: 568px;
        margin-left: auto;
        margin-right: auto;
    }
}

/* body and header background */
body {
    background-color: #ffffff !important;
    background-image: url('data:image/svg+xml;utf8,<svg width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg"><rect x="0" y="0" width="8" height="8" fill="%23ffffff"/><rect x="0" y="0" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="2" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="4" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="6" width="8" height="1" fill="%23f5f5f5"/><rect x="0" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="2" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="4" y="0" width="1" height="8" fill="%23f5f5f5"/><rect x="6" y="0" width="1" height="8" fill="%23f5f5f5"/></svg>') !important;
    background-size: 8px 8px;
    color: #3a3a3a;
}

.header {
    background-color: #000 !important;
}

/* section-news background */
.section-news {
    background-color: transparent !important;
}

.top-slideshow {
    color: #222 !important;
}

.top-slideshow span,
.top-slideshow p,
.top-slideshow h2,
.top-slideshow h3 {
    color: #222 !important;
}