/* Animation Lab 14 — cinematic interactions, additions only; no calculator formulas changed. */
:root{--rc14-cinema-ease:cubic-bezier(.22,.8,.2,1)}
.editorial-hero{isolation:isolate;overflow:hidden}
.editorial-hero>.container{position:relative;z-index:3}
@media (prefers-reduced-motion:no-preference){
/* Clear continuous movement instead of barely perceptible on-load-only motion */
.editorial-hero::before{content:"";position:absolute;z-index:1;inset:-24% -24%;pointer-events:none;background:radial-gradient(ellipse 38% 38% at 23% 32%,rgba(205,165,108,.31),transparent 73%),radial-gradient(ellipse 42% 45% at 79% 68%,rgba(115,153,129,.25),transparent 73%);transform:translate3d(-7%,1%,0) scale(1);animation:rc14-ambient 10s ease-in-out infinite alternate;will-change:transform,opacity}
.editorial-hero::after{z-index:2;opacity:.72;background:linear-gradient(107deg,transparent 32%,rgba(248,231,193,.32) 48%,transparent 66%);background-size:220% 100%;animation:rc14-sunbeam 12s linear infinite;pointer-events:none}
@keyframes rc14-ambient{0%{transform:translate3d(-9%,-3%,0) rotate(-3deg) scale(.97);opacity:.6}50%{transform:translate3d(6%,5%,0) rotate(3deg) scale(1.13);opacity:1}100%{transform:translate3d(13%,-5%,0) rotate(-1deg) scale(1.05);opacity:.72}}
@keyframes rc14-sunbeam{0%{background-position:130% 0}100%{background-position:-110% 0}}
/* Keep foreground unaffected by animated moving light. */
#services .cards .card{transform:perspective(800px) rotateX(var(--rc14-tilt-y,0deg)) rotateY(var(--rc14-tilt-x,0deg)) translateY(var(--rc14-lift,0px));transition:transform .45s var(--rc14-cinema-ease),box-shadow .4s ease,border-color .3s ease;will-change:transform;position:relative}
#services .cards .card:after{content:"";position:absolute;inset:0;pointer-events:none;border-radius:inherit;opacity:var(--rc14-shine-opacity,0);background:radial-gradient(circle at var(--rc14-light-x,50%) var(--rc14-light-y,50%),rgba(227,192,138,.19),transparent 65%);transition:opacity .3s ease}
@media (hover:hover) and (pointer:fine){#services .cards .card:hover{--rc14-lift:-5px;--rc14-shine-opacity:1;box-shadow:0 19px 35px rgba(25,56,41,.12)}}
#services .cards .card.rc14-touched{--rc14-shine-opacity:1;box-shadow:0 12px 24px rgba(25,56,41,.10);border-color:rgba(164,126,73,.5)}
/* Numerical changes become discernible without making results unreadable. */
.rc14-number-update{animation:rc14-result-refresh .55s var(--rc14-cinema-ease)}
@keyframes rc14-result-refresh{0%{opacity:.48;filter:blur(2px);transform:translateY(6px)}100%{opacity:1;filter:blur(0);transform:translateY(0)}}
#invChart path.total-line,#invChart path.principal-line{transition:opacity .3s ease}
#invChart.rc14-chart-refresh path.total-line,#invChart.rc14-chart-refresh path.principal-line{animation:rc14-chart-draw 1.1s var(--rc14-cinema-ease) both;stroke-dasharray:var(--rc14-line-length,1800);stroke-dashoffset:var(--rc14-line-length,1800)}
#invChart.rc14-chart-refresh path.principal-line{animation-delay:.08s}
@keyframes rc14-chart-draw{to{stroke-dashoffset:0}}
}
/* Change mobile inherited rule that suppressed hero motion. CSS-only animation works without JS. */
@media(max-width:700px) and (prefers-reduced-motion:no-preference){
.editorial-hero::before{animation:rc14-ambient 10s ease-in-out infinite alternate!important;opacity:.82!important}
.editorial-hero::after{animation:rc14-sunbeam 12s linear infinite!important;opacity:.62!important}
/* Prevent competing older overlay from obscuring the new light effect. */
.rc12-lightstage{opacity:.24}
}
@media(prefers-reduced-motion:reduce){.editorial-hero::before,.editorial-hero::after{animation:none!important}.rc14-number-update,#invChart.rc14-chart-refresh path{animation:none!important}#services .cards .card{transform:none!important;transition:none!important}}
