/* Demo page — extends theme.css design tokens */

.demo-page {
  min-height: 100vh;
  background: var(--bg);
}

/* ===== DEMO HEADER ===== */
.demo-header {
  background: var(--dark);
  padding: 32px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.demo-header-brand { display: flex; align-items: center; gap: 12px; }
.demo-header-logo {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 20px;
  color: #fff;
}
.demo-header-badge {
  background: rgba(255,140,0,0.15);
  border: 1px solid rgba(255,140,0,0.4);
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
  letter-spacing: 0.05em;
}
.demo-header-info {
  font-size: 14px;
  color: rgba(255,255,255,0.5);
}
.demo-header-info span {
  color: var(--accent);
  font-weight: 600;
}

/* ===== MAIN LAYOUT ===== */
.demo-layout {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 0;
  max-width: 1100px;
  margin: 0 auto;
  min-height: calc(100vh - 90px);
}

/* Left panel: business info */
.demo-info {
  padding: 60px 48px 60px 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.demo-info-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}
.demo-info h1 {
  font-family: 'Syne', sans-serif;
  font-size: clamp(32px, 4vw, 52px);
  font-weight: 800;
  color: var(--dark);
  line-height: 1.1;
  margin-bottom: 20px;
}
.demo-info-lead {
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 48px;
  max-width: 440px;
}
.demo-features { display: flex; flex-direction: column; gap: 20px; }
.demo-feature {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.demo-feature-icon {
  width: 36px;
  height: 36px;
  background: var(--accent);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.demo-feature-icon svg { width: 18px; height: 18px; stroke: #fff; fill: none; }
.demo-feature-text h4 {
  font-family: 'Syne', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 4px;
}
.demo-feature-text p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Right panel: chat widget */
.demo-chat-panel {
  border-left: 1px solid rgba(26, 26, 46, 0.1);
  background: var(--white);
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
}

/* Chat header */
.chat-header {
  padding: 24px 24px 20px;
  border-bottom: 1px solid rgba(26, 26, 46, 0.08);
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--white);
}
.chat-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent) 0%, #FF4500 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.chat-avatar svg { width: 22px; height: 22px; stroke: #fff; fill: none; }
.chat-header-info h3 {
  font-family: 'Syne', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
}
.chat-header-info p {
  font-size: 12px;
  color: #22C55E;
  font-weight: 500;
}

/* Message area */
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  scroll-behavior: smooth;
}

.chat-msg {
  display: flex;
  gap: 10px;
  animation: msgIn 0.25s ease-out;
}
@keyframes msgIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.chat-msg--in .chat-msg-avatar { display: none; }
.chat-msg-bubble {
  max-width: 85%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.55;
}
.chat-msg--in .chat-msg-bubble {
  background: var(--bg-alt);
  color: var(--text);
  border-bottom-left-radius: 4px;
}
.chat-msg--out {
  flex-direction: row-reverse;
}
.chat-msg--out .chat-msg-bubble {
  background: var(--accent);
  color: #fff;
  border-bottom-right-radius: 4px;
}
.chat-msg-time {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
  padding: 0 4px;
}
.chat-msg--out .chat-msg-time { text-align: right; }

/* Quick reply buttons */
.chat-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 4px;
}
.chat-option-btn {
  background: var(--white);
  border: 1.5px solid var(--accent);
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.15s;
}
.chat-option-btn:hover {
  background: var(--accent);
  color: #fff;
}

/* Booking confirmed card */
.confirmation-card {
  background: #F0FDF4;
  border: 1.5px solid #BBF7D0;
  border-radius: 16px;
  padding: 20px;
  margin-top: 8px;
}
.confirmation-card-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}
.confirmation-check {
  width: 24px;
  height: 24px;
  background: #22C55E;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.confirmation-check svg { width: 14px; height: 14px; stroke: #fff; stroke-width: 2.5; fill: none; }
.confirmation-card-top span {
  font-size: 13px;
  font-weight: 700;
  color: #15803D;
}
.confirmation-detail {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  font-size: 13px;
  color: var(--text);
  border-bottom: 1px solid #D1FAE5;
}
.confirmation-detail:last-child { border-bottom: none; }
.confirmation-detail span:first-child { color: var(--text-muted); font-size: 12px; }
.confirmation-detail span:last-child { font-weight: 600; text-align: right; }

/* Typing indicator */
.typing-indicator {
  display: flex;
  gap: 4px;
  padding: 12px 16px;
  background: var(--bg-alt);
  border-radius: 16px;
  border-bottom-left-radius: 4px;
  width: fit-content;
}
.typing-indicator span {
  width: 7px;
  height: 7px;
  background: var(--text-muted);
  border-radius: 50%;
  animation: typingBounce 1.2s ease-in-out infinite;
}
.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
  30% { transform: translateY(-6px); opacity: 1; }
}

/* Input area */
.chat-input-area {
  padding: 16px 20px 24px;
  border-top: 1px solid rgba(26, 26, 46, 0.08);
  background: var(--white);
}
.chat-input-row {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}
.chat-input {
  flex: 1;
  padding: 12px 16px;
  border: 1.5px solid rgba(26, 26, 46, 0.15);
  border-radius: 12px;
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  color: var(--text);
  background: var(--bg);
  outline: none;
  transition: border-color 0.15s;
  resize: none;
  min-height: 48px;
  max-height: 120px;
  line-height: 1.5;
}
.chat-input:focus { border-color: var(--accent); }
.chat-input::placeholder { color: var(--text-muted); }
.chat-send-btn {
  width: 48px;
  height: 48px;
  background: var(--accent);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.15s;
}
.chat-send-btn:hover { background: var(--accent-dark); }
.chat-send-btn:disabled { background: var(--text-muted); cursor: default; }
.chat-send-btn svg { width: 18px; height: 18px; stroke: #fff; stroke-width: 2; fill: none; }

/* Mobile: stack vertically */
@media (max-width: 900px) {
  .demo-layout { grid-template-columns: 1fr; }
  .demo-chat-panel {
    position: static;
    height: 70vh;
    border-left: none;
    border-top: 1px solid rgba(26, 26, 46, 0.1);
  }
  .demo-info { padding: 48px 24px; }
  .demo-header { padding: 24px; }
}