/* =====================================================================
 *  にゅるはうす  style.css
 *  テーマ：青空＋ステッカー。常駐レイヤーの上をカードが流れる多層スクロール。
 * ===================================================================== */

:root {
  /* 空 */
  --sky-top: #6FB8EE;
  --sky-mid: #A5D8F3;
  --sky-low: #DCF0FC;
  --cloud: #ffffff;

  /* キャラ由来のアクセント */
  --gold: #FFC93C;
  /* 髪・金の瞳・★ */
  --pink: #FF9DC5;
  /* 髪ハイライト */
  --blue: #3D9BE8;
  /* 青の瞳 */
  --purple: #B79BE8;
  /* 髪ハイライト */
  --chick: #FFD84D;
  /* ぴよち */

  /* 文字・線 */
  --ink: #3A5680;
  /* 黒の代わりの柔らかいネイビー */
  --ink-soft: #6E86AD;
  --line: #ffffff;

  /* ステッカー */
  --sticker-radius: 26px;
  --sticker-border: 5px;
  --sticker-shadow: 0 14px 30px rgba(58, 86, 128, .18), 0 3px 0 rgba(58, 86, 128, .06);

  --maxw: 1080px;
  --font-disp: "Mochiy Pop One", system-ui, sans-serif;
  --font-latin: "Fredoka", system-ui, sans-serif;
  --font-body: "Zen Maru Gothic", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--sky-mid);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  line-height: 1.8;
}

img {
  display: block;
  max-width: 100%;
}

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

/* =====================================================================
 *  常駐ステージ（背景・空・キャラ）— position:fixed で動かない
 * ===================================================================== */
.stage {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.sky {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 80% at 50% -10%, #BFE7FF 0%, transparent 55%),
    linear-gradient(180deg, var(--sky-top) 0%, var(--sky-mid) 42%, var(--sky-low) 100%);
}

/* --- 雲 --- */
.clouds {
  position: absolute;
  inset: 0;
  will-change: transform;
}

.cloud {
  position: absolute;
  background: var(--cloud);
  border-radius: 50%;
  filter: blur(2px);
  opacity: .92;
  box-shadow:
    60px 10px 0 -6px var(--cloud),
    120px 20px 0 -14px var(--cloud),
    -60px 18px 0 -10px var(--cloud);
}

.cloud::after {
  content: "";
  position: absolute;
  left: 18%;
  top: -38%;
  width: 64%;
  height: 120%;
  background: var(--cloud);
  border-radius: 50%;
}

.c1 {
  width: 200px;
  height: 64px;
  top: 12%;
  left: 8%;
  animation: floatX 46s linear infinite;
}

.c2 {
  width: 150px;
  height: 50px;
  top: 30%;
  left: 62%;
  opacity: .8;
  animation: floatX 60s linear infinite reverse;
}

.c3 {
  width: 240px;
  height: 74px;
  top: 60%;
  left: 20%;
  opacity: .7;
  animation: floatX 72s linear infinite;
}

.c4 {
  width: 120px;
  height: 42px;
  top: 78%;
  left: 74%;
  opacity: .85;
  animation: floatX 54s linear infinite reverse;
}

@keyframes floatX {
  from {
    transform: translateX(-12vw);
  }

  to {
    transform: translateX(12vw);
  }
}

/* --- キラキラ・ぴよち・紙飛行機 --- */
.drift {
  position: absolute;
  inset: 0;
  will-change: transform;
}

.drift span {
  position: absolute;
  filter: drop-shadow(0 3px 4px rgba(58, 86, 128, .18));
}

.spark {
  color: #fff;
  text-shadow: 0 0 10px var(--gold);
}

.s1 {
  top: 18%;
  left: 30%;
  font-size: 24px;
  animation: twinkle 3.2s ease-in-out infinite;
}

.s2 {
  top: 46%;
  left: 84%;
  font-size: 18px;
  animation: twinkle 2.4s ease-in-out infinite .6s;
}

.s3 {
  top: 70%;
  left: 46%;
  font-size: 28px;
  animation: twinkle 3.8s ease-in-out infinite 1.1s;
  color: var(--gold);
}

.paperplane {
  top: 26%;
  left: 70%;
  font-size: 30px;
  color: #fff;
  animation: plane 16s ease-in-out infinite;
}

.chick {
  font-size: 34px;
}

.ch1 {
  top: 22%;
  left: 14%;
  animation: bob 4.5s ease-in-out infinite;
}

.ch2 {
  top: 64%;
  left: 80%;
  font-size: 28px;
  animation: bob 5.5s ease-in-out infinite 1s;
}

@keyframes twinkle {

  0%,
  100% {
    opacity: .25;
    transform: scale(.8);
  }

  50% {
    opacity: 1;
    transform: scale(1.15);
  }
}

@keyframes bob {

  0%,
  100% {
    transform: translateY(0) rotate(-4deg);
  }

  50% {
    transform: translateY(-14px) rotate(4deg);
  }
}

@keyframes plane {
  0% {
    transform: translate(0, 0) rotate(-8deg);
    opacity: 0;
  }

  10% {
    opacity: 1;
  }

  90% {
    opacity: 1;
  }

  100% {
    transform: translate(-46vw, 16vh) rotate(-8deg);
    opacity: 0;
  }
}

/* --- 常駐キャラ（下隅から覗く） --- */
.resident {
  position: absolute;
  right: -40px;
  bottom: -30px;
  width: min(40vw, 440px);
  filter: drop-shadow(0 18px 26px rgba(58, 86, 128, .28));
  opacity: .96;
  animation: residentFloat 7s ease-in-out infinite;
  transform-origin: bottom center;
}

@keyframes residentFloat {

  0%,
  100% {
    transform: translateY(0) rotate(-1deg);
  }

  50% {
    transform: translateY(-16px) rotate(1deg);
  }
}

/* =====================================================================
 *  手前：スクロールする中身
 * ===================================================================== */
.scroll {
  position: relative;
  z-index: 2;
}

/* ---------- ヒーロー ---------- */
.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(28px, 5vw, 56px);
  padding: clamp(28px, 6vw, 70px) clamp(20px, 5vw, 56px) 40px;
  max-width: var(--maxw);
  margin-inline: auto;
}

