/* 光の余韻 V20 — 動き（登場・区切り・反応）
   方針: 全文は最初から存在し、透明度と16pxの移動だけで現れる。ループなし。
   停止: html[data-motion="off"]（サイト内ボタン）と OS の「動きを減らす」で静止。 */

/* 冒頭の静かな登場（見出し→本文→扉の順） */
html.js:not([data-motion="off"]) .rv-hero{opacity:0;transform:translateY(16px);animation:v20-rise .7s cubic-bezier(.2,.7,.2,1) forwards}
html.js:not([data-motion="off"]) .hero-copy .rv-hero:nth-child(1){animation-delay:.05s}
html.js:not([data-motion="off"]) .hero-copy .rv-hero:nth-child(2){animation-delay:.18s}
html.js:not([data-motion="off"]) .hero-copy .rv-hero:nth-child(3){animation-delay:.32s}
html.js:not([data-motion="off"]) .hero-copy .rv-hero:nth-child(4){animation-delay:.46s}
html.js:not([data-motion="off"]) .hero-copy .rv-hero:nth-child(5){animation-delay:.58s}
html.js:not([data-motion="off"]) .hero-stage.rv-hero,html.js:not([data-motion="off"]) .hero-photo.rv-hero{animation-delay:.3s;animation-duration:1s}
html.js:not([data-motion="off"]) .hero-text .rv-hero:nth-child(4){animation-delay:.46s}
@keyframes v20-rise{to{opacity:1;transform:none}}
/* 保険: 何らかの理由で登場が完了しなくても 1.6 秒後には必ず見える */
html.hero-done .rv-hero{opacity:1!important;transform:none!important;animation:none!important}

/* スクロールで区切りが淡く現れる（1回だけ） */
html.js:not([data-motion="off"]) .rv{opacity:0;transform:translateY(16px);transition:opacity .7s cubic-bezier(.2,.7,.2,1),transform .7s cubic-bezier(.2,.7,.2,1)}
html.js:not([data-motion="off"]) .rv.is-in{opacity:1;transform:none}
html.js:not([data-motion="off"]) .steps .rv:nth-child(2),html.js:not([data-motion="off"]) .tiles .rv:nth-child(2),html.js:not([data-motion="off"]) .plans .rv:nth-child(2){transition-delay:.1s}
html.js:not([data-motion="off"]) .steps .rv:nth-child(3),html.js:not([data-motion="off"]) .tiles .rv:nth-child(3),html.js:not([data-motion="off"]) .plans .rv:nth-child(3){transition-delay:.2s}
html.js:not([data-motion="off"]) .steps .rv:nth-child(4),html.js:not([data-motion="off"]) .tiles .rv:nth-child(4){transition-delay:.3s}
html.js:not([data-motion="off"]) .doors .rv:nth-child(2){transition-delay:.15s}

/* アイコンの順番の登場（タイムライン・タイル・箇条書き） */
html.js:not([data-motion="off"]) .tl-steps li,html.js:not([data-motion="off"]) .ipoints li{opacity:0;transform:translateY(10px);transition:opacity .5s ease,transform .5s ease}
html.js:not([data-motion="off"]) .is-in .tl-steps li,html.js:not([data-motion="off"]) .is-in .ipoints li,html.js:not([data-motion="off"]) .panel .ipoints li,html.js:not([data-motion="off"]) .hero-facts li{opacity:1;transform:none}
html.js:not([data-motion="off"]) .tl-steps li:nth-child(2),html.js:not([data-motion="off"]) .ipoints li:nth-child(2){transition-delay:.15s}
html.js:not([data-motion="off"]) .tl-steps li:nth-child(3),html.js:not([data-motion="off"]) .ipoints li:nth-child(3){transition-delay:.3s}
html.js:not([data-motion="off"]) .tl-steps li:nth-child(4),html.js:not([data-motion="off"]) .ipoints li:nth-child(4){transition-delay:.45s}
html.js:not([data-motion="off"]) .is-in .tl-ico,html.js:not([data-motion="off"]) .is-in .tile-icon,html.js:not([data-motion="off"]) .is-in .ip-ico{animation:v20-pop .6s cubic-bezier(.2,.7,.2,1) both}
@keyframes v20-pop{from{transform:scale(.6)}to{transform:scale(1)}}
html[data-motion="off"] .tl-steps li,html[data-motion="off"] .ipoints li{opacity:1!important;transform:none!important}

