/* ==========================================================================
   Pawsitive Salon — portal.css
   The signed-in client portal: a top bar + sidebar shell with dashboard,
   pet profiles, appointments, and payments. Builds on tokens.css.
   ========================================================================== */

body.portal { background: var(--paper); }

/* --- Top bar ------------------------------------------------------------- */
.portal-top { position: sticky; top: 0; z-index: 20; background: var(--surface); border-bottom: 1px solid var(--line); }
.portal-top__inner { max-width: var(--container); margin-inline: auto; padding: 0 var(--space-m); height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: var(--space-s); }
.uchip { display: flex; align-items: center; gap: var(--space-2xs); min-width: 0; }
.uchip__name { font-weight: 700; font-size: var(--step--1); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.uchip__signout { flex: none; background: none; border: 0; color: var(--ink-faint); font: inherit; font-size: var(--step--1); cursor: pointer; padding: 0.3rem 0.5rem; border-radius: var(--radius-s); }
@media (max-width: 460px) { .uchip__name { display: none; } }
.uchip__signout:hover { color: var(--tang-deep); background: var(--cream); }

/* --- Avatars ------------------------------------------------------------- */
.avatar { width: 36px; height: 36px; border-radius: var(--radius-pill); display: grid; place-items: center; font-weight: 800; font-size: 0.8rem; flex: none; }
.avatar--client { background: #cfe4df; color: #0e5c5b; }
.avatar--lg { width: 64px; height: 64px; font-size: 1.6rem; }
.avatar--sm { width: 28px; height: 28px; font-size: 0.68rem; }
/* Chosen illustrated avatar fills the circle (the art is already round). */
.avatar--img { overflow: hidden; background: var(--gold-soft); padding: 0; }
.avatar--img img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: var(--radius-pill); }
.avatar--pet { background: var(--gold); color: var(--ink); }

/* --- Shell --------------------------------------------------------------- */
.portal-shell { max-width: var(--container); margin-inline: auto; padding: var(--space-l) var(--space-m) var(--space-2xl); display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-l); align-items: start; }
@media (min-width: 900px) { .portal-shell { grid-template-columns: 220px minmax(0, 1fr); } }

/* --- Sidebar ------------------------------------------------------------- */
.portal-side { display: flex; flex-direction: column; gap: var(--space-2xs); min-width: 0; }
@media (min-width: 900px) { .portal-side { position: sticky; top: calc(var(--header-h) + var(--space-l)); } }
.pnav { display: flex; flex-wrap: wrap; gap: var(--space-3xs); padding-bottom: 2px; }
@media (min-width: 900px) { .pnav { flex-direction: column; overflow: visible; } }
.pnav__item { display: flex; align-items: center; gap: var(--space-2xs); padding: 0.6rem 0.8rem; border-radius: var(--radius-s); color: var(--ink-soft); font-weight: 700; font-size: var(--step--1); text-decoration: none; white-space: nowrap; border: 1px solid transparent; transition: background var(--dur) var(--ease); }
.pnav__item:hover { background: var(--cream); }
.pnav__item[aria-current="page"] { background: var(--gold-soft); color: var(--tang-deep); }
.pnav__icon { font-size: 1.05rem; line-height: 1; }
.pnav__soon { margin-left: auto; font-size: 0.6rem; font-weight: 800; letter-spacing: 0.06em; background: var(--cream); color: var(--ink-faint); border-radius: var(--radius-pill); padding: 1px 6px; }
.portal-side .btn { margin-top: var(--space-2xs); }

/* --- Main + headings ----------------------------------------------------- */
.portal-main { min-width: 0; }
.phead { margin-bottom: var(--space-m); }
.phead h1 { font-size: var(--step-3); }
.phead p { color: var(--ink-soft); margin-top: var(--space-3xs); }

.pcard { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-m); box-shadow: var(--shadow-s); }
.pcard + .pcard, .pgrid + .pcard, .pcard + .pgrid { margin-top: var(--space-m); }
.pcard__head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-s); margin-bottom: var(--space-s); }
.pcard__head h2, .pcard__head h3 { font-size: var(--step-1); }
.pcard__link { font-size: var(--step--1); font-weight: 700; color: var(--tang-deep); text-decoration: none; }
.pgrid { display: grid; gap: var(--space-m); }
@media (min-width: 720px) { .pgrid--2 { grid-template-columns: 1fr 1fr; } }

/* --- Appointment cards / rows -------------------------------------------- */
.appt { display: flex; align-items: center; gap: var(--space-s); }
.appt__icon { width: 44px; height: 44px; border-radius: var(--radius-s); background: var(--gold-soft); color: var(--tang-deep); display: grid; place-items: center; font-size: 1.3rem; flex: none; }
.appt__body { flex: 1; min-width: 0; }
.appt__title { font-weight: 700; }
.appt__when { color: var(--ink-soft); font-size: var(--step--1); }
.appt__price { font-family: var(--font-display); color: var(--tang-deep); font-weight: 600; }
.appt__actions { display: flex; flex-wrap: wrap; gap: var(--space-2xs); margin-top: var(--space-s); }
.appt--feature { background: var(--gold-soft); border-color: transparent; }
.appt-list { display: grid; gap: var(--space-s); }
.appt-row { display: flex; align-items: center; gap: var(--space-s); padding: var(--space-s) 0; border-bottom: 1px solid var(--line); }
.appt-row:last-child { border-bottom: 0; }

.statetag { font-size: 0.68rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; border-radius: var(--radius-pill); padding: 2px 9px; }
.statetag--upcoming { background: var(--tang-soft); color: var(--tang-deep); }
.statetag--completed { background: #d9efe4; color: #0e5c5b; }
.statetag--cancelled { background: var(--cream); color: var(--ink-faint); }

/* --- Pets ---------------------------------------------------------------- */
.pet-tabs { display: flex; flex-wrap: wrap; gap: var(--space-2xs); margin-bottom: var(--space-m); }
.pet-tab { display: inline-flex; align-items: center; gap: var(--space-2xs); border: 1.5px solid var(--line); background: var(--surface); border-radius: var(--radius-pill); padding: 0.4rem 0.9rem; font: inherit; font-weight: 700; color: var(--ink-soft); cursor: pointer; }
.pet-tab[aria-pressed="true"] { border-color: var(--tang); background: var(--tang-soft); color: var(--tang-deep); }
.pet-tab--add { color: var(--tang-deep); border-style: dashed; }
.pet-hero { display: flex; align-items: center; gap: var(--space-s); margin-bottom: var(--space-m); flex-wrap: wrap; }
.pet-hero__main { flex: 1 1 auto; min-width: 0; }   /* min-width:0 lets the name/breed lines use the full row instead of the buttons stealing half */
.pet-hero__actions { display: flex; gap: .4rem; flex: 0 0 auto; }
@media (max-width: 560px) {
  /* On phones the two buttons drop to their own full-width row so the name,
     breed · age · size, and honor line each get the whole first row. */
  .pet-hero__actions { flex-basis: 100%; justify-content: flex-end; }
}
.pet-hero h2 { font-size: var(--step-2); }
.pet-hero p { color: var(--ink-soft); font-size: var(--step--1); }

.detail-list { display: grid; gap: 0; }
.detail-row { display: flex; justify-content: space-between; gap: var(--space-s); padding: 0.6rem 0; border-bottom: 1px solid var(--line); }
.detail-row:last-child { border-bottom: 0; }
.detail-row span { color: var(--ink-faint); font-size: var(--step--1); }
.detail-row b { text-align: right; }
.ok { color: #0e7c54; font-weight: 700; }

/* --- Payments ------------------------------------------------------------ */
.pay-row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-s); padding: var(--space-s) 0; border-bottom: 1px solid var(--line); }
.pay-row:last-child { border-bottom: 0; }
.pay-row small { color: var(--ink-faint); }

