/* =========================================================
   知の泉 / The Spring of Knowledge  —  宮野宏樹 公式サイト
   Theme: 古典的・知的・静謐。深い紺と金、羊皮紙の地。
   ========================================================= */

:root {
  --ink:        #1b2235;   /* 深い藍墨 */
  --ink-soft:   #3a4259;
  --paper:      #f7f2e7;   /* 羊皮紙 */
  --paper-2:    #efe7d4;
  --paper-card: #fffdf8;
  --gold:       #b8893b;   /* 金 */
  --gold-deep:  #946b25;
  --spring:     #2a6f73;   /* 泉の青緑 */
  --spring-dk:  #1d5054;
  --line:       #e0d6bf;
  --muted:      #6c6757;
  --shadow:     0 8px 30px rgba(27,34,53,.12);
  --shadow-lg:  0 20px 60px rgba(27,34,53,.22);
  --serif-ja:   "Shippori Mincho", "Noto Serif JP", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --serif-en:   "Cormorant Garamond", "Georgia", "Times New Roman", serif;
  --sans-ja:    "Zen Kaku Gothic New", "Noto Sans JP", "Hiragino Sans", sans-serif;
  --maxw: 1140px;
  --readw: 720px;
}

/* ---------- reset ---------- */
*,*::before,*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans-ja);
  line-height: 1.85;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: var(--spring-dk); text-decoration: none; }
a:hover { color: var(--gold-deep); }

