@charset "UTF-8";

/* ====================================================
   1. VARIABLES & RESET
   ==================================================== */
:root {
    /* Layout */
    --content-width: 1000px;
    --header-height: 72px;
    /* Defined for consistent calculation */

    /* Colors */
    --color-bg: #ffffff;
    --color-bg-gray-dark: #ebebeb;
    /* Slightly darker than typical #f8f9fa */
    --color-text: #1a1a1a;
    --color-text-sub: #4a4a4a;
    --color-line: #06C755;
    --color-accent-yellow: #FFFF00;
    /* New standard for highlight */

    /* Fonts */
    --font-en: 'Inter', sans-serif;
    --font-jp: 'Noto Sans JP', sans-serif;

    /* Animation */
    --easing: cubic-bezier(0.22, 1, 0.36, 1);
    --transition-fast: 0.3s ease;
    --section-padding: 80px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    height: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-jp);
    color: var(--color-text);
    background-color: var(--color-bg);
    line-height: 2.0;
    letter-spacing: 0.15em;
    -webkit-font-smoothing: antialiased;
    width: 100%;
    overflow-x: hidden;
    /* Prevent horizontal scroll */
}

/* LINK RESET */
a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

img {
    max-width: 100%;
    height: auto;
    vertical-align: bottom;
    /* Removes whitespace below inline-block imgs */
}


.container,
.b5-container,
.adv-container,
.flow-container,
.about-container,
.lab-container,
.footer-container,
.close-container {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal.delay-1 {
    transition-delay: 0.08s;
}

.reveal.delay-2 {
    transition-delay: 0.16s;
}

.reveal.delay-3 {
    transition-delay: 0.24s;
}

/* Section Common */
section,
.b5-section,

.image-section,
.service-page-section {
    padding-top: 80px;
    padding-bottom: 80px;
}

#about.about-hero {
    padding-bottom: 0;
}

.section-title,
.b5-header,
.adv-header,
.flow-header,
.about-header,
.lab-header {
    text-align: center;
    margin-bottom: 40px;
    margin-top: 0;
    /* Force reset */
}

.section-title h2,
.about-header h2 {
    margin: 0;
}

.section-title-img,
.b5-heading-img,
.adv-heading-img,
.flow-heading-img,
.about-heading-img,
.lab-heading-img {
    max-width: 100%;
    height: auto;
    display: inline-block;
}

/* Specific image sizes */
.b5-heading-img,
.adv-heading-img,
.lab-heading-img {
    max-width: 280px;
}

.flow-heading-img {
    max-width: 400px;
}

.about-heading-img {
    max-width: 250px;
}

.section-desc,
.adv-intro-text,
.flow-intro-text {
    text-align: center;
    margin-top: 0;
    margin-bottom: 40px;
    line-height: 1.8;
    color: var(--color-text-sub);
    font-size: 0.95rem;
    /* Standardize */
}

.section-footer-link,
.about-footer-link {
    text-align: right;
    margin-top: 20px;
    /* Reduced from 30px */
    margin-bottom: 20px;
    /* Ensure bottom spacing */
}

.section-footer-link a,
.about-footer-link a {
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-text);
    text-decoration: none;
    transition: color 0.3s;
}

.section-footer-link a:hover,
.about-footer-link a:hover {
    color: var(--color-line);
}

/* SP Center Alignment for Footer Links */
@media (max-width: 768px) {

    .section-footer-link,
    .about-footer-link {
        text-align: center;
    }
}

/* ====================================================
   3. HEADER & NAV
   ==================================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 0;
    opacity: 0;
    transform: translateY(-20px);
    height: 64px;
    display: flex;
    align-items: center;
    line-height: 1;

    /* Initial State: Transparent Black 60% (0.4 alpha) with Blur */
    background-color: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: background-color 0.3s ease, backdrop-filter 0.3s ease;
}

.site-header.loaded {
    opacity: 1;
    transform: translateY(0);
}

.site-header.scrolled {
    /* Scrolled State: Solid Black, No Blur */
    background-color: rgba(0, 0, 0, 1);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* ====================================================
   HEADER LAYOUT (Restored Flexbox)
   ==================================================== */
.header-inner {
    max-width: var(--content-width);
    margin: 0 auto;
    height: 100%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
    position: relative;
    box-sizing: border-box;
    overflow: visible;
}

/* 2. Left Column: Branding (Logo) */
.branding {
    display: flex;
    align-items: center;
    gap: 16px;
    height: 100%;
    /* 親の72pxに高さを合わせる */
    margin-right: auto;
}

/* Logo Image Override */
.logo-text {
    display: flex;
    align-items: center;
    height: 100%;
    /* 高さを100%確保 */
    text-decoration: none;
}

.logo-text img {
    height: 40px !important;
    max-height: 40px !important;
    width: auto;
    display: block;
    object-fit: contain;
    margin-top: 0;
    transform: none;
    /* Reset transform */
}

/* H1 Mini: Static position, aligned via Flexbox */
/* H1 Mini: Center column, Row 1 */
/* H1 Mini: Positioned relative to logo or absolute if preferred */
/* Restoring simple layout: placed aside logo for now or absolute if needed to keep height */
.h1-mini {
    position: absolute;
    top: 4px;
    /* Move to very top or side */
    left: 20px;
    /* Align check */
    /* Hiding or minimizing based on "compact" request logic to prioritize Logo/Nav/CTA */
    /* User said: "Logo, Global Nav, LINE Button... Restore Flex Alignment" */
    /* User also said: "H1 text... aligned to logo height" previously, but now emphasizes compact. */
    /* Best safe bet: Static next to logo, or Absolute to avoid clutter. */
    /* Let's keep it Absolute Top Left to match "previous beauty" implied */
    white-space: nowrap;
    font-size: 10px;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.8);
    pointer-events: none;
    /* Don't block logo click */
    opacity: 0.8;
}

@media (max-width: 768px) {
    .branding {
        gap: 12px;
    }

    .logo-text img {
        height: auto !important;
        width: 50% !important;
        /* Force 50% width */
        max-width: 150px !important;
        /* Safety constraint */
    }

    .h1-mini {
        position: static;
        font-size: 9px;
    }
}

/* 3. Center Column: Navigation */
/* 3. Center Column: Navigation */
.global-nav {
    flex: 1 1 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    /* Vertical Center */
    height: 100%;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 24px;
    /* Restored gap */
    margin: 0;
    padding: 0;
    align-items: center;
}

.nav-list a {
    text-decoration: none;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 500;
    white-space: nowrap;
    transition: 0.3s;
    position: relative;
    padding: 6px 6px;
    /* Reduced padding */
    line-height: 1.0;
    /* Tighter line height */
    letter-spacing: 0.03em;
}

/* 4. Right Column: CTA */
/* 4. Right Column: CTA */
.nav-actions {
    margin-left: 20px;
    height: 100%;
    display: flex;
    align-items: center;
}

/* MOBILE RESET (< 769px) */
@media (max-width: 768px) {
    .header-inner {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 0;
        padding: 0 20px;
    }

    .branding {
        display: flex;
        flex-direction: column;
    }

    .logo-text {
        display: block;
    }

    .logo-text img {
        height: 56px;
    }

    .h1-mini {
        position: static;
        font-size: 9px;
        order: -1;
        margin-bottom: 4px;
        text-align: left;
        justify-self: auto;
    }

    .global-nav {
        display: none;
    }
}

/* Mobile Responsive Adjustments */
@media (max-width: 980px) {
    .global-nav {
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        min-width: 0;
        /* Allow shrinking on mobile */
        display: none;
        /* Toggle usually handles this, specific to existing toggle script logic */
    }

    /* Existing toggle logic likely uses display:block or similar on .global-nav.active */
}

/* Legacy mobile blocks removed */

.nav-list a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-line);
    transition: width 0.3s ease;
}

.nav-list a:hover {
    color: var(--color-line);
}

.nav-list a:hover::after {
    width: 100%;
}

/* Header CTA Button */
.nav-actions {
    margin-left: 0;
    flex: 0 0 auto;
    white-space: nowrap;
}

.btn-header-line {
    display: inline-flex;
    padding: 8px 16px;
    /* Reduced from 10px 22px */
    font-size: 0.75rem;
    font-weight: 600;
    border: 1px solid #fff;
    border-radius: 4px;
    text-decoration: none;
    color: #fff;
    transition: all 0.3s ease;
}

.btn-header-line:hover {
    background: #fff;
    color: #000;
    transform: translateY(-2px);
}

/* SP Navigation Styles */
@media (max-width: 768px) {
    .h1-mini {
        font-size: 8px;
        top: -2px;
        left: 15px;
    }

    .branding {
        padding-top: 0;
    }

    .header-inner {
        padding: 0 20px;
    }

    .nav-actions {
        order: 2;
    }

    .btn-header-line {
        padding: 8px 10px;
        font-size: 0.65rem;
        white-space: nowrap;
    }

    .global-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        visibility: hidden;
        z-index: 1000;
        transition: all 0.4s ease;
    }

    .global-nav.is-open {
        right: 0;
        visibility: visible;
    }

    .nav-list {
        flex-direction: column;
        gap: 40px;
        text-align: center;
    }

    .nav-list a {
        font-size: 1.1rem;
    }
}

/* ====================================================
   4. HERO SECTION
   ==================================================== */
