/* ========================================
   custom_legal.css
   特定商取引法・利用規約ページ
   https://shosha-plus.com/
======================================== */

/* メインコンテナ */
.ec-legal-page {
    max-width: 900px !important;
    width: 90% !important;
    margin: 0 auto !important;
    padding: 40px 0 80px !important;
}

/* ページヘッダー */
.ec-legal-header {
    margin-top: 24px !important;
}

.ec-legal-header h1 {
    font-size: 24px !important;
    font-weight: 700 !important;
    color: #23AC38 !important;
    text-align: center !important;
    margin: 0 0 40px !important;
    padding: 0 0 16px !important;
    border-bottom: 2px solid #23AC38 !important;
}

/* セクション */
.ec-legal-section {
    width: 90% !important;
    margin: 0 auto 48px !important;
}

.ec-legal-section:last-child {
    margin-bottom: 0 !important;
}

/* セクション見出し */
.ec-legal-heading {
    font-size: 18px !important;
    font-weight: 700 !important;
    color: #333 !important;
    margin: 0 0 24px !important;
    padding: 12px 16px !important;
    background: #f8f8f8 !important;
    border-left: 4px solid #23AC38 !important;
    border-radius: 0 4px 4px 0 !important;
}

/* テーブル */
.ec-legal-table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #ddd !important;
    border-radius: 8px !important;
    overflow: hidden !important;
    font-size: 14px !important;
    background: #fff !important;
}

/* テーブルヘッダー（th） */
.ec-legal-table th {
    width: 180px !important;
    padding: 16px 20px !important;
    background: #f5f5f5 !important;
    color: #333 !important;
    font-weight: 600 !important;
    text-align: left !important;
    vertical-align: top !important;
    border-bottom: 1px solid #e0e0e0 !important;
    border-right: 1px solid #e0e0e0 !important;
}

/* テーブルデータ（td） */
.ec-legal-table td {
    padding: 16px 20px !important;
    background: #fff !important;
    color: #555 !important;
    line-height: 1.8 !important;
    vertical-align: top !important;
    border-bottom: 1px solid #e0e0e0 !important;
}

/* 最終行のボーダー削除 */
.ec-legal-table tr:last-child th,
.ec-legal-table tr:last-child td {
    border-bottom: none !important;
}

/* 行ホバー */
.ec-legal-table tr:hover th {
    background: #eef7ef !important;
}

.ec-legal-table tr:hover td {
    background: #fafafa !important;
}

/* ========================================
   レスポンシブ
======================================== */
@media (max-width: 768px) {
    .ec-legal-page {
        width: 95% !important;
        padding: 24px 0 60px !important;
    }

    .ec-legal-header {
        margin-top: 16px !important;
    }

    .ec-legal-header h1 {
        font-size: 20px !important;
        margin-bottom: 32px !important;
    }

    .ec-legal-section {
        width: 100% !important;
        margin-bottom: 32px !important;
    }

    .ec-legal-heading {
        font-size: 16px !important;
        margin-bottom: 16px !important;
        padding: 10px 12px !important;
    }

    /* テーブルを縦並びに */
    .ec-legal-table,
    .ec-legal-table tbody,
    .ec-legal-table tr,
    .ec-legal-table th,
    .ec-legal-table td {
        display: block !important;
        width: 100% !important;
    }

    .ec-legal-table {
        border: none !important;
    }

    .ec-legal-table tr {
        margin-bottom: 16px !important;
        border: 1px solid #ddd !important;
        border-radius: 8px !important;
        overflow: hidden !important;
    }

    .ec-legal-table th {
        padding: 12px 16px !important;
        border-right: none !important;
        border-bottom: 1px solid #e0e0e0 !important;
        background: #23AC38 !important;
        color: #fff !important;
    }

    .ec-legal-table td {
        padding: 16px !important;
        font-size: 13px !important;
        border-bottom: none !important;
    }

    .ec-legal-table tr:hover th {
        background: #23AC38 !important;
    }
}

/* 商品ページ下部余白 */
.ec-productRole + div,
.ec-layoutRole__main > div:last-child {
    margin-bottom: 24px !important;
}
