/* --- Base & Scrollbar Hide --- */
body { margin: 0; background-color: #000; font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", sans-serif; -ms-overflow-style: none; scrollbar-width: none; color: #fff; }
body::-webkit-scrollbar { display: none; }

/* --- Hero Layers --- */
#bg-container { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-image: url('../images/movient_portal_main.jpg'); background-size: cover; background-position: center; z-index: -1; filter: brightness(0.5) contrast(1.1); opacity: 0; display: block; }
canvas { position: fixed; top: 0; left: 0; z-index: 10; pointer-events: none; background: transparent !important; }
#genesis-text { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 150; color: #fff; font-weight: 200; font-size: 18px; letter-spacing: 0.4em; text-align: center; opacity: 0; white-space: nowrap; pointer-events: none; text-shadow: 0 0 15px rgba(255,255,255,0.3); }
#ui-layer { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 100; pointer-events: none; }
.header { position: fixed; top: 0; left: 0; width: 100%; display: flex; justify-content: space-between; align-items: center; padding: 20px 40px; pointer-events: auto; opacity: 0; visibility: hidden; transition: opacity 0.8s ease, visibility 0s linear 0.8s; z-index: 1000; background: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.4) 70%, transparent 100%); box-sizing: border-box; }
body.header-visible .header { opacity: 1; visibility: visible; transition: opacity 0.8s ease, visibility 0s linear 0s; }
.header-logo-img { height: 28px; width: auto; }
.nav { display: flex; align-items: center; flex-wrap: wrap; gap: 20px; }
.nav a { color: #fff; text-decoration: none; font-size: 12px; letter-spacing: 0.12em; opacity: 0.6; transition: opacity 0.3s; cursor: pointer; margin-left: 0; white-space: nowrap; }
.nav a:hover { opacity: 1; }

/* ヘッダーのレスポンシブ対応 */
@media (max-width: 768px) {
  .header { padding: 15px 20px; }
  .header-logo-img { height: 24px; }
  .nav { gap: 12px; }
  .nav a { font-size: 10px; letter-spacing: 0.08em; }
}

@media (max-width: 480px) {
  .header { padding: 12px 15px; }
  .header-logo-img { height: 20px; }
  .nav { gap: 8px; }
  .nav a { font-size: 9px; letter-spacing: 0.05em; }
}
.center-content { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); text-align: center; width: 100%; transition: opacity 1.5s ease, transform 1.5s ease, filter 1.5s ease; }
.catch-copy { font-size: 16px; letter-spacing: 0.6em; margin-bottom: 25px; opacity: 0; color: #b0fbff; transform: translateY(10px); }
.main-logo-img { width: 420px; height: auto; opacity: 0; transform: scale(0.98); filter: drop-shadow(0 0 15px rgba(0, 242, 254, 0.4)); }
#loading-msg { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); color: #00f2fe; z-index: 200; font-size: 11px; letter-spacing: 0.2em; }
#title-overlay { position: absolute; top: 32%; left: 15%; transform: translateY(-50%); width: 450px; pointer-events: none; z-index: 120; }
.service-title-img { width: 100%; opacity: 0; position: absolute; top: 0; left: 0; }

/* --- Main Content Area --- */
#main-scroll-container { 
    position: relative; width: 100%; z-index: 200; margin-top: 100vh; 
    background: linear-gradient(to bottom, transparent, rgba(0,0,0,0.8) 15vh, rgba(0,0,0,0.95) 50vh, #000 100%); 
    visibility: hidden; opacity: 0; transition: opacity 2.0s ease; 
}

.content-section { max-width: 1100px; margin: 0 auto; padding: 120px 40px; min-height: 80vh; }
.section-label { color: #00f2fe; font-size: 12px; letter-spacing: 0.5em; margin-bottom: 20px; display: block; opacity: 0.7; }
.section-title { font-size: 32px; font-weight: 200; letter-spacing: 0.2em; margin-bottom: 60px; text-align: center; }

/* --- 01. ABOUT US (Redesigned) --- */
#section-about { 
    position: relative; 
    display: flex; 
    flex-direction: column;
    align-items: center; 
    justify-content: center; 
    height: 100vh;
    padding: 100px 40px 150px;  /* 下部を60px → 150px（2.5倍）に */
}

/* 球体コンテナ */
.baby-sphere-container {
    width: 100%;
    max-width: 600px;
    margin: 0 auto 20px;  /* 60px → 20px */
    display: flex;
    justify-content: center;
    align-items: center;
}

.baby-sphere-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    animation: sphere-float 8s ease-in-out infinite;
}

