/* Base Layout & Theme Variables */
.hero-detail-layout, .hero-detail-layout * { box-sizing: border-box; }
.hero-detail-layout {
    --color-yellow: radial-gradient(circle at 30% 30%, rgba(255,255,200,0.2) 0%, transparent 50%), linear-gradient(135deg, #b99a1a 0%, #9a8010 100%);
    --tag-bg-yellow: radial-gradient(circle at center, #554321, #423310);
    --color-purple: radial-gradient(circle at 30% 30%, rgba(200,150,255,0.2) 0%, transparent 50%), linear-gradient(135deg, #833794 0%, #5a246b 100%);
    --tag-bg-purple: radial-gradient(circle at center, #48235c, #391c49);
    --color-red: radial-gradient(circle at 30% 30%, rgba(255,200,200,0.2) 0%, transparent 50%), linear-gradient(135deg, #ba2a2a 0%, #801a1a 100%);
    --tag-bg-red: radial-gradient(circle at center, #58211a, #431914);
    --color-blue: radial-gradient(circle at 30% 30%, rgba(200,230,255,0.2) 0%, transparent 50%), linear-gradient(135deg, #347cc0 0%, #24578a 100%);
    --tag-bg-blue: radial-gradient(circle at center, #1d2c49, #0e1a2b);
    --color-green: radial-gradient(circle at 30% 30%, rgba(180,255,180,0.2) 0%, transparent 50%), linear-gradient(135deg, #3d9e30 0%, #2a6e20 100%);
    --tag-bg-green: radial-gradient(circle at center, #285220, #1f3f19);
    --color-holy: var(--color-yellow); --tag-bg-holy: var(--tag-bg-yellow);
    --color-dark: var(--color-purple); --tag-bg-dark: var(--tag-bg-purple);
    --color-fire: var(--color-red); --tag-bg-fire: var(--tag-bg-red);
    --color-ice: var(--color-blue); --tag-bg-ice: var(--tag-bg-blue);
    --color-nature: var(--color-green); --tag-bg-nature: var(--tag-bg-green);
    --card-theme: var(--color-yellow); --tag-theme: var(--tag-bg-yellow); --text-main: #ffffff;
    /* font-family: 'Poppins', 'Noto Sans JP', sans-serif; color: var(--text-main);
     */
    font-family: 'Poppins', 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', 'Noto Sans JP', 'Yu Gothic', 'YuGothic', Meiryo, sans-serif;
    display: flex; flex-direction: column; gap: 1.5rem; width: 100%; max-width: 100%; margin: 0 auto; line-height: 1.5;
}


/* Hero Card */
.hero-card { background: var(--card-theme) !important; border-radius: 16px; padding: 20px; box-shadow: 0 12px 30px rgba(0,0,0,0.5); border: 1px solid rgba(255,255,255,0.1); color: #fff; width: 100%; }
.hero-title-line { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; width: 100%; }
#hero-name { font-size: 1.1rem; font-weight: 800; text-align: center; flex-grow: 1; margin: 0; }
.nav-arrow { font-size: 2rem; line-height: 1; cursor: pointer; width: 40px; text-align: center; user-select: none; }
.hero-info-grid { display: flex; gap: 15px; margin-bottom: 20px; align-items: flex-start; width: 100%; }
.portrait-cell { display: flex; flex-direction: column; align-items: center; flex-shrink: 0; width: 100px; }
.hero-portrait { width: 100px !important; height: auto !important; max-height: 160px; border-radius: 10px; border: 2px solid rgba(255,255,255,0.2); object-fit: contain; background: rgba(0,0,0,0.3); display: block; }
.stars { color: #FFD700; font-size: 14px; margin-bottom: 5px; white-space: nowrap; }
.hero-tag-column { display: flex; flex-direction: column; gap: 8px; flex: 1; width: 100%; min-width: 0; }
.tag, .shared-toggle-summary.tag { background: var(--tag-theme) !important; border-radius: 6px; padding: 6px 12px; display: flex; align-items: center; gap: 10px; font-size: 0.9rem; font-weight: 600; color: #fff; width: 100%; min-height: 36px; text-decoration: none; }
.tag img, .mana-icon { width: 24px !important; height: 24px !important; object-fit: contain; }
details > summary { list-style: none; cursor: pointer; position: relative; }
details > summary::-webkit-details-marker { display: none; }
.shared-toggle-summary::after { content: ""; position: absolute; right: 12px; top: 50%; margin-top: -4px; width: 8px; height: 8px; border-right: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(45deg); transition: transform 0.2s; }
details[open] > .shared-toggle-summary::after { transform: rotate(-135deg); margin-top: 2px; }
.aether-power-panel { background: rgba(0,0,0,0.5); padding: 10px; border-radius: 0 0 6px 6px; display: flex; flex-direction: column; gap: 8px; }
.mana-calc-panel { background: rgba(0,0,0,0.3); padding: 10px; border-radius: 0 0 6px 6px; display: flex; flex-direction: column; gap: 8px; }
.mana-calc-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; }
.mana-calc-box { display: flex; flex-direction: column; align-items: center; justify-content: center; background: rgba(0,0,0,0.15); border-radius: 4px; padding: 6px 4px; min-height: 50px; text-align: center; }
.mana-calc-box-dark { background: rgba(0,0,0,0.4); }
.mana-calc-value { font-size: 1.1em; font-weight: 700; color: #fff; }
.mana-calc-value.bonus { color: #76ff76; }
.mana-calc-label { font-size: 0.7em; opacity: 0.7; }
.hero-stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; background: var(--tag-theme) !important; border-radius: 8px; padding: 10px; text-align: center; margin-bottom: 15px; width: 100%; }
.stat { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 5px 0; min-width: 0; }
.stat img { width: 20px !important; height: 20px !important; margin-bottom: 4px; display: block; }
.stat div[id^="display-"] { font-size: 1.1rem; font-weight: 800; line-height: 1.2; white-space: nowrap; }
.stat .plus { font-size: 0.7rem; color: #76ff76; min-height: 1.2em; }
.stat.power { background: rgba(0,0,0,0.5); border: 1px solid #e74c3c; border-radius: 4px; }
.hero-skill { background: var(--tag-theme) !important; border-radius: 8px; padding: 12px; margin-top: 10px; width: 100%; }
.hero-skill summary { font-weight: 700; padding-right: 20px; }
.section-content { padding-top: 10px; font-size: 0.9rem; line-height: 1.6; border-top: 1px solid rgba(255,255,255,0.15); margin-top: 8px; }
.section-content p { margin: 0 0 8px 0 !important; }
.addinfo { font-style: italic; opacity: 0.9; margin-top: -4px !important; margin-bottom: 12px !important; font-size: 0.85em; }

/* Options */
.hero-option-panel { background: var(--tag-theme) !important; border-radius: 16px; padding: 15px; color: #fff; width: 100%; border: 1px solid rgba(255,255,255,0.1); }
.options-content-wrapper { display: flex; flex-direction: column; gap: 15px; width: 100%; }
.option-fieldset { border: 1px solid rgba(255,255,255,0.2); background: rgba(0,0,0,0.2); border-radius: 8px; padding: 15px 10px 10px 10px; margin: 0; width: 100%; }
.option-fieldset legend { padding: 0 6px; font-size: 0.85em; opacity: 0.8; font-weight: 600; }
.option-buttons { display: grid; gap: 8px; width: 100%; }
.grid-1-col { grid-template-columns: 1fr; }
.grid-2-cols { grid-template-columns: 1fr 1fr; }
.grid-3-cols { grid-template-columns: 1fr 1fr 1fr; }
.grid-4-cols { grid-template-columns: repeat(4, 1fr); }
.grid-5-cols { grid-template-columns: repeat(5, 1fr); }
.option-button { background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.2); color: #ddd; padding: 6px 4px; border-radius: 6px; cursor: pointer; font-size: 0.75rem; text-align: center; min-height: 40px; display: flex; align-items: center; justify-content: center; flex-direction: column; }
.option-button img { width: 20px !important; height: auto !important; margin-bottom: 2px; display: block; }
.option-button.active { background: #fff; color: #222; font-weight: 700; border-color: #fff; }
.option-button:disabled, .option-button.disabled { opacity: 0.2; cursor: not-allowed; pointer-events: none; border-color: transparent; }
.all-clear-button { width: 100%; background: transparent; border: 1px solid rgba(255,255,255,0.3); color: #ccc; padding: 8px; margin-top: 5px; }

/* Emblem Simulator */
.emblem-simulator-container { margin-top: 10px; border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 8px; background-color: rgba(0, 0, 0, 0.2); }
.emblem-simulate-button { display: block; width: 100%; padding: 12px; background-color: #5a6475; color: #fff; font-weight: 700; text-align: center; cursor: pointer; list-style: none; position: relative; border-radius: 8px 8px 0 0; }
.emblem-simulate-button:hover { background-color: #6b7688; }
details:not([open]) .emblem-simulate-button { border-radius: 8px; }
.emblem-simulate-button::-webkit-details-marker { display: none; }
.emblem-simulate-button::after { content: ""; position: absolute; top: 50%; right: 20px; margin-top: -4px; border: 6px solid transparent; border-top-color: #fff; transition: transform 0.2s; }
.emblem-simulator-container[open] .emblem-simulate-button::after { transform: rotate(180deg) translateY(50%); }
.emblem-clear-button { display: block; width: 80%; margin: 10px auto; padding: 8px; background-color: #c25050; color: #fff; border: 1px solid rgba(255,255,255,0.1); border-radius: 4px; cursor: pointer; font-size: 0.8rem; font-weight: 700; }
.emblem-simulator-layout { display: grid; grid-template-columns: 30px 1fr; gap: 5px; padding: 10px 5px 20px 5px; background-image: linear-gradient(to bottom, transparent 54px, rgba(255,255,255,0.05) 54px, rgba(255,255,255,0.05) 55px, transparent 55px); background-size: 100% 55px; overflow-x: auto; }

/* --- Sprites --- */
.talent-node {
    background-image: url('/wp-content/uploads/camp-img/astro/iconui/talent-sprite-swap3.png');
    background-repeat: no-repeat;
    /* background-size deleted: use natural size */
}

.level-numbers { display: grid; grid-auto-rows: 55px; justify-items: center; align-items: center; padding-top: 8px; }
.talent-num { display: flex; align-items: center; justify-content: center; width: 100%; height: 40px; font-size: 1.0rem; font-weight: 700; color: rgba(255,255,255,0.7); }
.talent-grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 55px; justify-items: center; padding-top: 8px; }
.talent-node-wrapper { display: flex; flex-direction: column; align-items: center; width: 100%; position: relative; }
.talent-node { width: 40px; height: 40px; cursor: pointer; transition: transform 0.1s ease; background-position-x: -40px; /* Default Inactive */ }
.talent-node:hover { transform: scale(1.1); }
.emblem-bonus-label { color: #aaeebb; font-size: 0.65rem; font-weight: 700; text-shadow: 1px 1px 2px rgba(0,0,0,0.8); margin-top: -4px; pointer-events: none; white-space: nowrap; }

/* --- Sprite Positions (Corrected) --- */

/* Basic Active */
.talent-node.active { background-position-x: -200px !important; }

/* Class Icons (1-20) */
.talent-node.class-node { background-position-x: 0px; }
.talent-node.active.class-node { background-position-x: -160px !important; }

/* Master Stats (21-25) */
/* Note: No !important on X to allow active overwrite, but need !important on Y */
.talent-node.masterpowerup { background-position-x: -400px; }
.talent-node.active.masterpowerup { background-position-x: -440px !important; }

.talent-node.masterdefup { background-position-x: -400px; }
.talent-node.active.masterdefup { background-position-x: -440px !important; }

.talent-node.masterhpup { background-position-x: -400px; }
.talent-node.active.masterhpup { background-position-x: -440px !important; }

/* Superior / Master Superior (Node 26) */
.talent-node.activesuper { background-position-x: -360px !important; }
.talent-node.activemaster { background-position-x: -520px !important; }
.talent-node.master { background-position-x: -480px !important; }

/* Basic Types Y-Axis */
.talent-node.hpup { background-position-y: 0px !important; }
.talent-node.protectionup { background-position-y: -40px !important; }
.talent-node.powerup { background-position-y: -80px !important; }
.talent-node.healup { background-position-y: -120px !important; }
.talent-node.manaup { background-position-y: -240px !important; }
.talent-node.critup { background-position-y: -280px !important; }
.talent-node.protectionplus { background-position-y: -360px !important; }
.talent-node.powerplus { background-position-y: -400px !important; }
.talent-node.powerplus { background-position-y: -400px !important; }
.talent-node.hpplus { background-position-y: -400px !important; background-position-x: 0px !important; }
.talent-node.active.hpplus { background-position-x: -160px !important; }


/* Master Stats Y-Axis */
.talent-node.masterpowerup { background-position-y: 0px !important; }
.talent-node.masterdefup { background-position-y: -40px !important; }
.talent-node.masterhpup { background-position-y: -80px !important; }

/* Class Y-Axis (Start, Superior, Master) */
/* Barbarian */
[data-class="Barbarian"] .talent-node.class-node, .barbarian.activesuper, .barbarian.activemaster { background-position-y: 0px !important; }
/* Cleric */
[data-class="Cleric"] .talent-node.class-node, .cleric.activesuper, .cleric.activemaster { background-position-y: -40px !important; }
/* Druid */
[data-class="Druid"] .talent-node.class-node, .druid.activesuper, .druid.activemaster { background-position-y: -80px !important; }
/* Fighter */
[data-class="Fighter"] .talent-node.class-node, .fighter.activesuper, .fighter.activemaster { background-position-y: -120px !important; }
/* Monk */
[data-class="Monk"] .talent-node.class-node, .monk.activesuper, .monk.activemaster { background-position-y: -160px !important; }
/* Paladin */
[data-class="Paladin"] .talent-node.class-node, .paladin.activesuper, .paladin.activemaster { background-position-y: -200px !important; }
/* Ranger */
[data-class="Ranger"] .talent-node.class-node, .ranger.activesuper, .ranger.activemaster { background-position-y: -240px !important; }
/* Rogue */
[data-class="Rogue"] .talent-node.class-node, .rogue.activesuper, .rogue.activemaster { background-position-y: -280px !important; }
/* Sorcerer */
[data-class="Sorcerer"] .talent-node.class-node, .sorcerer.activesuper, .sorcerer.activemaster { background-position-y: -320px !important; }
/* Wizard */
[data-class="Wizard"] .talent-node.class-node, .wizard.activesuper, .wizard.activemaster { background-position-y: -360px !important; }

/* Skill Description Title */
.skilldesctitle {
    font-weight: bold;
    color: gold;
}

/* Tippy Tooltop Trigger */
.tippy-trigger {
    cursor: help;
    margin-left: 0.3em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    /* widthとheightはFontAwesomeアイコンの自然なサイズに任せるため削除 */
    /* border-radius: 50%; */ /* 青い丸をなくすため削除 */
    background-color: transparent; /* 背景色を透明にする */
    color: #87cefa; /* FontAwesomeアイコンの色をブルーに */
    font-size: 1.1em; /* アイコンのサイズを調整 */
    vertical-align: middle;
    line-height: 1;
}

.hdbdf-tooltip {
    position: fixed;
    z-index: 100000;
    max-width: min(420px, calc(100vw - 16px));
    padding: 10px;
    background: #444;
    color: whitesmoke;
    font-size: 13px;
    line-height: 1.5;
    pointer-events: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}


/* Tippy Tooltop Theme addinfoBlue */
.tippy-box[data-theme~='addinfoBlue'] {
  /* background: rgb(26,55,88);
  background: linear-gradient(90deg, rgba(26,55,88,1) 0%, rgba(46,91,127,1) 50%, rgba(26,55,88,1) 100%); */
  background-color: #444444;
  color: whitesmoke;
  font-size: 13px;
  /* arrow: false; - This is a JS option, not CSS */
  padding: 10px;
}
.tippy-box[data-theme~='addinfoBlue'] ul {
  margin-left: 0;
  padding-left: 20px;
}

/* Passive Skills Section */
.passive-section .passive-subtitle {
    font-size: 0.9em;
    font-weight: 700;
    color: #ffd700; /* gold */
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    padding-bottom: 0.3rem;
    border-bottom: 2px solid rgba(255, 215, 0, 0.3);
}
.passive-section .passive-skill-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.passive-section .passive-skill-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
.passive-section .passive-icon {
    width: 32px !important;
    height: 32px !important;
    flex-shrink: 0;
    object-fit: contain;
}
.passive-section .passive-skill-content {
    flex-grow: 1;
}
.passive-section .passive-skill-title {
    font-weight: 700;
    font-size: 0.95em;
}
.passive-section .passive-skill-desc {
    font-size: 1.0em;
    line-height: 1.5;
    opacity: 0.9;
}

.display-line-gap {
    display: block;
    padding-top: 0.25em;
}

/* Mana Summary Row */
.mana-summary-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 5px;
    margin-top: 8px;
    background: rgba(0,0,0,0.2);
    border-radius: 4px;
    font-size: 0.8em;
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.05);
}
.mana-summary-box {
    width: 50%;
}
.mana-summary-box:first-child {
    border-right: 1px solid rgba(255,255,255,0.1);
}
.mana-summary-label {
    display: block;
    opacity: 0.8;
    font-size: 0.9em;
}
.mana-summary-value {
    display: block;
    font-weight: 700;
    font-size: 1.1em;
    color: #fff;
}
.mana-summary-value b {
    color: #ffd700;
}

/* Custom Bullet Styling for Skill Descriptions */
.custom-bullet {
    list-style: none;
    padding-left: 0;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}

.custom-bullet li, p.custom-bullet-item {
    position: relative;
    padding-left: 1.4em; /* Create space for the bullet */
    
    /* ▼▼▼ 追加 ▼▼▼ */
    font-size: 1em;       /* 親要素(.section-content)のフォントサイズ(0.9rem)を継承・維持させる */
    line-height: 1.6;     /* 行間も通常のテキスト(.section-content)に合わせる */
}

.custom-bullet li::before, p.custom-bullet-item::before {
    content: '・';
    position: absolute;
    left: 0.2em; /* Position bullet in the space */
    top: 0;
    line-height: inherit; /* Align with text line */
}

/* Ensure consistent spacing for styled paragraphs */
p.custom-bullet-item {
    margin-bottom: 8px !important; /* Matches existing .section-content p rule */
    margin-left: 0; /* Override any user-agent stylesheet margin */
}

/* Costume bonus by family display under C Option buttons */
/* コンテナ：横並び・右寄せ・少しマージン */
#costume-bonus-display {
    display: none; /* 初期状態は非表示 */
    justify-content: flex-end; /* 右寄せ */
    gap: 12px; /* アイテム間の隙間 */
    margin-top: 8px;
    margin-bottom: 4px;
    font-size: 0.85rem;
    /* font-weight: bold; */
    color: #ffd700;
}

/* 個別のボーナスアイテム（アイコン＋数値） */
.c-bonus-item {
    display: flex;
    align-items: center;
    gap: 2px; /* アイコンと数値の隙間 */
}

/* アイコンサイズ調整 */
.c-bonus-icon {
    width: 16px;
    height: 16px;
    object-fit: contain;
    vertical-align: middle;
}

/* --- 画像エリアのスタイル --- */
.portrait-wrapper {
    position: relative;
    width: 100%;
    /* 正方形を維持する場合 */
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 4px;
    margin-bottom: 8px; /* ボタンとの隙間 */
}
/* --- HTMLタグ内の width="80" を無視させる --- */
.portrait-wrapper img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    object-position: top center;
}
/* 画像本体 */
.hero-portrait.square-style {
    width: 100%;
    height: 100%;
    object-fit: cover; /* 枠いっぱいに表示 */
    object-position: top center;
}

/* --- BETAバッジ (中央配置スタイル) --- */
/* BETAバッジ：ゲーム内UI風のゴールド立体文字 */
.portrait-wrapper.is-beta::before {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px; /* 文字の大きさ+パディングに合わせて高さを調整してください */
    
    background-color: rgba(0, 0, 0, 0.4); /* ここで色調整 */
    z-index: 9; /* 文字の下に敷く */
    pointer-events: none;
}

/* 2. 既存修正：ゴールド文字担当 (::after) */
.portrait-wrapper.is-beta::after {
    /* --- 既存の設定 --- */
    content: "BETA";
    position: absolute;
    bottom: 0; /* 位置合わせ */
    left: 0;
    width: 100%;
    
    /* フォント・グラデーション設定はそのまま */
    font-family: "Impact", "Arial Black", sans-serif;
    font-size: 1.8rem;
    font-weight: 900;
    letter-spacing: 1px;
    line-height: 1;
    text-align: center;
    background: linear-gradient(to bottom, #FFF8DC 0%, #FFD700 48%, #FF8C00 52%, #D35400 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    filter: 
        drop-shadow(1.5px 1.5px 0px #000) 
        drop-shadow(-1.5px -1.5px 0px #000) 
        drop-shadow(-1.5px 1.5px 0px #000) 
        drop-shadow(1.5px -1.5px 0px #000)
        drop-shadow(0px 3px 2px rgba(0,0,0,0.8));

    /* --- 変更点 --- */
    padding-bottom: 8px; /* さきほどの調整値 */
    /* background-color: ... はここでは効かないので削除 */
    
    z-index: 10; /* 背景(9)より手前に出す */
    pointer-events: none;
}


/* --- 設定コピーボタン --- */
.copy-config-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1px;
    padding: 2px 0;
    
    /* 右側のOPTIONボタンに似せたスタイル */
    background-color: #444; 
    border: 1px solid #666;
    color: #fff;
    font-size: 0.55rem;
    font-weight: bold;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.copy-config-btn:hover {
    background-color: #555;
    border-color: #888;
}

/* コピー成功時のスタイル（緑色） */
.copy-config-btn.copied {
    background-color: #2e7d32; /* Green */
    border-color: #4caf50;
}


/* --- タイトル行レイアウト --- */
.hero-title-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    gap: 8px;
    margin-bottom: 15px; /* カード内のバランス調整 */
}

.hero-title-line .hdbdf-search-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    margin: 0;
    padding: 0.45rem 0.8rem;
    border: 1px solid #dfc15e;
    border-radius: 4px;
    background: #333;
    color: #dfc15e;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
}

/* 名前エリア（常に中央確保） */
.hero-name-wrapper {
    flex-grow: 1;
    text-align: center;
    min-width: 0;
}

/* --- 矢印コンテナ --- */
.nav-arrow-container {
    position: relative;
    z-index: 50;
    
    /* 初期状態は非表示（JSで中身がある時だけ表示） */
    visibility: hidden; 
}
.nav-arrow-container.has-items {
    visibility: visible;
}

/* 矢印ボタンのデザイン（円形・半透明黒） */
.nav-arrow-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.3); /* 暗めの半透明 */
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #eee;
    
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    
    font-size: 1.1rem; /* アイコンサイズ */
}
.nav-arrow-btn:hover {
    background-color: rgba(255, 255, 255, 0.2); /* ホバーで少し明るく */
    color: #fff;
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* --- ポップアップメニュー --- */
.nav-popup-menu {
    display: none; /* デフォルト非表示 */
    position: absolute;
    top: 110%; /* ボタンの少し下 */
    
    /* 背景：属性色を使用しつつ透過 */
    background: var(--tag-theme); 
    opacity: 0.95;
    
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 8px;
    padding: 8px;
    
    /* ボタンを横並びにする設定 */
    width: max-content;
    max-width: 220px;
    display: flex; /* showクラスがなくてもflex定義は持たせておく（display切り替えで制御） */
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
    
    box-shadow: 0 8px 20px rgba(0,0,0,0.6);
    z-index: 100;
}

/* 表示制御 */
.nav-popup-menu { display: none; }
.nav-popup-menu.show { display: flex; }

/* 左メニューは左寄せ、右メニューは右寄せ */
.nav-arrow-container.prev .nav-popup-menu { left: 0; }
.nav-arrow-container.next .nav-popup-menu { right: 0; }

/* --- メニュー内のリンクボタン --- */
.nav-menu-item {
    display: inline-block;
    padding: 6px 10px;
    color: #eee;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: bold;
    line-height: 1;
    
    /* ボタンの見た目 */
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 4px;
    
    text-align: center;
    transition: all 0.2s;
}
.nav-menu-item:hover {
    background: #fff;
    color: #333;
    border-color: #fff;
}

@media (min-width: 768px) {
    .hero-detail-layout { flex-direction: row; align-items: flex-start; }
    .hero-left-pane { flex: 1 1 50%; width: 50%; min-width: 0; }
    .hero-right-pane { flex: 1 1 50%; width: 50%; min-width: 0; }
    /* PCでの文字サイズ調整：ベースが大きいため少し縮小 */
    .section-content, .tag, .shared-toggle-summary.tag { font-size: 0.8rem; }
}

/* --- 追加修正: リスト内見出しのインデント解除 --- */
.embedded-header {
    margin-left: -1.6em;
    margin-top: 12px;
    margin-bottom: 6px;
    display: block;
    line-height: 1.4;
    font-weight: bold;
}

/* --- 追加修正: Tippy内リストのデザイン統一 --- */
/* 強制的に「白丸」を消して、統一した「・」を出す設定 */
.tippy-box ul.custom-bullet {
    list-style: none; /* ブラウザ標準の記号（白丸など）を無視する */
    padding-left: 0;
    margin: 0.5em 0;
}
.tippy-box ul.custom-bullet li {
    position: relative;
    padding-left: 1.4em;
    margin-bottom: 4px;
    font-size: 1em;
    line-height: 1.6;
}
.tippy-box ul.custom-bullet li::before {
    content: '・'; /* これだけを表示する */
    position: absolute;
    left: 0.2em;
    top: 0;
}

/* --- subheaderクラス付きリストのスタイル --- */
/* 通常時とツールチップ(Tippy)時の両方に適用 */
ul.custom-bullet li.subheader,
.tippy-box ul.custom-bullet li.subheader {
    list-style: none !important;
    padding-left: 0 !important;     /* バレット用の余白を消す */
    margin-left: -0.2em !important; /* 左に少し突き出させる（お好みで調整してください） */
    margin-top: 12px;
    margin-bottom: 6px;
    font-weight: bold;
    color: #6cc9f9;                 /* [#!]と同じ青色 */
    line-height: 1.4;
}

/* バレット（・）を強制的に消す */
ul.custom-bullet li.subheader::before,
.tippy-box ul.custom-bullet li.subheader::before {
    content: none !important;
}

.hero-variant-icons {
    display: none;
    justify-content: center;
    gap: 8px;
    margin: 10px auto 0;
    padding: 8px 10px;
    background: rgba(0, 0, 0, 0.35);
    border-radius: 8px;
    flex-wrap: wrap;
}
.hero-variant-icon {
    display: flex;
    width: 58px;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: #fff;
    font-size: 0.7rem;
    font-weight: bold;
    text-decoration: none;
    opacity: 0.8;
}
.hero-variant-icon:hover, .hero-variant-icon.active { opacity: 1; }
.hero-variant-icon.active { color: #ffd700; }
.hero-variant-icon img { width: 48px; height: 48px; object-fit: contain; border-radius: 6px; }