/* 動きを止めたとき: 位置も透明度も通常表示へ */
html[data-motion="off"] .rv,html[data-motion="off"] .rv-hero{opacity:1!important;transform:none!important;animation:none!important;transition:none!important}
html[data-motion="off"] *{transition-duration:0s!important;animation-duration:0s!important}
html[data-motion="off"] .scene{transition:none}
html[data-motion="off"] .door:hover,html[data-motion="off"] .tile:hover,html[data-motion="off"] .plan:hover{transform:none}

/* OS の「動きを減らす」設定 */
@media (prefers-reduced-motion:reduce){
  .tl-steps li,.ipoints li{opacity:1!important;transform:none!important}.tl-line path,.flow-arrow path{stroke-dashoffset:0!important}.tl-bar-fill{width:100%!important}.ring-dash,.route-dash{animation:none!important}
  .rv,.rv-hero{opacity:1!important;transform:none!important;animation:none!important;transition:none!important}
  *{transition-duration:0s!important;animation-duration:0s!important;scroll-behavior:auto!important}
  html{scroll-behavior:auto}
  .door:hover,.tile:hover,.plan:hover,.window:hover,.cross:hover,.chip:hover{transform:none}
  .door-photo img{transition:none}
}

/* ========== 第3版: 仕立ての動き ========== */
/* 現れ方: 透明度＋16px（ぼかしは重いので使わない） */
html.js:not([data-motion="off"]) .rv{transition:opacity .9s cubic-bezier(.2,.7,.2,1),transform .9s cubic-bezier(.2,.7,.2,1)}
/* 光の揺らぎ（ヒーロー背景・30秒でゆっくり） */
html.js:not([data-motion="off"]) .hero::before{animation:v20-drift 30s ease-in-out infinite alternate}
@keyframes v20-drift{from{transform:translate(0,0) scale(1)}to{transform:translate(-6%,-8%) scale(1.08)}}
/* 写真: 表示中の1枚がごくゆっくり寄る */
html.js:not([data-motion="off"]) .scene.is-active img{animation:v20-kenburns 12s ease-out forwards}
@keyframes v20-kenburns{from{transform:scale(1)}to{transform:scale(1.05)}}
html.js:not([data-motion="off"]) .hero-photo img{animation:v20-kenburns 14s ease-out forwards}
/* 扉: 写真の寄りと文字の持ち上がり */
.door h3,.door>.door-body>p,.door .btn{transition:transform .5s cubic-bezier(.2,.7,.2,1)}
.door:hover h3{transform:translateY(-2px)}
@media (prefers-reduced-motion:reduce){.hero::before,.scene img,.hero-photo img{animation:none!important}}

