@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Inter:wght@400;500;600&family=JetBrains+Mono&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&display=swap");

:root {
  color-scheme: light;
  --bg: #f8f9fa;
  --bg-accent: radial-gradient(circle at top left, rgba(37, 211, 102, 0.12), transparent 28%), radial-gradient(circle at bottom right, rgba(0, 109, 47, 0.08), transparent 24%), linear-gradient(180deg, #f3fcef 0%, #f8f9fa 100%);
  --surface: rgba(255, 255, 255, 0.9);
  --surface-strong: #ffffff;
  --border: #bbcbb9;
  --text: #151e16;
  --muted: #3c4a3d;
  --muted-soft: #64748b;
  --accent: #006d2f;
  --accent-dark: #005523;
  --accent-bright: #25d366;
  --accent-surface: #e7f1e4;
  --danger: #b42318;
  --success: #15703c;
  --shadow: 0 18px 60px rgba(21, 30, 22, 0.08);
  --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.05);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  background: var(--bg);
  background-image: var(--bg-accent);
  color: var(--text);
}

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

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

body {
  min-height: 100vh;
}

.marketing-page,
.auth-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
}

.hero-card,
.auth-card,
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}

.hero-card {
  max-width: 780px;
  border-radius: 28px;
  padding: 40px;
}

.hero-card h1,
.auth-card h1,
.page-title {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.04;
}

.hero-card p,
.auth-copy,
.section-copy {
  color: var(--muted);
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.primary-button,
button {
  border: 0;
  border-radius: 14px;
  padding: 12px 18px;
  background: var(--accent);
  color: white;
  font-weight: 600;
}

.secondary-button {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent-dark);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
}

.auth-card {
  width: min(460px, 100%);
  border-radius: 24px;
  padding: 32px;
}

.auth-link {
  margin: 18px 0 0;
  color: var(--muted);
}

.stack-form {
  display: grid;
  gap: 14px;
}

.stack-form label {
  display: grid;
  gap: 8px;
  font-size: 0.95rem;
  color: var(--muted);
}

.stack-form input,
.stack-form textarea,
.language-switcher select {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--surface-strong);
  padding: 12px 14px;
  color: var(--text);
}

.page-shell {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 290px;
  padding: 28px 20px;
  border-right: 1px solid var(--border);
  background: rgba(250, 252, 251, 0.84);
  backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.sidebar-top {
  display: grid;
  gap: 16px;
}

.sidebar-top h2 {
  margin: 0;
  font-size: 1.4rem;
}

.sidebar-nav {
  display: grid;
  gap: 10px;
}

.sidebar-nav a,
.sidebar-muted {
  padding: 12px 14px;
  border-radius: 14px;
  color: var(--text);
}

.sidebar-nav a:hover {
  background: rgba(31, 157, 85, 0.08);
}

.sidebar-muted {
  color: #8a958f;
}

.sidebar-logout {
  width: 100%;
  margin-top: auto;
}

.content {
  flex: 1;
  padding: 32px;
}

.section-head {
  margin-bottom: 24px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.card {
  border-radius: 22px;
  padding: 22px;
}

.metric-label {
  color: var(--muted);
  margin-bottom: 10px;
}

.metric-value {
  font-size: 2rem;
  font-weight: 700;
}

.list-card ul {
  margin: 0;
  padding-left: 18px;
}

.list-card li {
  padding: 8px 0;
}

.language-switcher {
  display: grid;
  gap: 8px;
}

.language-switcher-compact {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid rgba(187, 203, 185, 0.7);
  background: rgba(231, 241, 228, 0.88);
}

.language-switcher-compact button {
  min-width: 44px;
  padding: 8px 12px;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  box-shadow: none;
}

.language-switcher-compact button.is-active {
  background: white;
  color: var(--accent);
  box-shadow: 0 1px 4px rgba(21, 30, 22, 0.08);
}

.language-switcher label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.9rem;
}

.form-error {
  color: var(--danger);
  margin: 0;
}

.form-success {
  color: var(--success);
  margin: 0;
}

.auth-page-enterprise {
  position: relative;
  overflow: hidden;
}

.auth-page-login {
  padding: 40px 24px 32px;
}

.auth-enterprise-glow {
  position: fixed;
  z-index: 0;
  width: 360px;
  height: 360px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(37, 211, 102, 0.15), transparent 68%);
  pointer-events: none;
}

.auth-enterprise-glow-right {
  top: -90px;
  right: -80px;
}

.auth-enterprise-glow-left {
  bottom: -120px;
  left: -120px;
}

.auth-container,
.two-factor-shell {
  width: min(100%, 440px);
  display: grid;
  gap: 32px;
  position: relative;
  z-index: 1;
}

.two-factor-shell {
  width: min(100%, 480px);
}

.auth-container-login {
  gap: 24px;
}

.auth-login-toolbar {
  display: flex;
  justify-content: center;
}

.auth-login-locale {
  display: inline-flex;
  justify-content: center;
}

.auth-brand,
.two-factor-brand {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 16px;
}

.auth-brand-mark,
.two-factor-mark {
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: var(--accent-bright);
  color: white;
  display: grid;
  place-items: center;
  box-shadow: 0 6px 16px rgba(0, 109, 47, 0.18);
}

.auth-brand-mark svg,
.two-factor-mark svg,
.button-icon svg,
.input-icon svg,
.security-icon svg {
  width: 24px;
  height: 24px;
}

.auth-brand-mark svg {
  width: 38px;
  height: 38px;
}

.two-factor-mark svg {
  width: 34px;
  height: 34px;
}

.auth-brand-copy,
.two-factor-brand h1 {
  display: grid;
  gap: 6px;
}

.auth-brand-copy {
  justify-items: center;
}

.auth-brand-copy h1,
.two-factor-brand h1 {
  margin: 0;
  font-size: 2rem;
  line-height: 1.3;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.auth-brand-copy h2 {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.3;
  font-weight: 700;
  color: var(--text);
}

.auth-brand-copy p,
.two-factor-brand p {
  margin: 0;
  color: var(--muted-soft);
  max-width: 28rem;
}

.auth-card-enterprise,
.two-factor-card {
  background: var(--surface-strong);
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(187, 203, 185, 0.3);
  padding: 40px 46px;
}

.enterprise-form {
  display: grid;
  gap: 24px;
}

.auth-form-block {
  display: grid;
  gap: 10px;
}

.field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.field-label {
  font-size: 0.76rem;
  line-height: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--muted);
}

.text-link {
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 600;
}

.text-link:hover {
  text-decoration: underline;
}

.text-link-compact {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  padding-right: 14px;
  z-index: 1;
}

.input-shell {
  position: relative;
  display: flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-strong);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.input-shell:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(37, 211, 102, 0.12);
}

.input-shell input {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  border-radius: 14px;
  padding: 14px 92px 14px 46px;
  color: var(--text);
}

.input-shell input::placeholder {
  color: #8ea08c;
}

.input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #8ba08c;
  pointer-events: none;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 0.95rem;
}

.check-row input {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}

.auth-submit {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: 14px;
  background: var(--accent-bright);
  color: white;
  box-shadow: 0 8px 16px rgba(37, 211, 102, 0.24);
}

.auth-submit:hover {
  filter: brightness(0.98);
}

.auth-submit[disabled],
.auth-secondary-button[disabled] {
  opacity: 0.9;
}

.button-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.brand-google svg {
  width: 18px;
  height: 18px;
}

.auth-divider {
  position: relative;
  text-align: center;
  margin: 20px 0 0;
}

.auth-divider::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: var(--border);
}

.auth-divider span {
  position: relative;
  z-index: 1;
  background: var(--surface-strong);
  padding: 0 14px;
  font-size: 0.76rem;
  line-height: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6c7b6b;
  font-weight: 700;
}

.auth-secondary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.auth-secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px;
  border-radius: 14px;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.auth-secondary-button:hover {
  background: rgba(237, 246, 233, 0.7);
}

.auth-assist-row {
  margin-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted-soft);
  font-size: 0.9rem;
}

.auth-assist-row p {
  margin: 0;
}

.auth-footer {
  display: grid;
  justify-items: center;
  gap: 16px;
  text-align: center;
}

.auth-footer p {
  margin: 0;
  color: var(--muted-soft);
}

.auth-footer .text-link {
  display: inline;
}

.auth-footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 18px;
}

.auth-footer-links button {
  border: 0;
  background: transparent;
  padding: 0;
  color: #6c7b6b;
  font-size: 0.76rem;
  line-height: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.auth-footer-links button:hover {
  color: var(--muted);
}

.auth-page-symbol {
  position: fixed;
  z-index: 0;
  display: none;
  opacity: 0.08;
  color: var(--accent);
  pointer-events: none;
}

.auth-page-symbol .material-symbols-outlined {
  font-size: 320px;
  line-height: 1;
}

.auth-page-symbol-top {
  top: 0;
  right: 0;
  padding: 48px;
}

.auth-page-symbol-bottom {
  bottom: 0;
  left: 0;
  padding: 48px;
}

.auth-page-login .language-switcher-compact {
  background: rgba(231, 241, 228, 0.95);
  border-color: rgba(187, 203, 185, 0.9);
  box-shadow: 0 12px 32px rgba(21, 30, 22, 0.06);
}

.auth-page-login .language-switcher-compact button {
  min-width: 50px;
  padding: 9px 14px;
  font-size: 0.9rem;
  letter-spacing: 0.03em;
}

.auth-page-login .language-switcher-compact button.is-active {
  color: var(--accent);
}

.two-factor-copy {
  display: grid;
  gap: 12px;
  text-align: center;
  margin-bottom: 28px;
}

.two-factor-copy h2 {
  margin: 0;
  font-size: 1.25rem;
}

.two-factor-copy p,
.security-info-card p,
.placeholder-note p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.otp-row {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 24px;
}

.otp-box {
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: white;
  color: var(--accent-dark);
  font-size: 1.3rem;
  font-weight: 700;
}

.two-factor-meta {
  margin-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.placeholder-note {
  margin-top: 22px;
  border-radius: 16px;
  background: var(--accent-surface);
  padding: 16px 18px;
}

.placeholder-note strong {
  display: block;
  margin-bottom: 6px;
  color: var(--accent-dark);
}

.two-factor-info-grid {
  display: grid;
  gap: 18px;
}

.security-info-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: rgba(231, 241, 228, 0.72);
  border: 1px solid rgba(187, 203, 185, 0.2);
  border-radius: 20px;
  padding: 22px;
}

.security-info-card h3 {
  margin: 0 0 6px;
  font-size: 0.82rem;
  line-height: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.security-icon {
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  border-radius: 12px;
  background: white;
  display: grid;
  place-items: center;
  color: var(--accent);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.dashboard-app {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
}

.dashboard-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 24px 16px;
  background: rgba(255, 255, 255, 0.88);
  border-right: 1px solid rgba(187, 203, 185, 0.45);
  backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.dashboard-brand h1 {
  margin: 0;
  font-size: 1.55rem;
  color: var(--accent);
}

.dashboard-brand p {
  margin: 6px 0 0;
  color: var(--muted-soft);
  font-size: 0.92rem;
}

.dashboard-primary-action {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 13px 16px;
  border-radius: 16px;
  background: var(--accent-bright);
  color: white;
  font-weight: 700;
  box-shadow: 0 10px 18px rgba(37, 211, 102, 0.2);
}

.dashboard-nav {
  display: grid;
  gap: 6px;
}

.dashboard-nav-link,
.dashboard-logout-button {
  width: 100%;
  text-align: left;
  padding: 12px 14px;
  border-radius: 14px;
  color: var(--muted);
  background: transparent;
  border: 0;
  font-weight: 600;
}

.dashboard-nav-link:hover,
.dashboard-logout-button:hover {
  background: rgba(231, 241, 228, 0.95);
}

.dashboard-nav-link.is-active {
  background: rgba(37, 211, 102, 0.18);
  color: var(--accent-dark);
}

.dashboard-sidebar-footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid rgba(187, 203, 185, 0.45);
  display: grid;
  gap: 6px;
}

.dashboard-main {
  min-width: 0;
}

.dashboard-topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 18px 32px;
  background: rgba(243, 252, 239, 0.78);
  border-bottom: 1px solid rgba(187, 203, 185, 0.35);
  backdrop-filter: blur(14px);
}

.dashboard-topbar-left {
  display: flex;
  align-items: center;
  gap: 18px;
}

.dashboard-topbar-title {
  display: grid;
  gap: 2px;
}

.dashboard-topbar-title p {
  margin: 0;
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
}

.dashboard-topbar-title h2 {
  margin: 0;
  font-size: 1.2rem;
}

.dashboard-search {
  flex: 1;
  max-width: 420px;
}

.dashboard-search input,
.form-stack input,
.form-stack textarea,
.chat-composer input {
  width: 100%;
  border: 1px solid rgba(187, 203, 185, 0.65);
  border-radius: 14px;
  padding: 13px 15px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
}

.dashboard-topbar-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.dashboard-icon-button {
  width: 42px;
  height: 42px;
  padding: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  border: 1px solid rgba(187, 203, 185, 0.5);
  box-shadow: none;
  display: grid;
  place-items: center;
}

.dashboard-icon-button span {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  border: 2px solid currentColor;
  display: block;
}

.dashboard-profile {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dashboard-profile strong,
.page-heading,
.surface-card h2,
.surface-card h3 {
  margin: 0;
}

.dashboard-profile span {
  display: block;
  color: var(--muted-soft);
  font-size: 0.8rem;
}

.dashboard-avatar {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-bright));
  color: white;
  display: grid;
  place-items: center;
  font-weight: 700;
}

.dashboard-content {
  padding: 32px;
  display: grid;
  gap: 24px;
}

.dashboard-main-conversations {
  height: 100dvh;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
}

.dashboard-content-conversations {
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) 320px;
  gap: 24px;
}

.overview-main,
.overview-side {
  display: grid;
  gap: 24px;
  align-content: start;
}

.overview-kpi-card {
  min-height: 164px;
}

.overview-kpi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.overview-kpi-dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: rgba(220, 229, 216, 1);
}

.overview-kpi-dot.success {
  background: rgba(37, 211, 102, 1);
}

.overview-kpi-dot.warning {
  background: rgba(245, 158, 11, 1);
}

.overview-volume-card {
  min-height: 428px;
}

.overview-campaign-grid {
  grid-template-columns: minmax(0, 1.6fr) 0.8fr 0.8fr;
}

.page-section,
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
}

.page-header.split {
  align-items: center;
}

