/* Booking Brain — Chat Widget Styles */

:root {
  --accent: #00e599;
  --accent-glow: rgba(0, 229, 153, 0.15);
  --accent-dim: #00b377;
  --bg: #0a0a0c;
  --bg-elevated: #111114;
  --bg-card: #16161a;
  --fg: #e8e6e3;
  --fg-muted: #8a8a8e;
  --fg-dim: #5a5a5e;
  --border: #2a2a2e;
  --radius: 12px;
  --font-heading: 'Space Grotesk', sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;
}

/* ── Floating Widget Toggle Button ── */
.dp-widget-toggle {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 24px rgba(0, 229, 153, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
  transition: transform 0.2s, box-shadow 0.2s;
}

.dp-widget-toggle:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 32px rgba(0, 229, 153, 0.5);
}

.dp-widget-toggle svg {
  width: 28px;
  height: 28px;
  fill: #0a0a0c;
}

/* ── Widget Window ── */
.dp-widget {
  position: fixed;
  bottom: 100px;
  right: 28px;
  width: 380px;
  height: 560px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 9999;
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.dp-widget.open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: all;
}

/* ── Header ── */
.dp-header {
  padding: 20px 20px 16px;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dp-header-info {
  display: flex;
  flex-direction: column;
}

.dp-header-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: -0.01em;
}

.dp-header-subtitle {
  font-size: 0.75rem;
  color: var(--fg-dim);
  margin-top: 2px;
  font-family: var(--font-mono);
}

.dp-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--fg-muted);
  font-size: 1.1rem;
  transition: background 0.2s;
}

.dp-close:hover { background: var(--border); }

/* ── Messages ── */
.dp-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dp-messages::-webkit-scrollbar { width: 4px; }
.dp-messages::-webkit-scrollbar-track { background: transparent; }
.dp-messages::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

.dp-msg {
  display: flex;
  flex-direction: column;
  max-width: 85%;
  animation: msgIn 0.2s ease;
}

@keyframes msgIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.dp-msg.user { align-self: flex-end; }
.dp-msg.assistant { align-self: flex-start; }

.dp-bubble {
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 0.88rem;
  line-height: 1.5;
  word-break: break-word;
}

.dp-msg.user .dp-bubble {
  background: var(--accent);
  color: #0a0a0c;
  border-bottom-right-radius: 4px;
}

.dp-msg.assistant .dp-bubble {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--fg);
  border-bottom-left-radius: 4px;
}

.dp-time {
  font-size: 0.65rem;
  color: var(--fg-dim);
  font-family: var(--font-mono);
  margin-top: 4px;
}

/* ── Quick Services ── */
.dp-quick-actions {
  padding: 0 20px 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.dp-quick-btn {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 0.75rem;
  color: var(--fg-muted);
  cursor: pointer;
  transition: all 0.2s;
  font-family: var(--font-heading);
}

.dp-quick-btn:hover {
  border-color: var(--accent-dim);
  color: var(--accent);
}

/* ── Input ── */
.dp-input-area {
  padding: 16px 20px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg-card);
  display: flex;
  gap: 10px;
  align-items: flex-end;
}

.dp-input {
  flex: 1;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 0.88rem;
  color: var(--fg);
  font-family: var(--font-heading);
  resize: none;
  min-height: 44px;
  max-height: 100px;
  line-height: 1.5;
}

.dp-input:focus {
  outline: none;
  border-color: var(--accent-dim);
}

.dp-input::placeholder { color: var(--fg-dim); }

.dp-send {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--accent);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: opacity 0.2s;
}

.dp-send:disabled { opacity: 0.4; cursor: not-allowed; }
.dp-send svg { width: 18px; height: 18px; fill: #0a0a0c; }

.dp-typing {
  padding: 0 20px 8px;
  font-size: 0.75rem;
  color: var(--fg-dim);
  font-family: var(--font-mono);
  height: 20px;
}

/* ── Booking Confirmed Card ── */
.dp-booking-card {
  background: var(--bg-elevated);
  border: 1px solid var(--accent-dim);
  border-radius: 10px;
  padding: 14px;
  margin-top: 4px;
}

.dp-booking-card .card-title {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.dp-booking-card .card-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  padding: 3px 0;
}

.dp-booking-card .card-row .label { color: var(--fg-dim); }
.dp-booking-card .card-row .value { color: var(--fg); font-weight: 600; }

@media (max-width: 480px) {
  .dp-widget {
    width: calc(100vw - 32px);
    right: 16px;
    bottom: 90px;
  }
  .dp-widget-toggle { right: 20px; bottom: 20px; }
}