/* --- Quick actions ------------------------------------------------------- */
.quick { display: grid; gap: var(--space-s); grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.quick a { display: flex; align-items: center; gap: var(--space-2xs); padding: var(--space-s); border: 1px solid var(--line); border-radius: var(--radius-s); text-decoration: none; color: var(--ink); font-weight: 700; background: var(--surface); }
.quick a:hover { border-color: var(--gold); background: var(--cream); }

/* --- Empty / soon -------------------------------------------------------- */
.empty { color: var(--ink-faint); }
.soon-wrap { text-align: center; padding: var(--space-xl) var(--space-m); }
.soon-wrap .card__icon { margin-inline: auto; }

/* --- Toasts (stand-in for push notifications) ---------------------------- */
.toast-host { position: fixed; left: 50%; bottom: calc(var(--space-l) + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: var(--space-2xs); width: min(420px, 94vw); pointer-events: none; }
.toast { display: flex; gap: var(--space-2xs); align-items: flex-start; background: var(--ink); color: #fff; border-radius: var(--radius); padding: var(--space-s) var(--space-m); box-shadow: var(--shadow-l); opacity: 0; transform: translateY(14px); transition: opacity .26s var(--ease), transform .26s var(--ease); }
.toast.is-in { opacity: 1; transform: none; }
.toast__icon { font-size: 1.2rem; line-height: 1.25; }
.toast__body { display: grid; gap: 1px; font-size: var(--step--1); }
.toast__body b { font-weight: 800; }
.toast__body span { color: rgba(255,255,255,.85); }
.toast--good { background: #0e7c54; }

/* --- Client live pipeline ------------------------------------------------- */
.live { margin-top: var(--space-m); padding-top: var(--space-m); border-top: 1px dashed var(--line); }
.pstepper { display: flex; justify-content: space-between; gap: 4px; margin-bottom: var(--space-m); }
.pstep { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; position: relative; }
.pstep::before { content: ""; position: absolute; top: 9px; left: -50%; width: 100%; height: 2px; background: var(--line); z-index: 0; }
.pstep:first-child::before { display: none; }
.pstep__dot { width: 18px; height: 18px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line); z-index: 1; }
.pstep__lbl { font-size: 0.66rem; font-weight: 700; color: var(--ink-faint); text-align: center; }
.pstep--done .pstep__dot { background: var(--gold); border-color: var(--gold); }
.pstep--done::before { background: var(--gold); }
.pstep--active .pstep__dot { background: var(--tang); border-color: var(--tang); box-shadow: 0 0 0 4px var(--tang-soft); }
.pstep--active::before { background: var(--gold); }
.pstep--active .pstep__lbl { color: var(--tang-deep); }
.live__status { display: flex; align-items: center; gap: var(--space-2xs); margin-bottom: var(--space-s); }
.live__label { font-weight: 700; color: var(--ink-soft); font-size: var(--step--1); }
.live-note { color: var(--ink-soft); font-size: var(--step--1); margin: 0 0 var(--space-s); }
.btn--block { display: flex; width: 100%; justify-content: center; }
.live-btn[disabled] { opacity: .6; }

/* --- Mobile header trims (avoid horizontal overflow on small phones) ------ */
@media (max-width: 460px) {
  .portal-top__inner { padding: 0 var(--space-s); gap: var(--space-2xs); }
  .brand .tag { display: none; }
}

/* --- Community ----------------------------------------------------------- */
.feed { display: grid; gap: var(--space-m); }
.formrow2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-s); }
@media (max-width: 520px) { .formrow2 { grid-template-columns: 1fr; } }
.post { display: grid; grid-template-columns: 130px 1fr; gap: 0; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-l); overflow: hidden; }
@media (max-width: 560px) { .post { grid-template-columns: 1fr; } }
.post__media { background: var(--gold-soft); display: grid; place-items: center; min-height: 130px; }
.post__media img { width: 100%; height: 100%; object-fit: cover; }
.post__glyph { font-size: 3.2rem; }
/* Before/after tile in the community feed — two photos with corner labels. */
.post__ba { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; width: 100%; }
.post__bafig { position: relative; margin: 0; }
.post__bafig img { width: 100%; height: 100%; aspect-ratio: 1; object-fit: cover; display: block; }
.post__bafig figcaption { position: absolute; left: 8px; bottom: 8px; font: 700 .68rem/1 var(--font-body); letter-spacing: .04em; text-transform: uppercase; color: #fff; background: rgba(23,29,37,.62); padding: 3px 8px; border-radius: 999px; }
.post__ba.post__media--zoom { cursor: zoom-in; }
.post__body { padding: var(--space-m); min-width: 0; }
.post__head { display: flex; align-items: center; gap: .6rem; }
.post__who b { display: block; line-height: 1.1; }
.post__who small { color: var(--ink-faint); }
.post__stars { color: var(--gold-deep); letter-spacing: 1px; font-size: .85rem; }
.post__caption { margin: var(--space-s) 0; }
.likebtn { border: 1px solid var(--line); background: var(--paper); border-radius: var(--radius-pill); padding: .3rem .75rem; cursor: pointer; font: inherit; color: var(--ink-soft); }
.likebtn.is-liked { color: #d23b6a; border-color: #f3c6d4; background: #fdecf1; }
.post__comments { margin-top: var(--space-s); display: grid; gap: .4rem; }
.pcomment { background: var(--cream); border-radius: var(--radius-s); padding: .4rem .65rem; font-size: .9rem; }
.pcomment__role { font-size: .62rem; text-transform: capitalize; background: var(--gold-soft); color: var(--gold-deep); padding: 1px 7px; border-radius: var(--radius-pill); margin-left: .3rem; }
.pcomment p { margin: .1rem 0 0; }
.post__addc { display: flex; gap: .4rem; margin-top: var(--space-s); }
.post__cin { flex: 1; min-width: 0; padding: .45rem .6rem; border: 1px solid var(--line); border-radius: var(--radius-s); font: inherit; }
.starpick { display: flex; gap: .15rem; }
.starpick__s { background: none; border: 0; font-size: 1.6rem; cursor: pointer; color: var(--gold-deep); padding: 0; line-height: 1; }
.toggle { display: inline-flex; align-items: center; gap: .5rem; font-weight: 700; cursor: pointer; }
.modrow { display: flex; gap: var(--space-s); align-items: center; padding: var(--space-s) 0; border-bottom: 1px solid var(--line); }
.modrow:last-child { border-bottom: 0; }
.modrow__media { width: 64px; height: 64px; border-radius: var(--radius-m); background: var(--gold-soft); display: grid; place-items: center; font-size: 1.8rem; overflow: hidden; flex-shrink: 0; }
.modrow__media img { width: 100%; height: 100%; object-fit: cover; }
.modrow__body { flex: 1; min-width: 0; }
.modrow__body p { margin: .2rem 0 0; }
.modrow__act { display: flex; flex-direction: column; gap: .3rem; flex-shrink: 0; }

/* --- Top toolbar (staff + client app shell) ------------------------------ */
.toolbar { position: sticky; top: 0; z-index: 40; background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: 0 1px 0 rgba(23,29,37,.04); }
.toolbar__inner { max-width: 1180px; margin-inline: auto; display: flex; align-items: center; gap: var(--space-m); padding: .55rem var(--space-l); flex-wrap: wrap; }
.toolbar__brand { flex-shrink: 0; }
.toolbar__badge { margin-left: .5rem; }
.toolbar__nav { display: flex; align-items: center; gap: .25rem; flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: thin; }
.toolbar__nav::-webkit-scrollbar { height: 0; }
.tnav__item { display: inline-flex; align-items: center; gap: .45rem; padding: .46rem .8rem; line-height: 1; border-radius: var(--radius-pill); color: var(--ink-soft); font-weight: 600; white-space: nowrap; position: relative; transition: background var(--dur) var(--ease), color var(--dur) var(--ease); }
.tnav__item:hover { background: var(--cream); color: var(--ink); }
.tnav__item:focus-visible { outline: 2px solid var(--tang); outline-offset: 2px; }
.tnav__item[aria-current="page"] { background: var(--gold-soft); color: var(--gold-deep); font-weight: 700; }
.tnav__icon { display: inline-flex; flex: none; }
.tnav__icon .glyph { width: 18px; height: 18px; display: block; }
.pnav__soon { font-size: .58rem; background: var(--line); color: var(--ink-faint); border-radius: var(--radius-pill); padding: 1px 6px; margin-left: .25rem; }
.toolbar__actions { display: flex; align-items: center; gap: .6rem; flex-shrink: 0; margin-left: auto; }
.toolbar-main { max-width: 1180px; margin-inline: auto; padding: var(--space-l); }

/* Cascade fade-in: applied to the page content area for one beat right after a
   page mounts (added by spa.js, removed after the run so live re-renders don't
   re-animate). Direct children stagger in top→bottom — snappy, then settled. */
@keyframes pawCascadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.paw-cascade > * { animation: pawCascadeIn .45s cubic-bezier(.22, .61, .36, 1) both; }
.paw-cascade > *:nth-child(1) { animation-delay: 0ms; }
.paw-cascade > *:nth-child(2) { animation-delay: 55ms; }
.paw-cascade > *:nth-child(3) { animation-delay: 110ms; }
.paw-cascade > *:nth-child(4) { animation-delay: 160ms; }
.paw-cascade > *:nth-child(5) { animation-delay: 205ms; }
.paw-cascade > *:nth-child(6) { animation-delay: 245ms; }
.paw-cascade > *:nth-child(7) { animation-delay: 280ms; }
.paw-cascade > *:nth-child(n+8) { animation-delay: 310ms; }   /* cap the tail so long pages don't drag */
@media (prefers-reduced-motion: reduce) { .paw-cascade > * { animation: none; } }

/* Account menu — replaces the always-visible sign-out chip. The avatar opens a
   small popover holding identity + sign out, so the bar reads calmer. */
.acct { position: relative; flex: none; }
.acct__btn { display: inline-flex; align-items: center; gap: .4rem; background: none; border: 0; padding: .25rem .4rem .25rem .25rem; border-radius: var(--radius-pill); cursor: pointer; font: inherit; color: var(--ink); transition: background var(--dur) var(--ease); }
.acct__btn:hover { background: var(--cream); }
.acct__btn:focus-visible { outline: 2px solid var(--tang); outline-offset: 2px; }
.acct__name { font-weight: 700; font-size: var(--step--1); max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct__chev .glyph { width: 15px; height: 15px; display: block; color: var(--ink-faint); transition: transform var(--dur) var(--ease); }
.acct__btn[aria-expanded="true"] .acct__chev .glyph { transform: rotate(180deg); }
.acct__menu { position: absolute; right: 0; top: calc(100% + 8px); width: 216px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-l); box-shadow: var(--shadow-l); padding: 6px; z-index: 60; }
.acct__menu[hidden] { display: none; }
.acct__hd { display: flex; align-items: center; gap: .55rem; padding: .55rem .55rem .6rem; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.acct__hd b { display: block; font-size: var(--step--1); line-height: 1.2; }
.acct__hd .role { color: var(--ink-faint); font-size: .76rem; text-transform: capitalize; }
.acct__item { display: flex; align-items: center; gap: .6rem; width: 100%; padding: .55rem; border-radius: var(--radius-s); color: var(--ink-soft); font: inherit; font-weight: 600; font-size: var(--step--1); text-decoration: none; background: none; border: 0; cursor: pointer; text-align: left; }
.acct__item .glyph { width: 17px; height: 17px; flex: none; }
.acct__item:hover { background: var(--cream); color: var(--ink); }
.acct__item--danger { color: var(--tang-deep); }
.acct__item--danger:hover { background: #fbeae2; color: var(--tang-deep); }

/* Staff avatar — neutral silhouette per the brand convention (never initials). */
.avatar--staff { background: var(--gold-soft); color: var(--ink-faint); }
.avatar--staff .glyph { width: 64%; height: 64%; }

/* ===== Avatar picker modal ===== */
.avpick { position: fixed; inset: 0; z-index: 140; display: flex; align-items: center; justify-content: center;
  padding: 16px; background: rgba(23, 29, 37, .5); backdrop-filter: blur(2px); opacity: 0; transition: opacity .18s ease; }
.avpick.is-open { opacity: 1; }
.avpick__card { background: #fff; border-radius: var(--radius-l); width: min(560px, 100%); max-height: 88vh;
  display: flex; flex-direction: column; box-shadow: var(--shadow-l); overflow: hidden;
  transform: translateY(10px) scale(.98); transition: transform .22s cubic-bezier(.22, .61, .36, 1); }
.avpick.is-open .avpick__card { transform: none; }
.avpick__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: var(--space-l) var(--space-l) var(--space-s); }
.avpick__title { font-family: var(--font-display); font-size: var(--step-2); margin: 0; line-height: 1.1; }
.avpick__sub { color: var(--ink-soft); margin: 4px 0 0; font-size: var(--step--1); }
.avpick__x { border: 0; background: none; font-size: 1.7rem; line-height: 1; color: var(--ink-faint); cursor: pointer; padding: 0 4px; }
.avpick__x:hover { color: var(--ink); }
.avpick__preview { display: flex; align-items: center; gap: 14px; padding: 0 var(--space-l) var(--space-m); }
.avpick__big { width: 68px; height: 68px; border-radius: 50%; overflow: hidden; flex: none; display: grid; place-items: center;
  background: var(--gold-soft); box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--gold); }
.avpick__big img { width: 100%; height: 100%; object-fit: cover; }
.avpick__bigph { font-weight: 800; color: var(--ink-faint); font-size: 1.5rem; }
.avpick__previewtxt { display: flex; flex-direction: column; gap: 4px; }
.avpick__previewlabel { color: var(--ink-soft); font-size: var(--step--1); }
.avpick__shuffle { align-self: flex-start; border: 1px solid var(--line); background: #fff; color: var(--ink-soft);
  border-radius: var(--radius-pill); padding: .3rem .7rem; font: inherit; font-size: .8rem; font-weight: 700; cursor: pointer; }
.avpick__shuffle:hover { border-color: var(--gold); color: var(--ink); }
.avpick__grid { overflow-y: auto; padding: var(--space-2xs) var(--space-l) var(--space-s);
  display: grid; grid-template-columns: repeat(auto-fill, minmax(62px, 1fr)); gap: 12px; }
.avpick__tile { border: 0; background: none; padding: 0; cursor: pointer; position: relative; aspect-ratio: 1;
  border-radius: 50%; transition: transform .12s ease; }
.avpick__tile img { width: 100%; height: 100%; border-radius: 50%; display: block; }
.avpick__tile:hover { transform: scale(1.07); }
.avpick__tile:focus-visible { outline: 2px solid var(--tang); outline-offset: 3px; }
.avpick__tile.is-selected { box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--tang); }
.avpick__tile.is-selected::after { content: "\2713"; position: absolute; right: -3px; bottom: -3px; width: 22px; height: 22px;
  background: var(--tang); color: #fff; border-radius: 50%; display: grid; place-items: center; font-size: .78rem; font-weight: 800;
  box-shadow: 0 1px 5px rgba(23, 29, 37, .3); }
.avpick__loading { padding: 28px; text-align: center; color: var(--ink-faint); grid-column: 1 / -1; }
.avpick__foot { display: flex; justify-content: flex-end; gap: 10px; padding: var(--space-s) var(--space-l) var(--space-l); border-top: 1px solid var(--line); }
@media (max-width: 480px) { .avpick__grid { grid-template-columns: repeat(auto-fill, minmax(54px, 1fr)); gap: 10px; } }
@media (prefers-reduced-motion: reduce) { .avpick, .avpick__card { transition: none; } }

/* Staff bar runs a touch denser, with a hairline divider before the tools. */
.toolbar--staff .toolbar__nav { gap: .25rem; }
.toolbar--staff .tnav__item { padding: .46rem .72rem; }
.toolbar--staff .toolbar__actions { padding-left: .7rem; border-left: 1px solid var(--line); }

/* Notification bell */
.bell { position: relative; }
.bell__btn { position: relative; background: var(--cream); border: 1px solid var(--line); width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 1.1rem; line-height: 1; }
.bell__btn:hover { background: var(--gold-soft); }
.bell__badge { position: absolute; top: -3px; right: -3px; background: #ec6a2e; color: #fff; font-size: .62rem; font-weight: 800; min-width: 17px; height: 17px; border-radius: 9px; display: grid; place-items: center; padding: 0 4px; }
.bell__badge[hidden] { display: none; }
.bell__panel { position: absolute; right: 0; top: calc(100% + 8px); width: min(344px, 92vw); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-l); box-shadow: var(--shadow-l); z-index: 60; overflow: hidden; }
.bell__head { display: flex; align-items: center; justify-content: space-between; padding: .65rem var(--space-s); border-bottom: 1px solid var(--line); }
.bell__clear { background: none; border: 0; color: var(--gold-deep); font: inherit; font-weight: 700; cursor: pointer; font-size: .8rem; }
.bell__list { max-height: 60vh; overflow-y: auto; }
.notif { display: flex; gap: .6rem; align-items: flex-start; padding: .6rem var(--space-s); border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; }
.notif:last-child { border-bottom: 0; }
.notif:hover { background: var(--cream); }
.notif.is-unread { background: var(--gold-soft); }
.notif__ic { font-size: 1.1rem; line-height: 1.3; }
.notif__body { display: grid; gap: 1px; flex: 1; min-width: 0; }
.notif__body b { font-size: .86rem; }
.notif__body span { color: var(--ink-soft); font-size: .82rem; }
.notif__body small { color: var(--ink-faint); font-size: .72rem; }
.notif__dot { width: 8px; height: 8px; border-radius: 50%; background: #ec6a2e; margin-top: 6px; flex-shrink: 0; }
.bell__empty { padding: var(--space-m); text-align: center; color: var(--ink-faint); }

@media (max-width: 640px) {
  .bell__panel { position: fixed; top: 58px; right: 8px; left: auto; width: min(344px, calc(100vw - 16px)); }
}
@media (max-width: 860px) {
  .toolbar__nav { order: 3; flex-basis: 100%; gap: .4rem; padding-block: .25rem; }
  .toolbar--staff .toolbar__nav { gap: .4rem; }
  .toolbar--staff .tnav__item { padding: .44rem .7rem; }
  .toolbar__actions { order: 2; }
  .tnav__item { padding: .42rem .72rem; }
}
@media (max-width: 560px) {
  .toolbar__site, .acct__name, .toolbar__badge { display: none; }
  .toolbar--staff .toolbar__actions { border-left: 0; padding-left: 0; }
  .toolbar-main { padding: var(--space-m); }
  .toolbar__inner { padding: .5rem var(--space-m); }
}
@media (prefers-reduced-motion: reduce) {
  .tnav__item, .acct__btn, .acct__chev .glyph { transition: none; }
}

/* Toolbar "+ New" menu */
.tbmenu { position: relative; }
.tbmenu__panel { position: absolute; right: 0; top: calc(100% + 8px); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-m); box-shadow: var(--shadow-l); z-index: 60; min-width: 192px; padding: 4px; display: grid; gap: 2px; }
.tbmenu__panel[hidden] { display: none; }
.tbmenu__panel button { display: block; width: 100%; text-align: left; background: none; border: 0; font: inherit; font-weight: 700; padding: .55rem .7rem; border-radius: var(--radius-s); cursor: pointer; color: var(--ink); }
.tbmenu__panel button:hover { background: var(--cream); }
@media (max-width: 640px) {
  .tbmenu__panel { position: fixed; top: 58px; right: 8px; left: auto; }
}

/* --- Messaging ----------------------------------------------------------- */
.msg-layout { display: grid; grid-template-columns: 300px 1fr; gap: var(--space-m); height: min(70vh, 640px); }
.msg-threads { border: 1px solid var(--line); border-radius: var(--radius-l); overflow-y: auto; background: var(--paper); }
.thread { display: flex; align-items: center; gap: .6rem; width: 100%; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--line); padding: .7rem var(--space-s); cursor: pointer; font: inherit; }
.thread:hover { background: var(--cream); }
.thread.is-active { background: var(--gold-soft); }
.thread__main { flex: 1; min-width: 0; display: grid; gap: 1px; }
.thread__top { display: flex; justify-content: space-between; gap: .4rem; align-items: baseline; }
.thread__top small { color: var(--ink-faint); font-size: .7rem; flex-shrink: 0; }
.thread__prev { color: var(--ink-soft); font-size: .8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.thread__unread { background: #ec6a2e; color: #fff; font-size: .66rem; font-weight: 800; min-width: 18px; height: 18px; border-radius: 9px; display: grid; place-items: center; padding: 0 5px; flex-shrink: 0; }
.msg-convo { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius-l); background: var(--paper); overflow: hidden; }
.msg-convo__head { display: flex; align-items: center; gap: .6rem; padding: .6rem var(--space-s); border-bottom: 1px solid var(--line); font-family: var(--font-display); }
.msg-back { display: none; background: none; border: 0; font-size: 1.2rem; cursor: pointer; }
.chat { flex: 1; overflow-y: auto; padding: var(--space-m); display: flex; flex-direction: column; gap: .5rem; }
.msg-card { display: flex; flex-direction: column; height: min(68vh, 600px); padding: 0; overflow: hidden; }
.bubble { max-width: 78%; padding: .5rem .75rem; border-radius: var(--radius-m); display: grid; gap: 2px; }
.bubble__who { font-size: .66rem; font-weight: 800; color: var(--gold-deep); }
.bubble__body { line-height: 1.35; overflow-wrap: anywhere; }
.bubble__time { font-size: .62rem; color: var(--ink-faint); justify-self: end; }
.bubble--them { background: var(--cream); align-self: flex-start; border-bottom-left-radius: 4px; }
.bubble--me { background: var(--gold-soft); align-self: flex-end; border-bottom-right-radius: 4px; }
.bubble--me .bubble__time { color: var(--gold-deep); }
.msg-composer { display: flex; gap: .4rem; padding: var(--space-s); border-top: 1px solid var(--line); }
.msg-composer input { flex: 1; min-width: 0; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: var(--radius-pill); font: inherit; }
@media (max-width: 720px) {
  .msg-layout { grid-template-columns: 1fr; height: auto; }
  .msg-layout .msg-convo { display: none; }
  .msg-layout.show-convo .msg-threads { display: none; }
  .msg-layout.show-convo .msg-convo { display: flex; height: min(70vh, 560px); }
  .msg-back { display: inline; }
  .msg-threads { max-height: 70vh; }
}

/* Email-verification banner + locked feature cards (v1.1.0) */
.verify-bar { display:flex; align-items:center; gap:var(--space-s); flex-wrap:wrap;
  background:var(--gold-soft, #f7eddc); border-bottom:1px solid var(--line);
  padding:var(--space-s) var(--space-m); }
.verify-bar__msg { font-weight:700; color:var(--ink-soft); font-size:var(--step--1); }
.lockcard { text-align:center; }
.lockcard__icon { font-size:2rem; margin-bottom:var(--space-2xs); }
.is-locked { position:relative; opacity:.55; pointer-events:none; filter:grayscale(.3); }

/* Multi-pet visit card (v1.9.0) — one arrival control, per-pet progress rows. */
.vpets{ display:flex; flex-direction:column; gap:.5rem; }
.vpet{ display:flex; align-items:center; gap:.6rem; padding:.5rem .65rem; border:1px solid var(--line); border-radius:12px; background:var(--paper); }
.vpet__icon{ font-size:1.1rem; flex:0 0 auto; }
.vpet__main{ flex:1; min-width:0; }
.vpet__name{ font-weight:800; line-height:1.1; }
.vpet__svc{ color:var(--ink-soft); font-size:.8rem; }
.visit .live-note{ margin-top:.55rem; }
.visit .btn--block{ margin-top:.65rem; }

/* ===== Modern notification bell + itemized manager (v1.24.0) ===== */
.bell__btn { display: grid; place-items: center; color: var(--ink); }
.bell__btn svg { width: 21px; height: 21px; }
.notif__ic { width: 30px; height: 30px; border-radius: 50%; background: var(--gold-soft);
  color: var(--gold-deep); display: grid; place-items: center; flex: 0 0 auto; }
.notif__ic svg { width: 17px; height: 17px; }

.nmgr { padding: 0 !important; overflow: hidden; }
.nmgr__bar { width: 100%; display: flex; align-items: center; gap: .6rem; background: none; border: 0;
  cursor: pointer; padding: 12px 14px; text-align: left; color: var(--ink); }
.nmgr__icon { width: 34px; height: 34px; flex: 0 0 auto; border-radius: 50%; background: var(--gold-soft);
  color: var(--gold-deep); display: grid; place-items: center; }
.nmgr__icon svg { width: 19px; height: 19px; }
.nmgr__sum { flex: 1 1 auto; display: flex; flex-direction: column; line-height: 1.25; }
.nmgr__sum b { font-weight: 800; font-size: .95rem; }
.nmgr__sum small { color: var(--ink-faint); font-size: .76rem; font-weight: 700; }
.nmgr__chev { color: var(--ink-faint); display: grid; place-items: center; transition: transform .2s ease; }
.nmgr__chev svg { width: 18px; height: 18px; display: block; }
.nmgr__chev.is-open { transform: rotate(180deg); }
.nmgr__body { padding: 2px 14px 12px; border-top: 1px solid var(--line); }
.nmgr__device { display: flex; align-items: center; justify-content: space-between; gap: .6rem; flex-wrap: wrap;
  font-size: .85rem; font-weight: 700; color: var(--ink-soft); padding: 12px 0; }
.nmgr__on { display: inline-flex; align-items: center; gap: .45rem; }
.nmgr__acts { display: inline-flex; gap: .9rem; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--gold-deep); font: inherit; font-weight: 800;
  font-size: .82rem; cursor: pointer; }
.linkbtn:hover { text-decoration: underline; }
.nmgr__note { font-size: .8rem; color: var(--ink-faint); padding: 10px 0; margin: 0; }
.nmgr__list { display: flex; flex-direction: column; }
.nrow { display: flex; align-items: center; gap: .8rem; padding: 11px 0; border-top: 1px solid var(--line); cursor: pointer; margin: 0; }
.nrow__txt { flex: 1 1 auto; display: flex; flex-direction: column; line-height: 1.2; }
.nrow__txt b { font-weight: 700; font-size: .9rem; color: var(--ink); }
.nrow__txt small { color: var(--ink-faint); font-size: .76rem; }
.nswitch { position: relative; flex: 0 0 auto; width: 44px; height: 26px; }
.nswitch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.nswitch__t { position: absolute; inset: 0; border-radius: 999px; background: #d6d3cb; transition: background .18s ease; }
.nswitch__t::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .18s ease; }
.nswitch input:checked + .nswitch__t { background: var(--tang); }
.nswitch input:checked + .nswitch__t::after { transform: translateX(18px); }
.nswitch input:focus-visible + .nswitch__t { outline: 2px solid var(--tang); outline-offset: 2px; }

/* "Share the glow-up" — bold dashboard card teeing up a one-tap community repost */
.glow { display: grid; grid-template-columns: 176px 1fr; padding: 0; overflow: hidden; border: 1px solid var(--gold); }
.glow__media { background: var(--cream); }
.glow__media img { width: 100%; height: 100%; min-height: 210px; object-fit: cover; display: block; }
.glow__body { padding: var(--space-l); }
.glow__body h2 { font-size: var(--step-2); margin: var(--space-2xs) 0; }
.glow__body p { color: var(--ink-soft); font-size: var(--step--1); margin-bottom: var(--space-s); }
.glow__body textarea { width: 100%; margin: var(--space-s) 0; }
.glow__acts { display: flex; gap: var(--space-s); flex-wrap: wrap; }
@media (max-width: 560px) { .glow { grid-template-columns: 1fr; } .glow__media img { min-height: 160px; max-height: 240px; } }

/* Photo thumbnail in a notification (e.g. the completion glow shot) */
.notif__ic--img { width: 40px; height: 40px; flex: none; padding: 0; }
.notif__ic--img img { width: 40px; height: 40px; border-radius: 9px; object-fit: cover; display: block; }

/* Disabled buttons (e.g. reschedule/cancel once a pet is checked in) */
.btn:disabled, .btn[disabled] { opacity: .45; cursor: not-allowed; box-shadow: none; }
.appt__locknote { margin: var(--space-s) 0 0; font-size: var(--step--1); color: var(--ink-faint); }

/* Notifications manager opened from the avatar chevron menu */
.nmodal { position: fixed; inset: 0; z-index: 210; background: rgba(23,29,37,.5); display: grid; place-items: start center; padding: clamp(12px, 6vh, 64px) var(--space-m); overflow-y: auto; }
.nmodal__card { background: var(--surface); border-radius: var(--radius-l); width: min(440px, 100%); box-shadow: var(--shadow-l); border: 1px solid var(--line); }
.nmodal__head { display: flex; align-items: center; justify-content: space-between; padding: var(--space-m) var(--space-l); border-bottom: 1px solid var(--line); }
.nmodal__head b { font-family: var(--font-display); font-size: var(--step-1); }
.nmodal__x { background: none; border: 0; font-size: 1.5rem; line-height: 1; color: var(--ink-faint); cursor: pointer; }
.nmodal__body { padding: var(--space-m) var(--space-l) var(--space-l); }
/* Embedded manager (inside the modal): drop the card chrome, it's already framed */
.nmgr--embedded { border: 0; padding: 0; background: none; box-shadow: none; }
.nmgr--embedded .nmgr__body { display: block; }

/* Slim "notifications are off" reminder (dashboard / appointments / community) */
.notifoff { display: flex; align-items: center; gap: .5rem; width: 100%; border: 0; cursor: pointer;
  background: rgba(236,106,46,.12); color: var(--tang-deep); font: inherit; font-weight: 700; font-size: var(--step--1);
  padding: .4rem var(--space-l); border-bottom: 1px solid rgba(236,106,46,.35); text-align: left; }
.notifoff:hover { background: rgba(236,106,46,.18); }
.notifoff__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--tang); flex: none; }
.notifoff b { text-decoration: underline; }

