/* Demo page styles — extends theme.css */
.demo-hero {
  padding: 4rem 2rem 3rem;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, var(--bg-alt) 0%, var(--bg) 100%);
}
.demo-hero-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.demo-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  border-radius: 100px;
  padding: 0.3rem 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 1.5rem;
}
.demo-badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.demo-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 1rem;
}
.demo-hero p {
  font-size: 1rem;
  color: var(--fg-muted);
  max-width: 55ch;
  line-height: 1.7;
  margin-bottom: 2rem;
}
.demo-grid {
  max-width: 1100px;
  margin: 0 auto;
  padding: 4rem 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
.demo-section-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}
.demo-section-title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 0.75rem;
}
.demo-section-desc {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.65;
  margin-bottom: 1.5rem;
}

/* Chat widget container */
.chat-widget {
  position: sticky;
  top: 80px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 580px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}
.chat-header {
  padding: 1.25rem 1.5rem;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 1rem;
}
.chat-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}
.chat-info h3 {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--fg);
}
.chat-info p {
  font-size: 0.75rem;
  color: var(--accent);
}
.chat-status {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.7rem;
  color: var(--fg-muted);
}
.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
}
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  scroll-behavior: smooth;
}
.msg {
  max-width: 85%;
  padding: 0.75rem 1rem;
  border-radius: 16px;
  font-size: 0.875rem;
  line-height: 1.55;
  animation: msgIn 0.3s ease;
}
@keyframes msgIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.msg-user {
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  border-bottom-right-radius: 4px;
  align-self: flex-end;
  color: var(--fg);
}
.msg-assistant {
  background: var(--bg);
  border: 1px solid var(--border);
  border-bottom-left-radius: 4px;
  align-self: flex-start;
  color: var(--fg);
}
.msg-time {
  font-size: 0.65rem;
  color: var(--fg-muted);
  margin-top: 0.25rem;
  opacity: 0.7;
}
.msg-user .msg-time { text-align: right; }

/* Typing indicator */
.typing-indicator {
  display: flex;
  gap: 4px;
  padding: 0.75rem 1rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  border-bottom-left-radius: 4px;
  align-self: flex-start;
  max-width: 60px;
}
.typing-indicator span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--fg-muted);
  animation: bounce 1.2s infinite;
}
.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }
@keyframes bounce {
  0%, 60%, 100% { transform: translateY(0); }
  30% { transform: translateY(-6px); }
}

/* Quick reply chips */
.quick-replies {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.5rem 1.5rem;
}
.quick-reply {
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  border-radius: 100px;
  padding: 0.4rem 1rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent);
  cursor: pointer;
  transition: all 0.2s;
}
.quick-reply:hover {
  background: var(--accent);
  color: var(--bg);
}

/* Chat input area */
.chat-input-area {
  padding: 1rem 1.5rem;
  background: var(--bg);
  border-top: 1px solid var(--border);
  display: flex;
  gap: 0.75rem;
  align-items: flex-end;
}
.chat-input {
  flex: 1;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0.75rem 1rem;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 0.875rem;
  resize: none;
  min-height: 44px;
  max-height: 120px;
  line-height: 1.5;
}
.chat-input::placeholder { color: var(--fg-muted); }
.chat-input:focus { outline: none; border-color: var(--accent); }
.send-btn {
  width: 44px;
  height: 44px;
  background: var(--accent);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
}
.send-btn:hover { background: #c4963a; transform: scale(1.05); }
.send-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

/* Slot picker */
.slots-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.slot-btn {
  background: var(--bg);
  border: 1px solid var(--accent);
  border-radius: 10px;
  padding: 0.5rem;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s;
  color: var(--fg);
}
.slot-btn:hover { background: var(--accent-dim); }
.slot-date {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.slot-time {
  font-size: 0.8rem;
  font-weight: 500;
  margin-top: 2px;
}

/* Booking confirmation */
.booking-confirm {
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  border-radius: 14px;
  padding: 1rem;
  text-align: center;
  margin-top: 0.5rem;
}
.booking-confirm .check-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}
.booking-confirm h4 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.25rem;
}
.booking-confirm p {
  font-size: 0.8rem;
  color: var(--fg-muted);
}

/* Stats bar */
.stats-bar {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}
.stats-row {
  display: flex;
  gap: 2rem;
  margin-bottom: 1rem;
}
.stats-row:last-child { margin-bottom: 0; }
.stat-item { flex: 1; }
.stat-value {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}
.stat-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--fg-muted);
  margin-top: 0.25rem;
}

/* Feature cards */
.feature-cards {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}
.feature-card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.25rem;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}
.feature-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--accent-dim);
  border: 1px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}
.feature-card h4 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--fg);
  margin-bottom: 0.25rem;
}
.feature-card p {
  font-size: 0.8rem;
  color: var(--fg-muted);
  line-height: 1.55;
}

/* Business switcher */
.biz-switcher {
  margin-bottom: 0.75rem;
}
.biz-switcher-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fg-muted);
  margin-bottom: 0.5rem;
}
.biz-buttons {
  display: flex;
  gap: 0.5rem;
}
.biz-btn {
  flex: 1;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--fg-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.2s;
}
.biz-btn span { font-size: 0.9rem; }
.biz-btn:hover { border-color: var(--accent); color: var(--fg); }
.biz-btn.active {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
}

/* Live stats bar */
.live-stats {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1rem 1.25rem;
  margin-bottom: 0.75rem;
}
.live-stats-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fg-muted);
  margin-bottom: 0.75rem;
}
.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  animation: livePulse 2s infinite;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.85); }
}
.live-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.5rem;
}
.live-stat-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.65rem;
  text-align: center;
}
.live-stat-num {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}
.live-stat-name {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--fg-muted);
  margin-top: 0.2rem;
}

/* Lead form modal */
.lead-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.lead-modal.hidden { display: none; }
.lead-modal-box {
  background: var(--bg-alt);
  border: 1px solid var(--accent);
  border-radius: 20px;
  padding: 2rem;
  width: 100%;
  max-width: 440px;
}
.lead-modal-box h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 0.5rem;
}
.lead-modal-box > p {
  font-size: 0.875rem;
  color: var(--fg-muted);
  margin-bottom: 1.5rem;
}
.form-group { margin-bottom: 1rem; }
.form-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--fg-muted);
  margin-bottom: 0.4rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.65rem 0.85rem;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 0.875rem;
}
.form-group input::placeholder { color: var(--fg-muted); }
.form-group input:focus, .form-group select:focus {
  outline: none;
  border-color: var(--accent);
}
.form-submit {
  width: 100%;
  background: var(--accent);
  border: none;
  border-radius: 12px;
  padding: 0.85rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--bg);
  cursor: pointer;
  transition: background 0.2s;
}
.form-submit:hover { background: #c4963a; }

/* Responsive */
@media (max-width: 900px) {
  .demo-grid { grid-template-columns: 1fr; }
  .chat-widget { position: static; height: 520px; }
}
@media (max-width: 480px) {
  .demo-hero { padding: 3rem 1.25rem 2rem; }
  .slots-grid { grid-template-columns: 1fr 1fr; }
}