﻿@charset "utf-8";

/* =================================================
    1. Base & Reset
================================================= */
:root {
    --primary-color: #1785e5;
    --text-main: #2c3e50;
    --text-sub: #7f8c8d;
    --bg-color: #f8f9fa;
    --card-bg: #ffffff;
    --border-color: #e0e0e0;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    line-height: 1.8;
    color: var(--text-main);
    background-color: var(--bg-color);
    -webkit-font-smoothing: antialiased;
}

a { color: var(--primary-color); text-decoration: none; transition: 0.3s; }
a:hover { color: #0056b3; text-decoration: underline; }

/* =================================================
    2. Layout
================================================= */
.container { max-width: 1320px; margin: 0 auto; padding: 0 40px; }

.main-layout { display: flex; gap: 40px; margin: 40px auto 60px; }

.content-area { flex: 1; min-width: 0; }

.sidebar { width: 260px; flex-shrink: 0; }

@media (max-width: 850px) {
    .main-layout { flex-direction: column; }
    .sidebar { width: 100%; }
}

/* =================================================
    3. Header & Footer
================================================= */
.site-header {
    background-color: #fff;
    padding: 50px 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.site-header h1 { font-size: 2.2rem; font-weight: 800; margin-bottom: 5px; }
.site-name a { color: var(--text-sub); font-size: 0.9rem; font-weight: 500; }

.site-footer {
    background: #fff; padding: 60px 0; text-align: center;
    font-size: 0.85rem; color: #888; border-top: 1px solid var(--border-color);
}

/* =================================================
    4. Common Article Card (TOP & Content 共通)
================================================= */
.article-card, .entry-card {
    background: var(--card-bg);
    padding: 50px 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    border: 1px solid var(--border-color);
}

/* コンテンツ詳細の装飾 */

/* H1: タイトル — 下線＋背景グラデーションで格調高く */
.entry-header h1 {
    font-size: 2.2rem;
    color: #111;
    line-height: 1.4;
    margin-bottom: 30px;
    font-weight: 800;
    padding: 20px 30px 20px 20px;
    background: linear-gradient(135deg, #f0f6ff 0%, #ffffff 60%);
    border-left: 6px solid var(--primary-color);
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(23, 133, 229, 0.08);
}

/* H2: セクション見出し — 帯＋アイコン風アクセントで目立たせる */
.entry-section h2 {
    position: relative;
    font-size: 1.45rem;
    margin: 50px 0 20px;
    padding: 14px 20px 14px 52px;
    background: #fff;
    border: 2px solid var(--primary-color);
    border-radius: 6px;
    font-weight: 700;
    color: var(--primary-color);
    box-shadow: 4px 4px 0px rgba(23, 133, 229, 0.12);
}
.entry-section h2::before {
    content: "◆";
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.9rem;
    color: var(--primary-color);
    opacity: 0.6;
}

/* H3: 小見出し — シンプルな下線スタイルで H2 より軽く */
.entry-section h3 {
    font-size: 1.2rem;
    margin: 35px 0 15px;
    padding-bottom: 8px;
    font-weight: 700;
    color: var(--text-main);
    border-bottom: 2px dashed var(--border-color);
}

/* H4: 最小単位 — テキストカラーを落として控えめに */
.entry-section h4 {
    font-size: 1.05rem;
    margin: 25px 0 10px;
    font-weight: 700;
    color: var(--text-sub);
    padding-left: 12px;
    border-left: 3px solid var(--border-color);
}

.entry-body p, .entry-section p { font-size: 1.1rem; line-height: 2.1; margin-bottom: 1.8em; }

/* =================================================
    5. List Designs (TOPの記事リスト & サイドバー)
================================================= */
/* リスト共通設定 */
.entry-list, .link-list { list-style: none; padding: 0; }

/* TOPページ用のリッチなリスト */
.entry-item {
    display: block; padding: 20px 0; border-bottom: 1px solid #f0f0f0;
    text-decoration: none; transition: 0.3s;
}
.entry-item:last-child { border-bottom: none; }
.entry-item:hover { transform: translateX(5px); }
.entry-date { display: block; font-size: 0.85rem; color: var(--text-sub); font-weight: 700; margin-bottom: 5px; }
.entry-title { display: block; font-size: 1.15rem; font-weight: 700; color: var(--text-main); }

/* サイドバー用のシンプルなリスト */
.sidebar-widget {
    background: var(--card-bg); padding: 25px; border-radius: 12px;
    margin-bottom: 30px; border: 1px solid var(--border-color);
}
.sidebar-widget h3 { font-size: 1.1rem; margin-bottom: 20px; font-weight: 700; border-left: 4px solid var(--text-main); padding-left: 12px; }

.link-list li { padding: 10px 0; border-bottom: 1px dashed #eee; }
.link-list li:last-child { border-bottom: none; }
.link-list a { font-size: 0.95rem; color: var(--text-main); font-weight: 500; }
.link-list a:hover { color: var(--primary-color); }

/* 戻るボタン */
.back-link {
    display: inline-block; margin-top: 30px; padding: 12px 25px;
    background: #f0f0f0; border-radius: 50px; font-size: 0.9rem; color: #666;
}
.back-link:hover { background: var(--primary-color); color: #fff; text-decoration: none; }


/* =================================================
    6. Responsive Font Sizes (PC / Tablet / Smartphone)
================================================= */

/* --- 1. タブレットサイズ (画面幅 1024px 以下) --- */
@media (max-width: 1024px) {
    .entry-header h1 {
        font-size: 1.8rem;
        padding: 18px 24px;
        margin-bottom: 25px;
    }
    .entry-section h2 {
        font-size: 1.35rem;
        padding: 12px 18px 12px 48px;
        margin: 40px 0 18px;
    }
    .entry-section h2::before {
        left: 16px;
    }
    .entry-section h3 {
        font-size: 1.15rem;
        margin: 30px 0 12px;
    }
    .entry-section h4 {
        font-size: 1.02rem;
        margin: 22px 0 8px;
    }
}
/* --- 2. スマートフォンサイズ (画面幅 600px 以下) --- */
@media (max-width: 600px) {
    /* 【追加】全体の左右の余白を狭めて画面を広く使う */
    .container {
        padding: 0 15px;
    }
    
    /* 【追加】メインレイアウトの上下余白もスマホ向けに調整 */
    .main-layout {
        margin: 20px auto 40px;
    }

    /* H1: タイトル（影と余白をスマートに） */
    .entry-header h1 {
        font-size: 1.15rem;
        padding: 12px 16px;
        margin-bottom: 15px;
        box-shadow: 0 1px 4px rgba(23, 133, 229, 0.06); /* 影を薄く浅く */
        border-left-width: 4px;                        /* 左線を4pxに細く */
    }

    /* H2: セクション見出し（枠をギリギリまで細く狭く） */
    .entry-section h2 {
        font-size: 1.1rem;
        padding: 6px 10px 6px 28px;                  /* 上下6px、左右10px（左は◆があるため28px）までスリム化 */
        margin: 22px 0 10px;
        border-width: 1px;
        box-shadow: 2px 2px 0px rgba(23, 133, 229, 0.12);
        border-radius: 4px;
    }
    .entry-section h2::before {
        left: 10px;                                  /* 枠が狭まった分、◆の位置も左に寄せました */
        font-size: 0.75rem;
    }

    /* H3: 小見出し */
    .entry-section h3 {
        font-size: 0.9rem;
        margin: 18px 0 8px;
        padding-bottom: 4px;                         /* 下線との隙間を狭く */
        border-bottom-width: 1px;
    }

    /* H4: 最小単位 */
    .entry-section h4 {
        font-size: 0.8rem;
        margin: 14px 0 6px;
        padding-left: 6px;                           /* 左線との隙間を狭く */
        border-left-width: 2px;
    }

    /* 記事を囲む大元のカード（左右の余白をさらに削ってコンテンツを最大化） */
    .article-card, .entry-card {
        padding: 25px 10px;                          /* 横の余白を15pxから10pxに変更 */
    }
}