* { box-sizing: border-box; }

:root {
  --ink: #e9ecf2;
  --muted: #9badc6;
  --card-border: rgba(255,255,255,0.06);
  --card-bg: linear-gradient(145deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
  --accent: #00c6ff;
  --accent-2: #6c5ce7;
  --success: #25d366;
  --glass: rgba(8, 10, 16, 0.55);
  --shadow-lg: 0 24px 80px rgba(0,0,0,0.45);
  --shadow-md: 0 14px 40px rgba(0,0,0,0.35);
  --ring: 0 0 0 1px rgba(255,255,255,0.05), 0 0 0 2px rgba(0,198,255,0.08);
}

body.page {
  margin: 0;
  font-family: 'Space Grotesk', 'Segoe UI', sans-serif;
  background:
    radial-gradient(circle at 15% 15%, rgba(108,92,231,0.16), transparent 35%),
    radial-gradient(circle at 85% 0%, rgba(0,199,255,0.14), transparent 34%),
    radial-gradient(circle at 70% 80%, rgba(255,255,255,0.04), transparent 40%),
    #05060a;
  color: var(--ink);
  min-height: 100vh;
  overflow-x: hidden;
}

* {
  scrollbar-width: thin;
  scrollbar-color: rgba(126, 227, 255, 0.45) rgba(255,255,255,0.06);
}

*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
*::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.06);
  border-radius: 999px;
}
*::-webkit-scrollbar-thumb {
  background: rgba(126, 227, 255, 0.45);
  border-radius: 999px;
  border: 2px solid rgba(255,255,255,0.06);
}

.bg-blob {
  position: fixed;
  width: 340px;
  height: 340px;
  filter: blur(90px);
  opacity: 0.6;
  z-index: 0;
  animation: float 14s ease-in-out infinite;
}
.bg-blob-1 { top: -80px; left: -40px; background: #6c5ce7; }
.bg-blob-2 { bottom: -120px; right: -60px; background: #00c6ff; animation-duration: 18s; }
.bg-grid {
  position: fixed;
  inset: 0;
  background-image: linear-gradient(transparent 0%, rgba(255,255,255,0.03) 100%);
  background-size: 100% 160px;
  mask-image: radial-gradient(circle at 50% 40%, rgba(255,255,255,0.35), transparent 60%);
  z-index: 0;
}
.bg-grid::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 24px 24px;
  opacity: 0.25;
  pointer-events: none;
}

@keyframes float {
  0%, 100% { transform: translate3d(0,0,0); }
  50% { transform: translate3d(20px, -20px, 0); }
}

@keyframes riseIn {
  0% { opacity: 0; transform: translate3d(0, 10px, 0) scale(0.98); }
  100% { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
}

@keyframes fadeSlide {
  0% { opacity: 0; transform: translate3d(0, 8px, 0); }
  100% { opacity: 1; transform: translate3d(0, 0, 0); }
}

.topbar {
  position: sticky;
  top: 0;
  padding: 16px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--glass);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  z-index: 2;
}
.brand {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.6px;
}
.pill {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  border: 1px solid rgba(255,255,255,0.08);
}
.pill-live {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: #05060a;
  font-weight: 600;
  box-shadow: 0 6px 18px rgba(0,198,255,0.25);
}

.dashboard {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px 18px 80px;
}

.hero {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  align-items: center;
  background: linear-gradient(135deg, rgba(108,92,231,0.22), rgba(0,198,255,0.18));
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 22px;
  box-shadow: var(--shadow-lg);
  animation: riseIn 0.55s ease both;
}
.hero h1 { margin: 8px 0 10px; font-size: 32px; line-height: 1.15; }
.eyebrow { text-transform: uppercase; letter-spacing: 1px; font-size: 12px; color: #8be9ff; margin: 0; }
.muted { color: #aab3c2; margin: 4px 0 0; line-height: 1.5; }
.avatar-wrap { display:flex; align-items:center; justify-content:center; }
.avatar {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  border: 3px solid rgba(255,255,255,0.12);
  object-fit: cover;
  display: none;
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
}

.input-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  width: 100%;
}
.input {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06);
  color: #fff;
  font-size: 15px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}
.input:focus { outline: none; box-shadow: var(--ring); }
.select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #9badc6 50%), linear-gradient(135deg, #9badc6 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 4px), calc(100% - 12px) calc(50% - 4px);
  background-size: 6px 6px;
  background-repeat: no-repeat;
}
.select[multiple] {
  background-image: none;
  min-height: 120px;
}
.textarea { resize: vertical; min-height: 120px; }