.hero-section {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    position: relative;
    z-index: 10;
    overflow: hidden;
    /* Fixed background (like closing CTA) */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

/* ヒーロー内のrevealもフェードインで表示 */

@media (max-width: 768px) {
    .hero-section {
        height: 100vh;
        height: 100svh;
        min-height: 100vh;
        min-height: 100svh;
        padding-bottom: 0;
        background-attachment: scroll; /* fixed は mobile でパフォーマンス劣化のため無効化 */
    }
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    overflow: hidden;
}

.hero-bg-image {
    width: 100%;
    height: 100%;
}

/* iOS: fixed attachment not supported */
@supports (-webkit-touch-callout: none) {
    .hero-section {
        background-attachment: scroll;
    }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Gradient Overlay: Darker at top/bottom - Matching ai-manager */
    background: linear-gradient(to bottom,
            rgba(0, 0, 0, 0.4) 0%,
            rgba(0, 0, 0, 0.3) 40%,
            rgba(0, 0, 0, 0.7) 100%);
    z-index: 2;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 900px;
    padding: 0 20px;
    /* メインコピーを背景画像の縦中央に配置するため調整 */
    padding-bottom: 0;
    margin-top: 160px;
    text-align: center;
}

/* AI Manager hero: vertically centered layout */
.ai-manager-page .hero-content {
    margin-top: 0;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.hero-main {
    font-size: clamp(1.8rem, 4.2vw, 2.6rem);
    /* Optimized */
    font-weight: 700;
    line-height: 1.8;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
    margin-top: 0;
    /* Reset H1 default margin */
    margin-bottom: 20px;
}

.hero-sub {
    font-size: clamp(1.0rem, 2.8vw, 1.4rem);
    /* Optimized */
    opacity: 0.9;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
    margin-top: 30px;
    /* Optimized */
    line-height: 1.6;
}

/* Dots Decoration */
.dot-accent {
    display: inline-block;
}

.dot-char {
    position: relative;
    display: inline-block;
    line-height: 1;
}

.dot-char::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: -0.4em;
    width: 0.25em;
    height: 0.25em;
    background-color: #fff;
    border-radius: 50%;
    z-index: 5;
}

@media (max-width: 768px) {
    .dot-char::before {
        top: -0.4em;
        width: 0.25em;
        height: 0.25em;
    }

    .hero-main {
        line-height: 2.2;
    }
}

/* Hero CTA */
.hero-cta {
    margin-top: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.btn-hero-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: #fff;
    font-weight: 700;
    padding: 18px 50px;
    border-radius: 50px;
    font-size: 1.2rem;
    text-decoration: none;
    transition: all 0.3s var(--easing);
    border: 2px solid #fff;
}

.btn-hero-ghost:hover {
    background: #fff;
    color: #000;
    border-color: #fff;
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.25),
        0 0 15px rgba(255, 255, 255, 0.15);
}

.hero-cta-notes {
    margin-top: 30px;
    font-size: 0.85rem;
    color: #fff;
    background: rgba(0, 0, 0, 0.4);
    padding: 12px 25px;
    border-radius: 4px;
}

/* ====================================================
   5. COMMON CAROUSEL & CARDS
   ==================================================== */
.common-carousel {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 24px;
    padding-bottom: 15px;
    /* Reduced from 20px */
}

.common-carousel::-webkit-scrollbar {
    display: none;
}

.common-card {
    flex: 0 0 calc((100% - 48px) / 3);
    /* Default PC */
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    border: 1px solid #f0f0f0;
}

/* PC Optimization: 3 Cards + Peek */
@media (min-width: 769px) {
    .common-carousel {
        padding-bottom: 20px;
        /* Reduced from 30px */
        cursor: grab;
    }

    .common-carousel:active {
        cursor: grabbing;
    }

    .common-card {
        flex: 0 0 29% !important;
        /* ~3 cards + peek */
        max-width: none !important;
    }
}

.common-card-image {
    width: 100%;
    aspect-ratio: 302 / 197;
    background: #eee;
    overflow: hidden;
}

.common-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.common-card:hover .common-card-image img {
    transform: scale(1.05);
}

.common-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.common-card-link {
    display: inline-block;
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--color-text);
    text-decoration: none;
    margin-bottom: 12px;
    line-height: 1.4;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s;
}

.common-card-link:hover {
    border-color: var(--color-line);
}

.common-card-text {
    font-size: 0.9rem;
    color: var(--color-text-sub);
    line-height: 1.7;
}

/* Indicators */
.carousel-indicators {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 30px;
}

.indicator-dot {
    width: 10px;
    height: 10px;
    background: #e5e5e5;
    border: 1px solid #ccc;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.indicator-dot.active {
    background: #000;
    width: 10px;
    /* Keep round */
}

/* SP Carousel Adjustments */
@media (max-width: 768px) {
    .common-carousel {
        gap: 16px;
        padding-left: 20px;
        /* Start Padding */
        padding-right: 20px;
        /* Peek padding */
    }

    .common-card {
        flex: 0 0 85%;
        /* Peek effect */
        max-width: 320px;
    }

    .carousel-indicators {
        margin-top: 20px;
    }
}

/* ====================================================
   6. SECTIONS CONTENT
   ==================================================== */
.main-wrapper {
    position: relative;
    z-index: 20;
    background-color: #fff;
    width: 100%;
}

/* General Spacing */
/* User Request: Reduce vertical spacing significantly (from 100px+ to ~40-60px) */
section:not(.hero-section) {
    padding-top: 40px;
    padding-bottom: 60px;
}

@media (max-width: 768px) {
    section:not(.hero-section) {
        padding-top: 20px;
        padding-bottom: 60px;
    }
}

/* --- Intro Section --- */
.intro-section {
    background-color: #fff;
    padding-bottom: 40px;
    /* Less bottom padding */
}

.service-title {
    /* Used in Intro too */
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    font-weight: 700;
    margin-bottom: 2rem;
    text-align: center;
    /* Added centering */
}

@media (max-width: 768px) {
    .service-title {
        font-size: 1rem;
    }
}

.service-body {
    font-size: 1rem;
    color: var(--color-text-sub);
    text-align: center;
    /* Updated from justify */
    max-width: 850px;
    margin: 0 auto 40px auto;
    /* Added bottom margin */
}

/* --- Image Section --- */
.image-section {
    background-color: #fff;
    padding-bottom: 40px;
}

.feature-image {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 15px 50px rgba(0, 0, 0, 0.08));
}

/* --- Challenges (B5) Section --- */
.b5-section {
    background-color: var(--color-bg-gray-dark);
}

.b5-main-title {
    font-size: clamp(1.4rem, 4vw, 2rem);
    font-weight: 700;
    line-height: 1.5;
    margin-bottom: 30px;
}

/* Unify Headers */
.b5-main-title,
.b5-solution-title {
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    font-family: var(--font-jp);
    color: var(--color-text);
}

.b5-highlight {
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    font-family: var(--font-jp);
    color: var(--color-text);
}

.b5-problems-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 20px;
}

.b5-problem-item {
    background: #000;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.05);
    color: #fff;
}

.b5-problem-summary {
    list-style: none;
    pointer-events: none;
}

.b5-problem-summary::-webkit-details-marker {
    display: none;
}

.b5-sub-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
}

.b5-sub-title::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 1.2em;
    background: var(--color-line);
    margin-right: 12px;
}

.b5-check-list {
    list-style: none;
}

.b5-check-list li {
    position: relative;
    padding-left: 28px;
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 15px;
    color: #fff;
}

.b5-check-list li::before {
    content: '〼';
    position: absolute;
    left: 0;
    color: var(--color-line);
    font-weight: bold;
}

/* Solution Area */
.b5-solution-area {
    text-align: center;
    border-top: none;
    padding-top: 0;
}

.b5-solution-title {
    font-weight: 700;
    margin-top: 20px;
    margin-bottom: 30px;
}

.b5-solution-body {
    max-width: 880px;
    margin: 0 auto;
    text-align: justify;
}

.b5-solution-body p {
    margin-bottom: 25px;
    font-size: 1rem;
    color: var(--color-text-sub);
    line-height: 2.2;
}

.b5-highlight {
    margin-top: 40px;
    text-align: center;
    display: block;
    line-height: 1.5;
}

/* Challenges Mobile Carousel */
.b5-indicators {
    display: none;
}

/* Hide on PC */

@media (max-width: 768px) {
    .b5-problems-wrapper {
        display: flex !important;
        overflow-x: auto !important;
        scroll-snap-type: x mandatory !important;
        grid-template-columns: none !important;
        gap: 20px !important;
        padding-bottom: 20px !important;
        padding-left: 20px !important;
        padding-right: 20px !important;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .b5-problems-wrapper::-webkit-scrollbar {
        display: none;
    }

    .b5-problem-item {
        flex: 0 0 85% !important;
        width: 85% !important;
        scroll-snap-align: start;
        padding: 30px;
        /* Reduced padding for SP */
    }

    .b5-problem-summary {
        padding: 0;
    }

    .b5-sub-title {
        margin-bottom: 20px;
    }

    .b5-problem-content {
        padding: 0;
    }

    /* Show indicators */
    .b5-indicators {
        display: flex;
        margin-top: 10px;
        justify-content: center;
    }

    .b5-highlight {
        font-size: clamp(1rem, 4.5vw, 1.35rem);
    }
}

/* ====================================================
   SERVICE PAGE (GRID LAYOUT)
   ==================================================== */
.service-page-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    width: 100%;
}

/* Override .common-card flex behavior when inside grid */
.service-page-grid .common-card {
    flex: auto;
    max-width: 100%;
    width: 100%;
    margin: 0;
}

/* SP: Force 3 Columns as requested (Warning: Cards will be small) */
@media (max-width: 768px) {
    .service-page-grid {
        grid-template-columns: repeat(3, 1fr);
        /* Keep 3 columns */
        gap: 10px;
        /* Compress gap */
    }

    .service-page-grid .common-card {
        border-radius: 8px;
        /* Slightly tighter radius */
    }

    .service-page-grid .common-card-body {
        padding: 10px;
        /* Reduce padding to fit content */
    }

    .service-page-grid .common-card-link {
        font-size: 0.8rem;
        /* Shrink title */
        margin-bottom: 5px;
    }

    .service-page-grid .common-card-text {
        font-size: 0.65rem;
        /* Shrink text */
        line-height: 1.4;
    }
}

/*
   SERVICE PAGE: FV & SECTIONS
   ====================================================
*/
.service-fv {
    width: 100%;
    min-height: 70vh;
    height: auto;
    /* 70% of typical hero */
    background-color: #000;
    position: relative;
    /* Centering Content using Flexbox */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    padding-top: 80px;
    /* Offset for header */
}

/* Service Intro styling inside FV */
.service-fv .section-title-img {
    margin-bottom: 30px;
}

/* Override for Page FV Height and Alignment (Reason & Service) */
.fv-short {
    min-height: 51vh;
    height: auto;
}

.fv-short .container {
    padding-top: 40px;
    /* Shift content down to create space from nav */
}

