/* ============================================
   BUSINESS PAGE STYLES
   ============================================ */

/* Common Container */
.business-page-container {
    width: 80%;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 768px) {
    .business-page-container {
        width: calc(90% - 13px);
        margin: 0 auto;
    }
}

/* ============================================
   BUSINESS HERO SECTION
   ============================================ */
.business-hero {
    margin-top: var(--header-height);
    position: relative;
    background: var(--white);
    /* padding: 80px 0 60px; */
    overflow: hidden;
}

@media (min-width: 769px) {
    .business-hero {
        margin-top: calc(var(--header-height) + var(--border-frame) + 50px);
    }
}

/* Hero Header (Title + Catchphrase + Background Image) */
.business-hero-header {
    position: relative;
    height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin-bottom: 60px;
}

.business-hero-title {
    margin-bottom: 30px;
    position: relative;
    z-index: 1;
}

.business-hero-catchphrase {
    margin-bottom: 0;
    position: relative;
    z-index: 1;
    color: var(--white);
    text-shadow: -1px -1px 0 var(--navy), 1px -1px 0 var(--navy), -1px 1px 0 var(--navy), 1px 1px 0 var(--navy);
}

/* Hero Background Image - inside hero-header, from 30% left to right edge */
.business-hero-image {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 30%;
    right: calc(-10vw - 10%); /* extend beyond container to viewport edge */
    z-index: 0;
}

.business-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left center;
}

/* Challenge Bubbles */
.business-challenges {
    position: relative;
    min-height: 500px;
    margin-bottom: 60px;
    transform: translateY(-22%);
        max-width: 1040px;
    margin: auto;
}

.challenge-item {
    position: absolute;
    z-index: 1;
    /* width: 42%; */
}

.challenge-bubble {
    background: var(--navy);
    color: var(--white);
    padding:28px 40px;
    border-radius: 20px;
    position: relative;
    font-size: 14px;
    line-height: 1.6;
    text-align: center;
}
.challenge-bubble p {
        display: inline-block;
        font-size:22px;
}

.challenge-bubble::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 30px;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 15px solid var(--navy);
}
.challenge-item:nth-child(even) .challenge-bubble {
    background: var(--gray-light2);
    
}

.challenge-item:nth-child(even) .challenge-bubble::after {
    border-top: 15px solid var(--gray-light2);
}

/* 各吹き出しの位置 */
.challenge-item-1 {
    top: 0;
    right: 20%;
}

.challenge-item-2 {
    top: 75px;
    left: 0;
}

.challenge-item-3 {
        top: 200px;
    left: 10%;
}

.challenge-item-4 {
        top: 350px;
    right: 10%;
}

.challenge-item-5 {
    top: 445px;
    left: 5%;
}

/* Business Icons */
.business-icons.service-icons {
    gap: 10px;
    max-width: 295px;
    margin-bottom: 30px;
}
.business-icons.service-icons .service-icon::before {
    content:none;
}
.business-icons.service-icons .service-icon {
        width: 63px;
    height: 104px;
    gap: 0px;
}


/* ============================================
   CASE STUDY SECTION
   ============================================ */
.case-study-section {
    background: var(--white);
    padding: 100px 0 0;
}

.case-study-title {
    margin-bottom: 60px;
}

/* Case Study Item */
.case-study-item {
    margin-bottom: 80px;
}

.case-study-item-title {
    margin-bottom: 30px;
}

.case-study-content {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.case-study-text {
    flex: 1 1 55%;
}

.case-study-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.case-study-list li {
    list-style: none;
    /* font-size: 14px; */
    line-height: 2;
    color: var(--gray-dark);
    /* padding-left: 1em; */
    position: relative;
}

/* .case-study-list li::before {
    content: '・';
    position: absolute;
    left: 0;
} */

.case-study-image {
    flex: 1 1 45%;
    /* max-width: 400px; */
}

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

/* ============================================
   BUSINESS SERVICES
   ============================================ */
.business-services {
    margin-bottom: 100px;
    box-shadow: 10px 10px 10px rgba(0, 0, 0, 0.2);
    padding: 90px 40px;
}

.business-services-title {
    margin-bottom: 20px;
}

.business-services-intro {
    margin-bottom: 80px;
    line-height: 1.8;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.service-card {
    display: flex;
    /* flex-direction: column; */
    align-items:center;
    gap: 15px;
}

.service-card-icon {
    /* width: 80px; */
    /* height: 80px; */
    flex: 0 1 160px;
}

.service-card-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.service-card-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--navy);
}

