/* Public booking pages (/b/:slug, /booking/:token, /u/:handle). ASCII only. */
.bk-body { min-height: 100dvh; display: flex; flex-direction: column; align-items: center; padding: 32px 16px 16px; background: var(--bg); }
.bk { width: min(1040px, 100%); background: var(--bg-elev-1); border: 1px solid var(--rule); border-radius: var(--radius-xl); box-shadow: var(--shadow-md); display: grid; grid-template-columns: 300px minmax(0,1fr); overflow: hidden; outline: none; }
.bk-loading { padding: 40px; text-align: center; grid-column: 1 / -1; }
.bk-skip { position: absolute; left: -9999px; top: 8px; background: var(--bg-elev-1); padding: 8px 12px; border-radius: 8px; z-index: 10; }
.bk-skip:focus { left: 8px; }
.ic { display: inline-flex; }
.ic svg { width: 18px; height: 18px; }
.bk-info { padding: 28px 24px; border-right: 1px solid var(--rule); }
.bk-host { font-weight: 600; color: var(--fg-muted); margin: 14px 0 2px; }
.bk-info h1 { font: 700 24px/1.2 var(--font-display); margin: 0 0 12px; letter-spacing: -0.01em; }
.bk-facts { display: grid; gap: 10px; margin: 0 0 16px; }
.bk-facts div { display: flex; gap: 10px; align-items: flex-start; color: var(--fg-muted); font-weight: 500; }
.bk-facts .ic { margin-top: 1px; flex: 0 0 auto; }
.bk-desc { white-space: pre-wrap; color: var(--fg-muted); }
.bk-preview { grid-column: 1 / -1; margin: 0; padding: 10px 16px; background: #fef3c7; color: #713f12; font-weight: 600; font-size: 13px; border-bottom: 1px solid var(--rule); }

/* Picker */
.bk-pick { padding: 24px; display: grid; grid-template-columns: minmax(0,1fr) 240px; gap: 24px; align-content: start; }
.bk-pick h2 { font: 600 18px/1.3 var(--font-display); margin: 0; grid-column: 1 / -1; }
.bk-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; font-weight: 700; min-height: 44px; }
.bk-cal-head .icon-btn { width: 44px; height: 44px; }
.bk-cal-head .icon-btn:disabled { opacity: .35; cursor: default; }
.bk-cal { display: grid; gap: 4px; text-align: center; }
.bk-row { display: grid; grid-template-columns: repeat(7, minmax(0,1fr)); gap: 4px; }
.bk-cal .dow { font-size: 11px; font-weight: 700; color: var(--fg-muted); text-transform: uppercase; padding: 4px 0; }
.bk-day { aspect-ratio: 1; max-width: 48px; min-height: 40px; width: 100%; margin: 0 auto; display: grid; place-items: center; border-radius: 50%; border: 0; background: none; font-weight: 600; cursor: default; color: var(--fg-muted); }
.bk-day[aria-disabled="true"] { text-decoration: none; opacity: .62; }
.bk-day.open { background: var(--mmm-brand-soft); color: var(--ws-accent-strong); cursor: pointer; font-weight: 700; }
.bk-day.open:hover { background: rgba(220,38,38,.2); }
.bk-day[aria-pressed="true"] { background: var(--mmm-brand); color: #fff; }
.bk-day:focus-visible { outline: 3px solid var(--ws-focus); outline-offset: 2px; }
.bk-side { display: grid; gap: 12px; align-content: start; min-width: 0; }
.bk-times { display: flex; flex-direction: column; gap: 8px; }
.bk-times h3 { font-size: 14px; margin: 0 0 4px; }
.bk-tlist { display: flex; flex-direction: column; gap: 8px; max-height: 420px; overflow-y: auto; padding: 2px 4px 2px 2px; }
.bk-time { min-height: 44px; border: 1px solid var(--mmm-brand); color: var(--ws-accent-strong); background: var(--bg-elev-1); border-radius: var(--radius-md); font-weight: 700; cursor: pointer; flex: 0 0 auto; }
.bk-time:hover { background: var(--mmm-brand-soft); }
.bk-time[aria-pressed="true"] { background: var(--fg); border-color: var(--fg); color: var(--bg-elev-1); }
.bk-bar { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--rule-strong); border-radius: var(--radius-md); background: var(--bg-elev-1); }
.bk-bar-txt { display: grid; gap: 2px; font-size: 13px; }
.bk-go { min-height: 44px; font-size: 15px; }
.bk-tzrow { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; margin-top: 16px; }
.bk-tz { flex: 1 1 220px; max-width: 340px; }
.bk-tz label { display: inline-flex; gap: 6px; align-items: center; }
.bk-tz .ic svg { width: 14px; height: 14px; }
.bk-fmt { flex: 0 0 auto; margin-bottom: 22px; }
.bk-fmt button { min-height: 36px; min-width: 52px; }
.bk-hint { margin: 2px 0 0; font-size: 12px; font-weight: 500; color: var(--fg-muted); }
.bk-hint.bk-err { color: var(--ws-accent-strong); }
.bk-empty { display: grid; justify-items: start; gap: 6px; padding: 16px; border: 1px dashed var(--rule-strong); border-radius: var(--radius-md); color: var(--fg-muted); grid-column: 1 / -1; }
.bk-empty .ic svg { width: 24px; height: 24px; }
.bk-empty p { margin: 0; font-weight: 600; }
.sk { display: block; border-radius: 50%; aspect-ratio: 1; max-width: 48px; width: 100%; margin: 0 auto; background: var(--bg-elev-3); animation: pulse 1.2s ease-in-out infinite; }
.skel { grid-template-columns: repeat(7, minmax(0,1fr)); }
.sk-line { width: 140px; height: 18px; aspect-ratio: auto; border-radius: 6px; margin: 0; max-width: none; }
@keyframes pulse { 50% { opacity: .45; } }

