/* Provo shared UI layer. Loaded LAST on every layout (customer, provider, area portal, admin console, sign-in, errors).
   1) one shimmer loading system   2) mobile / Android WebView smoothness. No new colours: neutral tints only. */

/* ================================================================== 1. shimmer tokens (dark values are set next to the page loader) */
:root{--shm-base:rgba(128,104,111,.13);--shm-hi:rgba(255,255,255,.62);--shm-sweep:rgba(205,180,187,.34);--shm-time:1.35s}
@keyframes pvs-move{from{transform:translate3d(-100%,0,0)}to{transform:translate3d(100%,0,0)}}
@keyframes pvs-pan{from{background-position:160% 0}to{background-position:-60% 0}}

/* ---- skeleton blocks: every older skeleton class now has the same surface and the same sweep (composited: transform only) */
.shm,.skel,.sk:not(.msgx-conv):not(.msgx-row),.cc-skel,.ac-skel,.ar-skel,.cs-sk i,.bk-slot-sk,.pp-skel,.skeleton,.skl,.msgx-skel i,.msgx-conv.sk i,.msgx-row.sk .msgx-bub i{
  position:relative;overflow:hidden;background:var(--shm-base)!important;animation:none!important}
.shm::after,.skel::after,.sk:not(.msgx-conv):not(.msgx-row)::after,.cc-skel::after,.ac-skel::after,.ar-skel::after,.cs-sk i::after,.bk-slot-sk::after,.pp-skel::after,.skeleton::after,.skl::after,.msgx-skel i::after,.msgx-conv.sk i::after,.msgx-row.sk .msgx-bub i::after{
  content:""!important;position:absolute!important;inset:0!important;width:auto!important;height:auto!important;border:0!important;border-radius:0!important;
  background:linear-gradient(90deg,transparent 0,var(--shm-hi) 50%,transparent 100%)!important;transform:translate3d(-100%,0,0);animation:pvs-move var(--shm-time) linear infinite!important}
.pp-skel{list-style:none}
.shm,.shm-line{display:block;border-radius:10px}
.shm-line{height:12px}

/* service-detail popup: picture, title, text and button, in the places the real content will take */
.cs-sk{height:auto!important;background:none!important;animation:none!important;display:grid;gap:12px;padding:2px 0}
.cs-sk i{display:block;height:13px;border-radius:8px}
.cs-sk i:nth-child(1){height:auto;aspect-ratio:16/9;border-radius:14px}
.cs-sk i:nth-child(2){height:20px;width:68%}
.cs-sk i:nth-child(4){width:82%}
.cs-sk i:nth-child(5){height:44px;border-radius:999px;margin-top:4px}

.pvui-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* notification rows */
.ntf-sk{display:grid;grid-template-columns:36px 1fr;gap:8px 12px;padding:12px 14px;text-align:left}
.ntf-sk .shm:first-child{grid-row:span 2;width:36px;height:36px;border-radius:50%}
.ntf-sk .shm-line:last-child{width:60%}

/* ---- buttons that are working: the label stays (nothing resizes), a light sweep crosses the button. No spinning rings. */
.btn.is-loading{position:relative;overflow:hidden}
.btn.is-loading>:not(.spinner){opacity:1!important}
.btn .spinner,button .spinner,a .spinner,.btn.is-loading::after,.bk .btn.is-loading::before{
  content:""!important;position:absolute!important;inset:0!important;width:auto!important;height:auto!important;margin:0!important;border:0!important;border-radius:inherit!important;pointer-events:none;
  background:linear-gradient(100deg,transparent 30%,var(--shm-sweep) 50%,transparent 70%) 0 0/220% 100% no-repeat!important;animation:pvs-pan 1.1s linear infinite!important}
.btn:has(>.spinner)::after{display:none!important}
.bk .btn.is-loading span::after{content:none!important}
.bk .btn.is-loading::after{display:none!important}
button:has(>.spinner){position:relative;overflow:hidden}
/* a spinner that is not inside a button becomes a short shimmer bar */
.spinner{display:inline-block;width:72px;height:10px;border:0!important;border-radius:6px;background:linear-gradient(100deg,var(--shm-base) 30%,var(--shm-sweep) 50%,var(--shm-base) 70%) 0 0/220% 100%;animation:pvs-pan 1.1s linear infinite}