.page-eyebrow {
  margin: 0 0 10px;
  color: var(--accent-dark);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.page-heading {
  font-size: clamp(2rem, 4vw, 2.7rem);
  line-height: 1.06;
}

.page-copy,
.card-caption,
.surface-card p,
.surface-card span,
.surface-card small {
  color: var(--muted-soft);
}

.header-actions,
.button-row,
.tabs-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.surface-card {
  background: rgba(255, 255, 255, 0.94);
  border-radius: 24px;
  border: 1px solid rgba(187, 203, 185, 0.35);
  box-shadow: var(--shadow-soft);
  padding: 22px;
}

.surface-link-card {
  display: block;
}

.surface-link-card:hover {
  transform: translateY(-1px);
}

.dashboard-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.card-kicker {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.card-metric-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.card-metric-row h3,
.surface-card > h3 {
  font-size: 2rem;
  line-height: 1;
}

.status-pill,
.soft-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
}

.soft-chip {
  background: rgba(231, 241, 228, 1);
  color: var(--accent-dark);
}

.status-pill.success {
  background: rgba(37, 211, 102, 0.18);
  color: var(--accent-dark);
}

.status-pill.warning {
  background: rgba(245, 158, 11, 0.18);
  color: #9a5a00;
}

.status-pill.neutral {
  background: rgba(220, 229, 216, 1);
  color: var(--muted);
}

.dashboard-two-column {
  display: grid;
  grid-template-columns: 1.65fr 1fr;
  gap: 16px;
}

.dashboard-two-column-bottom {
  grid-template-columns: 1.3fr 1fr;
}

.tall-card {
  min-height: 360px;
}

.card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.chart-bars {
  height: 280px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 14px;
  align-items: end;
}

.chart-column {
  display: grid;
  justify-items: center;
  gap: 10px;
  height: 100%;
}

.chart-column div {
  width: 100%;
  border-radius: 18px 18px 10px 10px;
  background: linear-gradient(180deg, rgba(37, 211, 102, 0.95), rgba(0, 109, 47, 0.88));
}

.metric-stack {
  display: grid;
  gap: 18px;
}

.metric-stack div {
  display: grid;
  gap: 6px;
  padding: 16px;
  border-radius: 18px;
  background: rgba(243, 252, 239, 0.88);
}

.metric-stack strong,
.detail-stack strong {
  color: var(--text);
  font-size: 1.18rem;
}

.detail-stack {
  display: grid;
  gap: 16px;
}

.detail-stack div {
  display: grid;
  gap: 6px;
}

.plain-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 12px;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.data-table {
  display: grid;
}

.data-row {
  display: grid;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(187, 203, 185, 0.3);
}

.data-row:last-child {
  border-bottom: 0;
}

.data-row-head {
  padding-top: 0;
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.data-row-link:hover {
  background: rgba(243, 252, 239, 0.65);
}

.contacts-grid,
.campaign-grid,
.message-grid,
.webhook-grid,
.users-grid,
.logs-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.conversation-layout {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 16px;
}

.conversation-list {
  display: grid;
  gap: 10px;
}

.conversation-item {
  border-radius: 18px;
  padding: 16px;
  background: rgba(243, 252, 239, 0.72);
  border: 1px solid transparent;
}

.conversation-item.active {
  border-color: rgba(37, 211, 102, 0.32);
  background: rgba(231, 241, 228, 0.94);
}

.conversation-item p,
.conversation-item span {
  margin: 6px 0 0;
}

.conversation-chat {
  display: grid;
  gap: 18px;
}

.chat-header,
.chat-composer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.chat-thread {
  min-height: 340px;
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 12px 0;
}

.chat-bubble {
  max-width: 70%;
  padding: 14px 16px;
  border-radius: 20px;
  line-height: 1.6;
}

.chat-bubble.incoming {
  background: rgba(231, 241, 228, 1);
}

.chat-bubble.outgoing {
  margin-left: auto;
  background: rgba(37, 211, 102, 0.18);
}

.tabs-row {
  margin-bottom: 18px;
  color: var(--muted-soft);
}

.tab-active {
  color: var(--accent);
  font-weight: 700;
  border-bottom: 2px solid var(--accent);
  padding-bottom: 8px;
}

.form-stack {
  display: grid;
  gap: 14px;
}

.form-stack label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.form-stack input,
.form-stack select,
.form-stack textarea {
  width: 100%;
  border: 1px solid rgba(187, 203, 185, 0.55);
  background: rgba(243, 252, 239, 0.8);
  color: var(--text);
  border-radius: 14px;
  padding: 12px 14px;
}

.settings-form-stack {
  display: grid;
  gap: 16px;
}

.settings-checkbox {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--text);
}

.settings-checkbox span:first-of-type {
  display: grid;
  gap: 4px;
}

.settings-checkbox strong {
  color: var(--text);
}

.settings-checkbox small {
  color: var(--muted-soft);
}

.settings-subscriptions {
  display: grid;
  gap: 10px;
  padding-top: 6px;
}

.settings-subscriptions p {
  margin: 0;
  color: var(--muted-soft);
  font-size: 0.92rem;
}

.settings-subscription-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(243, 252, 239, 0.72);
  border: 1px solid rgba(187, 203, 185, 0.35);
}

.settings-subscription-row span {
  display: grid;
  gap: 4px;
}

.settings-subscription-row strong {
  color: var(--text);
}

.settings-subscription-row small {
  color: var(--muted-soft);
}

.settings-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.settings-toggle input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  margin: 0;
}

.settings-toggle-ui {
  position: relative;
  width: 48px;
  height: 28px;
  border-radius: 999px;
  background: rgba(187, 203, 185, 0.9);
  border: 1px solid rgba(108, 123, 107, 0.35);
  transition: background-color 160ms ease, border-color 160ms ease;
}

.settings-toggle-ui::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: white;
  box-shadow: 0 2px 6px rgba(21, 30, 22, 0.18);
  transition: transform 160ms ease;
}

.settings-toggle input:checked + .settings-toggle-ui {
  background: var(--accent);
  border-color: var(--accent);
}

.settings-toggle input:checked + .settings-toggle-ui::after {
  transform: translateX(20px);
}

.retry-form {
  display: grid;
  gap: 10px;
}

.phone-preview {
  display: grid;
  place-items: center;
}

.phone-screen {
  width: 260px;
  min-height: 460px;
  border-radius: 36px;
  background: linear-gradient(180deg, rgba(243, 252, 239, 1), rgba(231, 241, 228, 1));
  padding: 22px;
  display: grid;
  align-content: start;
}

.phone-bubble {
  padding: 14px 16px;
  border-radius: 18px 18px 18px 6px;
  background: white;
  line-height: 1.6;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
}

.creative-preview {
  display: grid;
  gap: 14px;
}

.creative-image {
  height: 180px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(37, 211, 102, 0.24), rgba(255, 160, 126, 0.34));
}

.template-grid,
.permission-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.roles-create-button,
.role-action-button,
.roles-help-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 16px;
  padding: 12px 18px;
  font-weight: 700;
}

.roles-create-button {
  background: var(--accent);
  color: white;
  box-shadow: 0 14px 24px rgba(0, 109, 47, 0.18);
}

.roles-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.roles-create-panel {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(187, 203, 185, 0.65);
  border-radius: 24px;
  padding: 28px;
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 22px;
}

.roles-create-panel-head h3 {
  margin: 6px 0 0;
  font-size: 1.3rem;
}

.roles-create-copy {
  margin: 10px 0 0;
  max-width: 760px;
  color: var(--muted-soft);
  line-height: 1.65;
}

.roles-create-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.roles-create-field {
  display: grid;
  align-content: start;
  gap: 10px;
  color: var(--muted);
  font-weight: 600;
}

.roles-create-field span {
  color: var(--muted);
  font-size: 0.98rem;
  font-weight: 700;
}

.roles-create-field input,
.roles-create-field textarea {
  width: 100%;
  border: 1px solid rgba(108, 123, 107, 0.45);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.98);
  color: var(--text);
  padding: 16px 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: border-color 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

.roles-create-field input {
  min-height: 60px;
  font-size: 1.02rem;
  font-weight: 600;
}

.roles-create-form textarea {
  resize: vertical;
  min-height: 132px;
  line-height: 1.6;
}

.roles-create-field input:focus,
.roles-create-field textarea:focus {
  outline: none;
  border-color: rgba(0, 109, 47, 0.72);
  box-shadow: 0 0 0 4px rgba(37, 211, 102, 0.14);
  background: #fff;
}

.roles-create-field small {
  color: var(--muted-soft);
  font-size: 0.82rem;
  line-height: 1.55;
  font-weight: 500;
}

.roles-create-actions {
  padding-top: 2px;
}

.role-card {
  text-align: left;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(187, 203, 185, 0.65);
  border-radius: 24px;
  padding: 22px;
  box-shadow: var(--shadow-soft);
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
  cursor: pointer;
}

.role-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 36px rgba(21, 30, 22, 0.08);
}

.role-card.is-selected {
  border-color: rgba(0, 109, 47, 0.6);
  box-shadow: 0 0 0 2px rgba(37, 211, 102, 0.22), 0 18px 40px rgba(21, 30, 22, 0.1);
}

.role-card-head,
.permission-matrix-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.role-icon {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  display: grid;
  place-items: center;
}

.role-icon .material-symbols-outlined {
  font-size: 26px;
}

.role-icon.tone-primary {
  background: rgba(37, 211, 102, 0.16);
  color: var(--accent);
}

.role-icon.tone-secondary {
  background: rgba(140, 241, 225, 0.22);
  color: #006b5f;
}

.role-icon.tone-tertiary {
  background: rgba(255, 160, 126, 0.18);
  color: #93492e;
}

.role-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.role-badge.tone-primary {
  background: var(--accent);
  color: white;
}

.role-badge.tone-secondary {
  background: rgba(220, 229, 216, 0.9);
  color: var(--muted);
}

.role-badge.tone-tertiary {
  background: rgba(37, 211, 102, 0.18);
  color: var(--accent-dark);
}

.role-badge.tone-editing {
  background: rgba(37, 211, 102, 0.16);
  color: var(--accent-dark);
}

.role-card h2,
.roles-help-copy h3,
.roles-section-title {
  margin: 18px 0 8px;
  color: var(--text);
  font-size: 1.42rem;
  line-height: 1.1;
}

.role-card p,
.roles-audit-copy p,
.roles-help-copy p {
  margin: 0;
  color: var(--muted-soft);
  line-height: 1.65;
}

.role-card-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
}

.role-card-actions {
  margin-top: 18px;
  display: flex;
  justify-content: flex-end;
}

.role-inline-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(187, 203, 185, 0.65);
  background: rgba(243, 252, 239, 0.92);
  color: var(--accent-dark);
  font-weight: 700;
}

.role-inline-button.is-active {
  background: rgba(37, 211, 102, 0.16);
  border-color: rgba(0, 109, 47, 0.3);
}

.permission-matrix-card {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(187, 203, 185, 0.65);
  border-radius: 24px;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.permission-matrix-head {
  padding: 22px 24px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.45);
}

.permission-matrix-head h3 {
  margin: 6px 0 0;
  font-size: 1.35rem;
}

.permission-matrix-head h3 span {
  color: var(--accent);
}

.permission-matrix-copy {
  margin: 10px 0 0;
  color: var(--muted-soft);
  max-width: 720px;
  line-height: 1.65;
}

.roles-feedback {
  margin: 0;
  padding: 0 24px 18px;
  color: var(--accent-dark);
  font-weight: 600;
}

.permission-table-wrap {
  overflow-x: auto;
}

.permission-table {
  width: 100%;
  border-collapse: collapse;
}

.permission-table th,
.permission-table td {
  padding: 18px 24px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.35);
}

.permission-table th {
  background: rgba(237, 246, 233, 0.92);
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
}

.permission-table th:first-child,
.permission-table td:first-child {
  text-align: left;
}

.permission-table tbody tr:last-child td {
  border-bottom: 0;
}

.permission-label {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.permission-label .material-symbols-outlined {
  color: var(--muted);
  font-size: 22px;
  margin-top: 1px;
}

.permission-label div {
  display: grid;
  gap: 4px;
}

.permission-label strong {
  color: var(--text);
  font-size: 0.98rem;
}

.permission-label small {
  color: var(--muted-soft);
  font-size: 0.84rem;
}

.permission-table td:not(:first-child) {
  text-align: center;
}

.permission-unavailable {
  color: var(--muted-soft);
  font-weight: 700;
}

.permission-indicator {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 64px;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.permission-indicator.is-on {
  background: rgba(37, 211, 102, 0.18);
  color: var(--accent-dark);
}

.permission-indicator.is-off {
  background: rgba(220, 229, 216, 0.95);
  color: var(--muted);
}

.toggle-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.toggle-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.toggle-track {
  width: 46px;
  height: 26px;
  border-radius: 999px;
  background: rgba(220, 229, 216, 1);
  padding: 4px;
  display: inline-flex;
  align-items: center;
  transition: background 150ms ease;
}

.toggle-thumb {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: white;
  box-shadow: 0 2px 6px rgba(21, 30, 22, 0.16);
  transition: transform 150ms ease;
}

.toggle-switch input:checked + .toggle-track {
  background: rgba(37, 211, 102, 1);
}

.toggle-switch input:checked + .toggle-track .toggle-thumb {
  transform: translateX(20px);
}

.roles-bottom-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.8fr);
  gap: 18px;
}

.roles-inline-link {
  color: var(--accent);
  font-weight: 700;
}

.roles-audit-list {
  display: grid;
}

.roles-audit-item {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid rgba(187, 203, 185, 0.35);
}

.roles-audit-item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.roles-audit-icon {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  background: rgba(231, 241, 228, 0.92);
  display: grid;
  place-items: center;
  color: var(--accent);
}

.roles-audit-copy {
  display: grid;
  gap: 4px;
}

.roles-audit-copy strong {
  color: var(--text);
}

.roles-audit-time {
  color: var(--muted-soft);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.roles-help-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  padding: 24px;
  background: linear-gradient(180deg, rgba(0, 109, 47, 0.96), rgba(0, 83, 34, 0.98));
  color: white;
  box-shadow: 0 18px 42px rgba(0, 109, 47, 0.2);
}

.roles-help-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 12px;
}

.roles-help-copy .card-kicker,
.roles-help-copy p {
  color: rgba(255, 255, 255, 0.86);
}

.roles-help-copy h3 {
  color: white;
}

.roles-help-button {
  justify-self: start;
  background: white;
  color: var(--accent);
}

.roles-help-mark {
  position: absolute;
  right: -10px;
  bottom: -6px;
  font-size: 128px;
  opacity: 0.12;
}

.audit-export-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 14px;
  border: 1px solid rgba(187, 203, 185, 0.65);
  background: rgba(255, 255, 255, 0.94);
  color: var(--text);
  font-weight: 700;
}

.audit-export-button.secondary {
  background: rgba(243, 252, 239, 0.92);
}

.audit-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.audit-kpi-card,
.audit-table-card,
.audit-detail-card,
.audit-filter-bar {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(187, 203, 185, 0.65);
  border-radius: 24px;
  box-shadow: var(--shadow-soft);
}

.audit-kpi-card {
  padding: 22px;
  display: grid;
  gap: 14px;
}

.audit-kpi-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.audit-kpi-head .material-symbols-outlined,
.audit-danger,
.audit-secondary {
  color: var(--accent);
}

.audit-danger {
  color: #b42318;
}

.audit-secondary {
  color: #006b5f;
}

.audit-kpi-metric {
  display: flex;
  align-items: flex-end;
  gap: 10px;
}

.audit-kpi-metric strong {
  font-size: 2rem;
  line-height: 1;
}

.audit-kpi-trend {
  margin-bottom: 4px;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.audit-kpi-trend.is-positive {
  color: var(--accent-dark);
}

.audit-kpi-trend.is-danger {
  color: #b42318;
}

.audit-kpi-bar {
  height: 8px;
  border-radius: 999px;
  background: rgba(231, 241, 228, 1);
  overflow: hidden;
}

.audit-kpi-bar div {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(37, 211, 102, 1), rgba(0, 109, 47, 1));
}

.audit-kpi-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

.audit-avatar {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: rgba(231, 241, 228, 1);
  color: var(--accent-dark);
  display: grid;
  place-items: center;
  font-weight: 800;
}

.audit-avatar.small {
  width: 32px;
  height: 32px;
  font-size: 0.85rem;
}

.audit-avatar.small.is-alert {
  background: rgba(255, 218, 214, 1);
  color: #b42318;
}

.audit-kpi-user strong,
.audit-detail-card h3 {
  color: var(--text);
}

.audit-kpi-user span {
  display: block;
  color: var(--muted-soft);
  margin-top: 3px;
}

.audit-filter-bar {
  padding: 18px 20px;
  display: grid;
  grid-template-columns: auto repeat(4, minmax(0, 180px)) minmax(220px, 1fr) auto;
  gap: 16px;
  align-items: end;
}

.audit-filter-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.audit-filter-field,
.audit-filter-search {
  display: grid;
  gap: 6px;
}

.audit-filter-field span,
.audit-filter-search span {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.audit-filter-field select,
.audit-filter-search input {
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(187, 203, 185, 0.6);
  background: rgba(243, 252, 239, 0.9);
  padding: 12px 14px;
  color: var(--text);
}

.audit-reset-button {
  justify-self: end;
  padding: 12px 14px;
  border-radius: 14px;
  background: transparent;
  color: var(--accent);
  font-weight: 800;
}

.audit-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(320px, 0.9fr);
  gap: 18px;
}