.service-card-desc {
    line-height: 1.8;
    color: var(--gray-dark);
}

/* ============================================
   SOLUTION GUIDE
   ============================================ */
.solution-guide {
    /* margin-bottom: 100px; */
    background: var(--gray-light3);
    padding: 120px 0 240px;
}

.solution-guide-title {
    font-size: 58px;
    margin-bottom: 40px;
    margin-bottom: 120px;
    color: var(--white);
    text-shadow: -1px -1px 0 var(--navy), 1px -1px 0 var(--navy), -1px 1px 0 var(--navy), 1px 1px 0 var(--navy);
}

.solution-categories {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-top: -120px;
}

.solution-category {
        margin-top: 120px;
    }
.solution-category-title {
   
    margin-bottom: 15px;
}

.solution-category-image {
    width: 100%;
    aspect-ratio: 8 / 5;
    background: #f0f0f0;
    overflow: hidden;
}

.solution-category-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
}

@media (max-width: 768px){
    .solution-guide {
        margin-bottom:0;
    }
    .solution-guide-title {
    font-size: 22px;
    padding-bottom: 40px;
    }
    .solution-category {
        margin-top: 40px;
    }
    .solution-category-title {
   
        margin-bottom: 5px;
    }
    .solution-guide {
        padding-bottom: 120px;
    }
}
/* ============================================
   BEST PARTNER SECTION
   ============================================ */
.best-partner-section {
    background: var(--white);
    padding: 100px 0;
}

.best-partner-content {
    display: flex;
    gap: 60px;
    align-items: flex-start;
    margin-bottom: 80px;
}

.best-partner-text {
    flex: 1 1 55%;
}

.best-partner-title {
    margin-bottom: 90px;
}

.best-partner-description p {
    line-height: 2;
    margin-bottom: 20px;
}

.best-partner-description p:last-child {
    margin-bottom: 0;
}

.best-partner-image {
    flex: 1 1 45%;
    /* max-width: 400px; */
    position: relative;
}

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

/* .best-partner-label {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    font-style: italic;
    color: var(--navy);
    font-family: 'Raleway', sans-serif;
} */



/* ============================================
   GALLERY SECTION
   ============================================ */
.gallery-section {
    background: var(--navy);
    padding: 120px 0;
}

.gallery-section-inner {
        width: calc(90% - 20px);
    margin-left: auto;
    margin-right: 20px;
}

.gallery-title {
    color: var(--white);
    margin-bottom: 80px;
}

/* Business Gallery (shared style from home.php) */
.gallery-section .business-gallery-wrapper {
    position: relative;
    opacity: 1;
    transform: none;
}

.gallery-section .business-gallery {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding-left: 0;
    padding-right: 90%;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-snap-type: x mandatory;
}

.gallery-section .business-gallery::-webkit-scrollbar {
    display: none;
}

/* Gallery Row - 縦に並ぶスライダー */
.gallery-row {
    margin-bottom: 80px;
    position: relative;
}

.gallery-row:last-child {
    margin-bottom: 0;
}

.gallery-row-header {
    /* display: flex;
    align-items: flex-end; */
    gap: 15px;
    margin-bottom: 0;
    padding-left: 0;
    position: relative;
    z-index: 10;
    transform: translateY(40%) translateX(50px);
    width: 60%;
}
.gallery-row-header > span {
    display: inline-block;
    vertical-align: top;
}