/* 球体の浮遊アニメーション */
@keyframes sphere-float {
    0%, 100% {
        transform: translateY(0px) translateX(0px);
    }
    25% {
        transform: translateY(-20px) translateX(10px);
    }
    50% {
        transform: translateY(-10px) translateX(-10px);
    }
    75% {
        transform: translateY(-25px) translateX(5px);
    }
}

/* ベース画像 */
.baby-sphere-base {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 20px 60px rgba(38, 198, 218, 0.3));
}

/* 発光エフェクト画像 */
.baby-sphere-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0.6;
    animation: pulse-glow 3s ease-in-out infinite;
    mix-blend-mode: screen;
    pointer-events: none;
}

/* 発光アニメーション */
@keyframes pulse-glow {
    0%, 100% {
        opacity: 0.4;
        filter: blur(0px) brightness(1.2);
    }
    50% {
        opacity: 0.8;
        filter: blur(2px) brightness(1.5);
    }
}

/* テキストコンテナ */
.about-text-container {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.about-title {
    font-size: 28px;
    font-weight: 300;
    letter-spacing: 0.15em;
    color: rgba(38, 198, 218, 1);
    margin-bottom: 40px;
    text-shadow: 0 0 20px rgba(38, 198, 218, 0.5);
}

.about-description {
    font-size: 16px;
    line-height: 2;
    letter-spacing: 0.08em;
    color: rgba(255, 255, 255, 0.85);
}

.about-description p {
    margin: 0;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .baby-sphere-container {
        max-width: 400px;
        margin-bottom: 40px;
    }
    
    .about-title {
        font-size: 22px;
        margin-bottom: 30px;
    }
    
    .about-description {
        font-size: 14px;
        line-height: 1.8;
    }
}

/* --- 02. SERVICES (Redesigned) --- */
#section-service {
    padding-top: 300px;  /* 120px × 2.5 = 300px */
}

.services-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 60px;
}

.service-row {
    display: flex;
    align-items: center;
    gap: 30px;
    padding: 35px 40px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.4s ease;
}

.service-row:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(38, 198, 218, 0.3);
    transform: translateY(-3px);
}

.service-number {
    font-size: 14px;
    color: rgba(38, 198, 218, 0.6);
    font-weight: 300;
    min-width: 30px;
}

.service-info {
    display: flex;
    align-items: center;
    gap: 40px;
    flex: 1;
}

.service-logo {
    height: 50px;
    width: auto;
    opacity: 0.95;
}

.service-description {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.7;
    margin: 0;
    flex: 1;
}

.service-button {
    padding: 12px 32px;
    background: rgba(38, 198, 218, 1);
    color: #000;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.service-button:hover {
    background: rgba(38, 198, 218, 0.8);
    transform: translateX(5px);
    box-shadow: 0 0 20px rgba(38, 198, 218, 0.4);
}

/* レスポンシブ対応 */
@media (max-width: 1024px) {
    .service-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        padding: 30px 25px;
    }
    
    .service-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
        width: 100%;
    }
    
    .service-logo {
        height: 40px;
    }
    
    .service-button {
        width: 100%;
        text-align: center;
    }
}

/* --- 03. RECOMMEND (Redesigned) --- */
.needs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 60px;
}

.needs-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.4s ease;
}

.needs-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(38, 198, 218, 0.3);
    transform: translateY(-5px);
}

.needs-image-container {
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.needs-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

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

.needs-title {
    font-size: 18px;
    font-weight: 400;
    line-height: 1.5;
    color: #ffffff;
    padding: 25px 25px 15px;
    margin: 0;
}

.needs-description {
    font-size: 13px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.6);
    padding: 0 25px 20px;
    margin: 0;
}