.audit-table-card {
  overflow: hidden;
  position: relative;
}

.audit-loading-bar {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, rgba(37, 211, 102, 0), rgba(37, 211, 102, 1), rgba(0, 109, 47, 0));
  animation: auditPulse 1.1s linear infinite;
}

.audit-table {
  width: 100%;
  border-collapse: collapse;
}

.audit-table th,
.audit-table td {
  padding: 18px 20px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.35);
  text-align: left;
}

.audit-table th {
  background: rgba(237, 246, 233, 0.92);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.audit-table tbody tr {
  transition: background 150ms ease;
}

.audit-table tbody tr:hover,
.audit-table tbody tr.is-selected {
  background: rgba(243, 252, 239, 0.86);
}

.audit-table tbody tr.is-alert {
  background: rgba(255, 218, 214, 0.28);
}

.audit-table tbody tr.is-alert:hover,
.audit-table tbody tr.is-alert.is-selected {
  background: rgba(255, 218, 214, 0.38);
}

.audit-stamp {
  display: grid;
  gap: 3px;
}

.audit-stamp strong {
  color: var(--text);
}

.audit-stamp span {
  color: var(--muted-soft);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
}

.audit-user-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.audit-action-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
}

.audit-action-pill.tone-default {
  background: rgba(0, 109, 47, 0.1);
  color: var(--accent-dark);
}

.audit-action-pill.tone-alert {
  background: rgba(186, 35, 24, 0.12);
  color: #b42318;
}

.audit-mono {
  font-family: "JetBrains Mono", monospace;
  color: var(--muted);
  font-size: 0.84rem;
}

.audit-actions-cell {
  text-align: right;
}

.audit-actions-cell button {
  background: transparent;
  color: var(--accent);
  font-weight: 700;
}

.audit-pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: rgba(237, 246, 233, 0.92);
  color: var(--muted);
}

.audit-pagination-meta {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.audit-page-size {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 700;
}

.audit-page-size select {
  min-width: 74px;
  min-height: 38px;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid rgba(187, 203, 185, 0.72);
  background: white;
  color: var(--text);
  font-weight: 700;
}

.audit-pagination-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
}

.audit-pagination-buttons button {
  min-width: 36px;
  min-height: 36px;
  padding: 8px 10px;
  border-radius: 12px;
  background: transparent;
  border: 1px solid rgba(187, 203, 185, 0.65);
  color: var(--text);
}

.audit-pagination-buttons button.is-active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.audit-detail-card {
  padding: 24px;
  display: grid;
  align-content: start;
  gap: 20px;
}

@keyframes auditPulse {
  0% {
    transform: translateX(-35%);
  }

  100% {
    transform: translateX(35%);
  }
}

.code-card pre {
  margin: 0;
  white-space: pre-wrap;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.9rem;
  line-height: 1.65;
}

@media (max-width: 960px) {
  .page-shell {
    flex-direction: column;
  }

  .sidebar {
    width: auto;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .content {
    padding: 20px;
  }

  .hero-card,
  .auth-card {
    padding: 24px;
  }

  .dashboard-app {
    grid-template-columns: 1fr;
  }

  .dashboard-sidebar {
    position: static;
    height: auto;
  }

  .dashboard-topbar,
  .dashboard-content {
    padding: 20px;
  }

  .dashboard-stat-grid,
  .dashboard-two-column,
  .dashboard-two-column-bottom,
  .conversation-layout,
  .overview-grid,
  .template-grid,
  .permission-grid,
  .analytics-bento,
  .analytics-metrics-grid,
  .templates-grid,
  .template-builder-grid {
    grid-template-columns: 1fr;
  }

  .roles-card-grid,
  .roles-bottom-grid,
  .roles-create-form,
  .audit-kpi-grid,
  .audit-layout {
    grid-template-columns: 1fr;
  }

  .permission-matrix-head,
  .roles-audit-item {
    grid-template-columns: 1fr;
  }

  .permission-matrix-head {
    align-items: flex-start;
  }

  .audit-filter-bar {
    grid-template-columns: 1fr;
  }

  .audit-pagination {
    flex-direction: column;
    align-items: flex-start;
  }

  .analytics-live-tail {
    align-items: flex-start;
    flex-direction: column;
  }

  .templates-row-card {
    grid-template-columns: 56px minmax(0, 1fr);
  }

  .templates-row-date,
  .templates-row-status,
  .templates-row-actions {
    grid-column: 2;
    justify-content: flex-start;
    text-align: left;
    padding-left: 0;
    border-left: 0;
  }

  .templates-guidelines {
    flex-direction: column;
    align-items: flex-start;
  }

  .templates-guidelines-button {
    margin-left: 0;
  }

  .template-builder-preview-column {
    position: static;
  }

  .conversations-layout {
    grid-template-columns: 300px minmax(0, 1fr);
  }

  .conversations-profile {
    display: none;
  }

  .security-session-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .auth-container,
  .two-factor-shell {
    gap: 24px;
  }

  .auth-card-enterprise,
  .two-factor-card {
    padding: 24px;
  }

  .auth-secondary-grid {
    grid-template-columns: 1fr;
  }

  .auth-assist-row,
  .two-factor-meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .security-session-head {
    flex-direction: column;
  }

  .dashboard-topbar,
  .page-header,
  .page-header.split,
  .chat-composer,
  .dashboard-topbar-left {
    flex-direction: column;
    align-items: flex-start;
  }

  .contacts-grid,
  .campaign-grid,
  .message-grid,
  .webhook-grid,
  .users-grid,
  .logs-grid,
  .auth-secondary-grid {
    grid-template-columns: 1fr;
  }

  .analytics-hero,
  .analytics-panel-head,
  .analytics-table-head,
  .analytics-table-foot,
  .templates-hero,
  .template-builder-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .dashboard-searchbar {
    min-width: 100%;
  }

  .templates-filter-meta {
    margin-left: 0;
  }

  .template-builder-actions,
  .template-builder-inline-meta {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .template-builder-basic-grid {
    grid-template-columns: 1fr;
  }

  .template-builder-phone-frame {
    width: min(100%, 340px);
  }

  .conversations-page {
    height: auto;
    min-height: 0;
  }

  .conversations-layout {
    grid-template-columns: 1fr;
    height: auto;
  }

  .conversations-sidebar,
  .conversations-thread,
  .conversations-profile {
    min-height: 0;
  }

  .conversations-sidebar {
    max-height: 420px;
  }

  .conversations-thread-body {
    min-height: 420px;
  }

  .conversations-thread-head,
  .conversations-profile-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .conversation-message-wrap {
    max-width: 88%;
  }

  .otp-row {
    gap: 8px;
  }

  .otp-box {
    height: 48px;
    font-size: 1.05rem;
  }
}

/* Dashboard Fidelity Overrides */
.material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  font-size: 24px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 24;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.dashboard-app {
  display: block;
}

.dashboard-sidebar {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 50;
  width: 260px;
  height: 100vh;
  padding: 24px 16px;
  background: #fff;
  border-right: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(21, 30, 22, 0.06);
  gap: 8px;
  overflow: hidden;
}

.dashboard-brand {
  margin-bottom: 20px;
  padding: 0 16px;
}

.dashboard-brand h1 {
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 24px;
  line-height: 32px;
  font-weight: 800;
}

.dashboard-brand p {
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 20px;
  color: var(--muted);
}

.dashboard-primary-action {
  margin: 0 8px 24px;
  padding: 12px 16px;
  border-radius: 8px;
  gap: 8px;
  background: var(--accent);
  box-shadow: none;
}

.dashboard-sidebar-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 0 8px 12px;
  scrollbar-width: thin;
  scrollbar-color: rgba(108, 123, 107, 0.45) transparent;
}

.dashboard-sidebar-scroll::-webkit-scrollbar {
  width: 8px;
}

.dashboard-sidebar-scroll::-webkit-scrollbar-thumb {
  background: rgba(108, 123, 107, 0.35);
  border-radius: 999px;
}

.dashboard-nav-link,
.dashboard-logout-button {
  display: flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 8px;
  gap: 12px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: background-color 150ms ease, transform 150ms ease;
}

.dashboard-nav-link.is-active {
  background: var(--accent-bright);
  color: var(--accent-dark);
}

.dashboard-nav-secondary {
  display: grid;
  gap: 2px;
  margin-top: 10px;
}

.dashboard-subnav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-radius: 8px;
  color: var(--muted);
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 600;
}

.dashboard-nav-link .material-symbols-outlined,
.dashboard-subnav-link .material-symbols-outlined,
.dashboard-logout-button .material-symbols-outlined,
.dashboard-primary-action .material-symbols-outlined {
  flex: 0 0 28px;
  width: 28px;
  min-width: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 22px;
  line-height: 1;
}

.dashboard-subnav-link:hover,
.dashboard-subnav-link.is-active {
  background: #edf6e9;
  color: var(--accent);
}

.dashboard-sidebar-footer {
  border-top-color: rgba(187, 203, 185, 1);
  margin-top: 18px;
  padding-top: 16px;
}

.dashboard-settings-accordion {
  display: grid;
  gap: 6px;
}

.dashboard-settings-accordion summary {
  list-style: none;
}

.dashboard-settings-accordion summary::-webkit-details-marker {
  display: none;
}

.dashboard-nav-link-main {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.dashboard-settings-caret {
  margin-left: auto;
  transition: transform 150ms ease;
}

.dashboard-settings-accordion[open] .dashboard-settings-caret {
  transform: rotate(180deg);
}

.dashboard-settings-subnav {
  display: grid;
  gap: 4px;
  margin: 8px 0 12px;
  padding-left: 14px;
  border-left: 1px solid rgba(187, 203, 185, 0.9);
}

.dashboard-settings-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 10px;
  color: var(--muted);
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 11px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
}

.dashboard-settings-link .material-symbols-outlined {
  flex: 0 0 20px;
  width: 20px;
  min-width: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
}

.dashboard-settings-link:hover,
.dashboard-settings-link.is-active {
  background: #edf6e9;
  color: var(--accent);
}

.dashboard-main {
  margin-left: 260px;
}

.dashboard-topbar {
  justify-content: space-between;
  height: 64px;
  padding: 0 32px;
  background: #f3fcef;
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(21, 30, 22, 0.05);
}

.dashboard-topbar-left {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  flex-wrap: nowrap;
  gap: 16px;
}

.dashboard-topbar-left h2 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 24px;
  font-weight: 700;
  color: var(--accent);
}

.dashboard-topbar-divider {
  width: 1px;
  height: 24px;
  flex-shrink: 0;
  background: rgba(187, 203, 185, 0.95);
}

.dashboard-searchbar {
  flex: 1 1 280px;
  min-width: 0;
  max-width: 420px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #e7f1e4;
}

.dashboard-searchbar .material-symbols-outlined {
  color: var(--muted);
  font-size: 20px;
}

.dashboard-searchbar input {
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 20px;
  color: var(--text);
  outline: none;
}

.language-switcher-compact {
  display: inline-flex;
  flex-shrink: 0;
  gap: 0;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #e7f1e4;
}

.language-switcher-compact button {
  min-width: 44px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  box-shadow: none;
}

.dashboard-topbar-actions {
  gap: 24px;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.dashboard-icon-button {
  width: auto;
  height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
}

.dashboard-icon-button svg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  font-size: 28px;
  line-height: 1;
  color: var(--muted);
}

.dashboard-icon-button:hover svg {
  color: var(--accent-dark);
}

.dashboard-profile {
  gap: 12px;
  padding-left: 24px;
  border-left: 1px solid var(--border);
}

.dashboard-profile strong {
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 20px;
  font-weight: 700;
  color: var(--text);
}

.dashboard-profile span {
  font-size: 10px;
  line-height: 16px;
  letter-spacing: 0.05em;
}

.dashboard-avatar {
  border: 1px solid var(--accent);
  background: #fff;
  color: var(--accent);
}

.dashboard-content {
  padding: 32px;
}

.dashboard-overview-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr);
  gap: 24px;
}

.dashboard-overview-main,
.dashboard-overview-side {
  display: grid;
  gap: 24px;
  align-content: start;
}

.dashboard-stat-grid {
  gap: 24px;
}

.surface-card {
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--border);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
  padding: 20px;
}

.dashboard-kpi-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dashboard-kpi-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.dashboard-kpi-icon {
  display: inline-flex;
  padding: 6px;
  border-radius: 8px;
  color: var(--accent);
  background: rgba(37, 211, 102, 0.16);
}

.dashboard-kpi-metric {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.dashboard-kpi-metric h3 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 32px;
  line-height: 40px;
  font-weight: 700;
  color: var(--text);
}

.dashboard-kpi-delta {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 20px;
  font-weight: 700;
}

.dashboard-kpi-delta.success {
  color: #25d366;
}

.dashboard-kpi-delta.warning {
  color: #ef4444;
}

.analytics-page {
  display: grid;
  gap: 24px;
}

.analytics-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
}

.analytics-heading {
  margin: 0 0 10px;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: clamp(2rem, 4vw, 2.85rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.analytics-copy {
  margin: 0;
  max-width: 760px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 24px;
  color: var(--muted);
}

.analytics-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.analytics-ghost-button,
.analytics-pagination button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  color: var(--muted);
  box-shadow: none;
}

.analytics-ghost-button {
  padding: 10px 16px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.analytics-bento {
  display: grid;
  grid-template-columns: minmax(280px, 380px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.analytics-side-stack {
  display: grid;
  gap: 24px;
}

.analytics-panel {
  display: grid;
  gap: 24px;
}

.analytics-panel-head,
.analytics-table-head,
.analytics-metric-head,
.analytics-worker-meta,
.analytics-table-foot,
.analytics-live-tail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.analytics-panel-head h3,
.analytics-table-head h3,
.analytics-throughput-card h3,
.analytics-live-tail-copy h3 {
  margin: 0;
  font-size: 18px;
  line-height: 24px;
  font-weight: 700;
}

.analytics-live-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(37, 211, 102, 0.12);
  color: #15703c;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 11px;
  line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
}

.analytics-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #25d366;
  box-shadow: 0 0 0 6px rgba(37, 211, 102, 0.12);
  animation: analyticsPulse 1.8s ease-in-out infinite;
}

.analytics-queue-stack,
.analytics-worker-list {
  display: grid;
  gap: 14px;
}

.analytics-queue-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
  border-radius: 12px;
  background: #edf6e9;
  border-left: 4px solid transparent;
}

.analytics-queue-card p,
.analytics-queue-card strong,
.analytics-throughput-card p,
.analytics-live-tail-copy p {
  margin: 0;
}

.analytics-queue-card p,
.analytics-worker-health h4,
.analytics-table thead th,
.analytics-metric-head span:first-child {
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.analytics-queue-card strong {
  display: block;
  margin-top: 4px;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 32px;
  line-height: 40px;
  font-weight: 700;
  color: var(--text);
}

.analytics-queue-card.is-info {
  border-left-color: #3b82f6;
}

.analytics-queue-card.is-primary {
  border-left-color: var(--accent);
}

.analytics-queue-card.is-error {
  border-left-color: #ef4444;
}

.analytics-queue-icon {
  font-size: 32px;
  color: var(--muted);
}

.analytics-queue-card.is-info .analytics-queue-icon {
  color: #3b82f6;
}

.analytics-queue-card.is-primary .analytics-queue-icon {
  color: var(--accent);
}

.analytics-queue-card.is-error .analytics-queue-icon,
.analytics-queue-card.is-error strong {
  color: #ef4444;
}

.analytics-queue-icon.is-spinning {
  animation: analyticsSpin 2s linear infinite;
}

.analytics-worker-health {
  display: grid;
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid rgba(187, 203, 185, 0.9);
}

.analytics-worker-health h4 {
  margin: 0;
}

.analytics-worker-meta span,
.analytics-worker-meta strong,
.analytics-table-head span,
.analytics-table-foot span,
.analytics-live-tail-copy p,
.analytics-metric-value span {
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 20px;
}

.analytics-worker-meta strong.is-success,
.analytics-metric-value span.is-success {
  color: #15703c;
}

.analytics-worker-meta strong.is-warning,
.analytics-metric-value span.is-warning {
  color: #f59e0b;
}

.analytics-metric-value span.is-muted {
  color: var(--muted);
}

.analytics-progress-track {
  width: 100%;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #dce5d8;
}

.analytics-progress-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
}

.analytics-progress-fill.is-success {
  background: #25d366;
}

.analytics-progress-fill.is-warning {
  background: #f59e0b;
}

.analytics-throughput-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px;
  border-radius: 14px;
  border: 1px solid rgba(0, 109, 47, 0.18);
  background: linear-gradient(180deg, rgba(37, 211, 102, 0.12), rgba(255, 255, 255, 0.9));
}

