/*
Theme Name: Polilog Pop Engine (Stripe Clean Edition - Unboxed)
Version: 6.1.0
Description: セクションのベタ塗りを排除し、要素ごとに独立したカード化。スマホのテキスト幅を最大化。ヘッダーSVGロゴ・ステータス右寄せ対応。
*/

/* ============================================================
   1. COLOR VARIABLES
   ============================================================ */
:root {
    --st-bg: #f6f9fc;
    --st-card: #ffffff;
    --st-text-main: #1a1f36;
    --st-text-muted: #4f566b;
    --st-border: #e3e8ee;
    
    --pop-red: #FF595E;
    --pop-yellow: #FFCA3A;
    --pop-green: #8AC926;
    --pop-blue: #1982C4;
    --pop-purple: #6A4C93;

    --primary: var(--pop-blue);
    --primary-light: rgba(25, 130, 196, 0.1);
    --shadow-sm: 0 2px 5px -1px rgba(50,50,93,0.15), 0 1px 3px -1px rgba(0,0,0,0.15);
    --shadow-md: 0 13px 27px -5px rgba(50,50,93,0.15), 0 8px 16px -8px rgba(0,0,0,0.15);
}

/* ============================================================
   2. GLOBAL BASE
   ============================================================ */
body {
    background-color: var(--st-bg);
    color: var(--st-text-main);
    margin: 0; padding: 0; 
    font-size: 16px; 
    line-height: 1.8;
    font-family: -apple-system, BlinkMacSystemFont, 'Inter', 'Noto Sans JP', sans-serif;
    -webkit-font-smoothing: antialiased;
}

.top-container { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 20px; box-sizing: border-box; }

/* ============================================================
   3. HEADER & BANNER (ロゴとバッジのバッキバキ配置)
   ============================================================ */
.live-dev-banner {
    background: #ffffff; color: var(--st-text-main); text-align: center;
    padding: 12px; font-size: 13px; font-weight: 700; letter-spacing: 0.05em;
    border-radius: 0 0 12px 12px; margin-bottom: 20px;
    border: 1px solid var(--st-border); border-top: none; box-shadow: var(--shadow-sm);
}

/* ヘッダー全体（ガラスモーフィズム） */
.pop-header {
    background: rgba(255, 255, 255, 0.85); backdrop-filter: blur(10px);
    padding: 12px 20px;
    position: sticky; top: 0; z-index: 2000; border-bottom: 1px solid var(--st-border);
}

/* 左右に分けるコンテナ */
.header-container {
    width: 100%; max-width: 1140px; margin: 0 auto;
    display: flex; justify-content: space-between; align-items: center;
}

.header-left { display: flex; align-items: center; }
.header-right { display: flex; align-items: center; gap: 8px; }

/* SVGロゴのニチャつき調整 */
.site-logo { display: flex; align-items: center; text-decoration: none; }
.custom-logo {
    display: block; height: auto; transition: transform 0.2s ease;
}
.custom-logo:hover { transform: scale(1.05); }

/* ステータスバッジのスマート化 */
.status-badge { 
    padding: 4px 10px; border-radius: 30px; font-size: 11px; font-weight: 700; 
    display: flex; align-items: center; gap: 6px; 
    background: #fff; color: var(--st-text-muted);
    border: 1px solid var(--st-border); box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}
