/*
Theme Name: WhatsApp AI Inbox
Theme URI: https://example.com
Author: Custom Build
Description: WordPress theme with a WhatsApp-style unified inbox demo, AI-drafted replies (via Claude API), and a pricing/landing page. Requires a Claude API key entered under Settings > WhatsApp AI to enable real AI replies.
Version: 1.0
Requires PHP: 7.4
Text Domain: whatsapp-ai
*/

:root{
  --bg: #0b0f14;
  --panel: #10161d;
  --panel-2: #151c24;
  --border: #232b34;
  --text: #e8edf2;
  --muted: #93a1ad;
  --accent: #1fae6f;
  --accent-2: #17c98d;
  --hot: #e5484d;
  --warm: #f5a623;
}

*{ box-sizing:border-box; }

body{
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  margin:0;
}

a{ color: inherit; text-decoration:none; }

.wai-container{ max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* Header */
.wai-header{ display:flex; align-items:center; justify-content:space-between; padding:20px 0; border-bottom:1px solid var(--border); }
.wai-logo{ font-weight:700; font-size:20px; }
.wai-nav a{ margin-left:24px; color:var(--muted); font-size:14px; }
.wai-nav a:hover{ color:var(--text); }

/* Pricing */
.wai-pricing{ display:grid; grid-template-columns: repeat(4, 1fr); gap:20px; margin: 60px 0; }
@media (max-width: 900px){ .wai-pricing{ grid-template-columns: 1fr; } }

.wai-plan{ background: var(--panel); border:1px solid var(--border); border-radius:14px; padding:28px; position:relative; }
.wai-plan.featured{ border-color: var(--accent-2); }
.wai-badge{ position:absolute; top:-14px; left:24px; background: var(--accent-2); color:#04170f; font-size:12px; font-weight:700; padding:4px 12px; border-radius:20px; }
.wai-plan h3{ margin:0 0 8px; font-size:22px; }
.wai-plan p.desc{ color:var(--muted); font-size:14px; min-height:56px; }
.wai-price{ font-size:34px; font-weight:800; margin:14px 0 4px; }
.wai-price span{ font-size:14px; color:var(--muted); font-weight:400; }
.wai-meta{ font-size:13px; color:var(--muted); margin-bottom:18px; }
.wai-btn{ display:block; text-align:center; padding:12px; border-radius:8px; font-weight:700; cursor:pointer; border:1px solid var(--border); background: var(--panel-2); color:var(--text); }
.wai-btn.primary{ background: var(--accent); color:#04170f; border-color:var(--accent); }
.wai-features{ list-style:none; padding:18px 0 0; margin:18px 0 0; border-top:1px solid var(--border); font-size:14px; }
.wai-features li{ padding:6px 0; color:var(--text); }
.wai-features li::before{ content:"✓ "; color: var(--accent-2); }

/* Demo inbox */
.wai-demo-wrap{ margin:60px 0; }
.wai-demo-browser{ background:#f4f6f8; color:#111; border-radius:14px; overflow:hidden; border:1px solid #dcdfe3; }
.wai-demo-topbar{ display:flex; align-items:center; gap:10px; padding:10px 16px; background:#fff; border-bottom:1px solid #eee; }
.wai-dot{ width:10px; height:10px; border-radius:50%; }
.wai-dot.r{ background:#ff5f56; } .wai-dot.y{ background:#ffbd2e; } .wai-dot.g{ background:#27c93f; }
.wai-url{ margin-left:8px; font-size:12px; color:#888; background:#f1f2f4; padding:4px 10px; border-radius:6px; }

.wai-demo-body{ display:flex; min-height:420px; }
.wai-list{ width:320px; border-right:1px solid #eee; overflow-y:auto; }
.wai-list-item{ padding:14px 16px; border-bottom:1px solid #f0f0f0; cursor:pointer; }
.wai-list-item:hover, .wai-list-item.active{ background:#f5fdf9; }
.wai-list-item .row1{ display:flex; justify-content:space-between; font-weight:600; font-size:14px; }
.wai-tag{ font-size:10px; font-weight:700; padding:2px 8px; border-radius:20px; }
.wai-tag.hot{ background:#fdeaea; color:var(--hot); }
.wai-tag.warm{ background:#fdf3e2; color:#b26a00; }
.wai-tag.support{ background:#e7f1fd; color:#1a5fb4; }
.wai-preview{ font-size:13px; color:#666; margin-top:4px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.wai-score{ font-size:11px; color:#999; margin-top:6px; }

.wai-thread{ flex:1; display:flex; flex-direction:column; }
.wai-thread-head{ padding:16px 20px; border-bottom:1px solid #eee; }
.wai-thread-head h4{ margin:0; font-size:15px; }
.wai-thread-head span{ font-size:12px; color:#888; }
.wai-thread-msgs{ flex:1; padding:20px; overflow-y:auto; }
.wai-bubble{ max-width:70%; padding:10px 14px; border-radius:12px; font-size:14px; margin-bottom:10px; }
.wai-bubble.in{ background:#f0f0f0; }
.wai-bubble.out{ background: var(--accent-2); color:#04170f; margin-left:auto; }
.wai-time{ font-size:10px; color:#999; margin-top:4px; }
.wai-composer{ display:flex; gap:8px; padding:14px; border-top:1px solid #eee; }
.wai-composer input{ flex:1; padding:10px 14px; border:1px solid #ddd; border-radius:8px; }
.wai-composer button{ padding:10px 16px; border:none; background: var(--accent); color:#04170f; font-weight:700; border-radius:8px; cursor:pointer; }
.wai-status{ font-size:12px; color:#999; padding:0 20px 12px; }

.wai-step-label{ display:inline-block; background:#e7f7f0; color:var(--accent); font-size:12px; font-weight:700; padding:4px 12px; border-radius:20px; margin-bottom:12px; }

footer.wai-footer{ border-top:1px solid var(--border); padding:30px 0; color:var(--muted); font-size:13px; text-align:center; }
