/* ======================================================= */
/* TOPページ専用のレイアウトスタイル */
/* ======================================================= */

/* 共通のstyle.cssでbody, #main-contentなどの基本設定は行われています */

/* トップビジュアル */
.top-visual {
    margin-bottom: 20px;
    text-align: center;
}
.top-visual img {
    /* 既存の 638px の幅をmax-widthで再現しつつ、スマホでは100%になる */
    max-width: 638px;
    width: 100%; 
    height: auto;
}

/* トピックスセクション */
.topics {
    display: flex;
    align-items: flex-start; /* 既存のテイストに合わせて上揃え */
    padding: 10px 0;
    margin-bottom: 20px;
    border-top: 1px solid #ddd;
    border-bottom: 1px solid #ddd;
}
.topics-header img {
    max-width: 150px;
    height: auto;
    margin-right: 15px;
}
.topics-content {
    flex-grow: 1;
    font-size: 0.9em;
}
.topics-content p {
    margin: 5px 0;
}
.highlight a {
    color: #c00; /* 目立つ色 */
    font-weight: bold;
}

/* ご注文・ハートハンズセクション */
.order-section {
    text-align: center;
    margin: 20px 0;
}
.order-buttons {
    display: flex;
    justify-content: center;
    align-items: flex-end; /* 下揃えにすることでキャプションとボタンの高さを調整 */
    gap: 20px;
    flex-wrap: wrap; /* スマホで折り返す */
}
.order-form-link img {
    max-width: 365px;
    height: auto;
}
.hearthands-container {
    text-align: center;
    margin-top: 10px;
}
.hearthands-caption {
    margin: 0;
    font-size: 12px;
    line-height: 1.2;
    margin-bottom: -5px;
}
.hearthands-link img {
    max-width: 125px; /* 元のサイズを基準に設定 */
    height: auto;
}

/* コンタクト情報セクション */
.contact-info {
    text-align: center;
    margin: 20px 0;
}
.contact-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}
.contact-buttons img {
    max-width: 113px; /* ボタン画像の最大幅 */
    height: auto;
}
.contact-text {
    font-size: 0.9em;
    white-space: nowrap;
}

/* PDFノーティスセクション */
.pdf-notice {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin: 20px 0;
    padding: 10px;
    border: 1px dashed #ccc;
    flex-wrap: wrap;
    text-align: left;
}
.pdf-text-box {
    flex: 1;
    min-width: 280px;
    font-size: 0.85em;
}
.pdf-icon img {
    max-width: 112px;
}

/* 商品グリッド (上部4点) */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* PCでは4列 */
    gap: 15px;
    text-align: center;
    margin: 20px 0;
}
.products-grid img, 
.bottom-products img {
    max-width: 150px; /* 画像の元の幅を維持 */
    height: auto;
}

/* 下部商品 (下部2点) */
.bottom-products {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

/* クイックリンク */
.quick-links {
    max-width: 638px; /* 元の幅を最大幅として維持 */
    margin: 0 auto 30px;
}
.quick-links-row {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}
.quick-links-row .nav-button {
    flex: 1;
    text-align: center;
}
.quick-links-row .nav-button img {
    max-width: 311px;
    width: 100%;
}

/* サイトフッター */
#site-footer {
    /* 共通CSSのfooterとは別に、TOPページ独自の会社情報を表示 */
    text-align: center;
    padding: 20px;
    background-color: #f8f8f8;
    border-top: 1px solid #ddd;
    color: #333;
}
.company-info img {
    max-width: 235px;
    margin-bottom: 10px;
}
.company-address, .mail-info {
    font-style: normal;
    font-size: 0.9em;
    line-height: 1.5;
    margin: 5px 0;
}
.mail-link img {
    max-width: 28px;
    vertical-align: middle;
    margin-right: 5px;
}

/* ======================================================= */
/* スマホ対応 (Max-width: 600px) */
/* ======================================================= */
@media (max-width: 600px) {
    #main-content {
        padding: 10px;
    }

    /* トピックス */
    .topics {
        flex-direction: column; /* 縦に並べる */
        text-align: center;
    }
    .topics-header {
        margin-bottom: 10px;
        justify-content: center;
    }
    .topics-header img {
        margin-right: 0;
    }
    .topics-content {
        margin-left: 0;
    }
    
    /* ご注文・ハートハンズセクション */
    .order-buttons {
        flex-direction: column; /* 縦に並べる */
        gap: 15px;
    }
    .order-form-link img {
        max-width: 100%; /* スマホ幅いっぱいに */
    }

    /* コンタクト情報 */
    .contact-buttons {
        flex-direction: column; 
        gap: 10px;
    }

    /* PDFノーティス */
    .pdf-notice {
        flex-direction: column;
        text-align: center;
    }
    .pdf-text-box {
        min-width: unset;
        margin-right: 0;
    }

    /* 商品グリッド */
    .products-grid {
        grid-template-columns: repeat(2, 1fr); /* 2列に変更 */
        gap: 10px;
    }
    .products-grid img, 
    .bottom-products img {
        max-width: 100%; /* 親要素いっぱいに */
    }

    /* 下部商品 */
    .bottom-products {
        flex-direction: column;
        align-items: center;
    }
    .bottom-products .product-item {
        width: 80%; /* 幅を制限して見やすく */
        max-width: 250px;
    }

    /* クイックリンク */
    .quick-links-row {
        flex-direction: column; /* 縦に並べる */
        gap: 10px;
        margin-bottom: 10px;
    }
}