/* ================================================================
   ENTRENADORA PERSONAL — Booking Widget CSS
   Paleta: Negro + Coral + Crema
   ================================================================ */
:root {
  --ink:        #1D1D1F;
  --ink-soft:   #1D1D1F;
  --coral:      #0071E3;
  --coral-dark: #0058B0;
  --coral-soft: #F5F5F7;
  --cream:      #FFFFFF;
  --soft:       #F5F5F7;
  --line:       rgba(0,0,0,.1);
  --muted:      #86868B;
}

/* Overlay */
.bk-overlay {
  position: fixed; inset: 0; z-index: 3000;
  background: rgba(14,14,20,.85); backdrop-filter: blur(16px);
  display: flex; align-items: flex-end; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity .3s;
}
@media (min-width: 600px) { .bk-overlay { align-items: center; padding: 20px; } }
.bk-overlay.open { opacity: 1; pointer-events: all; }

.bk-panel {
  background: #fff; width: 100%; max-width: 480px;
  height: 92dvh; max-height: 780px;
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: 20px 20px 0 0;
  transform: translateY(40px);
  transition: transform .4s cubic-bezier(.22,1,.36,1);
  box-shadow: 0 30px 80px rgba(0,0,0,.4);
}
@media (min-width: 600px) { .bk-panel { border-radius: 20px; } }
.bk-overlay.open .bk-panel { transform: none; }

/* Header */
.bk-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px;
  background: #fff; border-bottom: 1px solid var(--line);
  color: var(--ink); flex-shrink: 0;
}
.bk-brand { display: flex; align-items: center; gap: 12px; }
.bk-brand-logo {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--ink); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: 15px;
}
.bk-brand-name { font-weight: 600; font-size: 14px; }
.bk-brand-sub { font-size: 11px; opacity: .6; margin-top: 2px; }
.bk-close {
  width: 32px; height: 32px; background: var(--soft); color: var(--ink);
  font-size: 20px; border: none; border-radius: 50%; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}

/* Progress */
.bk-progress-track { height: 3px; background: var(--soft); flex-shrink: 0; }
.bk-progress-fill {
  height: 100%; width: 0;
  background: linear-gradient(90deg, var(--coral), var(--coral-dark));
  transition: width .5s cubic-bezier(.22,1,.36,1);
}

/* Chat */
.bk-chat {
  flex: 1; overflow-y: auto;
  padding: 22px 18px 28px;
  display: flex; flex-direction: column; gap: 10px;
  scroll-behavior: smooth;
  background: var(--cream);
}
.bk-chat::-webkit-scrollbar { width: 4px; }
.bk-chat::-webkit-scrollbar-thumb { background: var(--coral); border-radius: 99px; }

.bk-msg {
  max-width: 84%; padding: 13px 17px;
  border-radius: 14px; font-size: 14px; line-height: 1.55;
  animation: msgIn .3s cubic-bezier(.22,1,.36,1) both;
  word-wrap: break-word;
}
@keyframes msgIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.bk-msg--bot { align-self: flex-start; background: #fff; color: var(--ink); border-radius: 4px 14px 14px 14px; box-shadow: 0 2px 8px rgba(14,14,20,.06); }
.bk-msg--user { align-self: flex-end; background: var(--coral); color: #fff; border-radius: 14px 4px 14px 14px; font-weight: 600; }

.bk-typing {
  align-self: flex-start; background: #fff;
  border-radius: 4px 14px 14px 14px;
  padding: 14px 18px; display: flex; gap: 5px;
  box-shadow: 0 2px 8px rgba(14,14,20,.06);
}
.bk-typing span {
  width: 7px; height: 7px; border-radius: 50%; background: var(--coral);
  animation: typingDot 1.4s ease-in-out infinite;
}
.bk-typing span:nth-child(2) { animation-delay: .2s; }
.bk-typing span:nth-child(3) { animation-delay: .4s; }
@keyframes typingDot { 0%,60%,100% { opacity: .3; transform: scale(.85); } 30% { opacity: 1; transform: scale(1); } }

/* Actions */
.bk-actions {
  padding: 16px 18px 20px; background: #fff;
  border-top: 1px solid var(--line); flex-shrink: 0;
}
.bk-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.bk-chip {
  background: var(--soft); border: 1px solid var(--line); color: var(--ink);
  font-family: inherit; font-size: 13px; font-weight: 600;
  padding: 11px 16px; border-radius: 99px; cursor: pointer;
  transition: background .2s, border-color .2s, transform .15s;
  flex: 1 1 auto; min-width: 120px; text-align: center;
}
.bk-chip:hover { background: var(--coral-soft); border-color: var(--coral); }
.bk-chip:disabled { opacity: .5; cursor: not-allowed; }
.bk-chip--send {
  background: var(--coral); color: #fff; border-color: var(--coral);
  flex: 0 0 auto;
}
.bk-chip--send:hover { background: var(--coral-dark); }

.bk-input-row { display: flex; gap: 8px; }
.bk-input {
  flex: 1; background: var(--soft); border: 1px solid var(--line);
  color: var(--ink); font-size: 14px; padding: 13px 16px;
  outline: none; border-radius: 99px; font-family: inherit;
  transition: border-color .2s;
}
.bk-input:focus { border-color: var(--coral); background: #fff; }
.bk-shake { animation: shake .35s; }
@keyframes shake { 0%,100% { transform: translateX(0); } 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

/* Date picker */
.bk-date-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(72px,1fr));
  gap: 8px; max-height: 200px; overflow-y: auto;
}
.bk-date-chip {
  background: var(--soft); border: 1px solid var(--line);
  padding: 10px 6px; border-radius: 10px; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-family: inherit; transition: background .2s, border-color .2s;
}
.bk-date-chip:hover, .bk-date-chip.sel { background: var(--coral); border-color: var(--coral); color: #fff; }
.bk-date-chip b { font-size: 10px; letter-spacing: 1px; text-transform: uppercase; opacity: .7; }
.bk-date-chip span { font-size: 22px; font-weight: 700; line-height: 1; }
.bk-date-chip small { font-size: 9px; letter-spacing: 1px; text-transform: uppercase; opacity: .6; }

/* Summary */
.bk-summary {
  background: var(--soft); border-radius: 12px; padding: 14px 16px;
  display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px;
}
.bk-sum-row { display: flex; justify-content: space-between; align-items: baseline; font-size: 13px; }
.bk-sum-row span { color: var(--muted); }
.bk-sum-row strong { color: var(--ink); text-align: right; }
.bk-sum-total {
  display: flex; justify-content: space-between; align-items: baseline;
  padding-top: 10px; margin-top: 4px;
  border-top: 1px dashed var(--line);
  font-size: 15px;
}
.bk-sum-total strong { color: var(--coral); font-size: 20px; font-weight: 800; }

.bk-chips--final { flex-direction: column; gap: 8px; }
.bk-chips--final .bk-chip { width: 100%; }