.hero-inner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: clamp(22px, 4vw, 52px);
  align-items: center;
}

/* ポートレート（ステッカー風の白フチ円） */
.hero-portrait {
  position: relative;
  width: clamp(180px, 26vw, 300px);
  aspect-ratio: 1;
  flex: none;
}

.hero-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 18%;
  border-radius: 50%;
  border: 7px solid var(--line);
  background:
    radial-gradient(circle at 50% 38%, #fff 0%, #EAF6FF 70%, #D4ECFB 100%);
  box-shadow: var(--sticker-shadow);
}

/* 金＆青の瞳バッジ＝ブランドの核 */
.badge-eye {
  position: absolute;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 4px solid #fff;
  box-shadow: 0 4px 10px rgba(58, 86, 128, .25);
}

.eye-gold {
  background: radial-gradient(circle at 40% 35%, #FFE7A0, var(--gold));
  top: 14%;
  left: -6px;
}

.eye-blue {
  background: radial-gradient(circle at 40% 35%, #BBE2FF, var(--blue));
  top: 14%;
  right: -6px;
}

.eyebrow {
  font-family: var(--font-latin);
  font-weight: 700;
  letter-spacing: .18em;
  color: #fff;
  margin: 0 0 10px;
  text-shadow: 0 2px 0 var(--blue), 0 0 14px rgba(61, 155, 232, .5);
}

.title {
  margin: 0 0 14px;
  line-height: 1.05;
}

.title-sub {
  display: block;
  font-family: var(--font-disp);
  font-size: clamp(15px, 2.2vw, 20px);
  color: var(--pink);
  text-shadow: 0 2px 0 #fff;
  margin-bottom: 4px;
}

.title-main {
  display: block;
  font-family: var(--font-disp);
  font-size: clamp(46px, 9vw, 92px);
  color: var(--gold);
  -webkit-text-stroke: 3px #fff;
  paint-order: stroke fill;
  text-shadow: 0 8px 0 rgba(255, 201, 60, .28), 0 10px 18px rgba(58, 86, 128, .22);
}

.catch {
  display: inline-block;
  font-family: var(--font-disp);
  font-size: clamp(15px, 2.4vw, 21px);
  color: var(--ink);
  background: #fff;
  padding: 12px 18px;
  border-radius: 18px;
  border: 4px solid var(--gold);
  box-shadow: var(--sticker-shadow);
  margin: 6px 0 18px;
  line-height: 1.5;
}

.lead {
  white-space: pre-line;
  max-width: 46ch;
  color: var(--ink);
  font-weight: 500;
  margin: 0 0 22px;
  background: rgba(255, 255, 255, .66);
  backdrop-filter: blur(2px);
  padding: 10px 14px;
  border-radius: 14px;
}

/* SNS：アイコン画像そのものをボタンに */
.socials {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.social {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 4px solid var(--line);
  border-radius: 999px;
  padding: 7px 16px 7px 7px;
  box-shadow: var(--sticker-shadow);
  font-family: var(--font-latin);
  font-weight: 600;
  color: var(--ink);
  transition: transform .18s cubic-bezier(.34, 1.56, .64, 1), box-shadow .18s;
}

.social:hover {
  transform: translateY(-4px) rotate(-2deg);
  box-shadow: 0 20px 32px rgba(58, 86, 128, .26);
}

.social:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

.social img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
}

.social .s-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  align-items: flex-start;
}

.social .s-label {
  font-size: .98rem;
}

.social .s-handle {
  font-size: .74rem;
  color: var(--ink-soft);
  font-family: var(--font-body);
  font-weight: 500;
}

.social.is-soon {
  opacity: .92;
}

.social.is-soon::after {
  content: "準備中";
  font-family: var(--font-body);
  font-size: .7rem;
  color: #fff;
  background: var(--pink);
  padding: 2px 8px;
  border-radius: 999px;
}

/* ---------- 固定の紹介カードゾーン（グリッド） ---------- */
.works {
  width: 100%;
}

.works-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.works-title {
  font-family: var(--font-disp);
  font-size: clamp(20px, 3.4vw, 30px);
  color: #fff;
  margin: 0;
  text-shadow: 0 3px 0 var(--pink), 0 6px 12px rgba(58, 86, 128, .25);
}

.works-hint {
  font-family: var(--font-latin);
  font-weight: 600;
  color: var(--ink);
  background: #fff;
  padding: 3px 12px;
  border-radius: 999px;
  margin: 0;
  box-shadow: 0 6px 14px rgba(58, 86, 128, .16);
}

.works-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: clamp(14px, 2.4vw, 22px);
}

