/**
 * Advanced Shop HP Blog - 個別記事ページスタイル (Hitode Blog Style)
 */

/* ========================================
   変数定義（メインCSSと同じ）
   ======================================== */
:root {
    --primary: #2962ff;
    --primary-dark: #0039cb;
    --secondary: #00d2ff;
    --accent: #ffea00;
    --text-main: #1e293b;
    --text-sub: #64748b;
    --bg-body: #ffffff;
    --bg-card: #ffffff;
    --bg-header: #f8fbff;
    --border: #e2e8f0;
    --footer-bg: #0f172a;

    --font-base: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', sans-serif;
    --font-heading: 'Noto Sans JP', sans-serif;

    --container-max: 900px;
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;

    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
    --transition: all 0.3s ease;
}

/* ========================================
   共通リセット & ベース (styles.cssと同期)
   ======================================== */
* {
    box-sizing: border-box;
}

body {
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.8;
    font-size: 16px;
    font-family: var(--font-base);
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    margin: 0;
    line-height: 1.4;
    font-weight: 700;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

/* ========================================
   記事コンテナ
   ======================================== */
.blog-post {
    max-width: var(--container-max);
    margin: 2rem auto;
    padding: 3rem 4rem;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
}

/* ========================================
   ヘッダーエリア
   ======================================== */
/* ========================================
   コンポーネント: ヘッダー
   ======================================== */
.blog-hero {
    background: var(--bg-header);
    color: var(--text-main);
    padding: 3rem 1rem 2rem;
    text-align: center;
    border-bottom: none;
    margin-bottom: 2rem;
}

.hero-overlay {
    display: none;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-content h1 {
    margin-bottom: 1.5rem;
}

/* サイトロゴ v10: Split Color Slide (Global) */
.site-logo-v10 {
    /* PC: コンテンツ幅に合わせる / Mobile: 画面幅に収まるよう縮小 */
    font-size: clamp(1.5rem, 6vw, 3.8rem);
    font-weight: 1000;
    display: inline-flex;
    flex-wrap: nowrap;
    /* 特別に指示がない限り横並びを死守 */
    justify-content: center;
    align-items: center;
    gap: 0;
    transition: var(--transition);
    letter-spacing: -0.01em;
    line-height: 1;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .site-logo-v10 {
        font-size: clamp(1.4rem, 5vw, 2rem);
    }
}

@media (max-width: 480px) {
    .site-logo-v10 {
        flex-wrap: nowrap;
        gap: 0;
    }
}

.site-logo-v10:hover {
    transform: translateY(-3px) scale(1.02);
    opacity: 1;
}

.v10-bazz {
    background: var(--primary);
    color: white;
    padding: 0.1em 0.5em;
    border-radius: 0.3em 0 0 0.3em;
}

.v10-sns {
    border: 0.08em solid var(--primary);
    padding: 0.05em 0.6em;
    border-radius: 0 0.3em 0.3em 0;
    margin-left: -0.05em;
    color: var(--text-main);
    display: flex;
    align-items: center;
    background: white;
}

.hero-content p {
    font-size: 1rem;
    color: var(--text-sub);
    font-weight: 400;
    line-height: 1.6;
    max-width: 600px;
    /* 読みやすい幅に制限 */
    margin: 0 auto;
    word-break: keep-all;
    /* 単語の途中での改行を防ぐ（日本語でも機能） */
    overflow-wrap: anywhere;
    /* 溢れる場合はどこでも改行を許可 */
}

.blog-post-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    font-size: 0.9rem;
    color: var(--text-sub);
}

.blog-post-meta time {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.blog-category {
    background: var(--primary);
    color: white;
    font-weight: 600;
    padding: 0.3rem 0.8rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
}

/* ========================================
   パンくずリスト
   ======================================== */
.blog-breadcrumbs {
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    color: var(--text-sub);
}

.blog-breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0;
}

.blog-breadcrumbs li+li::before {
    content: ">";
    margin: 0 0.5rem;
    color: var(--border);
}

.blog-breadcrumbs a:hover {
    color: var(--primary);
}

/* ========================================
   アイキャッチ画像
   ======================================== */
.blog-eye-catch {
    margin: 2rem 0 3rem;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.blog-eye-catch img {
    width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   記事本文スタイル
   ======================================== */
.blog-post-content {
    font-size: 1rem;
    line-height: 1.9;
    color: var(--text-main);
}

.blog-post-content p {
    margin-bottom: 1.8rem;
}

/* 見出し H2 */
.blog-post-content h2 {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 3rem 0 1.5rem;
    padding: 0.75rem 1rem;
    background: var(--bg-header);
    color: var(--text-main);
    border-left: 5px solid var(--primary);
    border-radius: var(--radius-sm);
}

/* 見出し H3 */
.blog-post-content h3 {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 2.5rem 0 1.2rem;
    padding-bottom: 0.5rem;
    color: var(--text-main);
    border-bottom: 2px solid var(--primary);
}

/* 見出し H4 */
.blog-post-content h4 {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 2rem 0 1rem;
    padding-left: 0.8rem;
    border-left: 3px solid var(--secondary);
    color: var(--text-main);
}

/* リスト */
.blog-post-content ul,
.blog-post-content ol {
    margin: 1.5rem 0 2rem;
    padding-left: 2rem;
    background: #fafaf9;
    border: 1px solid var(--border);
    padding: 1.25rem 1.25rem 1.25rem 2.5rem;
    border-radius: var(--radius-sm);
}

.blog-post-content li {
    margin-bottom: 0.75rem;
}

.blog-post-content li:last-child {
    margin-bottom: 0;
}

.blog-post-content ul li {
    list-style-type: disc;
}

.blog-post-content ol li {
    list-style-type: decimal;
}

/* 引用 */
.blog-post-content blockquote {
    position: relative;
    background: #f9f8f6;
    padding: 1.5rem 2rem;
    margin: 2rem 0;
    color: var(--text-sub);
    border-left: 4px solid var(--secondary);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-style: italic;
}

.blog-post-content blockquote::before {
    content: "\201C";
    position: absolute;
    top: -10px;
    left: 10px;
    font-size: 3rem;
    opacity: 0.1;
    font-family: serif;
    color: var(--secondary);
}

/* 強調文字 */
.blog-post-content strong {
    background: linear-gradient(transparent 60%, rgba(255, 153, 102, 0.3) 60%);
    padding: 0 0.2em;
    font-weight: 700;
    color: var(--text-main);
}

/* リンク */
.blog-post-content a {
    color: var(--primary);
    text-decoration: underline;
    font-weight: 600;
    transition: var(--transition);
}

.blog-post-content a:hover {
    color: var(--primary-dark);
    opacity: 0.8;
}

/* 画像 */
.blog-post-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-sm);
    margin: 2rem auto;
    box-shadow: var(--shadow-sm);
}

/* テーブル */
.blog-post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 2rem 0;
    box-shadow: var(--shadow-sm);
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--border);
}

