/*
 Theme Name: Nephilim
 Theme URI: https://example.com/nephilim
 Author: （あなたの名前）
 Author URI: https://example.com
 Description: フルスクラッチで構築する WordPress テーマ「Nephilim」。
 Version: 1.0.0
 License: GNU General Public License v2 or later
 License URI: https://www.gnu.org/licenses/gpl-2.0.html
 Text Domain: nephilim
 Tags: custom-theme, full-scratch, blog, minimal, responsive
*/

/* =========================================
   ホーム（投稿一覧）カードレイアウト
   ====================================== */


/* 記事本文の見出しデザイン */
.nephilim-single-content h2 {
    margin-top: 32px;
    margin-bottom: 12px;
    padding: 8px 12px;
    border-left: 4px solid rgba(139, 69, 19, 0.6); /* 木目系ブラウン */
    background-color: rgba(255, 255, 255, 0.75);
    border-radius: 6px;
    font-size: 1.3rem;
    font-weight: 700;
}

.nephilim-single-content h3 {
    margin-top: 24px;
    margin-bottom: 8px;
    padding-bottom: 4px;
    border-bottom: 2px solid rgba(139, 69, 19, 0.35);
    font-size: 1.1rem;
    font-weight: 600;
}

.nephilim-single {
    max-width: 1400px;
    margin: 40px auto;
    padding: 24px 20px;
    border-radius: 10px;
    background-color: rgba(255, 255, 255, 0.65);
    box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}

.nephilim-single-header {
    margin-bottom: 16px;
}

/* 記事タイトルの背景装飾 */
.nephilim-single-title {
    background: rgba(255, 255, 255, 0.6); /* 半透明の白で抜け感 */
    padding: 12px 18px;
    border-left: 5px solid rgba(139, 69, 19, 0.35); /* 木の色を少しアクセントに */
    border-radius: 6px;
    font-size: 1.8rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 16px;
}

.nephilim-single-meta {
    font-size: 0.9rem;
    color: #666;
}

/* サムネ（通常表示） */
.nephilim-single-thumb {
    margin: 16px 0 24px;
}

.nephilim-single-thumb img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}

.nephilim-single-content {
    font-size: 1rem;
    line-height: 1.8;
}

.nephilim-single-footer {
    margin-top: 24px;
    border-top: 1px solid rgba(0,0,0,0.1);
    padding-top: 16px;
}

.nephilim-single-tags {
    margin-bottom: 12px;
    font-size: 0.9rem;
}

/* 前後記事ナビ（ベース：後段でカード化の定義あり） */
.nephilim-single-nav {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.95rem;
}

/* タイトル下のバッジエリア */
.nephilim-single-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 8px 0 16px;
}

/* 共通バッジスタイル（ボタン風） */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px; /* pill型 */
    font-size: 0.8rem;
    text-decoration: none;
    border: 1px solid rgba(0,0,0,0.08);
    box-shadow: 0 1px 2px rgba(0,0,0,0.08);
    transition: background-color 0.15s ease, transform 0.1s ease;
}

/* リンクも文字色を継承 */
.badge:link,
.badge:visited {
    color: inherit;
}

/* ホバー時の軽い浮き上がり */
.badge:hover {
    transform: translateY(-1px);
}

/* 投稿タイプバッジ */
.badge-type {
    background-color: rgba(139, 69, 19, 0.12); /* 落ち着いたブラウン系 */
    color: #5b3410;
    font-weight: 600;
}

/* カテゴリバッジ */
.badge-cat {
    background-color: rgba(46, 139, 87, 0.10); /* グリーン寄り */
    color: #2e6b45;
}

/* タグバッジ */
.badge-tag {
    background-color: rgba(0, 0, 0, 0.04); /* グレー系 */
    color: #555;
}

/* 前後記事ナビ全体（カード化の本体定義） */
.nephilim-single-nav {
    display: flex;
    gap: 16px;
    margin-top: 20px;
    flex-wrap: wrap;
}

