/* ========================================
   ファーストビュー
======================================== */
.fv {
    position: relative;
    width: 100vw;
    max-width: 100%; /* iOS対応 */
    /* iOSのアドレスバーを考慮した高さ設定（固定） */
    height: 100vh; /* フォールバック */
    height: 100svh; /* iOS 15.4+: アドレスバー表示時の高さで固定 */
    
    display: flex;
    align-items: center;
    justify-content: center;
    /* iOS対応: overflow: hidden の代わりにclipを使用 */
    overflow: clip;
    padding-top: 0; /* padding-topを削除 */
    margin-top: 0; /* marginもゼロに */
}

/* Vegas.jsが生成するwrapper要素のスタイル */
.fv .vegas-wrapper {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    overflow: hidden !important;
    z-index: 0 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

/* Vegas.jsの画像の上にオーバーレイをかける */
.fv .vegas-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.125) 0%, rgba(0, 0, 0, 0.125) 100%);
    z-index: 1;
    pointer-events: none;
}

/* Vegas.jsが生成するスライド要素 */
.fv .vegas-slide {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
}

/* Vegas.jsが生成する画像要素 */
.fv .vegas-slide-inner {
    background-position: center center !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
}

@media (min-width: 576px) {
    .fv {
        /* padding-topを削除済み */
    }
}

@media (min-width: 1080px) {
    .fv {
        /* padding-topを削除済み */
    }
}

/* コンテンツコンテナ */
.fv__content {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

/* キャッチフレーズ */
.fv__catchphrase {
    color: white;
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 700;
    text-align: center;
    letter-spacing: 1.2px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    font-size: 2.25rem;
    line-height: var(--heading-line-height);
}

@media (max-width: 375px) {
    .fv__catchphrase {
        font-size: 2rem;
    }
}

@media (min-width: 768px) {
    .fv__catchphrase {
        font-size: 48px;
        letter-spacing: 3px;
    }
}


@media (min-width: 1280px) {
    .fv__catchphrase {
        font-size: 56px;
        letter-spacing: 3px;
    }
}

/* ロゴ */
.fv__logo {
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.fv__logo img {
    aspect-ratio: 1 / 1;
    max-width: 320px;
    width: 100%;
    height: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

@media (min-width: 768px) {
    .fv__logo img {
        max-width: 480px;
    }
}

/* ========================================
   セクションボタンスタイル（改善版）
======================================== */
.section-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 20px 28px 20px 24px;
    /* 微細なグラデーションで立体感 */
    background: linear-gradient(180deg, #3a3a3a 0%, #2d2d2d 100%);
    color: white;
    text-decoration: none;
    /* 影で高級感 */
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: clamp(1.1rem, 2vw, 1.2rem);
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 400;
    line-height: var(--body-line-height-sp);
    letter-spacing: var(--button-letter-spacing);
    position: relative;
    overflow: hidden;
}

/* ゴールドのアクセントライン */
.section-btn::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--color-primary) 0%, transparent 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.section-btn:hover {
    background: linear-gradient(180deg, #4a4a4a 0%, #3d3d3d 100%);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transform: translateX(4px);
    opacity: 1;
}

.section-btn:hover::before {
    transform: scaleX(1);
}

.section-btn__text {
    text-align: center;
}

/* 矢印を正確に接続 */
.section-btn__arrow {
    position: relative;
    display: inline-block;
    width: 30px;
    height: 2px ;
    background: white;
    flex-shrink: 0;
    margin-left: 4px;
    align-self: flex-end;
    margin-bottom: 0.25em;
}

/* 矢印の先端 - つなぎ目を正確に */
.section-btn__arrow::after {
    content: "";
    width: 11px;
    height: 2px;
    background: white;
    position: absolute;
    top: -1px;
    right: 1px;
    transform: rotate(45deg);
    transform-origin: calc(100% - 1px) 50%;
}

/* ホバー時の矢印アニメーション */
.section-btn:hover .section-btn__arrow {
    animation: arrowSlide 0.6s ease-in-out;
}

@keyframes arrowSlide {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(4px);
    }
}

@media (min-width: 768px) {
    .section-btn {
        padding: 24px 36px 24px 32px;
        gap: 16px;
        line-height: var(--body-line-height-pc);
    }

    .section-btn__arrow {
        width: 38px;
    }

    .section-btn__arrow::after {
        width: 14px;
    }
}

/* ========================================
   ABOUT導入セクション
======================================== */
.about-intro {
    position: relative;
    background-color: rgba(255, 255, 255, 0.9);
    padding: var(--section-padding-sp);
    overflow: hidden;
}

.about-intro__background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.33) 0%, rgba(0, 0, 0, 0.33) 100%);
    background-image: url('../images/about-bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    -webkit-mask-image: url('../images/about-section-bg.svg'), linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);
    mask-image: url('../images/about-section-bg.svg'), linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);
    -webkit-mask-composite: source-in;
    mask-composite: intersect;
    -webkit-mask-size: 100% 100%, 100% 100%;
    mask-size: 100% 100%, 100% 100%;
    -webkit-mask-position: center, center;
    mask-position: center, center;
    -webkit-mask-repeat: no-repeat, no-repeat;
    mask-repeat: no-repeat, no-repeat;
    z-index: 0;
    pointer-events: none;
}