.blog-post-content th {
    background: var(--bg-header);
    font-weight: 600;
    text-align: left;
    padding: 0.75rem 1rem;
    border-bottom: 2px solid var(--border);
}

.blog-post-content td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
}

/* コードブロック */
.blog-post-content pre {
    background: #2d2d2d;
    color: #ccc;
    padding: 1.5rem;
    border-radius: var(--radius-sm);
    overflow-x: auto;
    margin: 2rem 0;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.9em;
}

.blog-post-content code {
    background: #f4f4f4;
    color: #d63384;
    padding: 0.2rem 0.4rem;
    border-radius: 3px;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.9em;
}

.blog-post-content pre code {
    background: none;
    color: inherit;
    padding: 0;
}

/* ========================================
   SNSシェアセクション
   ======================================== */
.blog-share-section {
    margin-top: 4rem;
    padding: 2rem;
    background: var(--bg-header);
    border-radius: var(--radius-md);
    text-align: center;
    border: 1px solid var(--border);
}

.blog-share-section h3 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-sub);
    font-weight: 600;
}

.blog-share-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.share-button,
.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.7rem 1.5rem;
    border-radius: var(--radius-sm);
    color: white;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: var(--transition);
    min-width: 120px;
}

.share-button:hover,
.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.share-twitter {
    background: #1da1f2;
}

.share-facebook {
    background: #1877f2;
}

.share-line {
    background: #00c300;
}

.share-pocket {
    background: #ef4056;
}

.share-hatena {
    background: #00a4de;
}

/* ========================================
   広告エリア
   ======================================== */
.blog-ad-section {
    margin: 3rem 0;
    text-align: center;
    background: var(--bg-header);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
}

/* ========================================
   レスポンシブ
   ======================================== */
@media (max-width: 768px) {
    .blog-post {
        padding: 2rem 1.5rem;
        margin: 1rem;
    }

    .blog-post-title {
        font-size: 1.6rem;
    }

    .blog-post-content h2 {
        font-size: 1.4rem;
        padding: 0.6rem 0.8rem;
    }

    .blog-post-content h3 {
        font-size: 1.2rem;
    }

    .blog-post-content h4 {
        font-size: 1.05rem;
    }

    .share-button,
    .share-btn {
        flex: 1;
        min-width: auto;
    }

    .blog-share-buttons {
        flex-direction: column;
    }

    .blog-post-content ul,
    .blog-post-content ol {
        padding: 1rem 1rem 1rem 2rem;
    }
}