/* =========================================
   基本設定・フォント
========================================= */
body { 
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto',
                 'Helvetica Neue', Arial, sans-serif; 
    background-color: #F7F4EF !important; 
    color: #333333 !important; 
}

h1, h2, h3, h4 { color: #1A1A1A !important; }
p, li { 
    color: #333333; 
    line-height: 1.75; 
}
a { color: #2563EB !important; } 
a:hover { color: #1D4ED8 !important; }

/* =========================================
   ナビゲーションバー & フッター
========================================= */
.navbar {
    background-color: #F7F4EF !important;
    backdrop-filter: blur(8px);
    border-bottom: 1.5px solid #d7dff0 !important;
}
.navbar-brand {
    color: #1A1A1A !important; 
    letter-spacing: 0.06em !important;
}
.nav-link { 
    color: #4B5563 !important; 
}
.nav-link:hover { 
    color: #D97706 !important; 
}
.nav-footer {
    background-color: #F9FAFB !important;
    border-top: 1px solid #E5E7EB !important;
    color: #6B7280 !important;
}

/* =========================================
   ヒーローエリア（タイトルバナー）
========================================= */
.quarto-title-banner {
    background-color: #F7F4EF !important;
    background-image:
        linear-gradient(rgba(0, 0, 0, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 0, 0, 0.02) 1px, transparent 1px) !important;
    background-size: 40px 40px !important;
    border-bottom: 2px solid #D97706 !important;
    padding: 4rem 0 3rem !important;
}
.quarto-title-banner .title {
    color: #111827 !important; 
    font-weight: 500 !important;
    letter-spacing: 0.02em !important;
}
.quarto-title-banner .description {
    color: #4B5563 !important;
    font-weight: 300 !important;
}

/* =========================================
   記事カード・リスト
========================================= */
.page-layout-full {
    background-color: #F7F4EF !important;
}
.quarto-post {
    background: #FFFFFF !important;
    border: 1px solid #E5E7EB !important;
    border-left: 4px solid #D97706 !important; 
    border-radius: 12px !important;
    transition: transform 0.2s, box-shadow 0.2s !important;
    overflow: hidden !important;
    padding: 1.5rem !important;
    margin-bottom: 1rem !important;
}
.quarto-post:hover {
    border-color: #D97706 !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05) !important;
}
.quarto-post .title { color: #1A1A1A !important; }
.quarto-post .description { color: #4B5563 !important; }
.quarto-post .listing-date { color: #6B7280 !important; }

/* カテゴリバッジ */
.listing-category {
    background: #FEF3C7 !important; 
    border: 1px solid #FDE68A !important;
    color: #D97706 !important; 
    border-radius: 999px !important;
    font-size: 11px !important;
    padding: 0.2rem 0.6rem !important;
}
.quarto-listing-category-title { 
    color: #D97706 !important; 
    font-size: 11px !important; 
    letter-spacing: 0.12em !important; 
}
.quarto-listing-category a { color: #6B7280 !important; }
.quarto-listing-category a:hover { color: #D97706 !important; }


/* =========================================
   コードブロック・インラインコードの設定
========================================= */

/* コードブロック全体（複数行のコード） */
pre, pre.sourceCode {
    background: #f4f0e7 !important; 
    border: 1px solid #dbd9d9 !important;
    border-radius: 8px !important;
    }

/* コードブロック内のテキスト色リセット */
pre code {
    background: transparent !important;
    color: inherit !important;
    padding: 0 !important;
}

/* インラインコード（文章中の短いコード）
   ★ 0.png (Claude風) のような「薄い背景＋濃い赤文字」に変更しました */
code:not(pre code) {
    background: #F3F4F6 !important; /* ほんのりグレー */
    color: #9B2C2C !important;      /* 落ち着いた赤（エンジ色） */
    border: 1px solid #E5E7EB !important; /* 薄い枠線を追加 */
    border-radius: 4px !important;
    padding: 0.1em 0.4em !important;
    font-size: 0.88em !important;
    font-family: 'JetBrains Mono', 'Fira Code', Consolas, monospace !important;
}

/* =========================================
   スクロールバー
========================================= */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: #FDFDFD; }
::-webkit-scrollbar-thumb { background: #D1D5DB; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #9CA3AF; }

/* listing カードのタイトルを明示的に指定 */
.quarto-post .title,
.quarto-post .listing-title,
h3.no-anchor.listing-title {
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    color: #1A1A1A !important;
    line-height: 1.4 !important;
}

/* =========================================
   言語切り替えトグルスイッチ
========================================= */
/* =========================================
   言語切り替えトグルスイッチ
========================================= */
.lang-toggle-wrapper {
  display: flex;
  align-items: center;
  padding: 0 12px;
}

.lang-switch-container {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  user-select: none;
}

.lang-switch-container:hover {
  opacity: 0.8;
}

.lang-text {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  transition: color 0.3s ease;
}

.lang-switch-container.is-jp .jp-text {
  color: #D97706; /* アクティブ: オレンジ */
}
.lang-switch-container.is-jp .en-text {
  color: #9CA3AF; /* 非アクティブ: グレー */
}

.lang-switch-container.is-en .jp-text {
  color: #9CA3AF;
}
.lang-switch-container.is-en .en-text {
  color: #D97706;
}

.lang-mini-toggle {
  position: relative;
  width: 36px;
  height: 18px;
  background-color: #F3F4F6;
  border-radius: 9px;
  border: 1px solid #E5E7EB;
  transition: all 0.3s ease;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.05);
}

.lang-mini-slider {
  position: absolute;
  top: 1px;
  left: 1px;
  width: 14px;
  height: 14px;
  background-color: #D97706; /* オレンジのボタン */
  border-radius: 50%;
  box-shadow: 0 1px 2px rgba(0,0,0,0.2);
  transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
}

.lang-switch-container.is-en .lang-mini-slider {
  transform: translateX(18px);
}