/* rite-art.css — 「我们」的三个打卡图标、两个人都点亮时屏幕上的一段、状态图标（11＋，10-17 主人定 v4；画法在 js/rite-art.js）。
   动画时长都是 2.4 秒；减少动态效果时 base.css 的 .reduce-motion 和下面的系统设置把它们压掉（屏幕上那一段另有 .ra-rm：只淡入淡出合成后的画面）。 */

/* ---------- 打卡图标：谁做了谁那一半亮；两个人都做了就整只亮 ---------- */
.ra-rb { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; color: var(--muted); }
.ra-rb .ra-ri { position: relative; z-index: 2; width: 34px; height: 34px; overflow: visible; }
.ra-fl, .ra-fr { opacity: 0; transition: opacity .4s; }
.ra-ln { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; transition: stroke .4s; }
.ra-seam { stroke: currentColor; stroke-width: 1; stroke-dasharray: 1.5 2.5; opacity: 0; transition: opacity .4s; }
.ra-rb.is-me .ra-fl, .ra-rb.is-ta .ra-fr, .ra-rb.is-both .ra-fl, .ra-rb.is-both .ra-fr { opacity: 1; }
.ra-rb.is-me, .ra-rb.is-ta, .ra-rb.is-both { color: var(--ra-ln); }
.ra-rb.is-me .ra-seam, .ra-rb.is-ta .ra-seam { opacity: .55; }
.ra-rb.is-both .ra-ri { filter: drop-shadow(0 0 5px var(--ra-glow)); }
.ra-glow, .ra-ring, .ra-pt { position: absolute; left: 50%; top: 50%; pointer-events: none; opacity: 0; }
.ra-glow { z-index: 1; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; background: radial-gradient(circle, var(--ra-glow) 0%, transparent 70%); }
.ra-ring { z-index: 1; width: 40px; height: 40px; margin: -20px 0 0 -20px; border-radius: 50%; box-shadow: 0 0 0 1.2px var(--ra-ln); }
.ra-pt { z-index: 3; width: 8px; height: 8px; margin: -4px 0 0 -4px; color: var(--ra-pt); }
.ra-pt svg { display: block; width: 8px; height: 8px; }
.ra-p1 { --x: 8px; --y: -30px; } .ra-p2 { --x: -16px; --y: -30px; } .ra-p3 { --x: 15px; --y: -36px; } .ra-p4 { --x: -3px; --y: -42px; } .ra-p5 { --x: 22px; --y: -16px; }
/* 两个人刚都点亮：两半往中间一合、轻轻一跳，一团光涨开、一道细圈散开，几颗小星 / 小心 / 光点往上飘 */
.ra-burst .ra-ri { animation: raJoin 2.4s cubic-bezier(.2, .8, .2, 1) both; }
.ra-burst .ra-fl { animation: raHalfL 2.4s cubic-bezier(.2, .8, .2, 1) both; }
.ra-burst .ra-fr { animation: raHalfR 2.4s cubic-bezier(.2, .8, .2, 1) both; }
.ra-burst.ra-v .ra-fl { animation-name: raHalfT; }
.ra-burst.ra-v .ra-fr { animation-name: raHalfB; }
.ra-burst .ra-glow, .ra-pop .ra-glow { animation: raGlow 2.4s ease-out both; }
.ra-burst .ra-ring { animation: raRing 2.4s ease-out both; }
.ra-burst .ra-pt, .ra-pop .ra-pt { animation: raRise 2.4s ease-out both; }
.ra-burst .ra-p2, .ra-pop .ra-p2 { animation-delay: .12s; } .ra-burst .ra-p3, .ra-pop .ra-p3 { animation-delay: .2s; }
.ra-burst .ra-p4, .ra-pop .ra-p4 { animation-delay: .32s; } .ra-burst .ra-p5, .ra-pop .ra-p5 { animation-delay: .4s; }
/* 我刚点亮自己那一半：图标里小小地闪一下（屏幕上不演） */
.ra-pop .ra-ri { animation: raJoin 2.4s cubic-bezier(.2, .8, .2, 1) both; }
.ra-pop.is-me .ra-fl, .ra-pop.is-ta .ra-fr { animation: raFill 2.4s ease-out both; }
@keyframes raJoin { 0% { transform: scale(1); } 20% { transform: scale(1.16); } 42% { transform: scale(.96); } 60% { transform: scale(1.03); } 100% { transform: scale(1); } }
@keyframes raHalfL { 0% { transform: translateX(-2.5px); } 20%, 100% { transform: none; } }
@keyframes raHalfR { 0% { transform: translateX(2.5px); opacity: 0; } 12% { opacity: 1; } 20%, 100% { transform: none; opacity: 1; } }
@keyframes raHalfT { 0% { transform: translateY(-2.5px); } 20%, 100% { transform: none; } }
@keyframes raHalfB { 0% { transform: translateY(2.5px); opacity: 0; } 12% { opacity: 1; } 20%, 100% { transform: none; opacity: 1; } }
@keyframes raFill { 0%, 12% { opacity: 0; } 40%, 100% { opacity: 1; } }
@keyframes raGlow { 0% { opacity: 0; transform: scale(.4); } 25% { opacity: 1; transform: scale(1.1); } 60% { opacity: .55; transform: scale(1.35); } 100% { opacity: 0; transform: scale(1.6); } }
@keyframes raRing { 0%, 12% { opacity: 0; transform: scale(.6); } 22% { opacity: .9; } 70%, 100% { opacity: 0; transform: scale(1.9); } }
@keyframes raRise { 0%, 14% { opacity: 0; transform: translate(0, 0) scale(.4); } 30% { opacity: 1; transform: translate(calc(var(--x, 8px) * .5), calc(var(--y, -28px) * .4)) scale(1); } 85% { opacity: .25; } 100% { opacity: 0; transform: translate(var(--x, 8px), var(--y, -28px)) scale(.8); } }

