@charset "UTF-8";

/* =========================================
   パンくずリスト
   ========================================= */
.breadcrumb {
    padding: 15px 0;
    background-color: #fff;
    border-bottom: 1px solid #eee;
}
.breadcrumb ul {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    font-size: 13px;
    color: #666;
}
.breadcrumb li {
    display: flex;
    align-items: center;
    gap: 10px;
}
.breadcrumb li:not(:last-child)::after {
    content: '>';
    color: #ccc;
    font-size: 12px;
}
.breadcrumb a {
    color: #666;
    display: flex;
    align-items: center;
}
.breadcrumb a:hover {
    color: var(--primary-color);
}

/* =========================================
   レイアウト
   ========================================= */
.page-wrapper {
    padding: 60px 0 100px;
    background-color: #F9F9F9;
}

/* =========================================
   メインコンテンツ (1カラム)
   ========================================= */
.page-main {
    background-color: #fff;
    padding: 60px;
    border: 1px solid #ddd;
    box-shadow: 0 5px 20px rgba(0,0,0,0.02);
    /* ▼ 変更: 幅の制限を解除し、パンくず(コンテナ)と同じ幅に広げる */
    width: 100%; 
    margin: 0 auto;
    box-sizing: border-box;
}

/* -----------------------------------------
   見出しスタイル
   ----------------------------------------- */
/* 大見出し (H1) */
.page-header-title {
    border: 1px solid #ddd;
    background: #fff;
    padding: 20px 20px 20px 45px;
    position: relative;
    font-size: 24px;
    font-weight: bold;
    color: #333;
    margin-top: 0;
    margin-bottom: 30px;
}
/* H1: 左側の線 */
.page-header-title::before {
    content: "";
    position: absolute;
    left: -1px;
    top: 15px;
    bottom: 15px;
    width: 4px;
    background-color: var(--primary-color);
}
/* H1: 左側の三角形 */
.page-header-title::after {
    content: "";
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 8px solid var(--primary-color);
}

/* 中見出し (H2) */
.page-content h2 {
    background-color: #f5f5f5;
    border-left: 5px solid var(--primary-color);
    padding: 15px 20px;
    font-size: 20px;
    font-weight: bold;
    color: #333;
    margin: 50px 0 25px;
}

/* 小見出し (H3) */
.page-content h3 {
    position: relative;
    padding-left: 20px;
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin: 40px 0 20px;
}
/* H3: 左側の三角形 */
.page-content h3::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
    border-left: 7px solid var(--primary-color);
}

/* -----------------------------------------
   本文スタイル
   ----------------------------------------- */
.page-content {
    font-size: 15px;
    line-height: 1.8;
    color: #333;
    word-break: break-word;
    overflow-wrap: break-word;
}
:where(.page-content) p {
    margin-bottom: 25px;
}
.page-content a {
    color: var(--primary-color);
}
.page-content a:hover {
    text-decoration: none;
}
.page-content img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 30px 0;
}

/* 区切り線 */
.page-divider {
    height: 1px;
    background-color: #ddd;
    margin: 40px 0;
}

/* -----------------------------------------
   リストスタイル
   ----------------------------------------- */
.page-list {
    margin-bottom: 30px;
    padding-left: 5px;
}
.page-list li {
    position: relative;
    padding-left: 15px;
    margin-bottom: 10px;
}
.page-list li::before {
    content: '・';
    position: absolute;
    left: 0;
    top: 0;
    color: #666;
}

/* -----------------------------------------
   テーブルスタイル
   ----------------------------------------- */
.page-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
}
.page-content th, 
.page-content td {
    border: 1px solid #ddd;
    padding: 15px 20px;
    text-align: left;
    font-size: 14px;
    vertical-align: top;
}
.page-content th {
    background-color: #fafafa;
    width: 35%;
    font-weight: normal;
    color: #555;
}


.page-content .wp-block-table thead,
.page-content .wp-block-table tbody,
.page-content .wp-block-table tfoot {
    border: none !important; /* デフォルトの3pxの線を消す */
}
.page-content .wp-block-table {
    margin: 0; /* 既にtableタグでmarginを取っているので余分な余白を消す */
}