.works-grid>li {
  list-style: none;
  display: flex;
  /* スクロール出現アニメ（ホバーと干渉しないよう li 側で行う） */
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .55s ease, transform .55s cubic-bezier(.22, 1, .36, 1);
}

.works-grid>li.in {
  opacity: 1;
  transform: none;
}

.works-grid>li:nth-child(2) {
  transition-delay: .06s;
}

.works-grid>li:nth-child(3) {
  transition-delay: .12s;
}

.works-grid>li:nth-child(4) {
  transition-delay: .18s;
}

.card {
  width: 100%;
  /* button を素のカード見た目にリセット */
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
  appearance: none;
  padding: 0;
  background: #fff;
  border: var(--sticker-border) solid var(--line);
  border-radius: var(--sticker-radius);
  box-shadow: var(--sticker-shadow);
  overflow: hidden;
  transition: transform .2s cubic-bezier(.34, 1.56, .64, 1), box-shadow .2s;
}

.card:hover {
  transform: translateY(-6px) rotate(-1deg);
  box-shadow: 0 22px 36px rgba(58, 86, 128, .28);
}

.card:focus-within {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

.card-media {
  position: relative;
  aspect-ratio: 4/3;
  background: #EAF6FF;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 22%;
}

.card-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  font-family: var(--font-latin);
  font-weight: 700;
  font-size: .72rem;
  color: #fff;
  padding: 3px 11px;
  border-radius: 999px;
  border: 2px solid #fff;
  box-shadow: 0 4px 10px rgba(58, 86, 128, .25);
}