/* ---------- 两个人都点亮的那一下：屏幕中下部（提示条上面）的一段，不挡点按 ---------- */
.ra-sx { position: absolute; left: 50%; top: 60%; z-index: 88; width: 260px; height: 220px; margin: -110px 0 0 -130px; pointer-events: none; animation: raLife 2.4s ease-out both; }
.ra-sx > * { position: absolute; left: 50%; top: 50%; }
.ra-bl { width: 240px; height: 240px; margin: -120px 0 0 -120px; border-radius: 50%; background: radial-gradient(circle, var(--ra-glow) 0%, transparent 68%); opacity: 0; animation: raBloom 2.4s ease-out both; }
.ra-pa, .ra-pb { width: 34px; height: 34px; margin: -17px 0 0 -17px; opacity: 0; }
.ra-pa { animation: raA 2.4s cubic-bezier(.3, .7, .2, 1) both; }
.ra-pb { animation: raB 2.4s cubic-bezier(.3, .7, .2, 1) both; }
.ra-mk { width: 150px; height: 130px; margin: -65px 0 0 -75px; opacity: 0; animation: raMark 2.4s cubic-bezier(.2, .8, .2, 1) both; }
.ra-bit { width: 12px; height: 12px; margin: -6px 0 0 -6px; opacity: 0; animation: raBit 2.4s ease-out both; }
.ra-sx svg { display: block; width: 100%; height: 100%; overflow: visible; }
@keyframes raLife { 0%, 82% { transform: none; } 100% { transform: translateY(-14px); } }
@keyframes raA { 0% { opacity: 0; transform: translate(-104px, 34px) scale(.7) rotate(-18deg); } 14% { opacity: 1; } 44% { transform: translate(-16px, 0) scale(1) rotate(-6deg); } 54% { opacity: 1; transform: translate(-2px, 0) scale(.92); } 62%, 100% { opacity: 0; transform: translate(0, 0) scale(.6); } }
@keyframes raB { 0% { opacity: 0; transform: translate(104px, 34px) scale(.7) rotate(18deg); } 14% { opacity: 1; } 44% { transform: translate(16px, 0) scale(1) rotate(6deg); } 54% { opacity: 1; transform: translate(2px, 0) scale(.92); } 62%, 100% { opacity: 0; transform: translate(0, 0) scale(.6); } }
@keyframes raMark { 0%, 50% { opacity: 0; transform: scale(.55); } 64% { opacity: 1; transform: scale(1.06); } 76% { transform: scale(1); } 88% { opacity: 1; } 100% { opacity: 0; transform: translateY(-6px) scale(1); } }
@keyframes raBloom { 0%, 48% { opacity: 0; transform: scale(.4); } 62% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(1.5); } }
@keyframes raBit { 0%, 56% { opacity: 0; transform: translate(0, 0) scale(.4) rotate(0); } 66% { opacity: 1; transform: translate(calc(var(--dx) * .45), calc(var(--dy) * .45)) scale(1) rotate(20deg); } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(.8) rotate(60deg); } }
/* 报平安 = 抱一下：两个小人走过来、靠在一起不消失，手从对方背后搭过来 */
.ra-sx.ra-hug { zoom: 1.35; }
.ra-hug .ra-pa, .ra-hug .ra-pb { width: 46px; height: 58px; margin: -36px 0 0 -23px; }
.ra-hug .ra-pa { animation-name: raHugA; }
.ra-hug .ra-pb { animation-name: raHugB; }
.ra-hug .ra-mk { animation-name: raHugArms; }
.ra-hug .ra-arm { stroke-dasharray: 22; stroke-dashoffset: 22; animation: raArm 2.4s cubic-bezier(.3, .7, .2, 1) both; }
@keyframes raHugA { 0% { opacity: 0; transform: translate(-104px, 8px) rotate(0); } 12% { opacity: 1; } 26% { transform: translate(-70px, 0) rotate(-4deg); } 36% { transform: translate(-46px, 3px) rotate(3deg); } 50% { transform: translate(-17px, 0) rotate(11deg); } 60% { transform: translate(-15px, 0) rotate(12deg) scale(1.05); } 72% { transform: translate(-15px, 0) rotate(11deg) scale(1); } 88% { opacity: 1; } 100% { opacity: 0; transform: translate(-15px, -16px) rotate(11deg); } }
@keyframes raHugB { 0% { opacity: 0; transform: translate(104px, 8px) rotate(0); } 12% { opacity: 1; } 26% { transform: translate(70px, 0) rotate(4deg); } 36% { transform: translate(46px, 3px) rotate(-3deg); } 50% { transform: translate(17px, 0) rotate(-11deg); } 60% { transform: translate(15px, 0) rotate(-12deg) scale(1.05); } 72% { transform: translate(15px, 0) rotate(-11deg) scale(1); } 88% { opacity: 1; } 100% { opacity: 0; transform: translate(15px, -16px) rotate(-11deg); } }
@keyframes raHugArms { 0%, 48% { opacity: 0; } 54% { opacity: 1; transform: none; } 60% { transform: scale(1.05); } 72% { transform: scale(1); } 88% { opacity: 1; } 100% { opacity: 0; transform: translateY(-16px); } }
@keyframes raArm { 0%, 50% { stroke-dashoffset: 22; } 62%, 100% { stroke-dashoffset: 0; } }
/* 减少动态效果：不飘、不飞，只淡入淡出合成后的画面（抱一下就是两个小人靠在一起） */
.ra-sx.ra-rm, .ra-sx.ra-rm * { animation: none !important; }
.ra-sx.ra-rm { animation: raFade 2.4s ease both !important; }
.ra-sx.ra-rm .ra-bit, .ra-sx.ra-rm:not(.ra-hug) .ra-pa, .ra-sx.ra-rm:not(.ra-hug) .ra-pb { display: none; }
.ra-sx.ra-rm .ra-mk, .ra-sx.ra-rm .ra-bl { opacity: 1; }
.ra-sx.ra-rm.ra-hug .ra-pa { opacity: 1; transform: translate(-15px, 0) rotate(11deg); }
.ra-sx.ra-rm.ra-hug .ra-pb { opacity: 1; transform: translate(15px, 0) rotate(-11deg); }
.ra-sx.ra-rm.ra-hug .ra-arm { stroke-dashoffset: 0; }
@keyframes raFade { 0% { opacity: 0; } 20%, 80% { opacity: 1; } 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .ra-rb *, .ra-rb { animation: none !important; } }

/* ---------- 状态图标 ---------- */
.ra-si { flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.ra-si .a { stroke: var(--clay); }
.ra-si .af { fill: var(--clay); stroke: none; }

/* ---------- 三套皮肤 ---------- */
/* 极简：黑白——亮的那一半是墨色，不发光 */
:root[data-skin="minimal"] .ra-fl, :root[data-skin="minimal"] .ra-fr { fill: var(--ink); }
:root[data-skin="minimal"] .ra-rb.is-me, :root[data-skin="minimal"] .ra-rb.is-ta, :root[data-skin="minimal"] .ra-rb.is-both { color: var(--ink); }
:root[data-skin="minimal"] .ra-rb.is-both .ra-ri { filter: none; }
:root[data-skin="minimal"] .ra-glow, :root[data-skin="minimal"] .ra-bl { display: none; }
:root[data-skin="minimal"] .ra-si .a { stroke: var(--ink); }
:root[data-skin="minimal"] .ra-si .af { fill: var(--ink); }
/* 可爱：线粗一点 */
:root[data-skin="cute"] .ra-ln { stroke-width: 2.2; }
:root[data-skin="cute"] .ra-si { stroke-width: 1.9; }
