/* ------------------------------------------------------------------------------------------------ */
/* **修正点1: 共通リセット** - WordPress環境で余計なマージン/パディングがつくのを防ぐためにリセットを追加 */
/* ------------------------------------------------------------------------------------------------ */
.first-view-container * {
    box-sizing: border-box;
}
/* bodyやhtmlへの影響を避けるため、first-view-containerを包む要素に影響を与えそうなマージンをリセット */
/* WordPressのカスタムHTMLブロック内では:rootやbody/htmlへの直接の影響は推奨されないため、
   通常はコンテナの外側の要素のスタイルを削除しますが、今回は最も効果的なリセットを追加します。 */
:root, body, html {
    margin: 0 !important;
    padding: 0 !important;
    overflow-x: hidden !important; /* 横スクロール防止 */
}
/* ------------------------------------------------------------------------------------------------ */


/* フォント、リセット、ベーススタイル */
.first-view-container {
    /* Noto Serif JPをGoogle Fontsから読み込む */
    width: 100%;
    height: 100vh; /* ビューポート全体を覆う */
    color: #fff;
    /* フォントをNoto Serif JPに変更 */
    font-family: "Noto Serif JP", serif; 
    position: relative;
    overflow: hidden;
    display: flex;
    /* 画面端に寄せるためcenterからflex-startに変更 */
    justify-content: flex-start;
    align-items: flex-start;
}

.first-view-content {
    position: relative;
    /* ----------------------------------- */
    /* **修正点2: 全体のパディングを削除** */
    /* ----------------------------------- */
    padding: 0; 
    width: 100%;
    height: 100%;
    display: flex;
    /* max-widthを削除し、常にビューポートの100%幅を使用 */
    max-width: none; 
    margin: 0; /* マージンを削除 */
    z-index: 10;
}

/* 1. 左側の垂直オーバーレイ */
.left-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 70%; /* 左側パネルの幅を70%に設定 */
    height: 100%;
    
    background-color: rgba(233, 233, 233, 0.85); /* 濃い青みがかったグレーのオーバーレイ */
    background-image: url('./images/3.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-blend-mode: multiply; /* オーバーレイと画像を合成 */

    z-index: 1;
    transition: width 0.3s ease;
}

/* 2. 左側のコンテンツパネル */
.left-panel {
    position: relative;
    flex: 0 0 70%; /* left-overlayと幅を合わせる (70%) */
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: space-around; 
    gap: 40px;
    
    /* ----------------------------------- */
    /* **修正点3: 左パネルのパディングを調整し、端に寄せる** */
    /* ----------------------------------- */
    padding: 80px 40px 80px 80px; /* 上下80px, 左80px, 右40px */
}
.left-panel::after{
    content: "";
    width: 60px;
    height: 100%;
    background-color: rgb(53, 53, 241);
    position: absolute;
    left:100px;
    opacity: 0.85;
    z-index: -1;
	top:0;

}
.intro-text h2 {
    font-size: 2rem; /* 全て2remに統一 */
    margin-bottom: 10px;
    letter-spacing: 1px;
}

/* サービスメニュー (省略...) */
.service-menu {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 400px;
    padding-left: 0; 
}

.service-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-decoration: none;
    color: #fff;
    padding: 15px 20px;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    position: relative;
    overflow: hidden;
    font-size: 1.8rem;
    font-weight: bold;
    letter-spacing: 2px;
}