.b-music {
  background: var(--purple);
}

.b-art {
  background: var(--pink);
}

.b-comic {
  background: var(--gold);
  color: var(--ink);
}

.b-movie {
  background: var(--blue);
}

/* キャラ／世界観カードのバッジ色 */
.b-gold {
  background: var(--gold);
  color: var(--ink);
}

.b-pink {
  background: var(--pink);
}

.b-blue {
  background: var(--blue);
}

.b-purple {
  background: var(--purple);
}

.card-body {
  padding: 13px 15px 16px;
}

.card-title {
  font-family: var(--font-disp);
  font-size: 1.02rem;
  margin: 0 0 3px;
  color: var(--ink);
}

.card-sub {
  font-family: var(--font-latin);
  font-weight: 600;
  font-size: .74rem;
  color: var(--ink-soft);
  margin: 0 0 7px;
}

.card-desc {
  font-size: .84rem;
  color: var(--ink-soft);
  margin: 0;
}

.card-soon,
.card-cta {
  font-size: .78rem;
  color: var(--pink);
  font-weight: 700;
  margin-top: 8px;
}

.card:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

/* ---- 作品ライトボックス（拡大／再生） ---- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.lightbox[hidden] {
  display: none;
}

.lb-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(58, 86, 128, .55);
  backdrop-filter: blur(4px);
}

.lb-panel {
  position: relative;
  z-index: 1;
  width: min(560px, 94vw);
  max-height: 90vh;
  overflow: auto;
  background: #fff;
  border: 6px solid #fff;
  border-radius: 28px;
  box-shadow: 0 30px 60px rgba(58, 86, 128, .4);
  animation: lbPop .25s cubic-bezier(.34, 1.56, .64, 1);
}

@keyframes lbPop {
  from {
    transform: scale(.92);
    opacity: 0;
  }

  to {
    transform: scale(1);
    opacity: 1;
  }
}

.lb-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 3px solid #fff;
  background: var(--gold);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(58, 86, 128, .3);
}

.lb-close:hover {
  background: var(--pink);
}

.lb-close:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.lb-media img {
  width: 100%;
  height: auto;
  display: block;
  background: #EAF6FF;
}

.lb-media iframe {
  width: 100%;
  aspect-ratio: 1/1;
  display: block;
  border: 0;
}

.lb-media audio {
  width: 100%;
  display: block;
  margin-top: 4px;
}

.lb-info {
  padding: 16px 20px 20px;
}

.lb-title {
  font-family: var(--font-disp);
  color: var(--ink);
  margin: 0 0 6px;
}

.lb-desc {
  color: var(--ink-soft);
  margin: 0 0 12px;
}

.lb-link {
  display: inline-block;
  font-family: var(--font-disp);
  font-size: .85rem;
  color: #fff;
  background: var(--blue);
  padding: 8px 16px;
  border-radius: 999px;
}

.lb-link[hidden] {
  display: none;
}

.lb-link:hover {
  background: var(--purple);
}

.lb-play {
  display: inline-block;
  font-family: var(--font-disp);
  font-size: .88rem;
  color: var(--ink);
  background: var(--gold);
  padding: 9px 18px;
  border-radius: 999px;
  border: 3px solid #fff;
  box-shadow: 0 6px 14px rgba(58, 86, 128, .22);
  cursor: pointer;
  margin: 0 8px 10px 0;
}

.lb-play[hidden] {
  display: none;
}

.lb-play:hover {
  background: var(--pink);
  color: #fff;
}

.lb-play:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

/* スクロール誘導 */
.scroll-cue {
  align-self: center;
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-latin);
  font-weight: 600;
  color: var(--ink);
  background: #fff;
  padding: 8px 18px;
  border-radius: 999px;
  box-shadow: var(--sticker-shadow);
}