/* Form */
.bk-form { padding: 24px; display: grid; gap: 14px; align-content: start; max-width: 580px; }
.bk-form h2 { margin: 0; font: 600 18px/1.3 var(--font-display); }
.bk-back { justify-self: start; }
.bk-when { display: flex; gap: 10px; align-items: flex-start; margin: 0; font-weight: 600; }
.bk-when .ic { margin-top: 2px; color: var(--fg-muted); }
.bk-when .dim { font-weight: 500; font-size: 13px; color: var(--fg-muted); }
.bk-field { display: grid; gap: 4px; font-size: 13px; font-weight: 600; color: var(--fg); }
.bk-field > label { color: var(--fg); }
.bk-field .toggle { font-size: 14px; }
.bk-field [aria-invalid="true"] { border-color: var(--ws-accent-strong); box-shadow: 0 0 0 1px var(--ws-accent-strong); }
.bk-ferr { margin: 0; font-size: 12px; font-weight: 600; color: var(--ws-accent-strong); }
.bk-err { margin: 0; padding: 10px 12px; border-radius: var(--radius-md); background: rgba(220,38,38,.10); color: var(--ws-accent-strong); font-weight: 600; font-size: 13px; }
.bk-hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.bk-submit { min-height: 44px; padding: 0 22px; font-size: 15px; }
.bk-form input[type=tel] { min-height: 38px; padding: 7px 10px; border: 1px solid var(--rule-strong); border-radius: var(--radius-md); background: var(--bg-elev-1); width: 100%; }

/* Confirmation + manage */
.bk-done { padding: 32px 24px; display: grid; gap: 14px; align-content: start; }
.bk-done h2 { font: 700 24px/1.2 var(--font-display); margin: 0; outline: none; }
.bk-check { width: 52px; height: 52px; border-radius: 50%; background: #15803d; color: #fff; display: grid; place-items: center; }
.bk-check.off { background: #475569; }
.bk-check svg { width: 28px; height: 28px; }
.bk-note { margin: 0; }
.bk-add h3 { margin: 0 0 8px; font-size: 14px; }
.bk-add .btn { min-height: 44px; }
.bk-link { font-weight: 700; }
.bk-small { font-size: 12px; margin: 0; color: var(--fg-muted); }
.bk-cancel summary { cursor: pointer; font-weight: 600; min-height: 44px; display: flex; align-items: center; }
.bk-msg:empty { display: none; }
.bk-missing { grid-column: 1 / -1; text-align: center; justify-items: center; }

/* Profile (/u/:handle) */
.bk-profile .bk { grid-template-columns: 1fr; width: min(760px, 100%); }
.bk-prof { padding: 32px 24px; display: grid; gap: 10px; justify-items: center; text-align: center; }
.bk-prof h1 { font: 700 26px/1.2 var(--font-display); margin: 6px 0 0; }
.bk-prof .bk-empty { justify-items: center; width: 100%; }
.bk-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; width: 100%; margin-top: 8px; text-align: left; }
.bk-card { display: grid; align-content: start; gap: 6px; padding: 16px; border: 1px solid var(--rule-strong); border-top: 4px solid var(--c); border-radius: var(--radius-md); text-decoration: none; color: var(--fg); background: var(--bg-elev-1); min-height: 44px; }
.bk-card:hover { box-shadow: var(--shadow-md); }
.bk-card strong { font: 600 16px/1.3 var(--font-display); }
.bk-card-facts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; color: var(--fg-muted); font-size: 13px; font-weight: 600; }
.bk-card-facts .ic svg { width: 15px; height: 15px; }
.bk-card-desc { font-size: 13px; }