/* ========== 第4版の動き ========== */
/* 行ごとの立ち上がり: ヒーローは読み込み時、節見出しは現れたとき */
html.js:not([data-motion="off"]) h1 .ln>span{transform:translateY(110%);animation:v20-line .9s cubic-bezier(.2,.7,.2,1) forwards}
html.js:not([data-motion="off"]) h1 .ln:nth-child(2)>span{animation-delay:.12s}
html.js:not([data-motion="off"]) h1 .ln:nth-child(3)>span{animation-delay:.24s}
@keyframes v20-line{to{transform:none}}
html.hero-done h1 .ln>span,html[data-motion="off"] h1 .ln>span{transform:none!important;animation:none!important}
/* 写真のワイプ（現れたとき1回だけ） */
html.js:not([data-motion="off"]) .rv .split-photo img,html.js:not([data-motion="off"]) .split-photo.rv img,html.js:not([data-motion="off"]) .door.rv .door-photo img,html.js:not([data-motion="off"]) .gallery.rv img{clip-path:inset(0 100% 0 0);transform:scale(1.08);transition:clip-path 1.1s cubic-bezier(.2,.7,.2,1),transform 1.4s cubic-bezier(.2,.7,.2,1)}
html.js:not([data-motion="off"]) .rv.is-in .split-photo img,html.js:not([data-motion="off"]) .split-photo.rv.is-in img,html.js:not([data-motion="off"]) .door.rv.is-in .door-photo img,html.js:not([data-motion="off"]) .gallery.rv.is-in img{clip-path:inset(0 0 0 0);transform:scale(1)}
html.js:not([data-motion="off"]) .gallery.rv.is-in figure:nth-child(2) img{transition-delay:.12s}
html.js:not([data-motion="off"]) .gallery.rv.is-in figure:nth-child(3) img{transition-delay:.24s}
html.js:not([data-motion="off"]) .gallery.rv.is-in figure:nth-child(4) img{transition-delay:.36s}
html.js:not([data-motion="off"]) .door.rv.is-in:hover .door-photo img{transform:scale(1.04)}
/* 写真の視差（CSSのみ・対応ブラウザーだけ・スクロールに応じて上下に数%） */
@supports (animation-timeline: view()){
  html.js:not([data-motion="off"]) .split-photo.is-in img,html.js:not([data-motion="off"]) .rv.is-in .split-photo img,html.js:not([data-motion="off"]) .panel-photo img{animation:v20-parallax linear both;animation-timeline:view();animation-range:entry 0% exit 100%;transform:none;clip-path:none;transition:none}
  html.js:not([data-motion="off"]) .split-photo.is-in,html.js:not([data-motion="off"]) .panel-photo{overflow:hidden}
  html.js:not([data-motion="off"]) .split-photo.is-in img,html.js:not([data-motion="off"]) .rv.is-in .split-photo img{height:112%;margin-top:-6%}
}
@keyframes v20-parallax{from{translate:0 -4%}to{translate:0 4%}}
/* タグラインの帯: ゆっくり流れ、ホバーで止まる */
html.js:not([data-motion="off"]) .ticker-track{animation:v20-ticker 48s linear infinite}
.ticker:hover .ticker-track{animation-play-state:paused}
@keyframes v20-ticker{to{transform:translateX(-50%)}}
/* ページ遷移の短いフェード */
html.js:not([data-motion="off"]) body{animation:v20-page-in .6s ease both}
@keyframes v20-page-in{from{opacity:0}to{opacity:1}}
html.js:not([data-motion="off"]) body.is-leaving{opacity:0;transition:opacity .22s ease}
@media (prefers-reduced-motion:reduce){
  h1 .ln>span{transform:none!important;animation:none!important}
  .split-photo img,.door-photo img,.gallery img,.panel-photo img{clip-path:none!important;transform:none!important;animation:none!important;transition:none!important;height:auto!important;margin:0!important}
  .ticker-track{animation:none!important}
  body{animation:none!important}
}
html[data-motion="off"] .split-photo img,html[data-motion="off"] .door-photo img,html[data-motion="off"] .gallery img,html[data-motion="off"] .panel-photo img{clip-path:none!important;transform:none!important;animation:none!important;height:auto!important;margin:0!important}
html[data-motion="off"] .ticker-track{animation:none!important}
/* 下層の冒頭: 写真は左から拭われ、見出しの板は行ごとに立ち上がる */
html.js:not([data-motion="off"]) .hero-v2-photo img{clip-path:inset(0 0 0 100%);animation:v20-wipe-in 1.2s cubic-bezier(.2,.7,.2,1) .15s forwards,v20-kenburns 14s ease-out 1.2s forwards}
@keyframes v20-wipe-in{to{clip-path:inset(0 0 0 0)}}
html.hero-done .hero-v2-photo img,html[data-motion="off"] .hero-v2-photo img{clip-path:none!important}
@media (prefers-reduced-motion:reduce){.hero-v2-photo img{clip-path:none!important;animation:none!important}}