.cue-arrow {
  animation: bob 1.6s ease-in-out infinite;
}

/* ---------- ぴよち業務議事録 ---------- */
.minutes {
  max-width: 820px;
  margin-inline: auto;
  padding: clamp(40px, 9vw, 110px) clamp(16px, 5vw, 40px) clamp(60px, 10vw, 120px);
}

.section-title {
  text-align: center;
  margin: 0 0 clamp(14px, 2.6vw, 20px);
}

.section-title span {
  font-family: var(--font-disp);
  font-size: clamp(24px, 5vw, 40px);
  color: var(--gold);
  -webkit-text-stroke: 3px #fff;
  paint-order: stroke fill;
  text-shadow: 0 6px 0 rgba(255, 201, 60, .25), 0 8px 16px rgba(58, 86, 128, .22);
}

.minutes-lead {
  text-align: center;
  max-width: 46ch;
  margin: 0 auto clamp(22px, 4vw, 34px);
  color: var(--ink);
  font-weight: 500;
  background: rgba(255, 255, 255, .7);
  backdrop-filter: blur(2px);
  padding: 10px 16px;
  border-radius: 14px;
}

/* ボード全体：出現アニメ */
.board {
  position: relative;
  opacity: 0;
  transform: translateY(34px);
  transition: opacity .6s ease, transform .6s cubic-bezier(.22, 1, .36, 1);
}

.board.in {
  opacity: 1;
  transform: none;
}

/* --- 見出しタブ（エピソード）--- */
.board-tabs {
  display: flex;
  gap: 8px;
  padding: 0 6px;
  overflow-x: auto;
  scrollbar-width: none;
  position: relative;
  z-index: 2;
}

.board-tabs::-webkit-scrollbar {
  display: none;
}

.board-tab {
  flex: 0 0 auto;
  max-width: 230px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  text-align: left;
  cursor: pointer;
  appearance: none;
  font: inherit;
  color: var(--ink-soft);
  background: #EAF3FB;
  border: 4px solid #fff;
  border-bottom: none;
  border-radius: 16px 16px 0 0;
  padding: 8px 16px 14px;
  margin-bottom: -8px;
  box-shadow: 0 -2px 10px rgba(58, 86, 128, .12);
  transition: transform .16s, background .16s, color .16s;
}

.board-tab:hover {
  transform: translateY(-2px);
}

.board-tab .tab-no {
  font-family: var(--font-disp);
  font-size: .74rem;
  letter-spacing: .02em;
  color: var(--blue);
}

.board-tab .tab-title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: .84rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.board-tab.is-active {
  background: #fff;
  color: var(--ink);
  transform: translateY(0);
  box-shadow: 0 -6px 14px rgba(58, 86, 128, .14);
}

.board-tab.is-active .tab-no {
  color: var(--pink);
}

.board-tab:nth-child(3n+2).is-active .tab-no {
  color: var(--purple);
}

.board-tab:nth-child(3n+3).is-active .tab-no {
  color: var(--gold);
}

.board-tab:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

