/* AI Frontly demo — Bright Smile Dental Studio (fictional) */
:root{
  --teal:#0F766E; --teal-dark:#0b5f58; --ink:#1f2937; --muted:#6b7280;
  --bg:#f8fafc; --card:#ffffff; --bubble-bot:#eef2f7; --bubble-user:#0F766E;
  --radius:14px;
}
*{box-sizing:border-box;margin:0;padding:0}
body{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;color:var(--ink);background:var(--bg);line-height:1.6}

/* Demo honesty banner */
.demo-banner{background:#1f2937;color:#fff;font-size:13px;padding:8px 16px;text-align:center;position:sticky;top:0;z-index:50}
.demo-badge{background:#f59e0b;color:#1f2937;font-weight:700;font-size:11px;padding:2px 8px;border-radius:20px;margin-right:8px;letter-spacing:.5px}

.wrap{max-width:960px;margin:0 auto;padding:0 20px}
.site-header{background:#fff;border-bottom:1px solid #e5e7eb;position:sticky;top:33px;z-index:40}
.nav{display:flex;justify-content:space-between;align-items:center;padding:14px 20px}
.logo{font-weight:700;font-size:18px}
.site-header nav a{margin-left:22px;color:var(--muted);text-decoration:none;font-size:15px}
.site-header nav a:hover{color:var(--teal)}

.hero{background:linear-gradient(135deg,#0F766E,#14b8a6);color:#fff;padding:72px 0;text-align:center}
.hero h1{font-size:clamp(30px,5vw,46px);margin-bottom:12px}
.hero p{opacity:.92;font-size:18px;max-width:600px;margin:0 auto 26px}
.hero-cta{display:flex;gap:12px;justify-content:center;flex-wrap:wrap}
.btn{background:#fff;color:var(--teal-dark);border:none;font-weight:700;font-size:16px;padding:13px 30px;border-radius:30px;cursor:pointer}
.btn:hover{transform:translateY(-1px)}
.btn-ghost{background:transparent;color:#fff;border:2px solid #fff}
.hero-hint{margin-top:18px;font-size:14px;opacity:.85}

.cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:16px;padding:40px 20px 8px}
.info{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:16px;padding:8px 20px 48px}
.card{background:var(--card);border:1px solid #e5e7eb;border-radius:var(--radius);padding:22px}
.card h3{margin-bottom:8px;color:var(--teal-dark)}
.card p{color:var(--muted);font-size:15px}

.site-footer{background:#fff;border-top:1px solid #e5e7eb;padding:28px 0;font-size:14px;color:var(--muted)}
.site-footer a{color:var(--teal)}

/* Launcher */
#chat-launcher{position:fixed;right:22px;bottom:22px;width:60px;height:60px;border-radius:50%;background:var(--teal);color:#fff;border:none;cursor:pointer;box-shadow:0 6px 20px rgba(15,118,110,.4);z-index:60;display:flex;align-items:center;justify-content:center}
#chat-launcher:hover{background:var(--teal-dark)}
#chat-launcher .dot{position:absolute;top:2px;right:2px;width:14px;height:14px;background:#ef4444;border:2px solid #fff;border-radius:50%;animation:pulse 1.6s infinite}
@keyframes pulse{0%,100%{transform:scale(1)}50%{transform:scale(1.25)}}

/* Widget */
#chat-widget{position:fixed;right:22px;bottom:94px;width:380px;max-width:calc(100vw - 32px);height:540px;max-height:calc(100vh - 130px);background:#fff;border-radius:18px;box-shadow:0 12px 44px rgba(0,0,0,.22);display:flex;flex-direction:column;overflow:hidden;z-index:60}
#chat-widget.hidden{display:none}
.chat-header{background:var(--teal);color:#fff;padding:14px 16px;display:flex;justify-content:space-between;align-items:center}
.chat-title{font-weight:700;font-size:16px}
.chat-sub{font-size:12.5px;opacity:.92;display:flex;align-items:center;gap:6px}
.online{width:8px;height:8px;background:#4ade80;border-radius:50%;display:inline-block}
.demo-tag{background:#f59e0b;color:#1f2937;font-weight:700;font-size:10.5px;padding:1px 7px;border-radius:12px;letter-spacing:.4px}
#chat-close{background:none;border:none;color:#fff;font-size:18px;cursor:pointer;opacity:.85}
#chat-close:hover{opacity:1}

#chat-body{flex:1;overflow-y:auto;padding:16px 14px;display:flex;flex-direction:column;gap:10px;background:#fbfdff}
.msg{max-width:82%;padding:10px 14px;border-radius:16px;font-size:14.5px;line-height:1.5;white-space:pre-wrap;word-wrap:break-word}
.msg.bot{background:var(--bubble-bot);color:var(--ink);align-self:flex-start;border-bottom-left-radius:4px}
.msg.user{background:var(--bubble-user);color:#fff;align-self:flex-end;border-bottom-right-radius:4px}
.msg .time{display:block;font-size:10.5px;opacity:.6;margin-top:4px}
.msg.typing{display:flex;gap:5px;padding:14px 16px}
.msg.typing span{width:7px;height:7px;background:#9ca3af;border-radius:50%;animation:blink 1.2s infinite}
.msg.typing span:nth-child(2){animation-delay:.2s}
.msg.typing span:nth-child(3){animation-delay:.4s}
@keyframes blink{0%,80%,100%{opacity:.25}40%{opacity:1}}

#quick-replies{display:flex;gap:8px;flex-wrap:wrap;padding:8px 14px;background:#fbfdff;border-top:1px solid #f1f5f9}
#quick-replies:empty{display:none}
.qr{background:#fff;border:1.5px solid var(--teal);color:var(--teal-dark);font-size:13px;font-weight:600;padding:7px 14px;border-radius:20px;cursor:pointer}
.qr:hover{background:var(--teal);color:#fff}

#chat-form{display:flex;border-top:1px solid #e5e7eb;padding:10px;background:#fff}
#chat-input{flex:1;border:1px solid #e5e7eb;border-radius:24px;padding:10px 16px;font-size:14.5px;outline:none}
#chat-input:focus{border-color:var(--teal)}
#chat-form button{background:var(--teal);color:#fff;border:none;width:42px;height:42px;border-radius:50%;font-size:17px;cursor:pointer;margin-left:8px;flex-shrink:0}
#chat-form button:hover{background:var(--teal-dark)}

@media (max-width:480px){
  #chat-widget{right:12px;bottom:88px}
  #chat-launcher{right:16px;bottom:16px}
  .site-header nav{display:none}
}