.pulse-icon { color: var(--pop-green); animation: pulse 2s infinite; font-size: 10px; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

/* ============================================================
   4. FRONT PAGE (TOP PAGE)
   ============================================================ */
.hero-pop { padding: 80px 0 60px; text-align: left; max-width: 800px; }
.hero-title { font-size: 64px; font-weight: 900; letter-spacing: -0.04em; color: var(--st-text-main); margin-bottom: 24px; line-height: 1.1; }
.hero-lead { font-size: 20px; color: var(--st-text-muted); line-height: 1.6; }

.content-grid-pop { display: grid; grid-template-columns: 1fr 340px; gap: 40px; align-items: start; padding-bottom: 100px; }

.card-pop {
    background: var(--st-card); border-radius: 16px; padding: 40px;
    box-shadow: var(--shadow-sm); margin-bottom: 40px;
    border: 1px solid rgba(0,0,0,0.03); transition: transform 0.2s, box-shadow 0.2s;
}
.card-pop:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.card-tag { display: inline-block; background: var(--primary-light); color: var(--pop-blue); padding: 6px 14px; border-radius: 30px; font-size: 12px; font-weight: 800; letter-spacing: 0.1em; margin-bottom: 24px; }
.section-title { font-size: 28px; font-weight: 800; color: var(--st-text-main); margin-bottom: 24px; }
.chara-text { color: var(--st-text-muted); font-size: 16px; line-height: 1.8; }
.btn-pop { display: inline-flex; align-items: center; background: var(--pop-blue); color: #fff; padding: 14px 28px; border-radius: 8px; font-weight: 700; text-decoration: none; box-shadow: var(--shadow-sm); margin-top: 20px; }

/* サイドバー */
.sync-pop-card { padding: 32px; }
.sync-item { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--st-border); padding: 12px 0; font-size: 14px; }
.sync-item:last-child { border: none; padding-bottom: 0; }
.sync-item .label { color: var(--st-text-muted); font-weight: 600; font-size: 12px; }
.sync-item .value { font-weight: 700; color: var(--st-text-main); }
.sync-item .online { color: var(--pop-green); display: flex; align-items: center; gap: 6px;}

/* ============================================================
   5. ABOUT PAGE (METHODOLOGY)
   ============================================================ */
.page-hero-pop { padding: 60px 0 40px; text-align: center; }
.page-title-pop { font-size: 48px; font-weight: 900; color: var(--st-text-main); margin-bottom: 16px; letter-spacing: -0.02em; }
.page-subtitle-pop { color: var(--st-text-muted); font-size: 18px; max-width: 700px; margin: 0 auto; }

.page-card-pop {
    background: var(--st-card); border-radius: 20px; padding: 60px 80px;
    box-shadow: var(--shadow-md); max-width: 900px; margin: 0 auto 100px;
}

.about-general-section,
.about-expert-section { max-width: 900px; margin: 0 auto; }

.about-h2 { font-size: 28px; font-weight: 800; color: var(--st-text-main); margin: 80px 0 24px; }
.about-h3 { font-size: 20px; color: var(--pop-blue); margin: 60px 0 20px; font-weight: 700; }
.about-lead { font-size: 18px; color: var(--st-text-muted); line-height: 1.8; margin-bottom: 32px; }
.about-intro-badge { display: inline-block; background: var(--primary-light); color: var(--pop-blue); padding: 6px 14px; border-radius: 30px; font-size: 12px; font-weight: 800; letter-spacing: 0.1em; margin-bottom: 16px; }

.about-promise-box { background: #ffffff; border: 1px solid var(--st-border); border-left: 4px solid var(--pop-blue); padding: 24px 32px; border-radius: 8px; margin: 40px 0; display: flex; gap: 20px; align-items: flex-start; box-shadow: var(--shadow-sm); }
.about-promise-icon { font-size: 28px; line-height: 1; }
.about-promise-box strong { color: var(--st-text-main); font-size: 18px; display: block; margin-bottom: 8px;}
.about-promise-box p { margin: 0; color: var(--st-text-muted); font-size: 15px; }

.about-feature-list { list-style: none; padding: 0; margin-bottom: 60px;}
.about-feature-list li { background: #ffffff; border: 1px solid var(--st-border); padding: 24px; border-radius: 12px; margin-bottom: 16px; display: flex; gap: 20px; transition: transform 0.2s, box-shadow 0.2s; box-shadow: 0 2px 4px rgba(0,0,0,0.02);}
.about-feature-list li:hover { transform: translateX(4px); box-shadow: var(--shadow-sm); }
.about-feature-list strong { color: var(--st-text-main); font-size: 16px; display: block; margin-bottom: 4px;}
.about-feature-list p { margin: 0; color: var(--st-text-muted); font-size: 14px; }
.about-feature-icon { font-size: 24px; width: 40px; height: 40px; background: var(--st-bg); border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0;}

.about-chart-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; margin-top: 40px; }
.about-chart-card { background: var(--st-card); padding: 32px; border-radius: 16px; border: 1px solid var(--st-border); box-shadow: var(--shadow-sm); }
.about-chart-card--blue { border-top: 4px solid var(--pop-blue); }
.about-chart-card--yellow { border-top: 4px solid var(--pop-yellow); }
.about-chart-svg-wrap { text-align: center; margin-bottom: 20px; }
.about-chart-title { font-size: 18px; font-weight: 800; color: var(--st-text-main); margin-bottom: 12px; text-align: center; display: flex; align-items: center; justify-content: center; gap: 8px; }
.about-chart-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; }
.about-chart-desc { font-size: 14px; color: var(--st-text-muted); line-height: 1.8; margin: 0; }

.about-divider { display: flex; align-items: center; justify-content: center; margin: 100px 0 60px; max-width: 900px; margin-left: auto; margin-right: auto;}
.about-divider::before, .about-divider::after { content: ''; flex: 1; height: 1px; }
.about-divider::before { background: linear-gradient(90deg, transparent, var(--st-border) 80%); }
.about-divider::after { background: linear-gradient(270deg, transparent, var(--st-border) 80%); }
.about-divider-label { display: inline-block; background: #ffffff; color: var(--st-text-muted); font-size: 12px; font-weight: 800; letter-spacing: 0.15em; padding: 8px 24px; border-radius: 50px; border: 1px solid var(--st-border); margin: 0 20px; box-shadow: var(--shadow-sm); }

.about-expert-section .about-h2 { margin-top: 0; }
.about-expert-section p { font-size: 16px; color: var(--st-text-muted); }

.about-protocol-table { background: #ffffff; border-radius: 16px; padding: 40px 48px; border: 1px solid var(--st-border); box-shadow: var(--shadow-sm); margin-top: 40px; }
.about-protocol-row { border-bottom: 1px solid var(--st-border); padding: 32px 0; display: flex; gap: 24px; align-items: flex-start;}
.about-protocol-row:last-child { border-bottom: none; padding-bottom: 0; }
.about-protocol-row:first-child { padding-top: 0; }

.about-protocol-label { flex-shrink: 0; width: 60px; }
.about-pid { background: rgba(106, 76, 147, 0.1); color: var(--pop-purple); padding: 4px 10px; border-radius: 6px; font-weight: 900; font-size: 14px;}
.about-protocol-body { min-width: 0; width: 100%; }
.about-protocol-title { font-size: 18px; font-weight: 700; color: var(--st-text-main); margin: 0 0 8px; }

.about-math-box { background: var(--st-bg); border: 1px solid var(--st-border); padding: 20px; border-radius: 8px; margin: 16px 0; color: var(--st-text-main); width: 100%; max-width: 100%; box-sizing: border-box; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.about-math-box mjx-container { min-width: max-content; }

.about-p7-section { background: #ffffff; border-radius: 16px; padding: 40px 48px; border: 1px solid var(--st-border); box-shadow: var(--shadow-sm); margin-top: 40px; }
.about-p7-header { display: flex; gap: 16px; margin-bottom: 24px; align-items: flex-start;}
.about-p7-foundation { background: var(--st-bg); padding: 20px; border-radius: 8px; margin-bottom: 24px; border: 1px solid var(--st-border);}
.about-p7-foundation-title { color: var(--st-text-main); font-weight: 700; margin-bottom: 8px; font-size: 15px;}

.about-p7-observations { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-top: 24px;}
.about-p7-obs-item { background: #ffffff; padding: 20px; border-radius: 8px; border: 1px solid var(--st-border); box-shadow: 0 2px 4px rgba(0,0,0,0.02);}
.about-p7-obs-symbol { display: inline-block; color: var(--pop-blue); font-family: monospace; font-size: 15px; font-weight: bold; margin-bottom: 8px;}
.about-p7-obs-item strong { display: block; color: var(--st-text-main); margin-bottom: 4px; font-size: 15px;}
.about-p7-obs-item p { font-size: 13px; margin: 0; line-height: 1.6;}

.about-mini-list { list-style: none; padding: 0; margin-top: 16px;}
.about-mini-list li { position: relative; padding-left: 16px; margin-bottom: 8px; font-size: 15px; color: var(--st-text-muted);}
.about-mini-list li::before { content: ''; position: absolute; left: 0; top: 10px; width: 6px; height: 6px; border-radius: 50%; background: var(--pop-purple);}

/* ============================================================
   6. RESPONSIVE DESIGN (スマホ用調整・最適化)
   ============================================================ */
@media (max-width: 992px) {
    .content-grid-pop { grid-template-columns: 1fr; }
    .hero-title { font-size: 48px; }
}

@media (max-width: 768px) {
    /* フロントページ */
    .hero-pop { padding: 40px 0; }
    .hero-title { font-size: 30px; }
    .section-title { font-size: 22px; }
    .card-pop { padding: 32px 20px; }
    
    .page-card-pop { padding: 40px 20px; border-radius: 0; }
    
    .page-hero-pop { padding: 40px 0 20px; }
    .page-title-pop { font-size: 28px; }
    .about-h2 { font-size: 22px; margin: 40px 0 20px; }
    .about-h3 { font-size: 18px; margin: 40px 0 16px; }
    
    .about-chart-grid { grid-template-columns: 1fr; gap: 20px; }
    .about-chart-card { padding: 24px; } 
    .about-divider { margin: 60px 0 40px; }
    
    .about-protocol-table { padding: 32px 20px; border-radius: 12px; }
    .about-protocol-row { flex-direction: column; gap: 12px; padding: 24px 0; }
    
    .about-p7-section { padding: 32px 20px; border-radius: 12px; margin-top: 32px; }
    .about-p7-foundation { padding: 16px 12px; margin-bottom: 16px;}
    .about-p7-obs-item { padding: 16px; }

    .about-math-box { padding: 16px 12px; font-size: 14px; }
}

/* 🎯 スマホ時のヘッダーバッジ微調整（追加！） */
@media (max-width: 600px) {
    .pop-header { padding: 8px 12px; }
    .status-badge { font-size: 10px; padding: 4px 8px; }
    .header-right { gap: 4px; }
}

/* ============================================================
   7. HORIZONTAL SCROLL HELPERS & OVERVIEW CARDS
   ============================================================ */

/* --- スクロールテーブル用 --- */
.polilog-table-container {
    position: relative;
    margin-bottom: 40px;
}
.polilog-scroll-hint {
    text-align: right;
    margin-bottom: 8px;
    padding-right: 4px;
}
.polilog-scroll-hint span {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    color: var(--st-text-muted);
    background: rgba(25, 130, 196, 0.05);
    border: 1px solid rgba(25, 130, 196, 0.2);
    padding: 4px 12px;
    border-radius: 20px;
    letter-spacing: 0.05em;
    animation: bounce-horizontal 2s infinite;
}
@keyframes bounce-horizontal {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-4px); }
}
.polilog-scroll-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 12px;
}
.polilog-scroll-wrapper::-webkit-scrollbar {
    height: 6px;
}
.polilog-scroll-wrapper::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 10px;
}
.polilog-scroll-wrapper::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}
.polilog-scroll-wrapper::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* --- プロトコル概要カード用 --- */
.proto-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
    margin-top: 20px;
    margin-bottom: 40px;
}
.proto-overview-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.02);
    transition: transform 0.2s, box-shadow 0.2s;
}
.proto-overview-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.05);
}
.proto-overview-title {
    font-weight: 700;
    color: #0f172a;
    font-size: 1rem;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.proto-overview-badge {
    font-size: 0.7rem;
    font-weight: 900;
    background: #f1f5f9;
    color: #64748b;
    padding: 2px 6px;
    border-radius: 4px;
    letter-spacing: 0.05em;
}
.proto-overview-desc {
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.6;
}
.proto-detail-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px dashed #e2e8f0;
}
.proto-detail-header h4 {
    margin: 0;
    font-size: 1.1rem;
    color: #334155;
}