.about-intro__inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin: 0 auto;
    width: 100%;
}

/* SP版での表示順序制御（Flexboxのorder） */
.about-intro__inner .section-header {
    order: 1;
}

.about-intro__inner .about-intro__content {
    order: 2;
}

.about-intro__inner .about-intro__image-wrapper {
    order: 3;
}

.about-intro__inner .about-intro__button {
    order: 4;
}

.about-intro__image-wrapper {
    width: 100%;
}

.about-intro__image {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    max-height: 400px;
    background-image: url('../images/about-photo.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 4px 12px rgba(0, 0, 0, 0.08);
}

.about-intro__content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 24px 20px 24px 20px;
    background-color: rgba(255, 255, 255, 0.95);
    border-left: 4px solid #B8986D;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.about-intro__catchphrase {
    font-size: 24px;
    font-family: var(--font-base);
    font-weight: 450;
    letter-spacing: 1.2px;
    color: #333333;
}

.about-intro__text {
    font-size: clamp(1.1rem, 2vw, 1.2rem);
    font-family: var(--font-base);
    font-weight: 400;
    line-height: var(--body-line-height-sp);
    letter-spacing: var(--body-letter-spacing);
    color: var(--color-text);
}

.about-intro__button {
    display: flex;
    justify-content: flex-end;
}

@media (min-width: 768px) {
    .about-intro {
        padding: var(--section-padding-pc);
    }

    .about-intro__inner {
        gap: 48px;
        max-width: 1400px;
    }

    .about-intro__content {
        padding: 32px 28px 32px 28px;
    }

    .about-intro__catchphrase {
        font-size: 32px;
    }

    .about-intro__text {
        line-height: var(--body-line-height-pc);
    }

    .about-intro__button {
        justify-content: flex-end;
    }
}

/* 1280px以上: 左テキスト、右に画像 */
@media (min-width: 1280px) {
    .about-intro__inner {
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            "header header"
            "content image"
            "button button";
        gap: 48px;
        align-items: start;
    }

    .about-intro__inner .section-header-wrapper {
        grid-area: header;
        order: unset;
    }

    .about-intro__inner .about-intro__content {
        grid-area: content;
        align-self: start;
        order: unset;
    }

    .about-intro__inner .about-intro__image-wrapper {
        grid-area: image;
        order: unset;
    }

    .about-intro__inner .about-intro__button {
        grid-area: button;
        justify-self: end;
        order: unset;
    }
}

/* ========================================
   COMPANY導入セクション
======================================== */
.company-intro {
    position: relative;
    background-color: white;
    padding: var(--section-padding-sp);
    overflow: hidden;
}

.company-intro__background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/company-section-bg.svg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);
    mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);
    z-index: 0;
    pointer-events: none;
}

.company-intro__inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin: 0 auto;
    width: 100%;
}

/* SP版での表示順序制御（Flexboxのorder） */
.company-intro__inner .section-header {
    order: 1;
}

.company-intro__inner .company-intro__image-wrapper {
    order: 2;
}

.company-intro__inner .company-intro__content {
    order: 3;
}

.company-intro__inner .company-intro__button {
    order: 4;
}

.company-intro__image-wrapper {
    width: 100%;
}

.company-intro__image {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    max-height: 400px;
    background-image: url('../images/company-bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 4px 12px rgba(0, 0, 0, 0.08);
}

.company-intro__content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 24px 20px 24px 20px;
    background-color: rgba(255, 255, 255, 0.95);
    border-left: 4px solid #B8986D;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.company-intro__catchphrase {
    font-size: 24px;
    font-family: var(--font-base);
    font-weight: 450;
    letter-spacing: 1.2px;
    color: var(--color-text);
}

.company-intro__text {
    font-size: clamp(1.1rem, 2vw, 1.2rem);
    font-family: var(--font-base);
    font-weight: 400;
    line-height: var(--body-line-height-sp);
    letter-spacing: var(--body-letter-spacing);
    color: var(--color-text);
}

.company-intro__button {
    display: flex;
    justify-content: flex-start;
}

