/* =========================================
   楽器ヒストリー — style.css
   ========================================= */

:root {
  --bg: #faf6ef;          /* 生成りの紙 */
  --bg-alt: #f1e9dc;
  --ink: #2a211b;         /* こげ茶の文字 */
  --ink-soft: #6b5d52;
  --wood: #8a4b25;        /* ローズウッド */
  --gold: #c8963e;        /* ブラス */
  --dark: #1f1813;
  --red: #e62117;         /* YouTube */
  --radius: 14px;
  --serif: "Noto Serif JP", serif;
  --sans: "Noto Sans JP", system-ui, sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

img, iframe { max-width: 100%; display: block; }
a { color: inherit; }

.container { width: min(1080px, 100% - 40px); margin-inline: auto; }
.center { text-align: center; margin-top: 40px; }

/* ---------- ボタン ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition: transform .2s, background .2s, color .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn svg { width: 20px; height: 20px; fill: currentColor; }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: #c41a12; }
.btn-ghost { color: #fff; border: 1px solid rgba(255,255,255,.4); }
.btn-ghost:hover { background: rgba(255,255,255,.1); }
.btn-outline { border: 2px solid var(--wood); color: var(--wood); }
.btn-outline:hover { background: var(--wood); color: #fff; }
.btn-small { padding: 8px 18px; font-size: .875rem; background: var(--red); color: #fff; }

/* ---------- ヘッダー ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 10;
  background: rgba(31, 24, 19, .85);
  backdrop-filter: blur(8px);
  color: #fff;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo {
  margin: 0;
  font-family: var(--serif);
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: .05em;
  text-decoration: none;
}
.logo span { color: var(--gold); }
.nav { display: flex; align-items: center; gap: 28px; font-size: .9rem; }
.nav a:not(.btn) { text-decoration: none; opacity: .85; }
.nav a:not(.btn):hover { opacity: 1; color: var(--gold); }

/* ---------- ヒーロー ---------- */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 100svh;
  display: flex;
  align-items: center;
  color: #fff;
  background:
    radial-gradient(ellipse at 80% 30%, rgba(200,150,62,.25), transparent 60%),
    linear-gradient(160deg, #3a2417 0%, var(--dark) 70%);
}
.hero-inner { position: relative; z-index: 1; padding-block: 120px 80px; }
.hero-eyebrow {
  margin: 0 0 16px;
  font-size: .8rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--gold);
}
.hero-title {
  margin: 0 0 24px;
  font-family: var(--serif);
  font-size: clamp(2.2rem, 6vw, 4.2rem);
  line-height: 1.35;
}
.hero-title em { font-style: normal; color: var(--gold); }
.hero-lead { margin: 0 0 40px; max-width: 34em; color: rgba(255,255,255,.8); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 16px; }

/* 背景のギター弦 */
.hero-strings {
  position: absolute;
  inset: 0 0 0 auto;
  width: 45%;
  display: flex;
  justify-content: space-evenly;
  transform: skewX(-12deg);
  opacity: .35;
}
.hero-strings span {
  width: 1px;
  background: linear-gradient(transparent, var(--gold) 20%, var(--gold) 80%, transparent);
  animation: vibrate 3s ease-in-out infinite;
}
.hero-strings span:nth-child(n+4) { width: 2px; }
.hero-strings span:nth-child(2) { animation-delay: .3s; }
.hero-strings span:nth-child(3) { animation-delay: .6s; }
.hero-strings span:nth-child(4) { animation-delay: .9s; }
.hero-strings span:nth-child(5) { animation-delay: 1.2s; }
.hero-strings span:nth-child(6) { animation-delay: 1.5s; }
@keyframes vibrate {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(2px); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-strings span { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- セクション共通 ---------- */
.section { padding-block: 100px; }
.section-alt { background: var(--bg-alt); }
.section-title {
  margin: 0 0 48px;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 3vw, 2rem);
  text-align: center;
}
.section-title span {
  display: block;
  margin-bottom: 4px;
  font-family: var(--sans);
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--wood);
}

