/*!
Theme Name: halfmoon-f
Theme URI: https://halfmoon-f.com/
Author: halfmoon.com
Author URI: https://halfmoon-f.com/
*/

/*!
 * WordPress Normalize CSS
 * Based on normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css
 * Enhanced for WordPress
 */

/* ==========================
 * 基本リセット
 * ========================== */
html {
    line-height: 1.15;
    -webkit-text-size-adjust: 100%;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

*, *::before, *::after {
    box-sizing: inherit;
    margin: 0;
    padding: 0;
}

/* ==========================
 * WordPress デフォルトタグの調整
 * ========================== */
body {
    margin: 0;
	font-family: "游ゴシック体", "Yu Gothic", YuGothic, "ヒラギノ角ゴ Pro", "Hiragino Kaku Gothic Pro", "メイリオ", "Meiryo", sans-serif;	
    font-size: 0.9rem;
    line-height: 1.6;
    color: #333;
    background: rgba(244, 244, 242, 1) !important;
    font-weight: 400;
    font-style: normal;
    letter-spacing: 0.1em;
}

main {
    display: block;
}

/* ==========================
 * リンクのスタイル
 * ========================== */
a {
    background-color: transparent;
    color: #333 !important;
    text-decoration: none !important;
}

a:hover,
a:focus {
    color: #333 !important;
    /*text-decoration: underline;*/
	text-decoration:none !important;
}

/* コンテンツ内のリンク */
#content a {
    background-color: transparent;
    color: #333 !important;
}

#content a:hover,
#content a:focus {
    color: #666 !important;
    text-decoration: none;
}

#content .entry-category a.category-link {
    text-decoration: none !important; /* デフォルトの下線を削除 */
}

/* ==========================
 * ヘッディング共通設定
 * ========================== */
h1 {
	font-family: 'Noto Sans JP', sans-serif;
    font-optical-sizing: auto;
    margin-bottom: 2em !important;
    font-size: 1.8rem;
    letter-spacing: 0.2rem;
}

/* シングル記事・エントリータイトル */
.single h1, 
h2.entry-title {
	font-family: 'Noto Sans JP', sans-serif;
    font-size: 1.6rem;
    line-height: 1.5;
}

/* h2 のスタイル */
h2 {
	font-family: 'Noto Sans JP', sans-serif;
    font-optical-sizing: auto;
    margin-bottom: 2em !important;
    font-size: 1.4rem !important;
    letter-spacing: 0.2rem;
}

/* h3 ～ h6 のスタイル */
h3, h4, h5, h6 {
	font-family: 'Noto Sans JP', sans-serif;
    font-optical-sizing: auto;
    margin-bottom: 2em !important;
    font-size: 1.2rem;
    letter-spacing: 0.2rem;
}

/* ==========================
 * スマホ向けスタイル（576px以下）
 * ========================== */
@media (max-width: 575.98px) {
    h1 {
        font-size: 1.4rem;
    }

    h2 {
        font-size: 1rem !important;
        letter-spacing: 0.1rem;
    }

    h3, h4, h5, h6 {
        font-size: 1.1rem;
        letter-spacing: 0.1rem !important;
    }
}


/* ==========================
 * コンテンツの段落
 * ========================== */
#content p {
	font-family: 'Noto Sans JP', sans-serif;
    line-height: 2em !important;
    margin-bottom: 2em;
}

/* ==========================
 * 選択時のスタイル
 * ========================== */
::selection {
    background-color: #333;
    color: #fff;
}

::-moz-selection {
    background-color: #333;
    color: #fff;
}

/* ==========================
 * 画像
 * ========================== */
#content img {
    width: 100%; /* 親要素いっぱいに広がる */
    max-width: 100%;
    height: auto;
    display: block;
    margin-bottom: 1em;
}

.wp-block-image {
    position: relative;
    display: block; /* inline-block を block に変更し、幅いっぱいに */
    width: 100%; /* 画像を含む .wp-block-image も幅いっぱいに */
}

.wp-block-image img {
    width: 100%; /* 画像を常に幅いっぱいに */
}

figcaption.wp-element-caption {
    position: absolute;
    right: 0;
    bottom: -10px;
    text-align: right;
}

/* ==========================
 * リスト
 * ========================== */
ul, ol {
    margin: 0 0 1rem 1.5rem;
}

li > ul,
li > ol {
    margin-left: 1rem;
}