/* ---------- language switch ---------- */
/* 既定: 日本語表示。body.lang-en で英語表示 */
.lang-en .ja { display: none !important; }
body:not(.lang-en) .en { display: none !important; }
/* インライン要素用 */
span.ja, span.en, em.ja, em.en { display: inline; }
.lang-en span.ja, .lang-en em.ja { display: none !important; }
body:not(.lang-en) span.en, body:not(.lang-en) em.en { display: none !important; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247,242,231,.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav {
  max-width: var(--maxw); margin: 0 auto;
  display: flex; align-items: center; gap: 28px;
  padding: 14px 24px;
}
.brand { display: flex; align-items: baseline; gap: 10px; margin-right: auto; }
.brand .mark {
  font-family: var(--serif-ja); font-weight: 600;
  font-size: 22px; letter-spacing: .12em; color: var(--ink);
}
.brand .sub { font-size: 12px; color: var(--gold-deep); letter-spacing: .25em; }
.nav a.navlink { color: var(--ink-soft); font-size: 14px; letter-spacing: .08em; }
.nav a.navlink:hover { color: var(--gold-deep); }
.lang-toggle {
  display: inline-flex; border: 1px solid var(--gold); border-radius: 999px;
  overflow: hidden; font-size: 12px; letter-spacing: .1em;
}
.lang-toggle button {
  border: 0; background: transparent; color: var(--gold-deep);
  padding: 6px 14px; cursor: pointer; font-family: inherit;
}
.lang-toggle button.active { background: var(--gold); color: #fff; }

/* ---------- hero ---------- */
.hero {
  position: relative; color: #f4eedd; overflow: hidden;
  background: linear-gradient(180deg, #11162a 0%, #1b2235 60%, #232b44 100%);
}
.hero .hero-bg {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; opacity: .5; filter: saturate(1.05);
}
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(120% 90% at 50% 10%, transparent 30%, rgba(17,22,42,.85) 100%);
}
.hero-inner {
  position: relative; z-index: 2;
  max-width: var(--maxw); margin: 0 auto;
  padding: 120px 24px 110px; text-align: center;
}
.hero .kicker {
  letter-spacing: .42em; font-size: 12px; color: var(--gold);
  margin-bottom: 22px;
}
.hero h1 {
  font-family: var(--serif-ja); font-weight: 600;
  font-size: clamp(38px, 7vw, 76px); line-height: 1.15; margin: 0 0 8px;
  letter-spacing: .06em;
}
.hero .h1-en { font-family: var(--serif-en); letter-spacing: .04em; }
.hero .lead {
  max-width: 640px; margin: 26px auto 0; font-size: 17px;
  color: #ded6c2; line-height: 2;
}
.hero .cta { margin-top: 40px; display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ---------- buttons ---------- */
.btn {
  display: inline-block; padding: 13px 30px; border-radius: 2px;
  font-size: 14px; letter-spacing: .12em; cursor: pointer; border: 1px solid transparent;
  font-family: var(--sans-ja); transition: .2s;
}
.btn-gold { background: var(--gold); color: #fff; }
.btn-gold:hover { background: var(--gold-deep); color: #fff; }
.btn-ghost { border-color: rgba(244,238,221,.55); color: #f4eedd; }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--spring-dk); color: #fff; }

/* ---------- layout sections ---------- */
.section { max-width: var(--maxw); margin: 0 auto; padding: 84px 24px; }
.section-narrow { max-width: 860px; }
.eyebrow {
  letter-spacing: .34em; font-size: 12px; color: var(--gold-deep);
  text-align: center; margin-bottom: 14px;
}
.section h2 {
  font-family: var(--serif-ja); font-weight: 600;
  font-size: clamp(26px,4vw,38px); text-align: center; margin: 0 0 14px;
  letter-spacing: .05em;
}
.section .section-lead {
  max-width: 640px; margin: 0 auto 50px; text-align: center; color: var(--muted);
}
.divider {
  width: 64px; height: 1px; background: var(--gold);
  margin: 22px auto; position: relative;
}
.divider::before, .divider::after {
  content: "◆"; color: var(--gold); font-size: 9px;
  position: absolute; top: -6px;
}
.divider::before { left: -20px; } .divider::after { right: -20px; }

/* ---------- feature grid ---------- */
.grid { display: grid; gap: 28px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--paper-card); border: 1px solid var(--line);
  border-radius: 4px; padding: 30px; box-shadow: var(--shadow);
  transition: transform .2s, box-shadow .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card .ic { font-size: 26px; color: var(--gold); margin-bottom: 12px; }
.card h3 { font-family: var(--serif-ja); font-size: 20px; margin: 0 0 10px; letter-spacing: .04em; }
.card p { color: var(--muted); font-size: 15px; margin: 0; }

/* ---------- series feature (FRB) ---------- */
.feature {
  display: grid; grid-template-columns: 1.05fr 1fr; gap: 0;
  background: var(--paper-card); border: 1px solid var(--line);
  border-radius: 6px; overflow: hidden; box-shadow: var(--shadow-lg);
}
.feature .feat-media { position: relative; min-height: 380px; }
.feature .feat-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.feature .feat-body { padding: 52px 48px; }
.feature .badge {
  display: inline-block; background: var(--spring); color: #fff;
  font-size: 11px; letter-spacing: .2em; padding: 5px 12px; border-radius: 2px; margin-bottom: 18px;
}
.feature h3 { font-family: var(--serif-ja); font-size: 30px; margin: 0 0 14px; line-height: 1.4; }
.feature p { color: var(--muted); }
.feature .meta { font-size: 13px; color: var(--gold-deep); letter-spacing: .1em; margin: 18px 0 24px; }

/* ---------- note section ---------- */
.note-band { background: var(--ink); color: #e9e2cf; }
.note-band .section h2, .note-band .eyebrow { color: #e9e2cf; }
.note-band .eyebrow { color: var(--gold); }
.note-card {
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.12);
  border-radius: 4px; padding: 26px; transition: .2s;
}
.note-card:hover { background: rgba(255,255,255,.08); border-color: var(--gold); }
.note-card .tag { font-size: 11px; letter-spacing: .18em; color: var(--gold); }
.note-card h3 { font-family: var(--serif-ja); font-size: 19px; margin: 10px 0; color: #f4eedd; }
.note-card p { color: #c3bca9; font-size: 14px; margin: 0 0 14px; }
.note-card .more { font-size: 13px; color: var(--gold); letter-spacing: .08em; }

/* =========================================================
   article (連載) layout
   ========================================================= */
.article-hero {
  position: relative; color: #f4eedd;
  background: linear-gradient(180deg,#11162a,#1b2235);
  overflow: hidden;
}
.article-hero img.cover {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .45;
}
.article-hero::after {
  content:""; position:absolute; inset:0;
  background: linear-gradient(180deg, rgba(17,22,42,.5), rgba(17,22,42,.92));
}
.article-hero .ah-inner {
  position: relative; z-index: 2; max-width: var(--readw); margin: 0 auto;
  padding: 110px 24px 70px;
}
.article-hero .series-tag {
  letter-spacing: .26em; font-size: 12px; color: var(--gold); margin-bottom: 18px;
}
.article-hero .ep { font-size: 14px; color: #ccc4b0; letter-spacing: .14em; }
.article-hero h1 {
  font-family: var(--serif-ja); font-weight: 600;
  font-size: clamp(30px,5vw,48px); line-height: 1.35; margin: 14px 0 18px; letter-spacing: .04em;
}
.article-hero .sub { color: #d8d0bc; font-size: 16px; }
.article-hero .byline { margin-top: 26px; font-size: 13px; color: #b7af9c; letter-spacing: .08em; }

.article-body {
  max-width: var(--readw); margin: 0 auto; padding: 56px 24px 40px;
}
.article-body p { margin: 0 0 1.5em; }
.lang-en .article-body { font-family: var(--serif-en); font-size: 19px; line-height: 1.9; }
.lang-en .article-body h2, .lang-en .article-body h3 { font-family: var(--serif-en); }

.article-body .lede {
  font-family: var(--serif-ja); font-size: 21px; line-height: 2; color: var(--ink);
  border-left: 3px solid var(--gold); padding-left: 22px; margin-bottom: 40px;
}
.lang-en .article-body .lede { font-family: var(--serif-en); font-size: 23px; }

.article-body h2 {
  font-family: var(--serif-ja); font-size: 27px; margin: 56px 0 20px;
  letter-spacing: .03em; position: relative; padding-bottom: 10px;
}
.article-body h2::after {
  content:""; position:absolute; left:0; bottom:0; width:48px; height:2px; background: var(--gold);
}
.article-body h3 { font-family: var(--serif-ja); font-size: 20px; margin: 38px 0 14px; color: var(--ink-soft); }

.article-body figure { margin: 40px 0; }
.article-body figure img { border-radius: 4px; box-shadow: var(--shadow); width: 100%; }
.article-body figcaption {
  font-size: 13px; color: var(--muted); text-align: center; margin-top: 10px; letter-spacing: .02em;
}

/* pull quote */
.pullquote {
  font-family: var(--serif-ja); font-size: 23px; line-height: 1.8; color: var(--spring-dk);
  text-align: center; margin: 46px 0; padding: 10px 20px;
}
.pullquote::before { content:"“"; color: var(--gold); font-size: 40px; display:block; line-height:0.2; margin-top:18px;}

/* callout / note box */
.callout {
  background: var(--paper-2); border: 1px solid var(--line); border-left: 4px solid var(--spring);
  border-radius: 4px; padding: 22px 26px; margin: 38px 0; font-size: 15.5px;
}
.callout .ttl { font-weight: 700; color: var(--spring-dk); letter-spacing: .08em; margin-bottom: 8px; font-size: 13px; }

/* chart frame */
.chart {
  background: var(--paper-card); border: 1px solid var(--line); border-radius: 6px;
  padding: 26px 24px 18px; margin: 40px 0; box-shadow: var(--shadow);
}
.chart .chart-title { font-family: var(--serif-ja); font-size: 17px; text-align:center; margin-bottom: 6px; }
.chart .chart-note { font-size: 12px; color: var(--muted); text-align:center; margin-top: 10px; }
.chart svg { width: 100%; height: auto; display: block; }

/* timeline */
.timeline { list-style: none; padding: 0; margin: 36px 0; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 26px 28px; }
.timeline li::before {
  content:""; position:absolute; left:-7px; top:5px; width:12px; height:12px;
  background: var(--gold); border-radius:50%; box-shadow: 0 0 0 4px var(--paper);
}
.timeline .yr { font-family: var(--serif-en); color: var(--gold-deep); font-weight: 600; margin-right: 10px; }

/* end / next nav */
.article-end {
  max-width: var(--readw); margin: 10px auto 0; padding: 0 24px 60px; text-align:center;
}
.article-end .sig { font-family: var(--serif-ja); color: var(--muted); letter-spacing:.2em; margin: 30px 0; }
.next-box {
  display:flex; justify-content: space-between; gap: 16px; margin-top: 30px;
  border-top: 1px solid var(--line); padding-top: 26px;
}
.next-box a { flex: 1; padding: 18px 22px; border:1px solid var(--line); border-radius:4px; background: var(--paper-card); }
.next-box a:hover { border-color: var(--gold); }
.next-box .lbl { font-size: 11px; color: var(--muted); letter-spacing:.18em; }
.next-box .tl { font-family: var(--serif-ja); font-size:16px; color: var(--ink); margin-top:6px; }
.next-box .r { text-align:right; }

/* series index list */
.toc-list { display: grid; gap: 18px; margin: 40px 0; }
.toc-item {
  display:grid; grid-template-columns: 64px 1fr auto; align-items:center; gap: 20px;
  background: var(--paper-card); border:1px solid var(--line); border-radius:4px;
  padding: 22px 26px; box-shadow: var(--shadow); transition:.2s;
}
.toc-item:hover { transform: translateX(4px); border-color: var(--gold); }
.toc-item .num { font-family: var(--serif-en); font-size: 30px; color: var(--gold); text-align:center; }
.toc-item h3 { font-family: var(--serif-ja); font-size: 19px; margin: 0 0 4px; }
.toc-item p { margin: 0; font-size: 14px; color: var(--muted); }
.toc-item .stat { font-size: 12px; letter-spacing:.1em; color: var(--spring-dk); white-space:nowrap; }
.toc-item.upcoming { opacity:.6; }
.toc-item.upcoming .stat { color: var(--muted); }

/* ---------- footer ---------- */
.site-footer { background: #11162a; color: #b7af9c; margin-top: 60px; }
.footer-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 54px 24px 30px;
  display:flex; flex-wrap:wrap; gap: 40px; justify-content: space-between;
}
.footer-inner .f-brand .mark { font-family: var(--serif-ja); font-size: 20px; color:#f4eedd; letter-spacing:.1em; }
.footer-inner .f-brand p { font-size: 13px; max-width: 280px; margin-top:10px; }
.footer-col h4 { color: var(--gold); font-size: 12px; letter-spacing:.2em; margin:0 0 14px; }
.footer-col a { display:block; color:#b7af9c; font-size:14px; margin-bottom:9px; }
.footer-col a:hover { color: var(--gold); }
.copyright { text-align:center; font-size:12px; color:#6f6957; padding: 20px; border-top:1px solid rgba(255,255,255,.08); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .feature { grid-template-columns: 1fr; }
  .feature .feat-media { min-height: 240px; }
  .nav { gap: 16px; flex-wrap: wrap; }
  .nav a.navlink { font-size: 13px; }
}
@media (max-width: 560px) {
  .hero-inner { padding: 80px 20px 70px; }
  .feature .feat-body { padding: 34px 26px; }
  .toc-item { grid-template-columns: 44px 1fr; }
  .toc-item .stat { grid-column: 2; }
  .next-box { flex-direction: column; }
}