@media (min-width: 768px) {
    .company-intro {
        padding: var(--section-padding-pc);
    }

    .company-intro__inner {
        gap: 48px;
        max-width: 1400px;
    }

    .company-intro__content {
        padding: 32px 28px 32px 28px;
    }

    .company-intro__catchphrase {
        font-size: 32px;
    }

    .company-intro__text {
        line-height: var(--body-line-height-pc);
    }
}

/* 1280px以上: 左に画像、右にテキスト */
@media (min-width: 1280px) {
    .company-intro__inner {
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            ". header"
            "image content"
            "button button";
    }

    .company-intro__inner .section-header-wrapper {
        grid-area: header;
        order: unset;
    }

    .company-intro__inner .company-intro__image-wrapper {
        grid-area: image;
        order: unset;
    }

    .company-intro__inner .company-intro__content {
        grid-area: content;
        order: unset;
    }

    .company-intro__inner .company-intro__button {
        grid-area: button;
        order: unset;
    }
}

/* ========================================
   事業内容導入セクション
======================================== */
.business-intro {
    position: relative;
    background-color: white;
    padding: var(--section-padding-sp);
    overflow: hidden;
}

@media (min-width: 768px) {
    .business-intro {
        padding: var(--section-padding-pc);
    }
}

.business-intro__background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/business-section-bg.svg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);
    mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 70%, rgba(0,0,0,0) 100%);
    z-index: 0;
    pointer-events: none;
}

.business-intro__inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin: 0 auto;
    width: 100%;
}

/* SP版での表示順序制御（Flexboxのorder） */
.business-intro__inner .section-header {
    order: 1;
}

.business-intro__inner .business-intro__content {
    order: 2;
}

.business-intro__inner .business-intro__images {
    order: 3;
}

.business-intro__inner .business-intro__button {
    order: 4;
}

/* 画像エリア - SP版（縦並び） */
.business-intro__images {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

/* メイン画像（足場工事）- 縦長 */
.business-intro__image-main {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-image: url('../images/business-bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* サブ画像（土木工事）- 縦長・小さめ */
.business-intro__image-sub {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-image: url('../images/business-photo.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12), 0 4px 12px rgba(0, 0, 0, 0.08);
}

.business-intro__content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 24px 20px 24px 20px;
    background-color: rgba(255, 255, 255, 0.95);
    border-left: 4px solid #B8986D;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.business-intro__catchphrase {
    font-size: 24px;
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 450;
    letter-spacing: 1.2px;
    color: #333333;
}

.business-intro__text {
    font-size: clamp(1.1rem, 2vw, 1.2rem);
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 400;
    line-height: var(--body-line-height-sp);
    letter-spacing: 0.88px;
    color: #333333;
}

.business-intro__button {
    display: flex;
    justify-content: flex-end;
}

/* 768px～1279px: テキストの下に写真横並び */
@media (min-width: 768px) {
    .business-intro__inner {
        gap: 48px;
        max-width: 1400px;
    }

    /* 画像エリアを横並びに */
    .business-intro__images {
        flex-direction: row;
        gap: 32px;
    }

    /* メイン画像を大きめに */
    .business-intro__image-main {
        flex: 1.2;
        width: 100%;
        aspect-ratio: 3 / 4;
        max-height: 400px;
    }

    /* サブ画像を小さめに */
    .business-intro__image-sub {
        flex: 0.8;
        width: 100%;
        aspect-ratio: 3 / 4;
        max-height: 400px;
    }

    .business-intro__content {
        padding: 32px 28px 32px 28px;
    }

    .business-intro__catchphrase {
        font-size: 32px;
    }

    .business-intro__text {
        line-height: var(--body-line-height-pc);
    }

    .business-intro__button {
        justify-content: flex-end;
    }
}

/* 1280px以上: 左テキスト、右に写真横並び */
@media (min-width: 1280px) {
    .business-intro__inner {
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            "header header"
            "content images"
            "button button";
        gap: 48px;
        align-items: start;
    }

    .business-intro__inner .section-header-wrapper {
        grid-area: header;
        order: unset;
    }

    .business-intro__inner .business-intro__content {
        grid-area: content;
        align-self: start;
        order: unset;
    }

    .business-intro__inner .business-intro__images {
        grid-area: images;
        flex-direction: row;
        gap: 24px;
        height: 100%;
        order: unset;
    }

    .business-intro__inner .business-intro__button {
        grid-area: button;
        justify-self: end;
        order: unset;
    }

    /* PC版で縦長にする */
    .business-intro__image-main {
        flex: 1.1;
        width: 100%;
        aspect-ratio: 3 / 4;
    }

    .business-intro__image-sub {
        flex: 0.9;
        width: 100%;
        aspect-ratio: 3 / 4;
    }
}