/* メニューの背景色（画像に近い色味で） */
.service-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.6; /* 透明度 */
    z-index: 0;
}
.service-item.bg-blue::before { background-color: #5d88a8; }
.service-item.bg-purple::before { background-color: #7b5da8; }
.service-item.bg-green::before { background-color: #5d9785; }

.service-name, .service-detail-link {
    position: relative;
    z-index: 1;
}

.service-detail-link {
    font-size: 1rem;
    font-weight: normal;
    display: flex;
    align-items: center;
    gap: 5px;
}
.service-detail-link svg {
    height: 16px;
    width: 16px;
}

.service-item:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}


/* 3. 右側のコンテンツパネル */
.right-panel {
    position: relative;
    flex: 1; /* 残りの幅 (30%) を取る */
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* 上部と下部のコンテンツを切り離す */
    align-items: center; /* 子要素を中央に配置 */
    
    /* ----------------------------------- */
    /* **修正点4: 右パネルのパディングを調整し、端に寄せる** */
    /* ----------------------------------- */
    padding: 80px 40px 80px 40px; 
    
    z-index: 2;
    text-align: center; /* テキストを中央寄せに */
    
    background-image: url('./images/tate-wood-texture_00034.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-color: rgba(0, 0, 0, 0.2); 
    background-blend-mode: multiply;
}

/* 事務所名/コンサルティングライン (省略...) */
.office-info {
    padding-top: 0; /* 親要素のパディングで調整するため削除 */
    width: 95%; 
}

.office-name {
    font-size: 1.7rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.consulting-line {
    font-size: 1.1rem;
    margin: 0;
    opacity: 0.8;
}

/* 連絡先詳細カード (省略...) */
.contact-details-card {
    background-color: rgba(0, 0, 0, 0.5); 
    backdrop-filter: blur(5px);
    padding: 30px;
    border-radius: 10px;
    width: 95%; 
}

.contact-details {
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    padding-top: 15px;
    text-align: left !important; 
}

.contact-details p {
    font-size: 0.9rem;
    margin-bottom: 5px;
    line-height: 1.6;
}

.contact-details a {
    color: #fff;
    text-decoration: underline;
    transition: opacity 0.3s;
}

.contact-details a:hover {
    opacity: 0.8;
}

/* ======================================================
   レスポンシブデザイン (モバイル対応)
   ====================================================== */
@media (max-width: 768px) {
    /* モバイルでは縦積みにする */
    .first-view-container {
        height: auto;
        min-height: 100vh;
    }

    .first-view-content {
        flex-direction: column;
    }

    .left-overlay {
        width: 100%; /* フル幅に */
        height: 100%; /* left-panelをカバー */
        top: 0;
        background-color: rgba(233, 233, 233, 0.85);
        background-image: url('./images/4.png');
        background-size: cover;
        background-position: center;
        background-attachment: scroll; /* モバイルではfixedは避ける */
        background-blend-mode: multiply;
    }
    
    .left-panel, .right-panel {
        flex: 1 1 100%;
        width: 100%;
        /* ----------------------------------- */
        /* **修正点5: モバイルの左右パディングを調整** */
        /* ----------------------------------- */
        padding: 40px 20px; /* 上下40px, 左右20px */
        align-items: center;
        text-align: center;
    }

    .left-panel {
        padding-top: 80px; /* 上部に余白 */
        justify-content: space-around; 
    }
    .left-panel::after{
    content: "";
    width: 80px;
    height: 100%;
    background-color: rgb(53, 53, 241);
    position: absolute;
    left:120px;
    opacity: 0.85;
    z-index: -1;
	top:0;

}
    /* モバイルでのh2スタイルを調整 */
    .intro-text h2 { 
        font-size: 1.4rem; 
        margin: 5px 0;
    }
    
    .right-panel {
        padding-bottom: 60px;
        justify-content: flex-start; 
        
        background-image: url('./images/tate-wood-texture_00034.jpg');
        background-size: cover;
        background-position: center;
        background-attachment: scroll;
        background-color: rgba(0, 0, 0, 0.2); 
        background-blend-mode: multiply;
    }

    .office-info {
        padding-top: 0;
        margin-bottom: 30px; 
        width: 100%; 
    }
    
    .contact-details-card {
        text-align: center; 
        max-width: 90%;
        align-self: center; 
        width: 100%; 
    }

    .contact-details {
        text-align: left !important; 
    }
}