/* ---- areas that refresh in place: the current content stays visible (no jump) with the same sweep over it */
.list-loading,.dz-results.is-loading,.bk-cal-g.is-loading,.bk-slots.is-loading,.cal.is-loading,.av-cal.is-loading,.pfx.is-loading,.cv-box.is-busy,.mm-root.is-busy,.is-busy[data-mm]{position:relative}
.list-loading::before{content:none!important}
.list-loading::after,.dz-results.is-loading::after,.bk-cal-g.is-loading::after,.cal.is-loading::after,.av-cal.is-loading::after,.pfx.is-loading::after,.cv-box.is-busy::after,.is-busy::after{
  content:""!important;position:absolute!important;inset:0!important;z-index:4;pointer-events:none;border-radius:14px;
  background:linear-gradient(100deg,transparent 30%,var(--shm-sweep) 50%,transparent 70%) 0 0/220% 100% no-repeat!important;animation:pvs-pan 1.2s linear infinite!important}
.pp-calc.is-busy{position:relative}
.pp-calc.is-busy::after{content:none!important}
.pp-calc.is-busy .pp-price-v{background:linear-gradient(100deg,var(--shm-base) 30%,var(--shm-sweep) 50%,var(--shm-base) 70%) 0 0/220% 100%!important;animation:pvs-pan 1.2s linear infinite!important}

/* ---- former ring spinners in popups, viewers and payment screens */
.cz-spin,.bk-prep-spin{width:176px!important;height:12px!important;border:0!important;border-radius:8px!important;margin-left:auto;margin-right:auto;
  background:linear-gradient(100deg,var(--shm-base) 30%,rgba(220,38,38,.28) 50%,var(--shm-base) 70%) 0 0/220% 100%!important;animation:pvs-pan 1.2s linear infinite!important}
.pv-spin{inset:0!important;width:auto!important;height:auto!important;border:0!important;border-radius:0!important;
  background:linear-gradient(100deg,transparent 30%,rgba(255,255,255,.14) 50%,transparent 70%) 0 0/220% 100%!important;animation:pvs-pan 1.2s linear infinite!important}
.cw-vstage.is-loading::before{inset:0!important;margin:auto!important;width:min(78%,420px)!important;height:min(56%,320px)!important;border:0!important;border-radius:16px!important;
  background:linear-gradient(100deg,rgba(255,255,255,.07) 30%,rgba(255,255,255,.18) 50%,rgba(255,255,255,.07) 70%) 0 0/220% 100%!important;animation:pvs-pan 1.2s linear infinite!important}
.cw-fdl.is-busy,.cw-pin-go.is-busy{animation:none!important}
.cw-fdl.is-busy,.cw-pin-go.is-busy{position:relative;overflow:hidden}
.cw-fdl.is-busy::after,.cw-pin-go.is-busy::after{border-radius:inherit}
.ntf-spin{display:inline-block;width:56px!important;height:10px!important;border:0!important;border-radius:6px!important;background:linear-gradient(100deg,var(--shm-base) 30%,var(--shm-sweep) 50%,var(--shm-base) 70%) 0 0/220% 100%!important;animation:pvs-pan 1.1s linear infinite!important}
.avatar-busy .spin{animation:none!important;opacity:0}
.avatar-busy{background-image:linear-gradient(100deg,transparent 30%,rgba(255,255,255,.35) 50%,transparent 70%)!important;background-size:220% 100%!important;animation:pvs-pan 1.2s linear infinite}
html.tr-busy .lang-btn .lang-globe{animation:none!important;opacity:.55}
html.tr-busy .lang-btn{background-image:linear-gradient(100deg,transparent 30%,var(--shm-sweep) 50%,transparent 70%);background-size:220% 100%;animation:pvs-pan 1.2s linear infinite}