/* ==========================
 * テーブル
 * ========================== */
table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 0.5rem;
    border: 1px solid #ddd;
}

thead th {
    background: #f4f4f4;
}

/* ==========================
 * 記事のデザイン
 * ========================== */
.archive article,
.single article {
    margin-bottom: 4em !important;
    padding-bottom: 2em;
    border-bottom: 1px solid #d9d9d6;
}

.masonry-grid article {
    margin-bottom: 0 !important;
    padding-bottom: 0;
    border-bottom: none;
}

/* スマホ（576px～） */
@media (max-width: 575.98px) {
.masonry-grid article {
    margin-bottom: 10px !important;
    padding-bottom: 10px;
    border-bottom: none;
}
}

.post-type-archive-works article,
.tax-works_category article {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
    border-bottom: none;
}

/* ==========================
 * WordPress 固有のスタイル調整
 * ========================== */

/* ブロックエディタ (Gutenberg) 用 */
.wp-block {
    max-width: 100%;
}

/* ブロックの全幅指定 */
.w90 {
    width: 90%;
    max-width: 1300px;
    margin: 0 auto; /* 左右中央配置 */
}

@media (max-width: 575.98px) {
    .w90 {
        width: 100%;
    }
}

.w80 {
    width: 80%;
    max-width: 1000px;
    margin: 0 auto; /* 左右中央配置 */
}

@media (max-width: 575.98px) {
    .w80 {
        width: 100%;
    }
}

.w70 {
    width: 70%;
    max-width: 900px;
    margin: 0 auto; /* 左右中央配置 */
}

@media (max-width: 575.98px) {
    .w70 {
        width: 100%;
    }
}

.w60 {
    width: 60%;
    max-width: 800px;
    margin: 0 auto; /* 左右中央配置 */
}

@media (max-width: 575.98px) {
    .w60 {
        width: 100%;
    }
}

/* 画像ブロックにも幅指定 */

.w90 img {
    width: 90%;
    max-width: 1100px;
}

.w80 img {
    width: 80%;
    max-width: 1000px;
}

.w70 img {
    width: 70%;
    max-width: 900px;
}

.w60 img {
    width: 60%;
    max-width: 800px;
}

@media (max-width: 575.98px) {
    .w90 img, .w80 img, .w70 img, .w60 img {
        width: 100%;
    }
}

/* ==========================
 * 画像配置
 * ========================== */
.alignleft {
    float: left;
    margin-right: 1rem;
}

.alignright {
    float: right;
    margin-left: 1rem;
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* キャプション付き画像 */
.wp-caption {
    max-width: 100%;
    text-align: center;
    font-size: 0.9rem;
    color: #666;
}

/* ==========================
 * ボタン
 * ========================== */
button,
input[type="button"],
input[type="submit"],
.button {
    border: none;
    padding: 0.6rem 1.2rem;
    font-size: 1rem;
    cursor: pointer;
    background: #0073aa;
    color: #fff;
    border-radius: 3px;
    transition: background 0.2s ease-in-out;
}

button:hover,
input[type="button"]:hover,
input[type="submit"]:hover,
.button:hover {
    background: #005177;
}

/* ==========================
 * フォーム
 * ========================== */
input,
textarea,
select {
    font-size: 1rem;
    border: 1px solid #ccc;
    padding: 0.5rem;
    width: 100%;
}

/* WordPressのコメントフォーム */
.comment-form input,
.comment-form textarea {
    width: 100%;
    padding: 0.75rem;
    border-radius: 4px;
}

/* ==========================
 * 投稿メタ情報
 * ========================== */
.post-meta-archive {
    font-size: 0.9rem !important;
}

/* ==========================
 * 投稿ナビゲーション
 * ========================== */
.post-navigation {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.nav-previous a,
.nav-next a {
    display: inline-block;
    padding: 0 12px;
}

/* ==========================
 * Bootstrap 固有のスタイル調整
 * ========================== */

/* デフォルトの .container を上書きして自由な幅を設定 */
.container {
    max-width: 630px; /* 任意のサイズに変更 */
    width: 90%; /* 必要に応じて調整 */
}

/* ==========================
 * 画面幅ごとのサイズ調整
 * ========================== */

/* スマホ（～576px） */
@media (max-width: 575.98px) {
    .container {
        max-width: 600px; /* 例: 小さい画面 */
    }
    .container-fluid {
        width: 100%; /* 必要に応じて調整 */
    }
}

/* タブレット（～768px） */
@media (max-width: 767.98px) {
    .container {
        max-width: 630px;
    }
    .container-fluid {
        width: 90%;
    }
}

/* 小型PC・ノートPC（～992px） */
@media (max-width: 991.98px) {
    .container {
        max-width: 630px;
    }
    .container-fluid {
        width: 90%;
    }
}

/* 大画面（～1200px） */
@media (max-width: 1199.98px) {
    .container {
        max-width: 630px;
    }
    .container-fluid {
        width: 90%;
    }
}

/* 最大画面（1200px～） */
@media (min-width: 1199.98px) {
    .container {
        max-width: 630px; /* さらに大きな画面 */
    }
    .container-fluid {
        width: 90%;
    }
}

/* ==========================
 * 固定サイドバー
 * ========================== */
.fixed-sidebar {
    position: sticky;
    top: 140px; /* 上からの距離（調整可） */
    height: fit-content; /* 必要に応じて高さを制限 */
}


/* ==========================
 * アクセシビリティ対応
 * ========================== */

/* スクリーンリーダー専用のテキスト */
.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.screen-reader-text:focus {
    position: static;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0;
    clip: auto;
}

/* ==========================
 * 固定ヘッダー
 * ========================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 90px;
    background: rgba(244, 244, 242, 0.9) !important;
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 15px 0;
    transition: background 0.3s ease-in-out, transform 0.3s ease-in-out;
}

/* スクロール時のヘッダー変化 */
.site-header.scrolled {
    background: rgba(0, 0, 0, 0.85);
    transform: translateY(0);
}

/* ==========================
 * コンテンツレイアウト
 * ========================== */
#content {
    padding-top: 110px;
}

/* スマホ（～576px） */
@media (max-width: 575.98px) {
#content {
    padding-top: 120px !important;
}
}