.gallery-row-number {
    font-family: "Roboto Condensed", sans-serif;
    font-optical-sizing: auto;
    font-weight: 700;
    font-size: 90px;
    color: #fff;
    line-height: 0.8;
    /* font-family: "Big Shoulders Inline", sans-serif; */
    text-shadow:
        -1px -1px 0 #000,
        1px -1px 0 #000,
        -1px 1px 0 #000,
        1px 1px 0 #000;
    /* transform: translateY(30%) scaleX(0.93); */
    transform:  scaleX(0.93);
    position: relative;
    /* margin-right: -40px; */
}

.gallery-row-title {
    color: var(--white);
    padding-left: 15px;
    /* transform: translateY(-40%); */
    margin-bottom: 0;
}

.gallery-row-wrapper {
    position: relative;
    margin-bottom: 15px;
    padding-left: 40px;
}

.gallery-row-slider {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding-right: 90%;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-snap-type: x mandatory;
}

.gallery-row-slider::-webkit-scrollbar {
    display: none;
}

/* ドラッグ中のスタイル */
.gallery-row-slider.dragging {
    scroll-behavior: auto;
    scroll-snap-type: none;
    user-select: none;
}

.gallery-row-slider.dragging * {
    pointer-events: none;
}

/* .gallery-row-slider .gallery-item {
    flex-shrink: 0;
    width: auto;
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
}

.gallery-row-slider .gallery-item img {
    height: 400px;
    width: auto;
    max-width: none;
    display: block;
} */

.gallery-item-caption {
    /* font-size: 12px; */
    color: var(--white);
    margin: 8px 0 0 0;
    /* opacity: 0.8; */
}

.gallery-row-caption {
    font-size: 14px;
    color: var(--white);
    margin: 0;
}

/* Gallery Navigation */
.gallery-row .gallery-nav {
    position: absolute;
    top: -50px;
    right: 0;
    display: flex;
    gap: 10px;
}

.gallery-row .gallery-nav button {
    pointer-events: auto;
    background: transparent;
    border: none;
    width: 120px;
    height: 40px;
    cursor: pointer;
    position: relative;
    transition: opacity 0.3s;
    flex-shrink: 0;
}

.gallery-row .gallery-nav button:hover {
    opacity: 0.7;
}

.gallery-row .gallery-nav button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* 左矢印 - 水平線 */
.gallery-row .gallery-prev::before {
    content: '';
    position: absolute;
    width: 110px;
    height: 1px;
    background: var(--white);
    left: 0;
    top: 50%;
    transform: translateY(-50%);
}

/* 左矢印 - 斜め線 */
.gallery-row .gallery-prev::after {
    content: '';
    position: absolute;
    width: 12px;
    height: 1px;
    background: var(--white);
    left: 0;
    top: 50%;
    transform: translateY(-50%) rotate(-45deg);
    transform-origin: left center;
}

/* 右矢印 - 水平線 */
.gallery-row .gallery-next::before {
    content: '';
    position: absolute;
    width: 110px;
    height: 1px;
    background: var(--white);
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

/* 右矢印 - 斜め線 */
.gallery-row .gallery-next::after {
    content: '';
    position: absolute;
    width: 12px;
    height: 1px;
    background: var(--white);
    right: 0;
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
    transform-origin: right center;
}

/* Gallery Item Block */
.gallery-item-block {
    margin-bottom: 100px;
    position: relative;
}

.gallery-item-block:last-child {
    margin-bottom: 0;
}

.gallery-item-number {
    width: 100px;
    height: 120px;
    position: absolute;
    left: 0;
    top: 0;
    z-index: 2;
    transform: translate(-20px, 20px);
}

.gallery-item-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--white);
    margin-bottom: 20px;
    padding-left: 100px;
}

.gallery-images {
    display: flex;
    gap: 20px;
}

.gallery-image-main {
    flex: 1;
    aspect-ratio: 4/3;
    background: #00e6d3;
}

.gallery-image-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-image-sub {
    flex: 1;
    aspect-ratio: 4/3;
    background: #00e6d3;
}

.gallery-image-sub img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-caption {
    color: var(--white);
    margin-top: 15px;
}


