/* "Ask our AI" (sales-chat.js): BookDirectSetup's own plum and gold, light and dark, on any of our pages */
.sc{--sc-surface:#FFFFFF;--sc-ink:#22182A;--sc-muted:#6D6172;--sc-line:#E4DADF;--sc-soft:#F5F1F2;--sc-btn:#5E2A5C;--sc-btn-ink:#FFFFFF;--sc-me:#5E2A5C;--sc-me-ink:#FFFFFF;--sc-link:#5E2A5C;
  position:fixed;right:16px;bottom:16px;z-index:40;display:flex;flex-direction:column;align-items:flex-end;gap:10px;max-width:calc(100vw - 32px);font-family:"Hanken Grotesk",system-ui,sans-serif}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]) .sc{--sc-surface:#1E1624;--sc-ink:#F2E9EE;--sc-muted:#B3A3B2;--sc-line:#33283B;--sc-soft:#2A2031;--sc-btn:#F0B65C;--sc-btn-ink:#22182A;--sc-me:#F0B65C;--sc-me-ink:#22182A;--sc-link:#F0B65C}}
:root[data-theme="dark"] .sc{--sc-surface:#1E1624;--sc-ink:#F2E9EE;--sc-muted:#B3A3B2;--sc-line:#33283B;--sc-soft:#2A2031;--sc-btn:#F0B65C;--sc-btn-ink:#22182A;--sc-me:#F0B65C;--sc-me-ink:#22182A;--sc-link:#F0B65C}
@media (min-width:860px){.sc{right:24px;bottom:24px}}
.sc-open{display:inline-flex;align-items:center;gap:8px;font:inherit;font-size:15px;font-weight:700;color:var(--sc-btn-ink);background:var(--sc-btn);border:0;border-radius:999px;padding:11px 16px;min-height:46px;box-shadow:0 10px 30px -10px rgba(0,0,0,.45);cursor:pointer}
.sc-open svg{width:20px;height:20px;flex:none}
/* Kip (Nov 14, 2026): a floating brass key in place of the pill. Small on phones (no tag) so he stays out of the way;
   the button keeps a 48px tap target. Idle bob and blink only; none under reduced motion. */
.sc-open.kip{flex-direction:column;gap:3px;padding:0;min-height:48px;min-width:48px;background:none;box-shadow:none;border-radius:20px;color:var(--sc-ink)}
.sc-open.kip .kip-art{width:50px;height:64px;filter:drop-shadow(0 6px 8px rgba(60,30,10,.3));animation:kip-bob 3.4s ease-in-out infinite}
.sc-open.kip .kip-tag{display:none;font-size:12px;font-weight:700;padding:3px 10px;border-radius:999px;background:var(--sc-surface);color:var(--sc-ink);border:1px solid var(--sc-line);box-shadow:0 4px 12px -6px rgba(0,0,0,.35)}
.sc-open.kip:focus-visible{outline:3px solid var(--sc-btn);outline-offset:3px}
@media (min-width:860px){.sc-open.kip .kip-art{width:72px;height:92px}.sc-open.kip .kip-tag{display:block}}
.kip-head{display:flex;align-items:center;gap:10px;min-width:0}
.kip-head .kip-art{width:36px;height:46px;flex:none}
.kip-eyes{transform-box:fill-box;transform-origin:center;animation:kip-blink 5.5s infinite}
@keyframes kip-bob{0%,100%{transform:translateY(0)}50%{transform:translateY(-4px)}}
@keyframes kip-blink{0%,93%,100%{transform:scaleY(1)}96%{transform:scaleY(.12)}}
/* Phones: Kip sits a little higher while the chat is closed, clear of the bottom of the screen (the open chat stays put) */
@media (max-width:859px){.sc:not(.on){bottom:84px}}
/* Phones: Kip shrinks into his corner while something tappable is under him (sales-chat.js), never past the 16px margin */
.sc-open.kip{transition:transform .25s ease,opacity .25s ease}
.sc-open.kip.peek{transform:scale(.6);transform-origin:100% 100%;opacity:.85}
/* The jingle when the chat opens: a quick wiggle from the bow */
.kip-head .kip-art.jingle{transform-origin:50% 30%;animation:kip-jingle .6s ease-in-out}
@keyframes kip-jingle{0%,100%{transform:rotate(0)}20%{transform:rotate(-14deg)}40%{transform:rotate(11deg)}60%{transform:rotate(-7deg)}80%{transform:rotate(4deg)}}
/* Thinking: a gentle tilt while an answer loads. Answer: a soft glow around the key. */
.kip-head .kip-art.thinking{transform-origin:50% 30%;transform:rotate(-10deg);animation:kip-think 1.4s ease-in-out infinite alternate}
@keyframes kip-think{from{transform:rotate(-12deg)}to{transform:rotate(-4deg)}}
.kip-head .kip-art.glow{animation:kip-glow 1.6s ease-out}
@keyframes kip-glow{0%{filter:drop-shadow(0 0 0 rgba(255,210,120,0))}35%{filter:drop-shadow(0 0 9px rgba(255,210,120,.95))}100%{filter:drop-shadow(0 0 0 rgba(255,210,120,0))}}
/* Reduced motion: no bob, blink, jingle, glow or sliding; while thinking Kip just holds a still tilt so it still shows */
@media (prefers-reduced-motion:reduce){.sc-open.kip .kip-art,.kip-eyes,.kip-head .kip-art.jingle,.kip-head .kip-art.thinking,.kip-head .kip-art.glow{animation:none}.sc-open.kip{transition:none}}
.sc.on .sc-open{display:none}
.sc-panel{width:min(380px,calc(100vw - 32px));max-height:min(580px,calc(100vh - 32px));display:flex;flex-direction:column;background:var(--sc-surface);color:var(--sc-ink);border:1px solid var(--sc-line);border-radius:20px;box-shadow:0 24px 60px -20px rgba(0,0,0,.45);overflow:hidden}
.sc-panel[hidden]{display:none}
.sc-head{display:flex;align-items:flex-start;justify-content:space-between;gap:10px;padding:14px 16px;border-bottom:1px solid var(--sc-line)}
.sc-head h2{margin:0;font:700 17px/1.3 "Hanken Grotesk",system-ui,sans-serif;color:var(--sc-ink)}
.sc-sub{margin:2px 0 0;font-size:13px;line-height:1.4;color:var(--sc-muted)}
.sc-x{font:inherit;font-size:24px;line-height:1;width:40px;height:40px;flex:none;border:0;border-radius:50%;background:transparent;color:var(--sc-ink);cursor:pointer}
.sc-log{flex:1;overflow:auto;padding:14px 16px;display:grid;gap:10px;align-content:start}
.sc-msg{margin:0;padding:10px 13px;border-radius:16px;font-size:15px;line-height:1.5;max-width:88%;white-space:pre-wrap;overflow-wrap:anywhere}
.sc-msg.bot{background:var(--sc-soft);color:var(--sc-ink);justify-self:start;border-bottom-left-radius:6px}
.sc-msg.me{background:var(--sc-me);color:var(--sc-me-ink);justify-self:end;border-bottom-right-radius:6px}
.sc-msg.wait{opacity:.7}
.sc-cta{display:inline-block;font-weight:700;color:var(--sc-link);text-underline-offset:3px}
.sc-form{display:flex;gap:8px;padding:12px 16px 8px;border-top:1px solid var(--sc-line)}
.sc-form input,.sc-hand input{flex:1;min-width:0;width:100%;box-sizing:border-box;font:inherit;font-size:16px;color:var(--sc-ink);background:var(--sc-soft);border:1px solid var(--sc-line);border-radius:999px;padding:10px 14px}
.sc-ask{font:inherit;font-weight:700;color:var(--sc-btn-ink);background:var(--sc-btn);border:0;border-radius:999px;min-height:44px;padding:10px 16px;cursor:pointer}
.sc-ask:disabled{opacity:.6}
.sc-hand{display:grid;gap:6px;padding:12px;border:1px solid var(--sc-line);border-radius:16px}
.sc-hand label{font-size:13px;font-weight:600;color:var(--sc-muted)}
.sc-note{margin:0;font-size:14px;line-height:1.45;color:var(--sc-ink)}
.sc-fine{margin:0;padding:0 16px 12px;font-size:12px;color:var(--sc-muted)}
.sc-link{font:inherit;font-size:12px;font-weight:700;color:var(--sc-link);background:none;border:0;padding:0;text-decoration:underline;text-underline-offset:2px;cursor:pointer}
.sc-sr,.sc-trap{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0;padding:0;margin:-1px}
.sc :focus-visible{outline:2px solid var(--sc-link);outline-offset:2px}
/* Kip's personality (Nov 16, 2026, the owner's; sales-chat.js): the keyhole opening once per visit, a wave after
   "Talk to a person", dozing on a doormat late at night (Arizona time) and a keychain with a palm charm on weekends */
.sc-open.kip{position:relative}
.kip-mat,.kip-z,.kip-ring{display:none;pointer-events:none}
.sc-open.kip.doze .kip-mat{display:block;width:62px;height:14px;margin-top:-10px}
.sc-open.kip.doze .kip-art{animation:none;transform:rotate(-8deg) translateY(4px)}
.sc-open.kip.doze .kip-eyes{animation:none;transform:scaleY(.12)}
.sc-open.kip.doze .kip-z{display:block;position:absolute;top:-6px;right:0;width:16px;height:16px;color:var(--sc-muted);animation:kip-z 3s ease-in-out infinite}
@keyframes kip-z{0%{opacity:0;transform:translateY(4px)}30%{opacity:1}100%{opacity:0;transform:translateY(-10px)}}
.sc-open.kip.weekend{padding:0 4px}
.sc-open.kip.weekend .kip-ring{display:block;width:30px;height:38px;margin-bottom:-14px;margin-left:18px}
.sc-open.kip.weekend .kip-art{transform-origin:50% 0;animation:kip-swing 3.6s ease-in-out infinite}
@keyframes kip-swing{0%,100%{transform:rotate(-3deg)}50%{transform:rotate(3deg)}}
@media (min-width:860px){.sc-open.kip.doze .kip-mat{width:88px;height:20px;margin-top:-14px}.sc-open.kip.weekend .kip-ring{width:40px;height:50px;margin-bottom:-18px;margin-left:26px}}
/* The keyhole: a brass plate where Kip sits; he slides in and turns, a ring shows the click, then the door opens */
.kip-plate{position:absolute;z-index:-1;width:46px;height:62px;border-radius:14px;background:linear-gradient(160deg,#F7D58C,#C98A2B);box-shadow:inset 0 0 0 2px #8A5A1C,0 8px 18px -8px rgba(0,0,0,.4);display:grid;place-items:center;animation:kip-plate .56s ease-out}
.kip-hole{width:12px;height:26px;background:#2A1C12;border-radius:6px 6px 2px 2px;clip-path:polygon(0 0,100% 0,100% 45%,75% 100%,25% 100%,0 45%)}
.kip-click{position:absolute;inset:14px;border-radius:50%;border:2px solid rgba(255,230,170,.95);opacity:0;animation:kip-click .56s ease-out}
@keyframes kip-plate{0%{opacity:0;transform:scale(.7)}25%{opacity:1;transform:scale(1)}100%{opacity:1}}
@keyframes kip-click{0%,62%{opacity:0;transform:scale(.4)}75%{opacity:1}100%{opacity:0;transform:scale(1.4)}}
.sc-open.kip.turning .kip-art{animation:kip-turn .56s ease-in forwards}
.sc-open.kip.turning .kip-tag,.sc-open.kip.turning .kip-mat,.sc-open.kip.turning .kip-z,.sc-open.kip.turning .kip-ring{visibility:hidden}
@keyframes kip-turn{0%{transform:scale(1) rotate(0)}40%{transform:scale(.42) rotate(0)}75%{transform:scale(.42) rotate(90deg);opacity:1}100%{transform:scale(.3) rotate(90deg);opacity:0}}
.sc-panel.door{transform-origin:100% 50%;animation:kip-door .42s ease-out}
@keyframes kip-door{from{transform:perspective(900px) rotateY(-75deg);opacity:.2}to{transform:perspective(900px) rotateY(0);opacity:1}}
.kip-head .kip-art.wave{transform-origin:50% 90%;animation:kip-wave .9s ease-in-out}
@keyframes kip-wave{0%,100%{transform:rotate(0)}20%,60%{transform:rotate(14deg)}40%,80%{transform:rotate(-8deg)}}
@media (prefers-reduced-motion:reduce){.sc-open.kip.weekend .kip-art,.sc-open.kip.doze .kip-z,.kip-head .kip-art.wave,.sc-panel.door,.sc-open.kip.turning .kip-art{animation:none}}
@media print{.sc{display:none}}