/* --- 議事録のページ（白い紙）--- */
.board-paper {
  position: relative;
  z-index: 1;
  background:
    linear-gradient(180deg, #ffffff 0%, #FBFDFF 100%);
  border: var(--sticker-border) solid var(--line);
  border-radius: 6px 22px 22px 22px;
  box-shadow: var(--sticker-shadow);
  padding: clamp(30px, 5vw, 40px) clamp(20px, 4vw, 34px) clamp(16px, 3vw, 22px) clamp(34px, 6vw, 56px);
  min-height: clamp(360px, 52vw, 420px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* クリップ（上部中央） */
.paper-clip {
  position: absolute;
  top: -22px;
  left: 50%;
  transform: translateX(-50%) rotate(8deg);
  width: 24px;
  height: 54px;
  border-radius: 13px;
  border: 5px solid var(--gold);
  background: transparent;
  box-shadow: 0 4px 8px rgba(58, 86, 128, .2);
}

.paper-clip::after {
  content: "";
  position: absolute;
  inset: 5px 5px auto 5px;
  height: 28px;
  border: 4px solid var(--gold);
  border-radius: 9px 9px 0 0;
  border-bottom: none;
}

/* リング（左の綴じ） */
.paper-rings {
  position: absolute;
  left: 10px;
  top: 24px;
  bottom: 24px;
  width: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.paper-rings i {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 3px solid #CFE3F4;
  background: #fff;
  box-shadow: inset 0 2px 3px rgba(58, 86, 128, .12);
}

.paper-head {
  position: relative;
  border-bottom: 3px dashed #DCEAF6;
  padding-bottom: 12px;
  margin-bottom: 14px;
}

.paper-stamp {
  position: absolute;
  top: -4px;
  right: -2px;
  transform: rotate(9deg);
  font-family: var(--font-disp);
  font-size: .74rem;
  color: #E8607F;
  border: 2.5px solid #E8607F;
  border-radius: 8px;
  padding: 3px 9px;
  opacity: .9;
}

.paper-case {
  font-family: var(--font-disp);
  font-size: clamp(17px, 3.2vw, 24px);
  color: var(--ink);
  margin: 0 80px 4px 0;
  line-height: 1.4;
}

.paper-date {
  font-family: var(--font-latin);
  font-weight: 600;
  font-size: .82rem;
  color: var(--ink-soft);
  margin: 0;
}

/* 本文（イラスト＋議事録） */
.paper-body {
  flex: 1;
  display: flex;
  gap: clamp(16px, 3vw, 26px);
  flex-wrap: wrap;
  align-content: flex-start;
}

.page-illust {
  flex: 1 1 240px;
  margin: 0;
  min-width: 0;
}

.page-illust img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  border: 4px solid #fff;
  box-shadow: 0 10px 22px rgba(58, 86, 128, .2);
  background: #EAF6FF;
}

.page-doc {
  flex: 1 1 260px;
  min-width: 0;
}

.page-label {
  display: inline-block;
  font-family: var(--font-disp);
  font-size: .78rem;
  color: #fff;
  background: var(--blue);
  padding: 4px 14px;
  border-radius: 999px;
  border: 3px solid #fff;
  box-shadow: 0 5px 12px rgba(58, 86, 128, .2);
  margin-bottom: 12px;
}

.kind-debate .page-label {
  background: var(--pink);
}

.kind-verdict .page-label {
  background: var(--gold);
  color: var(--ink);
}

.page-heading {
  font-family: var(--font-disp);
  font-size: clamp(16px, 2.8vw, 21px);
  color: var(--ink);
  margin: 0 0 10px;
  line-height: 1.5;
}

.page-text {
  margin: 0;
  color: var(--ink);
  font-weight: 500;
}

/* ページめくりアニメ */
@keyframes pageTurn {
  0% {
    opacity: 0;
    transform: translateX(26px) rotateY(-9deg);
  }

  100% {
    opacity: 1;
    transform: none;
  }
}

.paper-body.flip {
  animation: pageTurn .42s cubic-bezier(.22, 1, .36, 1);
  transform-origin: left center;
}

/* 紙のフッター（ページ送り） */
.paper-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 3px dashed #DCEAF6;
}

.page-btn {
  font-family: var(--font-disp);
  font-size: .92rem;
  color: var(--ink);
  cursor: pointer;
  background: var(--gold);
  border: 4px solid #fff;
  border-radius: 999px;
  padding: 8px 18px;
  box-shadow: var(--sticker-shadow);
  transition: transform .15s, background .15s, opacity .15s;
}

.page-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  background: var(--pink);
  color: #fff;
}

.page-btn:disabled {
  opacity: .4;
  cursor: default;
}

.page-btn:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 2px;
}

.page-count {
  font-family: var(--font-latin);
  font-weight: 600;
  color: var(--ink-soft);
  font-size: .9rem;
}