.needs-recommend {
    padding: 20px 25px 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.needs-recommend-label {
    font-size: 11px;
    color: rgba(38, 198, 218, 1);
    letter-spacing: 0.1em;
    margin: 0 0 15px 0;
    text-align: center;
}

.needs-logos {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
}

.needs-logo {
    height: 40px;
    width: auto;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.needs-logo:hover {
    opacity: 1;
}

.needs-logo-single {
    height: 45px;
}

/* レスポンシブ対応 */
@media (max-width: 1024px) {
    .needs-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .needs-image-container {
        aspect-ratio: 16 / 9;
    }
}

/* --- 04. CASE STUDY --- */
.case-grid { 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); 
    gap: 20px; 
    margin-top: 60px; 
}

.case-panel { 
    background: rgba(255, 255, 255, 0.02); 
    border: 1px solid rgba(255, 255, 255, 0.05); 
    border-radius: 8px;
    overflow: hidden;
    display: flex; 
    flex-direction: column;
    transition: 0.6s ease; 
    opacity: 0; 
    transform: perspective(1000px) translateZ(-100px); 
}

.case-panel:hover { 
    background: rgba(0, 242, 254, 0.03); 
    border-color: rgba(0, 242, 254, 0.2); 
    transform: perspective(1000px) translateZ(20px); 
}

.case-image-container {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    position: relative;
}

.case-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
    opacity: 0.6;
}

.case-panel:hover .case-image {
    transform: scale(1.1);
    opacity: 0.8;
}

.case-content {
    padding: 30px 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.case-tag { 
    font-size: 10px; 
    color: rgba(255,255,255,0.3); 
    letter-spacing: 0.1em; 
    text-transform: uppercase; 
}

.case-panel h4 { 
    font-size: 18px; 
    font-weight: 300; 
    color: #b0fbff; 
    margin: 0; 
    line-height: 1.4; 
    border-left: 2px solid #00f2fe; 
    padding-left: 15px; 
}

.case-panel p { 
    font-size: 13px; 
    opacity: 0.5; 
    line-height: 1.7; 
    margin: 0; 
}

/* レスポンシブ対応 */
@media (max-width: 1024px) {
    .case-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* --- Global Animation --- */
.is-visible .reveal { opacity: 1 !important; transform: translateY(0) !important; transition: all 1.2s cubic-bezier(0.16, 1, 0.3, 1); }
.is-visible .case-reveal { opacity: 1 !important; transform: perspective(1000px) translateZ(0) !important; transition: all 1.5s cubic-bezier(0.16, 1, 0.3, 1); }

/* --- State Control --- */
body.hero-active { overflow: hidden !important; height: 100vh; }
body.content-active { overflow-y: auto !important; height: auto; }
#rocket-back-btn { position: fixed; bottom: 30px; right: 30px; width: 44px; height: 44px; background: rgba(0, 242, 254, 0.05); border: 1px solid rgba(0, 242, 254, 0.3); border-radius: 50%; cursor: pointer; z-index: 500; display: flex; justify-content: center; align-items: center; transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1); opacity: 0; transform: scale(0.8); pointer-events: none; box-shadow: 0 0 15px rgba(0, 242, 254, 0.1); }
#rocket-back-btn.is-active { opacity: 1; transform: scale(1); pointer-events: auto; }
#rocket-back-btn svg { width: 20px; height: 20px; fill: #00f2fe; filter: drop-shadow(0 0 3px rgba(0, 242, 254, 0.6)); }

/* --- SKIP Button --- */
#skip-btn { 
    position: fixed; 
    bottom: 30px; 
    left: 30px; 
    padding: 8px 16px;
    background: rgba(0, 0, 0, 0.5); 
    border: 1px solid rgba(255, 255, 255, 0.2); 
    border-radius: 4px; 
    color: rgba(255, 255, 255, 0.6);
    font-size: 11px; 
    letter-spacing: 0.15em;
    cursor: pointer; 
    z-index: 500; 
    transition: all 0.3s ease;
    opacity: 1;  /* 最初から表示 */
    pointer-events: auto;  /* 最初から操作可能 */
}
#skip-btn.is-visible { 
    opacity: 1; 
    pointer-events: auto; 
}
#skip-btn:hover { 
    background: rgba(0, 242, 254, 0.1); 
    border-color: rgba(0, 242, 254, 0.5);
    color: #00f2fe;
}

