*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  font-family: var(--font-sans);
  background: var(--color-background);
  color: var(--color-primary);
  font-size: 15px;
  line-height: 1.4;
}

button {
  font: inherit;
  border: none;
  cursor: pointer;
  background: none;
  color: inherit;
}

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

input {
  font: inherit;
  color: inherit;
}

ul {
  list-style: none;
}

h1,
h2,
h3,
h4 {
  font-weight: 700;
  line-height: 1.2;
}

/* login.html reuses this same stylesheet */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 20%, rgba(229, 35, 27, 0.06), transparent 45%),
    radial-gradient(circle at 80% 80%, rgba(28, 29, 32, 0.05), transparent 45%),
    var(--color-background);
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  background: var(--color-surface);
  padding: var(--space-xl) var(--space-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
  width: 360px;
}

.login-form h1 {
  color: var(--color-primary);
  font-size: 22px;
  letter-spacing: -0.01em;
  margin-bottom: var(--space-sm);
}

.login-form h1::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: var(--color-accent);
  margin-right: var(--space-sm);
}

.login-form input {
  padding: 12px var(--space-md);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface-raised);
  transition: border-color .15s, box-shadow .15s;
}

.login-form input:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-soft);
  background: var(--color-surface);
}

.login-form button {
  padding: 12px;
  margin-top: var(--space-xs);
  background: var(--color-accent);
  color: #fff;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: background .15s, transform .05s;
}

.login-form button:hover {
  background: var(--color-accent-dark);
}

.login-form button:active {
  transform: scale(0.99);
}

.login-error {
  background: rgba(185, 28, 28, 0.1);
  color: #b91c1c;
  padding: 10px var(--space-md);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
}

/* header */
#app_header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  padding: var(--space-md) var(--space-lg);
  position: sticky;
  top: 0;
  z-index: 100;
}

#app_title {
  color: var(--color-primary);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

#app_title::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--color-accent);
  margin-right: var(--space-sm);
}

#app_nav {
  display: flex;
  gap: var(--space-xs);
}

.nav-link {
  color: var(--color-secondary);
  font-weight: 600;
  font-size: 14px;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  transition: background .15s, color .15s;
}

.nav-link:hover {
  color: var(--color-primary);
  background: var(--color-surface-raised);
}

.nav-link.active {
  color: var(--color-accent);
  background: var(--color-accent-soft);
}

#btn_logout {
  color: var(--color-secondary);
  font-weight: 600;
  font-size: 14px;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  transition: background .15s, color .15s;
}

#btn_logout:hover {
  color: var(--color-danger);
  background: var(--color-danger-soft);
}

/* app shell (sidebar layout) */
.app-shell {
  display: flex;
  min-height: calc(100vh - var(--wa-banner-h, 0px));
}

.app-sidebar {
  width: 220px;
  flex: 0 0 220px;
  background: var(--color-surface);
  border-right: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  padding: var(--space-lg) var(--space-md);
  gap: var(--space-lg);
  position: sticky;
  top: var(--wa-banner-h, 0px);
  height: calc(100vh - var(--wa-banner-h, 0px));
}

.app-sidebar-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.app-sidebar-title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--color-primary);
  white-space: nowrap;
}

.app-sidebar-title::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--color-accent);
  margin-right: var(--space-sm);
}

.sidebar-collapse-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  color: var(--color-secondary);
  border-radius: var(--radius-sm);
  transition: background .15s, color .15s;
}

.sidebar-collapse-btn:hover {
  color: var(--color-primary);
  background: var(--color-surface-raised);
}

.sidebar-collapse-btn svg {
  transition: transform .15s;
}

.app-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  flex: 1;
}

.sidebar-link,
.sidebar-logout {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  color: var(--color-secondary);
  font-weight: 600;
  font-size: 14px;
  padding: 10px var(--space-md);
  border-radius: var(--radius-sm);
  transition: background .15s, color .15s;
}

.sidebar-link:hover {
  color: var(--color-primary);
  background: var(--color-surface-raised);
}

.sidebar-link.active {
  color: var(--color-accent);
  background: var(--color-accent-soft);
}

.sidebar-link-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.sidebar-link-text {
  white-space: nowrap;
  overflow: hidden;
}

.sidebar-logout {
  align-self: stretch;
}

.sidebar-logout:hover {
  color: var(--color-danger);
  background: var(--color-danger-soft);
}