.btn {
  border: none;
  border-radius: 12px;
  padding: 12px 16px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn.primary {
  background: linear-gradient(135deg, var(--accent-2), var(--accent));
  color: #0a0a0f;
  box-shadow: 0 10px 30px rgba(108,92,231,0.35);
}
.btn.active {
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(255,255,255,0.1);
}
.btn.ghost {
  background: rgba(255,255,255,0.08);
  color: #f1f3f7;
  border: 1px solid rgba(255,255,255,0.12);
}
.btn.danger {
  background: rgba(255,77,77,0.14);
  color: #ff9a9a;
  border: 1px solid rgba(255,77,77,0.35);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible {
  outline: 2px solid rgba(0,198,255,0.6);
  outline-offset: 2px;
}

.back-link {
  color: #7ee3ff;
  text-decoration: none;
  font-weight: 600;
}

.cards {
  margin-top: 26px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 16px;
  backdrop-filter: blur(6px);
  animation: fadeSlide 0.6s ease both;
}
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.section-head h2 { margin: 0; }

.client-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 14px;
  margin-top: 14px;
}
.card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 14px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), 0 8px 28px rgba(0,0,0,0.2);
  height: 100%;
  animation: riseIn 0.5s ease both;
}
.client-card h3 { margin: 4px 0 2px; }
.client-card .meta { color: #9badc6; font-size: 13px; min-height: 18px; }
.client-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
.client-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,198,255,0.2);
  border: 1px solid rgba(0,198,255,0.35);
  color: #e9f7ff;
  font-weight: 600;
}
.client-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.client-avatar-fallback {
  font-size: 14px;
}
.client-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.client-count {
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  background: rgba(0,198,255,0.12);
  border: 1px solid rgba(0,198,255,0.3);
  color: #cfeeff;
  white-space: nowrap;
}
.card-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.status-badge {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  text-transform: capitalize;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
}
.status-ready { background: rgba(46, 204, 113, 0.15); color: #7bed9f; border-color: rgba(46,204,113,0.35); }
.status-qr, .status-authenticated { background: rgba(0,198,255,0.15); color: #7ee3ff; border-color: rgba(0,198,255,0.35); }
.status-disconnected, .status-auth_failure { background: rgba(255,77,77,0.15); color: #ff9a9a; border-color: rgba(255,77,77,0.35); }
.status-initializing { color: #f7e16b; border-color: rgba(247,225,107,0.3); background: rgba(247,225,107,0.08); }

.card-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}
.card-actions a { text-decoration: none; }

.empty {
  padding: 20px;
  border: 1px dashed rgba(255,255,255,0.15);
  border-radius: 12px;
  text-align: center;
  color: #9badc6;
}

.container { max-width: 1000px; margin: 20px auto; padding: 16px; }
a { color: #7ee3ff; }

.breadcrumb {
  margin: 6px 0 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.client-layout .hero { margin-bottom: 16px; }
.hero-compact { grid-template-columns: 80px 1fr auto; align-items: center; }
.status-chip {
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  font-weight: 600;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.chat-layout { max-width: 1200px; }
.groups-layout { max-width: 1200px; }
.bulk-layout { max-width: 1200px; }
.chat-shell {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 14px;
  margin-top: 12px;
}
.chat-list,
.chat-thread {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 14px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), var(--shadow-md);
}
.groups-shell {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 14px;
  margin-top: 12px;
}
.groups-list,
.groups-detail {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 14px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), var(--shadow-md);
}
.bulk-shell {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 14px;
  margin-top: 12px;
}
.bulk-form,
.bulk-preview {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 14px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), var(--shadow-md);
}
.preview-card {
  border-radius: 12px;
  padding: 12px;
  background: rgba(0,0,0,0.2);
  border: 1px solid rgba(255,255,255,0.08);
  min-height: 260px;
  display: grid;
  gap: 10px;
  align-content: start;
}
.preview-img {
  width: 100%;
  border-radius: 12px;
  display: none;
}
.preview-caption {
  color: var(--muted);
  font-size: 14px;
}
.upload-list {
  margin-top: 8px;
  display: grid;
  gap: 10px;
  max-height: 320px;
  overflow: auto;
  padding-right: 4px;
}
.upload-item {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 10px;
  padding: 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
}
.upload-thumb {
  width: 80px;
  height: 80px;
  border-radius: 10px;
  object-fit: cover;
  background: rgba(255,255,255,0.04);
}
.upload-meta { min-width: 0; }
.upload-name {
  font-weight: 600;
  font-size: 12px;
}
.upload-url {
  color: var(--muted);
  font-size: 11px;
  word-break: break-all;
  margin-top: 4px;
}
.upload-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.bulk-jobs {
  display: grid;
  grid-template-columns: 1fr 0.9fr;
  gap: 14px;
}
.job-list {
  display: grid;
  gap: 8px;
}
.job-card {
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
  cursor: pointer;
}
.job-card.active {
  background: rgba(0,198,255,0.12);
  border-color: rgba(0,198,255,0.35);
}
.job-title {
  font-weight: 600;
  font-size: 13px;
}
.job-meta {
  color: var(--muted);
  font-size: 12px;
  margin-top: 4px;
}
.job-detail {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 14px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), var(--shadow-md);
}
.job-stats {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}
.job-row {
  display: flex;
  justify-content: space-between;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  padding: 10px 12px;
}
.job-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.member-list {
  margin-top: 6px;
  display: grid;
  gap: 8px;
  max-height: 520px;
  overflow: auto;
}
.member-actions {
  display: flex;
  justify-content: flex-end;
  margin: 6px 0 8px;
}
.member-row {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
  font-weight: 600;
  letter-spacing: 0.5px;
}
.chat-list-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.chat-items {
  margin-top: 12px;
  display: grid;
  gap: 8px;
  max-height: 520px;
  overflow: auto;
}
.chat-item {
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--card-border);
  background: rgba(255,255,255,0.03);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
  position: relative;
  animation: fadeSlide 0.4s ease both;
}
.chat-item:hover {
  transform: translateY(-1px);
  border-color: rgba(0,198,255,0.25);
}
.chat-item-body { min-width: 0; }
.chat-badge {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: linear-gradient(180deg, #3afc8e, #25d366);
  color: #0b141a;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.chat-avatar-sm {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,198,255,0.2);
  color: #e9f7ff;
  font-weight: 600;
  border: 1px solid rgba(0,198,255,0.35);
}
.chat-item.active {
  background: rgba(0,198,255,0.12);
  border-color: rgba(0,198,255,0.35);
}
.chat-item-title { font-weight: 600; }
.chat-item-meta {
  color: var(--muted);
  font-size: 12px;
  margin-top: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-thread-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.chat-head {
  display: flex;
  align-items: center;
  gap: 12px;
}
.chat-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(108,92,231,0.2);
  color: #f3f5fb;
  font-weight: 600;
  border: 1px solid rgba(108,92,231,0.35);
  position: relative;
  overflow: hidden;
}
.chat-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}
.msg-media {
  max-width: 240px;
  border-radius: 12px;
  display: block;
}
.msg-media-placeholder {
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(255,255,255,0.08);
  color: #c8d2e2;
  font-size: 12px;
}
.chat-messages {
  height: 420px;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 8px;
  border-radius: 12px;
  background:
    radial-gradient(circle at 10% 0%, rgba(0,198,255,0.12), transparent 38%),
    linear-gradient(180deg, rgba(10,12,20,0.6), rgba(5,6,10,0.8));
  border: 1px solid rgba(255,255,255,0.08);
}
.msg {
  max-width: 70%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.1);
  display: inline-flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.28);
  animation: fadeSlide 0.25s ease both;
}
.msg-text { white-space: pre-wrap; }
.msg-in {
  align-self: flex-start;
  background: rgba(255,255,255,0.1);
}
.msg-out {
  align-self: flex-end;
  background: linear-gradient(135deg, rgba(0,198,255,0.25), rgba(108,92,231,0.22));
  border-color: rgba(0,198,255,0.5);
}
.msg-time {
  font-size: 11px;
  color: var(--muted);
  align-self: flex-end;
}
.chat-input {
  margin-top: 10px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}