.analytics-throughput-icon,
.analytics-live-tail-icon {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  color: var(--accent);
  box-shadow: 0 4px 14px rgba(21, 30, 22, 0.08);
}

.analytics-table-card {
  overflow: hidden;
  padding: 0;
}

.analytics-table-head,
.analytics-table-foot {
  padding: 20px 24px;
}

.analytics-table-head {
  border-bottom: 1px solid rgba(187, 203, 185, 0.9);
}

.analytics-table-head span {
  padding: 6px 10px;
  border-radius: 10px;
  background: #e7f1e4;
  color: var(--muted);
}

.analytics-table-scroll {
  overflow-x: auto;
}

.analytics-table {
  width: 100%;
  border-collapse: collapse;
}

.analytics-table thead {
  background: #edf6e9;
}

.analytics-table thead th {
  padding: 14px 24px;
  text-align: left;
}

.analytics-table tbody tr {
  transition: background-color 150ms ease;
}

.analytics-table tbody tr:hover {
  background: rgba(237, 246, 233, 0.72);
}

.analytics-table tbody td {
  padding: 18px 24px;
  border-top: 1px solid rgba(187, 203, 185, 0.75);
  vertical-align: middle;
}

.analytics-table-time {
  white-space: nowrap;
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  line-height: 20px;
  color: var(--muted);
}

.analytics-action-cell,
.analytics-live-tail-copy {
  display: grid;
  gap: 4px;
}

.analytics-action-cell strong,
.analytics-metric-value strong {
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-weight: 700;
  color: var(--text);
}

.analytics-action-cell span {
  font-size: 11px;
  line-height: 16px;
  color: var(--muted);
}

.analytics-actor-cell {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 20px;
}

.analytics-actor-badge {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #8cf1e1;
  color: #006f64;
  font-size: 11px;
  font-weight: 800;
}

.analytics-actor-icon {
  color: var(--muted);
  font-size: 20px;
}

.analytics-status-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 11px;
  line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
}

.analytics-status-pill.is-success {
  background: rgba(37, 211, 102, 0.12);
  color: #15703c;
}

.analytics-status-pill.is-warning {
  background: rgba(245, 158, 11, 0.12);
  color: #b45309;
}

.analytics-status-pill.is-error {
  background: rgba(239, 68, 68, 0.12);
  color: #b91c1c;
}

.analytics-payload-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 10px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

.analytics-payload-button:hover {
  background: #edf6e9;
  color: var(--accent);
}

.analytics-payload-button.is-error:hover {
  color: #b91c1c;
}

.analytics-payload-button.is-success:hover {
  color: #15703c;
}

.analytics-payload-button.is-primary:hover {
  color: var(--accent);
}

.analytics-table-foot {
  border-top: 1px solid rgba(187, 203, 185, 0.9);
}

.analytics-pagination {
  display: flex;
  gap: 8px;
}

.analytics-pagination button {
  width: 40px;
  height: 40px;
  justify-content: center;
  padding: 0;
}

.analytics-live-tail {
  padding: 20px 24px;
  border-radius: 14px;
  border: 1px solid rgba(187, 203, 185, 0.95);
  background: #edf6e9;
}

.analytics-live-tail-copy {
  flex: 1;
}

.analytics-console-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: 12px;
  background: var(--accent);
  color: white;
  box-shadow: 0 8px 18px rgba(0, 109, 47, 0.18);
}

.analytics-metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.analytics-metric-card {
  display: grid;
  gap: 16px;
}

.analytics-metric-head .material-symbols-outlined {
  color: var(--accent);
}

.analytics-metric-value {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.analytics-metric-value strong {
  font-size: 32px;
  line-height: 40px;
}

.analytics-mini-bars {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 56px;
}

.analytics-mini-bars span {
  flex: 1;
  border-radius: 6px 6px 0 0;
  background: #dce5d8;
}

.analytics-mini-bars span.is-primary {
  background: var(--accent);
}

.analytics-mini-bars.is-memory span {
  background: rgba(0, 109, 47, 0.16);
}

.analytics-mini-bars.is-memory span:last-child {
  background: var(--accent);
}

.analytics-metric-progress {
  height: 16px;
}

.templates-page,
.template-builder-page {
  display: grid;
  gap: 28px;
}

.templates-hero,
.template-builder-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
}

.templates-heading,
.template-builder-heading {
  margin: 0 0 10px;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: clamp(2rem, 4vw, 2.7rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--text);
}

.templates-copy,
.template-builder-copy {
  margin: 0;
  max-width: 760px;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 24px;
  color: var(--muted);
}

.templates-create-button,
.template-builder-submit-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 20px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 28px rgba(0, 109, 47, 0.16);
  font-weight: 700;
}

.templates-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.templates-filter-pill,
.templates-guidelines-button,
.template-builder-draft-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(187, 203, 185, 0.95);
  background: #fff;
  color: var(--muted);
  box-shadow: none;
}

.templates-filter-pill-select {
  gap: 10px;
  padding-right: 12px;
}

.templates-filter-pill-select span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.templates-filter-pill-select select {
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  outline: none;
}

.templates-filter-apply {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 999px;
  border: 0;
  background: rgba(0, 109, 47, 0.08);
  color: var(--accent);
  font-weight: 700;
}

.templates-filter-pill .material-symbols-outlined {
  font-size: 18px;
}

.templates-filter-meta {
  margin-left: auto;
  color: var(--muted);
  font-size: 14px;
}

.templates-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.templates-card,
.templates-row-card,
.template-builder-card {
  padding: 24px;
}

.templates-card {
  border: 1px solid transparent;
  transition: border-color 150ms ease, transform 150ms ease;
}

.templates-card:hover,
.templates-row-card:hover {
  border-color: rgba(0, 109, 47, 0.28);
  transform: translateY(-1px);
}

.templates-card-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.templates-status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
}

.templates-status-pill.is-approved {
  background: rgba(37, 211, 102, 0.18);
  color: #005523;
}

.templates-status-pill.is-pending {
  background: #ffdbcf;
  color: #763319;
}

.templates-status-pill.is-rejected {
  background: #ffdad6;
  color: #93000a;
}

.templates-overflow-button,
.templates-edit-button,
.templates-row-actions button,
.template-builder-toolbar button,
.template-builder-delete-button {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

.templates-overflow-button {
  opacity: 0;
  transition: opacity 150ms ease;
}

.templates-card:hover .templates-overflow-button {
  opacity: 1;
}

.templates-card h2,
.templates-row-main h2,
.template-builder-card h2,
.templates-guidelines-copy h3 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 24px;
  color: var(--text);
}

.templates-category {
  margin: 4px 0 18px;
  color: #006b5f;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
}

.templates-preview-box {
  position: relative;
  min-height: 128px;
  padding: 16px;
  border-radius: 14px;
  background: #f3fcef;
  overflow: hidden;
}

.templates-preview-box p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
  font-style: italic;
}

.templates-preview-fade {
  position: absolute;
  inset: auto 0 0;
  height: 48px;
  background: linear-gradient(180deg, rgba(243, 252, 239, 0), #f3fcef 90%);
}

.templates-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(220, 229, 216, 0.95);
}

.templates-update-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

.templates-update-meta.is-alert {
  color: #b91c1c;
}

.templates-edit-button {
  color: var(--accent);
}

.templates-row-card {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 160px 160px auto;
  align-items: center;
  gap: 20px;
}

.templates-row-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #e7f1e4;
  color: var(--accent);
  display: grid;
  place-items: center;
}

.templates-row-icon .material-symbols-outlined {
  font-size: 28px;
}

.templates-row-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

.templates-row-meta span {
  color: #006b5f;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.templates-row-meta i {
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: rgba(108, 123, 107, 0.6);
}

.templates-row-meta p,
.template-builder-button-row p,
.template-builder-phone-contact span {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.templates-row-date {
  text-align: center;
}

.templates-row-date span {
  display: block;
  color: var(--muted);
  font-size: 14px;
}

.templates-row-date strong,
.template-builder-button-row strong {
  font-size: 16px;
  line-height: 24px;
}

.templates-row-status {
  display: flex;
  justify-content: center;
  padding: 0 16px;
  border-left: 1px solid rgba(220, 229, 216, 0.95);
}

.templates-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.templates-row-actions button:hover,
.templates-overflow-button:hover,
.templates-edit-button:hover,
.template-builder-toolbar button:hover,
.template-builder-delete-button:hover {
  background: #edf6e9;
}

.templates-row-actions button.is-primary {
  color: var(--accent);
}

.templates-guidelines {
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 30px;
  border-radius: 24px;
  background: #e7f1e4;
  border: 1px dashed rgba(108, 123, 107, 0.5);
}

.templates-guidelines-icon {
  width: 96px;
  height: 96px;
  border-radius: 999px;
  background: #dce5d8;
  color: var(--accent);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.templates-guidelines-icon .material-symbols-outlined {
  font-size: 46px;
}

.templates-guidelines-copy p {
  margin: 8px 0 0;
  max-width: 640px;
  color: var(--muted);
  line-height: 1.7;
}

.templates-guidelines-button {
  margin-left: auto;
  border-radius: 12px;
  padding: 12px 18px;
  font-weight: 700;
}

.template-builder-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.template-builder-draft-button {
  border-radius: 12px;
  padding: 12px 18px;
  color: #6c7b6b;
  font-weight: 700;
}

.template-builder-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(340px, 0.95fr);
  gap: 32px;
  align-items: start;
}

.template-builder-form-column {
  display: grid;
  gap: 24px;
}

.template-builder-card {
  display: grid;
  gap: 22px;
}

.template-builder-card-head,
.template-builder-card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.template-builder-card-head {
  justify-content: flex-start;
}

.template-builder-card-head .material-symbols-outlined {
  color: var(--accent);
}

.template-builder-basic-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.template-builder-field {
  display: grid;
  gap: 10px;
}

.template-builder-field-full {
  grid-column: 1 / -1;
}

.template-builder-field span,
.template-builder-inline-meta span,
.template-builder-button-row strong {
  color: #64748b;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
}

.template-builder-field input,
.template-builder-field select,
.template-builder-field textarea {
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid rgba(226, 232, 240, 1);
  background: #f3fcef;
  color: var(--text);
  outline: none;
}

.template-builder-field textarea {
  resize: vertical;
  min-height: 210px;
  line-height: 1.7;
}

.template-builder-field input:focus,
.template-builder-field select:focus,
.template-builder-field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 211, 102, 0.12);
}

.template-builder-toolbar {
  display: flex;
  gap: 8px;
}

.template-builder-toolbar button {
  background: #e7f1e4;
}

.template-builder-content-stack,
.template-builder-button-stack {
  display: grid;
  gap: 18px;
}

.template-builder-inline-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.template-builder-inline-meta span {
  text-transform: none;
  letter-spacing: 0;
}

.template-builder-inline-meta button {
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--accent);
  font-weight: 700;
}

.template-builder-button-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
  border-radius: 14px;
  border: 1px dashed rgba(108, 123, 107, 0.34);
  background: #f3fcef;
}

.template-builder-button-row .material-symbols-outlined {
  color: #6c7b6b;
}

.template-builder-button-row div {
  flex: 1;
}

.template-builder-button-row input {
  width: 100%;
  margin-top: 8px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(226, 232, 240, 1);
  background: #fff;
  color: var(--text);
}

.template-builder-button-row input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 211, 102, 0.12);
  outline: none;
}

.template-builder-delete-button {
  color: #ba1a1a;
}

.template-builder-add-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 18px;
  border-radius: 14px;
  border: 2px dashed rgba(0, 109, 47, 0.26);
  background: rgba(0, 109, 47, 0.03);
  color: var(--accent);
  font-weight: 700;
}

.template-builder-preview-column {
  position: sticky;
  top: 92px;
}

.template-builder-preview-shell {
  display: grid;
  justify-items: center;
  gap: 26px;
}

.template-builder-phone-frame {
  width: 340px;
  height: 680px;
  padding: 10px;
  border-radius: 48px;
  background: #0f172a;
  box-shadow: 0 26px 70px rgba(15, 23, 42, 0.28);
}

.template-builder-phone-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 22px 10px;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.template-builder-phone-status div {
  display: flex;
  gap: 4px;
}

.template-builder-phone-status .material-symbols-outlined {
  font-size: 15px;
}

.template-builder-phone-screen {
  height: calc(100% - 28px);
  overflow: hidden;
  border-radius: 38px;
  background: linear-gradient(180deg, rgba(229, 221, 213, 0.95), rgba(236, 229, 221, 0.96));
  position: relative;
}

.template-builder-phone-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.28), transparent 24%),
    radial-gradient(circle at 80% 0%, rgba(255, 255, 255, 0.16), transparent 22%);
  pointer-events: none;
}

.template-builder-phone-header {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 10px;
  min-height: 64px;
  padding: 0 16px;
  background: #075e54;
  color: #fff;
}

.template-builder-phone-avatar {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  display: grid;
  place-items: center;
  font-weight: 800;
}

.template-builder-phone-contact strong,
.template-builder-chat-bubble strong {
  display: block;
}

.template-builder-chat-area {
  position: relative;
  z-index: 1;
  height: calc(100% - 64px);
  padding: 18px 14px 88px;
}

.template-builder-chat-date {
  width: fit-content;
  margin: 0 auto 18px;
  padding: 6px 12px;
  border-radius: 8px;
  background: #d1e5f0;
  color: #556b77;
  font-size: 11px;
  font-weight: 700;
}

.template-builder-chat-stack {
  max-width: 86%;
}

.template-builder-chat-bubble {
  padding: 14px;
  border-radius: 0 18px 18px 18px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.template-builder-chat-bubble p {
  margin: 0;
  color: #1f2937;
  font-size: 14px;
  line-height: 1.5;
}

.template-builder-chat-bubble strong {
  display: inline;
  color: var(--accent);
}

.template-builder-chat-bubble span {
  color: #2563eb;
  text-decoration: underline;
}

.template-builder-chat-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin-top: 10px;
  color: #6b7280;
}

.template-builder-chat-meta .material-symbols-outlined {
  font-size: 14px;
  color: #3b82f6;
}

.template-builder-chat-reply {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 2px;
  padding: 12px 14px;
  border-radius: 0 0 18px 18px;
  border: 0;
  background: #fff;
  color: #2563eb;
  font-weight: 700;
}

.template-builder-input-row {
  position: absolute;
  right: 12px;
  bottom: 14px;
  left: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.template-builder-input-shell {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.08);
  color: #9ca3af;
}

.template-builder-input-placeholder {
  flex: 1;
  font-size: 14px;
}

.template-builder-mic-button {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: #075e54;
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.14);
}

.template-builder-preview-toggle {
  display: inline-flex;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  border: 1px solid rgba(226, 232, 240, 1);
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
}

.template-builder-preview-toggle button {
  min-width: 108px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 0;
  background: transparent;
  color: #64748b;
  font-weight: 700;
}