/* Groom photo + "share to community" on an appointment card */
.appt-photo { display: flex; gap: var(--space-m); align-items: center; margin-top: var(--space-s);
  padding: var(--space-s); background: var(--cream); border-radius: var(--radius-m); }
.appt-photo__img { width: 96px; height: 96px; object-fit: cover; border-radius: var(--radius-s); flex: none; }
.appt-photo__body { display: flex; flex-direction: column; gap: .2rem; min-width: 0; }
.appt-photo__body b { font-size: var(--step-0); }
.appt-photo__body span { color: var(--ink-soft); font-size: var(--step--1); }
.appt-photo__body .btn { align-self: flex-start; margin-top: .3rem; }
.appt-photo__done { color: var(--ink-faint); font-weight: 700; font-size: var(--step--1); margin-top: .2rem; }
@media (max-width: 460px) {
  .appt-photo { flex-direction: column; align-items: stretch; }
  .appt-photo__img { width: 100%; height: 190px; }
}

/* Owner moderation: delete a post or a comment from the community feed */
.post__actions { display: flex; align-items: center; gap: .6rem; }
.post__del { margin-left: auto; background: none; border: 0; color: var(--tang-deep); font: inherit; font-weight: 700; font-size: var(--step--1); cursor: pointer; padding: .2rem .45rem; border-radius: var(--radius-s); }
.post__del:hover { background: #fbeae2; }
.pcomment__del { background: none; border: 0; color: var(--ink-faint); cursor: pointer; font-size: 1.05rem; line-height: 1; padding: 0 .15rem; vertical-align: middle; }
.pcomment__del:hover { color: var(--tang-deep); }

/* Community: header row + distinctive share button */
.phead--row { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-m); flex-wrap: wrap; }
.phead--row > div { min-width: 0; }
.sharebtn { flex-shrink: 0; white-space: nowrap; border: 0; color: #3a2410; font-weight: 800;
  background: linear-gradient(135deg, var(--gold) 0%, var(--tang) 100%);
  box-shadow: 0 6px 18px rgba(231,171,106,.45); }