/* ============================================
   RESPONSIVE - Business Page
   ============================================ */
   @media (max-width: 1000px) and (min-width: 768px) {
    .case-study-content {
        
        flex-direction: column;
        gap: 30px;
    }
   }
@media (max-width: 768px) {
    .business-hero {
        margin-top: 45px;
        padding: var(--header-height)  0 0px;
    }

    .business-challenges {
        position: relative;
        min-height: auto;
        display: flex;
        flex-direction: column;
            gap: 20px;
            margin-bottom: 0px;
    }

    

    .challenge-item {
        position: relative;
        top: auto !important;
        left: auto !important;
        right: auto !important;
        width: 90%;
    }
    .challenge-item:nth-child(even) {
                margin-right: 0;
        margin-left: auto;
    }
    .challenge-item:nth-child(even) .challenge-bubble::after{
        right: 30px;
        left: auto;
    }
    .challenge-bubble {
        font-size: 13px;
        padding: 12px 20px;
    }
.challenge-bubble p {
        font-size: 16px;
    }
    .business-hero-header {
        height: auto;
        margin-bottom: 30px;
    }

    .business-hero-image {
        position: relative;
        width: 100%;
        height: 200px;
        left: auto;
        right: auto;
        margin-top: 20px;
    }

    .business-hero-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center center;
    }

    .business-icons {
        flex-wrap: wrap;
        gap: 20px;
    }

    .business-icon-item img {
        width: 50px;
        height: 50px;
    }

    .case-study-section {
        padding: 20px 0;
    }

    .case-study-content {
        flex-direction: column;
        gap: 30px;
    }

    .case-study-image {
        max-width: 100%;
    }
    .business-services {
        padding: 0px;
        box-shadow: none;
    }

    .service-card  {
        
        flex-direction: column;
    }
    .services-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .service-card-icon img  {
        
    width: 70%;
    margin: auto;
    }
    .solution-categories {
        /* grid-template-columns: 1fr; */
        gap: 10px;
    }

    .best-partner-section {
        padding: 60px 0;
    }

    .best-partner-content {
        flex-direction: column;
        gap: 40px;
    }

    .best-partner-image {
        max-width: 100%;
    }

    

    .gallery-section {
        padding: 60px 20px;
        overflow-x: hidden;
    }

    .gallery-title {
        margin-bottom: 60px;
    }
    .gallery-section-inner {
        width: calc(90% + 7px);
        /* width: 100%; */
        /* overflow:hidden; */
    }

    .gallery-section .business-gallery {
        padding-left: 0;
        padding-right: calc(100vw - 20px);
    }

    .gallery-row {
        margin-bottom: 0px;
    }
    .gallery-row-header {
        
    transform:  translateY(40%) translateX(18px);
    }
    .gallery-row-number {
        font-size: 50px;
        margin-right: -25px;
        /* margin-bottom: -20px; */
    }

    .gallery-row-title {
        font-size: 12px;
        /* padding-bottom: 30px; */
        padding-left: 20px;
    }

    .gallery-row-wrapper {
        padding-left: 0px;/*25px;*/
    }

    .gallery-row-slider {
        padding-right: calc(100vw - 20px);
        padding-left: 20px;
    }

    /* .gallery-row-slider .gallery-item img {
        height: 250px;
    } */

    .gallery-item-caption {
        /* font-size: 11px; */
    }

    .gallery-row .gallery-nav {
        display: none;
    }
}

/* ============================================
   ANIMATIONS
   ============================================ */

/* Challenge Bubbles Fade In */
.challenge-item {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.challenge-item.fade-in {
    opacity: 1;
    transform: translateY(0);
}

/* Service Cards Fade In */
.service-card {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.service-card.fade-in {
    opacity: 1;
    transform: translateY(0);
}

/* Solution Categories Fade In */
.solution-category {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.solution-category.fade-in {
    opacity: 1;
    transform: translateY(0);
}

/* Gallery Items Slide In */
.gallery-item-block {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.gallery-item-block.slide-in {
    opacity: 1;
    transform: translateX(0);
}
