/* 風の表現(index.html と見比べ用 wind-ref.html、2026-11-20 本人が採用)
   F = 大気社採用:水色→薄紫へにじむ背景で、空気が広がる(理念の区画だけ)
   G = 新成空調:水色の細線の束が、区画の境目を右から左へ流れ続ける
   最初の画面には何も足さない(本人)。白い曲線(fuuring)は外した(本人) */
html, body { overflow-x: clip; }

/* ---------- F:にじむ背景(理念) ---------- */
.w-air { display: none; position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.w-f .w-air {
  display: block;
  /* 上下の端は白へ溶け込ませ、前後の区画(白)との境目で色が切り替わらないようにする(2026-11-20 本人) */
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 22%, #000 78%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 22%, #000 78%, transparent 100%);
}
.w-air i {
  position: absolute; border-radius: 50%; filter: blur(70px);
  animation: w-drift 22s var(--ease-in-out) infinite alternate;
}
.w-air i:nth-child(1) { left: -12%; top: -25%; width: 56%; height: 85%; background: #d9eff9; animation-duration: 24s; }
.w-air i:nth-child(2) { right: -12%; top: 5%; width: 50%; height: 80%; background: #e9e4f9; animation-duration: 28s; animation-delay: -6s; }
.w-air i:nth-child(3) { left: 22%; bottom: -35%; width: 52%; height: 75%; background: #e0f0fa; animation-duration: 20s; animation-delay: -12s; }
.w-air i:nth-child(4) { left: 58%; bottom: -25%; width: 40%; height: 60%; background: #f0ecfb; animation-duration: 26s; animation-delay: -3s; }
.w-air i:nth-child(5) { left: 30%; top: 22%; width: 40%; height: 44%; background: #ffffff; animation-duration: 18s; animation-delay: -9s; }
@keyframes w-drift { from { transform: translate3d(3%, -2%, 0) scale(1); } to { transform: translate3d(-4%, 3%, 0) scale(1.08); } }

/* 元の水彩の代わりに置く(背景→言葉の順に浮かぶ流れは同じ) */
.w-f .about-wash { display: none; }
.js .w-air-about { opacity: 0; transition: opacity 900ms var(--ease-out); }
.about.is-blown .w-air-about { opacity: 1; }
.about-in { z-index: 1; }

/* ---------- G:流れる細線の束(区画の境目) ---------- */
.w-seam { display: none; position: relative; height: 0; pointer-events: none; }
.w-g .w-seam { display: block; }
.w-seam-1 { z-index: 4; }
.w-seam-2 { z-index: 0; }
.w-g .news { position: relative; z-index: 1; }
/* 枠:画面幅で切り取る。中の線は2周ぶんの幅があり、半分だけ左へ送って繰り返す(つなぎ目なし) */
.w-bundle { position: absolute; left: 0; right: 0; overflow: hidden; }
.w-seam-1 .w-bundle { top: -20px; height: 260px; }   /* 最初の画面の写真にかからないよう、理念側に置く */
.w-seam-2 .w-bundle { top: -70px; height: 200px; }
.w-bundle svg {
  display: block; width: 200%; height: 100%;
  /* 一定の速さで流れ続ける動きは linear(Emil Kowalski の基準)。風の向きは写真の流れと同じ右→左 */
  animation: w-flow 60s linear infinite;
}
.w-seam-2 .w-bundle svg { animation-duration: 75s; }
@keyframes w-flow { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-50%, 0, 0); } }

/* 画面に入ったとき、右から描き出す(1回だけ) */
.js .w-bundle { clip-path: inset(0 0 0 100%); transition: clip-path 1800ms var(--ease-out); }
.js .w-bundle.is-drawn { clip-path: inset(0 0 0 0); }

/* ---------- 見比べ用の切り替え(本番には入れない) ---------- */
.w-panel {
  position: fixed; left: 16px; bottom: 16px; z-index: 30;
  display: flex; flex-direction: column; gap: 2px; padding: 12px 16px;
  background: var(--paper); color: var(--kifu-navy); font-size: 14px; line-height: 1.6;
  border: 1px solid #c9d3de; border-radius: 12px;
}
.w-panel summary { font-weight: 700; cursor: pointer; min-height: 32px; display: flex; align-items: center; }
.w-panel form { display: flex; flex-direction: column; gap: 2px; margin-top: 4px; }
.w-panel label { display: flex; align-items: center; gap: 8px; cursor: pointer; min-height: 32px; }
.w-panel input { width: 18px; height: 18px; accent-color: var(--kifu-navy); }

@media (max-width: 900px) {
  .w-seam-1 .w-bundle { top: -10px; height: 180px; }
  .w-seam-2 .w-bundle { top: -50px; height: 150px; }
  /* スマホは画面が狭いので、線の形が詰まりすぎないよう1周を画面3つぶんに */
  .w-bundle svg { width: 600%; animation-duration: 90s; }
  .w-seam-2 .w-bundle svg { animation-duration: 110s; }
  .w-panel { font-size: 13px; padding: 8px 12px; left: 8px; bottom: 8px; }
  .w-air i { filter: blur(48px); }
}

@media (prefers-reduced-motion: reduce) {
  .w-air i, .w-bundle svg { animation: none; }
  .js .w-bundle { clip-path: none; transition: none; }
}