.sharebtn:hover { filter: brightness(1.04); }
@media (max-width: 560px) { .phead--row .sharebtn { width: 100%; justify-content: center; } }

/* Bottom sheet (share composer) */
.sheet { position: fixed; inset: 0; z-index: 80; }
.sheet[hidden] { display: none; }
.sheet__scrim { position: absolute; inset: 0; background: rgba(23,29,37,.45); opacity: 0; transition: opacity .24s ease; }
.sheet.is-open .sheet__scrim { opacity: 1; }
.sheet__panel { position: absolute; left: 0; right: 0; bottom: 0; max-width: 560px; margin: 0 auto;
  background: var(--surface); border-radius: 20px 20px 0 0; overflow-y: auto; max-height: 88vh;
  padding: var(--space-s) var(--space-m) calc(var(--space-l) + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -12px 40px rgba(23,29,37,.22);
  transform: translateY(100%); transition: transform .26s cubic-bezier(.22,1,.36,1); }
.sheet.is-open .sheet__panel { transform: translateY(0); }
.sheet__grab { display: block; width: 42px; height: 5px; border: 0; border-radius: 999px; background: var(--line); margin: .2rem auto .6rem; cursor: pointer; }
.sheet__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--space-s); }
.sheet__head b { font-family: var(--font-display); font-size: var(--step-1); }
.sheet__x { background: none; border: 0; font-size: 1.5rem; line-height: 1; color: var(--ink-soft); cursor: pointer; padding: .1rem .3rem; }