@charset "UTF-8";

/* === POLILOG 共通変数（今後の特集でも使い回せるお！） === */
:root {
    --pl-bg-color: #fcfcfc; /* やや冷たいオフホワイト（公文書のイメージ） */
    --pl-text-main: #222222;
    --pl-text-sub: #555555;
    --pl-accent-red: #cc0000; /* パニックや警告を表す赤 */
    --pl-system-bg: #1a1a1a; /* AIログ用の黒背景 */
    --pl-system-text: #00ff66; /* AIログ用の緑文字（ターミナル風） */
    --pl-border-color: #dddddd;
    
    /* フォント設定：明朝体で重厚感、システムログは等幅 */
    --pl-font-serif: "Shippori Mincho", "Noto Serif JP", serif;
    --pl-font-sans: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    --pl-font-mono: "Courier New", Consolas, monospace;
}

body {
    font-family: var(--pl-font-serif);
    color: var(--pl-text-main);
    background-color: var(--pl-bg-color);
    line-height: 1.8;
    margin: 0;
    padding: 0;
    font-size: 16px;
    letter-spacing: 0.05em;
}

.polilog-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* === ヘッダー＆タイトル === */
.pl-header {
    text-align: center;
    margin-bottom: 50px;
    border-bottom: 2px solid var(--pl-text-main);
    padding-bottom: 20px;
}

