/******* Do not edit this file *******
Simple Custom CSS and JS - by Silkypress.com
Saved: Jul 08 2026 | 12:12:25 */
/* ==============================================
   メイン目次デザイン：Apple Style (Gradient Edition)
   修正：
     BUG-1: overflow: hidden → clip に変更（position: sticky が機能しなかった問題を解消）
     BUG-2: .toc_title に will-change を追加（backdrop-filter / sticky の描画改善）
     BUG-3: -webkit-overflow-scrolling: touch を削除（iOS13以降は不要・非推奨）
     BUG-4: prefers-reduced-motion 対応を追加
     BUG-5: backdrop-filter の背景色を0.98→0.90に修正（0.98ではblurが視覚的に出ない）
     BUG-6: :focus-visible によるキーボードフォーカスリングを追加
   ============================================== */

/* 1. 外枠（カード全体） */
#toc_container {
    background: rgba(255, 255, 255, 0.98) !important;
    border: 1px solid rgba(0, 0, 0, 0.06) !important;
    border-radius: 20px !important;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06) !important;
    padding: 0 !important;
    width: 100% !important;
    max-width: 600px !important;
    margin: 40px auto 60px auto !important;
    /*
     * ★修正BUG-1（最重要）：overflow: hidden → overflow: clip に変更
     *
     * overflow: hidden はブラウザ仕様上「スクロールコンテナ」を生成する。
     * スクロールコンテナの子孫は position: sticky が機能しなくなるため、
     * .toc_title のスティッキーヘッダーが一切動いていなかった。
     *
     * overflow: clip は「はみ出しをクリップする」だけで
     * スクロールコンテナを生成しないため、sticky が正常に動作する。
     *
     * フォールバック（古いブラウザ向け）:
     *   overflow: hidden を先に書き、overflow: clip を後に書くことで
     *   clip 未対応ブラウザは hidden にフォールバックする。
     *   その場合 sticky は機能しないが、表示崩れは起きない。
     */
    overflow: hidden !important;  /* フォールバック（Chrome<90, Safari<16） */
    overflow: clip !important;    /* モダンブラウザ用（sticky が有効になる） */
    display: block !important;
    position: relative !important;
}

/* 2. ヘッダーエリア（スティッキーヘッダー） */
.toc_title {
    position: sticky !important;
    top: 0 !important;
    z-index: 10 !important;
    /*
     * ★修正BUG-5：0.98（ほぼ完全不透明）→ 0.90 に変更。
     * backdrop-filter のぼかしは背景が透けて初めて視覚的効果が出る。
     * 0.98では透明度が2%しかなく、ぼかしがほとんど見えていなかった。
     */
    background: rgba(255, 255, 255, 0.90) !important;
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding: 20px 24px !important;
    margin: 0 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
    /*
     * ★修正BUG-2：will-change を追加。
     * backdrop-filter はGPU合成が必要。
     * さらに position: sticky の要素は合成レイヤーに昇格させると
     * スクロール追従のジャンクを防止できる。
     */
    will-change: transform;
}

/* 親要素の擬似要素を無効化 */
.toc_title::before,
.toc_title::after {
    content: none !important;
    display: none !important;
}

/* アイコンのコンテナ */
.toc_title .toc-icon-wrap {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 48px !important;
    height: 48px !important;
    background: #F2F2F7 !important;
    border-radius: 12px !important;
    margin-right: 16px !important;
    flex-shrink: 0 !important;
    font-size: 0 !important;
    color: transparent !important;
}

/* プラグイン標準のSVGや画像アイコンを完全に消す */
.toc_title .toc-icon-wrap svg,
.toc_title .toc-icon-wrap i,
.toc_title .toc-icon-wrap img {
    display: none !important;
}

