/* =========================================
   ベース設定
========================================= */
body {
    margin: 0;
    padding: 0;
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    color: #333;
    background-color: #fdfdfd;
}

* {
    box-sizing: border-box;
}

a {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: #007bff;
}

/* =========================================
   コラム一覧 (index.php)
========================================= */
.column-list-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
}

.column-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.column-thumb {
    width: 240px;
    flex-shrink: 0;
    background: #f0f0f0;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 16/9;
    display: flex;
    align-items: center;
    justify-content: center;
}

.column-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.column-meta {
    display: flex;
    gap: 10px;
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 8px;
}

.column-cat {
    background: #007bff;
    color: #fff;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: bold;
}

.column-title {
    font-size: 1.25rem;
    margin: 0 0 10px 0;
}

.column-desc {
    font-size: 0.95rem;
    color: #555;
    line-height: 1.6;
}

/* =========================================
   コラム詳細 (view.php)
========================================= */
.single-container {
    max-width: 760px;
    margin: 0 auto;
    padding: 40px 20px;
}

.single-header {
    margin-bottom: 30px;
    text-align: center;
}

.single-meta {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 15px;
    display: flex;
    justify-content: center;
    gap: 15px;
    align-items: center;
}

.single-cat {
    background: #007bff;
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-weight: bold;
}

.single-title {
    font-size: 2rem;
    margin: 0 0 20px 0;
    line-height: 1.4;
    color: #222;
}

.single-thumb {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 40px;
}

.single-content {
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333;
}

.single-content p {
    margin-bottom: 1.5em;
}

.single-content h2 {
    margin: 2em 0 1em;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
    font-size: 1.5rem;
}

.single-content h3 {
    margin: 1.5em 0 1em;
    font-size: 1.25rem;
}

.single-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 1em 0;
}

.single-content ul,
.single-content ol {
    margin-bottom: 1.5em;
    padding-left: 1.5em;
}

.back-btn {
    display: inline-block;
    padding: 10px 20px;
    background: #eee;
    color: #333;
    border-radius: 4px;
    transition: 0.2s;
}

.back-btn:hover {
    background: #ddd;
}

/* 前後記事ナビゲーション */
.post-nav {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 50px;
    margin-bottom: 30px;
    padding-top: 30px;
    border-top: 1px solid #eee;
}

.post-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.post-nav-prev {
    text-align: left;
}

.post-nav-next {
    text-align: right;
}

.post-nav-label {
    font-size: 0.85rem;
    color: #777;
    margin-bottom: 5px;
}

.post-nav-title {
    font-size: 1rem;
    font-weight: bold;
    color: #007bff;
}

.post-nav-title:hover {
    text-decoration: underline;
}

/* =========================================
   レスポンシブ対応 (スマホ向け)
========================================= */
@media (max-width: 600px) {
    .column-item {
        flex-direction: column;
    }

    .column-thumb {
        width: 100%;
        aspect-ratio: 16/9;
    }

    .post-nav {
        flex-direction: column;
        gap: 20px;
    }

    .post-nav-prev,
    .post-nav-next {
        text-align: center;
    }
}

/* コラム本文内のソース（citeタグ）の共通スタイル */
.single-content cite {
    display: block;
    font-style: normal;
    /* 斜体を解除して読みやすく */
    font-size: 0.85rem;
    /* 本文より一回り小さく */
    color: #666666;
    /* 控えめなグレー */
    margin-top: 15px;
    /* 上に少し余白を作る */
    margin-bottom: 15px;
    /* 下に少し余白を作る */
    padding-left: 8px;
    /* 左側に少し隙間を空ける */
    border-left: 2px solid #ccc;
    /* 補足情報だと分かりやすいよう左側に縦線を引く */
}

/* ソース内のリンク文字 */
.single-content cite a {
    color: #0066cc;
    /* 一般的なリンクの青色 */
    text-decoration: underline;
    /* 下線をつけてリンクと分かりやすく */
}

/* リンクホバー時 */
.single-content cite a:hover {
    color: #0033aa;
    /* ホバー時に少し濃い青に */
    text-decoration: none;
    /* ホバー時に下線を消す */
}