/* ===================================================================
   お知らせページ メインコンテンツ調整
   ===================================================================
   header-fix.cssでヘッダーを管理し、こちらではコンテンツの位置のみ調整します。
   =================================================================== */

/* ===================================================================
   これより下は既存のCSSです
   =================================================================== */

/* お知らせページタイトルの位置調整（色はカスタマイザーで制御） */
body:not(.home) .news__title,
body:not(.home) h1.news__title,
body:not(.home) h2.news__title,
body:not(.home) .page-title,
body:not(.home) .entry-title,
body:not(.home) h1.entry-title,
body:not(.home) h2.entry-title,
body:not(.home) h1,
body:not(.home) h2 {
    text-shadow: none !important;
    -webkit-text-stroke: 0 !important;
    background: transparent !important;
    background-color: transparent !important;
    margin-top: 15px !important;
    padding-top: 5px !important;
}

/* お知らせ一覧ページのタイトルを確実にヘッダー分下げる */
.news__title,
h1.news__title,
.news-archive .news__title,
.news-archive h1.news__title {
    margin-top: 70px !important;
    padding-top: 20px !important;
    /* カスタマイザーの色設定を有効にするため、強制的な色設定を削除 */
}

/* お知らせアーカイブページのメインコンテナを下げる - 絶対版 */
.news-archive,
main.news-archive,
html .news-archive,
html main.news-archive {
    padding-top: 70px !important;
    margin-top: 0 !important;
}