.template-builder-preview-toggle button.is-active {
  background: var(--accent);
  color: #fff;
}

.conversations-page {
  --conversation-header-height: 86px;
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.conversations-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr) 288px;
  gap: 0;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(187, 203, 185, 0.95);
  background: #fff;
  box-shadow: 0 18px 46px rgba(15, 23, 42, 0.08);
}

.conversations-sidebar,
.conversations-thread,
.conversations-profile {
  height: 100%;
  min-height: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  background: #fff;
}

.conversations-sidebar {
  display: grid;
  grid-template-rows: var(--conversation-header-height) minmax(0, 1fr);
  border-right: 1px solid rgba(187, 203, 185, 0.95);
}

.conversations-profile {
  border-left: 1px solid rgba(187, 203, 185, 0.95);
}

.conversations-filter-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: center;
  gap: 8px;
  min-height: var(--conversation-header-height);
  padding: 16px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.95);
}

.conversations-filter-tabs button {
  min-height: 34px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.conversations-filter-tabs button.is-active {
  background: rgba(37, 211, 102, 0.18);
  color: #005523;
}

.conversations-list,
.conversations-thread-body,
.conversations-profile-scroll {
  min-height: 0;
  overflow-y: auto;
}

.conversations-list {
  height: auto;
}

.conversation-list-item {
  position: relative;
  display: flex;
  gap: 14px;
  padding: 18px 18px 18px 20px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.75);
  cursor: pointer;
  transition: background-color 150ms ease;
}

.conversation-list-item:hover {
  background: #edf6e9;
}

.conversation-list-item.is-active {
  background: #edf6e9;
}

.conversation-active-rail {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--accent);
}

.conversation-avatar {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(37, 211, 102, 0.25), rgba(0, 109, 47, 0.18));
  color: var(--accent);
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 15px;
  font-weight: 800;
}

.conversation-avatar.is-large {
  width: 40px;
  height: 40px;
  font-size: 13px;
}

.conversation-avatar.is-profile {
  width: 96px;
  height: 96px;
  font-size: 28px;
  box-shadow: 0 0 0 8px rgba(37, 211, 102, 0.08);
}

.conversation-list-main {
  min-width: 0;
  flex: 1;
}

.conversation-list-topline {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 4px;
}

.conversation-list-topline h3,
.conversations-thread-contact h2,
.conversations-profile-top h3 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 22px;
}

.conversation-list-topline span,
.conversation-meta span,
.conversations-online-row span,
.conversations-profile-top p,
.conversations-detail-list p,
.conversations-activity-item p {
  font-size: 12px;
  line-height: 16px;
  color: var(--muted);
}

.conversation-list-topline span.is-recent {
  color: var(--accent);
  font-weight: 700;
}

.conversation-list-main p {
  margin: 0;
  color: #3c4a3d;
  font-size: 14px;
  line-height: 20px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.conversation-list-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.conversation-list-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 10px;
  line-height: 14px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.conversation-list-pill.is-info {
  background: rgba(59, 130, 246, 0.12);
  color: #1d4ed8;
}

.conversation-list-pill.is-success {
  background: rgba(37, 211, 102, 0.12);
  color: #15703c;
}

.conversation-list-pill.is-warning {
  background: rgba(245, 158, 11, 0.12);
  color: #b45309;
}

.conversation-list-pill.is-muted {
  background: #dce5d8;
  color: #3c4a3d;
}

.conversations-thread {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  min-height: 0;
  overflow: hidden;
  background: #f8f9fa;
}

.conversations-thread-head,
.conversations-composer {
  background: #fff;
}

.conversations-thread-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: var(--conversation-header-height);
  padding: 16px 24px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.95);
}

.conversations-thread-contact,
.conversations-thread-actions,
.conversations-profile-actions,
.conversations-detail-list div,
.conversations-composer-shell {
  display: flex;
  align-items: center;
}

.conversations-thread-contact {
  gap: 14px;
}

.conversations-online-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}

.conversations-online-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #25d366;
}

.conversations-online-dot.is-offline {
  background: #94a3b8;
}

.conversations-thread-actions {
  gap: 8px;
}

.conversations-thread-actions button,
.conversations-profile-actions button {
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

.conversations-thread-actions button:hover,
.conversations-profile-actions button:hover {
  background: #edf6e9;
  color: var(--accent);
}

.conversations-thread-body {
  display: flex;
  flex-direction: column;
  min-height: 0;
  gap: 18px;
  padding: 24px;
  background: #f8f9fa;
}

.conversations-empty-state {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 32px 20px;
  text-align: center;
  color: var(--muted);
}

.conversations-empty-state .material-symbols-outlined {
  font-size: 28px;
}

.conversations-empty-state p {
  margin: 0;
  font-size: 14px;
}

.conversation-message-wrap {
  display: flex;
  flex-direction: column;
  max-width: 70%;
}

.conversation-message-wrap.is-outgoing {
  align-self: flex-end;
  align-items: flex-end;
}

.conversation-message-wrap.is-incoming {
  align-items: flex-start;
}

.conversation-bubble {
  padding: 14px;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
}

.conversation-bubble.is-incoming {
  border: 1px solid rgba(187, 203, 185, 0.95);
  border-radius: 0 18px 18px 18px;
  background: #fff;
}

.conversation-bubble.is-outgoing {
  border-radius: 18px 0 18px 18px;
  background: var(--accent);
  color: #fff;
}

.conversation-bubble.is-outgoing p,
.conversation-bubble.is-outgoing strong {
  color: #f8fff9;
}

.conversation-bubble.is-rich {
  display: grid;
  gap: 10px;
}

.conversation-bubble p,
.conversation-bubble strong {
  margin: 0;
  font-size: 14px;
  line-height: 22px;
}

.conversation-bubble.is-rich strong {
  font-size: 15px;
}

.conversation-meta {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
}

.conversation-meta.is-outgoing {
  justify-content: flex-end;
}

.conversation-meta .material-symbols-outlined {
  font-size: 15px;
  color: var(--accent);
}

.conversation-system-divider {
  display: flex;
  justify-content: center;
  margin: 6px 0;
}

.conversation-system-divider span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 14px;
  border-radius: 999px;
  background: #dce5d8;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.conversations-composer {
  display: grid;
  gap: 12px;
  flex-shrink: 0;
  padding: 16px;
  border-top: 1px solid rgba(187, 203, 185, 0.95);
}

.conversations-composer-tools {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  overflow-x: auto;
}

.conversations-composer-tools button,
.conversations-profile-footer button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  border: 1px solid rgba(187, 203, 185, 0.95);
  background: #fff;
  color: #3c4a3d;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  box-shadow: none;
}

.conversations-composer-tools button {
  flex: 0 0 auto;
  padding: 8px 14px;
  white-space: nowrap;
}

.conversations-composer-tools button.is-active {
  border-color: rgba(0, 109, 47, 0.3);
  background: rgba(0, 109, 47, 0.05);
  color: var(--accent);
}

.conversations-composer-suggestions {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  overflow-x: auto;
}

.conversation-suggestion-chip {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid rgba(0, 109, 47, 0.16);
  border-radius: 999px;
  background: rgba(0, 109, 47, 0.04);
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  box-shadow: none;
  white-space: nowrap;
}

.conversation-suggestion-chip:hover {
  background: rgba(0, 109, 47, 0.08);
}

.conversations-composer-shell {
  gap: 10px;
  padding: 10px 14px;
  border-radius: 16px;
  background: #edf6e9;
}

.conversations-composer-shell > button,
.conversations-send-button {
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
}

.conversations-composer-shell textarea {
  flex: 1;
  min-height: 24px;
  max-height: 128px;
  resize: none;
  border: 0;
  background: transparent;
  color: var(--text);
  outline: none;
}

.conversations-send-button {
  background: var(--accent);
  color: #fff;
}

.conversations-profile {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.conversations-profile-top,
.conversations-profile-footer {
  padding: 24px;
}

.conversations-profile-top {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 10px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.95);
}

.conversations-profile-actions {
  gap: 8px;
  margin-top: 6px;
}

.conversations-profile-scroll {
  padding: 24px;
  display: grid;
  gap: 28px;
}

.conversations-profile-section h4 {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 12px;
  line-height: 16px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.conversations-detail-list,
.conversations-activity-list {
  display: grid;
  gap: 14px;
}

.conversations-detail-list div {
  gap: 10px;
}

.conversations-detail-list .material-symbols-outlined {
  color: var(--muted);
  font-size: 18px;
}

.conversations-detail-list p {
  margin: 0;
  color: var(--text);
}

.conversations-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.conversations-tags span,
.conversations-tags button {
  min-height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid rgba(187, 203, 185, 0.95);
  background: #e2ebde;
  color: #3c4a3d;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.conversations-tags button {
  background: rgba(0, 109, 47, 0.1);
  color: var(--accent);
  box-shadow: none;
}

.conversations-activity-item {
  display: flex;
  gap: 12px;
}

.conversations-activity-item i {
  width: 4px;
  border-radius: 999px;
  background: rgba(108, 123, 107, 0.5);
}

.conversations-activity-item i.is-primary {
  background: #25d366;
}

.conversations-activity-item strong {
  display: block;
  margin-bottom: 4px;
  font-size: 14px;
  line-height: 20px;
}

.conversations-profile-footer {
  border-top: 1px solid rgba(187, 203, 185, 0.95);
  background: #fff;
}

.conversations-profile-footer button {
  width: 100%;
  justify-content: center;
  min-height: 42px;
  border-radius: 12px;
}

@keyframes analyticsSpin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes analyticsPulse {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.45;
  }
}

.dashboard-kpi-delta.neutral {
  color: var(--muted);
}

.dashboard-volume-card {
  min-height: 400px;
  display: flex;
  flex-direction: column;
}

.card-head h3,
.dashboard-funnel-card h3,
.dashboard-alerts-card h3,
.dashboard-webhook-title h3,
.dashboard-table-head h3 {
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 24px;
  font-weight: 600;
  color: var(--text);
}

.dashboard-select {
  padding: 4px 12px;
  border-radius: 8px;
  border: 0;
  background: #e7f1e4;
  font-size: 14px;
  font-weight: 700;
}

.dashboard-line-chart {
  position: relative;
  flex: 1;
  min-height: 300px;
}

.dashboard-line-axis {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 0 16px 32px;
}

.dashboard-axis-column {
  position: relative;
  width: 1px;
  height: 100%;
}

.dashboard-axis-line {
  position: absolute;
  left: 50%;
  bottom: 24px;
  width: 2px;
  transform: translateX(-50%);
  background: rgba(187, 203, 185, 0.35);
}

.dashboard-axis-column span {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  font-size: 10px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.dashboard-line-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.dashboard-campaigns-card {
  overflow: hidden;
  padding: 0;
}

.dashboard-table-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.dashboard-link-button {
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: var(--accent);
  box-shadow: none;
  font-size: 14px;
  font-weight: 700;
}

.dashboard-table {
  width: 100%;
  border-collapse: collapse;
  font-family: "Inter", "Segoe UI", sans-serif;
  font-size: 14px;
}

.dashboard-table thead {
  background: rgba(237, 246, 233, 0.72);
}

.dashboard-table th,
.dashboard-table td {
  padding: 14px 20px;
  text-align: left;
}

.dashboard-table th {
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}

.dashboard-table tbody tr {
  border-top: 1px solid rgba(187, 203, 185, 0.3);
}

.dashboard-table tbody td:first-child {
  font-weight: 700;
  color: var(--text);
}

.status-pill.info {
  background: rgba(59, 130, 246, 0.12);
  color: #3b82f6;
}

.dashboard-funnel-card {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.dashboard-funnel-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dashboard-funnel-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  font-size: 14px;
}

.dashboard-funnel-meta span:first-child {
  font-weight: 700;
  color: var(--text);
}

.dashboard-funnel-track {
  height: 12px;
  border-radius: 999px;
  background: #e7f1e4;
  overflow: hidden;
}

.dashboard-funnel-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
}

.dashboard-webhook-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 20px;
  border-radius: 12px;
  background: #2a332a;
  color: #eaf3e6;
  box-shadow: 0 12px 28px rgba(21, 30, 22, 0.16);
}

.dashboard-webhook-card * {
  color: inherit;
}

.dashboard-webhook-head,
.dashboard-endpoint-meta,
.dashboard-webhook-stats div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.dashboard-webhook-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.dashboard-webhook-title .material-symbols-outlined {
  color: var(--accent-bright);
}

.dashboard-live-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--accent-bright);
  box-shadow: 0 0 0 6px rgba(37, 211, 102, 0.18);
}

.dashboard-endpoint-box {
  padding: 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(108, 123, 107, 0.24);
}

.dashboard-endpoint-meta span {
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.dashboard-endpoint-meta span:last-child {
  color: var(--accent-bright);
  font-weight: 700;
}

.dashboard-endpoint-box code {
  display: block;
  margin-top: 8px;
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dashboard-webhook-stats {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dashboard-outline-button {
  width: 100%;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid rgba(187, 203, 185, 0.22);
  background: transparent;
  color: #eaf3e6;
  box-shadow: none;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
}

.dashboard-alerts-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dashboard-alert {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-radius: 10px;
}

.dashboard-alert strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text);
}

.dashboard-alert p {
  margin: 0;
  font-size: 12px;
  line-height: 1.45;
}

.dashboard-alert.danger {
  background: rgba(255, 218, 214, 0.2);
  border-left: 4px solid #ba1a1a;
}

.dashboard-alert.danger .material-symbols-outlined,
.dashboard-alert.danger strong,
.dashboard-alert.danger p {
  color: #93000a;
}

.dashboard-alert.info {
  background: #e7f1e4;
  border-left: 4px solid var(--accent);
}

.dashboard-alert.info .material-symbols-outlined {
  color: var(--accent);
}

@media (max-width: 960px) {
  .dashboard-sidebar {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
  }

  .dashboard-sidebar-scroll {
    overflow: visible;
    padding: 0;
  }

  .dashboard-main {
    margin-left: 0;
  }

  .dashboard-overview-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .dashboard-topbar,
  .dashboard-topbar-left,
  .dashboard-topbar-actions {
    flex-direction: column;
    align-items: flex-start;
    height: auto;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .dashboard-stat-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-table {
    display: block;
    overflow-x: auto;
  }
}

.users-row-button {
  width: 100%;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.users-row-button:hover {
  background: rgba(231, 241, 228, 0.72);
}

.users-board {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.users-page-header {
  margin-bottom: 0;
}

.users-hero-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 16px;
  background: var(--accent);
  color: #fff;
  padding: 14px 20px;
  font-weight: 700;
  box-shadow: 0 18px 30px rgba(0, 109, 47, 0.18);
  transition: transform 180ms ease, opacity 180ms ease;
}

.users-hero-button:hover {
  opacity: 0.94;
  transform: translateY(-2px);
}

.users-hero-button:disabled {
  opacity: 0.7;
  transform: none;
  cursor: wait;
}

.users-stats-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 24px;
}

.users-stat-card {
  grid-column: span 4;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 24px;
  border-radius: 24px;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.35);
  box-shadow: 0 12px 24px rgba(21, 30, 22, 0.04);
  position: relative;
  overflow: hidden;
}

.users-stat-card.is-accent {
  background: var(--accent);
  color: #fff;
  border-color: transparent;
}

.users-stat-content {
  position: relative;
  z-index: 1;
}

.users-stat-glow {
  position: absolute;
  right: -32px;
  bottom: -48px;
  width: 148px;
  height: 148px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  filter: blur(18px);
}

.users-stat-label {
  margin: 0 0 8px;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #64748b;
  font-weight: 700;
}

.users-stat-card.is-accent .users-stat-label,
.users-stat-card.is-accent .users-stat-copy {
  color: rgba(255, 255, 255, 0.88);
}

.users-stat-card h3 {
  margin: 0;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 36px;
  line-height: 1;
}

.users-stat-copy {
  margin: 8px 0 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: #25d366;
}

.users-stat-copy.is-warning {
  color: #f59e0b;
}

.users-stat-icon {
  width: 56px;
  height: 56px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.users-stat-icon .material-symbols-outlined {
  font-size: 30px;
}

.users-stat-icon.tone-primary {
  background: rgba(0, 109, 47, 0.1);
  color: var(--accent);
}

.users-stat-icon.tone-secondary {
  background: rgba(140, 241, 225, 0.35);
  color: #006b5f;
}

.users-stat-icon.tone-contrast {
  position: relative;
  z-index: 1;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.users-form-shell {
  display: grid;
  grid-template-columns: 1fr;
}

.users-panel-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
  gap: 24px;
}

.users-edit-layout {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.users-form-card {
  padding: 28px;
  border-radius: 24px;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.35);
  box-shadow: 0 12px 28px rgba(21, 30, 22, 0.05);
}

.users-form-card.edit {
  padding: 36px;
}

.users-form-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.users-form-head.create {
  margin-bottom: 32px;
}

.users-form-head h2 {
  margin: 6px 0 8px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 28px;
  line-height: 1.1;
}

.users-form-head p {
  margin: 0;
  color: #64748b;
  max-width: 720px;
}

.users-panel-badge {
  align-self: flex-start;
  padding: 10px 14px;
  border-radius: 999px;
  background: #e7f1e4;
  color: var(--accent);
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
}

.users-panel-badge.tone-success {
  background: rgba(37, 211, 102, 0.16);
  color: #0b7d38;
}

.users-panel-badge.tone-warning {
  background: rgba(245, 158, 11, 0.16);
  color: #a16207;
}

.users-panel-badge.tone-error {
  background: rgba(239, 68, 68, 0.14);
  color: #b91c1c;
}

.users-panel-badge.tone-muted {
  background: rgba(187, 203, 185, 0.35);
  color: #3c4a3d;
}

.users-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 24px;
}

.users-create-section {
  padding: 24px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.28);
}