.service-main-copy {
    font-size: clamp(1.0rem, 2.5vw, 1.4rem);
    /* Smaller top line */
    font-weight: 700;
    line-height: 1.6;
    margin-bottom: 20px;
    /* Unified margin */
    color: #fff;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

.service-main-highlight {
    display: block;
    font-size: clamp(1.6rem, 4.0vw, 2.4rem);
    /* Large bottom line */
    margin-top: 10px;
    margin-bottom: 30px;
    /* Add specific bottom margin */
    line-height: 1.4;
    color: #fff;
    /* Ensure color is inherited or set */
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
    /* Ensure shadow matches */
}

.service-body-text {
    font-size: 1rem;
    line-height: 2.2;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    max-width: 800px;
    margin: 0 auto;
}

/* SP Adjustments for breaks */
.sp-only {
    display: none;
}

.pc-only {
    display: inline;
}


@media (max-width: 768px) {
    .sp-only {
        display: inline;
    }

    .pc-only {
        display: none;
    }

    .service-main-copy {
        font-size: 0.9rem;
        line-height: 1.8;
    }

    .service-main-highlight {
        font-size: 1.1rem;
        margin-top: 5px;
    }

    .service-body-text {
        font-size: 0.85rem;
        line-height: 2.0;
        padding: 0 15px;
    }
}

.service-page-section {
    padding-top: 60px;
    padding-bottom: 100px;
    background-color: #fff;
}

.service-bg-gray {
    background-color: var(--color-bg-gray-dark);
}

.service-h3 {
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    font-weight: 700;
    text-align: center;
    margin-bottom: 2rem;
    /* Uniform spacing */
}

.service-h3-desc {
    text-align: center;
    margin-bottom: 40px;
    color: var(--color-text-sub);
}

/* Ensure Closing Copy White */
.close-section .close-body-text,
.close-section .close-main-copy {
    color: #fff !important;
}

/* SP Adjustments */
@media (max-width: 768px) {
    .service-fv {
        min-height: 50vh;
        height: auto;
    }

    .fv-short {
        min-height: 38vh;
        height: auto;
        padding-bottom: 32px;
    }

    .service-page-section {
        padding-bottom: 60px;
    }

    .service-h3 {
        margin-bottom: 1.5rem;
    }
}

/* --- Service Section (Carousel) --- */
.service-section {
    background-color: #fff;
    padding-top: 5px;
    /* Reduced per design */
    padding-bottom: 5px;
}

@media (max-width: 768px) {
    .service-section {
        padding: 30px 0 20px;
    }
}

/* --- Advantages Section --- */
.adv-section {
    background-color: var(--color-bg-gray-dark);
}

/* --- Flow Section --- */
.flow-section {
    background-color: #fff;
}

.step-number {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--color-line);
    margin-bottom: 8px;
    display: block;
    letter-spacing: 0.1em;
}

/* --- About Section --- */
.about-section {
    background-color: var(--color-bg-gray-dark);
}

/* --- Home Page Specific About Section --- */
.home .about-section {
    position: relative;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

/* ===== ABOUT HERO (IMAGE PLACEMENT) ===== */
.home .about-hero {
    position: relative;
    width: 100%;
    background-color: var(--color-bg-gray-dark);
    padding-bottom: 0;
    padding-top: 40px;
}

.home .about-hero * {
    opacity: 1;
    filter: none;
}

.about-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.about-header {
    margin-bottom: 20px;
}

/* ── トップページ余白調整（PC） ── */

/* ① ヒーロー → イントロ */
.home .intro-section {
    padding-top: 24px;
    padding-bottom: 0;
}

/* ② イントロ → 画像 */
.home .image-section {
    padding-top: 0px;
    padding-bottom: 24px;
}

.home .service-body {
    margin-bottom: 5px;
}

/* ③④⑥⑦⑧ 共通ブロック（課題・売上理由・流れ・アバウト・ラボ） */
.home .b5-section,
.home .adv-section,
.home .flow-section,
.home .about-section,
.home .lab-section {
    padding-top: 32px;
    padding-bottom: 32px;
}

/* ⑤ サービスブロック */
.home .service-section {
    padding-top: 24px;
    padding-bottom: 24px;
}

.home .section-title,
.home .about-header {
    margin-top: 0;
}

/* ── トップページ余白調整（SP） ── */
@media (max-width: 768px) {
    .home .intro-section {
        padding-top: 16px;
        padding-bottom: 0;
    }

    .home .image-section {
        padding-top: 0px;
        padding-bottom: 16px;
    }

    .home .service-body {
        margin-bottom: 0;
    }

    .home .b5-section,
    .home .adv-section,
    .home .flow-section,
    .home .about-section,
    .home .lab-section {
        padding-top: 24px;
        padding-bottom: 24px;
    }

    .home .service-section {
        padding-top: 16px;
        padding-bottom: 16px;
    }
}

.about-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    /* テキスト量によっては上寄せの方が自然、または center */
    align-items: center;
}

/* Left: Image Container (Was Dummy) */
.about-dummy {
    width: 50%;
    /* Remove placeholder background */
    background-color: transparent;
    min-height: 420px;
    border-radius: 0;
    box-shadow: none;
    /* Ensure image fills this */
    position: relative;
}

.about-dummy img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Right: Text */
.about-text-side {
    width: 50%;
    /* 修正③：右側テキストの余白を調整して横幅最大化（右パディング削除） */
    padding: 20px 0 20px 40px;
    box-sizing: border-box;
}

/* 修正④：リンクを右側テキストの右端に寄せる（PCのみ） */
.about-footer-link {
    text-align: right;
    width: 50%;
    margin-left: 50%;
    margin-top: 20px;
    /* 余白微調整 */
}

/* SP (Max 768px) - Vertical Stack */
@media (max-width: 768px) {
    .about-inner {
        flex-direction: column;
    }

    .about-dummy {
        width: 100%;
        min-height: 260px;
        order: 1;
    }

    .about-text-side {
        width: 100%;
        /* SPは左右パディング戻す（横幅いっぱいすぎると読みにくい場合あり、または0にするか）*/
        /* 既存デザイン維持ならある程度のパディング必要だが、指示はPCのみ */
        /* PC修正でpadding変えたのでSPも明示的に再定義 */
        padding: 24px 0;
        order: 2;
    }

    .about-footer-link {
        /* SPは中央寄せ・全幅に戻す */
        width: 100%;
        margin-left: 0;
        text-align: center;
        margin-top: 30px;
        order: 3;
    }
}


/* Hide old photo elements on home page */
.home .about-photo-side,
.home .about-photo {
    display: none;
}


/* Ensure content is above background */
.home .about-section>* {
    position: relative;
    z-index: 1;
}

/* Hide dummy photo on home page */
.home .about-photo {
    display: none;
}

.about-flex {
    display: flex;
    gap: 60px;
    align-items: flex-start;
}

.about-photo-side {
    flex: 0 0 38%;
}

.about-photo {
    width: 100%;
    aspect-ratio: 3 / 4;
    background: #ddd;
    border-radius: 12px;
    background-size: cover;
}

.about-text-side {
    flex: 1;
}

.about-body p {
    font-size: 0.95rem;
    line-height: 2.2;
    color: var(--color-text-sub);
    margin-bottom: 1.8rem;
    text-align: justify;
    letter-spacing: 0.08em;
}

@media (max-width: 768px) {
    .about-flex {
        flex-direction: column;
        gap: 30px;
    }

    .about-photo-side {
        width: 100%;
        flex: auto;
    }

    .about-photo {
        aspect-ratio: 16/9;
    }
}

/* --- Lab Section --- */
.lab-section {
    background-color: #fff;
}

/* ====================================================
   7. CLOSING CTA SECTION
   ==================================================== */
.close-section {
    position: relative;
    background-image: url('image/bangkok_footer.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: #fff;
    text-align: center;
    overflow: hidden;
    z-index: 20;
    padding: 100px 0;
    /* Standard padding from privacy.html */
}


@supports (-webkit-touch-callout: none) {
    .close-section {
        background-attachment: scroll;
    }
}

.close-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1;
}

/* Fix: Ensure content is above overlay */
.close-container {
    position: relative;
    z-index: 5;
}

.close-main-copy {
    font-size: clamp(1.8rem, 4.2vw, 2.6rem);
    font-weight: 700;
    line-height: 1.8;
    margin-bottom: 20px;
    color: #fff;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}

.close-body-text {
    font-size: 1rem;
    line-height: 2.0;
    margin-bottom: 50px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    color: #fff !important;
    white-space: pre-wrap;
    /* Method A: Respect newlines */
}

/* Force all text inside to be white */
.close-body-text p,
.close-section p,
.close-section span {
    color: #fff !important;
}

.close-cta-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 0;
}

/* 7. CLOSING CTA SECTION 修正 */

.close-body-text {
    width: 100%;
    margin: 0 auto 25px;
    text-align: center;
    color: #fff;
    white-space: normal;
}

.close-body-text p {
    display: inline-block;
    text-align: center;
    line-height: 2.2;
    color: #fff;
    margin: 0;
    padding: 0;
}

/* Hide hero reproduction text as requested */

.close-cta-notes {
    margin-top: 30px;
    font-size: 0.85rem;
    color: #fff;
    background: rgba(0, 0, 0, 0.4);
    padding: 12px 25px;
    border-radius: 4px;
    text-align: center;
}

/* ====================================================
   8. FOOTER
   ==================================================== */
.footer-block {
    background-color: #000;
    color: #fff;
    padding: 60px 0 20px;
    z-index: 30;
    text-align: left;
    position: relative;
    isolation: isolate;
}

.footer-container {
    position: relative;
    z-index: 1;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    align-items: start;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-column {
    width: 100%;
    text-align: center;
    /* Fix: Align columns visually */
    padding: 0 10px;
    /* Improve spacing safety */
}

.footer-col-title-no-link {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--color-line);
    margin-bottom: 20px;
    cursor: default;
    display: block;
}

.footer-nav-list {
    list-style: none;
}

.footer-nav-list li {
    margin-bottom: 14px;
    line-height: 1;
}

.footer-nav-list a {
    text-decoration: none;
    font-size: 0.75rem;
    color: #fff;
    transition: 0.3s;
    position: relative;
    display: inline-block;
    line-height: 1.8;
}

.footer-nav-list a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-line);
    transition: width 0.3s ease;
}

.footer-nav-list a:hover {
    color: var(--color-line);
}

.footer-nav-list a:hover::after {
    width: 100%;
}

/* LINE Link Special */
.footer-nav-list a.nav-link-line {
    color: #fff;
    font-weight: 400;
}

.footer-nav-list a.nav-link-line:hover {
    color: var(--color-line);
}

/* Disclaimer & Copy */
.footer-bottom {
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid #333;
    text-align: center;
}

