/* 全体のベース設定 */
body {
    margin: 0;
    padding: 0;
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    color: #333333;
    line-height: 1.8;
    letter-spacing: 0.05em; /* 文字の間隔を広げて洗練させる */
    background-color: #ffffff;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

/* ヘッダー */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    background-color: #fff;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.logo {
    display: flex;
    flex-direction: column;
}
.logo-main {
    font-size: 1.3rem;
    font-weight: bold;
    color: #002b66; /* 誠実なディープブルー */
    letter-spacing: 0.02em;
}
.logo-sub {
    font-size: 0.7rem;
    color: #888888;
    font-weight: bold;
    letter-spacing: 0.1em;
    margin-top: 2px;
}

.global-nav ul {
    display: flex;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
}

.global-nav ul li {
    margin-left: 30px;
    font-weight: 500;
    font-size: 0.95rem;
}

.btn-nav-contact {
    background-color: #002b66;
    color: #ffffff !important;
    padding: 10px 24px;
    border-radius: 4px;
    font-weight: bold;
}
.btn-nav-contact:hover {
    background-color: #001f4d;
}

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: none;
    background: transparent;
    padding: 0;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: #002b66;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.contact-menu-wrap {
    position: relative;
}

.contact-menu {
    position: relative;
}

.contact-menu summary {
    list-style: none;
}

.contact-menu summary::-webkit-details-marker {
    display: none;
}

.contact-menu-panel {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 180px;
    background: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
    padding: 8px;
    z-index: 200;
}

.contact-menu-panel a {
    display: block;
    padding: 12px 14px;
    border-radius: 4px;
    color: #333333;
    font-weight: 600;
    white-space: nowrap;
}

.contact-menu-panel a:hover {
    background: #f5f8fd;
    color: #002b66;
}

.contact-menu:not([open]) .contact-menu-panel {
    display: none;
}

@media (max-width: 768px) {
    header {
        flex-wrap: wrap;
        gap: 12px;
    }

    .nav-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .global-nav {
        width: 100%;
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        transition: max-height 0.35s ease, opacity 0.25s ease;
    }

    .global-nav.is-open {
        max-height: 520px;
        opacity: 1;
    }

    .global-nav ul {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 10px;
        padding-top: 10px;
    }

    .global-nav ul li {
        margin-left: 0;
        width: 100%;
        opacity: 0;
        transform: translateY(-6px);
        transition: transform 0.25s ease, opacity 0.25s ease;
    }

    .global-nav.is-open ul li {
        opacity: 1;
        transform: translateY(0);
    }

    .global-nav ul li a,
    .contact-menu summary {
        display: block;
        width: 100%;
        box-sizing: border-box;
        text-align: center;
    }

    .contact-menu-wrap {
        width: 100%;
    }

    .contact-menu-panel {
        position: static;
        min-width: 0;
        box-shadow: none;
        border-radius: 0;
        margin-top: 8px;
    }

    .contact-menu-panel a {
        text-align: center;
    }

    .contact-menu-panel {
        right: auto;
        left: 0;
    }
}

/* メインビジュアル */
.main-visual {
    background: #e9eff5;
    padding-left: 0;
}

.main-visual-image {
    display: block;
    width: 100%;
    height: auto;
}

.mv-text h2 {
    font-size: 2.6rem;
    font-weight: bold;
    color: #111111;
    margin-bottom: 15px;
}
.mv-text p {
    font-size: 1.1rem;
    color: #555555;
}

/* セクション共通 */
.section-container {
    padding: 90px 8%;
}
.bg-gray {
    background-color: #fafafa;
}

/* 特徴的な見出し（英語＋日本語） */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}
.en-title {
    display: block;
    font-size: 0.8rem;
    font-weight: bold;
    color: #002b66;
    letter-spacing: 0.25em;
    margin-bottom: 8px;
}
.ja-title {
    font-size: 1.7rem;
    margin: 0;
    font-weight: bold;
    color: #111111;
}

