/* 基本設定 */
body {
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    background-color: #121212;
    color: #ffffff;
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

/* ヘッダー */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    background-color: rgba(0, 0, 0, 0.5);
    position: fixed;
    width: 95%;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 24px;
    font-weight: bold;
}

.logo img {
    width: 150px;
    height: auto;
}

.header nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

.header nav a {
    color: #fff;
    text-decoration: none;
    font-size: 16px;
}

.contact-btn {
    background-color: #007bff;
    padding: 8px 15px;
    border-radius: 5px;
}

/* ヒーローセクション */
.hero {
    height: 100vh;
    position: relative; /* 子要素を絶対配置するための基準点 */
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    overflow: hidden; /* はみ出した動画を隠す */
}

/* 背景動画のスタイリング */
.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 80%;
    /* zoom: 120%; */
    z-index: -1; /* テキストの背面に配置 */
}

.hero-video video {
    width: 100%;
    height: 100%;
    object-fit: cover; /* 画面いっぱいに動画を表示（アスペクト比維持） */
}

/* 動画の上の黒いオーバーレイ（文字を読みやすくするため） */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); 
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 4rem;
    margin: 0;
}

.hero p {
    font-size: 1.5rem;
}

/* 汎用セクション設定 */
section {
    padding: 80px 50px;
    text-align: center;
}

section h2 {
    font-size: 2.5rem;
    margin-bottom: 50px;
}

/* 強みセクション */
.features-grid {
    display: flex;
    justify-content: space-around;
    gap: 30px;
}

.feature-item {
    flex-basis: 30%;
}

.feature-item img {
    width: 270px;
    height: 200px;
    object-fit: cover;
    border-radius: 50%;
}

/* ギャラリーセクション */
.gallery-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
}

.gallery-grid img {
    width: 300px;
    height: 200px;
    object-fit: cover;
    border: 2px solid #333;
}

/* CTAセクション */
.cta {
    background-color: #000;
}

.cta-buttons {
    margin-top: 30px;
}

/* 汎用ボタン */
.btn {
    display: inline-block;
    padding: 15px 30px;
    border: 1px solid #fff;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    margin: 0 10px;
    transition: all 0.3s;
}

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

.btn-primary {
    background-color: #007bff;
    border-color: #007bff;
}

.btn-primary:hover {
    background-color: #0056b3;
    color: #fff;
}

/* ===============================================
  メニューページ用のスタイル
=============================================== 
*/

/* ページヘッダー（各下層ページのタイトル部分） */
.page-header {
    padding: 120px 50px 60px; /* ヘッダーに隠れないように上を多めに空ける */
    background: url('https://via.placeholder.com/1920x400/000000/000000?text=') no-repeat center center/cover; /* ここに背景画像を指定 */
    position: relative;
    text-align: center;
}
.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
}
.page-header-content {
    position: relative;
}
.page-header h1 {
    font-size: 3rem;
    margin: 0;
}
.page-header p {
    font-size: 1.2rem;
    color: #ccc;
}

/* 導入文セクション */
.intro {
    padding-top: 60px;
    padding-bottom: 60px;
}
.intro p {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.8;
}

/* 料金プラン */
.pricing-plans {
    background-color: #1a1a1a;
}
.plans-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}
.plan-card {
    background-color: #222;
    border: 1px solid #444;
    padding: 40px;
    flex-basis: 350px; /* カードの基本幅 */
    text-align: left;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative; /* リボンの基準点 */
    overflow: hidden; /* リボンのはみ出しを制御 */
}
.plan-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
}

.plan-card h3 {
    font-size: 1.8rem;
    text-align: center;
    margin-top: 0;
}
.plan-card .catchphrase {
    text-align: center;
    color: #ccc;
    margin-bottom: 30px;
    min-height: 40px; /* 高さを揃える */
}

/* 一番人気のリボン */
.recommended {
    border-color: #007bff;
}
.ribbon {
    position: absolute;
    top: 15px;
    right: -35px;
    background-color: #007bff;
    color: #fff;
    padding: 5px 40px;
    transform: rotate(45deg);
    font-size: 14px;
    font-weight: bold;
}