.footer-desc {
    color: #999;
    font-size: 0.85rem;
    line-height: 1.8;
    margin-bottom: 20px;
}

.footer-copyright {
    font-size: 0.75rem;
    color: #888;
}

@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }
}

/* ====================================================
   Footer Accordion (SP only)
   ==================================================== */

/* PC: always show content, disable toggle */
@media (min-width: 769px) {
    details.footer-accordion {
        pointer-events: auto;
    }
    details.footer-accordion > * {
        display: block;
    }
    .footer-accordion ul {
        display: block;
    }
    details.footer-accordion > summary {
        pointer-events: none;
        cursor: default;
        list-style: none;
    }
    details.footer-accordion > summary::marker,
    details.footer-accordion > summary::-webkit-details-marker {
        display: none;
    }
    .footer-accordion a {
        pointer-events: auto;
    }
    .footer-accordion li a {
        background: none !important;
        border: none !important;
        border-radius: 0 !important;
        padding: 4px 0 !important;
        margin: 0;
        font-weight: 400 !important;
        text-align: center !important;
    }
    .footer-accordion summary {
        text-align: center !important;
    }
    .footer-accordion li {
        text-align: center !important;
    }
}

/* SP: accordion style */
@media (max-width: 768px) {
    details.footer-accordion {
        border-bottom: 1px solid #333;
    }
    details.footer-accordion > summary {
        list-style: none;
        cursor: pointer;
        padding: 14px 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 0;
    }
    details.footer-accordion > summary::marker,
    details.footer-accordion > summary::-webkit-details-marker {
        display: none;
    }
    details.footer-accordion > summary::after {
        content: '▼';
        font-size: 0.65em;
        color: var(--color-line);
        transition: transform 0.3s ease;
        flex-shrink: 0;
        margin-left: 8px;
    }
    details.footer-accordion[open] > summary::after {
        transform: rotate(180deg);
    }
    details.footer-accordion > ul.footer-nav-list {
        padding: 4px 0 16px;
    }
}

/* SP専用: フッターアコーディオンのボタン風リンク */
@media (max-width: 768px) {
  .footer-accordion li a {
    display: block;
    padding: 12px 16px;
    margin: 4px 0;
    color: #fff;
    text-decoration: none;
    text-align: left;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.15);
    font-size: 1rem;
    transition: background 0.2s;
  }
  .footer-accordion li a:hover {
    background: rgba(255,255,255,0.18);
  }
}

/* ====================================================
   SP: Section images 80% width
   ==================================================== */
@media (max-width: 768px) {
    .adv-section .common-card-image,
    .service-section .common-card-image,
    .flow-section .common-card-image {
        margin: 0 auto;
    }

    .home .about-dummy {
        margin: 0 auto;
    }

    .lab-section .lab-card-thumb {
        margin: 0 auto;
    }
}

/* ====================================================
   REASON PAGE (STORY LAYOUT)
   ==================================================== */
.reason-page-container {
    max-width: 800px;
    /* Reading optimzied width */
    margin: 0 auto;
}

.reason-block {
    margin-bottom: 80px;
}

.reason-h2 {
    font-size: clamp(1.4rem, 3.5vw, 1.8rem);
    font-weight: 700;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--color-line);
    line-height: 1.4;
}


/* User-defined strict highlight class */
.highlight-yellow {
    background-color: #FFF59D;
    font-weight: 700;
    color: #000000;
    padding: 0.1em 0.2em;
}


.reason-img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    margin-bottom: 30px;
    display: block;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.reason-text {
    font-size: 1.05rem;
    line-height: 2.2;
    color: var(--color-text);
    margin-bottom: 20px;
    text-align: justify;
}

.reason-sub-block {
    margin-top: 40px;
    padding-left: 20px;
    border-left: 4px solid var(--color-bg-gray-dark);
}

.reason-h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 15px;
}

@media (max-width: 768px) {
    .reason-block {
        margin-bottom: 60px;
    }

    .reason-h2 {
        margin-bottom: 20px;
        padding-bottom: 10px;
    }

    .reason-img {
        margin-bottom: 20px;
    }

    .reason-sub-block {
        padding-left: 15px;
        margin-top: 30px;
    }
}

/* ====================================================
   ABOUT PAGE
   ==================================================== */
.about-hero-content {
    text-align: center;
    color: #fff;
    padding-top: 60px;
}

.about-hero-sub-en {
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    letter-spacing: 0.1em;
    font-weight: 600;
    margin-bottom: 20px;
    color: #ccc;
}

.about-hero-divider {
    width: 60px;
    height: 1px;
    background-color: #fff;
    margin: 0 auto 30px;
}

.about-hero-main {
    font-size: clamp(1.6rem, 4vw, 2.4rem);
    font-weight: 700;
    line-height: 1.6;
    margin-bottom: 20px;
}

.about-hero-sub-jp {
    font-size: 1.1rem;
    font-weight: 500;
    color: #ddd;
}

/* About CTA */
.about-cta-container {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 60px;
}

.about-cta-wrapper {
    display: flex;
    gap: 20px;
}

/* Company Table */
.company-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.company-table th,
.company-table td {
    padding: 20px;
    border-bottom: 1px solid #eee;
    text-align: left;
    font-size: 1rem;
}

.company-table th {
    width: 30%;
    color: var(--color-text);
    font-weight: 700;
    background-color: #f9f9f9;
}

.company-table td {
    color: var(--color-text-sub);
}

@media (max-width: 768px) {
    .about-cta-container {
        justify-content: center;
    }

    .company-table th,
    .company-table td {
        display: block;
        width: 100%;
        padding: 15px 10px;
        border-bottom: none;
    }

    .company-table th {
        background: none;
        padding-bottom: 5px;
        color: var(--color-text-sub);
        font-size: 0.9rem;
    }

    .company-table td {
        padding-top: 10px;
        border-bottom: 1px solid #eee;
        font-weight: 500;
        color: var(--color-text);
    }
}

/* ====================================================
   FLOW PAGE
   ==================================================== */
.flow-hero-lead {
    font-size: 1rem;
    line-height: 2;
    color: #eee;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .flow-hero-lead {
        font-size: 0.9rem;
        text-align: left;
    }
}

/* ====================================================
   (NEW) UNIVERSAL COMPONENT STYLES
   Master Page: flow.html
   Target Pages: reason.html, service.html
   ==================================================== */

/* 1. Page Background (Master: Flow) */
.unified-page-wrapper {
    background-color: var(--color-bg-gray-dark);
    /* #ebebeb */
    padding: 60px 0 100px;
    width: 100%;
}

/* 2. Unified Card (Master: Flow) */
.unified-card {
    width: 100%;
    max-width: 1000px;
    margin: 0 auto 48px;
    /* Center and Bottom Spacing */
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    /* Clip content */
}

.unified-card:last-child {
    margin-bottom: 0;
}

/* 3. Card Header (Master: Flow -> All Pages Navy) */
.unified-card-header {
    background-color: #2c3e50;
    /* Navy (User Rule: All pages same color) */
    color: #fff;
    text-align: center;
    padding: 1.5rem 2rem;
    border-radius: 12px 12px 0 0;
}

.unified-card-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.4;
    color: #fff;
}

.unified-card-header h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0.5rem 0 0;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.9);
}

.unified-card-header {
    margin-bottom: 0;
    padding: 30px 40px;
    /* PC Padding */
    padding-bottom: 30px;
    /* Explicit bottom */
}

@media (max-width: 768px) {
    .unified-card-header {
        padding: 20px;
        /* SP Padding */
    }
}

/* 4. Card Image (Master: Flow) */
.unified-card-img-wrap {
    width: 100%;
    height: auto;
    background-color: #eee;
    overflow: hidden;
}

.unified-card-img-wrap img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
}

@media (max-width: 768px) {
    .unified-card-img-wrap {
        max-height: none;
    }

    .unified-card-img-wrap img {
        height: auto;
    }
}

/* 5. Card Body & Text (Master: Flow) */
.unified-card-body {
    padding: 50px 60px;
}

.unified-card-text {
    font-size: 1rem;
    line-height: 2.0;
    color: var(--color-text-sub);
    text-align: justify;
}

.unified-card-text p {
    margin-bottom: 1.5rem;
}

.unified-card-text p:last-child {
    margin-bottom: 0;
}

/* 6. Responsive (Master: Flow) */
@media (max-width: 768px) {
    .unified-card-header h2 {
        font-size: 1.4rem;
    }

    .unified-card-body {
        padding: 30px 20px;
    }
}


/* ====================================================
   SERVICE PAGE (ACTION BUTTON)
   ==================================================== */
.service-action-link-wrap {
    text-align: center;
    margin-top: 40px;
    margin-bottom: 0px;
    padding-right: 0;
}

.btn-action-guide {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-text);
    /* Dark */
    color: #fff;
    padding: 18px 45px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
    font-size: 1.1rem;
    letter-spacing: 0.05em;
}

.btn-action-guide:hover {
    background-color: var(--color-line);
    /* Green */
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(6, 199, 85, 0.3);
    color: #fff;
}

.btn-action-guide .arrow {
    margin-left: 15px;
    font-weight: bold;
    transition: transform 0.3s ease;
}

.btn-action-guide:hover .arrow {
    transform: translateX(5px);
}

@media (max-width: 768px) {
    .service-action-link-wrap {
        text-align: center;
        padding-right: 0;
    }

    .btn-action-guide {
        width: 80%;
        max-width: 300px;
    }
}

/* Shine Animation */
@keyframes shineEffect {
    0% {
        left: -100%;
        opacity: 0;
    }

    20% {
        left: 100%;
        opacity: 0.9;
    }

    100% {
        left: 100%;
        opacity: 0;
    }
}

.btn-action-guide {
    position: relative;
    overflow: hidden;
    /* Ensure shine stays inside */
}

.btn-action-guide::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    /* Wider shine */
    height: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.8) 50%, rgba(255, 255, 255, 0) 100%);
    transform: skewX(-25deg);
    animation: shineEffect 2.5s infinite ease-in-out;
    pointer-events: none;
}

/* ====================================================
   SERVICE PAGE (ALTERNATING BACKGROUNDS)
   ==================================================== */
.service-section-group {
    padding: 80px 0;
    margin-bottom: 0;
}