.app-content {
  flex: 1;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

/* sidebar collapsed state */
.app-sidebar.collapsed {
  width: 64px;
  flex: 0 0 64px;
}

.app-sidebar.collapsed .app-sidebar-title,
.app-sidebar.collapsed .sidebar-link-text {
  display: none;
}

.app-sidebar.collapsed .app-sidebar-brand {
  justify-content: center;
}

.app-sidebar.collapsed .sidebar-link,
.app-sidebar.collapsed .sidebar-logout {
  justify-content: center;
}

.app-sidebar.collapsed .sidebar-collapse-btn svg {
  transform: rotate(180deg);
}

.app-sidebar.collapsed .app-sidebar-status {
  display: flex;
  justify-content: center;
  padding: 0;
}

.app-sidebar.collapsed .whatsapp-badge {
  padding: 0;
  gap: 0;
}

.app-sidebar.collapsed .whatsapp-badge-text {
  display: none;
}

.whatsapp-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
}

.whatsapp-badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 auto;
}

.whatsapp-badge-ok {
  background: rgba(22, 163, 74, 0.15);
  color: #16a34a;
}

.whatsapp-badge-off {
  background: rgba(185, 28, 28, 0.15);
  color: #b91c1c;
}

.whatsapp-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  padding: 10px var(--space-md);
  background: #b91c1c;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
}

.whatsapp-banner[hidden] {
  display: none;
}

.whatsapp-banner-btn {
  background: #fff;
  color: #b91c1c;
  padding: 4px 12px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

/* config subsidebar (configuracoes.html) */
.config-shell {
  display: flex;
  flex: 1;
  min-width: 0;
  min-height: 0;
}

.config-subsidebar {
  width: 180px;
  flex: 0 0 180px;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  padding: var(--space-lg) var(--space-md);
  border-right: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  overflow-y: auto;
}

.config-tab {
  text-align: left;
  color: var(--color-secondary);
  font-weight: 600;
  font-size: 14px;
  padding: 10px var(--space-md);
  border-radius: var(--radius-sm);
  transition: background .15s, color .15s;
}

.config-tab:hover {
  color: var(--color-primary);
  background: var(--color-surface-raised);
}

.config-tab.active {
  color: var(--color-accent);
  background: var(--color-accent-soft);
}

.config-panels {
  flex: 1;
  min-width: 0;
  margin: 0;
  padding: var(--space-lg);
}

/* main / views */
#app_main {
  height: 100%;
  min-height: 0;
  padding: var(--space-xs);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.settings-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

.view {
  display: none;
}

.view.active {
  display: block;
  height: 100%;
}

/* lists (shared list/row/col pattern) */
#leads_list,
#conf_list {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
}

.row-header {
  background: var(--color-surface-raised);
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-secondary);
}

.row-header,
.row {
  display: flex;
  align-items: center;
  padding: 14px var(--space-md);
  border-bottom: 1px solid var(--color-border);
  gap: var(--space-md);
}

.row:last-child {
  border-bottom: none;
}

.row {
  font-size: 14px;
  transition: background .1s;
}

.row:hover {
  background: var(--color-surface-raised);
  cursor: pointer;
}

.col {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.col-nome,
.col-lead {
  flex: 2;
  font-weight: 600;
}

.col-telefone {
  color: var(--color-secondary);
  font-variant-numeric: tabular-nums;
}

.col-classificacao,
.col-score,
.col-gatilho,
.col-acao {
  flex: 0 0 110px;
  text-align: center;
}

.col-data {
  flex: 0 0 140px;
  color: var(--color-secondary);
  font-size: 13px;
  text-align: right;
}

.empty-msg {
  color: var(--color-muted);
  padding: var(--space-xl);
  text-align: center;
  font-size: 14px;
}

/* badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.badge-a {
  background: var(--color-success-soft);
  color: var(--color-success);
}

.badge-b {
  background: var(--color-warning-soft);
  color: var(--color-warning);
}

.badge-c {
  background: var(--color-danger-soft);
  color: var(--color-danger);
}

.badge-gatilho {
  background: var(--color-accent-soft);
  color: var(--color-accent-dark);
}

.badge-score {
  background: var(--color-surface-raised);
  color: var(--color-primary);
  border: 1px solid var(--color-border);
}

/* confirmation queue row */
.conf-valor-input {
  padding: var(--space-xs) var(--space-sm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  width: 100%;
  background: var(--color-surface-raised);
  transition: border-color .15s, box-shadow .15s;
}

.conf-valor-input:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-soft);
  background: var(--color-surface);
}

