/* Shared treatment for booking, customer account and authenticated dashboard. */
:root {
  --bg: #f6f5ef;
  --card: #fdfdf9;
  --ink: #263b30;
  --ink-soft: #667366;
  --line: #dce1d6;
  --accent: #263b30;
  --accent-soft: #e5ebdf;
  --gold: #8a6542;
  --gold-soft: #eee7d8;
  --radius: 14px;
  --shadow: 0 6px 24px #263b3007;
}
body {
  background: var(--bg);
}
.app {
  background: transparent;
}
.topbar {
  background: #f6f5eff2;
  border-color: var(--line);
}
.brand .logo {
  display: none;
}
.brand:before {
  content: "仟";
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  font:
    22px Georgia,
    serif;
}
.brand h1 {
  font-family: Georgia, "PMingLiU", serif;
  letter-spacing: 0.12em;
  font-weight: 500;
}
.topbar .sub {
  letter-spacing: 0.06em;
}
.booking-home {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 22px;
  border-bottom: 1px solid var(--line);
  font-size: 11px;
  gap: 16px;
}
.booking-home a {
  color: var(--ink);
  text-decoration: none;
}
.booking-intro {
  padding: 28px 24px 6px;
  display: flex;
  align-items: center;
  gap: 22px;
}
.booking-intro img {
  width: 135px;
  height: 105px;
  object-fit: contain;
}
.booking-intro small {
  color: var(--ink-soft);
  font-size: 9px;
  letter-spacing: 0.14em;
}
.booking-intro h2 {
  font:
    25px Georgia,
    "PMingLiU",
    serif;
  margin: 7px 0;
}
.booking-intro p {
  font-size: 12px;
  color: var(--ink-soft);
  margin: 0;
}
.booking-mini {
  position: relative; flex: 0 0 auto; padding: 0; border: 0;
  background: transparent; cursor: pointer; border-radius: 18px;
  -webkit-tap-highlight-color: transparent;
}
.booking-mini img { display: block; position: relative; }
.booking-mini-float, .booking-mini-object { display: block; transform-origin: 50% 75%; }
.booking-mini-shadow {
  position: absolute; left: 22%; right: 18%; bottom: 5%; height: 12%;
  background: radial-gradient(ellipse, #263b302b, transparent 70%); border-radius: 50%;
}
.booking-mini-ring {
  position: absolute; inset: 12% 8%; border: 1px solid #8eac8c; border-radius: 50%;
  visibility: hidden; pointer-events: none;
}
.booking-motion-tools {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 0 24px 4px; min-height: 44px; color: var(--ink-soft); font-size: 10px;
}
.booking-motion-tools button {
  color: inherit; font: inherit; background: transparent; border: 0;
  padding: 10px 0 10px 14px; min-height: 44px; cursor: pointer; text-decoration: underline;
  text-underline-offset: 4px; white-space: nowrap;
}
.booking-motion-tools button[hidden] { display: none; }
.booking-motion-tools button:disabled { cursor: default; text-decoration: none; }
.booking-motion-status {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}
.booking-portrait-stage { transform-origin: 50% 90%; }
.staff .booking-portrait { position: relative; overflow: visible; }
.booking-portrait canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.booking-portrait.portrait-live img { visibility: hidden; }
.booking-portrait img { transform-origin: 50% 92%; }
@media (max-width: 480px) {
  .booking-intro { gap: 12px; padding: 20px 18px 6px; }
  .booking-intro img { width: 100px; height: 94px; }
  .booking-intro h2 { font-size: 21px; line-height: 1.45; }
  .booking-motion-tools { padding-inline: 18px; }
}
.staff .card {
  font: inherit;
  color: var(--ink);
  width: 100%;
  cursor: pointer;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(140deg, #fdfdf8, #e9eee1);
  box-shadow: 0 8px 20px #263b3007;
  transition:
    transform 0.2s,
    border 0.2s;
}
.staff .card:hover {
  transform: translateY(-3px);
}
.staff .card.sel {
  border: 2px solid var(--accent);
  background: #e7eedf;
}
.staff .avatar:has(img[src*="assets/salon"]) {
  height: 100px;
  width: 90px;
  margin: 0 auto 10px;
  background: transparent;
  border-radius: 0;
}
.staff .avatar img[src*="assets/salon"] {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0;
}
.staff .name {
  font-family: Georgia, serif;
  font-size: 23px;
  font-weight: 400;
}
.sec-title {
  font-weight: 500;
}
.sec-num {
  background: var(--accent);
  font-family: Georgia, serif;
}
.svc {
  border-radius: 10px;
}
.svc.sel {
  border-color: var(--accent);
  background: #e8eedf;
}
.btn {
  border-radius: 50px;
  box-shadow: 0 6px 16px #263b301a;
}
.cta {
  background: linear-gradient(to top, #f6f5effa 75%, transparent);
}
.pg-head h1 {
  font-weight: 500;
  font-family: Georgia, "PMingLiU", serif;
}
input,
textarea {
  accent-color: var(--accent);
}
a:focus-visible,
button:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid #bd5938;
  outline-offset: 3px;
}
.category-filter {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin: 0 0 18px;
}
.category-filter button {
  font: inherit;
  font-size: 11px;
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 25px;
  background: var(--card);
  cursor: pointer;
  color: var(--ink);
}
.category-filter button[aria-pressed="true"] {
  background: var(--accent);
  color: white;
}
.svc-group[hidden] {
  display: none;
}
.catalog-note {
  font-size: 11px;
  color: var(--ink-soft);
  margin-bottom: 15px;
}
.mini-foot a {
  color: var(--ink-soft);
}
@media (min-width: 900px) {
  .booking-intro {
    padding: 30px 26px 5px;
  }
  .booking-intro img {
    width: 170px;
    height: 120px;
  }
  .booking-intro h2 {
    font-size: 31px;
  }
  .booking-home {
    padding: 15px 26px;
  }
  .topbar {
    border-bottom: 0;
  }
  .app #flow {
    gap: 0 38px;
  }
  .app #flow section {
    scroll-margin-top: 150px;
  }
  .staff .avatar:has(img[src*="assets/salon"]) {
    height: 135px;
    width: 110px;
  }
  .app .cta {
    background: linear-gradient(to top, #f6f5effa 75%, transparent);
  }
}
.cancel-dialog {
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 30px;
  max-width: min(440px, calc(100vw - 32px));
  color: var(--ink);
  background: var(--bg);
}
.customer-calendar { margin: 16px 0; }
.customer-calendar a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; text-decoration: none; }
.customer-calendar a[hidden] { display: none; }
.customer-calendar p { font-size: 12px; line-height: 1.6; color: var(--ink-soft); }
.cancel-dialog::backdrop {
  background: #20302588;
  backdrop-filter: blur(5px);
}
.cancel-dialog h2 {
  font:
    25px Georgia,
    "PMingLiU",
    serif;
  margin: 0 0 15px;
}
.cancel-dialog p {
  font-size: 13px;
  line-height: 1.8;
  color: var(--ink-soft);
}
.cancel-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}
.cancel-actions button {
  flex: 1;
  padding: 12px;
  font-size: 12px;
}
.admin-scene {
  width: 230px;
  height: 180px;
  object-fit: contain;
  display: block;
  margin: -10px auto 15px;
}
.login-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fafbf5;
  max-width: 450px;
}
.login-card h1 {
  font:
    27px Georgia,
    "PMingLiU",
    serif;
}
.admin .login-card {
  margin: 60px auto;
}
body.login-bg {
  background: radial-gradient(
    ellipse at 50% 40%,
    #eef2e5,
    #f6f5ef 70%
  ) !important;
}
.abar {
  background: var(--accent);
}
.abar h1 {
  font-weight: 500;
}
.mycard {
  border: 1px solid var(--line);
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto !important;
  }
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
  }
}
.admin .login-card {
  max-width: min(450px, calc(100vw - 32px));
}
.cal-nav {
  font: inherit;
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
}
.timing-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 18px 0;
  border-top: 1px solid var(--line);
}
.timing-row h4, .timing-summary {
  grid-column: 1 / -1;
  margin: 0;
}
.timing-row h4 { font-size: 14px; }
.timing-row label, .timing-summary, .timing-sources {
  font-size: 12px;
  line-height: 1.7;
  color: var(--ink-soft);
}
.timing-row input { width: 100%; margin-top: 4px; }
.timing-row button { grid-column: 1 / -1; }
#serviceTimingBox { padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
#serviceTimingBox h3 { font-size: 15px; margin: 0 0 12px; }
.timing-sources { margin-bottom: 16px; }