.qr-box {
  border: 1px dashed rgba(255,255,255,0.2);
  border-radius: 12px;
  padding: 12px;
  text-align: center;
}
.qr-img {
  max-width: 100%;
  display: none;
  border-radius: 12px;
  background: rgba(255,255,255,0.04);
  padding: 8px;
}

.wa-instructions {
  margin-top: 14px;
  padding: 16px 16px 14px;
  border-radius: 14px;
  background: #ffffff;
  color: #111827;
  box-shadow: 0 16px 40px rgba(0,0,0,0.2);
  border: 1px solid rgba(0,0,0,0.06);
}
.wa-panel { display: grid; gap: 12px; }
.wa-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.wa-title {
  font-size: 18px;
  font-weight: 600;
  color: #0b141a;
}
.wa-link {
  font-size: 13px;
  font-weight: 600;
  color: #128c7e;
}
.wa-olist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.wa-step {
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 10px;
  align-items: start;
  color: #1f2937;
  font-size: 14px;
  line-height: 1.5;
}
.wa-num {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #e6f7f0;
  color: #0b141a;
  font-weight: 600;
  border: 1px solid #ccefe2;
}
.wa-help {
  font-size: 12px;
  color: #6b7280;
  border-top: 1px solid #eef2f5;
  padding-top: 10px;
}
.list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.list li {
  display: flex;
  justify-content: space-between;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 10px;
  padding: 10px 12px;
  color: #c8d2e2;
}
.list span { color: #9badc6; }
.list strong { color: #f3f5fb; }
.small { font-size: 13px; }

.form-card { max-width: 720px; }
.form-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.field { display: flex; flex-direction: column; gap: 6px; color: #c8d2e2; }
.field span { color: #9badc6; font-size: 14px; }
.actions { display: flex; justify-content: flex-end; }
.tab-buttons { display: inline-flex; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }

.wa-web {
  background: #0b141a;
  color: #e9edef;
  font-family: 'Rubik', 'Segoe UI', sans-serif;
}
.wa-web .bg-blob,
.wa-web .bg-grid,
.wa-web .topbar { display: none; }
.wa-shell {
  height: 100vh;
  display: grid;
  grid-template-columns: 360px 1fr;
  background:
    linear-gradient(135deg, rgba(18, 27, 33, 0.85), rgba(18, 27, 33, 0.85)),
    radial-gradient(circle at 20% 20%, rgba(0, 167, 131, 0.15), transparent 45%),
    #0b141a;
}
.wa-sidebar {
  border-right: 1px solid rgba(255,255,255,0.06);
  background: #111b21;
  display: grid;
  grid-template-rows: auto auto auto auto 1fr;
}
.wa-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: #202c33;
}
.wa-user { display: flex; align-items: center; gap: 12px; }
.wa-user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #00a884;
  color: #0b141a;
  font-weight: 700;
  display: grid;
  place-items: center;
}
.wa-user-name { font-weight: 600; }
.wa-user-id { font-size: 12px; color: #8696a0; }
.wa-back {
  text-decoration: none;
  font-size: 12px;
  color: #aebac1;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.08);
}
.wa-search {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.wa-new-chat {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  display: grid;
  gap: 8px;
}
.wa-new-chat-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}
.wa-input {
  width: 100%;
  background: #111b21;
  border: 1px solid rgba(255,255,255,0.08);
  color: #e9edef;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
}
.wa-input:focus {
  outline: none;
  border-color: rgba(0,168,132,0.6);
  box-shadow: 0 0 0 2px rgba(0,168,132,0.15);
}
.wa-btn {
  border: none;
  border-radius: 8px;
  padding: 10px 14px;
  background: #00a884;
  color: #0b141a;
  font-weight: 600;
  cursor: pointer;
}
.wa-btn.ghost {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.12);
  color: #aebac1;
}
.wa-chat-list-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  color: #aebac1;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.wa-chat-list {
  overflow: auto;
  padding: 6px 0;
}
.wa-chat-list .chat-item {
  border: none;
  border-radius: 0;
  padding: 12px 16px;
  background: transparent;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.wa-chat-list .chat-item:hover {
  border-color: rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.04);
  transform: none;
}
.wa-chat-list .chat-item.active {
  background: rgba(0,168,132,0.15);
  border-color: rgba(0,168,132,0.35);
}
.wa-chat-list .chat-avatar-sm {
  background: rgba(0,168,132,0.2);
  border: 1px solid rgba(0,168,132,0.4);
  color: #d0f5ee;
}
.wa-thread {
  display: grid;
  grid-template-rows: auto 1fr auto;
  background:
    radial-gradient(circle at 20% 0%, rgba(0,168,132,0.08), transparent 45%),
    #0b141a;
}
.wa-thread-head {
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  background: #202c33;
}
.wa-chat-head { display: flex; align-items: center; gap: 14px; }
.wa-chat-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  color: #e9edef;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.wa-chat-avatar-img { width: 100%; height: 100%; object-fit: cover; display: none; }
.wa-chat-label { font-size: 12px; color: #8696a0; text-transform: uppercase; letter-spacing: 1px; }
.wa-chat-title { font-size: 16px; font-weight: 600; }
.wa-chat-meta { font-size: 12px; color: #8696a0; }
.wa-thread-body {
  padding: 18px;
  overflow: auto;
  background:
    radial-gradient(circle at 25% 20%, rgba(0,168,132,0.08), transparent 45%),
    linear-gradient(180deg, rgba(11,20,26,0.95), rgba(11,20,26,0.9));
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.wa-thread-body .msg {
  border-radius: 8px;
  border: none;
  box-shadow: none;
  display: flex;
  flex-direction: column;
}
.wa-thread-body .msg-in {
  background: #202c33;
}
.wa-thread-body .msg-out {
  background: #005c4b;
  color: #e9edef;
}
.wa-thread-body .msg-time { color: rgba(255,255,255,0.6); }
.wa-thread-input {
  padding: 12px 18px;
  display: grid;
  gap: 10px;
  background: #202c33;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.wa-input-bar {
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  align-items: center;
  gap: 10px;
}
.wa-input-main {
  background: #111b21;
}
.wa-icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #aebac1;
  display: grid;
  place-items: center;
  cursor: pointer;
}
.wa-icon-btn:hover {
  background: rgba(255,255,255,0.08);
}
.wa-icon {
  font-size: 16px;
  font-weight: 700;
}
.wa-send-btn {
  width: auto;
  border-radius: 8px;
  padding: 8px 14px;
  background: #00a884;
  color: #0b141a;
  font-weight: 600;
}

@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; }
  .topbar { position: static; }
  .dashboard { padding: 16px 14px 60px; }
  .input-row { grid-template-columns: 1fr; }
  .card-actions { flex-direction: column; }
  .chat-shell { grid-template-columns: 1fr; }
  .groups-shell { grid-template-columns: 1fr; }
  .bulk-shell { grid-template-columns: 1fr; }
  .bulk-jobs { grid-template-columns: 1fr; }
  .chat-messages { height: 360px; }
  .wa-shell { grid-template-columns: 1fr; }
  .wa-sidebar { border-right: none; border-bottom: 1px solid rgba(255,255,255,0.06); }
}
