/* 文字の大きさ */

.recruit-banner {
  position: relative;
  background: linear-gradient(180deg, #FFE8C1, #F3C97E);
  padding: 20px;
  text-align: center;
  border-radius: 12px;
  font-family: sans-serif;
  font-weight: bold;
  color: #fff;
  margin: 20px auto;
  width: 80%;
  box-shadow: 0px 5px 0px #d8bf93;
  transition: .3s;
  position: relative;
  z-index: 1;
  /* box-shadow: 0 4px 8px rgba(0,0,0,0.2); */
}

.recruit-banner p {
    font-size: 35px;
    margin: 0;
    color: #ffffff;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.2);
}

.recruit-banner span {
  display: block;
  font-size: 45px;
  margin-top: 8px;
  font-weight: bold;
  color: rgba(255, 255, 255, 0.7);
}

.recruit-banner:hover {
    box-shadow: unset;
    transform: translateY(4px);
  }

.About-contents {
    display: flex;
    overflow: hidden;
    align-items: center;
    margin: 4% 2% 4% 8%;
    gap: 20px;

    position: relative;
    z-index: 3;
}

#AboutUs {
margin-top: 10%;
}

#AboutUs .left-contents {
    display: flex;
    flex-direction: column;
    gap: 40px;
}


#AboutUs #ItemTitle {
    margin-left: 0;
}

#AboutUs .title-en {
    font-size: clamp(24px, 4vw, 38px);
}

#AboutUs .title-ja {
    font-size: clamp(26px, 4vw, 40px);
}

#AboutUs .right-contents p {
    font-size: 18px;
    margin: 7% 0;
    line-height: 1.7;
}

.service-box {
    width: 80%;
    height: 280px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #ffffff;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    padding: 0 4%;
    gap: 2rem;
    position: relative;
    margin: 5% auto;
    transition-duration: .4s;
}

.number {
    width: 100%;
    display: flex;
    align-items: flex-end;
    position: absolute;
    top: -16%;
    left: 3.5%;
    gap: 18px;
    font-style: italic;
}

.service-box-last .number {
    width: 100%;
    display: flex;
    align-items: flex-end;
    position: absolute;
    top: -11%;
    left: 3.5%;
    gap: 18px;
}

.number h1 {
    font-size: 60px;
    margin: 0;
    font-weight: bold;
}

.number p {
    font-size: 30px;
    margin: 0;
    padding-bottom: 11px;
    font-weight: 600;
}

.service-text {
    flex: 1;
    min-width: 280px;
}

.service-text h2 {
    font-size: 25px;
    font-weight: bold;
    margin: 0 0;
    ;
}

.service-text p {
    font-size: 18px;
    line-height: 1.6;
    margin: 2% 0;
}

.service-text:last-child p {
    margin-bottom: 1%;
}

.service-text ul {
    margin-bottom: 2%;
}

.service-text li {
    list-style: none;
    font-size: 18px;
    line-height: 2;
    background-image: url(../../img/common/listIcon/Benefits.png);
    background-repeat: no-repeat;
    background-position: left center;
    background-size: 18px auto;
    padding-left: 30px;
}

.service-btn {
    display: flex;
}

.service-btn a {
    font-weight: bold;
    font-size: 18px;

    display: flex;
    align-items: center;
    cursor: pointer;
}

.service-btn p {
    font-size: 20px;
    font-weight: bold;
    margin: 0;
}

.service-contents-last .floating-text {
    position: absolute;
    top: 91%;
    z-index: -1;
}

.OrangeTitle {
    background: linear-gradient(180deg, #FFD8B9 0%, #FFE6B4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0 10%;
    font-size: clamp(40px, 8vw, 120px);
    font-weight: 900;
    font-stretch: expanded;
    font-style: italic;
    text-align: right;
    position: relative;
}


.ColorfulTitle {
    background: linear-gradient(180deg, #FCD9BE 0%, #FEE5B7 42%, #E4EBCD 75%, #D7EBD9 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0 10%;
    font-size: clamp(40px, 8vw, 120px);
    font-weight: 900;
    font-stretch: expanded;
    font-style: italic;
    text-align: right;
    position: relative;
}


.ColorfulTitle-right {
    background: linear-gradient(90deg, #FCD9BE 0%, #FEE5B7 42%, #E4EBCD 75%, #D7EBD9 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: clamp(40px, 8vw, 120px);
    font-weight: 900;
    font-stretch: expanded;
    margin: 0 5%;
    font-style: italic;
    text-align: left;
    position: relative;
}


#Officers {
    position: relative;
    z-index: 1;
    margin-bottom: 10%;
}

#Officers #ItemTitle {
    margin: 3% 5% 0%;
}

.officers-menu {
    padding: 0 5% 0 4%;
}

.officers-info h2 {
    font-size: 32px;
    margin: 0;
}

.officers-info span {
    font-size: 18px;
    margin: 0;
    padding-left: 15px;
}

.officers-info h1 {
    font-weight: bold;
    font-size: 32px;
    margin: 0;
}

.officer-btn {
    position: relative;
    text-align: center;
    z-index: 1;
}

.officers-message {
    font-size: clamp(12px, 2vw, 17px);
    overflow: auto;
    max-height: 300px;
    position: relative;
    z-index: 1;
    margin-top: 2%;
    width: 100%;
    max-width: 500px;
    padding-right: 4%;
    /* スクロールバーとの間に余白を確保 */
}

#Officers .floating-text {
    position: absolute;
    top: 80%;
    z-index: 0;
}