/* --- Scroll Hint --- */
#scroll-hint {
    position: fixed;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 500;
    color: rgba(255, 255, 255, 0.4);
    font-size: 10px;
    letter-spacing: 0.3em;
    opacity: 0;
    display: none;  /* 初期は完全に非表示 */
    pointer-events: none;
    transition: opacity 0.5s ease;
}
#scroll-hint.is-visible {
    display: block;  /* 表示 */
    animation: scroll-hint-pulse 2s ease-in-out infinite;
}
@keyframes scroll-hint-pulse {
    0%, 100% { 
        opacity: 0.4; 
        transform: translateX(-50%) translateY(0);
    }
    50% { 
        opacity: 0.8; 
        transform: translateX(-50%) translateY(-5px);
    }
}

/* ==========================================
   モバイル専用スタイル（完全独立）
   ========================================== */
@media (max-width: 767px) {
  /* 全体のレイアウトリセット */
  body {
    overflow-x: hidden;
    position: relative;
  }
  
  /* 3D関連を完全に非表示 */
  canvas {
    display: none !important;
  }
  
  #genesis-text,
  #scroll-hint,
  #rocket-back-btn,
  #skip-btn {
    display: none !important;
  }
  
  /* 背景を固定 */
  #bg-container {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    opacity: 1 !important;
    z-index: -1 !important;
    filter: brightness(0.6) contrast(1.1);
  }
  
  /* UIレイヤー */
  #ui-layer {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 1000 !important;
    pointer-events: none;
  }
  
  #main-ui {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100vh !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    z-index: 1000 !important;
    background: rgba(0, 0, 0, 0.7) !important;
  }
  
  /* タイトルオーバーレイ非表示 */
  #title-overlay {
    display: none !important;
  }
  
  /* ロゴとキャッチコピー */
  .main-logo-img,
  .catch-copy {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  
  .main-logo-img {
    width: 200px !important;
    max-width: 80vw !important;
    height: auto !important;
  }
  
  .catch-copy {
    font-size: 18px !important;
    margin-top: -40px !important;
    margin-bottom: 30px !important;
  }
  
  /* ヘッダー */
  .header {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 1000 !important;
    padding: 12px 15px !important;
    background: linear-gradient(to bottom, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.6) 70%, transparent 100%) !important;
  }
  
  .header-logo-img {
    height: 20px !important;
  }
  
  .nav {
    gap: 8px !important;
  }
  
  .nav a {
    font-size: 9px !important;
    padding: 4px 8px !important;
    white-space: nowrap !important;
  }
  
  /* メインコンテンツコンテナ */
  #main-scroll-container {
    position: relative !important;
    width: 100% !important;
    margin-top: 0 !important;
    padding-top: 100vh !important;
    z-index: 10 !important;
    background: linear-gradient(to bottom, transparent, rgba(0,0,0,0.8) 10vh, rgba(0,0,0,0.95) 30vh, #000 50vh) !important;
  }
  
  /* コンテンツが表示されたら */
  body.content-active #main-scroll-container {
    visibility: visible !important;
    opacity: 1 !important;
  }
  
  body.content-active #ui-layer,
  body.content-active #main-ui {
    opacity: 0 !important;
    pointer-events: none !important;
  }
  
  /* コンテンツセクション */
  .content-section {
    padding: 60px 20px !important;
    min-height: auto !important;
  }
  
  #section-about {
    height: auto !important;
    min-height: 100vh !important;
    padding: 80px 20px !important;
  }
  
  /* セクションラベル */
  .section-label {
    position: relative !important;
    top: 0 !important;
    left: 0 !important;
    display: block !important;
    text-align: center !important;
    margin-bottom: 20px !important;
  }
  
  /* セクションタイトル */
  .section-title {
    font-size: 24px !important;
    margin-bottom: 30px !important;
  }
  
  /* 球体ビジュアル */
  .sphere-visual {
    width: 250px !important;
    height: 250px !important;
    margin: 0 auto 30px !important;
  }
  
  /* テキストコンテンツ */
  .text-content {
    max-width: 100% !important;
    padding: 0 10px !important;
  }
  
  .text-content p {
    font-size: 14px !important;
    line-height: 1.8 !important;
  }
  
  /* フッター */
  footer {
    padding: 40px 20px !important;
  }
  
  /* スムーズなスクロール */
  html {
    scroll-behavior: smooth;
  }
  
  /* オーバーフロー対策 */
  * {
    max-width: 100vw;
  }
  
  img {
    max-width: 100%;
    height: auto;
  }
}
