/* Phone layout and controls shared by every jQuery Mobile page. */
:root {
  --coral: #EC4D5E;
  --plum: #2a0f2e;
  --cream: #F8F5F2;
  --muted: #69616d;
  --line: #e9e3e5;
  --card-shadow: 0 8px 28px #2a0f2e06;
  --iw-font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
.ui-page, #viewbooking {
  background: var(--cream);
  color: var(--plum);
  text-shadow: none;
  font-family: var(--iw-font);
}
.bookings-app { max-width: 540px; margin: auto; padding-bottom: 110px; }
.bookings-app * { box-sizing: border-box; }
.bookings-app button, .bookings-app a, .bookings-app input { font: inherit; text-shadow: none; }
.bookings-app button, .bookings-app a { touch-action: manipulation; }
.bookings-app button, .bookings-app .primary {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-height: 44px;
  margin: 0;
  padding: 11px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: white;
  color: var(--plum);
  box-shadow: none;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.35;
  cursor: pointer;
}
.bookings-app a { color: var(--plum); text-decoration: none; }
.bookings-app .primary { background: var(--coral); border-color: var(--coral); color: white; }
.bookings-app .primary:not(:disabled) { box-shadow: 0 6px 16px #ec4d5e18; }
.book-header {
  position: relative;
  padding: 48px 20px 30px;
  border-radius: 0 0 32px 32px;
  background-image: linear-gradient(110deg, #2a0f2ebf, #2a0f2e99), var(--lotus-image);
  background-size: cover;
  background-position: center;
  color: white;
  box-shadow: 0 10px 24px #2a0f2e19;
}
.brand-logo { display: block; width: 150px; height: auto; max-width: 100%; object-fit: contain; }
.book-title { margin-top: 24px; }
.book-title > div { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; min-width: 0; }
.book-title h1 { margin: 0; color: white; font-size: 30px; font-weight: 750; letter-spacing: -.8px; line-height: 1.2; }
.bookings-app .book-title > .primary { position: absolute; top: 56px; right: 20px; background: white; border-color: white; color: var(--coral); min-width: 90px; }
.week-chip { display: inline-block; font-size: 9px; font-weight: 750; background: #ffffff29; color: white; border-radius: 999px; padding: 5px 8px; text-transform: uppercase; white-space: nowrap; }
.muted { font-size: 12px; color: var(--muted); }
.book-header .muted { color: #fffffff2; margin: 8px 0 0; font-size: 14px; line-height: 1.5; }
.book-main { padding: 24px 20px; }
.switch { display: flex; background: #edeaec; border-radius: 14px; padding: 4px; gap: 4px; }
.bookings-app .switch button { flex: 1; border-radius: 11px; background: none; border: 0; color: var(--muted); font-size: 15px; }
.bookings-app .switch button[aria-pressed=true] { background: white; box-shadow: 0 2px 5px #2a0f2e08; color: var(--plum); }
.view-switch { margin-bottom: 24px; }
.attention { border: 1px solid #fff0f1; background: white; padding: 20px; border-radius: 20px; box-shadow: var(--card-shadow); margin-bottom: 24px; }
.attention h2 { color: var(--coral); font-size: 11px; letter-spacing: 1px; margin: 0 0 12px; text-transform: uppercase; }
.attention h2::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--coral); margin-right: 8px; }
.attention p { margin: 8px 0; font-size: 13px; line-height: 1.6; }
.attention strong { font-size: 17px; }
.attention .request-heading { margin: 0 0 6px; font-size: 18px; font-weight: 750; color: var(--plum); }
.attention .booking-note { border-left: 2px solid var(--coral); font-style: italic; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.actions > * { flex: 1; min-width: 44px; text-align: center; }
.actions a { display: inline-flex; align-items: center; justify-content: center; padding: 12px 8px; border: 1px solid var(--line); background: white; border-radius: 999px; font-size: 12px; min-height: 44px; }
.actions .cancel { color: #ac3145; background: white; }
.attention .actions .primary { flex-basis: 100%; min-height: 52px; font-size: 15px; }
.days { display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); gap: 4px; margin: 12px 0 24px; }
.days button { display: block; padding: 12px 0 6px; border: 0; border-radius: 20px; background: white; min-height: 72px; font-size: 16px; }
.days small { display: block; font-size: 9px; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.days button[aria-pressed=true] { background: var(--plum); color: white; }
.days button[aria-pressed=true] small { color: #ffffffe6; }
.dot { display: block; width: 5px; height: 5px; border-radius: 50%; background: #8e7d91; margin: 6px auto 0; }
.dot.pending { background: var(--coral); }
.bookings-app .week-nav { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 12px; font-weight: 700; }
.bookings-app .week-nav button { flex: 0 0 44px; width: 44px; height: 44px; padding: 0; background: white; border: 0; box-shadow: 0 2px 4px #2a0f2e08; font-size: 24px; }
.bookings-app #week-label { flex: 1; min-width: 0; text-align: center; line-height: 1.5; }
.bookings-app h2.day-heading, #timeline-title { font-size: 11px; text-transform: uppercase; letter-spacing: 1.4px; color: var(--muted); margin: 24px 0 14px; }
.day-heading { position: sticky; top: 0; background: var(--cream); padding: 10px 0; z-index: 1; }
.booking-card { background: white; border-radius: 18px; border: 1px solid #f0eaed; border-left: 3px solid #42bc8a; box-shadow: var(--card-shadow); margin-bottom: 12px; overflow: hidden; }
.booking-card.pending { border-color: #f7b7c0; border-left-color: var(--coral); }
.booking-card.expanded { border-left: 4px solid var(--coral); }
.bookings-app .card-toggle { border: 0; border-radius: 0; background: none; position: relative; width: 100%; display: grid; grid-template-columns: minmax(0,1fr); justify-items: start; text-align: left; gap: 8px; padding: 18px 16px; min-height: 120px; }
.card-toggle::after { content: "⋮"; position: absolute; top: 14px; right: 14px; font-size: 20px; color: var(--muted); }
.card-time { font-size: 11px; font-weight: 650; color: var(--muted); }
.card-name { flex: 1; min-width: 0; }
.card-name strong { display: block; font-size: 16px; overflow-wrap: anywhere; }
.card-name small { display: block; font-size: 12px; color: var(--muted); margin-top: 4px; }
.pill { display: inline-block; font-size: 8px; text-transform: uppercase; background: #eaf5ec; color: #28613c; border-radius: 999px; padding: 5px 7px; font-weight: 750; flex-shrink: 0; }
.pending .pill { color: #ac3145; background: #FFF5F6; }
.pill.source { color: #63406c; background: #f3edf5; }
.pill.reminder { color: #605665; background: var(--cream); }
.status-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.booking-detail { padding: 0 14px 18px; font-size: 12px; line-height: 1.6; }
.booking-note{white-space:pre-wrap;overflow-wrap:anywhere; background: var(--cream); color: #605665; padding: 12px; border-radius: 12px; }
.bookings-app .free { justify-content: flex-start; width: 100%; border: 1px dashed #dcd2db; background: transparent; color: var(--muted); margin-bottom: 12px; min-height: 54px; text-align: left; font-size: 12px; font-weight: 400; border-radius: 16px; }
.away { background: repeating-linear-gradient(45deg,#f3f0f2,#f3f0f2 10px,#ede8ed 10px,#ede8ed 20px); color: var(--muted); border-radius: 16px; padding: 16px; margin-bottom: 12px; font-size: 12px; }
.occupied { padding: 16px 12px; margin-bottom: 12px; border-radius: 16px; background: #edeaec; color: var(--muted); font-size: 12px; }
.list-controls { margin: 28px 0 16px; }
.search-label { display: block; font-size: 11px; margin: 16px 0 6px; color: var(--muted); }
.bookings-app input[type=search], .bookings-app input[type=date], .bookings-app #booking-search, .bookings-app #move-date { display: block; width: 100%; min-width: 0; min-height: 48px; border: 1px solid #ded8df; background: white; border-radius: 14px; padding: 12px; color: var(--plum); font-size: 14px; }
.book-tabs { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 540px; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: center; border-top: 1px solid #eee8ed; background: white; padding: 12px 8px calc(12px + env(safe-area-inset-bottom)); z-index: 5; }
.book-tabs a[href="#viewbooking"] { grid-column: 1 / 3; grid-row: 1; }
.book-tabs a[href="#viewclients"] { grid-column: 4; grid-row: 1; }
.book-tabs a[href="#logout"] { grid-column: 5; grid-row: 1; }
.book-tabs a { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 60px; min-height: 48px; text-align: center; color: #817887; }
.book-tabs svg { display: block; width: 25px; height: 25px; margin-bottom: 5px; }
.book-tabs span { display: block; font-size: 9px; text-transform: uppercase; font-weight: 700; letter-spacing: .7px; }
.book-tabs [aria-current] { color: var(--coral); }
.book-tabs .quick-new { grid-column: 3; grid-row: 1; justify-self: center; width: 64px; border: 4px solid var(--cream); background: var(--coral); color: white; border-radius: 50%; font-size: 34px; min-width: 64px; height: 64px; margin-top: -32px; box-shadow: 0 8px 20px #ec4d5e30; }
.bookings-app dialog { border: 0; border-radius: 24px 24px 0 0; padding: 0; position: fixed; top: auto; bottom: 0; margin: 0 auto; width: 100%; max-width: 540px; max-height: 90dvh; overflow: auto; background: var(--cream); color: var(--plum); box-shadow: 0 0 50px #0003; }
.bookings-app dialog::backdrop { background: #2a0f2e88; }
.sheet-inner { padding: 0 20px calc(22px + env(safe-area-inset-bottom)); }
.sheet-inner h2 { font: 750 24px/1.25 var(--iw-font); margin: 0 0 16px; overflow-wrap: anywhere; }
.bookings-app .sheet-header { margin: 0 -20px 20px; padding: 20px; border-radius: 24px 24px 20px 20px; }
.sheet-header .brand-logo { width: 112px; margin-bottom: 12px; }
.sheet-header h2 { color: white; margin: 0; }
.slot-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 16px 0; }
.bookings-app button:disabled { opacity: .5; cursor: default; }
.slot-grid [aria-pressed=true] { background: var(--coral); border-color: var(--coral); color: white; }
.sms-preview { font-size: 13px; background: white; border: 1px solid var(--line); border-radius: 16px; padding: 16px; white-space: pre-wrap; }
.text-choice { display: flex; align-items: center; gap: 10px; min-height: 48px; font-size: 14px; }
.text-choice input { width: 22px; height: 22px; accent-color: var(--coral); }
.notice { padding: 16px; background: #eaf5ec; color: #28613c; border-radius: 16px; margin-bottom: 16px; font-size: 14px; overflow-wrap: anywhere; }
.notice.warning, #move-error { color: #9b2638; background: #FFF5F6; }
#move-error:empty { display: none; }
#move-error { padding: 12px; border-radius: 12px; }
.bookings-app :focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; }
#list-note { text-align: center; padding: 24px 0; }
.bookings-app [hidden] { display: none !important; }