/* Community "pack favorites" rail */
.favrail-wrap { margin-bottom: var(--space-m); }
.favrail__head { margin-bottom: var(--space-xs); }
.favrail__title { font-family: var(--font-display); font-weight: 600; font-size: var(--step-0); }
.favrail { display: flex; gap: var(--space-s); overflow-x: auto; padding-bottom: .35rem; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; }
.favcard { flex: 0 0 auto; width: 116px; scroll-snap-align: start; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-m); padding: .5rem; text-align: center; }
.favcard--mine { border-color: var(--gold); background: var(--gold-soft); }
.favcard__media { width: 100%; aspect-ratio: 1; border-radius: var(--radius-s); overflow: hidden; background: var(--cream);
  display: flex; align-items: center; justify-content: center; margin-bottom: .4rem; }
.favcard__media img { width: 100%; height: 100%; object-fit: cover; }
.favcard__glyph { font-size: 2rem; }
.favcard__name { font-weight: 800; font-size: .9rem; line-height: 1.1; }
.favcard__count { font-size: .76rem; color: var(--ink-soft); margin-top: .15rem; }

/* Event-entry badge on community posts (contest entries) */
.post__media { position: relative; }
.post__event { position: absolute; top: 8px; left: 8px; display: inline-flex; align-items: center; gap: 4px;
  font-size: .7rem; font-weight: 800; padding: .25em .6em; border-radius: 999px;
  background: rgba(231,171,106,.96); color: #2a1c0c; box-shadow: 0 1px 3px rgba(0,0,0,.25); max-width: calc(100% - 16px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Estimate → final price (client sees the original estimate struck through). */
.price--final{white-space:nowrap}
.price--final .price--est{color:var(--ink-faint);font-weight:600;opacity:.75;margin-right:.15em}
.appt-row .appt__price{margin-left:var(--space-s)}

/* Freshly-groomed photo card — keeps the client's finish photo prominent and
   reachable on the dashboard + appointments after the merged Ready/Complete. */
.freshgroom__grid { display: grid; gap: var(--space-m); grid-template-columns: 1fr; }
@media (min-width: 560px) { .freshgroom__grid { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); } }
.freshgroom__item { margin: 0; display: flex; flex-direction: column; gap: var(--space-s); }
.freshgroom__img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); background: var(--cream); }
.freshgroom__cap { display: flex; flex-direction: column; gap: var(--space-3xs); align-items: flex-start; }
.freshgroom__cap b { font-size: var(--step-0); }
.freshgroom__meta { color: var(--ink-faint); font-size: var(--step--1); }
.freshgroom__shared { color: var(--ink-soft); font-size: var(--step--1); font-weight: 700; }
.freshgroom__cap .btn { margin-top: var(--space-2xs); }