/* 価格表 */
.price-table {
    width: 100%;
    margin-bottom: 30px;
    border-collapse: collapse;
}
.price-table th, .price-table td {
    padding: 10px;
    border-bottom: 1px solid #444;
}
.price-table th {
    text-align: left;
    font-weight: normal;
}
.price-table td {
    text-align: right;
    font-weight: bold;
    font-size: 1.2rem;
}
.normal-price{
    font-size: 1rem;
    text-decoration: line-through;
}
.campain-price{
    font-size: 1.2rem;
    color: #c0392b;
}
.attention{
    max-width: 800px;
    margin: 30px auto;
    width: 100%;
    text-align: left;
}

/* 特徴リスト */
.features-list {
    list-style: none;
    padding: 0;
    margin-bottom: 40px;
}
.features-list li {
    margin-bottom: 10px;
}
.check {
    color: #007bff;
    margin-right: 10px;
}

/* オプションメニュー */
.options-table {
    max-width: 800px;
    margin: 0 auto;
    width: 100%;
    text-align: left;
    border-collapse: collapse;
}
.options-table th, .options-table td {
    padding: 20px;
    border-bottom: 1px solid #444;
}
.options-table td {
    font-weight: bold;
    font-size: 1.2rem;
}
.options-text {
    max-width: 800px;
    margin: 30px auto;
    width: 100%;
    text-align: left;
}

/* ===============================================
  施工実績ページ用のスタイル
=============================================== 
*/

/* 一覧ページ：ギャラリーセクション */
.gallery-section {
    padding-top: 60px;
    padding-bottom: 60px;
}

.gallery-grid-works {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr)); /* 画面幅に応じて列数を自動調整 */
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    display: block;
    text-decoration: none;
}

.gallery-item img {
    width: 100%;
    display: block;
    transition: transform 0.4s ease;
}

.gallery-item:hover img {
    transform: scale(1.1); /* マウスを乗せると画像を拡大 */
}

.gallery-item .caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: #fff;
    padding: 30px 20px 20px;
    font-size: 1.2rem;
    font-weight: bold;
    opacity: 0; /* 最初は非表示 */
    transform: translateY(20px);
    transition: opacity 0.4s, transform 0.4s;
}

.gallery-item:hover .caption {
    opacity: 1; /* マウスを乗せるとキャプションを表示 */
    transform: translateY(0);
}


/* ページネーション */
.pagination {
    text-align: center;
    margin-top: 60px;
}

.page-numbers {
    display: inline-block;
    padding: 10px 15px;
    margin: 0 5px;
    border: 1px solid #555;
    color: #fff;
    text-decoration: none;
}

.page-numbers.current,
.page-numbers:hover {
    background-color: #007bff;
    border-color: #007bff;
}

/* 詳細ページ */
.work-detail-section {
    max-width: 1000px;
    margin: 0 auto;
    padding: 120px 20px 60px;
}

.work-detail-gallery img {
    width: 100%;
    height: auto;
}

.work-caption {
    text-align: center;
    padding: 40px 0;
    border-bottom: 1px solid #444;
}
.work-caption h2 {
    font-size: 2.5rem;
    margin: 0;
}
.work-caption p {
    font-size: 1.2rem;
    color: #ccc;
    margin-top: 10px;
}

/* 詳細ページナビゲーション */
.post-navigation {
    display: flex;
    justify-content: space-between;
    padding: 40px 0;
}
.post-navigation a {
    color: #fff;
    text-decoration: none;
    padding: 10px 20px;
    border: 1px solid #555;
}
.post-navigation a:hover {
    background-color: #333;
}
.post-navigation .back-to-list {
    border: none;
}
.post-navigation .back-to-list:hover {
    background-color: transparent;
    color: #007bff;
}

/* ===============================================
  こだわりページ用のスタイル
=============================================== 
*/
.commitment-section {
    max-width: 1000px;
    margin: 0 auto;
    padding: 60px 20px;
}

.commitment-item {
    display: flex;
    align-items: center;
    gap: 50px;
    margin-bottom: 80px;
}

/* 偶数番目のアイテムは画像とテキストを反転させる */
.commitment-item:nth-child(even) {
    flex-direction: row-reverse;
}

.commitment-image {
    flex: 1;
}

.commitment-image img {
    width: 100%;
    display: block;
}

.commitment-text {
    flex: 1;
}

.commitment-text h3 {
    font-size: 2rem;
    color: #007bff; /* 少しアクセントカラー */
    margin-top: 0;
}

.commitment-text p {
    font-size: 1rem;
    line-height: 1.8;
    color: #ccc;
}