.users-create-section h3 {
  margin: 0 0 24px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
}

.users-form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.users-form-field > span {
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #3c4a3d;
  font-weight: 700;
}

.users-form-field input,
.users-form-field select,
.users-filter-field input,
.users-filter-field select {
  width: 100%;
  min-width: 0;
  height: 56px;
  padding: 0 18px;
  border-radius: 14px;
  border: 1px solid rgba(187, 203, 185, 0.9);
  background: #ffffff;
  color: #1a1c1e;
  font-size: 16px;
  line-height: 24px;
  box-sizing: border-box;
  outline: none;
  transition: border-color 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}

.users-form-field input::placeholder,
.users-filter-field input::placeholder {
  color: #8a94a6;
}

.users-form-field input:focus,
.users-form-field select:focus,
.users-filter-field input:focus,
.users-filter-field select:focus {
  border-color: #25d366;
  box-shadow: 0 0 0 3px rgba(37, 211, 102, 0.14);
}

.users-form-field input:disabled,
.users-form-field select:disabled {
  background: #f8f9fa;
  color: #7b8799;
}

.users-form-note {
  margin-top: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 14px;
  background: #edf6e9;
  color: #3c4a3d;
  font-size: 14px;
}

.users-footer-actions {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid rgba(187, 203, 185, 0.3);
  display: flex;
  justify-content: flex-end;
  gap: 16px;
}

.users-form-actions {
  margin-top: 24px;
  justify-content: flex-end;
}

.users-edit-meta {
  margin-top: 20px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.users-edit-meta div {
  padding: 16px;
  border-radius: 16px;
  background: #f8f9fa;
  border: 1px solid rgba(187, 203, 185, 0.3);
}

.users-edit-meta strong {
  display: block;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
  margin-bottom: 6px;
}

.users-edit-meta span {
  color: #64748b;
  font-size: 14px;
}

.users-feedback {
  margin: 0;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(37, 211, 102, 0.12);
  color: #0b7d38;
  font-size: 14px;
}

.users-summary-card {
  padding: 24px;
  border-radius: 24px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 18px 36px rgba(0, 109, 47, 0.16);
}

.users-summary-card h4 {
  margin: 0 0 20px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 20px;
}

.users-summary-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.users-summary-list div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.users-summary-list span {
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.74);
}

.users-summary-list p {
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 14px;
  line-height: 1.6;
}

.users-illustration-card {
  overflow: hidden;
  border-radius: 24px;
  background: #e7f1e4;
  border: 1px solid rgba(187, 203, 185, 0.3);
}

.users-illustration-art {
  height: 192px;
  background:
    radial-gradient(circle at 20% 20%, rgba(37, 211, 102, 0.45), transparent 32%),
    radial-gradient(circle at 80% 30%, rgba(0, 107, 95, 0.24), transparent 28%),
    linear-gradient(135deg, #dce5d8 0%, #f3fcef 55%, #edf6e9 100%);
}

.users-illustration-copy {
  padding: 20px;
}

.users-illustration-copy h5 {
  margin: 0 0 6px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
}

.users-illustration-copy p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
  line-height: 1.6;
}

.users-profile-card,
.users-security-card,
.users-danger-card {
  padding: 24px;
  border-radius: 24px;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.3);
  box-shadow: 0 12px 28px rgba(21, 30, 22, 0.05);
}

.users-profile-card {
  text-align: center;
}

.users-profile-avatar {
  width: 128px;
  height: 128px;
  margin: 0 auto 16px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(37, 211, 102, 0.16);
  color: var(--accent);
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 40px;
  font-weight: 800;
  border: 4px solid #fff;
  box-shadow: 0 0 0 2px rgba(37, 211, 102, 0.28);
}

.users-profile-card h3 {
  margin: 0 0 4px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 24px;
}

.users-profile-card > p {
  margin: 0 0 24px;
  color: #64748b;
}

.users-profile-meta {
  padding-top: 24px;
  border-top: 1px solid rgba(187, 203, 185, 0.3);
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
}

.users-profile-meta p {
  margin: 0 0 6px;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #64748b;
}

.users-profile-meta strong {
  font-size: 16px;
}

.users-profile-meta strong.tone-success {
  color: #0b7d38;
}

.users-profile-meta strong.tone-warning {
  color: #a16207;
}

.users-profile-meta strong.tone-error {
  color: #b91c1c;
}

.users-security-card h4,
.users-danger-card h4 {
  margin: 0 0 16px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 14px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #64748b;
}

.users-toolbar-button.full {
  width: 100%;
  justify-content: center;
  padding: 14px 16px;
  color: var(--accent);
}

.users-danger-card {
  display: flex;
  gap: 16px;
  background: rgba(255, 218, 214, 0.16);
  border-color: rgba(186, 26, 26, 0.18);
}

.users-danger-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 218, 214, 0.9);
  color: #93000a;
}

.users-danger-card p {
  margin: 0 0 16px;
  color: #64748b;
}

.users-danger-card button {
  padding: 10px 16px;
  border-radius: 12px;
  border: 0;
  background: #ba1a1a;
  color: #fff;
  font-weight: 700;
}

.users-danger-card button:disabled {
  opacity: 0.6;
}

.users-table-shell {
  border-radius: 24px;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.35);
  box-shadow: 0 12px 28px rgba(21, 30, 22, 0.05);
}

.users-table-toolbar {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.3);
}

.users-table-toolbar h4 {
  margin: 0;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
}

.users-toolbar-actions {
  display: flex;
  gap: 12px;
}

.users-toolbar-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(187, 203, 185, 0.35);
  background: transparent;
  color: #3c4a3d;
}

.users-toolbar-button.large {
  padding: 18px 28px;
  border-radius: 22px;
  font-size: 14px;
  font-weight: 700;
}

.users-filters-panel {
  padding: 20px 24px;
  display: grid;
  grid-template-columns: minmax(220px, 2fr) repeat(2, minmax(180px, 1fr)) auto;
  gap: 16px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.3);
  background: #fcfdfb;
}

.users-filter-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.users-filter-field span {
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #64748b;
  font-weight: 700;
}

.users-filter-actions {
  display: flex;
  align-items: flex-end;
}

.users-table-wrap {
  overflow-x: auto;
}

.users-table {
  width: 100%;
  border-collapse: collapse;
}

.users-table th,
.users-table td {
  padding: 18px 24px;
  text-align: left;
}

.users-table thead th {
  background: rgba(237, 246, 233, 0.65);
  color: #3c4a3d;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.users-table tbody tr {
  border-top: 1px solid rgba(187, 203, 185, 0.22);
}

.users-table tbody tr:hover {
  background: rgba(248, 249, 250, 0.8);
}

.users-identity {
  display: flex;
  align-items: center;
  gap: 14px;
}

.users-avatar {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.users-avatar.tone-admin {
  background: rgba(37, 211, 102, 0.16);
  color: var(--accent);
}

.users-avatar.tone-editor {
  background: rgba(140, 241, 225, 0.3);
  color: #006b5f;
}

.users-avatar.tone-agent {
  background: rgba(220, 229, 216, 0.8);
  color: #3c4a3d;
}

.users-identity p {
  margin: 0 0 2px;
  font-weight: 700;
}

.users-identity span,
.users-muted {
  color: #64748b;
  font-size: 14px;
}

.users-role-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 11px;
  line-height: 14px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
  border: 1px solid transparent;
}

.users-role-pill.tone-admin {
  background: rgba(255, 160, 126, 0.18);
  color: #78351b;
  border-color: rgba(255, 160, 126, 0.25);
}

.users-role-pill.tone-editor {
  background: rgba(140, 241, 225, 0.32);
  color: #006f64;
  border-color: rgba(140, 241, 225, 0.4);
}

.users-role-pill.tone-agent {
  background: rgba(220, 229, 216, 0.65);
  color: #3c4a3d;
  border-color: rgba(187, 203, 185, 0.38);
}

.users-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.users-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
}

.users-status-dot.tone-success {
  background: #25d366;
}

.users-status-dot.tone-warning {
  background: #f59e0b;
}

.users-status-dot.tone-error {
  background: #ef4444;
}

.users-status-dot.tone-muted {
  background: #94a3b8;
}

.users-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.users-actions button {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #64748b;
}

.users-actions button:hover {
  background: rgba(0, 109, 47, 0.06);
  color: var(--accent);
}

.users-empty-state {
  padding: 48px 24px;
  text-align: center;
  color: #64748b;
}

.users-table .align-right {
  text-align: right;
}

.users-pagination {
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border-top: 1px solid rgba(187, 203, 185, 0.3);
  background: #fcfdfb;
}

.users-pagination p {
  margin: 0;
  font-size: 14px;
  color: #64748b;
}

.users-pagination-buttons {
  display: flex;
  gap: 6px;
}

.users-pagination-buttons button {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid rgba(187, 203, 185, 0.35);
  background: transparent;
  color: #3c4a3d;
}

.users-pagination-buttons button.is-active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.users-loading-bar {
  height: 3px;
  background: linear-gradient(90deg, rgba(0, 109, 47, 0.08), var(--accent), rgba(0, 109, 47, 0.08));
  background-size: 200% 100%;
  animation: users-loading 1.1s linear infinite;
}

@keyframes users-loading {
  from {
    background-position: 200% 0;
  }
  to {
    background-position: -200% 0;
  }
}

.users-role-overview {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 24px;
  align-items: start;
}

.users-role-overview h5 {
  margin: 0 0 8px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
}

.users-role-overview p {
  margin: 0;
  color: #64748b;
}

.users-role-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.users-role-card {
  padding: 18px;
  border-radius: 18px;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.3);
}

.users-role-card-head {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 700;
}

.users-role-card-head.tone-admin {
  color: #78351b;
}

.users-role-card-head.tone-editor {
  color: #006f64;
}

.users-role-card-head.tone-agent {
  color: #3c4a3d;
}

@media (max-width: 1100px) {
  .users-stat-card {
    grid-column: span 12;
  }

  .users-panel-layout,
  .users-edit-layout {
    grid-template-columns: 1fr;
  }

  .users-role-overview {
    grid-template-columns: 1fr;
  }

  .users-role-cards {
    grid-template-columns: 1fr;
  }

  .users-filters-panel {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .users-form-grid,
  .users-edit-meta {
    grid-template-columns: 1fr;
  }

  .users-form-head,
  .users-table-toolbar,
  .users-pagination {
    flex-direction: column;
    align-items: flex-start;
  }

  .users-toolbar-actions,
  .users-pagination-buttons {
    flex-wrap: wrap;
  }

  .users-filters-panel {
    grid-template-columns: 1fr;
  }

  .users-footer-actions {
    flex-direction: column;
    align-items: stretch;
  }
}

.invite-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px 24px;
  background:
    radial-gradient(circle at top, rgba(102, 255, 142, 0.2), transparent 35%),
    #edf6e9;
}

.invite-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 32px;
  color: var(--accent);
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 24px;
  font-weight: 800;
}

.invite-brand-mark {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
}

.invite-card {
  width: 100%;
  max-width: 480px;
  padding: 40px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.8);
  box-shadow: 0 24px 60px rgba(26, 28, 30, 0.08);
}

.invite-card-head {
  text-align: center;
  margin-bottom: 32px;
}

.invite-card-head h1 {
  margin: 0 0 12px;
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 30px;
  line-height: 1.1;
}

.invite-card-head p {
  margin: 0;
  color: #64748b;
}

.invite-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.invite-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.invite-field input,
.invite-field textarea {
  width: 100%;
  border: 1px solid rgba(187, 203, 185, 0.8);
  border-radius: 14px;
  background: #fff;
  color: var(--text);
  padding: 14px 16px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.invite-field input:focus,
.invite-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(37, 211, 102, 0.12);
}

.invite-field > span,
.invite-strength-head span {
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #3c4a3d;
  font-weight: 700;
}

.invite-password-wrap {
  position: relative;
}

.invite-password-wrap input {
  padding-right: 52px;
}

.invite-password-wrap button {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: #64748b;
  cursor: pointer;
}