.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 30px 0;
}
.table-responsive table {
    margin: 0;
    min-width: 600px; 
}





/* =========================================
   WordPress 標準ブロック (Gutenberg) スタイル
   ========================================= */

/* 引用ブロック (blockquote) */
.page-content .wp-block-quote {
    margin: 30px 0;
    padding: 20px 30px;
    background-color: #f9f9f9;
    border-left: 5px solid var(--primary-color); /* 紫のライン */
    font-style: normal;
    color: #555;
}
.page-content .wp-block-quote p {
    margin-bottom: 10px;
}
.page-content .wp-block-quote cite {
    font-size: 13px;
    color: #999;
    display: block;
    margin-top: 10px;
    text-align: right;
}

/* ボタンブロック */
.page-content .wp-block-button__link {
    background-color: var(--primary-color);
    color: #fff;
    border-radius: 30px;
    padding: 12px 30px;
    text-decoration: none;
    display: inline-block;
    font-weight: bold;
    transition: opacity 0.3s;
    border: none;
}
.page-content .wp-block-button__link:hover {
    opacity: 0.9;
    color: #fff;
    text-decoration: none;
}
/* 白抜きボタン (アウトライン) */
.page-content .wp-block-button.is-style-outline .wp-block-button__link {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}
.page-content .wp-block-button.is-style-outline .wp-block-button__link:hover {
    background-color: var(--primary-color);
    color: #fff;
}

/* アコーディオン (詳細ブロック) */
.page-content .wp-block-details {
    margin: 30px 0;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
}
.page-content .wp-block-details summary {
    padding: 15px 20px;
    font-weight: bold;
    cursor: pointer;
    background: #f5f5f5;
    outline: none;
    list-style-position: inside; /* ブラウザ標準の矢印 */
}
.page-content .wp-block-details summary:hover {
    background: #eee;
}
.page-content .wp-block-details > *:not(summary) {
    padding: 20px;
    margin: 0;
    border-top: 1px solid #ddd;
}

/* ギャラリーブロック */
.page-content .wp-block-gallery {
    margin: 30px 0;
}

/* カバーブロック */
.page-content .wp-block-cover {
    margin: 30px 0;
    padding: 40px 20px;
}

/* カラムブロックのスマホ調整 */
@media (max-width: 600px) {
    .page-content .wp-block-columns:not(.is-not-stacked-on-mobile) {
        display: block;
    }
    .page-content .wp-block-column {
        margin-bottom: 20px;
    }
}




/* =========================================
   目次 (TOC) スタイル
   ========================================= */
.toc-box {
    margin: 40px 0;
    background: #fff;
    border: 1px solid #ddd;
    max-width: 600px;
}
.toc-header {
    background-color: #f5f5f5;
    padding: 15px 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-bottom: 1px solid #ddd;
    cursor: pointer;
    position: relative;
    transition: background-color 0.3s;
}
.toc-header:hover {
    background-color: #eee;
}
.toc-title {
    font-size: 16px;
    color: #555;
    font-weight: 500;
}
.toc-toggle {
    position: absolute;
    right: 20px;
    font-size: 14px;
    color: #666;
}
/* ▼ アニメーションを追加 ▼ */
.toc-body {
    padding: 30px;
    display: grid;
    grid-template-rows: 1fr;
    transition: grid-template-rows 0.3s ease, padding 0.3s ease, opacity 0.3s ease;
}
/* ▼ 閉じた時の状態を追加 ▼ */
.toc-body.is-closed {
    grid-template-rows: 0fr;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
}
.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    overflow: hidden; /* ▼ アニメーション中はみ出さないように追加 */
}
/* ▼ 余白を15pxに縮小 */
.toc-list li {
    margin-bottom: 15px; 
}
.toc-list li:last-child {
    margin-bottom: 0;
}

