/* Loyalty points (loyalty.js): the coin beside Muse and the rules sheet. */
.muse-stage { position: relative; }
.pts-badge {
  position: absolute; top: 4px; right: 0; width: 84px; min-height: 96px; padding: 8px 4px 6px;
  display: grid; justify-items: center; gap: 1px; cursor: pointer;
  border: 1.5px solid color-mix(in srgb, #d9a520 60%, var(--line)); border-radius: 20px;
  background: var(--surface); color: var(--ink); box-shadow: var(--shadow); -webkit-tap-highlight-color: transparent;
}
.pts-badge[hidden] { display: none; }
.pts-badge:active { transform: scale(.97); }
.pts-badge strong { font: 700 1.25rem/1.1 var(--sans); font-variant-numeric: tabular-nums; }
.pts-badge small { font: 500 .8125rem/1.1 var(--sans); color: var(--ink-2); }
.pts-rules { margin-top: 3px; padding: 2px 8px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font: 600 .75rem/1.3 var(--sans); }
.pts-coin { width: 36px; height: 36px; overflow: visible; }
.pts-badge .pts-coin { animation: pts-bob 3.2s ease-in-out infinite; }
.pts-coin circle, .pts-coin path { stroke: none; }
.pts-coin-edge { fill: #b9801a; }
.pts-coin-face { fill: #f5c542; }
.pts-coin .pts-coin-ring { fill: none; stroke: #d9a520; stroke-width: 1.4; }
.pts-coin-star { fill: #fff3c4; }
.pts-coin .pts-coin-shine { fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; opacity: .75; }
@keyframes pts-bob { 0%, 100% { transform: translateY(0) rotate(-4deg); } 50% { transform: translateY(-3px) rotate(4deg); } }

.pts-sheet {
  width: min(520px, calc(100% - 24px)); max-height: min(88dvh, 860px); padding: 0; border: 0; border-radius: 24px;
  background: var(--surface); color: var(--ink); box-shadow: 0 20px 60px rgba(0, 0, 0, .3);
}
.pts-sheet::backdrop { background: rgba(20, 12, 24, .55); }
.pts-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 12px 8px 20px; }
.pts-head h2 { margin: 0; font-size: 1.3rem; }
.pts-close { width: 44px; height: 44px; border: 0; border-radius: 50%; background: none; color: var(--ink-2); font-size: 1.7rem; line-height: 1; cursor: pointer; }
.pts-body { padding: 4px 20px 22px; }
.pts-total { display: flex; align-items: center; gap: 12px; }
.pts-total .pts-coin { width: 52px; height: 52px; flex: none; }
.pts-total p { margin: 0; font: 400 1.05rem/1.3 var(--sans); color: var(--ink-2); }
.pts-total strong { display: block; font: 700 2rem/1.1 var(--sans); color: var(--ink); font-variant-numeric: tabular-nums; }
.pts-bar { height: 10px; margin: 14px 0 8px; border-radius: 999px; background: var(--surface-2); overflow: hidden; border: 1px solid var(--line); }
.pts-bar span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #f5c542, #d9a520); }
.pts-next { margin: 0 0 16px; font: 500 1rem/1.4 var(--sans); }
.pts-body h3 { margin: 0 0 8px; font-size: 1.1rem; }
.pts-list { margin: 0 0 14px; padding-left: 1.3em; display: grid; gap: 8px; font: 400 1rem/1.45 var(--sans); }
.pts-soon { margin: 0 0 16px; padding: 10px 14px; border-radius: 14px; background: var(--accent-soft); color: var(--ink); font: 400 .95rem/1.4 var(--sans); }
.pts-done { width: 100%; min-height: 48px; border: 0; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font: 600 1.05rem var(--sans); cursor: pointer; }
@media (prefers-reduced-motion: reduce) { .pts-badge .pts-coin { animation: none; } }

/* Staff: the customer's points on the appointment, with redeem */
[data-pts-staff] { margin: 6px 0 4px; }
.pts-staff { display: grid; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface-2); }
.pts-staff-total { display: flex; align-items: center; gap: 10px; }
.pts-staff-total .pts-coin { width: 40px; height: 40px; flex: none; }
.pts-staff-total p { margin: 0; font: 400 1rem/1.25 var(--sans); color: var(--ink-2); }
.pts-staff-total strong { font: 700 1.4rem/1.1 var(--sans); color: var(--ink); font-variant-numeric: tabular-nums; }
.pts-staff-total small { display: block; font: 400 .875rem/1.3 var(--sans); }
.pts-staff-note { margin: 0; padding: 8px 12px; border-radius: 12px; background: var(--ok-soft, #e3f0e8); color: var(--ok, #2f7a52); font: 600 .95rem/1.35 var(--sans); }
.pts-staff-form { display: flex; gap: 8px; }
.pts-staff-form select { flex: 1; min-width: 0; min-height: 46px; padding: 0 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink); font: 500 1rem var(--sans); }
.pts-staff-go { flex: none; min-height: 46px; padding: 0 18px; border: 0; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font: 600 1rem var(--sans); cursor: pointer; }
.pts-staff-go:disabled { opacity: .55; }
