/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   Fortune Result
   見た目はほぼ Tailwind のクラスで書き、ここには Tailwind で書きにくいものだけを置く
   ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

/* ─── 品種の写真の輪 ───
   --v-color (品種) と --vc-color (相性品種) はテンプレートの <style> が入れる。
   白い隙間をはさんで品種の色の輪にする (占いのページのおかえりバナーと同じ形) */
.fr-variety-img {
  box-shadow: 0 0 0 4px #fff, 0 0 0 6px var(--v-color, #e11d48);
}
.fr-companion-img {
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--vc-color, #e11d48);
}
/* ほかの品種の一覧で、今の品種の輪を品種の色にする (ring-2 ring-offset-2 と一緒に使う) */
.fr-current-ring {
  --tw-ring-color: var(--v-color, #e11d48);
}

/* ─── 総合運の星が順に出る ───
   登場の動きは、キーフレームの from (始まりの状態) だけを決め、backwards で
   animation-delay の間も from の状態にする。終わったあとは要素自身のスタイルに戻る。
   要素に opacity:0 を置いて forwards で最後の opacity:1 / transform を保つ書き方だと、
   同じ要素の opacity-* や hover:-translate-* が打ち消される (総合運の足りない分の星が
   薄くならず、どの点数でも 5 つとも満ちて見えていた。#272)。fortune-index.css も同じ。 */
.fr-star {
  display: inline-block;
  animation: frStarPop 0.45s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}
.fr-star:nth-child(1) { animation-delay: 0.10s; }
.fr-star:nth-child(2) { animation-delay: 0.18s; }
.fr-star:nth-child(3) { animation-delay: 0.26s; }
.fr-star:nth-child(4) { animation-delay: 0.34s; }
.fr-star:nth-child(5) { animation-delay: 0.42s; }

@keyframes frStarPop {
  from { opacity: 0; transform: scale(0.6); }
}

/* ─── Reduced motion ───
   登場の動きは要素自身のスタイルを変えないので、止めるだけで表示される。 */
@media (prefers-reduced-motion: reduce) {
  .fr-star {
    animation: none;
  }
}