/* First Section: Match Top Page Intro (30px top) */
.service-section-group:first-of-type {
    padding-top: 30px;
    padding-bottom: 80px;
}

/* Last Section: Match Top Page Bottom Spacing (Reduced) */
.service-section-group:last-of-type {
    padding-bottom: 60px;
}

.service-bg-white {
    background-color: #fff;
}


.service-content-area {
    width: 100%;
}

@media (max-width: 768px) {
    .service-section-group {
        padding: 60px 0;
    }

    .service-section-group:first-of-type {
        padding-top: 20px;
    }

    .service-section-group:last-of-type {
        padding-bottom: 60px;
    }
}

.why-visual {
    margin: 16px 0 8px;
}

.why-visual img {
    width: 100%;
    height: auto;
    display: block;
}

/* ====================================================
   Breakout Image in Card Body (Full Width 1000px)
   ==================================================== */
.unified-card-body .unified-card-img-wrap {
    margin-left: -60px;
    margin-right: -60px;
    width: calc(100% + 120px);
    max-width: none;
}

@media (max-width: 768px) {
    .unified-card-body .unified-card-img-wrap {
        margin-left: -20px;
        margin-right: -20px;
        width: calc(100% + 40px);
    }
}

/* Inline Image Placement (Reason 4, 5, 6) */
.reason-inline-image {
    max-width: 1000px;
    margin: 16px auto;
    /* セクションに自然に馴染む余白 */
}

.reason-inline-image img {
    display: block;
    width: 100%;
    height: auto;
}

/* ====================================================
   Top Page Updates (2026-02-03)
   ==================================================== */

/* Background Color Logic */
/* White: Real Cause (.adv-section), Flow, Lab */
.adv-section,
.flow-section,
.lab-section {
    background-color: #fff;
}

/* Colored (Gray): Service, About */
.service-section,
.about-section {
    background-color: var(--color-bg-gray-dark);
}

/* Hide Carousel Indicators on PC (Common Carousel) */
@media (min-width: 769px) {
    .common-carousel+.carousel-indicators {
        display: none;
    }
}

.bullet-list {
    margin: 12px 0 16px;
    padding-left: 1.2em;
    line-height: 1.8;
}

.bullet-list li {
    margin: 6px 0;
}

.flow-visual {
    display: block;
    width: 100%;
    max-width: 1000px;
    height: auto;
    margin: 0 auto 16px;
}

/* ====================================================
   9. CUSTOM ADJUSTMENTS
   ==================================================== */

/* Task 3: Reason Block (PC) to match Service Page Grid Styling */
@media (min-width: 769px) {
    #reason .common-carousel {
        /* Match Service Page Grid gap */
        gap: 30px;
        /* Reset padding overrides if any */
        padding-right: 0;
    }

    #reason .common-card {
        /* Match Service Page Grid Item Width */
        /* (100% container width - 60px gap total) / 3 items */
        flex: 0 0 calc((100% - 60px) / 3) !important;
        max-width: none !important;
    }
}

/* Task 4: Flow Scroll adjustment */
#flow-1,
#flow-2,
#flow-3,
#flow-4,
#flow-5,
#flow-6,
#flow-7,
#flow-8 {
    scroll-margin-top: 120px;
}

/* ====================================================
   10. USER REFINEMENTS (2026-02-08)
   ==================================================== */
/* 写真があるセクションの余白を削除 */
section:has(img) {
    padding-bottom: 0;
    margin-bottom: 0;
}


/* 写真自体の下にある不要な隙間を消す */
img {
    vertical-align: bottom;
}

/* ====================================================
   ABOUTセクション：写真の底付けとリンク配置の最終調整
   ==================================================== */

@media (min-width: 769px) {

    /* セクション全体の余白設定 */
    .home .about-hero {
        padding-top: 40px;
        padding-bottom: 0;
        /* 底に隙間を作らない */
        background-color: var(--color-bg-gray-dark) !important;
        overflow: visible;
        /* 写真が枠外へはみ出すのを許可 */
    }

    .about-container {
        position: relative;
    }

    .about-inner {
        display: flex;
        align-items: flex-end;
        /* 写真とテキストエリアの「底」を揃える */
        gap: 0;
    }

    /* 1. 写真：サイズを変えず、底辺を境界線に接地させる */
    .about-dummy {
        width: 50%;
        margin-bottom: -4px;
        /* 画像下のわずかな隙間（ゴースト）を消して接地 */
        line-height: 0;
        z-index: 1;
    }

    .about-dummy img {
        width: 100%;
        height: auto;
        display: block;
        transform: scale(1.1);
        /* 現在の大きさを維持 */
        /* 底辺を基準に固定 */
        /* 修正②：写真の接地 */
        margin: 0;
        /* 修正② */
    }

    /* 2. テキストエリア：リンクをこの内側に閉じ込める */
    .about-text-side {
        display: flex;
        flex-direction: column;
        width: 50%;
        /* 冒頭に改行を入れる代わりに padding-top で調整 */
        box-sizing: border-box;
        align-self: stretch;
        /* 修正③：テキスト位置微調整 */
        padding-bottom: 20px;
    }

    .about-body {
        flex-grow: 0;
    }

    /* 3. リンクボタン：テキストエリア内の右下に配置 */
    .about-footer-link {
        text-align: right;
        width: 100%;
        margin-left: 0;
        /* はみ出し防止 */

        /* 文章のすぐ下に配置するための調整 */
        margin-top: 40px;
        padding-bottom: 20px;
        position: static;
    }
}

/* スマホ用のレスポンシブ対応 */
@media (max-width: 768px) {
    .home .about-hero {
        padding-top: 30px;
    }

    .about-inner {
        flex-direction: column;
        align-items: center;
    }

    .about-dummy,
    .about-text-side {
        width: 100%;
    }

    .about-dummy img {
        transform: scale(1);
        /* スマホでは拡大解除 */
    }

    .about-text-side {
        padding: 24px 0;
    }

    .about-footer-link {
        margin-top: 30px;
        text-align: center;
    }
}

/* ====================================================
   11. FORCE VISIBILITY (HEADER / HERO / CTA)
   ==================================================== */
.header,
.hero-section,
.close-section {
    opacity: 1;
    visibility: visible;
}

/* Ensure Hero is clickable and visible */
.hero-section {
    z-index: 100;
}

/* ====================================================
   12. CEO MESSAGE LAYOUT (2026-02-09)
   ==================================================== */
@media (min-width: 769px) {

    /* メッセージセクションのコンテナ */
    .about-message-container {
        display: flex;
        align-items: flex-end;
        /* 底揃え */
        justify-content: space-between;
        padding-bottom: 0 !important;
        /* 接地のために余白を消す */
        position: relative;
    }

    /* 文章エリア */
    .about-message-content {
        width: 60%;
        padding-bottom: 60px;
        /* 文章の下に適度な余白 */
    }

    /* 右下の写真 */
    .about-ceo-photo {
        width: 35%;
        margin-bottom: -1px;
        /* 隙間を完全に消す */
        line-height: 0;
    }

    .about-ceo-photo img {
        width: 100%;
        height: auto;
        transform: scale(1.1);
        transform-origin: bottom right;
        vertical-align: bottom;
        /* 画像下の謎の隙間を消す */
    }
}

/* ====================================================
   13. FINAL POLISH (2026-02-09)
   ==================================================== */

/* 1. Unified Section Padding */
section:not(.hero-section):not(.close-section),
.b5-section,
.footer-block {
    padding-top: 120px;
    padding-bottom: 120px;
}

.footer-block {
    padding-bottom: 0;
    margin-bottom: 0;
}

/* Exception: Top Page About Hero */
.about-hero {
    padding-bottom: 0;
}

/* Heading Margins */
.section-title,
.b5-header,
.about-header,
.service-title,
.lab-header {
    margin-bottom: 60px;
}

/* SP Adjustments */
@media (max-width: 768px) {

    section:not(.hero-section):not(.close-section),
    .b5-section,
    .footer-block {
        padding-top: 80px;
        padding-bottom: 80px;
    }

    .about-hero {
        padding-bottom: 0;
    }

    .section-title,
    .b5-header,
    .about-header,
    .service-title,
    .lab-header {
        margin-bottom: 40px;
    }
}

/* 2. Enlarge CEO Photo (about.html) */
/* Override previous setting to verify 30% increase */
@media (min-width: 769px) {
    .about-ceo-photo {
        width: 45%;
    }

    .about-message-content {
        width: 50%;
        /* decreased from 60% */
    }

    /* Ensure transform is consistent or adjusted if needed */
    .about-ceo-photo img {
        transform: scale(1.1);
        /* Keep scale or adjust if needed, prompt says size 30% larger, maybe mostly handled by width */
    }
}

/* 3. Site-wide Fade-in Animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1), transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    visibility: hidden;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

.reveal-delay-1 {
    transition-delay: 0.15s;
}

.reveal-delay-2 {
    transition-delay: 0.30s;
}

.reveal-delay-3 {
    transition-delay: 0.45s;
}

/* ====================================================
   12. ABOUT PAGE CEO MESSAGE LAYOUT (ULTIMATE FORCE)
   ==================================================== */
@media (min-width: 769px) {

    /* 親要素：写真を絶対配置するための基準 */
    .about-message-container {
        position: relative;
        padding-bottom: 0;
        overflow: visible;
    }

    /* テキストエリア：幅制限を解除し、右側に写真用の余白を作る */
    .about-message-content {
        width: 100%;
        max-width: none;
        padding-right: 350px;
        /* 写真エリア確保 */
        box-sizing: border-box;
    }

    /* 写真：右下に1.5倍サイズで固定 */
    .about-ceo-photo {
        position: absolute;
        right: 0;
        bottom: 0;
        width: 45%;
        /* 1.5倍程度の迫力 */
        max-width: 500px;
        margin: 0;
        z-index: 10;
        line-height: 0;
    }

    .about-ceo-photo img {
        width: 100% !important;
        height: auto !important;
        vertical-align: bottom !important;
        transform: scale(1.0) !important;
        transform-origin: bottom right !important;
        margin: 0;
        box-shadow: none !important;
    }
}

/* ====================================================
   13. TOP PAGE SPACING & PHOTO GROUNDING (ULTIMATE FORCE)
   ==================================================== */
/* 修正①：各ブロックの開始・終了余白の極小化 */
.home section,
.home .flow-section,
.home .lab-section,
.home .hero-section {
    padding-top: 40px;
    padding-bottom: 40px;
}

