/*
Theme Name: hamubarg blog template
Description: はむばーぐのぶろぐ
Version: 1.0.0
*/

/* -------------------------------------
CSS変数定義 (テーマカラーや共通サイズ)
------------------------------------- */
:root {
    /* ベースカラー（背景色など） */
    --bg-base: #121212;
    --bg-surface: #1e1e24;
    --bg-surface-hover: #2a2a32;
    --bg-surface-light: #33333e;
    
    /* アクセントカラー（強調したい部分） */
    --accent-red: #e31d2e;
    --accent-orange: #ff9900;
    --accent-green: #90c32a;
    /* 青系のアクセントカラー（情報・補足など）を追加定義 */
    --accent-blue: #00aaec;
    
    /* テキストカラー */
    --text-main: #f0f0f0;
    --text-muted: #a0a0a0;
    --text-dark: #121212;
    
    /* レイアウト設定 */
    --max-width: 1200px;
    --sidebar-width: 320px;
    --radius: 8px; /* 要素の角丸 */
}
    
/* -------------------------------------
基本リセットとベーススタイル
------------------------------------- */
*{ margin: 0; padding: 0; box-sizing: border-box; }
body { background-color: var(--bg-base); color: var(--text-main);  font-family: 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif; line-height: 1.6; overflow-x: hidden; }
a { color: inherit; text-decoration: none;transition: opacity 0.2s; }
a:hover { opacity: 0.8; }
ul {list-style: none;}

/* レスポンシブの基本: 画像が親要素をはみ出さないようにする */
img { max-width: 100%; height: auto; pointer-events: none; -webkit-touch-callout: none; user-select: none; }

/* iframe(YouTube等)のレスポンシブ対応(16:9) */
.yt-wrapper { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; border-radius: var(--radius); }
.yt-wrapper iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }

/* スマホサイズ以下 */
.is-provider-youtube * iframe{ max-width: 800px; width: 100%; height: 100%; aspect-ratio: 16 / 9; }

/* 画面幅の最大値と中央寄せ */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 16px; }
.full-width-content{margin: 30px auto; max-width: 1000px;}

