@charset "UTF-8";

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

   【フレキシブル対応の仕組み】
   --u はカンプの1pxで、ページの幅に比例します。
   文字・画像・模様・余白はすべて calc(数値 * var(--u)) で指定しています。
   ・画面幅 768px 以上 … 通常メニュー
   ・画面幅 767px 以下 … カンプと同じ見た目。ハンバーガーメニュー
   ニュースの日付・題名は更新しやすいよう、どちらの幅でもHTMLの文字です。
   ========================================================== */
:root {
  --navy: #0d2c6e;
  --blue: #1d6fc8;
  --line: #c3dbf3;
  --bg: #fcfcf5;
  --font-base: "Noto Sans JP", sans-serif;
  --font-title: "Zen Maru Gothic", "Noto Sans JP", sans-serif;
  --font-hand: "Klee One", "Zen Maru Gothic", 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/news/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 {
  position: relative;
  height: calc(360 * var(--u));
  background: url("images/news/hero.png") 0 0 / 100% 100% no-repeat;
}

/* 「ニュース一覧」の下の英字（他のページの「News」「Links」と同じ雰囲気） */
.hero__en {
  position: absolute;
  top: calc(146 * var(--u));
  left: calc(410 * var(--u));
  font-family: "Kaushan Script", cursive;
  font-size: calc(44 * var(--u));
  line-height: 1;
  letter-spacing: 0.01em;
  color: #13336e;
  white-space: nowrap;
  transform: rotate(-6deg);
  transform-origin: left center;
  text-shadow:
    0 0 calc(3 * var(--u)) #fff,
    0 0 calc(7 * var(--u)) #fff,
    0 0 calc(12 * var(--u)) rgba(255, 255, 255, 0.85);
  pointer-events: none;
}

/* ==========================================================
   ニュース一覧
   1件ごとに、音符・下線・「詳細を見る」ボタンの絵を背景にして
   日付と題名を重ねます（奇数・偶数番目で絵が少し違います）。
   ========================================================== */
.news-item {
  position: relative;
  height: calc(305 * var(--u));
  background: url("images/news/item-odd.png") 0 0 / 100% 100% no-repeat;
}

.news-item:nth-child(even) {
  background-image: url("images/news/item-even.png");
}

.news-item__date,
.news-item__title {
  position: absolute;
  font-family: var(--font-hand);
  font-weight: 600;
  color: var(--navy);
  -webkit-text-stroke: calc(1.1 * var(--u)) currentColor;
  /* 手書きらしく少し右上がり・斜めに */
  transform: rotate(-1.5deg) skewX(-6deg);
  transform-origin: left bottom;
  white-space: nowrap;
}

.news-item__date {
  top: calc(8 * var(--u));
  left: calc(133 * var(--u));
  font-size: calc(33 * var(--u));
  line-height: calc(46 * var(--u));
  letter-spacing: 0.14em;
}

/* 題名が長いときは下線の長さで切って「…」にする */
.news-item__title {
  top: calc(45 * var(--u));
  left: calc(134 * var(--u));
  max-width: calc(520 * var(--u));
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: calc(40 * var(--u));
  line-height: calc(70 * var(--u));
  letter-spacing: 0.1em;
}

.news-item:nth-child(even) .news-item__date {
  top: calc(5 * var(--u));
  left: calc(135 * var(--u));
}

.news-item:nth-child(even) .news-item__title {
  top: calc(49 * var(--u));
  left: calc(138 * var(--u));
}

/* 「詳細を見る」ボタンの絵の上にリンクを重ねる */
.news-item__more {
  position: absolute;
  top: calc(148 * var(--u));
  left: calc(130 * var(--u));
  width: calc(495 * var(--u));
  height: calc(95 * var(--u));
  border-radius: 999px;
  transition: background 0.2s;
}

.news-item:nth-child(even) .news-item__more {
  top: calc(158 * var(--u));
  left: calc(142 * var(--u));
}

.news-item__more:hover {
  background: rgba(255, 255, 255, 0.15);
}

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

/* 下部の楽器のイラスト */
.bottom-deco {
  height: calc(290 * var(--u));
  background: url("images/news/bottom.png") 0 0 / 100% 100% no-repeat;
}

/* ==========================================================
   フッター
   ========================================================== */
.footer {
  position: relative;
  height: calc(136 * var(--u));
  margin-top: -1px;
  background: url("images/news/footer-bg.png") 0 0 / 100% 100% no-repeat;
  color: #fff;
}

.footer__insta {
  position: absolute;
  top: calc(22 * var(--u));
  left: calc(80 * var(--u));
  height: calc(52 * var(--u));
  padding-left: calc(67 * var(--u));
  font-size: calc(16 * var(--u));
  line-height: calc(52 * var(--u));
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.footer__copy {
  position: absolute;
  top: calc(42 * 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(32 * var(--u));
    right: calc(53 * var(--u));
    width: calc(33 * var(--u));
    height: calc(30 * 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 * 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(12 * var(--u)); }
  .menu-btn span:nth-child(3) { top: calc(25 * var(--u)); }

  .menu-btn.is-open span:nth-child(1) { transform: translateY(calc(12.5 * 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(-12.5 * 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);
  }

  /* フッターは文字入りの画像に切り替え */
  .footer {
    background-image: url("images/news/footer.png");
  }

  .footer__insta,
  .footer__copy {
    color: transparent;
  }
}

/* ==========================================================
   WordPress用：ページ送り・記事が無いときの表示
   ========================================================== */
.pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: calc(14 * var(--u));
  margin: calc(10 * var(--u)) 0 calc(30 * var(--u));
}

.pagination .page-numbers {
  display: grid;
  place-items: center;
  min-width: calc(52 * var(--u));
  height: calc(52 * var(--u));
  padding: 0 calc(12 * var(--u));
  font-family: var(--font-title);
  font-size: calc(22 * var(--u));
  color: var(--navy);
  text-decoration: none;
  background: #fff;
  border: calc(2 * var(--u)) solid var(--line);
  border-radius: 999px;
  transition: background 0.2s, color 0.2s;
}

.pagination .page-numbers.current,
.pagination a.page-numbers:hover {
  color: #fff;
  background: var(--blue);
  border-color: var(--blue);
}

.pagination .page-numbers.dots {
  background: none;
  border: none;
}

.news-empty {
  padding: calc(60 * var(--u)) 0;
  font-size: calc(22 * var(--u));
  text-align: center;
}

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

.footer {
  /* 余った高さはフッターが受け持つ（画像は元の高さのまま上に置き、下はフッター画像の下端と同じ青で塗る） */
  flex-grow: 1;
  margin-top: -1px; /* 上の内容との境目に、端数で細いすき間ができないように重ねる */
  background-size: 100% calc(136 * var(--u));
  background-color: #0154a4;
}