#News {
    position: relative;
    z-index: 1;
    margin-bottom: 10%;
}


.news-btn {
    display: flex;
    justify-content: center;
    text-align: center;
    z-index: 1;
    margin: 0 auto;
    width: 10%;
    padding: 1%;
    font-size: clamp(14px, 2vw, 18px);
    font-weight: bold;
    border-radius: 40px;
    cursor: pointer;
}


.news-btn.slide {
    background: #363636;
    color: #fff;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.news-btn.slide::after {
    background: #fff;
    position: absolute;
    top: 0;
    left: 0;
    content: '';
    width: 100%;
    height: 100%;
    transform: scale(0, 1);
    transform-origin: left top;
    transition: .2s cubic-bezier(0.45, 0, 0.55, 1);
    z-index: -1;
}

.news-btn.slide:hover {
    color: #363636;
}

.news-btn.slide:hover::after {
    transform: scale(1, 1);
}


#News .floating-text {
    position: absolute;
    top: 80%;
    z-index: 0;
}

.news-container {
    background-color: #ffffff;
    border-radius: 20px;
    width: 80%;
    margin: 2% auto;
    position: relative;
    z-index: 1;
}

.news-item {
    transition: background-color 0.3s ease;
    padding: 2% 4%;
    display: flex;
    justify-content: space-between;
    border-radius: 0;
}

.news-container a:first-child {
    border-radius: 20px 20px 0 0;
}

.news-container a:last-child {
    border-radius: 0 0 20px 20px;
}

.news-title {
    width: 100%;
}

.news-meta {
    display: flex;
    align-items: center;
    font-size: clamp(14px, 2vw, 16px);
    width: 300px;
}


.news-category {
    padding-left: 5%;
}

.news-divider {
    width: 1%;
    background-color: #000000;
    display: inline-block;
}

.news-text {
    font-weight: bold;
    font-size: clamp(14px, 2vw, 16px);
}

.news-link {
    display: flex;
    justify-content: center;
    align-items: center;
}

hr {
    margin: 0;
}

#Workstyle {
    margin-top: 6%;
}

#Workstyle h3 {
    margin: 0% 7%;
    font-size: 36px;
    font-weight: 600;
}

#Workstyle .left-contents img {
    width: 100%;
}

.Workstyle-text {
    width: 80%;
    font-size: clamp(14px, 2vw, 18px);
    line-height: 2;
    margin: 0 0 5% 0;
}

.Workstyle-list {
    background: #ffffff;
    border-radius: 16px;
    width: 80%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}


.Workstyle-list a {
    display: flex;
    justify-content: space-between;
    padding: 14px 24px;
    font-size: clamp(14px, 2vw, 18px);
    font-weight: bold;
    border-bottom: 1px solid #eee;
    /* transition: background 0.2s; */
}

.Workstyle-list img {
    width: 30px;
}

.Workstyle-list a:last-child {
    border-bottom: none;
}

/* 画像サイズ */


.main-image-wrapper {
    max-width: 100%;
    aspect-ratio: 1;
    margin: 0 auto;
}

.main-image {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 3;
    width: 92%;
    height: auto;
}

.fade-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 90%;
    height: auto;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.fade-slide.active {
    opacity: 1;
}


/* 後ろのオレンジ三角 */
.background-polygons {
    position: absolute;
    top: 0%;
    right: 16%;
    overflow: hidden;
    height: auto;
    z-index: 1;
    pointer-events: none;
    transform: scale(1.01);
}

.left-contents img {
    width: 85%;
}


