@charset "UTF-8";

/* ==========================================================
   ニュース（投稿ページ）
   デザインカンプ（news.png・幅1024px）を基準にしています。

   【フレキシブル対応の仕組み】
   --u はカンプの1pxで、ページの幅に比例します。
   文字・画像・模様・余白はすべて calc(数値 * var(--u)) で指定しています。
   ・画面幅 768px 以上 … 通常メニュー
   ・画面幅 767px 以下 … カンプと同じ見た目。ハンバーガーメニュー

   【WordPress 対応】
   日付・題名・本文は記事ごとに変わるため、どの幅でもHTMLの文字です。
   本文の長さに合わせてページの高さが伸び縮みします。
   本文（the_content の出力）は .entry-content の中に入り、
   段落・リスト・見出し・画像などのブロックにもデザインが当たります。
   ========================================================== */
:root {
  --navy: #0b1a4a;
  --blue: #1d6fc8;
  --line: #c3dbf3;
  --bg: #fdfdf9;
  --font-base: "Noto Sans JP", sans-serif;
  --font-title: "Zen Maru Gothic", "Noto Sans JP", sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  container-type: inline-size;
  --u: calc(100cqw / 1024);
  margin: 0;
  font-family: var(--font-base);
  color: var(--navy);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

h1, h2, p {
  margin: 0;
}

/* 画像に含まれている文字を、読み上げ・検索用に残す */
.sr-text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ==========================================================
   ヘッダー
   ========================================================== */
.header {
  position: relative;
  height: calc(184 * var(--u));
  background: url("images/post/header.png") 0 0 / 100% auto no-repeat;
  z-index: 10;
}

.header__logo {
  position: absolute;
  top: calc(10 * var(--u));
  left: calc(50 * var(--u));
  width: calc(210 * var(--u));
  height: calc(120 * var(--u));
}

.menu-btn {
  display: none;
}

/* 通常メニュー */
.global-nav {
  position: absolute;
  top: calc(134 * var(--u));
  left: 0;
  right: 0;
  height: calc(50 * var(--u));
  background: #fff;
  border-top: 1px solid var(--line);
}

.global-nav ul {
  display: flex;
  height: 100%;
  padding: 0 calc(50 * var(--u));
}

.global-nav li {
  flex: 1;
}

.global-nav a {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  font-family: var(--font-title);
  font-weight: 500;
  font-size: calc(16 * var(--u));
  letter-spacing: 0.08em;
  color: #17305f;
  transition: color 0.2s;
}

.global-nav a::after {
  content: "";
  position: absolute;
  left: 15%;
  right: 15%;
  bottom: calc(6 * var(--u));
  height: calc(2 * var(--u));
  border-radius: calc(2 * var(--u));
  background: var(--blue);
  transform: scaleX(0);
  transition: transform 0.2s;
}

.global-nav a:hover {
  color: var(--blue);
}

.global-nav a:hover::after,
.global-nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

/* ==========================================================
   メインビジュアル
   ========================================================== */
.hero {
  height: calc(360 * var(--u));
  background: url("images/post/hero.png") 0 0 / 100% 100% no-repeat;
}

/* ==========================================================
   記事
   ========================================================== */
.post {
  position: relative;
  padding: calc(41.5 * var(--u)) calc(154 * var(--u)) calc(31 * var(--u)) calc(130 * var(--u));
  background: var(--bg);
}

/* 左の音符・右の音符 */
.post::before,
.post::after {
  content: "";
  position: absolute;
  background: 0 0 / 100% 100% no-repeat;
  mix-blend-mode: multiply;
  pointer-events: none;
}

.post::before {
  top: calc(36 * var(--u));
  left: calc(52 * var(--u));
  width: calc(44 * var(--u));
  height: calc(52 * var(--u));
  background-image: url("images/post/note-left.png");
}

.post::after {
  top: calc(70 * var(--u));
  left: calc(880 * var(--u));
  width: calc(95 * var(--u));
  height: calc(152 * var(--u));
  background-image: url("images/post/notes-right.png");
}

.post__date {
  display: block;
  margin-left: calc(7 * var(--u));
  font-size: calc(23 * var(--u));
  font-weight: 500;
  line-height: calc(30 * var(--u));
  letter-spacing: 0.02em;
}

/* 題名：下に筆で引いたような青い線（題名の長さに合わせて伸びる） */
.post__title {
  position: relative;
  display: inline-block;
  max-width: 100%;
  margin: calc(9 * var(--u)) 0 0 calc(4 * var(--u));
  font-size: calc(33 * var(--u));
  font-weight: 700;
  line-height: calc(48 * var(--u));
  letter-spacing: 0.07em;
  isolation: isolate;
}

.post__title::before {
  content: "";
  position: absolute;
  left: calc(-23 * var(--u));
  right: calc(-45 * var(--u));
  bottom: calc(-13.5 * var(--u));
  height: calc(44 * var(--u));
  background: url("images/post/title-line.png") 0 0 / 100% 100% no-repeat;
  mix-blend-mode: multiply;
  z-index: -1;
}

/* ==========================================================
   本文（the_content の出力）
   ========================================================== */
.entry-content {
  margin-top: calc(45.5 * var(--u));
  font-size: calc(27 * var(--u));
  line-height: calc(40 * var(--u));
  letter-spacing: 0.06em;
  overflow-wrap: anywhere;
}

.entry-content > * {
  margin: 0 0 calc(32 * var(--u));
}

.entry-content > :last-child {
  margin-bottom: 0;
}

/* リスト：カンプと同じ「・」の印 */
.entry-content ul,
.entry-content ol {
  padding: 0;
  letter-spacing: 0;
}

.entry-content ul > li {
  list-style: none;
}

.entry-content ul > li::before {
  content: "・";
}

.entry-content ol {
  padding-left: 1.6em;
}

.entry-content ol > li {
  list-style: decimal;
}

.entry-content li > ul,
.entry-content li > ol {
  margin: 0 0 0 1em;
}

/* 見出し */
.entry-content h2,
.entry-content h3,
.entry-content h4 {
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.5;
}

.entry-content h2 {
  padding-bottom: calc(6 * var(--u));
  font-size: calc(30 * var(--u));
  border-bottom: calc(3 * var(--u)) solid #6fb3ec;
}

.entry-content h3 {
  padding-left: calc(14 * var(--u));
  font-size: calc(27 * var(--u));
  border-left: calc(6 * var(--u)) solid var(--blue);
}

.entry-content h4 {
  font-size: calc(25 * var(--u));
}

/* リンク・強調 */
.entry-content a {
  color: var(--blue);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.entry-content strong {
  font-weight: 600;
}

/* 画像・動画 */
.entry-content img,
.entry-content video,
.entry-content iframe {
  max-width: 100%;
  height: auto;
  vertical-align: bottom;
}

.entry-content img {
  border-radius: calc(12 * var(--u));
}

.entry-content figure {
  margin-left: 0;
  margin-right: 0;
}

.entry-content figcaption {
  margin-top: calc(8 * var(--u));
  font-size: calc(19 * var(--u));
  line-height: 1.6;
  text-align: center;
  color: #4a5a80;
}

.entry-content .aligncenter {
  display: block;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.entry-content .alignleft {
  float: left;
  margin: 0 calc(24 * var(--u)) calc(16 * var(--u)) 0;
}

.entry-content .alignright {
  float: right;
  margin: 0 0 calc(16 * var(--u)) calc(24 * var(--u));
}

.entry-content::after {
  content: "";
  display: block;
  clear: both;
}

/* 引用・区切り線・表・ボタン */
.entry-content blockquote {
  padding: calc(16 * var(--u)) calc(24 * var(--u));
  background: #eef6fd;
  border-left: calc(6 * var(--u)) solid #6fb3ec;
  border-radius: calc(8 * var(--u));
}

.entry-content hr {
  border: none;
  border-top: calc(2 * var(--u)) dashed var(--line);
}

.entry-content table {
  width: 100%;
  border-collapse: collapse;
  font-size: calc(21 * var(--u));
}

.entry-content th,
.entry-content td {
  padding: calc(8 * var(--u)) calc(12 * var(--u));
  border: 1px solid var(--line);
}

.entry-content th {
  background: #eef6fd;
}

.entry-content .wp-block-button__link {
  display: inline-block;
  padding: calc(10 * var(--u)) calc(32 * var(--u));
  color: #fff;
  background: var(--blue);
  border-radius: 999px;
  text-decoration: none;
}

/* ==========================================================
   一覧に戻るボタン・楽器のイラスト
   ========================================================== */
.post-footer {
  position: relative;
  height: calc(376 * var(--u));
  background: url("images/post/bottom.png") 0 0 / 100% 100% no-repeat;
}

/* 「ニュース一覧に戻る」ボタンの絵の上にリンクを重ねる */
.post-footer__back {
  position: absolute;
  top: calc(30 * var(--u));
  left: calc(318 * var(--u));
  width: calc(424 * var(--u));
  height: calc(66 * var(--u));
  border-radius: 999px;
  transition: background 0.2s;
}

.post-footer__back:hover {
  background: rgba(255, 255, 255, 0.25);
}

.post-footer__back:focus-visible {
  outline: none;
  box-shadow: 0 0 0 calc(3 * var(--u)) rgba(29, 111, 200, 0.45);
}

/* ==========================================================
   フッター
   カンプの波の下に、他のページと同じ紺色の帯を続けます。
   ========================================================== */
.footer {
  position: relative;
  height: calc(100 * var(--u));
  margin-top: -1px;
  background: #0152a1;
  color: #fff;
}

.footer__insta {
  position: absolute;
  top: calc(14.5 * var(--u));
  left: calc(73 * var(--u));
  height: calc(61 * var(--u));
  padding-left: calc(76 * var(--u));
  font-size: calc(16 * var(--u));
  line-height: calc(61 * var(--u));
  letter-spacing: 0.04em;
  white-space: nowrap;
  background: url("images/post/instagram.png") 0 50% / calc(61 * var(--u)) calc(61 * var(--u)) no-repeat;
  transition: opacity 0.2s;
}

.footer__insta:hover {
  opacity: 0.8;
}

.footer__copy {
  position: absolute;
  top: calc(36 * var(--u));
  right: calc(54 * var(--u));
  font-size: calc(12.5 * var(--u));
  line-height: calc(18 * var(--u));
  letter-spacing: 0.03em;
  white-space: nowrap;
}

/* ==========================================================
   スマートフォン（767px以下）
   ========================================================== */
@media (max-width: 767px) {
  .header {
    height: calc(140 * var(--u));
    background-size: 100% 100%;
  }

  /* ハンバーガーボタン */
  .menu-btn {
    position: absolute;
    display: block;
    top: calc(31 * var(--u));
    right: calc(53 * var(--u));
    width: calc(33 * var(--u));
    height: calc(31 * var(--u));
    padding: 0;
    background: none;
    border: none;
    cursor: pointer;
  }

  /* 押しやすいようにタップ範囲を広げる */
  .menu-btn::before {
    content: "";
    position: absolute;
    inset: -12px -12px;
  }

  .menu-btn span {
    position: absolute;
    left: 0;
    width: 100%;
    height: calc(5.5 * var(--u));
    background: #042d69;
    transition: transform 0.3s, opacity 0.3s;
  }

  .menu-btn span:nth-child(1) { top: 0; }
  .menu-btn span:nth-child(2) { top: calc(13 * var(--u)); }
  .menu-btn span:nth-child(3) { top: calc(26 * var(--u)); }

  .menu-btn.is-open span:nth-child(1) { transform: translateY(calc(13 * var(--u))) rotate(45deg); }
  .menu-btn.is-open span:nth-child(2) { opacity: 0; }
  .menu-btn.is-open span:nth-child(3) { transform: translateY(calc(-13 * var(--u))) rotate(-45deg); }

  /* ハンバーガーメニュー */
  .global-nav {
    top: 100%;
    left: auto;
    right: 8px;
    width: 240px;
    max-width: calc(100% - 16px);
    height: auto;
    background: rgba(13, 47, 108, 0.96);
    border-top: none;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(13, 47, 108, 0.3);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.3s, transform 0.3s, visibility 0.3s;
  }

  .global-nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .global-nav ul {
    display: block;
    height: auto;
    padding: 0;
  }

  .global-nav a {
    display: block;
    height: auto;
    padding: 13px 22px;
    font-family: var(--font-base);
    font-size: 15px;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  }

  .global-nav a::after {
    display: none;
  }

  .global-nav li:last-child a {
    border-bottom: none;
  }

  .global-nav a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
  }
}

/* ==========================================================
   ページが画面より短いとき（縦長のスマホなど）も、
   フッターを画面の一番下まで届かせる（フッターは単色なので伸ばすだけ）
   ========================================================== */
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh; /* スマホのアドレスバーの出入りに合わせた画面の高さ（対応ブラウザのみ） */
}

.footer {
  flex-grow: 1;
}