.news-archive .news__container,
main.news-archive .news__container,
html .news-archive .news__container,
html main.news-archive .news__container {
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* お知らせアーカイブページのグリッドを下げる */
.news-archive .news__grid,
main.news-archive .news__grid,
html .news-archive .news__grid,
html main.news-archive .news__grid {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* お知らせ個別記事ページ用CSS */

/* 個別ニュースページ全体のレイアウト */
.news-single {
    min-height: 100vh;
    padding: 60px 0 40px; /* 70px → 60px に修正 */
    margin-top: 0 !important;
}

.news-single .news__container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 記事全体 - 順序を確実に制御 */
.news__article {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin-bottom: 40px;
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    position: relative;
    display: flex !important;
    flex-direction: column !important;
}

.news__article::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(45deg, #667eea, #764ba2);
}

.news__article:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

/* 記事全体のレイアウト */
.news__article {
    display: block !important;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin-bottom: 40px;
    padding: 40px;
}

.news__meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    margin-top: 20px;
    font-size: 14px;
}

/* 日付スタイル - カスタマイザーで制御 */
.news__date {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    padding: 10px !important;
    border-radius: 10px !important;
    min-width: 60px !important;
}

.news__date-day {
    font-size: 1.5rem;
    font-weight: bold;
    line-height: 1;
}

.news__date-month {
    font-size: 0.8rem;
    text-transform: uppercase;
    margin-top: 2px;
}

/* カテゴリー - TOPページと同じ */
.news__category-tag {
    background: linear-gradient(45deg, #ffd700, #ffed4e);
    color: #333;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 3px 10px rgba(255, 215, 0, 0.3);
}

.news__title {
    font-size: 2.5em !important;
    font-weight: 700 !important;
    line-height: 1.3 !important;
    margin: 10px 0 40px 0 !important;
    text-align: center !important;
    position: relative !important;
    text-shadow: none !important;
    -webkit-text-stroke: 0 !important;
    background: transparent !important;
}

.news__title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 0;
    right: 0;
    margin: 0 auto;
    width: 100%;
    max-width: calc(100% - 40px);
    height: 3px;
    background: linear-gradient(90deg, #2e1b11, #4a2f1f, #2e1b11);
    border-radius: 2px;
}

/* アイキャッチ画像 */
.news__thumbnail {
    margin: 0;
    overflow: hidden;
    order: 1.5;
}

.news__thumbnail img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.news__thumbnail:hover img {
    transform: scale(1.02);
}

/* コンテンツ部分 - タイトルの下にきちんと表示 */
.news__content {
    padding: 0 !important;
    line-height: 1.8 !important;
    font-size: 18px !important;
    color: #2c3e50 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    margin-top: 0 !important;
}

/* コンテンツ内の要素スタイル */
.news__content h1,
.news__content h2,
.news__content h3,
.news__content h4,
.news__content h5,
.news__content h6 {
    margin-top: 2em;
    margin-bottom: 1em;
    font-weight: 600;
    line-height: 1.4;
    color: #333 !important;
}

.news__content h1 {
    font-size: 2em;
    border-bottom: 3px solid #ffd700;
    padding-bottom: 10px;
}

.news__content h2 {
    font-size: 1.7em;
    border-left: 4px solid #ffd700;
    padding-left: 15px;
}

.news__content h3 {
    font-size: 1.4em;
    color: #555;
}

.news__content h4 {
    font-size: 1.2em;
    color: #666;
}

.news__content p {
    margin-bottom: 1.5em;
    line-height: 1.8;
}

.news__content ul,
.news__content ol {
    margin: 1.5em 0;
    padding-left: 2em;
}

.news__content li {
    margin-bottom: 0.5em;
    line-height: 1.7;
}

.news__content blockquote {
    background: #f9f9f9;
    border-left: 4px solid #ffd700;
    margin: 2em 0;
    padding: 20px 30px;
    font-style: italic;
    border-radius: 0 8px 8px 0;
}

.news__content blockquote p {
    margin-bottom: 0;
}

.news__content code {
    background: #f4f4f4;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

.news__content pre {
    background: #f4f4f4;
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 1.5em 0;
}

.news__content pre code {
    background: none;
    padding: 0;
}

.news__content a {
    color: #2271b1;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.news__content a:hover {
    color: #135e96;
}

.news__content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5em 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.news__content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5em 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.news__content th,
.news__content td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.news__content th {
    background: #f8f9fa;
    font-weight: 600;
    color: #333;
}

.news__content tr:hover {
    background: #f9f9f9;
}

/* フッター部分 */
.news__footer {
    padding: 30px 40px 40px !important;
    background: rgba(255, 255, 255, 0.8) !important;
    border-top: 1px solid rgba(0, 0, 0, 0.1) !important;
    order: 4 !important;
}

/* 記事全体の順序を確実に制御 */
.news-single .news__article {
    display: flex !important;
    flex-direction: column !important;
}

.news-single .news__article .news__header {
    order: 1 !important;
}

.news-single .news__article .news__content {
    order: 2 !important;
}

.news-single .news__article .news__thumbnail {
    order: 3 !important;
}

.news-single .news__article .news__footer {
    order: 4 !important;
}

/* クリーンなレイアウト制御 */
.news-single .news__header {
    display: block !important;
}

.news-single .news__content {
    display: block !important;
}

/* ナビゲーション */
.news__navigation {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.news__prev,
.news__next {
    display: flex;
}

.news__next {
    justify-content: flex-end;
    text-align: right;
}

.news__nav-link {
    display: block;
    padding: 15px 20px;
    background: #ffffff;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    max-width: 300px;
}

.news__nav-link:hover {
    background: #ffd700;
    border-color: #ffd700;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.news__nav-label {
    display: block;
    font-size: 12px;
    color: #666;
    margin-bottom: 5px;
    font-weight: 500;
}

.news__nav-title {
    display: block;
    font-weight: 600;
    line-height: 1.4;
}

/* 戻るリンク */
.news__back {
    text-align: center;
    background: none !important;
    background-color: transparent !important;
    padding: 20px !important;
    margin: 20px 0 !important;
}

.news__back-link {
    display: inline-block !important;
    padding: 12px 30px !important;
    color: #FFFFFF !important;
    text-decoration: none !important;
    border-radius: 25px !important;
    font-weight: 500 !important;
    transition: all 0.3s ease !important;
    box-shadow: none !important;
    border: none !important;
    outline: none !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* カスタマイザーの背景色設定を有効にするため、強制背景設定を削除 */

/* カスタマイザーの背景設定を有効にするため、強制的な背景設定を削除 */

/* カスタマイザーの背景設定を有効にするため、強制背景設定を削除 */

/* ボタンはカスタマイザーで制御される */

.news__back-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

/* レスポンシブ対応 */
@media screen and (max-width: 768px) {
    .news-single {
        padding: 40px 0 20px;
    }
    
    .news-single .news__container {
        padding: 0 15px;
    }
    
    .news__header {
        padding: 30px 20px 15px;
    }
    
    .news__title {
        font-size: 1.8em;
        color: #2e1b11 !important;
        text-shadow: none !important;
    }
    
    .news__content {
        padding: 30px 20px;
        font-size: 15px;
        color: #333;
    }
    
    .news__content h1 {
        font-size: 1.6em;
        color: #333;
    }
    
    .news__content h2 {
        font-size: 1.4em;
        color: #333;
    }
    
    .news__content h3 {
        font-size: 1.2em;
        color: #333;
    }
    
    .news__footer {
        padding: 20px 20px 30px;
    }
    
    .news__navigation {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .news__next {
        justify-content: flex-start;
        text-align: left;
    }
    
    .news__nav-link {
        max-width: none;
    }
}

@media screen and (max-width: 480px) {
    .news__title {
        font-size: 1.5em;
        color: #2e1b11 !important;
        text-shadow: none !important;
    }
    
    .news__content {
        padding: 20px 15px;
        font-size: 14px;
        color: #333;
    }
    
    .news__meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .news__content table {
        font-size: 13px;
    }
    
    .news__content th,
    .news__content td {
        padding: 8px 10px;
    }
}

/* 印刷用スタイル */
@media print {
    .news-single {
        background: none;
        padding: 0;
    }
    
    .news__article {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .news__navigation,
    .news__back {
        display: none;
    }
    
    .news__content a {
        color: #333;
        text-decoration: none;
    }
    
    .news__content a:after {
        content: " (" attr(href) ")";
        font-size: 0.8em;
        color: #666;
    }
} 

/* 日付の背景色を薄いピンクに変更 */
.news-single .news-date {
    background-color: #f8d3e5 !important;
    color: #333 !important;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    display: inline-block;
    margin-bottom: 8px;
}

/* 投稿内容の順序修正 */
.news-single .news-content {
    display: flex !important;
    flex-direction: column !important;
}

.news-single .news-content .news-title {
    order: 1 !important;
    margin-bottom: 10px !important;
    color: #333 !important;
    font-size: 24px !important;
    font-weight: bold !important;
}

.news-single .news-content .news-body,
.news-single .news-content .news-text,
.news-single .news-content .entry-content,
.news-single .news-content p,
.news-single .news-content div {
    order: 2 !important;
    color: #555 !important;
    line-height: 1.6 !important;
    margin-bottom: 10px !important;
}

/* タイトルを確実に上に表示 */
.news-single h1.news-title,
.news-single h2.news-title {
    order: 1 !important;
    color: #333 !important;
    font-size: 24px !important;
    font-weight: bold !important;
    margin-bottom: 15px !important;
}

/* 内容を確実に下に表示 */
.news-single .post-content,
.news-single .entry-content {
    order: 2 !important;
    color: #555 !important;
    line-height: 1.6 !important;
} 