@charset "UTF-8";

/* ==============================================
   ニュース一覧・詳細ページ用スタイル (news.css)
   ============================================== */

/* 共通設定（全体の幅や余白） */
.news-page-main {
    max-width: 800px;
    margin: 120px auto 60px; /* ヘッダー分（120px）下げて中央寄せ */
    padding: 0 20px;
}

/* ==============================================
   ニュース一覧画面 (home.php)
   ============================================== */
.news-list-page .section-header {
    text-align: center;
    margin-bottom: 60px;
}

.news-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.news-item {
    border-bottom: 1px solid #ddd;
    padding: 24px 0;
}

/* 日付とタグの並び */
.news-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 10px;
    flex-wrap: wrap; /* スマホなどで画面が狭い時に折り返す */
}

.news-date {
    color: #666;
    font-size: 0.95rem;
}

.news-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.news-tag {
    display: inline-block;
    background-color: #3a4149;
    color: #fff;
    font-size: 0.8rem;
    padding: 6px 16px;
    border-radius: 20px;
    line-height: 1.2;
}

.news-title {
    margin: 0;
    font-size: 1.3rem;
    line-height: 1.5;
}

.news-title a,
.news-title a:visited {
    text-decoration: none;
    color: #333;
    transition: color 0.3s;
}

.news-title a:hover {
    color: #008080; /* tobosoのテーマカラーに合わせて色を変更 */
}

/* ページネーション（次へ・前へ） */
.pagination {
    margin-top: 50px;
    text-align: center;
}

.pagination .nav-links {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.pagination a, .pagination span {
    display: inline-block;
    padding: 10px 18px;
    background-color: #f7f7f7;
    color: #333;
    text-decoration: none;
    border-radius: 8px;
    transition: background-color 0.3s;
}

.pagination a:hover {
    background-color: #ddd;
}

.pagination .current {
    background-color: #3a4149;
    color: #fff;
}

/* ==============================================
   ニュース詳細画面 (single.php)
   ============================================== */
.news-detail-container .entry-header {
    margin-bottom: 40px;
    border-bottom: 2px solid #eee;
    padding-bottom: 25px;
}

.news-detail-container .entry-title {
    margin: 0;
    font-size: 1.8rem;
    line-height: 1.5;
    color: #333;
}

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

.entry-content p {
    margin-bottom: 1.8em;
}

/* ニュース一覧に戻るボタン */
.back-to-list {
    margin-top: 80px;
    text-align: center;
}

.btn-back,
.btn-back:visited {
    display: inline-block;
    padding: 18px 50px;
    background-color: #fff;
    color: #3a4149;
    text-decoration: none;
    border-radius: 30px;
    font-weight: bold;
    border: 2px solid #3a4149;
    transition: all 0.3s;
}

.btn-back:hover {
    background-color: #3a4149;
    color: #fff;
}

/* ==============================================
   スマホ対応
   ============================================== */
@media screen and (max-width: 768px) {
    .news-page-main {
        margin-top: 80px; /* スマホは少し余白を狭く */
    }
    .news-title {
        font-size: 1.1rem;
    }
    .news-detail-container .entry-title {
        font-size: 1.5rem;
    }
}