/* ===============================================
  お問い合わせページ用のスタイル
=============================================== 
*/
.contact-section {
    padding: 60px 20px;
}

.contact-container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    gap: 50px;
}

.contact-form-wrapper {
    flex: 1.5; /* フォーム側を少し広く */
}

.contact-info-wrapper {
    flex: 1;
}

.contact-form .form-group {
    margin-bottom: 20px;
}

.contact-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    text-align: left;
}
.contact-form label span {
    display: inline-block;
    margin-left: 10px;
    padding: 2px 8px;
    background-color: #c0392b;
    color: #fff;
    font-size: 12px;
    border-radius: 3px;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    width: 100%;
    padding: 12px;
    background-color: #333;
    border: 1px solid #555;
    color: #fff;
    border-radius: 5px;
}

.submit-btn {
    width: 100%;
    font-size: 1.1rem;
}

.contact-info-wrapper h3 {
    font-size: 1.5rem;
}
.tel-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: #007bff;
    margin: 10px 0;
}
.reception-time {
    color: #ccc;
    margin-top: 0;
}
.info-list {
    list-style: none;
    padding: 0;
}
.info-list li {
    margin-bottom: 15px;
    line-height: 1.6;
}

.map-section {
    /* Google Mapの埋め込みは上下の余白が不要なことが多いので独立させます */
}


/* フッター */
.footer {
    padding: 20px;
    text-align: center;
    background-color: #000;
    border-top: 1px solid #333;
}

/* ===============================================
  レスポンシブ対応（メディアクエリ）
=============================================== */

/* --- 画面幅が768px以下の場合に適用 --- */
@media (max-width: 768px) {

    /* --- ヘッダー --- */
    .header {
        padding: 15px 20px;
    }
    /* PC用のナビゲーションを隠す */
    .main-nav {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: rgba(0,0,0,0.95);
        justify-content: center;
        align-items: center;
        flex-direction: column;
    }
    .main-nav.active {
        display: flex; /* JavaScriptでactiveクラスがついたら表示 */
    }
    .header nav ul {
        flex-direction: column;
        text-align: center;
    }
    .header nav li {
        margin-bottom: 20px;
    }
    .header nav a {
        font-size: 1.2rem;
    }
    .contact-btn {
        background: none;
        padding: 0;
        border-radius: 0;
    }

    /* ハンバーガーメニューの表示 */
    .hamburger-menu {
        display: flex;
        flex-direction: column;
        justify-content: space-around;
        width: 30px;
        height: 21px;
        cursor: pointer;
        z-index: 150;
    }
    .hamburger-menu span {
        display: block;
        height: 3px;
        width: 100%;
        background-color: #fff;
        border-radius: 3px;
        transition: all 0.3s;
    }
    /* ハンバーガーメニューがactiveになったらバツ印に */
    .hamburger-menu.active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }
    .hamburger-menu.active span:nth-child(2) {
        opacity: 0;
    }
    .hamburger-menu.active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
    

    /* --- 全体的な調整 --- */
    section {
        padding: 60px 20px;
    }
    h1, h2, h3 {
        line-height: 1.3;
    }
    .hero h1, .page-header h1 { font-size: 2.5rem; }
    .hero p, .page-header p { font-size: 1rem; }
    section h2 { font-size: 2rem; }


    /* --- 各ページの縦積み対応 --- */

    /* トップページ：強み */
    .features-grid {
        flex-direction: column;
    }

    /* メニューページ：料金プラン */
    .plans-grid {
        flex-direction: column;
    }
    .plan-card {
        flex-basis: auto; /* 幅を自動に */
    }

    /* こだわりページ */
    .commitment-item,
    .commitment-item:nth-child(even) {
        flex-direction: column; /* 常に画像を上、テキストを下 */
    }

    /* お問い合わせページ */
    .contact-container {
        flex-direction: column;
    }
    .tel-number {
        font-size: 2rem;
    }
    
    /* 実績一覧ページ */
    .gallery-grid-works {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}
/* ===============================================
  ライトボックス用のスタイル
=============================================== */
.lightbox {
    display: none; /* 初期状態では非表示 */
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    justify-content: center;
    align-items: center;
}

.lightbox.active {
    display: flex; /* activeクラスがついたら表示 */
}

.lightbox-content {
    max-width: 90%;
    max-height: 80%;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.lightbox-close:hover {
    color: #bbb;
}