/* 会社情報 */
.company-info-grid {
    max-width: 780px;
    margin: 0 auto;
    background-color: #fff;
    border: 1px solid #ececec;
    border-radius: 4px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    padding: 32px;
}

.company-info-list {
    display: grid;
    grid-template-columns: 140px 1fr;
    row-gap: 18px;
    column-gap: 18px;
    margin: 0;
}

.company-info-list dt {
    font-weight: bold;
    color: #002b66;
}

.company-info-list dd {
    margin: 0;
    color: #333333;
}

@media (max-width: 768px) {
    .company-info-grid {
        padding: 24px;
    }

    .company-info-list {
        grid-template-columns: 1fr;
        row-gap: 8px;
    }

    .company-info-list dt {
        margin-top: 8px;
    }
}

/* 施工事例のグリッド（4枚に合わせて自動調整） */
.case-category-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 18px 0 20px;
    font-size: 1.15rem;
    font-weight: bold;
    color: #002b66;
    letter-spacing: 0.08em;
}

.case-category-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: #002b66;
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: bold;
    flex: 0 0 auto;
}

.case-grid {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    padding: 4px 8px 12px;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.case-card {
    flex: 0 0 min(86vw, 520px);
    background-color: #fff;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    border: 1px solid #ececec;
    scroll-snap-align: start;
}

/* 画像を表示する枠（位置基準を設定） */
.case-img {
    padding: 0;
    overflow: hidden;
    position: relative; /* 💡タグを写真の上に浮かせるために必要 */
    background-color: #fafafa;
    aspect-ratio: 4 / 3;
    display: flex;
    align-items: center;
    justify-content: center;
}

.roof-case-slider .case-img {
    aspect-ratio: 4 / 3;
}

/* 枠の中の画像自体 */
.case-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    transition: none;
    background-color: #ffffff;
}

.roof-case-slider .case-img img {
    height: 100%;
    object-fit: cover;
}

.roof-case-slider .case-img img.roof-portrait {
    object-fit: contain;
    background-color: #ffffff;
}

/* 💡新しく追加：写真の左上に浮かぶカテゴリタグ */
.category-tag {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: #002b66; /* GEAR2のブランドカラー（ネイビー） */
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: bold;
    padding: 4px 12px;
    border-radius: 2px;
    z-index: 10;
    letter-spacing: 0.05em;
}

/* マウスを乗せたときに写真を少しズームアップ */
.case-card:hover .case-img img {
    transform: none;
}

.case-info {
    padding: 24px;
}
.case-info h4 {
    margin: 0 0 12px 0;
    font-size: 1.1rem;
    font-weight: bold;
    line-height: 1.5;
}
.case-info p {
    margin: 0;
    font-size: 0.85rem;
    color: #666666;
    line-height: 1.7;
}

/* カルーセルの矢印 */
.case-slider {
    position: relative;
}

.case-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 43, 102, 0.92);
    color: #fff;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    z-index: 5;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

.case-nav:hover {
    background: #001f4d;
}

.case-nav.prev {
    left: -12px;
}

.case-nav.next {
    right: -12px;
}

@media (max-width: 768px) {
    .case-card {
        flex-basis: 88vw;
    }

    .case-nav {
        width: 38px;
        height: 38px;
        font-size: 1.4rem;
    }

    .case-nav.prev {
        left: -4px;
    }

    .case-nav.next {
        right: -4px;
    }
}

/* お客様の声 */
.voice-group {
    margin: 18px 0 34px;
}

.voice-title {
    margin: 0 0 12px;
    font-size: 0.92rem;
    font-weight: bold;
    color: #002b66;
    letter-spacing: 0.08em;
}

.voice-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.voice-card {
    margin: 0;
    background: #f8fbff;
    border: 1px solid #d9e6f8;
    border-radius: 4px;
    padding: 14px 16px;
}