/* Client-side reminder banner (reminders.js) — imminent-appointment nudge above the page */
.rbanner { display: flex; align-items: center; gap: 11px; padding: 11px 16px; font-size: .9rem; color: var(--ink-soft);
  background: var(--gold-soft); border-bottom: 1px solid var(--line); animation: tierpop-in .15s ease-out; }
.rbanner--today { background: #e8f5ee; }
.rbanner__ic { font-size: 1.2rem; line-height: 1; flex: none; }
.rbanner__txt { flex: 1; line-height: 1.35; }
.rbanner__txt b { color: var(--ink); }
.rbanner__cta { flex: none; font-weight: 800; color: var(--tang-deep); text-decoration: none; padding: 4px 10px; border-radius: var(--radius-pill); }
.rbanner__cta:hover { background: rgba(0,0,0,.05); }
.rbanner__x { flex: none; border: 0; background: none; font-size: 1.3rem; line-height: 1; cursor: pointer; color: var(--ink-faint); }
.rbanner__x:hover { color: var(--ink); }

/* --- Itemized receipt + grouped past visits (v1.75) --- */
.rcpt { border: 1px solid var(--line); border-radius: var(--radius-m); padding: var(--space-m); background: var(--paper); }
.rcpt-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: var(--space-s); flex-wrap: wrap; }
.rcpt-title { font-family: var(--font-display); font-weight: 600; font-size: var(--step-1); }
.rcpt-meta { color: var(--ink-soft); font-size: var(--step--1); }
.rcpt-lines { display: flex; flex-direction: column; gap: 5px; }
.rcpt-line { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.rcpt-desc { color: var(--ink); }
.rcpt-line--add .rcpt-desc { color: var(--ink-soft); padding-left: var(--space-s); font-size: var(--step--1); }
.rcpt-line--add .rcpt-amt { color: var(--ink-soft); font-size: var(--step--1); font-weight: 700; }
.rcpt-sz { color: var(--ink-faint); text-transform: capitalize; font-size: .85em; }
.rcpt-amt { font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.rcpt-total { border-top: 1px solid var(--line); margin-top: var(--space-s); padding-top: var(--space-s); font-weight: 800; }
.rcpt-total .rcpt-amt { font-size: var(--step-1); }
.rcpt-note { color: var(--ink-faint); font-size: var(--step--1); margin: var(--space-2xs) 0 0; }
.rcpt-foot { color: var(--ink-soft); font-size: var(--step--1); margin: var(--space-s) 0 0; }
.past-visit { display: flex; flex-direction: column; gap: var(--space-s); margin-bottom: var(--space-m); }
.past-visit__again { align-self: flex-start; }
.appt-row--cancel { opacity: .7; }
.pay-subhead { font-family: var(--font-display); font-size: var(--step-0); margin: var(--space-m) 0 var(--space-2xs); color: var(--ink-soft); }
.pay-subhead:first-child { margin-top: 0; }

/* ===== Payments: due-today hero + activity + receipt pill (v1.77) ========= */
.pcard--list { padding: 0; overflow: hidden; }

/* Due-today hero */
.pay-due { position: relative; padding: 0; border: 0; background: linear-gradient(135deg, var(--gold), var(--tang)); box-shadow: var(--shadow-m); }
.pay-due::after { content: ""; position: absolute; inset: 2px; border-radius: calc(var(--radius) - 2px); background: var(--surface); z-index: 0; }
.pay-due > * { position: relative; z-index: 1; }
.pay-due { padding: 0; }
.pay-due__top, .pay-due__amt, .pay-due__lbl, .pay-due__pets, .pay-due__note { margin-left: 18px; margin-right: 18px; }
.pay-due__top { display: flex; align-items: center; gap: 8px; padding-top: 16px; }
.pay-due__eyebrow { font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--tang-deep); }
.pay-due__live { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; font-size: .72rem; font-weight: 800; color: #1f8a4c; }
.pay-due__live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #2fb567; animation: payPulse 1.8s infinite; }
@keyframes payPulse { 0% { box-shadow: 0 0 0 0 rgba(47,181,103,.5); } 70% { box-shadow: 0 0 0 7px rgba(47,181,103,0); } 100% { box-shadow: 0 0 0 0 rgba(47,181,103,0); } }
.pay-due__amt { font-family: var(--font-display); font-weight: 600; font-size: var(--step-4); line-height: 1; margin-top: 10px; }
.pay-due__lbl { color: var(--ink-soft); font-size: .9rem; margin: 2px 0 14px; }
.pay-due__pets { display: flex; flex-direction: column; gap: 10px; }
.pay-due__pet { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: var(--radius); background: var(--cream); }
.pay-due__photo { position: relative; flex: none; }
.pay-due__photo img { width: 64px; height: 64px; border-radius: 14px; object-fit: cover; display: block; background: var(--gold-soft); }
.pay-due__x { position: absolute; top: -7px; right: -7px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--surface); background: var(--ink); color: #fff; font-size: 14px; line-height: 1; cursor: pointer; display: grid; place-items: center; padding: 0; }
.pay-due__info { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 3px; }
.pay-due__pn { font-weight: 800; font-size: .98rem; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.pay-due__ps { color: var(--ink-faint); font-size: .82rem; }
.pay-due__shared { font-size: .8rem; font-weight: 700; color: #1f8a4c; }
.pay-due__price { margin-left: auto; align-self: flex-start; font-weight: 800; font-size: 1.05rem; }
.pay-due__note { display: flex; gap: 9px; align-items: center; color: var(--ink-soft); font-size: .84rem; padding: 12px 0 16px; }
.pay-due .btn--mini { align-self: flex-start; }

/* status pills */
.pill { display: inline-block; font-size: .66rem; font-weight: 800; padding: 3px 9px; border-radius: var(--radius-pill); letter-spacing: .02em; }
.pill--ready { background: var(--tang-soft); color: var(--tang-deep); }
.pill--done { background: #d9f3e2; color: #1f8a4c; }

/* recent activity */
.pay-sec { margin-top: var(--space-m); }
.pay-sec__h { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 9px; }
.pay-sec__h h2 { font-family: var(--font-display); font-weight: 600; font-size: var(--step-1); margin: 0; }
.pay-sec__h small { color: var(--ink-faint); font-size: .8rem; }
.act { display: flex; align-items: center; gap: 11px; padding: 12px 14px; border-bottom: .5px solid var(--line); }
.act:last-child { border-bottom: 0; }
.act__ic { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; font-size: 1.05rem; flex: none; background: var(--cream); }
.act__b { min-width: 0; flex: 1; }
.act__t { font-weight: 800; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act__w { color: var(--ink-faint); font-size: .8rem; }
.act__r { text-align: right; flex: none; }
.act__amt { font-weight: 800; }
.act__amt--est { color: var(--ink-faint); text-decoration: line-through; font-weight: 600; }
.act__k { display: block; color: var(--ink-faint); font-size: .72rem; }

/* ===== Floating Receipt pill (shell chrome) =============================== */
.rpill { position: fixed; right: 14px; z-index: 44; display: inline-flex; align-items: center; gap: 8px;
  background: linear-gradient(135deg, var(--gold), var(--tang)); color: #fff; font-weight: 800; font-size: .86rem;
  padding: 10px 15px 10px 13px; border-radius: var(--radius-pill); box-shadow: var(--shadow-l); border: none;
  text-decoration: none; cursor: pointer; animation: rpillRise .45s cubic-bezier(.2,.8,.2,1) both; }
.rpill svg { width: 18px; height: 18px; }
.rpill__amt { background: rgba(255,255,255,.25); border-radius: var(--radius-pill); padding: 1px 8px; font-size: .8rem; }
.rpill[hidden] { display: none; }
.rpill--browser { bottom: 18px; }
.rpill--shell { bottom: calc(var(--ashell-bar-h, 60px) + env(safe-area-inset-bottom) + 14px); }
@keyframes rpillRise { from { transform: translateY(14px) scale(.92); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .rpill { animation: none; } .pay-due__live::before { animation: none; } }

/* Prestige marks on the dashboard status hero */
.rephero__marks { display: flex; align-items: center; margin: .15rem 0 .1rem; font-size: 1.05rem; }