/* 前後共通カード */
.nav-card {
    flex: 1 1 0;
    min-width: 260px;
    text-decoration: none;
    color: inherit;

    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    padding: 10px 12px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.3);

    display: flex;
    flex-direction: column;
    gap: 6px;

    transition: transform 0.12s ease, box-shadow 0.12s ease;
}

/* ラベル（← 前 / 次 →） */
.nav-card-label {
    font-size: 0.8rem;
    color: #666;
}

/* 内側レイアウト：サムネ＋テキスト横並び */
.nav-card-inner {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* サムネ */
.nav-card-thumb img {
    display: block;
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
}

/* テキスト部 */
.nav-card-text {
    flex: 1;
}

.nav-card-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.nav-card-date {
    font-size: 0.8rem;
    color: #777;
}

/* ホバー時 */
.nav-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 3px 8px rgba(0,0,0,0.18);
}

/* スマホでは縦並びに */
@media (max-width: 768px) {
    .nephilim-single-nav {
        flex-direction: column;
    }
}


/* コメント欄 */

/* コメントフォームのカード化 */
.comment-respond {
    background-color: rgba(255, 255, 255, 0.80);
    padding: 20px 24px;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
    margin-top: 24px;
}

/* コメントリスト（投稿済コメント）のカード風デザイン */
.comment-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.comment-list li {
    background-color: rgba(255, 255, 255, 0.80);
    padding: 16px 20px;
    border-radius: 10px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 16px;
}

/* コメントフォームの入力エリア */
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid rgba(0,0,0,0.2);
    border-radius: 6px;
    margin-bottom: 12px;
    background-color: rgba(255,255,255,0.95);
}

/* コメント送信ボタン（デザイン変更） */
.comment-form .submit {
    display: inline-block;
    padding: 10px 22px;
    border: none;
    border-radius: 999px; /* pill型ボタン */
    background: linear-gradient(135deg, #8b4513, #a35a21);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0,0,0,0.18);
    transition: transform 0.1s ease, box-shadow 0.1s ease, opacity 0.15s ease;
}

/* ホバー・フォーカス時 */
.comment-form .submit:hover,
.comment-form .submit:focus {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0,0,0,0.24);
    opacity: 0.95;
}

/* クリック中 */
.comment-form .submit:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(0,0,0,0.18);
    opacity: 0.9;
}


/* 記事末尾：HOME帰還リンク */
.nephilim-home-back {
    margin: 72px auto 0;
    text-align: center;
}

.nephilim-home-link {
    display: inline-block;
    opacity: 0.85;
    transition: opacity 0.3s ease;
}

.nephilim-home-link:hover {
    opacity: 1;
}

.nephilim-home-image {
    width: 240px;
    height: auto;
}

/*topスクロール*/

.nephilim-to-top{
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease;
}

.nephilim-to-top.is-visible{
  opacity: 1;
  pointer-events: auto;
}


/* ==============================
   記事冒頭アイキャッチ（帯）＋白ベール
   ============================== */

/* タイトル下の余白（既存方針を維持） */
.single .entry-title {
    margin-bottom: 0.4em;
}

/* サムネ用ラッパ（帯に固定して安定化） */
.single .nephilim-single-thumb {
    position: relative;
    width: 100%;
    height: 3.2em;      /* 画像帯の高さ（タイトル相当） */
    overflow: hidden;   /* 見切れOKをここで確定 */
}

/* アイキャッチ画像本体（帯にフィット） */
.single .nephilim-single-thumb img.wp-post-image {
    width: 100%;
    height: 100%;
    object-fit: cover;  /* 見切れOK */
    display: block;
    max-width: none;
    margin-top: 0;
}

/* 白い半透明ベール（画像の上だけ） */
.single .nephilim-single-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.45);
    pointer-events: none;
}


/* スマホ調整 */
@media (max-width: 600px) {
    .nephilim-home-image {
        width: 180px;
    }
}