.bk-foot { color: var(--fg-muted); font-size: 12px; margin: 16px 0; }
.bk-foot a { color: inherit; }

/* Embed mode (?embed=1): no page chrome, transparent, fills the iframe */
html.embed, body.embed { height: auto; min-height: 0; background: transparent; }
body.embed { padding: 0; }

body.embed .bk-foot, body.embed .bk-skip { display: none; }
body.embed .bk { width: 100%; box-shadow: none; }

/* Phones (B15): 44px targets, 16px inputs (no zoom), sticky selected time bar, no sideways scroll */
@media (max-width: 860px) {
  .bk-body { padding: 0; }
  .bk { grid-template-columns: minmax(0,1fr); border-radius: 0; border: 0; box-shadow: none; }
  .bk-info { border-right: 0; border-bottom: 1px solid var(--rule); padding: 18px 16px; }
  .bk-info .brand-mark { display: none; }
  .bk-host { margin-top: 0; }
  .bk-info h1 { font-size: 22px; margin-bottom: 8px; }
  .bk-facts { margin-bottom: 4px; gap: 6px; }
  .bk-desc { margin: 8px 0 0; }
  .bk-pick { grid-template-columns: minmax(0,1fr); padding: 16px; gap: 16px; }
  .bk-tlist { max-height: none; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); overflow: visible; }
  .bk-bar { position: sticky; bottom: 0; z-index: 5; grid-template-columns: minmax(0,1fr) auto; align-items: center; margin: 0 -16px -16px; border-radius: 0; border-width: 1px 0 0; box-shadow: 0 -8px 24px -12px rgba(0,0,0,.25); padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); }
  .bk-form, .bk-done, .bk-prof { padding: 16px; }
  .bk input, .bk select, .bk textarea { font-size: 16px; min-height: 44px; }
  .bk .btn { min-height: 44px; }
  .bk-day { min-height: 44px; }
  .bk-fmt { margin-bottom: 26px; }
  .bk-fmt button { min-height: 44px; }
  body.embed .bk-bar { margin: 0 -16px -16px; }
}
@media (max-width: 380px) { .bk-tlist { grid-template-columns: 1fr; } }

/* r50 S16 polish (2026-11-26): hover lifts, picked-state motion, confirmation pop. The app.css
   prefers-reduced-motion rule (loaded first) cuts all of it to ~0. */
.bk-day { transition: background var(--dur-1), color var(--dur-1), transform var(--dur-1) var(--ease-out); }
.bk-day.open:hover { transform: scale(1.08); }
.bk-day[aria-pressed="true"] { box-shadow: 0 6px 14px rgba(220,38,38,.3); }
.bk-time { transition: background var(--dur-1), color var(--dur-1), transform var(--dur-1) var(--ease-out), box-shadow var(--dur-2) var(--ease-out); animation: mcal-fade-up var(--dur-2) var(--ease-out) both; }
.bk-time:hover { transform: translateY(-1px); box-shadow: 0 6px 14px rgba(220,38,38,.18); }
.bk-time:active { transform: scale(.97); }
.bk-time:nth-child(2) { animation-delay: 30ms; } .bk-time:nth-child(3) { animation-delay: 60ms; } .bk-time:nth-child(4) { animation-delay: 90ms; }
.bk-time:nth-child(5) { animation-delay: 120ms; } .bk-time:nth-child(n+6) { animation-delay: 150ms; }
.bk-card { transition: box-shadow var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out); }
.bk-card:hover { transform: translateY(-2px); }
.bk-done { animation: mcal-fade-up 320ms var(--ease-out) both; }
.bk-check { animation: bk-pop 420ms cubic-bezier(.2,.9,.3,1.3) both; box-shadow: 0 0 0 0 rgba(21,128,61,.45); }
.bk-check:not(.off) { animation: bk-pop 420ms cubic-bezier(.2,.9,.3,1.3) both, bk-ring 1.6s 420ms ease-out 2; }
@keyframes bk-pop { from { transform: scale(.4); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes bk-ring { from { box-shadow: 0 0 0 0 rgba(21,128,61,.45); } to { box-shadow: 0 0 0 16px rgba(21,128,61,0); } }