.home .section-title,
.home .about-header {
    margin-top: 0;
}

/* SP: 極小化 */
@media (max-width: 768px) {

    .home section,

    .home .flow-section,
    .home .lab-section {
        padding-top: 20px !important;
        padding-bottom: 20px !important;
    }

    /* ヒーローは 100vh 固定のため padding 上書き禁止 */
    .home .hero-section {
        padding-top: 0;
        padding-bottom: 0;
    }
}

/* ABOUT SECTION GROUNDING */
/* 1. Footer Spacing Removal & Centering (Force) */
footer,
.footer-container {
    padding-bottom: 0;
    margin-bottom: 0;
}

.footer-block {
    padding-bottom: 0;
    margin-bottom: 0;
}

/* Updated Footer Bottom for Perfect Centering */
.footer-bottom {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 50px;
    padding: 15px 0 0;
    border-top: 1px solid #333;
    width: 100%;
    margin: 20px 0 0;
    box-sizing: border-box;
}

.footer-bottom p,
.footer-bottom small,
.footer-copyright {
    margin: 0;
    padding: 0;
    font-size: 0.75rem;
    color: #888;
    line-height: 1;
    /* Prevent line-height shifts */
}

body,
html {
    padding-bottom: 0;
    margin-bottom: 0;
    height: auto;
    min-height: 100%;
}

.close-body-text {
    width: 100%;
    text-align: center;
    white-space: normal;
}

.close-body-text p {
    display: inline-block;
    text-align: center;
    margin: 0 auto 15px;
}

/* Prevent overlap of button and notes */
.close-cta-wrapper {
    margin-top: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

@media (min-width: 769px) {
    .home .about-hero {
        padding-bottom: 0;
        overflow: visible;
        background-color: var(--color-bg-gray-dark);
    }

    .home .about-dummy {
        width: 50%;
        margin-bottom: -1px;
        line-height: 0;
        z-index: 1;
        vertical-align: bottom;
    }

    .home .about-dummy img {
        vertical-align: bottom;
        transform-origin: bottom center;
        margin: 0;
    }

    .home .about-text-side {
        padding-bottom: 20px;
    }

    .home .about-footer-link {
        padding-bottom: 20px;
        margin-top: 20px;
        position: static;
    }
}

/* ====================================================
   14. ABOUT PAGE FULL WIDTH & COMPANY PROFILE (2026-02-09)
   ==================================================== */

/* CEO Message Full Width Override */
@media (min-width: 769px) {
    .about-message-content {
        padding-right: 0;
        /* Remove photo space reservation */
    }
}

/* Company Profile Table */
.about-message-visual {
    text-align: center;
    margin: 0;
    padding: 0;
}

.about-message-visual img {
    max-width: 100%;
    height: auto;
    display: block;
    /* Remove bottom whitespace */
}

.company-profile-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 16px;
}

.company-profile-table th,
.company-profile-table td {
    padding: 20px;
    border-bottom: 1px solid #eee;
    text-align: left;
    vertical-align: top;
}

.company-profile-table th {
    background-color: #f9f9f9;
    width: 30%;
    font-weight: 700;
    color: #333;
    white-space: nowrap;
}

.company-profile-table td {
    background-color: #fff;
    width: 70%;
    color: #555;
    line-height: 1.8;
}

/* Responsive Table */
@media (max-width: 768px) {

    .company-profile-table th,
    .company-profile-table td {
        display: block;
        width: 100%;
        box-sizing: border-box;
    }

    .company-profile-table th {
        background-color: #f0f0f0;
        border-bottom: none;
        padding-bottom: 10px;
    }

    .company-profile-table td {
        padding-top: 10px;
    }
}

/* 20. CLOSE SECTION POSITION FIX (Zero Margin Predecessor) */
.close-section::before {
    content: "";
    display: block;
    margin-top: 0;
}

section+.close-section {
    margin-top: 0;
}

/* 21. COMMON SPACER FOR CLOSING SECTION ALIGNMENT */
/* Spacer kept for HTML consistency with Privacy Policy, but visually neutral handled by flow */
.closing-spacer {
    display: none;
}

/* ====================================================
   MOBILE HEADER LOGO SIZING FIX (Task 80 - Final Strict)
   ==================================================== */
@media (max-width: 768px) {

    /* 1. Header Height Fixed */
    .header-inner {
        height: 64px !important;
        min-height: 64px !important;
        padding: 0 20px !important;
    }

    /* 2. Logo Height (Base Control) */
    .branding,
    .logo-text {
        height: 100% !important;
        display: flex !important;
        align-items: center !important;
        margin: 0;
        padding: 0 !important;
    }

    /* 3. Logo Image (Height 32px) */
    .logo-text img {
        height: 32px !important;
        width: auto !important;
    max-width: none !important;
        max-height: none !important;
        object-fit: contain !important;
    }

    /* 4. LINE Button (Height 32px - Match Logo) */
    .btn-header-line {
        height: 32px !important;
        padding: 0 14px !important;
        display: flex !important;
        align-items: center !important;
        box-sizing: border-box !important;
        flex-shrink: 0 !important;
        white-space: nowrap !important;
    }
}

/* ====================================================
   MOBILE HEADER RESTRUCTURE & NAVIGATION (Task 81-83)
   ==================================================== */

/* 1. Header Layout (Base) */
.site-header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: #000;
    padding: 0;
    margin: 0;
    transition: all 0.3s;
    line-height: 1;
    height: 64px;
    display: flex;
    align-items: center;
    transform: translateY(0);
    opacity: 1;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    width: 100%;
    padding: 0 20px;
    max-width: var(--content-width);
    margin: 0 auto;
    box-sizing: border-box;
}

.header-left {
    display: flex;
    align-items: center;
    height: 100%;
}

.header-right {
    display: flex;
    align-items: center;
    height: 100%;
    gap: 8px;
    flex-shrink: 0;
}

/* 2. Logo Styling */
.logo-text img {
    height: 32px;
    width: auto;
    display: block;
    opacity: 1;
    visibility: visible;
}

/* 3. LINE Button Styling */
.btn-header-line {
    height: 32px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    border: 1px solid #fff;
    border-radius: 999px;
    /* Pill shape */
    font-size: 12px;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s;
    background-color: transparent;
    flex-shrink: 0;
    white-space: nowrap;
}

.btn-header-line:hover {
    background-color: #fff;
    color: #000;
}

/* 4. Hamburger Menu Toggle */
.menu-toggle {
    font-size: 24px;
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    line-height: 1;
    padding: 0 4px;
    /* Touch target adjustment */
    display: none;
    /* Hidden on PC by default */
}

/* 5. SP Navigation Overlay */
.sp-nav {
    display: none;
    position: fixed;
    top: 64px;
    /* Below header */
    left: 0;
    width: 100%;
    height: calc(100vh - 64px);
    background: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    padding: 40px 20px;
    overflow-y: auto;
}

.sp-nav.open {
    display: block;
}

.sp-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: center;
}

.sp-nav li {
    margin-bottom: 24px;
}

.sp-nav a {
    color: #fff;
    font-size: 1rem;
    font-weight: 400;
    text-decoration: none;
    display: block;
    padding: 12px 16px;
    margin: 4px 20px;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.15);
    transition: background 0.2s;
}
.sp-nav a:hover {
    background: rgba(255,255,255,0.18);
}

/* Responsive Switching */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .global-nav,
    .pc-only-nav {
        display: none;
        /* Hide PC nav */
    }

    .header-inner {
        padding: 0 20px !important;
    }

    /* Common Section Spacing (SP) */
    section,
    .b5-section,

    .image-section,
    .service-page-section {
        padding-top: 40px;
        padding-bottom: 40px;
    }

    /* H2 Margin (SP) */
    .section-title,
    .b5-header,
    .sv-header,
    .adv-header,
    .flow-header,
    .about-header,
    .lab-header {
        margin-bottom: 30px;
    }
}

@media (min-width: 769px) {

    .menu-toggle,
    .sp-nav {
        display: none;
    }

    .global-nav,
    .pc-only-nav {
        display: flex;
        flex: 1;
        justify-content: center;
        align-items: center;
    }

    .nav-list {
        display: flex;
        gap: 40px;
        /* Adjusted spacing */
        list-style: none;
        margin: 0;
        padding: 0;
        align-items: center;
    }

    .header-right {
        gap: 20px;
    }
}

/* ====================================================
   HERO GAP OPTIMIZATION (Pinpoint Fix - Deep Clean)
   ==================================================== */
.home .intro-section {
    padding-top: 0;
    margin-top: 0;
    transform: translateY(-10px);
    /* Visual pull-up */
}