/* ================================================================== 2. mobile smoothness */
a,button,label,select,summary,input,textarea,[role=button]{touch-action:manipulation}

@media (max-width:899px),(hover:none) and (pointer:coarse){
  /* Live blur is repainted on every frame of a scroll or popup animation and is the main cause of stutter in Android WebView.
     The dim colour behind popups stays; only the blur is removed. */
  .dialog::backdrop,.scrim.is-on,.site-header,.bottom-nav,.cz-overlay,.bk-pl-wrap,.bk-pop-bg,.bk-prep,.cw-viewer,.cw-vnav,.cs-tag,.pv-rate,.hx-go,.hm-hero .hm-tile span,.ph .tag-c,.ph .btn-outline.ph-btn,
  .sub-list--glass .sub-card .sub-go,.pfx-play,.pfx-dlg::backdrop,.pfx-viewer::backdrop,.apply-actions,.pp-play,.pp .btn-outline,.pp .pp-hero,.pv::backdrop,.pv-x,.pv-nav,.pv-act,.lang-panel.is-sheet::backdrop{
    -webkit-backdrop-filter:none!important;backdrop-filter:none!important}
  /* these relied on the blur to stay readable, so they become (almost) solid instead */
  .apply-actions,.pp .pp-hero{background:var(--surface)}
  .bk-pl-wrap{background:rgba(255,255,255,.98)}
  .bottom-nav{background:var(--surface)!important}
  /* shorter popup entrances feel immediate */
  .dialog[open]{animation-duration:.2s}
  .dialog.sheet[open]{animation-duration:.24s}
  .search-dialog[open]{animation-duration:.2s}
  .dialog::backdrop{animation-duration:.16s}
}
@media (prefers-reduced-motion:reduce){
  .shm::after,.skel::after,.sk::after,.cc-skel::after,.ac-skel::after,.ar-skel::after,.cs-sk i::after,.bk-slot-sk::after,.pp-skel::after,.skeleton::after,.skl::after,.msgx-skel i::after,.msgx-conv.sk i::after,.msgx-bub i::after{animation:none!important;opacity:0}
  .btn .spinner,button .spinner,.btn.is-loading::after,.is-busy::after,.is-loading::after,.list-loading::after{animation-duration:3s!important}
}

/* ================================================================== payment loading skeleton (booking page + "pay now" on a booking) */
.bk-pl-box:not(.bk-pl-err){width:100%;max-width:400px;gap:0}
/* a solid page-colour backdrop: nothing shows through the placeholder, and nothing behind it has to be blurred or blended */
.cz-overlay,.bk-pl-wrap{background:var(--bg)!important}
.pay-sk{width:min(400px,100%);display:grid;gap:14px;text-align:left}
.pay-sk-card{position:relative;display:grid;gap:12px;padding:20px 18px 18px;background:var(--surface);border:1px solid var(--border);border-radius:20px;box-shadow:0 18px 44px -24px rgba(60,14,20,.35);overflow:hidden}
.pay-sk-card::before{content:"";position:absolute;inset:0 0 auto;height:4px;background:linear-gradient(90deg,#DC2626,#B91C1C)}
.pay-sk i{display:block;border-radius:10px}
.pay-sk-head{display:flex;align-items:center;gap:10px}.pay-sk-head img{flex:none}
.pay-sk-title{height:14px;width:46%}
.pay-sk-amt{height:34px;width:58%;margin-top:4px}
.pay-sk-note{width:72%}
.pay-sk-methods{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-top:4px}.pay-sk-methods i{height:46px}
.pay-sk-lab{width:30%}
.pay-sk-field{height:44px}
.pay-sk-two{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.pay-sk-btn{height:50px;border-radius:999px!important;margin-top:4px;background:rgba(220,38,38,.22)!important}
.pay-sk-cap{margin:0;text-align:center;font-size:.86rem;font-weight:600;color:var(--muted)}
@media (max-height:600px){.pay-sk-methods,.pay-sk-two,.pay-sk-lab{display:none}}