.pl-series-name {
    font-family: var(--pl-font-sans);
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--pl-text-sub);
    text-transform: uppercase;
    letter-spacing: 0.2em;
}

.pl-main-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin: 10px 0;
    line-height: 1.4;
}

.pl-sub-title {
    font-size: 1.1rem;
    color: var(--pl-text-sub);
}

/* === 本文要素 === */
.pl-chapter-title {
    font-size: 1.6rem;
    font-weight: bold;
    margin-top: 60px;
    margin-bottom: 30px;
    padding-left: 15px;
    border-left: 5px solid var(--pl-text-main);
}

.pl-text {
    margin-bottom: 20px;
    text-indent: 1em; /* 段落の字下げ */
}

/* === 引用（歴史の証言）コンポーネント === */
/* ※2章以降で使う「政治家の発言」用のスタイルだお！ */
.pl-quote-block {
    margin: 40px 0;
    padding: 25px 30px;
    background-color: #f4f4f4;
    border-top: 1px solid var(--pl-border-color);
    border-bottom: 1px solid var(--pl-border-color);
    position: relative;
}

.pl-quote-text {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--pl-text-main);
    line-height: 1.9;
    margin-bottom: 15px;
}

.pl-quote-speaker {
    text-align: right;
    font-size: 0.9rem;
    color: var(--pl-text-sub);
    font-family: var(--pl-font-sans);
}

/* === システム・ログ（AI解析）コンポーネント === */
.pl-system-log {
    background-color: var(--pl-system-bg);
    color: var(--pl-system-text);
    font-family: var(--pl-font-mono);
    padding: 30px;
    margin: 50px 0;
    border-radius: 4px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.pl-system-header {
    font-size: 0.85rem;
    border-bottom: 1px solid #333;
    padding-bottom: 10px;
    margin-bottom: 20px;
    color: #888;
    text-transform: uppercase;
}

.pl-system-text {
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 15px;
}

.pl-highlight-red {
    color: #ff3333;
    font-weight: bold;
}

/* === 罫線（Nスペ風の場面転換） === */
.pl-divider {
    border: 0;
    text-align: center;
    margin: 60px 0;
}
.pl-divider::before {
    content: "***";
    font-size: 20px;
    letter-spacing: 10px;
    color: var(--pl-text-sub);
}