/* ---------- フッター ---------- */
.foot {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: clamp(40px, 8vw, 80px) 20px clamp(150px, 26vw, 180px);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, .78) 60%);
}

.foot-note {
  font-family: var(--font-latin);
  color: var(--ink-soft);
  font-size: .85rem;
  margin: 0;
}

/* =====================================================================
 *  歌を再生ウィジェット（最初は大きく → 数秒で左下に常設）
 * ===================================================================== */
.song {
  position: fixed;
  z-index: 40;
  left: clamp(14px, 3vw, 28px);
  bottom: clamp(14px, 3vw, 26px);
  display: flex;
  align-items: center;
  gap: 8px;
  /* ボタンの大きさ（画面のおよそ1/8の存在感） */
  --song-thumb: clamp(74px, 12vw, 104px);
}

.song[hidden] {
  display: none;
}

.song-main {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  font: inherit;
  color: var(--ink);
  cursor: pointer;
  appearance: none;
  background: #fff;
  border: 5px solid var(--line);
  border-radius: 999px;
  padding: 8px 24px 8px 8px;
  box-shadow: var(--sticker-shadow);
  transition: padding .35s cubic-bezier(.22, 1, .36, 1), gap .35s, transform .18s, box-shadow .18s;
}

.song-main:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 36px rgba(58, 86, 128, .28);
}

.song-main:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

/* サムネ＋中央の再生/イコライザ */
.song-thumb {
  position: relative;
  flex: none;
  width: var(--song-thumb);
  height: var(--song-thumb);
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid #fff;
  box-shadow: 0 5px 14px rgba(58, 86, 128, .24);
  background: #EAF6FF;
}

.song-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.song-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(58, 86, 128, .34);
  color: #fff;
}

.song-icon {
  font-size: clamp(1.3rem, 3.4vw, 1.9rem);
  line-height: 1;
  transform: translateX(2px);
  filter: drop-shadow(0 2px 4px rgba(58, 86, 128, .5));
}

.song-eq {
  display: none;
  align-items: flex-end;
  gap: 3px;
  height: clamp(22px, 5vw, 30px);
}

.song-eq i {
  width: 5px;
  height: 8px;
  background: #fff;
  border-radius: 3px;
  animation: eq .9s ease-in-out infinite;
  box-shadow: 0 0 6px rgba(255, 255, 255, .6);
}

.song-eq i:nth-child(2) {
  animation-delay: .18s;
}

.song-eq i:nth-child(3) {
  animation-delay: .36s;
}

.song-eq i:nth-child(4) {
  animation-delay: .54s;
}

@keyframes eq {

  0%,
  100% {
    height: 7px;
  }

  50% {
    height: 100%;
  }
}

.song.is-playing .song-eq {
  display: flex;
}

.song.is-playing .song-icon {
  display: none;
}

/* テキスト（大きい状態だけ表示） */
.song-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  max-width: 220px;
  overflow: hidden;
  white-space: nowrap;
  transition: max-width .35s cubic-bezier(.22, 1, .36, 1), opacity .25s, margin .35s;
}

.song-q {
  font-family: var(--font-disp);
  font-size: clamp(1rem, 2.6vw, 1.18rem);
  color: var(--ink);
}

.song-rec {
  font-family: var(--font-disp);
  font-size: clamp(.8rem, 2vw, .92rem);
  color: var(--pink);
}

/* もっと聴くリンク */
.song-more {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  border: 3px solid #fff;
  box-shadow: var(--sticker-shadow);
  font-weight: 700;
  font-size: 1.05rem;
  transition: transform .15s, max-width .3s, opacity .25s;
}

.song-more:hover {
  transform: translateY(-3px) rotate(8deg);
  background: var(--purple);
}

.song-more:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

/* 音量調節バー（常設＝ミニ状態のときだけ表示） */
.song-vol {
  display: none;
  align-items: center;
  gap: 9px;
  background: #fff;
  border: 4px solid var(--line);
  border-radius: 999px;
  padding: 6px 16px 6px 9px;
  box-shadow: var(--sticker-shadow);
}

