@charset "UTF-8";

/* ====================================================
　　汎用
====================================================*/
* {
    box-sizing: border-box;
    font-family: "Yu Mincho", "Hiragino Mincho ProN",
        Meiryo, "Yu Gothic", "Arial", sans-serif;
}

header {
    width: 100%;
    background: #ffffff;
}

body,
html {
    margin: 0;
    padding: 0;
}

/* ====================================================
　　個別
====================================================*/
#header {
    background: #ffffff;
}

#header .logo {
    display: inline-block;
    width: 20%;
}

#header .logo img {
    width: 60%;
}

.wrap h2 {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 0;
}

.company-name {
    text-align: center;
}

.company-prefix {
    font-size: 1em;
    display: block;
}

.company-title {
    font-size: 1.8em;
    font-weight: bold;
    display: block;
}

#header .nav li a {
    padding: 15px;
    color: #333;
}

@media screen and (min-width: 641px) {
    #header .logo {
        padding: 10px 0;
    }

    #header .wrap {
        padding: 20px 0;
        display: -webkit-box;
        display: -webkit-flex;
        display: -ms-flexbox;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    #header .cont {
        display: -webkit-box;
        display: -webkit-flex;
        display: -ms-flexbox;
        display: flex;
        flex-direction: row-reverse;
        align-items: center;
    }

    #header .nav {
        display: inline-block;
    }

    #header .nav li {
        display: inline-block;
    }

    #header .nav li a {
        color: #333;
        text-decoration: none;
    }

    #header .nav li a:hover {
        color: #17a50a;
    }
}

@media only screen and (max-width: 640px) {
    #header {
        padding: 20px 0 0;
    }

    #header .inner-block {
        padding: 0;
    }

    #header .logo img,
    #header .logo {
        display: block;
        margin: 0 auto 20px;
        width: 80%;
    }

    #header .nav {
        padding-left: 0px;
    }

    #header .nav li {
        border-top: 1px solid #555;
        list-style: none;
    }

    #header .nav li a {
        padding: 12px;
        display: block;
        background-size: 5px auto;
        text-decoration: none;
    }

    #header .nav li:last-child {
        border-bottom: 1px solid #555;
    }
}

/* ヒーロー */
.video-wrapper {
    width: 100%;
    aspect-ratio: 16 / 9;
    position: relative;
    overflow: hidden;
}


.hero {
    width: 100%;
    height: 100%;
    position: relative;
}

.hero video,
.hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
}

.hero img {
    display: none;
}

/* 追加：動画が終わったら画像に切り替える場合 */
#heroVideo:ended+#backImage {
    display: block;
}

/* パララックス */
.mission {
    margin: 5%;
}

.mission h1 {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 10vh;
}

/* パララックス背景（PC表示） */
.parallax-bg {
    height: 100vh;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

/* スマホ表示では通常のスクロールに */
@media (max-width: 768px) {
    .parallax-bg {
        background-attachment: scroll;
        height: 60vh;
        /* 必要に応じて調整 */
    }
}

/* 基本レイアウト */
.paralax-a,
.paralax-b {
    display: table;
    width: 100%;
    margin: 0;
    padding: 0;
}

.split-item {
    display: table-cell;
    width: 50%;
    vertical-align: middle;
}

/* 比率維持用 */
.ratio-box {
    position: relative;
    width: 100%;
    padding-top: 75%;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

/* テキストエリアの調整 */
.right-inner1,
.left-inner2 {
    position: static;
    width: 100%;
    height: auto;
}

.right-paralax1 h3,
.left-paralax2 h3 {
    margin: 0;
    padding: 0 5vw;
}

/* ===== レスポンシブ対応 ===== */
@media only screen and (max-width: 640px) {

    .paralax-a,
    .paralax-b {
        display: flex;
        flex-direction: column;
    }

    .split-item {
        display: block;
        width: 100%;
    }

    /* 表示順制御 */
    .paralax-a .left-paralax1 {
        order: 1;
    }

    .paralax-a .right-paralax1 {
        order: 2;
    }

    .paralax-b .right-paralax2 {
        order: 1;
    }

    .paralax-b .left-paralax2 {
        order: 2;
    }

    /* スマホ時画面幅横幅分 */
    .left-paralax1,
    .right-paralax2 {
        background-size: cover;
        width: 100%;
        aspect-ratio: 4 / 3;
    }

    /* テキスト上下余白調整 */
    .right-inner1,
    .left-inner2 {
        padding: 1rem 0;
    }
}

/* フッター */
footer p {
    background-color: #17a50a;
    color: #ffffff;
    text-align: center;
    margin: 0;
    padding: 1em 0;
}

/* ====================================================
　　会社概要
====================================================*/
table {
    width: 50%;
    border-collapse: collapse;
    margin: 5vh;
}

@media only screen and (max-width: 640px) {
    table {
        width: 90%;
        border-collapse: collapse;
        margin-left: auto;
        margin-right: auto;
        font-size: small;
    }
}

table tr {
    border-bottom: solid 2px white;
}

table tr:last-child {
    border-bottom: none;
}

table th {
    position: relative;
    text-align: left;
    width: 30%;
    background-color: #17a50a;
    color: white;
    text-align: center;
    padding: 10px 0;
}

table td {
    text-align: left;
    width: 70%;
    background-color: #eee;
    padding: 10px 0;
    padding-left: 5%;
}

.flex-container {
    display: flex;
    align-items: flex-start;
}

.building-img,
.map {
    margin: 5vh;
}

iframe {
    width: 600px;
    height: 300px;
    border: 0;
}

@media (max-width: 600px) {
    .flex-container {
        flex-direction: column;
        align-items: center;
    }

    iframe {
        width: 100%;
        height: 300px;
    }
}