/* About */
.about { max-width: 720px; text-align: center; font-size: 1.05rem; }
.about p { margin: 0 0 1.2em; }

/* テーマカード */
.cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}
.card {
  padding: 36px 28px;
  background: #fff;
  border-radius: var(--radius);
  border-top: 4px solid var(--wood);
  box-shadow: 0 6px 24px rgba(42, 33, 27, .06);
}
.card-num { font-family: var(--serif); font-size: 2rem; font-weight: 800; color: var(--gold); line-height: 1; }
.card h3 { margin: 16px 0 8px; font-family: var(--serif); font-size: 1.15rem; }
.card p { margin: 0; color: var(--ink-soft); font-size: .95rem; }

/* 動画（ショートは縦長 9:16） */
.videos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 280px));
  justify-content: center;
  gap: 24px;
}
.video {
  aspect-ratio: 9 / 16;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--dark);
}
.video iframe { width: 100%; height: 100%; border: 0; }

/* CTA */
.cta {
  padding-block: 90px;
  text-align: center;
  color: #fff;
  background: linear-gradient(135deg, var(--wood), #5a2f16);
}
.cta h2 { margin: 0 0 8px; font-family: var(--serif); font-size: clamp(1.5rem, 3vw, 2.2rem); }
.cta p { margin: 0 0 32px; opacity: .85; }

/* フッター */
.site-footer { padding-block: 32px; background: var(--dark); color: #fff; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; }
.copyright { margin: 0; font-size: .8rem; opacity: .6; }
.footer-nav { display: flex; gap: 20px; font-size: .85rem; }
.footer-nav a { text-decoration: none; opacity: .75; }
.footer-nav a:hover { opacity: 1; color: var(--gold); }

/* ---------- プライバシーポリシーなどの文章ページ ---------- */
.legal { padding-block: 140px 100px; }
.legal-inner { max-width: 760px; }
.legal h2 {
  margin: 48px 0 12px;
  padding-left: 12px;
  border-left: 4px solid var(--wood);
  font-family: var(--serif);
  font-size: 1.2rem;
  line-height: 1.5;
}
.legal p { margin: 0 0 1em; }
.legal a { color: var(--wood); }
.legal a:hover { color: var(--gold); }
.legal-date { margin-top: 48px !important; text-align: right; color: var(--ink-soft); font-size: .9rem; }

/* ---------- 読みもの（/stories/） ---------- */
.story { padding-top: 140px; }
.story > .container:only-child { padding-bottom: 100px; }
.stories-intro { max-width: 720px; margin: -24px auto 24px; text-align: center; color: var(--ink-soft); }

.badge {
  display: inline-block;
  padding: 2px 12px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 700;
  line-height: 1.8;
  white-space: nowrap;
}
.badge-video   { background: var(--red); color: #fff; }
.badge-planned { background: var(--gold); color: var(--dark); }
.badge-extra   { background: var(--wood); color: #fff; }

.badge-legend {
  list-style: none;
  margin: 0 0 48px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 24px;
  font-size: .85rem;
  color: var(--ink-soft);
}
.badge-legend .badge { margin-right: 8px; }

.story-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.story-card a {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 28px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 6px 24px rgba(42, 33, 27, .06);
  text-decoration: none;
  transition: transform .2s, box-shadow .2s;
}
.story-card a:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(42, 33, 27, .12); }
.story-card .badge { align-self: flex-start; }
.story-thumb {
  width: calc(100% + 56px);
  max-width: none;
  margin: -28px -28px 20px;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center 58%;
  border-radius: var(--radius) var(--radius) 0 0;
  background: var(--dark);
}
.story-card h3 { margin: 12px 0 8px; font-family: var(--serif); font-size: 1.15rem; line-height: 1.5; }
.story-card p { margin: 0 0 16px; color: var(--ink-soft); font-size: .92rem; }
.story-more { margin-top: auto; color: var(--wood); font-weight: 700; font-size: .9rem; }

/* 記事 */
/* 本文は1行およそ38字に収める（日本語は35〜40字が読みやすい） */
.story-inner { max-width: 660px; padding-bottom: 80px; }
.breadcrumb { margin-bottom: 24px; font-size: .85rem; color: var(--ink-soft); }
.breadcrumb a { color: var(--wood); }
.story-head h1 {
  margin: 12px 0 16px;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 4vw, 2.1rem);
  line-height: 1.45;
}
/* 見出しは単語の途中で折り返さない（「トーレ／ス」のような分かれ方を防ぐ） */
.story-head h1, .story-body h2, .story-card h3 { word-break: auto-phrase; text-wrap: balance; }
.story-lead { margin: 0 0 8px; font-size: 1.05rem; }
.story-date { margin: 0 0 32px; font-size: .85rem; color: var(--ink-soft); }

.story-video {
  display: grid;
  grid-template-columns: 150px 1fr;
  align-items: center;
  gap: 20px;
  margin: 0 0 48px;
  padding: 16px;
  background: var(--bg-alt);
  border-radius: var(--radius);
}
.story-video p { margin: 0; color: var(--ink-soft); font-size: .92rem; }
.story-note {
  margin: 0 0 40px;
  padding: 16px 20px;
  background: var(--bg-alt);
  border-left: 4px solid var(--gold);
  border-radius: 4px;
  font-size: .92rem;
}
.story-note p { margin: 0; }
.story-note a { color: var(--wood); }

.story-body {
  font-size: 1.0625rem;
  line-height: 2.05;
  letter-spacing: .03em;
  text-wrap: pretty;
}
.story-body h2 {
  margin: 64px 0 20px;
  padding-left: 12px;
  border-left: 4px solid var(--wood);
  font-family: var(--serif);
  font-size: 1.3rem;
  line-height: 1.5;
}
.story-body p { margin: 0 0 1.8em; }
.story-body a { color: var(--wood); }
.story-body strong { background: linear-gradient(transparent 62%, rgba(200,150,62,.35) 62%); }
/* 動画から切り出した画像（右に寄せ、文章が回りこむ） */
.story-fig {
  float: right;
  width: 200px;
  margin: 6px 0 20px 28px;
}
.story-fig img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  background: var(--dark);
}
.story-fig figcaption {
  margin-top: 6px;
  font-size: .78rem;
  line-height: 1.6;
  letter-spacing: 0;
  color: var(--ink-soft);
}
.story-body h2 { clear: both; }

.story-body .point {
  display: flow-root;   /* 右の画像と重ならない */
  margin: 32px 0;
  padding: 20px 24px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 6px 24px rgba(42, 33, 27, .06);
}
.story-body .point h3 { margin: 0 0 8px; font-family: var(--serif); font-size: 1.05rem; color: var(--wood); }
.story-body .point p:last-child, .story-body .point ul:last-child { margin-bottom: 0; }
.story-body .timeline { margin: 0 0 1.4em; padding-left: 1.2em; }
.story-body .timeline li { margin-bottom: .3em; }

.story-sources {
  margin-top: 56px;
  padding-top: 24px;
  border-top: 1px solid rgba(42, 33, 27, .15);
  font-size: .85rem;
  color: var(--ink-soft);
}
.story-sources h2 { margin: 0 0 8px; font-size: .95rem; color: var(--ink); }
.story-sources ul { margin: 0 0 12px; padding-left: 1.2em; }
.story-sources a { color: var(--ink-soft); word-break: break-all; }

/* ---------- スマホ ---------- */
@media (max-width: 720px) {
  .nav a:not(.btn):not(.nav-keep) { display: none; }
  .nav { gap: 16px; }
  .pc-only { display: none; }
  .section { padding-block: 72px; }
  .hero-strings { width: 70%; opacity: .2; }
  .story { padding-top: 110px; }
  .story-video { grid-template-columns: 110px 1fr; gap: 14px; padding: 12px; }
  .story-body { font-size: 1rem; letter-spacing: .02em; }
  .story-body h2 { margin-top: 52px; font-size: 1.2rem; }
  .story-body .point { padding: 16px 18px; }
  .story-fig { width: 40%; margin: 6px 0 14px 16px; }
}