.invite-strength {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.invite-strength-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.invite-strength-head strong {
  color: var(--accent);
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.invite-strength-bars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
}

.invite-strength-bars span {
  height: 6px;
  border-radius: 999px;
  background: #dce5d8;
}

.invite-strength-bars span.is-active {
  background: var(--accent);
}

.invite-checklist {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  border-radius: 12px;
  background: #edf6e9;
}

.invite-checklist div {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #64748b;
  font-size: 14px;
}

.invite-checklist div.is-done {
  color: #151e16;
}

.invite-checklist .material-symbols-outlined {
  font-size: 18px;
}

.invite-checklist div.is-done .material-symbols-outlined {
  color: #25d366;
  font-variation-settings: "FILL" 1;
}

.invite-submit-button {
  width: 100%;
  height: 48px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  transition: transform 180ms ease, opacity 180ms ease;
}

.invite-submit-button:hover {
  opacity: 0.92;
}

.invite-submit-button:active {
  transform: scale(0.985);
}

.invite-submit-button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.invite-footer {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid rgba(187, 203, 185, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: #64748b;
  font-size: 14px;
}

.invite-footer a {
  color: var(--accent);
  font-weight: 700;
}

.auth-public-copy {
  margin-bottom: 24px;
}

.auth-public-meta {
  font-size: 0.9rem;
  color: var(--muted-soft);
}

.auth-inline-footer {
  margin-top: 24px;
}

.security-session-card {
  display: grid;
  gap: 24px;
}

.security-session-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.security-session-head h2 {
  margin: 6px 0 8px;
  font-size: 1.35rem;
}

.security-session-badge {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(37, 211, 102, 0.12);
  color: var(--accent-dark);
  font-size: 0.76rem;
  line-height: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.security-session-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.security-session-item {
  display: grid;
  gap: 6px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(187, 203, 185, 0.45);
  background: rgba(237, 246, 233, 0.55);
}

.security-session-item strong {
  font-size: 0.76rem;
  line-height: 1rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.security-session-item span {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.security-session-item small {
  color: var(--muted-soft);
  font-size: 0.9rem;
}

.security-session-actions {
  display: grid;
  gap: 12px;
}

.security-session-actions form {
  max-width: 320px;
}

.campaigns-page {
  display: grid;
  gap: 32px;
}

.campaigns-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.campaigns-title {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: clamp(2rem, 3vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: #1a1c1e;
}

.campaigns-copy {
  margin: 10px 0 0;
  max-width: 720px;
  color: #64748b;
  font-size: 16px;
  line-height: 1.6;
}

.campaigns-primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 24px;
  border: 0;
  border-radius: 16px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 16px 36px rgba(0, 109, 47, 0.16);
  cursor: pointer;
  transition: transform 180ms ease, opacity 180ms ease;
}

.campaigns-primary-button:hover {
  opacity: 0.92;
}

.campaigns-primary-button:active {
  transform: scale(0.98);
}

.campaigns-primary-button .material-symbols-outlined {
  font-size: 20px;
}

.campaigns-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}

.campaigns-create-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  background: rgba(21, 30, 22, 0.35);
  backdrop-filter: blur(6px);
}

.campaigns-create-modal {
  width: min(980px, 100%);
  max-height: calc(100vh - 64px);
  overflow: auto;
  border-radius: 24px;
  background: #fff;
  border: 1px solid rgba(187, 203, 185, 0.5);
  box-shadow: 0 32px 72px rgba(12, 18, 16, 0.18);
}

.campaigns-create-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 24px 0;
}

.campaigns-create-modal-head p {
  margin: 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.campaigns-create-modal-head h2 {
  margin: 6px 0 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 28px;
  line-height: 1.2;
  color: #1a1c1e;
}

.campaigns-create-modal-head button {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 12px;
  background: #edf6e9;
  color: #475569;
}

.campaigns-create-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 20px;
  padding: 24px;
}

.campaigns-create-form label {
  display: grid;
  gap: 8px;
}

.campaigns-create-form label.is-wide {
  grid-column: 1 / -1;
}

.campaigns-create-form label span {
  color: #4d5c50;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.campaigns-create-form input,
.campaigns-create-form select,
.campaigns-create-form textarea {
  width: 100%;
  min-height: 50px;
  border-radius: 14px;
  border: 1px solid rgba(187, 203, 185, 0.72);
  background: #f9fcf7;
  padding: 0 16px;
  color: #1a1c1e;
  font-size: 15px;
  outline: none;
}

.campaigns-create-form textarea {
  min-height: 120px;
  padding: 14px 16px;
  resize: vertical;
}

.campaigns-create-form input:focus,
.campaigns-create-form select:focus,
.campaigns-create-form textarea:focus {
  border-color: rgba(0, 109, 47, 0.45);
  box-shadow: 0 0 0 3px rgba(0, 109, 47, 0.12);
}

.campaigns-create-error {
  grid-column: 1 / -1;
  margin: 0;
  color: #dc2626;
  font-size: 14px;
  font-weight: 600;
}

.campaigns-create-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding-top: 8px;
}

.campaigns-create-cancel {
  min-height: 50px;
  padding: 0 20px;
  border-radius: 14px;
  border: 1px solid rgba(187, 203, 185, 0.8);
  background: #fff;
  color: #1a1c1e;
  font-weight: 700;
}

.campaigns-stat-card {
  min-height: 152px;
  padding: 20px;
  border: 1px solid rgba(187, 203, 185, 0.45);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(12, 18, 16, 0.04);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.campaigns-stat-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.campaigns-stat-head > .material-symbols-outlined {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: #e7f1e4;
  color: var(--accent);
  font-size: 22px;
}

.campaigns-stat-head > .material-symbols-outlined.is-secondary {
  color: #006b5f;
}

.campaigns-stat-head > .material-symbols-outlined.is-warning {
  color: #f59e0b;
}

.campaigns-stat-head > .material-symbols-outlined.is-error {
  color: #ef4444;
}

.campaigns-stat-delta {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 12px;
  font-weight: 700;
}

.campaigns-stat-delta.is-positive {
  color: #16a34a;
}

.campaigns-stat-delta .material-symbols-outlined {
  font-size: 16px;
}

.campaigns-stat-card p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
  font-weight: 600;
}

.campaigns-stat-card strong {
  display: block;
  margin-top: 6px;
  color: var(--accent);
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 32px;
  line-height: 1.1;
}

.campaigns-stat-card strong.is-secondary {
  color: #006b5f;
}

.campaigns-table-card {
  overflow: hidden;
  border: 1px solid rgba(187, 203, 185, 0.5);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(12, 18, 16, 0.05);
}

.campaigns-table-toolbar {
  padding: 24px;
  border-bottom: 1px solid rgba(187, 203, 185, 0.45);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.campaigns-filter-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.campaigns-filter-pill {
  border: 0;
  border-radius: 999px;
  padding: 12px 16px;
  background: transparent;
  color: #4d5c50;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease;
}

.campaigns-filter-pill:hover {
  background: #edf6e9;
}

.campaigns-filter-pill.is-active {
  background: rgba(37, 211, 102, 0.18);
  color: #005523;
  font-weight: 700;
}

.campaigns-filter-tabs .campaigns-filter-pill:last-child:not(.is-active) {
  color: #ef4444;
}

.campaigns-table-controls {
  display: flex;
  align-items: center;
  gap: 12px;
}

.campaigns-search-field,
.campaigns-sort-field {
  position: relative;
  display: flex;
  align-items: center;
}

.campaigns-search-field .material-symbols-outlined,
.campaigns-sort-field .material-symbols-outlined {
  position: absolute;
  left: 12px;
  color: #64748b;
  opacity: 0.72;
  font-size: 18px;
  pointer-events: none;
}

.campaigns-search-field input,
.campaigns-sort-field select {
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  background: #edf6e9;
  color: #1a1c1e;
  font-size: 14px;
  outline: none;
}

.campaigns-search-field input {
  width: 260px;
  padding: 0 14px 0 40px;
}

.campaigns-sort-field select {
  min-width: 210px;
  padding: 0 40px 0 40px;
  appearance: none;
  cursor: pointer;
}

.campaigns-search-field input:focus,
.campaigns-sort-field select:focus {
  box-shadow: 0 0 0 2px rgba(0, 109, 47, 0.18);
}

.campaigns-table-wrap {
  overflow-x: auto;
}

.campaigns-table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
}

.campaigns-table thead tr {
  background: #edf6e9;
}

.campaigns-table th,
.campaigns-table td {
  padding: 18px 24px;
  text-align: left;
  vertical-align: middle;
}

.campaigns-table th {
  color: #5f6f63;
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.campaigns-table tbody tr {
  border-top: 1px solid rgba(187, 203, 185, 0.36);
  transition: background 180ms ease;
}

.campaigns-table tbody tr:hover {
  background: rgba(243, 252, 239, 0.68);
}

.campaigns-table th.is-right,
.campaigns-table td.is-right {
  text-align: right;
}

.campaigns-name-link {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  color: inherit;
  text-decoration: none;
}

.campaigns-name-link span {
  font-size: 16px;
  font-weight: 700;
  color: #151e16;
}

.campaigns-name-link small,
.campaigns-audience-cell small,
.campaigns-date-cell small {
  color: #64748b;
  font-size: 11px;
  line-height: 16px;
}

.campaigns-audience-cell {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.campaigns-audience-cell .material-symbols-outlined {
  color: #64748b;
  opacity: 0.64;
  font-size: 18px;
}

.campaigns-audience-cell > div,
.campaigns-date-cell {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
}

.campaigns-audience-cell span,
.campaigns-date-cell span {
  color: #151e16;
  font-size: 14px;
}

.campaigns-date-cell.is-scheduled span {
  color: #2563eb;
  font-weight: 600;
}

.campaign-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.campaign-status-pill.is-sent {
  background: rgba(37, 211, 102, 0.16);
  color: #0f7a39;
}

.campaign-status-pill.is-scheduled {
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.2);
  color: #2563eb;
}

.campaign-status-pill.is-draft {
  background: #e7f1e4;
  color: #526458;
}

.campaign-status-pill.is-failed {
  background: rgba(239, 68, 68, 0.1);
  color: #dc2626;
}

.campaigns-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
}

.campaign-status-pill.is-scheduled .campaigns-status-dot {
  animation: campaigns-pulse 1.4s ease-in-out infinite;
}

.campaign-status-pill .material-symbols-outlined {
  font-size: 14px;
}

.campaigns-pending-text {
  color: #64748b;
  font-size: 14px;
  font-style: italic;
}

.campaigns-delivery-cell {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.campaigns-progress-track {
  width: 64px;
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: #e7f1e4;
}

.campaigns-progress-bar {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #25d366;
}

.campaigns-progress-bar.is-failed {
  background: #ef4444;
}

.campaigns-delivery-cell strong {
  color: #151e16;
  font-size: 14px;
}

.campaigns-delivery-cell strong.is-error {
  color: #dc2626;
}

.campaigns-action-button {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: #5f6f63;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease;
}

.campaigns-action-button:hover {
  background: #edf6e9;
}

.campaigns-action-button.is-error {
  color: #dc2626;
}

.campaigns-pagination {
  padding: 18px 24px;
  border-top: 1px solid rgba(187, 203, 185, 0.45);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.campaigns-pagination p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
}

.campaigns-pagination strong {
  color: #151e16;
}

.campaigns-pagination-buttons {
  display: flex;
  align-items: center;
  gap: 4px;
}

.campaigns-pagination-buttons button,
.campaigns-pagination-buttons span {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #526458;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.campaigns-pagination-buttons button {
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease;
}

.campaigns-pagination-buttons button:hover:not(:disabled):not(.is-active) {
  background: #edf6e9;
}

.campaigns-pagination-buttons button.is-active {
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}

.campaigns-pagination-buttons button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.campaigns-insight-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr);
  gap: 24px;
}

.campaigns-insight-card,
.campaigns-health-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  box-shadow: 0 18px 40px rgba(12, 18, 16, 0.05);
}

.campaigns-insight-card {
  border: 1px solid rgba(187, 203, 185, 0.5);
  background: #fff;
}

.campaigns-insight-glow {
  position: absolute;
  right: -40px;
  bottom: -56px;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  background: rgba(37, 211, 102, 0.16);
  filter: blur(22px);
}

.campaigns-insight-body {
  position: relative;
  z-index: 1;
  padding: 24px;
}

.campaigns-insight-body h2,
.campaigns-health-card h2 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.3;
  color: #151e16;
}

.campaigns-insight-body p,
.campaigns-health-card p {
  margin: 12px 0 0;
  color: #64748b;
  font-size: 16px;
  line-height: 1.7;
}

.campaigns-insight-body p strong {
  color: var(--accent);
}

.campaigns-insight-body p strong.is-success {
  color: #16a34a;
}

.campaigns-insight-body button {
  margin-top: 18px;
  min-height: 42px;
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: #e7f1e4;
  color: #1a1c1e;
  font-weight: 700;
  cursor: pointer;
}

.campaigns-health-card {
  padding: 24px;
  background: var(--accent);
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.campaigns-health-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.campaigns-health-head .material-symbols-outlined {
  font-size: 24px;
}

.campaigns-health-card h2,
.campaigns-health-card p {
  color: inherit;
}

.campaigns-health-card strong {
  display: block;
  margin-top: 28px;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 42px;
  line-height: 1;
}

@keyframes campaigns-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.35;
  }
}

@media (max-width: 1120px) {
  .campaigns-stats-grid,
  .campaigns-insight-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .campaigns-header,
  .campaigns-table-toolbar,
  .campaigns-pagination {
    flex-direction: column;
    align-items: stretch;
  }

  .campaigns-table-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .campaigns-search-field input,
  .campaigns-sort-field select {
    width: 100%;
  }

  .campaigns-create-form {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .campaigns-stats-grid,
  .campaigns-insight-grid {
    grid-template-columns: 1fr;
  }
}

.campaign-detail-page {
  display: grid;
  gap: 32px;
}

.campaign-detail-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.campaign-detail-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #64748b;
  font-size: 14px;
}

.campaign-detail-breadcrumb a {
  color: inherit;
  text-decoration: none;
}

.campaign-detail-breadcrumb span:last-child {
  color: var(--accent);
  font-weight: 600;
}

.campaign-detail-heading-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 8px;
}

.campaign-detail-heading-row h1 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: clamp(2rem, 3vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: #1a1c1e;
}

.campaign-detail-header p {
  margin: 10px 0 0;
  color: #64748b;
  font-size: 16px;
}

.campaign-detail-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.campaign-detail-badge.is-sent {
  background: rgba(37, 211, 102, 0.18);
  color: #0f7a39;
}

.campaign-detail-badge.is-scheduled {
  background: rgba(59, 130, 246, 0.12);
  color: #2563eb;
}

.campaign-detail-badge.is-draft {
  background: #e7f1e4;
  color: #4d5c50;
}

.campaign-detail-badge.is-failed {
  background: rgba(239, 68, 68, 0.12);
  color: #dc2626;
}

.campaign-detail-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.campaign-detail-header-actions a {
  text-decoration: none;
}

.campaign-detail-header-actions button:disabled,
.campaign-detail-header-actions a:disabled,
.campaign-detail-primary-button:disabled,
.campaign-detail-secondary-button:disabled,
.campaign-detail-danger-button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.campaign-detail-primary-button,
.campaign-detail-secondary-button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
  cursor: pointer;
}

.campaign-detail-secondary-button {
  border: 1px solid rgba(187, 203, 185, 0.7);
  background: #fff;
  color: #475569;
}

.campaign-detail-primary-button {
  border: 0;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 12px 28px rgba(0, 109, 47, 0.18);
}

.campaign-detail-danger-button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  background: rgba(239, 68, 68, 0.12);
  color: #b91c1c;
  font-weight: 700;
  cursor: pointer;
}

.campaign-detail-inline-tools {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
}

.campaign-detail-schedule-field {
  display: grid;
  gap: 8px;
  min-width: min(100%, 320px);
}

.campaign-detail-schedule-field span,
.campaign-detail-field span {
  color: #3c4a3d;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.campaign-detail-schedule-field input,
.campaign-detail-field input,
.campaign-detail-field select,
.campaign-detail-field textarea {
  width: 100%;
  min-height: 46px;
  border-radius: 12px;
  border: 1px solid rgba(187, 203, 185, 0.8);
  background: #fff;
  padding: 0 14px;
  color: #1a1c1e;
}

.campaign-detail-field textarea {
  min-height: 116px;
  padding: 14px;
  resize: vertical;
}

.campaign-detail-inline-message {
  margin: 14px 0 0;
  color: #006d2f;
  font-size: 14px;
  font-weight: 600;
}

.campaign-detail-edit-panel {
  margin-top: 20px;
  padding: 20px;
  border-radius: 20px;
  border: 1px solid rgba(187, 203, 185, 0.7);
  background: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.campaign-detail-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.campaign-detail-field {
  display: grid;
  gap: 8px;
}

.campaign-detail-field.is-full {
  grid-column: 1 / -1;
}

.campaign-detail-edit-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 18px;
}

.campaign-detail-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}