.service-img {
    width: 280px;
    height: auto;
    border-radius: 200px;
}

.service-btn img {
    width: 30px;
    height: 30px;
    padding-left: 10px;
}


#officersIMG {
    display: flex;
    justify-content: space-evenly;
    padding: 5%;
}

#officersIMG img {
    width: 20%;
    height: auto;
}

.popup {
    display: none;
    justify-content: center;
    align-items: center;
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 5;
}


.officer-content {
    background-color: #fff;
    padding: 2%;
    border-radius: 8px;
    width: 64%;
    align-items: center;
    margin: 0 auto;
    display: flex;
}

.officer-content img {
    width: 300px;
    height: auto;
    position: relative;
    z-index: 1;
}

.close {
    position: absolute;
    font-size: 20px;
    cursor: pointer;
    z-index: 5;
    top: 10%;
    right: 15%;
    border-radius: 50%;
    background-color: #1c1e21;
    color: white;
    width: 24px;
    height: 24px;
    padding: 0.5%;
    text-align: center;
}

.sp-close {
    display: none;
}


.news-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: transparent;
}

.news-container>a:first-child .news-item {
    border-radius: 20px 20px 0 0;
}

.news-container>a:last-child .news-item {
    border-radius: 0 0 20px 20px;
}

.news-link img {
    width: 30%;
}

.Office-Polygon {
    width: 75%;
    overflow: hidden;
    clip-path: path('M0 0H552.717C708.738 0 835.217 126.48 835.217 282.5V282.5C835.217 438.52 708.738 565 552.717 565H0V0Z');
    -webkit-clip-path: path('M0 0H552.717C708.738 0 835.217 126.48 835.217 282.5V282.5C835.217 438.52 708.738 565 552.717 565H0V0Z');
    aspect-ratio: 836 / 565;

    margin-left: -8%;
}

.Office-Polygon img {
    width: 100%;
    height: auto;
    display: block;
}

#gallery {
    position: relative;
    z-index: 1;
}


.gallery-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 30px;
    margin: 10% auto;
}

.image-card img {
    width: 100%;
    height: auto;
}

/* 高さ調整の例 */
.image-card.tall {
    width: 260px;
}

.image-card.mid {
    width: 300px;
    margin-top: 5%;
}


#SNS-contents {
    position: relative;
    z-index: 4;
}

#SNS-container {
    display: flex;
    margin: 5% 5% 10%;
    gap: 5%;
}

#SP {
    display: none;
}

/* アニメーション */
.fade-image {
    position: absolute;
    top: -16%;
    left: -5%;
    transition: opacity 1s ease-in-out;
    opacity: 0;
    max-width: 100%;
    height: auto;
}

/* メイン画像フェード */
.fade-slide {
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.fade-slide.active {
    opacity: 1;
}

/* サービスボックス・役員画像・ニュース・ワークスタイルのホバー */
.service-box:hover,
.service-box-last:hover {
    transform: scale(1.03);
}

/* Popup */
.popup-trigger {
    transition: transform 0.3s ease;
    cursor: pointer;
    z-index: 3;
}

.popup-trigger:hover {
    transform: scale(1.2);
}

/* ニュース・ワークスタイルのホバー */
.news-item:hover {
    background-color: rgb(20, 20, 20);
    color: #ffffff;
}

.news-item:hover img {
    filter: invert(100%);
}

/* ワークスタイルのホバー */
.Workstyle-item:hover {
    background-color: rgb(20, 20, 20);
    color: #ffffff;
}

.Workstyle-item:hover img {
    filter: invert(100%);
}

/* ギャラリー画像 */
#gallery img {
    width: 85%;
    height: auto;
}

.gallery2,
.gallery4 {
    margin-top: 12%;
}

.gallery-list {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 20% 0 15%;
    width: max-content;
}

.gallery-list li {
    flex-shrink: 0;
    width: 25vw;
    padding: 0 0.5vw;
}

/* メディアクエリ内の三角アニメーションやギャラリー調整 */
.gallery-list {
    margin: 35% 0 20%;
}

.gallery-list li {
    width: 65vw;
}


/* 背景の動くテキスト */