/* CSSで作るApple風アイコン */
.toc_title .toc-icon-wrap::before {
    content: '📕' !important;
    font-size: 24px !important;
    line-height: 1 !important;
    color: initial !important;
    background: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* テキストラッパー */
.toc_title .toc-text-wrap {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
}

/* メインタイトル */
.toc_title .toc-main-title {
    font-size: 20px !important;
    font-weight: 700 !important;
    color: #1d1d1f !important;
    line-height: 1.2 !important;
    margin: 0 !important;
}

/* サブテキスト */
.toc_title .toc-sub-text {
    font-size: 12px !important;
    font-weight: 400 !important;
    color: #86868b !important;
    line-height: 1.4 !important;
    margin-top: 4px !important;
}

/* 3. リストエリア */
.toc_list {
    padding: 12px 0 !important;
    margin: 0 !important;
    max-height: 65vh !important;
    overflow-y: auto !important;
    /*
     * ★修正BUG-3：-webkit-overflow-scrolling: touch を削除。
     * iOS 13以降はモメンタムスクロールがデフォルト有効のため不要。
     * MDN公式も非推奨と明記しており、将来的に副作用が出る可能性がある。
     */
}

/* スタイルリセット */
.toc_list li, .toc_list ol, .toc_list ul,
.toc_list ol li, .toc_list ul li {
    list-style: none !important;
    background: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
}

/* 4. 親見出し（H2） */
.toc_list > li > a {
    display: flex !important;
    align-items: center !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    color: #1d1d1f !important;
    padding: 14px 24px !important;
    text-decoration: none !important;
    line-height: 1.5 !important;
    transition: background 0.2s ease !important;
}
.toc_list > li > a:active {
    background: rgba(0, 0, 0, 0.05) !important;
}

/* ★修正BUG-6：キーボードフォーカス時の視覚的リング（Tab操作対応） */
.toc_list > li > a:focus-visible,
.toc_list ol li a:focus-visible,
.toc_list ul li a:focus-visible {
    outline: 2px solid #ff2d55 !important;
    outline-offset: -2px !important;
    border-radius: 6px !important;
    background: rgba(255, 45, 85, 0.04) !important;
}

/* H2の赤丸 */
.toc_list > li > a::before {
    content: '' !important;
    display: inline-block !important;
    width: 8px !important;
    height: 8px !important;
    background-color: #ff2d55 !important;
    border-radius: 50% !important;
    margin-right: 12px !important;
    flex-shrink: 0 !important;
}

/* 5. 子見出し（H3） */
.toc_list ol,
.toc_list ul {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* H3の区切り線 */
.toc_list ol li,
.toc_list ul li {
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
    margin-left: 28px !important;
}
.toc_list ol li:last-child,
.toc_list ul li:last-child {
    border-bottom: none !important;
}

/* H3リンク */
.toc_list ol li a,
.toc_list ul li a {
    display: block !important;
    font-size: 14px !important;
    color: #424245 !important;
    padding: 12px 16px 12px 24px !important;
    text-decoration: none !important;
    position: relative !important;
}
.toc_list ol li a:active,
.toc_list ul li a:active {
    background: rgba(0, 0, 0, 0.03) !important;
}

/* H3の点（青と赤のグラデーション） */
.toc_list ol li a::before,
.toc_list ul li a::before {
    content: '' !important;
    position: absolute !important;
    left: 8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 4px !important;
    height: 4px !important;
    background: linear-gradient(135deg, #007aff, #ff2d55) !important;
    border-radius: 50% !important;
}

/* 6. prefers-reduced-motion 対応 */
/*
 * ★修正BUG-4：「動きを減らす」設定を尊重。
 * transitionを無効化し、will-changeも解除（不要なレイヤー確保を防ぐ）。
 */
@media (prefers-reduced-motion: reduce) {
    .toc_list > li > a,
    .toc_list ol li a,
    .toc_list ul li a {
        transition: none !important;
    }
    .toc_title {
        will-change: auto !important;
    }
}

/* 7. スマホ微調整 */
@media screen and (max-width: 768px) {
    #toc_container {
        margin: 30px 16px !important;
        width: auto !important;
    }
    .toc_title {
        padding: 16px 20px !important;
    }
    .toc_list > li > a {
        padding: 14px 20px !important;
        font-size: 16px !important;
    }
    .toc_list ol li,
    .toc_list ul li {
        margin-left: 24px !important;
    }
    .toc_list ol li a,
    .toc_list ul li a {
        padding-left: 20px !important;
        font-size: 14px !important;
    }
}