.campaign-detail-kpi-card,
.campaign-detail-card {
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.campaign-detail-kpi-card {
  padding: 20px;
}

.campaign-detail-kpi-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.campaign-detail-kpi-head > .material-symbols-outlined {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: #e7f1e4;
  color: var(--accent);
}

.campaign-detail-kpi-head > .material-symbols-outlined.is-secondary {
  background: rgba(140, 241, 225, 0.3);
  color: #006b5f;
}

.campaign-detail-kpi-head > .material-symbols-outlined.is-tertiary {
  background: rgba(255, 160, 126, 0.22);
  color: #93492e;
}

.campaign-detail-kpi-head > .material-symbols-outlined.is-error {
  background: rgba(255, 218, 214, 0.5);
  color: #ba1a1a;
}

.campaign-detail-kpi-head .is-positive,
.campaign-detail-kpi-head .is-warning,
.campaign-detail-kpi-head .is-danger {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  font-weight: 700;
}

.campaign-detail-kpi-head .is-positive {
  color: #16a34a;
}

.campaign-detail-kpi-head .is-warning {
  color: #f59e0b;
}

.campaign-detail-kpi-head .is-danger {
  color: #ef4444;
}

.campaign-detail-kpi-card p {
  margin: 0 0 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.campaign-detail-kpi-card strong {
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 32px;
  line-height: 1.1;
  color: #1a1c1e;
}

.campaign-detail-main-grid,
.campaign-detail-bottom-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 32px;
}

.campaign-detail-timeline-card {
  grid-column: span 8;
  padding: 20px;
}

.campaign-detail-preview-card {
  grid-column: span 4;
  padding: 20px;
}

.campaign-detail-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.campaign-detail-card-head h2,
.campaign-detail-preview-card h2,
.campaign-detail-recipients-card h2,
.campaign-detail-side-stack h2 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.3;
  color: #1a1c1e;
}

.campaign-detail-card-head select {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid rgba(187, 203, 185, 0.7);
  background: #edf6e9;
}

.campaign-detail-timeline-bars {
  min-height: 300px;
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

.campaign-detail-timeline-column {
  flex: 1;
  height: 300px;
  display: flex;
  align-items: flex-end;
}

.campaign-detail-timeline-bar {
  width: 100%;
  min-height: 12px;
  border-radius: 14px 14px 0 0;
  background: rgba(0, 109, 47, 0.1);
}

.campaign-detail-timeline-bar.is-highlight {
  background: var(--accent);
  box-shadow: 0 16px 32px rgba(0, 109, 47, 0.2);
}

.campaign-detail-timeline-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 16px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.campaign-preview-phone {
  max-width: 320px;
  margin: 0 auto;
  padding: 16px;
  border-radius: 18px;
  background: #e7fedc;
  position: relative;
  overflow: hidden;
}

.campaign-preview-phone img {
  width: 100%;
  height: 128px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 12px;
}

.campaign-preview-title,
.campaign-preview-copy {
  margin: 0;
  color: #151e16;
}

.campaign-preview-title {
  font-weight: 700;
}

.campaign-preview-copy {
  margin-top: 6px;
  line-height: 1.6;
  font-size: 14px;
}

.campaign-preview-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 14px 0 16px;
  color: #64748b;
  font-size: 11px;
}

.campaign-preview-buttons {
  display: grid;
  gap: 8px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  padding-top: 10px;
}

.campaign-preview-buttons button {
  min-height: 40px;
  border: 0;
  border-radius: 10px;
  background: #fff;
  color: var(--accent);
  font-weight: 700;
}

.campaign-preview-foot {
  margin-top: 24px;
  display: grid;
  gap: 12px;
}

.campaign-preview-foot div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 14px;
}

.campaign-preview-foot span {
  color: #64748b;
}

.campaign-preview-foot strong {
  color: #1a1c1e;
}

.campaign-detail-recipients-card {
  grid-column: span 9;
  overflow: hidden;
}

.campaign-detail-side-stack {
  grid-column: span 3;
  display: grid;
  gap: 32px;
  align-content: start;
}

.campaign-detail-icon-actions {
  display: flex;
  gap: 8px;
}

.campaign-detail-icon-actions button {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: #5f6f63;
}

.campaign-detail-table-wrap {
  overflow-x: auto;
}

.campaign-detail-table {
  width: 100%;
  border-collapse: collapse;
}

.campaign-detail-table thead {
  background: #edf6e9;
}

.campaign-detail-table th,
.campaign-detail-table td {
  padding: 14px 24px;
  text-align: left;
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.campaign-detail-table th {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.campaign-detail-table tbody tr:hover {
  background: rgba(237, 246, 233, 0.65);
}

.campaign-detail-mono {
  font-family: "JetBrains Mono", monospace;
  font-size: 14px;
}

.campaign-recipient-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.campaign-recipient-status.is-read {
  color: var(--accent);
}

.campaign-recipient-status.is-delivered {
  color: #6c7b6b;
}

.campaign-recipient-status.is-failed {
  color: #ef4444;
}

.campaign-recipient-status .material-symbols-outlined {
  font-size: 16px;
}

.campaign-detail-error-pill {
  display: inline-flex;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255, 218, 214, 0.35);
  color: #ba1a1a;
  font-size: 11px;
  font-weight: 600;
}

.campaign-detail-table-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 24px;
}

.campaign-detail-table-footer p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
}

.campaign-detail-pagination {
  display: flex;
  align-items: center;
  gap: 8px;
}

.campaign-detail-pagination a {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  color: #1a1c1e;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.campaign-detail-pagination a.is-disabled {
  pointer-events: none;
  opacity: 0.45;
}

.campaign-detail-side-stack > .campaign-detail-card {
  padding: 20px;
}

.campaign-detail-device-list {
  display: grid;
  gap: 20px;
}

.campaign-detail-device-row {
  display: grid;
  gap: 8px;
}

.campaign-detail-device-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}

.campaign-detail-device-head span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #4d5c50;
}

.campaign-detail-device-track {
  width: 100%;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e7f1e4;
}

.campaign-detail-device-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
}

.campaign-detail-device-track span.is-android {
  background: var(--accent);
}

.campaign-detail-device-track span.is-ios {
  background: #006b5f;
}

.campaign-detail-device-track span.is-web {
  background: #6c7b6b;
}

.campaign-detail-insight-card {
  position: relative;
  overflow: hidden;
  padding: 20px;
  border-radius: 20px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 16px 34px rgba(0, 109, 47, 0.22);
}

.campaign-detail-insight-icon {
  position: absolute;
  right: -18px;
  bottom: -18px;
  opacity: 0.1;
}

.campaign-detail-insight-icon .material-symbols-outlined {
  font-size: 96px;
}

.campaign-detail-insight-card h3 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 18px;
}

.campaign-detail-insight-card p {
  margin: 12px 0 18px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
  line-height: 1.7;
  position: relative;
  z-index: 1;
}

.campaign-detail-insight-card button {
  width: 100%;
  min-height: 42px;
  border: 0;
  border-radius: 12px;
  background: #fff;
  color: var(--accent);
  font-weight: 700;
  position: relative;
  z-index: 1;
}

@media (max-width: 1180px) {
  .campaign-detail-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .campaign-detail-timeline-card,
  .campaign-detail-preview-card,
  .campaign-detail-recipients-card,
  .campaign-detail-side-stack {
    grid-column: span 12;
  }
}

@media (max-width: 900px) {
  .campaign-detail-header,
  .campaign-detail-header-actions,
  .campaign-detail-table-footer,
  .campaign-detail-inline-tools,
  .campaign-detail-edit-actions {
    flex-direction: column;
    align-items: stretch;
  }
}

@media (max-width: 720px) {
  .campaign-detail-kpi-grid {
    grid-template-columns: 1fr;
  }

  .campaign-detail-heading-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .campaign-detail-edit-grid {
    grid-template-columns: 1fr;
  }
}

.contacts-directory-page,
.contact-detail-page {
  display: grid;
  gap: 24px;
}

.contacts-directory-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.contacts-directory-header h1,
.contact-detail-hero-title h1 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 32px;
  line-height: 1.15;
  color: #151e16;
}

.contacts-directory-header p,
.contact-detail-hero p {
  margin: 8px 0 0;
  color: #64748b;
  font-size: 16px;
}

.contacts-directory-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.contacts-primary-button,
.contacts-secondary-button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.contacts-primary-button {
  border: 0;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 12px 28px rgba(0, 109, 47, 0.18);
}

.contacts-secondary-button {
  border: 1px solid rgba(187, 203, 185, 0.85);
  background: #fff;
  color: #475569;
}

.contacts-filter-bar,
.contacts-table-card,
.contact-detail-card,
.contact-detail-history-card,
.contact-detail-hero {
  border-radius: 22px;
  border: 1px solid rgba(220, 229, 216, 0.7);
  background: #fff;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.contacts-filter-bar {
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.contacts-filter-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.contacts-filter-input,
.contacts-filter-select,
.contacts-form-field input,
.contacts-form-field textarea {
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  background: #edf6e9;
  color: #151e16;
  padding: 0 14px;
}

.contacts-filter-input {
  min-width: 220px;
  flex: 1 1 220px;
}

.contacts-filter-select {
  padding-right: 34px;
}

.contacts-clear-button {
  margin-left: auto;
  border: 0;
  background: transparent;
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.contacts-table-wrap {
  overflow-x: auto;
}

.contacts-table {
  width: 100%;
  border-collapse: collapse;
}

.contacts-table thead {
  background: rgba(237, 246, 233, 0.65);
}

.contacts-table th,
.contacts-table td {
  padding: 18px 24px;
  text-align: left;
  border-bottom: 1px solid rgba(220, 229, 216, 0.5);
}

.contacts-table th {
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contacts-table tbody tr:hover {
  background: rgba(237, 246, 233, 0.35);
}

.contacts-contact-cell {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.contacts-contact-cell span:last-child {
  display: grid;
  gap: 3px;
}

.contacts-contact-cell strong {
  color: #151e16;
}

.contacts-contact-cell small {
  color: #64748b;
  font-size: 12px;
}

.contacts-avatar,
.contact-detail-hero-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(37, 211, 102, 0.12);
  color: var(--accent);
  font-weight: 800;
}

.contacts-avatar {
  width: 42px;
  height: 42px;
}

.contacts-mono-cell {
  font-family: "JetBrains Mono", monospace;
}

.contacts-status-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.contacts-status-chip.is-active {
  background: rgba(37, 211, 102, 0.12);
  color: #16a34a;
}

.contacts-status-chip.is-inactive {
  background: rgba(60, 74, 61, 0.1);
  color: #3c4a3d;
}

.contacts-tags-inline {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.contacts-tags-inline.is-wrap {
  margin-top: 6px;
}

.contacts-tag-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 8px;
  background: rgba(140, 241, 225, 0.3);
  color: #006f64;
  font-size: 11px;
  font-weight: 700;
}

.contacts-table-actions {
  text-align: right;
}

.contacts-icon-button {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #64748b;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
}

.contacts-table-footer {
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: rgba(237, 246, 233, 0.35);
}

.contacts-table-footer,
.contacts-table-footer span,
.contacts-table-footer div,
.contacts-rows-label span {
  color: #64748b;
  font-size: 14px;
}

.contacts-table-footer strong {
  color: #151e16;
}

.contacts-pagination {
  display: flex;
  align-items: center;
  gap: 6px;
}

.contacts-page-button {
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid rgba(187, 203, 185, 0.85);
  background: #fff;
  color: #3c4a3d;
  font-weight: 700;
  cursor: pointer;
}

.contacts-page-button.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.contacts-page-button:disabled {
  opacity: 0.5;
  cursor: default;
}

.contacts-page-gap {
  padding: 0 3px;
  color: #64748b;
}

.contacts-rows-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.contacts-rows-label select {
  border: 0;
  background: transparent;
  color: #151e16;
}

.contacts-fab {
  position: fixed;
  right: 40px;
  bottom: 40px;
  width: 56px;
  height: 56px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 16px 34px rgba(0, 109, 47, 0.22);
  cursor: pointer;
}

.contacts-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(12, 16, 12, 0.36);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.contacts-modal-card {
  width: min(100%, 860px);
  border-radius: 24px;
  background: #fff;
  border: 1px solid rgba(220, 229, 216, 0.7);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.16);
  padding: 24px;
}

.contacts-modal-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.contacts-modal-head p {
  margin: 0 0 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contacts-modal-head h2 {
  margin: 0;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 28px;
  line-height: 1.2;
}

.contacts-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.contacts-form-field {
  display: grid;
  gap: 8px;
}

.contacts-form-field span,
.contacts-checkbox-row span {
  color: #3c4a3d;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.contacts-form-field textarea {
  min-height: 120px;
  padding: 14px;
  resize: vertical;
}

.contacts-form-field.is-full,
.contacts-checkbox-row.is-full,
.contacts-form-error {
  grid-column: 1 / -1;
}

.contacts-checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.contacts-form-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

.contacts-form-error {
  margin: 0;
  color: #b91c1c;
  font-size: 14px;
  font-weight: 600;
}

.contacts-form-success {
  margin: 0;
  color: #15803d;
  font-size: 14px;
  font-weight: 600;
}

.contact-detail-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #64748b;
  font-size: 14px;
}

.contact-detail-breadcrumb a {
  color: inherit;
  text-decoration: none;
}

.contact-detail-breadcrumb span:last-child {
  color: var(--accent);
  font-weight: 700;
}

.contact-detail-hero {
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.contact-detail-hero-main,
.contact-detail-hero-actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

.contact-detail-hero-avatar {
  width: 96px;
  height: 96px;
  position: relative;
  font-size: 28px;
}

.contact-detail-hero-avatar i {
  position: absolute;
  right: 6px;
  bottom: 6px;
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #25d366;
  border: 3px solid #fff;
}

.contact-detail-hero-title {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.contact-detail-hero-title span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  background: #e7f1e4;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.contact-detail-danger-icon,
.contact-detail-delete-button {
  border: 0;
  cursor: pointer;
}

.contact-detail-danger-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: rgba(255, 218, 214, 0.55);
  color: #ba1a1a;
}

.contact-detail-grid {
  display: grid;
  grid-template-columns: 4fr 8fr;
  gap: 24px;
}

.contact-detail-sidebar {
  display: grid;
  gap: 24px;
  align-content: start;
}

.contact-detail-card,
.contact-detail-history-card {
  padding: 24px;
}

.contact-detail-card h2,
.contact-detail-history-card h2 {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: "Plus Jakarta Sans", "Segoe UI", sans-serif;
  font-size: 18px;
}

.contact-detail-info-list {
  display: grid;
  gap: 22px;
  margin-top: 24px;
}

.contact-detail-info-list label {
  display: block;
  margin-bottom: 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.contact-detail-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.contact-detail-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.contact-detail-card-head button {
  border: 0;
  background: transparent;
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
}

.contact-detail-notes {
  display: grid;
  gap: 14px;
}

.contact-note-card {
  border-radius: 16px;
  background: #edf6e9;
  padding: 16px;
}

.contact-note-card.is-emphasized {
  border-left: 4px solid var(--accent);
}

.contact-note-card p {
  margin: 0 0 12px;
  line-height: 1.7;
}

.contact-note-card div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.contact-detail-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.contact-detail-tabs button {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
}

.contact-detail-tabs button.is-active {
  background: #e7f1e4;
  color: #3c4a3d;
}

.contact-history-timeline {
  position: relative;
  margin-left: 8px;
  display: grid;
  gap: 26px;
}

.contact-history-timeline::before {
  content: "";
  position: absolute;
  left: 11px;
  top: 4px;
  bottom: 4px;
  width: 2px;
  background: #dce5d8;
}

.contact-history-item {
  position: relative;
  padding-left: 40px;
}

.contact-history-icon {
  position: absolute;
  left: 0;
  top: 2px;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: #e7f1e4;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 4px solid #fff;
  z-index: 1;
}

.contact-history-icon .material-symbols-outlined {
  font-size: 14px;
}

.contact-history-title {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.contact-history-title span,
.contact-history-body p + small {
  color: #64748b;
  font-size: 12px;
}

.contact-history-body p {
  margin: 8px 0 0;
  color: #475569;
  line-height: 1.7;
}

.contact-detail-delete-button {
  min-height: 46px;
  padding: 0 18px;
  border-radius: 12px;
  background: rgba(255, 218, 214, 0.55);
  color: #b91c1c;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

@media (max-width: 1180px) {
  .contact-detail-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .contacts-directory-header,
  .contacts-table-footer,
  .contact-detail-hero,
  .contact-detail-hero-actions,
  .contact-detail-card-head {
    flex-direction: column;
    align-items: stretch;
  }

  .contacts-clear-button {
    margin-left: 0;
  }

  .contacts-form-grid {
    grid-template-columns: 1fr;
  }
}