.floating-text p {
    animation: animetxt 42s linear infinite;
    transform: translateX(0%);
    background: linear-gradient(100deg, #FFD8B9, #FFE6B4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    margin: 0;
    font-size: 150px;
    font-weight: bold;
    font-family: Impact, Haettenschweiler, 'Arial Narrow Bold', sans-serif;
    opacity: 0.5;
    position: relative;
    z-index: 1;
}

@keyframes animetxt {
    0% {
        transform: translateX(200%);
    }

    100% {
        transform: translateX(-100%);
    }
}

.service-box:hover {
    transform: scale(1.03);
}

.popup-trigger {
    transition: transform 0.3s ease;
    cursor: pointer;
    z-index: 3;
}

.popup-trigger:hover {
    transform: scale(1.2);
}

.news-item:hover {
    background-color: rgb(20, 20, 20);
    color: #ffffff;
}

.news-item:hover img {
    filter: invert(100%);
}

.Workstyle-item:hover {
    background-color: rgb(20, 20, 20);
    color: #ffffff;
}

.Workstyle-item:hover img {
    filter: invert(100%);
}

/* ------------------------------
   ギャラリー
------------------------------ */

#gallery img {
    width: 85%;
    height: auto;
}

.gallery2,
.gallery4 {
    margin-top: 12%;
}



@keyframes infinity-scroll-left {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }

}

.gallery-list {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 20% 0 15%;
    width: max-content;
    animation: infinity-scroll-left 60s infinite linear 0.5s both;
}

.gallery-list li {
    flex-shrink: 0;
    width: 25vw;
    padding: 0 0.5vw;
}

/* ----------------------
　　　各セクション
------------------------- */

#AboutUs,
#OurService,
#Officers,
#Workstyle,
#SNS {
    position: relative;
    z-index: 1;
}

/* スマホ対応 */