.hero-section {
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Conflict Resolution */
section.intro-section {
    padding-top: 0;
}

/* ====================================================
   HERO GAP LIMIT FIX (Ultimate Override)
   ==================================================== */
.home .intro-section {
    padding-top: 0;
    margin-top: 0;
    transform: translateY(-20px);
    /* FORCE PULL UP */
    position: relative;
    z-index: 10;
}

.hero-section {
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Ensure no pseudo-elements interfere */
.hero-section::after,
.hero-section::before,
.home .intro-section::before {
    display: none;
    content: none;
    height: 0;
}

/* ====================================================
   15. WHITESPACE REDUCTION (SPACING FIX) - 2026-02-11
   余白を全体的に短縮する設定
   ==================================================== */

/* 1. 全セクションの上下余白を短縮 (ブロック間の余白解消) */
section:not(.hero-section):not(.close-section),
.b5-section,
.intro-section,
.image-section,
.adv-section,
.service-section,
.flow-section,
.about-section,
.lab-section,
.footer-block {
    padding-top: 40px;
    padding-bottom: 40px;
}

/* 2. 見出し下の余白を短縮 */
.section-title,
.b5-header,
.about-header,
.service-title,
.lab-header,
.adv-header,
.flow-header {
    margin-bottom: 30px;
}

/* 3. ブロック１（イントロ）特有の修正 */
.intro-section {
    padding-top: 40px;
    padding-bottom: 0;
}

.service-body {
    margin-bottom: 5px;
}

.image-section {
    padding-top: 0;
    padding-bottom: 40px;
}

/* 4. アバウトセクション（CEOメッセージ）の微調整 */
.home .about-hero {
    padding-top: 40px;
    padding-bottom: 0;
}

/* 5. スマホ表示（SP）用のさらに詰めた設定 */
@media (max-width: 768px) {

    section:not(.hero-section):not(.close-section),
    .b5-section,
    .intro-section,
    .image-section,
    .adv-section,
    .service-section,
    .flow-section,
    .about-section,
    .lab-section {
        padding-top: 30px;
        padding-bottom: 30px;
    }

    .section-title,
    .b5-header,
    .about-header,
    .service-title,
    .lab-header {
        margin-bottom: 20px;
    }

    .intro-section {
        padding-top: 30px;
        padding-bottom: 0;
    }

    .service-body {
        margin-bottom: 0;
    }

    .image-section {
        padding-top: 0;
    }
}

/* ====================================================
   16. FV-PHOTO HERO (AI Manager LP) - 2026-02-16
   写真背景ヒーロー
   ==================================================== */
.service-fv.fv-photo {
    position: relative;
    background-image: url('image/ai-manager-hero.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
}

.service-fv-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1;
}

.service-fv.fv-photo .container {
    position: relative;
    z-index: 2;
}

.service-fv.fv-photo .service-intro-content-center {
    max-width: 800px;
    margin: 0 auto;
}

.service-fv.fv-photo .service-main-copy {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: #fff;
}

.service-fv.fv-photo .service-main-highlight {
    font-size: clamp(1.8rem, 4.2vw, 2.6rem);
    font-weight: 700;
    line-height: 1.8;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
    margin-bottom: 30px;
    color: #fff;
}

.service-fv.fv-photo .service-intro-text {
    font-size: 1.1rem;
    margin-bottom: 40px;
    color: #fff;
    opacity: 0.95;
}

.service-fv.fv-photo .hero-cta {
    margin-top: 40px;
}

@media (max-width: 768px) {
    .service-fv.fv-photo {
        min-height: 80vh;
    }

    .service-fv.fv-photo .service-main-highlight {
        font-size: 1.8rem;
    }
}

/* ============================================================================
   AI Manager LP Page Styles
   ============================================================================ */

/* 1. Hero Section Setup */
/* =============================================
   AI Manager Hero
   SP: 上下2分割 / PC: 左右2分割
   ============================================= */
.ai-manager-hero {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    height: 100vh;
    height: 100svh;
    display: flex;
    flex-direction: column;
    color: #fff;
    overflow: hidden;
}

/* ==== SP（〜768px）: 上下2分割 ==== */

/* SP上部：写真背景 + h1 + キャラ（72%） */
.hero-panel-visual {
    flex: 0 0 72%;
    position: relative;
    background: #0d1b2a;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: hidden;
}

.hero-panel-visual-bg {
    position: absolute;
    inset: 0;
    background: url('image/seedream-74ad2ba93fb04a2e50692eb51de9cbae.png') center bottom/cover no-repeat;
}

.hero-panel-visual-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.72) 0%,
        rgba(0, 0, 0, 0.4) 45%,
        rgba(0, 0, 0, 0.15) 100%
    );
    pointer-events: none;
}

/* SP: h1（写真上に重ねる） */
.hero-main-sp {
    position: relative;
    z-index: 10;
    text-align: center;
    padding: calc(60px + 16px) 24px 0;
    font-size: clamp(1.5rem, 6.5vw, 2rem);
    font-weight: 700;
    line-height: 1.6;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.7);
    margin: 0;
    flex-shrink: 0;
}

/* PC: h1 非表示 */
.hero-main-pc {
    display: none;
}

/* SP: キャラ（コピー直下・下端揃え） */
.hero-panel-visual .hero-character {
    position: relative;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    flex: 1;
    width: 100%;
}

.hero-panel-visual .hero-character img {
    max-height: 52vh;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 -4px 24px rgba(0, 150, 255, 0.35));
}

/* SP下部：黒 + サブコピー + CTA（28%） */
.hero-panel-copy {
    flex: 0 0 28%;
    background: #000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 12px 20px;
    overflow: hidden;
}

.hero-panel-copy .hero-sub {
    text-align: center;
    font-size: clamp(0.82rem, 3.5vw, 1rem);
    line-height: 1.7;
    margin: 0 0 12px;
    opacity: 1;
    text-shadow: none;
    flex-shrink: 0;
}

.hero-panel-copy .hero-cta {
    margin-top: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.hero-panel-copy .btn-hero-ghost {
    font-size: 0.92rem !important;
    padding: 13px 28px !important;
}

.hero-panel-copy .hero-cta-notes {
    margin-top: 8px !important;
    font-size: 0.75rem !important;
}

/* ==== PC（769px以上）: 左右2分割 ==== */
@media (min-width: 769px) {
    .ai-manager-hero {
        flex-direction: row;
    }

    /* PC左：写真 + キャラ下寄せ */
    .hero-panel-visual {
        order: 1;
        flex: 0 0 50%;
        height: 100%;
    }

    .hero-panel-visual-overlay {
        background: linear-gradient(
            to bottom,
            rgba(0, 0, 0, 0.3) 0%,
            rgba(0, 0, 0, 0.1) 50%,
            rgba(0, 0, 0, 0) 100%
        );
    }

    /* SP用h1はPC非表示 */
    .hero-main-sp {
        display: none;
    }

    .hero-panel-visual .hero-character {
        align-items: flex-end;
        justify-content: center;
        padding-bottom: 3%;
    }

    .hero-panel-visual-bg {
        background-position: center 92%;
    }

    .hero-panel-visual .hero-character img {
        max-height: 88vh;
    }

    /* PC右：黒 + h1 + サブ + CTA（左揃え） */
    .hero-panel-copy {
        order: 2;
        flex: 0 0 50%;
        height: 100%;
        background: #000;
        align-items: flex-start;
        justify-content: center;
        padding: 0 64px;
    }

    .hero-main-pc {
        display: block;
        text-align: left;
        font-size: clamp(2rem, 2.8vw, 2.8rem);
        font-weight: 700;
        line-height: 1.55;
        text-shadow: none;
        margin: 0 0 28px;
        padding: 0;
        flex-shrink: 0;
    }

    .hero-panel-copy .hero-sub {
        text-align: left;
        font-size: clamp(0.95rem, 1.4vw, 1.15rem);
        line-height: 1.8;
        margin: 0 0 24px;
        opacity: 0.9;
    }

    .hero-panel-copy .hero-cta {
        align-items: flex-start;
    }

    .hero-panel-copy .btn-hero-ghost {
        font-size: 1.05rem !important;
        padding: 16px 40px !important;
    }

    .hero-panel-copy .hero-cta-notes {
        margin-top: 14px !important;
        font-size: 0.82rem !important;
    }
}

/* Keyframes: Zoom Loop */
@keyframes zoomLoop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

/* 3. Content Container */
.ai-hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding-bottom: 60px;
    /* Space for footer/CTA */
}

/* 4. Typography & Animations */

/* Problem Statement */

.hero-problem {
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    letter-spacing: 0.1em;
    margin-bottom: 8px;
    opacity: 0;
    /* Hidden initially */
    /* Gentle floating */
    animation: floatGentle 3s ease-in-out infinite alternate;
}

/* Target Audience */

.hero-target {
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    font-weight: 700;
    margin-bottom: 0;
    opacity: 0;
    animation: floatGentle 4s ease-in-out infinite alternate-reverse;
}

/* Main Copy (AI店長) */


/* Character Animation */

/* Gold/Red Highlight */
.ai-highlight {
    color: #FFD700;
    /* Gold */
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.6);
}

/* Sub Copy */


/* Benefits List */

.benefit-item {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    padding: 10px 20px;
    border-radius: 50px;
    font-size: clamp(0.85rem, 1.5vw, 1rem);
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    opacity: 0;
    transition: transform 0.3s ease;
}

.benefit-item:hover {
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.2);
}


/* Pricing & CTA */


/* CTA Button Pulse */
/* CTA Button */
.btn-ai-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--color-line);
    /* Green */
    color: #fff;
    font-weight: 700;
    padding: 18px 50px;
    border-radius: 50px;
    font-size: 1.2rem;
    text-decoration: none;
    transition: all 0.3s var(--easing);
    border: 2px solid var(--color-line);
    /* Match closing button logic */
}

.btn-ai-cta:hover {
    background: #fff;
    color: #000;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.3);
}

/* Remove Pulse */
/* .pulse-btn { animation: pulseRed 2s infinite; } */

@keyframes pulseRed {
    0% {
        box-shadow: 0 0 0 0 rgba(230, 0, 18, 0.7);
    }

    70% {
        box-shadow: 0 0 0 15px rgba(230, 0, 18, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(230, 0, 18, 0);
    }
}

/* Animation Utilities */
@keyframes floatGentle {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(-5px);
    }
}

@keyframes floatStrong {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(-8px);
    }
}

