/* MedicPeptide splash + loader */
:root{--mp-gold:#B79E74;--mp-ink:#2B2D33;--mp-ivory:#FBF8F2}

/* ---------- Splash (first view per session, ≤1.4s) ---------- */
html.mp-splash-skip .mp-splash{display:none!important}
.mp-splash{position:fixed;inset:0;z-index:2147483000;display:flex;align-items:center;justify-content:center;background:var(--mp-ivory);animation:mp-splash-out .28s cubic-bezier(.4,0,1,1) 1.12s forwards}
.mp-splash__in{display:flex;flex-direction:column;align-items:center;gap:22px;animation:mp-splash-zoom .28s cubic-bezier(.4,0,1,1) 1.12s forwards}
.mp-splash__logo{display:block;width:clamp(100px,24vw,136px);height:auto;overflow:visible;animation:mp-splash-in .42s cubic-bezier(.2,.7,.2,1) both}
.mp-splash__edge{stroke-dasharray:1 1;stroke-dashoffset:1;animation:mp-draw .46s cubic-bezier(.6,0,.3,1) .02s forwards,mp-fade .3s ease .5s forwards}
.mp-splash__paint{stroke-dasharray:1 1;stroke-dashoffset:1;animation:mp-draw .4s cubic-bezier(.65,0,.35,1) .1s forwards}
.mp-splash__paint--p{animation-delay:.24s}
.mp-splash__shine{animation:mp-shine .5s cubic-bezier(.4,0,.2,1) .6s both}
.mp-splash__word{display:flex;direction:ltr;padding-left:.24em;font:700 clamp(15px,3.8vw,19px)/1 Assistant,system-ui,sans-serif;letter-spacing:.24em;color:var(--mp-ink)}
.mp-splash__word span{display:inline-block;opacity:0;transform:translateY(.5em);animation:mp-rise .36s cubic-bezier(.2,.7,.2,1) calc(.46s + var(--i)*24ms) forwards}
.mp-splash__word .g{color:var(--mp-gold);font-weight:400}
@keyframes mp-splash-out{to{opacity:0;visibility:hidden}}
@keyframes mp-splash-zoom{to{transform:scale(1.04)}}
@keyframes mp-splash-in{from{opacity:0;transform:scale(.92)}}
@keyframes mp-draw{to{stroke-dashoffset:0}}
@keyframes mp-fade{to{opacity:0}}
@keyframes mp-shine{from{transform:translateX(0)}to{transform:translateX(1150px)}}
@keyframes mp-rise{to{opacity:1;transform:none}}

/* ---------- Loader ---------- */
.mp-loader{position:fixed;inset:0;z-index:2147482000;display:flex;align-items:center;justify-content:center;background:rgba(251,248,242,.72);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);opacity:0;visibility:hidden;transition:opacity .2s ease,visibility 0s linear .2s}
.mp-loader.is-on{opacity:1;visibility:visible;transition:opacity .2s ease}
.mp-loader__box{display:flex;flex-direction:column;align-items:center;gap:14px;transform:scale(.96);transition:transform .25s cubic-bezier(.2,.7,.2,1)}
.mp-loader.is-on .mp-loader__box{transform:none}
.mp-loader__logo{display:block;width:60px;height:auto;color:var(--mp-gold)}
.mp-loader__text{margin:0;font:600 15px/1.4 Assistant,system-ui,sans-serif;color:#24262B;text-align:center}
.mp-loader__text:empty{display:none}
.mp-loader__base{fill:currentColor;opacity:.18}
.mp-loader__s{stroke-dasharray:1 1;stroke-dashoffset:1;animation:mp-loop 1.5s cubic-bezier(.65,0,.35,1) infinite both}
.mp-loader__s--p{animation-delay:.16s}
.mp-loader-inline{display:inline-block;width:1.2em;height:1em;vertical-align:-.15em}
.mp-loader-inline svg{display:block;width:100%;height:100%}
@keyframes mp-loop{0%{stroke-dashoffset:1}45%,58%{stroke-dashoffset:0}100%{stroke-dashoffset:-1}}
@keyframes mp-pulse{50%{opacity:.45}}

@media (prefers-reduced-motion:reduce){
  .mp-splash{animation-delay:.75s}
  .mp-splash__in,.mp-splash__logo,.mp-splash__paint,.mp-splash__word span{animation:none!important}
  .mp-splash__paint{stroke-dashoffset:0}
  .mp-splash__word span{opacity:1;transform:none}
  .mp-splash__edge,.mp-splash__shine{display:none}
  .mp-loader__s{animation:none;stroke-dashoffset:0}
  .mp-loader__logo,.mp-loader-inline svg{animation:mp-pulse 1.2s ease-in-out infinite}
  .mp-loader,.mp-loader__box{transition:none}
}