@media screen and (max-width: 768px) {
    #TopView {
        height: 55vh;
    }

    #TopView .Catchphrase {
        top: 54%;
    }

    #TopView-Text {
        top: 86%;
        left: 2%;
    }

    #TopView-Text h1 {
        font-size: 60px;
    }

    #TopView .Catchphrase p {
        font-size: 16px;
    }

    #TopView .Catchphrase h1 {
        font-size: 20px;
    }

    .Catchphrase h1 span {
        font-size: 16px;
    }

    .recruit-banner p {
        font-size: 25px;
    }

    .recruit-banner span {
        font-size: 30px;
    }

    #AboutUs .title-en {
        font-size: 30px;
    }

    #AboutUs .title-ja {
        font-size: 35px;
    }

    .About-contents {
        display: flex;
        flex-direction: column;
    }

    #AboutUs .right-contents {
        padding: 0%;
    }

    #AboutUs .left-contents {
        margin-top: 5%;
    }

    #AboutUs .right-contents p {
        font-size: 18px;
        width: 100%;
    }

    .Bbtn {
        display: flex;
        width: 50%;
        margin: 0 auto;
        justify-content: center;
        font-size: 18px;
        text-align: center;
        padding: 10px 17px;
    }

    .OrangeTitle {
        margin: 0 2%;
    }

    .service-box,
    .service-box-last {
        width: 90%;
        flex-direction: column;
    }

    .service-box {
        height: 90%;
        margin: 27% auto;
        background-color: rgba(255, 255, 255, 1);
    }

    .service-box-last {
        height: 100%;
        background-color: rgba(255, 255, 255, 1);
    }

    .service-text li {
        font-size: 17px;
    }


    .number h1 {
        font-size: 50px;
    }

    .number p {
        font-size: 26px;
        font-weight: 600;
    }

    .number {
        flex-direction: column;
        top: -14%;
        align-items: normal;
        gap: 0;
    }

    .service-box-last .number {
        flex-direction: column;
        top: -11%;
        align-items: normal;
        gap: 0;
    }

    .service-text h2 {
        font-size: 22px;
    }

    .service-text p {
        font-size: 16px;
    }

    .service-text ul {
        padding-left: 3%;
    }

    #Officers {
        margin-top: 20%;
    }

    .officers-menu {
        padding: 0;
        z-index: 1;
    }

    .officers-info h1 {
        font-size: 27px;
    }

    .officers-info span {
        font-size: 20px;
        padding-left: 0;
    }

    .officers-info h2 {
        font-size: 23px;
        display: flex;
        flex-direction: column;
    }

    .officers-message {
        font-size: 14px;
        width: 90%;
        max-height: 57%;
        position: absolute;
        top: 41%;
        left: 6%;
        overflow: auto;
        -webkit-overflow-scrolling: touch;
        /* for smooth scrolling on iOS */
    }

    .news-container {
        width: 370px;
    }

    .news-item {
        padding: 15px 10px;
    }


    .news-divider {
        margin: 0 3%;
    }

    .news-text {
        font-size: 15px;
    }

    .news-meta {
        font-size: 14px;
    }

    .news-btn {
        margin: 10% auto;
        width: 33%;
        padding: 8px 20px;
    }

    .officer-contents {
        flex-wrap: wrap;
    }

    .Workstyle-container {
        position: relative;
    }

    #Workstyle h3 {
        margin: 0% 7%;
        font-size: 25px;
    }

    .Workstyle-contents {
        flex-direction: column;
    }

    .Workstyle-contents .right-contents {
        width: 90%;
    }

    .Workstyle-text {
        font-size: 18px;
        margin-bottom: 10%;
        width: 90%;
    }

    .Workstyle-list {
        margin: 0;
        width: 100%;
    }


    .Workstyle-list a {
        padding: 10px 20px;
    }

    .Workstyle-list img {
        width: 25px;
    }

    #Workstyle {
        margin-top: 20%;
    }

    #Workstyle .left-contents img {
        margin: 10% 0 10% -10%;
    }

    #SP {
        display: block;
    }

    .main-image {
        width: 100%;
    }

    #PC {
        display: none;
    }

    #logo {
        width: 5%;
        top: 1%;
        left: 1%;
    }

    #TopView-Polygon {
        top: -37%;
        left: -7%;
    }

    #TopView-Polygon img {
        width: 130px;
    }

    #TopView-Polygon #logo {
        width: 40px;
        position: absolute;
        top: 48%;
        left: 9%
    }

    .catchphrase-bg {
        position: absolute;
        top: 38%;
        left: -5px;
    }

    .background-polygons {
        top: -21%;
        transform: scale(1);
    }

    #service-contents {
        width: 95%;
        margin: 0 auto;
    }

    .service-img {
        order: 1;
        width: 300px;
        margin-top: 12%;
    }

    .service-text {
        order: 2;
    }

    .service-btn {
        display: flex;
        align-items: center;
        margin: 4% auto;
    }

    .service-btn img {
        width: 30px;
        height: auto;
        padding-left: 12px;
    }

    #officersIMG {
        overflow-x: auto;
        white-space: nowrap;
        padding: 0;
    }

    #officersIMG img {
        width: 160px;
        margin: 5% 2%;
    }

    .officer-content {
        width: 320px;
        height: 480px;
    }

    .officer-content img {
        width: 130px;
        top: 3%;
        left: 3%;
        position: absolute;
    }

    .officers-info {
        padding: 0;
        width: 100%;
        position: absolute;
        top: 20%;
        left: 48%;
    }

    .officer-content {
        position: relative;
        z-index: 1;
        background-color: #fff;
    }

    .officer-content::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: linear-gradient(90deg, #FFD8B9 15%, #FFE6B4 100%);
        opacity: 0.5;
        z-index: 0;
        border-radius: 8px;
        pointer-events: none;
    }

    .close {
        display: none;
    }

    .sp-close {
        display: block;
        font-size: 18px;
        z-index: 5;
        border-radius: 25px;
        background-color: black;
        color: white;
        width: 20%;
        height: auto;
        padding: 5px 10px 8px;
        text-align: center;

        position: absolute;
        top: 90%;
        right: 37%;
    }

    .news-link img {
        width: 30px;
    }

    #gallery {
        margin-top: 20%;
    }

    #SNS-container {
        overflow-x: auto;
    }

    .catchphrase-bg {
        position: absolute;
        top: 53%;
        left: -1px;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.3);
        /* semi-transparent black */
        z-index: 3;
        pointer-events: none;
        clip-path: path('M0.8125 89V1.00004L390 0C390 0 392 2.5 391 9C390 15.5 354.5 89 354.5 89H0.8125Z');
        -webkit-clip-path: path('M0.8125 89V1.00004L390 0C390 0 392 2.5 391 9C390 15.5 354.5 89 354.5 89H0.8125Z');
        aspect-ratio: 392 / 89;
    }


    #AboutUs,
    #OurService,
    #Officers,
    #Workstyle,
    #News,
    #gallery,
    #SNS {
        top: 40%;
    }

    .back-ground-logo {
        display: none;
    }

    .line1 {
        top: 240%;
        left: -30%;
    }


    .line3 {
        top: -35%;
    }

    .line4 {
        top: -4%;
        left: 32%;
    }

    .line5 {
        top: 44%;
        left: 32%;
    }

    #dynamic-container4 {
        top: -25%;
    }

    .floating-text p {
        font-size: 75px;
    }

    .gallery-list {
        margin: 35% 0 20%;
    }

    .gallery-list li {
        width: 65vw;
    }

}