/* 見出し2（H2）のスタイル */
.toc-item-h2 a {
    font-size: 16px;
    font-weight: 500;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: flex-start;
    line-height: 1.4;
    transition: opacity 0.3s;
}
/* 矢印アイコン（CSSで太めの矢印を作成） */
.toc-item-h2 a::before {
    content: '';
    display: inline-block;
    width: 5px;
    height: 5px;
    border-top: 1px solid var(--primary-color);
    border-right: 1px solid var(--primary-color);
    transform: rotate(45deg);
    margin-right: 12px;
    /* ▼ margin-topを調整してテキストの中央にピッタリ合わせる */
    margin-top: 9px; 
    flex-shrink: 0;
}

/* 見出し3（H3）のスタイル */
.toc-item-h3 a {
    font-size: 14px;
    color: #333;
    text-decoration: none;
    display: block;
    padding-left: 25px;
    position: relative;
    line-height: 1.4;
    transition: opacity 0.3s;
}
.toc-item-h3 a::before {
    content: '-';
    position: absolute;
    left: 10px;
    /* ▼ H3のハイフンもテキストに揃うように位置調整 */
    top: 0; 
    line-height: 1.4;
    color: #999;
}
.toc-list a:hover {
    opacity: 0.7;
}

/* ▼ 目次のスマホ表示調整 ▼ */
@media (max-width: 900px) {
    .toc-box {
        max-width: 100%;
        margin: 30px 0;
    }
    .toc-header {
        padding: 12px 15px;
        justify-content: space-between;
    }
    .toc-title {
        font-size: 13px;
        text-align: left;
        flex-grow: 1;
        padding-right: 10px;
        line-height: 1.4;
    }
    .toc-toggle {
        position: static;
        flex-shrink: 0;
        font-size: 12px;
    }
    .toc-body {
        padding: 20px 15px;
    }
    .toc-body.is-closed {
        padding-top: 0;
        padding-bottom: 0;
    }
    /* ▼ スマホ時の余白を13pxに縮小 */
    .toc-list li {
        margin-bottom: 13px;
    }
    .toc-item-h2 a {
        font-size: 14px; 
    }
    .toc-item-h2 a::before {
        width: 4px;
        height: 4px;
        border-top-width: 1px;
        border-right-width: 1px;
        /* ▼ スマホ時の矢印もテキストの中央にピッタリ合わせる */
        margin-top: 8px; 
        margin-right: 10px;
    }
    .toc-item-h3 a {
        font-size: 13px; 
        padding-left: 20px;
    }
    .toc-item-h3 a::before {
        left: 5px;
    }
}





/* =========================================
   レスポンシブ対応 (スマホ用)
   ========================================= */
@media (max-width: 900px) {
    /* パンくずの横スクロール対応 */
    .breadcrumb {
        padding: 10px 0;
        overflow: hidden;
    }
    .breadcrumb .container {
        padding-right: 0;
    }
    .breadcrumb ul {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 10px;
        margin-bottom: -10px;
        scrollbar-width: none; 
        -ms-overflow-style: none;
    }
    .breadcrumb ul::-webkit-scrollbar {
        display: none; 
    }
    .breadcrumb li {
        white-space: nowrap; 
        flex-shrink: 0; 
    }
    .breadcrumb li:last-child {
        padding-right: 20px; 
    }

    .page-wrapper {
        padding: 30px 0 60px;
    }
    
    /* メインコンテンツのスマホ調整 */
    .page-main {
        padding: 25px 20px;
        border: none; 
        box-shadow: 0 2px 10px rgba(0,0,0,0.05); 
        border-radius: 4px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    
    /* 見出し周り */
    .page-header-title {
        font-size: 20px;
        padding: 15px 15px 15px 35px;
        margin-bottom: 20px;
    }
    .page-header-title::after {
        left: 15px;
    }
    .page-content h2 {
        font-size: 18px;
        padding: 12px 15px;
        margin: 40px 0 20px;
    }
    .page-content h3 {
        font-size: 16px;
    }
    
    /* 本文・テーブル */
    .page-content {
        font-size: 14px; 
    }
    .page-content p {
        margin-bottom: 20px;
    }
    .page-content th,
    .page-content td {
        padding: 10px;
    }
    .page-content th {
        width: 40%; /* スマホでは見出し幅を少し広げる */
    }

    .page-wrapper {
        padding: 0;
    }

    .page-wrapper .container {
        padding: 0;
    }
}