.btn-save {
  background: var(--color-accent);
  color: #fff;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 13px;
  transition: background .15s;
}

.btn-save:hover {
  background: var(--color-accent-dark);
}

.btn-save:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-remove {
  background: #d9534f;
  color: #fff;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 13px;
  transition: background .15s;
}

.btn-remove:hover {
  background: #c9302c;
}

.btn-remove:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: var(--color-overlay);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 400;
  padding: var(--space-md);
  backdrop-filter: blur(2px);
}

.modal-overlay[hidden] {
  display: none;
}

.modal {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: var(--space-lg);
  width: 480px;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.modal-close {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  font-size: 18px;
  line-height: 1;
  color: var(--color-secondary);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s, color .15s;
}

.modal-close:hover {
  color: var(--color-primary);
  background: var(--color-surface-raised);
}

#modal_nome {
  font-size: 20px;
  padding-right: var(--space-xl);
}

.modal-sub {
  color: var(--color-secondary);
  font-size: 14px;
  margin-top: -12px;
}

.modal-badges {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.modal-section {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  border-top: 1px solid var(--color-border);
  padding-top: var(--space-md);
}

.modal-section h4 {
  font-size: 12px;
  color: var(--color-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.field-list {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-sm) var(--space-md);
  font-size: 14px;
}

.field-list dt {
  color: var(--color-secondary);
}

.field-list dd {
  font-weight: 500;
  text-align: right;
}

.modal-section label {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  font-size: 13px;
  color: var(--color-secondary);
  font-weight: 600;
}

.modal-section input[type="number"] {
  padding: var(--space-sm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface-raised);
  transition: border-color .15s, box-shadow .15s;
}

.modal-section input[type="number"]:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-soft);
  background: var(--color-surface);
}

.btn-primary {
  background: var(--color-accent);
  color: #fff;
  padding: 10px var(--space-md);
  border-radius: var(--radius-sm);
  font-weight: 600;
  align-self: flex-start;
  transition: background .15s;
}

.btn-primary:hover {
  background: var(--color-accent-dark);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.interacoes-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  max-height: 200px;
  overflow-y: auto;
  font-size: 13px;
}

.interacoes-list li {
  padding: var(--space-sm);
  background: var(--color-surface-raised);
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
}

/* settings (Configurações) */
.settings-page {
  /* max-width: 900px; */
  margin: 0 auto;
  width: 100%;
}

.settings-section {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  overflow: hidden;
}

.settings-section+.settings-section {
  margin-top: var(--space-lg);
}

.config-panels .settings-section {
  display: none;
  margin-top: 0;
}

.config-panels .settings-section.active {
  display: block;
}

.settings-section-header {
  padding: var(--space-md);
  border-bottom: 1px solid var(--color-border);
  margin: 0 0 var(--space-md) 0;
}

.settings-section-header h3 {
  font-size: 17px;
  letter-spacing: -0.01em;
}

.settings-section-header h3::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--color-accent);
  margin-right: var(--space-sm);
}

.settings-section-header p {
  color: var(--color-secondary);
  font-size: 13px;
  margin-top: var(--space-xs);
}

.settings-body {
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--space-md);
}

.field {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

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

.field label {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.field input,
.field select,
.field textarea {
  padding: 10px var(--space-md);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface-raised);
  font-size: 14px;
  font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
}

.field textarea {
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-soft);
  background: var(--color-surface);
}

.field input:disabled {
  color: var(--color-muted);
  cursor: not-allowed;
}

.score-group {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  background: var(--color-surface-raised);
}

.score-group h4 {
  font-size: 12px;
  color: var(--color-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-sm);
}

.score-group .field-grid {
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: var(--space-sm);
}

.score-group .field label {
  font-size: 11px;
}

.score-group .field input {
  background: var(--color-surface);
  padding: var(--space-sm);
}

.settings-actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.settings-msg {
  font-size: 13px;
  font-weight: 600;
}

.settings-msg-ok {
  color: var(--color-success);
}

.settings-msg-error {
  color: var(--color-danger);
}

.evolution-connect {
  padding: var(--space-md) var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  align-self: flex-start;
}

#evolution_qr_wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

#evolution_qr_wrap[hidden] {
  display: none;
}

#evolution_qr_img {
  width: 220px;
  height: 220px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