.song[data-state="mini"] .song-vol {
  display: flex;
}

.vol-mute {
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
  background: #EAF6FF;
  cursor: pointer;
  font-size: .95rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .15s, background .15s;
}

.vol-mute:hover {
  transform: scale(1.1);
  background: #D9EEFC;
}

.vol-mute:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

.vol-range {
  -webkit-appearance: none;
  appearance: none;
  width: clamp(74px, 14vw, 120px);
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--blue) 0%, #BBE2FF 100%);
  outline: none;
  cursor: pointer;
}

.vol-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--gold);
  border: 3px solid #fff;
  box-shadow: 0 3px 8px rgba(58, 86, 128, .3);
  cursor: pointer;
}

.vol-range::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--gold);
  border: 3px solid #fff;
  box-shadow: 0 3px 8px rgba(58, 86, 128, .3);
  cursor: pointer;
}

.vol-range:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

/* --- 大きい状態：注目アニメ --- */
/* 登場：右からビューン → ぷるぷる揺れて注目させる */
.song[data-state="big"] .song-main {
  animation:
    songFlyIn 2s cubic-bezier(.16, .72, .18, 1) both,
    songWiggle 1.25s ease-in-out 2s 3;
}

@keyframes songFlyIn {
  0% {
    transform: translateX(115vw) rotate(18deg);
    opacity: 0;
  }

  55% {
    transform: translateX(-16px) rotate(-6deg);
    opacity: 1;
  }

  72% {
    transform: translateX(9px) rotate(4deg);
  }

  86% {
    transform: translateX(-5px) rotate(-2deg);
  }

  100% {
    transform: translateX(0) rotate(0);
    opacity: 1;
  }
}

@keyframes songWiggle {

  0%,
  100% {
    transform: rotate(0) translateY(0);
  }

  14% {
    transform: rotate(-6deg) translateY(-4px);
  }

  30% {
    transform: rotate(5deg) translateY(0);
  }

  46% {
    transform: rotate(-4deg) translateY(-2px);
  }

  62% {
    transform: rotate(3deg) translateY(0);
  }

  80% {
    transform: rotate(-1.5deg) translateY(-1px);
  }
}

/* --- 常設（ミニ）状態：丸ボタンだけ残す --- */
.song[data-state="mini"] .song-main {
  padding: 6px;
  gap: 0;
}

.song[data-state="mini"] .song-text {
  max-width: 0;
  opacity: 0;
  margin: 0;
}

.song[data-state="mini"] .song-more {
  max-width: 0;
  width: 0;
  padding: 0;
  border-width: 0;
  opacity: 0;
  overflow: hidden;
}

/* =====================================================================
 *  レスポンシブ
 * ===================================================================== */
@media (max-width:780px) {
  .hero-inner {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .hero-copy {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .lead {
    text-align: left;
  }

  .socials {
    justify-content: center;
  }

  /* 常駐キャラはモバイルでは小さく薄く、文字の邪魔をしない */
  .resident {
    width: 54vw;
    right: -46px;
    bottom: -20px;
    opacity: .5;
  }

  .works-head {
    justify-content: center;
  }

  /* タブはモバイルでは少し詰める */
  .board-tab {
    max-width: 160px;
    padding: 7px 12px 13px;
  }

  /* 大きい歌ボタンが画面端からはみ出さないように */
  .song[data-state="big"] .song-text {
    max-width: 150px;
  }

  .song-q {
    font-size: .84rem;
  }
}

@media (max-width:480px) {
  .resident {
    opacity: .34;
  }

  /* 議事録の本文はモバイルでは縦積み（イラスト→文章） */
  .paper-body {
    flex-direction: column;
  }
}

/* キーボード操作の可視フォーカス */
:focus-visible {
  outline-offset: 3px;
}

/* モーション控えめ設定を尊重 */
@media (prefers-reduced-motion:reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }

  html {
    scroll-behavior: auto;
  }

  .works-grid>li {
    opacity: 1;
    transform: none;
  }

  .board {
    opacity: 1;
    transform: none;
  }
}