.voice-card p {
    margin: 0 0 8px;
    font-size: 0.84rem;
    color: #444444;
    line-height: 1.75;
}

.voice-card cite {
    display: block;
    font-style: normal;
    font-size: 0.76rem;
    color: #5b6b84;
    text-align: right;
}

.voice-more-btn {
    display: none;
}

@media (max-width: 768px) {
    .voice-group.is-collapsed .voice-list .voice-card:nth-child(n+3) {
        display: none;
    }

    .voice-more-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        margin-top: 10px;
        padding: 8px 16px;
        border: 1px solid #b8cbea;
        border-radius: 999px;
        background: #ffffff;
        color: #1f3764;
        font-size: 0.75rem;
        font-weight: bold;
        letter-spacing: 0.04em;
        cursor: pointer;
    }

    .voice-group {
        margin: 14px 0 28px;
    }

    .voice-title {
        font-size: 0.86rem;
        margin-bottom: 10px;
        letter-spacing: 0.06em;
    }

    .voice-list {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .voice-card {
        padding: 12px 12px 11px;
        border-radius: 8px;
    }

    .voice-card p {
        font-size: 0.8rem;
        line-height: 1.82;
        word-break: break-word;
    }

    .voice-card p strong {
        display: block;
        margin-bottom: 6px;
        font-size: 0.84rem;
        line-height: 1.6;
        color: #1d2f52;
    }

    .voice-card cite {
        margin-top: 8px;
        font-size: 0.72rem;
    }
}

/* もっと見るボタン */
.more-btn-area {
    text-align: center;
    margin-top: 50px;
}
.btn-more {
    display: inline-block;
    border: 1px solid #002b66;
    color: #002b66;
    padding: 12px 60px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: bold;
    letter-spacing: 0.1em;
}
.btn-more:hover {
    background-color: #002b66;
    color: #fff;
}

/* リフォームメニュー */
.menu-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}
.menu-item a {
    display: block;
    background-color: #ffffff;
    padding: 30px;
    border: 1px solid #e5e5e5;
    font-weight: bold;
    font-size: 1.05rem;
}
.menu-item a:hover {
    border-color: #002b66;
    color: #002b66;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

/* FAQ */
.faq-list {
    max-width: 920px;
    margin: 0 auto;
    display: grid;
    gap: 12px;
}

.faq-item {
    background-color: #ffffff;
    border: 1px solid #e5eaf2;
    border-radius: 8px;
    overflow: hidden;
}

.faq-item summary {
    list-style: none;
    cursor: pointer;
    padding: 16px 48px 16px 18px;
    position: relative;
    font-weight: bold;
    color: #1f2f49;
    line-height: 1.6;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::before {
    content: "Q";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    margin-right: 10px;
    border-radius: 50%;
    background: #002b66;
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: bold;
}

.faq-item summary::after {
    content: "+";
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    color: #5a6e90;
    font-weight: 500;
}

.faq-item[open] summary::after {
    content: "−";
}

.faq-item p {
    margin: 0;
    padding: 0 18px 16px 18px;
    color: #4a5568;
    font-size: 0.92rem;
    line-height: 1.9;
}

@media (max-width: 768px) {
    .faq-item summary {
        padding: 14px 42px 14px 14px;
        font-size: 0.9rem;
    }

    .faq-item summary::before {
        width: 20px;
        height: 20px;
        margin-right: 8px;
        font-size: 0.72rem;
    }

    .faq-item summary::after {
        right: 12px;
    }

    .faq-item p {
        padding: 0 14px 14px;
        font-size: 0.84rem;
        line-height: 1.8;
    }
}

/* フッター */
footer {
    background-color: #111111;
    color: #ffffff;
    padding: 60px 8% 30px;
    text-align: center;
}
.footer-logo {
    font-size: 1.4rem;
    font-weight: bold;
    letter-spacing: 0.05em;
    margin-bottom: 20px;
}
.footer-copy {
    font-size: 0.75rem;
    color: #888888;
    margin: 0;
}