/* ==========================
 * ナビゲーションメニュー
 * ========================== */
.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.nav-menu li {
    position: relative;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
	font-family: 'Noto Sans JP', sans-serif;
    font-optical-sizing: auto !important;
    font-weight: 400 !important;
    font-style: normal !important;
    letter-spacing: 0.08em;
}

.nav-menu a {
    display: block;
    color: #333;
    text-decoration: none;
    padding: 10px 15px;
    background-color: transparent;
    box-sizing: border-box;
    transition: background 0.2s ease-in-out;
    border-radius: 0;
    margin: 0;
}

/* 親メニューのホバー時 */
.nav-menu a:hover {
    background-color: #fff;
    border-radius: 0;
    margin: 0;
    padding: 10px 15px;
}

/* ==========================
 * サブメニュー
 * ========================== */
.sub-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    position: absolute;
    top: 100%;
    left: 0;
    background: #444;
    min-width: 180px;
    display: none;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.2);
    border-radius: 0;
}

.sub-menu li {
    width: 100%;
    box-sizing: border-box;
    margin: 0;
}

.sub-menu a {
    display: block;
    width: 100%;
    color: #fff !important;
    text-decoration: none;
    padding: 10px 15px;
    background-color: #444;
    box-sizing: border-box;
    transition: background 0.2s ease-in-out;
    border-radius: 0;
    margin: 0;
}

/* サブメニューのホバー時 */
.sub-menu a:hover {
    background-color: #666;
    border-radius: 0;
    margin: 0;
    padding: 10px 15px;
}

/* サブメニューの表示 */
.nav-menu li:hover > .sub-menu {
    display: block;
}

/* ネストされたサブメニューを右にずらす */
.sub-menu .sub-menu {
    top: 0;
    left: 180px; /* 右に100pxずらす */
}

/* ==========================
 * モバイル対応
 * ========================== */
@media (max-width: 768px) {
    .main-navigation {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px;
    }

    .nav-menu {
        flex-direction: column;
        width: 100%;
    }

    .nav-menu li {
        margin: 0;
        width: 100%;
    }

    .nav-menu a {
        width: 100%;
        padding: 15px;
    }

    .sub-menu {
        position: static;
        display: none;
        width: 100%;
        background: #444;
    }

    .nav-menu li:hover > .sub-menu {
        display: block;
    }

    .text-center,
    .has-text-align-center {
        text-align: left !important;
    }

    .site-header {
        height: 70px;
    }

    #content {
        padding-top: 80px;
    }

    .main-navigation {
        flex-direction: column;
        text-align: right;
    }

    .nav-menu {
        flex-direction: column;
        align-items: flex-end;
    }

    .nav-menu li {
        margin: 10px 0;
    }

    .site-branding .custom-logo {
        max-width: 50%;
		margin-top:30px;
    }
}

