/* Blake website assistant. Matches the Own Your Time palette in styles.css */
.blake-launcher {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 60;
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.8rem 1.15rem 0.8rem 0.85rem; border: 0; border-radius: 999px;
  background: var(--forest, #1f4d3a); color: #fff; font-weight: 700; cursor: pointer;
  box-shadow: 0 14px 34px rgba(31, 77, 58, 0.32);
}
.blake-launcher:hover { background: var(--forest-deep, #16382a); }
.blake-launcher:focus-visible, .blake-panel :focus-visible { outline: 3px solid var(--gold, #c66a2a); outline-offset: 2px; }
.blake-avatar {
  width: 34px; height: 34px; border-radius: 50%; flex: 0 0 34px;
  display: grid; place-items: center; font-family: var(--display, Georgia, serif); font-size: 1.05rem;
  background: var(--mint, #dceee4); color: var(--forest, #1f4d3a); font-weight: 700;
}
.blake-launcher[aria-expanded="true"] { display: none; }

.blake-panel {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 61;
  width: min(390px, calc(100vw - 2rem)); height: min(620px, calc(100vh - 2.5rem));
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--paper, #fffdf8); color: var(--ink, #14201c);
  border: 1px solid var(--line, #e4ddd0); border-radius: var(--radius, 22px);
  box-shadow: 0 24px 60px rgba(20, 32, 28, 0.22);
  font-family: var(--font, system-ui, sans-serif); line-height: 1.5;
}
.blake-panel[hidden] { display: none; }
.blake-head {
  display: flex; align-items: center; gap: 0.7rem; padding: 0.9rem 1rem;
  background: var(--forest, #1f4d3a); color: #fff;
}
.blake-head .blake-avatar { background: #fff; }
.blake-title { flex: 1; min-width: 0; }
.blake-title strong { display: block; font-size: 1rem; }
.blake-title span { display: block; font-size: 0.8rem; opacity: 0.85; }
.blake-icon-btn {
  border: 0; background: rgba(255, 255, 255, 0.14); color: #fff; width: 36px; height: 36px;
  border-radius: 50%; cursor: pointer; font-size: 1.2rem; line-height: 1;
}
.blake-icon-btn:hover { background: rgba(255, 255, 255, 0.26); }

.blake-body { flex: 1; overflow-y: auto; padding: 1rem; display: flex; flex-direction: column; gap: 0.65rem; }
.blake-msg { max-width: 86%; padding: 0.65rem 0.85rem; border-radius: 16px; font-size: 0.95rem; white-space: pre-wrap; word-wrap: break-word; }
.blake-msg.bot { align-self: flex-start; background: var(--mint, #dceee4); color: var(--ink, #14201c); border-bottom-left-radius: 6px; }
.blake-msg.me { align-self: flex-end; background: var(--forest, #1f4d3a); color: #fff; border-bottom-right-radius: 6px; }
.blake-msg.note { align-self: stretch; max-width: none; background: #fbf1e6; color: var(--gold-deep, #9a5220); font-size: 0.85rem; border-radius: 12px; }
.blake-typing { align-self: flex-start; color: var(--muted, #6b7a73); font-size: 0.85rem; }

.blake-banner { padding: 0.55rem 1rem; font-size: 0.8rem; background: #fbf1e6; color: var(--gold-deep, #9a5220); border-bottom: 1px solid var(--line, #e4ddd0); }
.blake-banner[hidden] { display: none; }

.blake-foot { border-top: 1px solid var(--line, #e4ddd0); padding: 0.75rem; background: #fff; }
.blake-input-row { display: flex; gap: 0.5rem; align-items: flex-end; }
.blake-input-row textarea {
  flex: 1; resize: none; min-height: 44px; max-height: 120px; padding: 0.65rem 0.8rem;
  border: 1px solid var(--line, #e4ddd0); border-radius: 14px; background: var(--paper, #fffdf8); color: inherit; font-size: 0.95rem;
}
.blake-send, .blake-btn {
  border: 0; border-radius: 999px; padding: 0.7rem 1.05rem; font-weight: 700; cursor: pointer;
  background: var(--forest, #1f4d3a); color: #fff;
}
.blake-send:disabled, .blake-btn:disabled { opacity: 0.55; cursor: not-allowed; }
.blake-btn.secondary { background: transparent; color: var(--forest, #1f4d3a); border: 1px solid var(--forest, #1f4d3a); }
.blake-btn.gold { background: var(--gold, #c66a2a); }
.blake-meta { display: flex; justify-content: space-between; gap: 0.5rem; margin-top: 0.45rem; font-size: 0.75rem; color: var(--muted, #6b7a73); }
.blake-demo-cta { width: 100%; margin-top: 0.55rem; }

.blake-form { display: grid; gap: 0.6rem; }
.blake-form h3 { margin: 0; font-family: var(--display, Georgia, serif); font-size: 1.25rem; }
.blake-form p { margin: 0; font-size: 0.88rem; color: var(--ink-soft, #3a4a44); }
.blake-form label { display: grid; gap: 0.2rem; font-size: 0.85rem; font-weight: 600; color: var(--ink-soft, #3a4a44); }
.blake-form input[type="text"], .blake-form input[type="email"], .blake-form input[type="tel"] {
  padding: 0.6rem 0.75rem; border: 1px solid var(--line, #e4ddd0); border-radius: 12px; background: #fff; font-size: 0.95rem; font-weight: 400; color: inherit;
}
.blake-form input[aria-invalid="true"] { border-color: #b3261e; }
.blake-form .blake-check { display: flex; gap: 0.5rem; align-items: flex-start; font-weight: 400; }
.blake-form .blake-check input { margin-top: 0.25rem; }
.blake-form a { color: var(--forest, #1f4d3a); text-decoration: underline; }
.blake-form .blake-code { letter-spacing: 0.4em; font-size: 1.3rem; text-align: center; }
.blake-error { color: #b3261e; font-size: 0.85rem; min-height: 1.2em; }
.blake-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.blake-ts { min-height: 65px; }
.blake-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

@media (max-width: 560px) {
  .blake-launcher { right: 0.85rem; bottom: 0.85rem; }
  .blake-launcher .blake-label-long { display: none; }
  .blake-panel { inset: 0; right: 0; bottom: 0; width: 100vw; height: 100dvh; border-radius: 0; border: 0; }
}
@media (prefers-reduced-motion: no-preference) {
  .blake-panel:not([hidden]) { animation: blake-in 0.18s ease-out; }
  @keyframes blake-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
}
button.btn { cursor: pointer; } button.btn-primary { border: 0; }
.blake-panel .blake-check input[type="checkbox"] { width: 18px; height: 18px; min-width: 18px; flex: 0 0 18px; padding: 0; margin: 0.2rem 0 0; box-shadow: none; accent-color: var(--forest, #1f4d3a); }
.blake-foot .blake-ts { min-height: 0; }
.blake-foot .blake-ts:not(:empty) { margin-bottom: 0.5rem; }

/* Blake calls to action on the site pages */
.nav-links a.nav-blake {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.6rem 0.95rem; border-radius: 999px;
  border: 1.5px solid var(--gold, #c66a2a); color: var(--gold-deep, #9a5220); font-weight: 700;
}
.nav-links a.nav-blake::before { content: ""; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: #2fae6b; box-shadow: 0 0 0 3px rgba(47, 174, 107, 0.18); }
.nav-links a.nav-blake:hover { background: #fbf1e6; color: var(--gold-deep, #9a5220); }
.btn-blake { background: var(--gold, #c66a2a); color: #fff; box-shadow: 0 10px 24px rgba(198, 106, 42, 0.22); }
.btn-blake:hover { background: var(--gold-deep, #9a5220); color: #fff; }
.btn-blake-dot { width: 0.55rem; height: 0.55rem; border-radius: 50%; background: #9df0c0; box-shadow: 0 0 0 3px rgba(157, 240, 192, 0.3); }
.blake-meet { padding-top: 0; }
.blake-meet-panel { display: flex; gap: 1.4rem; align-items: flex-start; border: 1.5px solid rgba(198, 106, 42, 0.35); background: linear-gradient(135deg, #fffdf8 0%, #fbf1e6 100%); }
.blake-meet-avatar { flex: 0 0 auto; width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--forest, #1f4d3a); color: #fff; font-family: var(--display, Georgia, serif); font-size: 1.9rem; font-weight: 700; box-shadow: 0 10px 24px rgba(31, 77, 58, 0.2); }
.blake-meet-copy h2 { margin-top: 0.7rem; font-size: clamp(1.7rem, 3vw, 2.4rem); }
.blake-meet-copy p { font-size: 1.08rem; }
.blake-meet-copy .blake-meet-note { margin-top: 0.5rem; font-size: 0.98rem; color: var(--muted, #6b7a73); }
.blake-meet-copy .cta-row { margin-top: 1.1rem; }
@media (max-width: 640px) {
  .blake-meet-panel { flex-direction: column; gap: 0.9rem; }
  .blake-meet-avatar { width: 52px; height: 52px; font-size: 1.5rem; }
  .blake-meet-copy .cta-row .btn, .hero-actions .btn-blake { width: 100%; }
}