/* 画像がない場合のダミー表示 */
.placeholder-img { background: linear-gradient(135deg, #2a2a32 0%, #3a3a44 100%); display: flex; align-items: center; justify-content: center; color: #666; font-weight: bold; border-radius: var(--radius); width: 100%; height: 100%; aspect-ratio: 16/9;}
.img-wrap img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }

/* カテゴリなどの小さなラベル */
.badge { background: var(--accent-orange); color: var(--text-dark); font-size: 0.75rem; padding: 2px 8px; border-radius: 5px; font-weight: bold; }
.badge-red { background: var(--accent-red); color: var(--text-main); }
.badge-green { background: var(--accent-green); color: var(--text-dark); }
.badge-pickup { background: var(--accent-red); color: var(--text-main); font-size: 1.2rem; padding: 7px 20px; border-radius: 5px; font-weight: bold;}

/* 子カテゴリ一覧のタグバッジ（#タグ名）のスタイルを定義 */
.badge-tag { background: var(--accent-green); color: var(--text-dark); font-weight: bold; font-size: 0.75rem; padding: 2px 8px; border-radius: 4px; transition: background 0.2s, color 0.2s; }
/* 赤色 */
.badge-tag-red { background:var(--accent-red); color: var(--text-main); font-weight: bold; font-size: 0.75rem; padding: 2px 8px; border-radius: 4px; transition: background 0.2s, color 0.2s; }

/* セクションの見出し */
.section-title { font-size: 1.5rem; border-left: 4px solid var(--accent-orange); padding-left: 12px; margin-bottom: 20px; display: flex; align-items: center; gap: 8px; border: none; padding: 0; flex-direction: column; }

/* 記事カード等の共通ホバーエフェクト */
.card { background: var(--bg-surface); border-radius: var(--radius); overflow: hidden; transition: transform 0.2s, box-shadow 0.2s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 5px 15px rgba(0,0,0,0.5); }

/* ボタンの装飾 */
.wp-block-buttons { margin: 30px 0; }

/* メイン部分の最低縦サイズ保障 */
main { min-height: 80vh; }

/* スマホではパンくずの記事名は消す */
@media (max-width: 768px) { 
    .gw-breadcrumbs{ gap: 5px; align-items: flex-start; }
    /*.gw-breadcrumb-sep { transform: rotate(90deg); } */
    .gw-breadcrumb-current { display: none; } 
}
@media (max-width: 425px) { 
    .gw-breadcrumb-sep{ display: none; }
}

/* -------------------------------------
トップページエリア
------------------------------------- */
h2.toppage-section-title {
    font-size: 1.8rem;
    margin: 70px 0 20px;
}

/* -------------------------------------
ヘッダーエリア
------------------------------------- */
.site-header { background: var(--bg-surface); border-bottom: 1px solid #333; padding: 5px 0; position: relative; }
.site-header .container { display: flex; justify-content: space-between; align-items: center; }
.site-logo { display: flex; align-items: center; gap: 12px; font-size: 1.2rem; font-weight: bold; color: var(--text-main); }
.logo-icon { width: 45px; height: 40px; display: flex; align-items: center; justify-content: center; }
.header-nav { display: flex; gap: 20px; align-items: center; }
/* スマホサイズ以下 */
@media (max-width: 768px) {
    /* ヘッダーのPC用ナビを隠し、スマホメニュー表示用のスタイルを定義 */
    .header-nav { display: none; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0; background: var(--bg-surface); padding: 20px; z-index: 1000; border-bottom: 1px solid #333; }
    /* JSで.is-activeが付与されたら表示 */
    .header-nav.is-active { display: flex;  }
    .sp-menu-btn { display: block; }
}
/* ヘッダーの「攻略ゲーム一覧」ボタン */
.btn-category-all { background: var(--accent-orange); color: var(--text-dark) !important; padding: 5px 15px; border-radius: 10px; font-weight: bold; font-size: 0.9rem; display: inline-flex; align-items: center; gap: 6px; box-shadow: 0 2px 8px rgba(255, 153, 0, 0.3); transition: all 0.2s ease; }
.btn-category-all:hover { background: var(--accent-orange); transform: translateY(-2px); box-shadow: 0 4px 12px rgba(255, 153, 0, 0.4); }

/* -------------------------------------
トップページ固有レイアウト
------------------------------------- */
/* ピックアップエリア（左大・右小2つ） */
.hero-1-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; margin: 24px 0; }
.hero-1-main { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 16/9; /* PCで大きすぎるのを防ぐ */ }
.hero-1-main .placeholder-img, .hero-1-main .img-wrap { height: 100%; border-radius: 0; }
.hero-1-sub { display: grid; grid-template-rows: 1fr 1fr; gap: 16px; }
.hero-1-sub .card { position: relative; }
.hero-1-sub .placeholder-img, .hero-1-sub .img-wrap { height: 100%; border-radius: var(--radius); }
@media (max-width: 992px) {
    /* ピックアップのグリッドを解除 */
    .hero-1-grid { grid-template-columns: 1fr; }
    .hero-1-main { aspect-ratio: auto; height: 300px; }
}

/* ピックアップの画像上のグラデーションとテキスト */
.hero-overlay-text {position: absolute; bottom: 0; left: 0; right: 0; padding: 20px; background: linear-gradient(transparent, rgba(0,0,0,0.9)); }

/* カテゴリ一覧 */
.hero-2-grid { display: grid; gap: 12px; padding: 10px 0; margin-bottom: 50px; grid-template-columns: repeat(auto-fit, 130px); justify-content: center; }
.hero-2-scroll { display: flex; gap: 12px; overflow-x: auto; padding: 10px 0; margin-bottom: 50px; scrollbar-width: thin; scrollbar-color: var(--accent-orange) var(--bg-surface); }

/* カテゴリ横スクロールエリア */
.cat-chip { display: flex; align-items: center; max-width: 130px;height: 100%; gap: 5px; background: var(--bg-surface); padding: 10px; border-radius: 15px; white-space: nowrap; font-size: 0.7rem; border: 1px solid #333; flex-direction: column; }
@media (hover: hover) { .cat-chip:hover { border-color: var(--accent-orange); color: var(--accent-orange); } }
.cat-chip P { white-space: pre-line;letter-spacing: -0.05em; }
.cat-icon { display: flex; width: 100px; height: 100px; justify-content: center; align-items: center; }
.cat-icon > img { width: 100%; height: auto; }
.cat-icon-top{ display: flex; width: 150px; height: 150px; justify-content: center; align-items: center; }
@media (max-width: 765px) { 
    .hero-2-grid { grid-template-columns: repeat(auto-fit, minmax(123px, 1fr)); place-items: center;}
    .placeholder-img{ height: 100%; }
}
@media (max-width: 425px) {
    .hero-2-grid { grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));}
    .cat-chip { font-size: 0.5rem;gap: 1px;line-height: 1rem;} 
    .hero-2-grid .cat-icon { width: 90px; height: 90px; }
}
/* ステータスアイコン */
.cat-state-icon { width: 100%; text-align: center; }
.cat-state-icon .is-in-progress { background-color: var(--accent-green); color: var(--bg-surface);}
.cat-state-icon .is-paused { background-color: var(--bg-surface-light); }

/* 動画 */
.wp-block-embed{ margin-bottom: 10px; }

/* -------------------------------------
メイン＆サイドバーレイアウト
------------------------------------- */
.layout-main-sidebar { display: flex; gap: 30px; margin-bottom: 40px; }
.layout-main { flex: 1; min-width: 0; /* flexbug回避: 子要素のはみ出しを防ぐ */ }
.layout-sidebar { width: var(--sidebar-width); flex-shrink: 0; position: sticky; top: 20px; height: fit-content; }
@media (max-width: 992px) {
    /* 2カラムを1カラム(縦並び)に変更 */
    .layout-main-sidebar { flex-direction: column; }
    .layout-sidebar { width: 100%; }
}

/* 記事リスト(横並びカード) */
.article-list { display: grid; gap: 20px; }
.article-card-row { display: flex; gap: 16px; background: var(--bg-surface); padding: 12px; border-radius: var(--radius); transition: transform 0.2s, background 0.2s; }
.article-card-row:hover { background: var(--bg-surface-hover); transform: translateY(-2px); }
.article-card-row .img-wrap, .article-card-row .placeholder-img { width: 160px; height: 100px; flex-shrink: 0; border-radius: 4px; overflow: hidden; }
.article-card-info { width: 100%; display: flex; flex-direction: column; justify-content: space-between; padding: 4px 0; }
.article-meta { color: var(--text-muted); display: flex; gap: 12px; justify-content: space-between; }
/* スマホサイズ以下 */
@media (max-width: 768px) {
    .article-card-row { flex-direction: column; }
    .article-card-row .img-wrap, .article-card-row .placeholder-img { width: 100%; height: 180px; }
}
/* サイドバーウィジェット */
.widget { background: var(--bg-surface); border-radius: var(--radius); padding: 20px; margin-bottom: 24px;height: 100%; }
.widget-title { font-size: 1.1rem; border-bottom: 2px solid var(--accent-orange); padding-bottom: 8px; margin-bottom: 16px; font-weight: bold; }
a.widget-title > img { height: 100px; }
.rank-list li { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; border-bottom: 1px solid #333; padding-bottom: 12px; }
ul.rank-list > li > a { font-size: 0.9rem; }
.rank-num { font-size: 1.5rem; font-weight: bold; color: var(--accent-orange); font-style: italic; width: 24px;}
.sidebar-cat-list a { display: flex; align-items: center; gap: 5px; padding: 0; border-bottom: 1px dashed #333; }
.sidebar-cat-list a:hover { color: var(--accent-orange); }

/* プロフィールボックス */
.profile-box { text-align: center; height: 100%;}
.profile-icon { width: 150px; height: 150px; border-radius: 50%; background: var(--bg-surface-light); margin: 0 auto 12px; display: flex; align-items: center; justify-content: center; }
.site-box { text-align: center;max-height: 430px;overflow-y: scroll;}

/* トップページのみ */
.sction-sitenituite { display: flex; justify-content: space-between; }
.sction-sitenituite .widget{width: 48%;}
/* スマホサイズ以下 */
@media (max-width: 768px) {
    .sction-sitenituite { flex-direction: column; }
    .sction-sitenituite .widget{width: 100%;}
}
/* -------------------------------------
カテゴリアーカイブ用グリッド (3列 / 5列)
------------------------------------- */
/* 3列用 */
.grid-3col { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 40px; }
.grid-3col .card-col { background: var(--bg-surface); border-radius: var(--radius); padding: 12px; display: flex; flex-direction: column; }
.grid-3col .img-wrap { height: auto; margin-bottom: 12px; border-radius: 4px; overflow: hidden;}
.grid-3col .card-title { font-size: 1rem; margin-bottom: 8px; }

/* 5列用 */
.grid-5col { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 20px; }
.grid-5col .card-simple { background: var(--bg-surface); border-radius: var(--radius); overflow: hidden; padding: 7px;}
.grid-5col .card-title { padding: 10px; font-size: 0.9rem; line-height: 1.4;}

/* 装飾 */
.cat-block-title { background: var(--bg-surface-light); padding: 5px 15px; border-left: 5px solid var(--accent-orange); margin: 30px 0 16px; font-weight: bold; display: flex; align-items: center; gap: 10px; }
.card-badges{ display: flex; flex-wrap: wrap; gap: 4px; }
.card-meta { padding-bottom: 10px; display: flex; align-items: center; justify-content: space-between; }
.grid-next-content{ text-align:right;margin-bottom: 40px;display: flex;justify-content: end; }
.grid-next-btm{ padding: 5px 50px;border-radius: 10px;font-weight: bold;background: rgba(30, 30, 36, 0.85);backdrop-filter: blur(5px);color: var(--text-color, #f0f0f0);border: 3px solid #ff9900; }

@media (hover: hover) {
    .grid-next-btm:hover{
        background: var(--accent-orange);
        color: var(--text-color, #f0f0f0);
        border-color: var(--accent-orange);
        transform: scale(1.05);
    }
}

/* スマホサイズ以下 */
@media (max-width: 768px) {
    /* 3列用 */
    .grid-3col { grid-template-columns: 1fr; }
    .grid-3col .card-col { flex-direction: row;}
    .grid-3col .img-wrap { height: auto; width: 250px; margin: 0 10px 0 0;flex:1; }
    .grid-3col .article-card-info { flex-direction: column-reverse;flex:2; }
    .grid-3col .card-title { font-size: 1rem; line-height: 1.5rem; }
    .grid-3col .card-meta { padding: 0; }
    /* 5列用 */
    .grid-5col { grid-template-columns: repeat(2, 1fr); gap: 2px; }

    /* 装飾共通 */
    .card-img-title{ display: flex; }
}
/* スマホ小 */
@media (max-width: 425px) {
    .cat-block-title{ font-size: 1.2rem; }
    /* 3列用 */
    .grid-3col .card-title, .grid-5col .card-title { display: none; }
    .grid-3col .img-wrap { flex:2; }
    .grid-3col .card-meta { padding: 0;flex-direction: column;justify-content: space-between;align-items: flex-start;height: 100%; }
    .grid-3col .article-card-info{ padding:0; }

    /* 5列用 */
    .grid-5col .card-simple { display: flex;padding: 4px; }
    .grid-5col .img-wrap{ height: auto; width: 100%;flex:1;}
    .grid-5col .article-card-info{ flex:2; }
    .grid-5col .card-title{ flex:2; }
    .grid-5col .grid-5col-card-title { font-size: 0.85rem; }
}

/* -------------------------------------
記事詳細ページ (シングル)
------------------------------------- */
.article-header { margin-bottom: 24px; }
.article-h1 { font-size: 2rem; margin: 15px 0; line-height: 1.4; }
.article-stats { display: flex; gap: 16px; font-size: 0.9rem; color: var(--text-muted); margin-bottom: 20px; }
.article-stats > span { display: flex; align-items: center; }
.article-eyecatch { margin-bottom: 30px; border-radius: var(--radius); overflow: hidden; }

/* 目次 (TOC) */
.toc-box { background: var(--bg-surface); border: 1px solid #333; border-radius: var(--radius); padding: 24px; margin-bottom: 24px; }
.toc-title { font-weight: bold; font-size: 1.2rem; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.toc-list ul { padding-left: 20px; }
.toc-list li { margin-bottom: 8px; }
.toc-list a { color: var(--accent-orange); text-decoration: underline; }

/* 記事本文内の見出し・段落 */
.article-body h2 { font-size: 1.8rem;border: 2px solid var(--accent-orange);padding: 10px 15px;margin: 40px 0 20px;border-radius: 5px; box-shadow: 2px 3px 0px var(--accent-orange);}
.article-body h3 { font-size: 1.5rem; border-left: 10px solid var(--accent-red); padding: 10px; margin: 30px 0 16px;background-color: var(--bg-surface-light);}
.article-body p { margin: 10px auto 30px;font-size: 1.2rem; }
.article-body ul { list-style: disc; margin-left: 20px; margin-bottom: 20px; }
/* スマホサイズ以下 */
@media (max-width: 768px) {
    .article-h1{ font-size: 1.5rem; }
    .article-body h2,.article-body h3{ font-size: 1.2rem; }
    .article-body p { font-size: 1rem; line-height: 1.3rem; }
    .article-stats .article-stats-text{display: none;}
}
/* -------------------------------------
記事装飾・コンポーネント (追加分)
------------------------------------- */
/* 攻略記事用のハイライト（重要語句）のスタイルを設定 */
.gw-highlight { background: linear-gradient(transparent 60%, rgba(255, 153, 0, 0.4) 0%); font-weight: bold; }

/* 記事本文内のテーブル（ステータス表等）の視認性向上スタイル */
.wp-block-table{ margin: 30px 0; }
.article-body table, .status-table { width: 100%; border-collapse: collapse; overflow-x: auto; white-space: nowrap; background: var(--bg-surface); border-radius: var(--radius); }
.article-body th, .article-body td, .status-table th, .status-table td { border: 1px solid #444; padding: 10px 5px; text-align: center; line-height: 1; }
.article-body th, .status-table th { background: var(--bg-surface-light); font-weight: bold; color: var(--text-main); }
.val-good { color: var(--accent-green); font-weight: bold; }
.val-bad { color: var(--accent-red); font-weight: bold; }

/* 攻略情報用のインフォメーションボックスの基本設計を追加 */
.gw-box { margin: 24px 0; padding: 20px; border-radius: var(--radius); background: var(--bg-surface-light); border-left: 6px solid var(--text-muted); }
.gw-box-title { font-weight: bold; font-size: 1.1rem; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }

/* テーブルのストライプの色調整 */
.wp-block-table.is-style-stripes tbody tr:nth-child(odd){ background-color: #555555!important; }
.wp-block-table.is-style-stripes::-webkit-scrollbar { height: 10px; }
.wp-block-table.is-style-stripes::-webkit-scrollbar-thumb { background: var(--accent-orange, #ff9900);}

/* h2装飾だけ */
.title-h2-design{
    font-size: 1.5rem;
    border-left: 10px solid var(--accent-red);
    padding: 10px;
    margin: 30px 0 16px;
    background-color: var(--bg-surface-light);
}

/* ==========================================
RPG風 参考になったボタン 演出用スタイル
========================================== */
.rpg-btn-container { text-align: center; margin: 40px 0; }

/* コマンドボタンとウィンドウの共通デザイン */
.rpg-command-btn, .rpg-choice, .rpg-message-window { font-family: 'DotGothic16', monospace, sans-serif; color: #fff; }
.rpg-command-btn { padding: 15px 30px; font-size: 1rem; cursor: pointer; transition: transform 0.1s; }
.rpg-command-btn:active { transform: translateY(2px); }

/* 点滅カーソル */
.cursor { display: inline-block; margin-right: 8px; color: #fff; animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }
/* タイピング前の高さ確保 */
.rpg-text { min-height: 1.5em; }

/* 選択肢エリア */
.rpg-choices-box { margin-top: 10px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }

/* ========================================================
サイドバー目次 (TOC) のスクロール連動表示アニメーション
======================================================== */
/* サイドバー全体、またはTOC単体を追従させる場合 */
.sidebar { position: sticky; top: 20px; }
.sidebar-toc { display: none; opacity: 0; transition: opacity 0.5s, display 0.5s; transition-behavior: allow-discrete; }
@media (max-width: 600px) {
    .sidebar-toc { display: none!important; }
}

/* JSによって付与される表示用クラス */
.sidebar-toc.is-visible { display: block; opacity: 1; @starting-style { opacity: 0; } }

/* ========================================================
左下 フローティングメニュー
======================================================== */
.floating-menu { position: fixed; bottom: 20px; left: clamp(15vw, calc(20vw), 20vw); z-index: 9999; display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }

/* アバター(トリガー)部分 */
.floating-menu-toggle { cursor: pointer; border-radius: 50%; border: 3px solid var(--accent-orange, #ff9900); box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5); background: var(--surface-color, #1e1e24); transition: transform 0.2s ease; display: flex; justify-content: center; align-items: center; width: 56px; height: 56px; }
.floating-menu-items:hover { transform: scale(1.05); }
.float-avatar-img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }

/* 展開されるメニュー群 */
.floating-menu-items { 
    flex-direction: column; gap: 10px;  visibility: hidden; pointer-events: none; 
     display: none; }
     @keyframes fadeIn { from { opacity: 0;transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);transform: translateY(20px); } to { opacity: 1;transform: translateY(0); } }

/* タップ(スマホ) で展開 */
.floating-menu.is-active .floating-menu-items { visibility: visible; pointer-events: auto; display: flex;
    animation: fadeIn 0.3s ease forwards; animation-delay: 0.1s; opacity: 0; }
@keyframes fadeIn { from { opacity: 0;transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);transform: translateY(20px); } to { opacity: 1;transform: translateY(0); } }

/* 各メニューボタン */
.float-btn {
    min-width: 165px;
    display: flex;
    flex-direction: row; /* 横にアイコンと文字を並べる */
    align-items: center;
    gap: 8px;
    background: rgba(30, 30, 36, 0.85); /* 半透明グラスモーフィズム風 */
    backdrop-filter: blur(5px);
    color: var(--text-color, #f0f0f0);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 10px; /* 角丸のピル型 */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    font-size: 0.85rem;
    font-weight: bold;
    border: 3px solid #ff9900;
    transition: all 0.2s ease;
    /* 左側を起点に伸縮するアニメーション */
    transform-origin: left center;
}
@media (hover: hover) { .float-btn:hover { background: var(--accent-orange, #ff9900); color: #fff; border-color: var(--accent-orange, #ff9900); transform: scale(1.05); } }

/* スマホ閲覧時の調整 */
@media screen and (max-width: 768px) { .floating-menu { bottom: 15px; left: 15px; } }

/* ========================================================
いいね促進ポップアップ (吹き出し)
======================================================== */
.floating-like-popup {
position: absolute;
left: 80px; /* アバターの右側に配置 */
bottom: 0px;
background: var(--surface-color, #1e1e24);
border: 4px solid var(--accent-orange, #ff9900);
padding: 12px 16px;
border-radius: 8px;
box-shadow: var(--surface-color, #1e1e24);
width: max-content;
width: 250px;
opacity: 0;
transform: translateX(-10px) scale(0.95);
visibility: hidden;
transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
z-index: -1; /* アバターより背面に配置して展開時に奥から出るようにする */
}

/* 吹き出しのしっぽ（左向きの三角） */
.floating-like-popup::before {
content: '';
position: absolute;
bottom: 10%;
left: -10px;
transform: translateY(-50%);
border-width: 10px 10px 10px 0;
border-style: solid;
border-color: transparent var(--accent-orange, #ff9900) transparent transparent;
}

/* しっぽの内側（背景色で中抜きして枠線にする） */
.floating-like-popup::after {
content: '';
position: absolute;
bottom: 10%;
left: -5px;
transform: translateY(-50%);
border-width: 10px 10px 10px 0;
border-style: solid;
border-color: transparent var(--surface-color, #1e1e24) transparent transparent;
}

/* クラス付与で表示 */
.floating-like-popup.is-visible {
opacity: 1;
transform: translateX(0) scale(1);
visibility: visible;
z-index: 9998;
}

.popup-message {
color: var(--text-color, #f0f0f0);
font-size: 0.85rem;
margin: 0 0 10px 0;
line-height: 1.4;
}

.popup-like-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    background:#e31d2e;
    color: #fff;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.1s ease;
}

.popup-like-btn:hover { background: #915700; }
.popup-like-btn:active { transform: scale(0.95); }
.close-popup {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    background: #90c32a;
    color: #ffffff;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: bold;
    cursor: pointer;
}
.close-popup:hover { background: #486410; }

/* ボタンブロック */
.popup-btm-block { display: flex; flex-direction: row; align-items: center; }

/* スマホ閲覧時は上に吹き出しを出す */
@media screen and (max-width: 600px) {
    .floating-like-popup { left: 70px; transform: translateY(10px) scale(0.95); }
    .floating-like-popup.is-visible { transform: translateY(0) scale(1); }
}


/* ========================================================
ブロックエディタで「表」の”コピーボタン付き”カスタムスタイル
======================================================== */
/* コピーボタンのスタイリングとアニメーション */
.gw-copy-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 8px;
    padding: 7px 16px;
    font-size: 13px;
    font-weight: bold;
    color: #ffffff !important;
    background: linear-gradient(135deg, #007cba 0%, #005a87 100%);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    box-shadow: 0 2px 5px rgba(0, 124, 186, 0.2);
    white-space: nowrap;
}
.gw-copy-btn:hover {
    background: linear-gradient(135deg, #008cd4 0%, #00689c 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 124, 186, 0.35);
}
.gw-copy-btn:active { transform: translateY(0) scale(0.96); }
.is-style-gw-copy-table{ width: 100%!important; }
.is-style-gw-copy-table table{ white-space: unset!important; table-layout: unset!important; }
.is-style-gw-copy-table * img{ min-width: 50px; }

/* コピー成功時のポップアップ・アニメーション */
@keyframes gw-pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.08); }
    100% { transform: scale(1); }
}
.gw-copy-btn.copied {
    background: linear-gradient(135deg, #46b450 0%, #2e7d32 100%) !important;
    box-shadow: 0 3px 8px rgba(70, 180, 80, 0.4);
    animation: gw-pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.wp-block-table td { vertical-align: middle; }

/* スマホではボタンを消す */
@media screen and (max-width: 600px) { 
    .gw-copy-btn{ display: none!important; }
}
/* ========================================================
ブロックエディタで「メディアとテキスト」のカスタムスタイル
======================================================== */
/* 全体のラップ要素：背景などを透明にし、要素間のギャップを調整 */
.wp-block-media-text.is-style-gw-modern-card {
    background: transparent;
    border: none;
    box-shadow: none;
    margin-bottom: 2em;
    align-items: center; /* 画像と吹き出しを縦方向の中央に揃える */
    gap: 2em; /* 画像とテキストの隙間 */
}

/* 画像部分のスタイリング（アイコン風） */
.wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__media {
    margin: 0;
    border-radius: 50%; /* 画像を丸くする */
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    aspect-ratio: 1 / 1; /* 正方形（丸）を維持 */
}

/* ▼▼ 吹き出し（テキストエリア）本体 ▼▼ */
.wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__content {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    padding: 1em;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #e2e8f0;
}

/* 吹き出しの尻尾（枠線用と背景用の2つを重ねて作成） */
.wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__content::before,
.wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__content::after {
    content: "";
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border-style: solid;
    width: 0;
    height: 0;
}

/* 【通常時（画像が左）】 尻尾は「左」に出て、左を向く */
.wp-block-media-text.is-style-gw-modern-card:not(.has-media-on-the-right) .wp-block-media-text__content::before {
    left: -15px; /* 枠線の分少し外側へ */
    border-width: 15px 15px 15px 0;
    border-color: transparent #e2e8f0 transparent transparent; 
}
.wp-block-media-text.is-style-gw-modern-card:not(.has-media-on-the-right) .wp-block-media-text__content::after {
    left: -13px; /* 少し内側で重ねて枠線を表現 */
    border-width: 13px 13px 13px 0;
    border-color: transparent #ffffff transparent transparent; 
}

/* 【反転時（画像が右）】 尻尾は「右」に出て、右を向く */
.wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right .wp-block-media-text__content::before {
    right: -15px;
    border-width: 15px 0 15px 15px;
    border-color: transparent transparent transparent #e2e8f0;
}
.wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right .wp-block-media-text__content::after {
    right: -13px;
    border-width: 13px 0 13px 13px;
    border-color: transparent transparent transparent #ffffff;
}

/* ▼▼ 画像の左右反転（右配置時、人物がテキスト側を向くように） ▼▼ */
.wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right .wp-block-media-text__media img {
    transform: scaleX(-1);
    transition: transform 0.3s ease;
}
.wp-block-media-text__content > .wp-block-paragraph {
    color: var(--bg-base);
    font-weight: bold;
    margin: 5px auto;
}

/* ▼▼ モバイル端末での表示調整（縦積み禁止・横並び維持） ▼▼ */
@media (max-width: 600px) {
    /* 右に画像がある場合のグリッド割合 */
    body .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right,
    body .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right.is-stacked-on-mobile {
        grid-template-columns: auto 70px !important;
        gap: 1em;
    }
    /* スマホ時も縦積みを強制解除し、2カラム（画像+テキスト）を維持。優先度を上げるためにbodyを付与 */
    body .wp-block-media-text.is-style-gw-modern-card,
    body .wp-block-media-text.is-style-gw-modern-card.is-stacked-on-mobile {
        grid-template-columns: 70px auto !important;
        gap: 1em;
    }
    body .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right .wp-block-media-text__media,
    body .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right.is-stacked-on-mobile .wp-block-media-text__media{
        grid-column: 2 !important;
        grid-row: 1 !important;
    }
    body .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right .wp-block-media-text__content,
    body .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right.is-stacked-on-mobile .wp-block-media-text__content{
        grid-column: 1 !important;
        grid-row: 1 !important;
    }
    body .wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__media {
        border-radius: 50% !important; /* 丸を維持 */
        max-width: 100% !important;
        margin: 0 !important;
    }
    
    body .wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__media img {
        aspect-ratio: 1 / 1 !important; /* 丸を維持 */
        height: 100% !important;
        object-fit: cover !important;
    }

    /* 吹き出しの余白をスマホ用にスリム化 */
    body .wp-block-media-text.is-style-gw-modern-card .wp-block-media-text__content {
        padding: 1em !important;
        font-size: 0.8em !important;
        margin-top: 0 !important; /* WP標準の縦積み時の余白を消去 */
    }
    .wp-block-media-text.is-style-gw-modern-card:not(.has-media-on-the-right) .wp-block-media-text__content::after {
        left: -10px;
        right: auto;
        top: 50%;
        transform: translateY(-50%);
        border-width: 10px 10px 10px 0;
        border-color: transparent #ffffff transparent transparent;
    }
    
    .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right .wp-block-media-text__content::before {
        right: -12px;
        left: auto;
        top: 50%;
        transform: translateY(-50%);
        border-width: 12px 0 12px 12px;
        border-color: transparent transparent transparent #e2e8f0;
    }
    .wp-block-media-text.is-style-gw-modern-card.has-media-on-the-right .wp-block-media-text__content::after {
        right: -10px;
        left: auto;
        top: 50%;
        transform: translateY(-50%);
        border-width: 10px 0 10px 10px;
        border-color: transparent transparent transparent #ffffff;
    }
    .wp-block-media-text__content{
        grid-column: 2!important;
        grid-row: 1!important;
    }
    .wp-block-media-text__content > .wp-block-paragraph {
        font-weight: unset;
    }
}
/* ========================================================
ブロックエディタで「詳細」のカスタムスタイル
======================================================== */
/* 要約のスタイル定義 */
.wp-block-details-is-layout-flow { padding: 10px 15px; border-radius: 8px;margin: 20px auto;}
.wp-block-details-is-layout-flow .wp-block-paragraph { margin: 10px 0 0 0; }
.is-style-gw-box-point summary,
.is-style-gw-box-alert summary,
.is-style-gw-box-info summary {
    list-style: none;
    display: flex;
    cursor: unset;
    font-weight: bold;
    line-height: 1.5rem;
    gap: 5px;
    margin-bottom: 10px;
}
.is-style-gw-box-point summary::before,
.is-style-gw-box-alert summary::before,
.is-style-gw-box-info summary::before{
    content: '';
    display: inline-block;
    width: 24px;
    height: 24px;
    background-repeat: no-repeat;
    background-size: contain;
    vertical-align: middle;
}

/* ポイント・コツ用ボックス（緑系）のスタイル定義 */
.is-style-gw-box-point { border-left-color: var(--accent-green); background: rgba(0, 230, 118, 0.25); }
.is-style-gw-box-point summary{ color: var(--accent-green);}
.is-style-gw-box-point summary::before{
    background-image:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 1024 1024"><title>alert-outlined</title><path fill="%2390c32a" d="M193 796c0 17.7 14.3 32 32 32h574c17.7 0 32-14.3 32-32V563c0-176.2-142.8-319-319-319S193 386.8 193 563zm72-233c0-136.4 110.6-247 247-247s247 110.6 247 247v193H404V585c0-5.5-4.5-10-10-10h-44c-5.5 0-10 4.5-10 10v171h-75zm-48.1-252.5l39.6-39.6c3.1-3.1 3.1-8.2 0-11.3l-67.9-67.9a8.03 8.03 0 0 0-11.3 0l-39.6 39.6a8.03 8.03 0 0 0 0 11.3l67.9 67.9c3.1 3.1 8.1 3.1 11.3 0m669.6-79.2l-39.6-39.6a8.03 8.03 0 0 0-11.3 0l-67.9 67.9a8.03 8.03 0 0 0 0 11.3l39.6 39.6c3.1 3.1 8.2 3.1 11.3 0l67.9-67.9c3.1-3.2 3.1-8.2 0-11.3M832 892H192c-17.7 0-32 14.3-32 32v24c0 4.4 3.6 8 8 8h688c4.4 0 8-3.6 8-8v-24c0-17.7-14.3-32-32-32M484 180h56c4.4 0 8-3.6 8-8V76c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v96c0 4.4 3.6 8 8 8"/></svg>');
}

/* 注意・警告用ボックス（赤系）のスタイル定義 */
.is-style-gw-box-alert { border-left-color: var(--accent-red); background: rgba(255, 77, 77, 0.25); }
.is-style-gw-box-alert summary { color: var(--accent-red);}
.is-style-gw-box-alert summary::before{
    background-image:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24"><title>alert-filled</title><path fill="%23CC3300" fill-rule="evenodd" d="M7.843 3.802C9.872 2.601 10.886 2 12 2s2.128.6 4.157 1.802l.686.406c2.029 1.202 3.043 1.803 3.6 2.792c.557.99.557 2.19.557 4.594v.812c0 2.403 0 3.605-.557 4.594s-1.571 1.59-3.6 2.791l-.686.407C14.128 21.399 13.114 22 12 22s-2.128-.6-4.157-1.802l-.686-.407c-2.029-1.2-3.043-1.802-3.6-2.791C3 16.01 3 14.81 3 12.406v-.812C3 9.19 3 7.989 3.557 7s1.571-1.59 3.6-2.792zM13 16a1 1 0 1 1-2 0a1 1 0 0 1 2 0m-1-9.75a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-1.5 0V7a.75.75 0 0 1 .75-.75" clip-rule="evenodd"/></svg>');
}

/* 補足・情報用ボックス（青系）のスタイル定義 */
.is-style-gw-box-info { border-left-color: var(--accent-blue); background: rgba(0, 170, 236, 0.25); }
.is-style-gw-box-info summary { color: var(--accent-blue);}
.is-style-gw-box-info summary::before{
    background-image:url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24"><title>check-fill</title><path fill="%2300aaec" fill-rule="evenodd" d="M12 21a9 9 0 1 0 0-18a9 9 0 0 0 0 18m-.232-5.36l5-6l-1.536-1.28l-4.3 5.159l-2.225-2.226l-1.414 1.414l3 3l.774.774z" clip-rule="evenodd"/></svg>');
}


/* ========================================================
画像拡大モーダル機能
======================================================== */
/* モーダル全体のラッパー（非表示状態） */
.gw-image-modal { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; z-index: 999999; display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease; }

/* モーダル表示時の状態 */
.gw-image-modal.is-open { opacity: 1; visibility: visible; }

/* 暗めの背景とぼかし効果 */
.gw-image-modal-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.85); backdrop-filter: blur(5px); cursor: zoom-out; }

/* 画像と閉じるボタンのコンテナ（ポンッと浮き出るアニメーション） */
.gw-image-modal-content { position: relative; max-width: 90vw; width: 75%; max-height: 90vh; height: auto; z-index: 1000000; transform: scale(0.95); transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); display: flex; flex-direction: column; align-items: center; justify-content: center; border: 11px solid rgb(255, 105, 0); border-radius: 8px; border-style: double; background-color: #000; }
.gw-image-modal.is-open .gw-image-modal-content { transform: scale(1); }

/* 拡大画像のスタイリング */
.gw-image-modal-img { max-width: 100%; width: 100%; max-height: 85vh; height: auto; object-fit: contain; border-radius: 8px; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5); user-select: none; }

/* 閉じるボタン（×） */
.gw-image-modal-close { position: absolute; top: -8px; right: -8px; color: #ffffff; font-size: 36px; font-weight: bold; cursor: pointer; line-height: 1; transition: color 0.2s ease, transform 0.2s ease; user-select: none; padding: 5px 10px; background-color: rgb(255, 105, 0); border-radius: 6px; }
.gw-image-modal-close:hover { color: #cbd5e1; transform: scale(1.1); }

/* 記事内のクリック対象画像（カーソルを指マークに） */
.gw-zoomable-img { cursor: zoom-in !important; transition: opacity 0.2s ease; }
.gw-zoomable-img:hover { opacity: 0.9; }

/*画像右上の拡大ボタン用スタイル*/
.gw-zoom-wrapper { position: relative; }
.gw-zoom-btn { position: absolute; right: 0; top: 0; width: 150px; display: flex; flex-direction: row; align-items: center; cursor: pointer; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25); border: 3px solid rgb(255 153 0); justify-content: center; color: #fff; background-color: #000; border-radius: 8px; padding: 2px 0px; opacity: 0.5; }
@media (hover: hover) { .gw-zoom-btn:hover{ opacity: 1; } }
@media (max-width: 600px) { .gw-zoom-btn { display: none; } } 