/* ==========================
 * フッター
 * ========================== */
.site-footer {
    text-align: center;
    padding: 4em 0 2em;
}

/* ==========================
 * フェードインアニメーション
 * ========================== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#content {
    opacity: 0;
    animation: fadeIn 1.2s ease-out forwards;
}

/* ==========================
 * YouTube埋め込み
 * ========================== */
.youtube {
    width: 100%;
    aspect-ratio: 16 / 9;
}

.youtube iframe {
    width: 100%;
    height: 100%;
}

/* ==========================
 * メイソンリーレイアウト
 * ========================== */
.masonry-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin-left: auto;
    margin-right: auto;
    max-width: 100%;
}

/* 小サイズ（33.333%） */
.size-small {
    width: calc(33.333% - 10px);
}

/* 中サイズ（50%） */
.size-medium {
    width: calc(50% - 10px);
}

/* タブレット（横向き）: 2カラム */
@media (max-width: 1024px) {
    .size-small,
    .size-medium {
        width: calc(50% - 10px);
    }
}

/* スマホ（モバイル）: 1カラム */
@media (max-width: 768px) {
    .size-small,
    .size-medium {
        width: calc(100% - 10px);
    }
}

/* アイテムデザイン */
.masonry-item {
    position: relative;
    overflow: hidden;
    padding: 30px;
}

@media (max-width: 768px) {
    .masonry-item {
        padding: 0;
    }
}

/* 画像デザイン */
.masonry-thumbnail {
    width: 100%;
    height: auto;
    display: block;
}

/* タイトルデザイン */
.home h2 {
    margin-bottom: 1em !important;
    font-size: 1.8rem;
    text-align: center;
}

.masonry-grid h3.entry-title {
    /*font-family: "Zen Kaku Gothic New", serif;*/
	font-family: 'Noto Sans JP', sans-serif;
    font-optical-sizing: auto;
    margin-bottom: 1em !important;
    font-size: 1.2rem !important;
    line-height: 1.3;
    letter-spacing: 0.1rem;
}

a img {
    transition: all 0.3s ease-in-out;
}

a:hover img {
    opacity: 0.8;
}

/* ==========================
 * タクソノミーページナビゲーション
 * ========================== */

/* ページネーション全体のラッパー */
.pagination-wrapper {
    text-align: center;
    margin-top: 40px;
}

/* ページ番号リスト */
.pagination-wrapper ul.page-numbers {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 0;
    margin: 0;
    list-style: none;
}

/* 各ページ番号の共通スタイル */
.pagination-wrapper .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    border-radius: 50%;
    transition: background-color 0.2s ease-in-out;
}

/* 現在のページ番号（ハイライト） */
.pagination-wrapper .page-numbers.current {
    background-color: #e5e5e5;
    color: #000;
    font-weight: bold;
}

/* ホバー時のエフェクト（現在ページ以外） */
.pagination-wrapper .page-numbers:not(.current):hover {
    background-color: #f0f0f0;
}

/* ドット（...）のスタイル */
.pagination-wrapper .page-numbers.dots {
    cursor: default;
    color: #888;
    width: auto;
    padding: 0 8px;
}

/* 前へ・次へボタン */
.pagination-wrapper .page-numbers.prev,
.pagination-wrapper .page-numbers.next {
    font-size: 20px;
    color: #555;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: transparent;
}

.pagination-wrapper .page-numbers.prev:hover,
.pagination-wrapper .page-numbers.next:hover {
    background-color: #f0f0f0;
}

.pagination-wrapper {
    text-align: center;
}

.pagination-wrapper ul.page-numbers {
    display: inline-flex; /* flexでも block でもなく inline-flex に */
    justify-content: center;
    align-items: center;
    padding: 0;
    margin: 0 auto; /* ここで左右中央寄せ */
    list-style: none;
    gap: 8px;
}

@media (max-width: 768px) {
  .pagination-wrapper ul.page-numbers {
    display: flex; /* inline-flex ではなく flex に */
    justify-content: center;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
  }
}



/* ==========================
 * その他
 * ========================== */

.category-list a.active {
    font-weight: bold;
    color: #000;
}