@keyframes fadeUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeUpChar {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    0% {
        opacity: 0;
        transform: translateX(-20px);
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

.fade-in-up {
    animation: fadeUp 1s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.slide-in-left {
    animation: slideInLeft 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Animation Delays */
.delay-0 {
    animation-delay: 0.1s;
}

.delay-1 {
    animation-delay: 0.4s;
}

.delay-2 {
    animation-delay: 0.8s;
}

.delay-3 {
    animation-delay: 1.0s;
}

/* " */
.delay-4 {
    animation-delay: 1.1s;
}

/* AI */
.delay-5 {
    animation-delay: 1.2s;
}

/* 店 */
.delay-6 {
    animation-delay: 1.3s;
}

/* 長 */
.delay-7 {
    animation-delay: 1.4s;
}

/* " */
.delay-8 {
    animation-delay: 1.5s;
}

/* を */
.delay-9 {
    animation-delay: 1.6s;
}

/* 雇 */
.delay-10 {
    animation-delay: 1.7s;
}

/* い */
.delay-11 {
    animation-delay: 1.8s;
}

/* ま */
.delay-12 {
    animation-delay: 2.2s;
}

/* Sub copy */
.delay-13 {
    animation-delay: 2.5s;
}

/* Benefit 1 */
.delay-14 {
    animation-delay: 2.7s;
}

/* Benefit 2 */
.delay-15 {
    animation-delay: 2.9s;
}

/* Benefit 3 */
.delay-16 {
    animation-delay: 3.2s;
}

/* CTA */

/* Mobile Responsive */
@media (max-width: 768px) {


    .benefit-item {
        width: 100%;
        max-width: 300px;
        text-align: left;
        padding-left: 20px;
    }


}

/* ====================================================
   AI TENCHO SPEECH BUBBLE
   ==================================================== */
.ai-tencho-bubble {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-top: 30px;
}

.ai-tencho-avatar {
    flex: 0 0 80px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    background: #e8f4fd;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #d0e3f1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.ai-tencho-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ai-tencho-speech {
    position: relative;
    background: #f0f8ff;
    border-radius: 12px;
    padding: 16px 20px;
    flex: 1;
    font-size: 0.95rem;
    line-height: 1.8;
}

.ai-tencho-speech::before {
    content: '';
    position: absolute;
    left: -10px;
    top: 20px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 12px 8px 0;
    border-color: transparent #f0f8ff transparent transparent;
}

.ai-tencho-speech .ai-tencho-name {
    font-weight: 700;
    font-size: 0.9rem;
    color: #2a6496;
    margin-bottom: 4px;
    display: block;
}

.ai-tencho-speech p {
    margin: 0;
}

@media (max-width: 768px) {
    .ai-tencho-bubble {
        flex-direction: column;
        align-items: center;
        gap: 0;
    }

    .ai-tencho-avatar {
        flex: 0 0 64px;
        width: 64px;
        height: 64px;
        margin-bottom: -8px;
        z-index: 1;
    }

    .ai-tencho-speech::before {
        display: none;
    }

    .ai-tencho-speech {
        width: 100%;
    }
}

/* ===== スマホ版LINEボタン1行化 ===== */
@media (max-width: 480px) {
    .btn-hero-ghost {
        font-size: 0.95rem !important;
        padding: 14px 30px !important;
        white-space: nowrap !important;
    }

    .btn-header-line {
        font-size: 0.7rem !important;
        padding: 6px 10px !important;
        white-space: nowrap !important;
    }
}

/* ===== クロージングCTA余白詰め（全ページ共通） ===== */
.close-cta-wrapper {
    margin-top: 0;
}

.close-body-text {
    margin-bottom: 20px;
}

/* ====================================================
   ⑥ フッター余白修正 - copyright下の余白を詰める
   ==================================================== */
.footer-block {
    padding-bottom: 15px;
}

.footer-bottom {
    padding-bottom: 10px;
    margin-bottom: 0;
}

/* ====================================================
   ⑦ service-body 余白（トップページ）
   ==================================================== */
.home .service-body {
    margin-bottom: 0;
}

/* ====================================================
   ⑧ ヒーロー キャッチコピー スマホ表示最適化
   3行中央揃え（WEB集客… / × / AIによる…）
   + ファーストビュー全体のバランス調整
   ==================================================== */
@media (max-width: 768px) {
    .hero-content {
        margin-top: 60px !important;
        padding: 0 20px !important;
    }

    .ai-manager-page .hero-content {
        margin-top: 0 !important;
    }

    .hero-main {
        font-size: clamp(1.5rem, 5.5vw, 2.2rem) !important;
        margin-bottom: 5px !important;
        line-height: 2.0 !important;
    }

    .hero-sub {
        text-align: center !important;
        margin-top: 8px !important;
        margin-bottom: 0 !important;
        font-size: clamp(0.8rem, 3vw, 1rem) !important;
        line-height: 1.7 !important;
    }

    .hero-sub-line {
        display: block;
    }

    .hero-sub-x {
        display: block;
        font-size: 1.1em;
        margin: 3px 0;
    }

    .hero-cta {
        margin-top: 20px !important;
    }

    .btn-hero-ghost {
        font-size: 0.95rem !important;
        padding: 14px 32px !important;
    }

    .hero-cta-notes {
        margin-top: 14px !important;
    }
}

/* PC: keep inline */
@media (min-width: 769px) {
    .hero-sub-line,
    .hero-sub-x {
        display: inline;
    }
}

/* ====================================================
   ④ CTA注釈文 スタイル調整（PC・SP共通 + SP最適化）
   15文字×2行が1行に収まるように調整
   ==================================================== */
.hero-cta-notes,
.close-cta-notes {
    text-align: center;
}

.hero-cta-notes p,
.close-cta-notes p {
    margin: 3px 0;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .hero-cta-notes,
    .close-cta-notes {
        font-size: 0.7rem !important;
        padding: 10px 18px !important;
        margin-top: 18px !important;
    }

    .hero-cta-notes p,
    .close-cta-notes p {
        margin: 2px 0 !important;
        white-space: nowrap !important;
    }
}

/* ====================================================
   ⑨ スマホ表示 アクションボタンの ＞＞＞ 記号削除 & 1行化
   ==================================================== */
.btn-arrow-sp-hide {
    display: inline;
}

@media (max-width: 768px) {
    .btn-arrow-sp-hide {
        display: none !important;
    }

    .btn-action-guide {
        font-size: 0.85rem !important;
        padding: 16px 28px !important;
        white-space: nowrap !important;
    }
}

/* ====================================================
   ⑦ リード文 → 図解の余白をさらに大幅削減
   ==================================================== */
.home .intro-section {
    padding-bottom: 0;
    margin-bottom: -20px;
}

.home .image-section {
    padding-top: 0;
    margin-top: -25px;
}

@media (max-width: 768px) {
    .home .intro-section {
        margin-bottom: -15px;
    }

    .home .image-section {
        margin-top: -15px;
    }
}

/* ====================================================
   FV説明テキスト スマホ文字切れ防止（全ページ統一）
   ==================================================== */
@media (max-width: 768px) {
    .service-intro-text,
    .service-intro-text p {
        font-size: 0.82rem !important;
        line-height: 1.8 !important;
        word-break: break-word !important;
    }
}
/* ====================================================
   Lab Card Grid（トップページ バンコクラボ記事カード）
   ==================================================== */
/* Lab carousel (blog cards as horizontal slider) */
.lab-carousel-wrapper {
    margin-top: 32px;
}
.lab-carousel .lab-card {
    flex: 0 0 calc((100% - 48px) / 3);
    scroll-snap-align: start;
}
@media (min-width: 769px) {
    .lab-carousel .lab-card {
        flex: 0 0 29% !important;
        max-width: none !important;
    }
}
@media (max-width: 768px) {
    .lab-carousel .lab-card {
        flex: 0 0 calc((100% - 16px) / 1.15);
    }
}

/* Legacy grid fallback (unused, kept for reference) */
.lab-card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 32px;
}
@media (max-width: 900px) {
    .lab-card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 580px) {
    .lab-card-grid { grid-template-columns: 1fr; gap: 16px; }
}

.lab-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    border: 1px solid #eee;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.lab-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 28px rgba(0,0,0,0.10);
    text-decoration: none;
}

.lab-card-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #e8eff8;
}
.lab-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}
.lab-card:hover .lab-card-thumb img {
    transform: scale(1.04);
}

.lab-card-body {
    padding: 16px 18px 20px;
    display: flex;
    flex-direction: column;
}

.lab-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.lab-card-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    padding: 2px 8px;
    border-radius: 3px;
    letter-spacing: 0.04em;
}
.lab-card-tag.tag-guide { background: #2563a8; }
.lab-card-tag.tag-industry { background: #1a6b4a; }

.lab-card-date {
    font-size: 12px;
    color: #aaa;
}

.lab-card-title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.55;
    color: #1a1a1a;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: calc(14px * 1.55 * 3);
}

/* ====================================================
   スマホ見出しフォントサイズ統一
   service-title（イントロ h2）をスマホで2行表示に調整
   ==================================================== */
@media (max-width: 768px) {
    .service-title {
        font-size: clamp(1rem, 4.5vw, 1.35rem) !important;
        line-height: 1.7 !important;
    }
}

/* ====================================================
   見出し → 画像 → 本文 の統合セクション余白調整
   ==================================================== */
.home .intro-section {
    padding-top: 48px;
    padding-bottom: 48px;
    margin-top: 0;
    margin-bottom: 0;
}

.home .intro-section .service-title {
    margin-bottom: 28px;
}

.home .intro-section .feature-image {
    margin-bottom: 32px;
    display: block;
}

.home .intro-section .service-body {
    margin-top: 0;
}

@media (max-width: 768px) {
    .home .intro-section {
        padding-top: 32px;
        padding-bottom: 32px;
    }

    .home .intro-section .service-title {
        margin-bottom: 20px;
    }

    .home .intro-section .feature-image {
        margin-bottom: 24px;
    }
}

/* ====================================================
   ヒーローブロック スマホ1画面フィット最適化
   ==================================================== */
@media (max-width: 768px) {
    .hero-content {
        margin-top: 40px !important;
    }

    .hero-main {
        font-size: clamp(1.6rem, 5.8vw, 2.2rem) !important;
        line-height: 1.9 !important;
        margin-bottom: 4px !important;
    }

    .hero-sub {
        font-size: clamp(0.9rem, 3.5vw, 1.15rem) !important;
        margin-top: 6px !important;
    }

    .b5-highlight {
        font-size: clamp(1rem, 4.5vw, 1.35rem) !important;
    }

    .hero-cta {
        margin-top: 16px !important;
    }

    .hero-cta-notes {
        margin-top: 10px !important;
        font-size: 0.7rem !important;
        padding: 8px 16px !important;
    }
}

/* ====================================================
   見出しフォントサイズ統一 (スマホ)
   ==================================================== */
@media (max-width: 768px) {
    .b5-main-title {
        font-size: clamp(1rem, 4.5vw, 1.35rem) !important;
    }

    .b5-solution-title {
        font-size: clamp(1rem, 4.5vw, 1.3rem) !important;
    }

    .section-desc {
        font-size: clamp(0.85rem, 3.5vw, 1rem) !important;
    }
}

/* ====================================================
   セクション見出し画像 スマホ60%縮小
   2026-03-27 修正: heightの矛盾を解消、max-widthで制御
   ==================================================== */
@media (max-width: 768px) {
  .section-title-img,
  .b5-heading-img,
  .adv-heading-img,
  .lab-heading-img {
    max-width: 168px; /* デスクトップ280px × 60% */
    height: auto;
    display: block;
    margin: 0 auto;
  }
  .flow-heading-img {
    max-width: 240px; /* デスクトップ400px × 60% */
    height: auto;
    display: block;
    margin: 0 auto;
  }
  .about-heading-img {
    max-width: 150px; /* デスクトップ250px × 60% */
    height: auto;
    display: block;
    margin: 0 auto;
  }
}