#evolution_status_msg {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-secondary);
}

.corretores-list {
  list-style: none;
  padding: 0 var(--space-lg) var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.corretor-item {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.corretor-item input {
  flex: 1;
  background: var(--color-surface);
  padding: var(--space-sm);
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
}

.corretor-page {
  max-width: 480px;
  margin: 60px auto;
  padding: var(--space-lg);
  text-align: center;
}

.corretor-page .evolution-connect {
  align-items: center;
}

.corretor-page .btn-primary {
  align-self: center;
}

/* pro-table (lista profissional: corretores, instancias) */
.pro-table {
  display: flex;
  flex-direction: column;
  margin: 0 var(--space-md) var(--space-md);
  background: var(--color-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
}

.pro-table-row {
  display: flex;
  align-items: center;
  padding: 12px var(--space-md);
  border-bottom: 1px solid var(--color-border);
  gap: var(--space-md);
}

.pro-table-row:last-child {
  border-bottom: none;
}

.pro-table-head {
  background: var(--color-surface-raised);
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-secondary);
}

.pro-table-col {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pro-table-col-nome {
  flex: 2;
  font-weight: 600;
}

.pro-table-col-numero {
  color: var(--color-secondary);
  font-variant-numeric: tabular-nums;
}

.pro-table-col-acao {
  flex: 0 0 140px;
  text-align: center;
  overflow: visible;
  white-space: normal;
}

.pro-table-col-acao .btn-save {
  align-self: center;
}

.audio-corretor-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.audio-corretor-actions[hidden] {
  display: none;
}

.btn-play-audio-corretor {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.audio-preview-corretor {
  width: 140px;
  height: 32px;
}

.audio-preview-corretor[hidden] {
  display: none;
}

.pro-table-empty {
  padding: var(--space-lg);
  text-align: center;
  color: var(--color-secondary);
  font-size: 13px;
}

/* footer */
#app_footer {
  color: var(--color-muted);
  padding: var(--space-lg) var(--space-md);
  text-align: center;
  font-size: 12px;
}

/* responsivo */
@media (max-width: 900px) {
  #app_header {
    padding: var(--space-sm) var(--space-md);
    flex-wrap: wrap;
    gap: var(--space-sm);
  }

  #app_nav {
    order: 3;
    width: 100%;
    justify-content: center;
  }

  #app_main {
    padding: var(--space-md);
  }

  .col-gatilho,
  .col-data {
    display: none;
  }

  .col-classificacao,
  .col-score {
    flex: 0 0 80px;
  }

  .app-shell {
    flex-direction: column;
  }

  .app-sidebar {
    width: 100%;
    flex: 0 0 auto;
    height: auto;
    position: static;
    flex-direction: row;
    align-items: center;
    padding: var(--space-sm) var(--space-md);
  }

  .app-sidebar-nav {
    flex-direction: row;
  }

  .config-shell {
    flex-direction: column;
  }

  .config-subsidebar {
    width: 100%;
    flex: 0 0 auto;
    flex-direction: row;
    position: static;
    height: auto;
    overflow-x: auto;
    overflow-y: visible;
    border-right: none;
    border-bottom: 1px solid var(--color-border);
    padding: var(--space-sm) var(--space-md);
  }
}

@media (max-width: 640px) {
  #app_header {
    justify-content: center;
    text-align: center;
  }

  #btn_logout {
    position: absolute;
    right: var(--space-md);
    top: var(--space-sm);
  }

  #app_header {
    position: relative;
  }

  .row-header {
    display: none;
  }

  .row {
    flex-wrap: wrap;
    gap: var(--space-xs) var(--space-md);
    padding: var(--space-md);
  }

  .col {
    flex: 1 1 auto;
    white-space: normal;
  }

  .col-nome,
  .col-lead {
    flex: 1 1 100%;
    font-size: 15px;
  }

  .col-classificacao,
  .col-score,
  .col-gatilho,
  .col-acao,
  .col-data {
    flex: 0 0 auto;
    text-align: left;
  }

  .col-telefone {
    flex: 1 1 auto;
  }

  .modal {
    width: 100%;
    max-width: 420px;
    padding: var(--space-md);
  }

  .login-form {
    width: 100%;
    max-width: 340px;
  }

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

  .field-list dd {
    text-align: left;
  }
}

@media (max-width: 400px) {
  .login-form {
    padding: var(--space-lg) var(--space-md);
  }
}