/* ============================================================
   VARIÁVEIS
   ============================================================ */
:root {
  --primary:       #7C3AED;
  --primary-light: #A78BFA;
  --secondary:     #EC4899;
  --sidebar-bg:    #0F0D2A;
  --sidebar-hover: rgba(167,139,250,0.1);
  --sidebar-active:rgba(167,139,250,0.18);
  --bg:      #F5F3FF;
  --card:    #FFFFFF;
  --border:  #E5E7EB;
  --divider: #F3F4F6;
  --text:       #111827;
  --text-md:    #374151;
  --text-muted: #6B7280;
  --text-light: #9CA3AF;
  --success: #10B981;
  --warning: #F59E0B;
  --danger:  #EF4444;
  --info:    #3B82F6;
  /* Fluxo */
  --s-informacoes:         #6366F1;
  --s-briefing:            #3B82F6;
  --s-a-criar:             #F59E0B;
  --s-em-criacao:          #F97316;
  --s-em-revisao:          #8B5CF6;
  --s-em-aprovacao:        #EC4899;
  --s-agendar:             #06B6D4;
  --s-concluido:           #10B981;
  --s-aguardando-info:     #EF4444;
  --s-aguardando-captacao: #B45309;
  --s-criar-demanda:       #7C3AED;
  --s-alterar-copy:        #DC2626;
  --s-alterar-arte:        #D97706;
  --s-enviar-grafica:      #0891B2;
  --s-formulario-cliente:  #A78BFA;
  /* Trafego */
  --s-configurar: #7C3AED;
  --s-rodando:    #10B981;
  /* CRM */
  --crm-lead-frio:          #9CA3AF;
  --crm-primeiro-contato:   #3B82F6;
  --crm-aguardando-resposta:#F59E0B;
  --crm-em-negociacao:      #F97316;
  --crm-proposta-enviada:   #8B5CF6;
  --crm-fechado:            #10B981;
  --crm-perdido:            #EF4444;
  --sidebar-w: 288px;
  --sidebar-color: #0F0D2A;
  --btn-grad-from: #7C3AED;
  --btn-grad-to:   #6D28D9;
  --topbar-h:  64px;
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.06);
  --shadow-sm: 0 1px 6px rgba(0,0,0,0.08);
  --shadow:    0 4px 16px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.16);
  --r:    10px; --r-sm: 6px; --r-lg: 16px;
  --t: 0.18s ease;
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { font-family: var(--font-family); font-size: 14px; line-height: 1.5; background: var(--bg); color: var(--text); height: 100%; overflow: hidden; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 14px; }

/* ============================================================
   LOGIN
   ============================================================ */
.login-screen {
  position: fixed; inset: 0; z-index: 9999;
  background: linear-gradient(135deg, #0F0D2A 0%, #1a1040 50%, #14103a 100%);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.login-bg-shape {
  position: absolute; border-radius: 50%;
  background: linear-gradient(135deg, rgba(124,58,237,0.2), rgba(236,72,153,0.1));
  filter: blur(60px);
}
.shape-1 { width: 500px; height: 500px; top: -100px; right: -100px; }
.shape-2 { width: 400px; height: 400px; bottom: -100px; left: -80px; background: linear-gradient(135deg, rgba(6,182,212,0.15), rgba(124,58,237,0.1)); }
.login-card {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  backdrop-filter: blur(24px);
  border-radius: 24px;
  padding: 48px 40px;
  width: 100%; max-width: 420px;
  box-shadow: 0 25px 60px rgba(0,0,0,0.5);
  position: relative; z-index: 1;
}
.login-logo { text-align: center; margin-bottom: 36px; }
.login-logo-mark {
  width: 64px; height: 64px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 18px; font-size: 30px; font-weight: 800; color: #fff;
  display: inline-flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.login-logo h1 { color: #fff; font-size: 22px; font-weight: 800; margin-bottom: 4px; }
.login-logo p  { color: rgba(255,255,255,0.45); font-size: 13px; }
.login-label { color: rgba(255,255,255,0.7) !important; }
.login-input-wrap { position: relative; }
.login-input-wrap > i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: rgba(255,255,255,0.4); font-size: 14px; pointer-events: none; }
.login-input {
  background: rgba(255,255,255,0.08) !important;
  border-color: rgba(255,255,255,0.15) !important;
  color: #fff !important;
  padding-left: 38px !important;
  padding-right: 40px !important;
}
.login-input::placeholder { color: rgba(255,255,255,0.3) !important; }
.login-input:focus { border-color: var(--primary-light) !important; box-shadow: 0 0 0 3px rgba(167,139,250,0.2) !important; }
.login-toggle-pw { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); color: rgba(255,255,255,0.55); background: none; border: none; cursor: pointer; padding: 4px; z-index: 2; }
.login-remember { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
.checkbox-label { display: flex; align-items: center; gap: 8px; color: rgba(255,255,255,0.5); font-size: 13px; cursor: pointer; }
.checkbox-label input { width: 15px; height: 15px; cursor: pointer; }
.login-error { background: rgba(239,68,68,0.15); border: 1px solid rgba(239,68,68,0.3); border-radius: var(--r-sm); padding: 10px 12px; color: #FCA5A5; font-size: 13px; display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.login-btn { width: 100%; justify-content: center; padding: 12px; font-size: 15px; margin-top: 4px; }

/* ============================================================
   LAYOUT
   ============================================================ */
.app { display: flex; height: 100vh; overflow: hidden; }
.sidebar {
  width: var(--sidebar-w); min-width: var(--sidebar-w);
  background: var(--sidebar-color, var(--sidebar-bg));
  display: flex; flex-direction: column; overflow: hidden;
  transition: width var(--t), min-width var(--t); z-index: 100;
}
.sidebar.collapsed { width: 62px; min-width: 62px; }
.sidebar.collapsed .logo-text, .sidebar.collapsed .nav-link span:not(.nav-badge),
.sidebar.collapsed .sidebar-section-label, .sidebar.collapsed .team-member-name,
.sidebar.collapsed .team-member-role { display: none; }
.sidebar.collapsed .nav-link { justify-content: center; padding: 10px; }
.sidebar.collapsed .sidebar-team { padding: 10px 6px; }
.sidebar.collapsed .team-member { justify-content: center; }

.sidebar-logo { display: flex; align-items: center; gap: 12px; padding: 18px 16px; border-bottom: 1px solid rgba(255,255,255,0.06); }
.logo-mark { width: 34px; height: 34px; min-width: 34px; background: linear-gradient(135deg,var(--primary),var(--secondary)); border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 800; color: #fff; }
.logo-brand { display: block; color: #fff; font-size: 13.5px; font-weight: 700; white-space: normal; line-height: 1.25; max-width: 180px; }
.logo-sub   { display: block; color: rgba(255,255,255,0.35); font-size: 10.5px; }

.sidebar-nav { flex: 1; padding: 10px 8px; display: flex; flex-direction: column; gap: 1px; overflow-y: auto; }
.nav-divider { height: 1px; background: rgba(255,255,255,0.07); margin: 6px 4px; }
.nav-link { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: var(--r-sm); color: rgba(255,255,255,0.5); font-size: 13px; font-weight: 500; transition: all var(--t); position: relative; white-space: nowrap; }
.nav-link:hover { color: #fff; background: var(--sidebar-hover); }
.nav-link.active { color: #fff; background: var(--sidebar-active); }
.nav-link.active::before { content: ''; position: absolute; left: 0; top: 5px; bottom: 5px; width: 3px; background: var(--primary-light); border-radius: 0 3px 3px 0; }
.nav-crm { margin-top: 2px; }
.nav-crm.active::before { background: #F59E0B; }
.nav-link i { width: 16px; text-align: center; font-size: 14px; }
.nav-badge { margin-left: auto; background: var(--danger); color: #fff; font-size: 10px; font-weight: 700; min-width: 18px; height: 18px; border-radius: 9px; padding: 0 5px; display: flex; align-items: center; justify-content: center; }
.nav-badge-gold { background: #D97706; }

.sidebar-team { padding: 10px 8px 14px; border-top: 1px solid rgba(255,255,255,0.06); }
.sidebar-section-label { font-size: 9.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.8px; color: rgba(255,255,255,0.28); padding: 0 4px 6px; }
.team-list { display: flex; flex-direction: column; gap: 1px; }
.team-member { display: flex; align-items: center; gap: 9px; padding: 5px 7px; border-radius: var(--r-sm); }
.team-avatar { width: 26px; height: 26px; min-width: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; color: #fff; }
.team-member-name { color: rgba(255,255,255,0.6); font-size: 12px; font-weight: 500; }
.team-member-role { color: rgba(255,255,255,0.28); font-size: 10.5px; }
.sidebar-presence-note { font-size: 9px; color: rgba(255,255,255,0.2); padding: 6px 7px 0; line-height: 1.4; }
.sidebar-presence-note i { opacity: 0.6; }

.main-wrapper { flex: 1; display: flex; flex-direction: column; overflow: hidden; min-width: 0; }

/* TOPBAR */
.topbar { height: var(--topbar-h); min-height: var(--topbar-h); background: var(--card); border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; padding: 0 22px; gap: 12px; }
.topbar-left  { display: flex; align-items: center; gap: 14px; }
.topbar-right { display: flex; align-items: center; gap: 10px; }
.hamburger { width: 34px; height: 34px; border-radius: var(--r-sm); color: var(--text-muted); display: flex; align-items: center; justify-content: center; transition: all var(--t); }
.hamburger:hover { background: var(--divider); color: var(--text); }
.page-title { font-size: 17px; font-weight: 700; }

/* User profile in topbar */
.user-profile-wrap { position: relative; }
.user-profile-btn {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 10px; border-radius: var(--r-sm);
  background: none; border: 1px solid var(--border);
  cursor: pointer; transition: all var(--t); font-size: 13.5px; font-weight: 600;
}
.user-profile-btn:hover { background: var(--divider); }
.user-topbar-avatar { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; color: #fff; }
.profile-dropdown {
  position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--r);
  box-shadow: var(--shadow-lg); min-width: 240px; z-index: 500; overflow: hidden;
  display: none;
}
.profile-dropdown.open { display: block; }
.profile-dropdown-info { display: flex; align-items: center; gap: 12px; padding: 16px; }
.profile-dropdown-avatar { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 15px; font-weight: 700; color: #fff; }
.profile-dropdown-info strong { display: block; font-size: 13.5px; }
.profile-dropdown-info small { color: var(--text-muted); font-size: 11.5px; }
.profile-dropdown-divider { height: 1px; background: var(--divider); }
.profile-dropdown-item { width: 100%; display: flex; align-items: center; gap: 10px; padding: 11px 16px; font-size: 13.5px; color: var(--text-md); font-weight: 500; transition: background var(--t); text-align: left; }
.profile-dropdown-item:hover { background: var(--divider); }
.profile-dropdown-item i { width: 16px; color: var(--text-muted); }
.profile-logout { color: var(--danger); }
.profile-logout i { color: var(--danger); }

.content { flex: 1; overflow-y: auto; padding: 22px; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 15px; border-radius: var(--r-sm); font-size: 13px; font-weight: 600; cursor: pointer; border: none; white-space: nowrap; transition: all var(--t); }
.btn-primary { background: linear-gradient(135deg, var(--btn-grad-from), var(--btn-grad-to)); color: #fff; box-shadow: 0 2px 8px rgba(124,58,237,0.35); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(124,58,237,0.4); }
.btn-ghost   { background: transparent; color: var(--text-muted); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--divider); color: var(--text); }
.btn-danger  { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #DC2626; }
.btn-trafego { background: linear-gradient(135deg,#10B981,#059669); color: #fff; box-shadow: 0 2px 8px rgba(16,185,129,0.35); }
.btn-trafego:hover { transform: translateY(-1px); }
.btn-sm { padding: 5px 11px; font-size: 12.5px; }
.btn-xs { padding: 3px 9px;  font-size: 11.5px; }
.icon-btn { width: 34px; height: 34px; border-radius: var(--r-sm); display: flex; align-items: center; justify-content: center; color: var(--text-muted); background: transparent; transition: all var(--t); position: relative; }
.icon-btn:hover { background: var(--divider); color: var(--text); }
.notif-dot { position: absolute; top: 5px; right: 5px; width: 7px; height: 7px; background: var(--danger); border-radius: 50%; border: 2px solid var(--card); }
.notif-badge { position: absolute; top: 1px; right: 1px; min-width: 17px; height: 17px; background: var(--danger); color: #fff; border-radius: 50px; border: 2px solid var(--card); display: flex; align-items: center; justify-content: center; font-size: 9px; font-weight: 700; padding: 0 3px; line-height: 1; pointer-events: none; }

/* ============================================================
   KANBAN
   ============================================================ */
.kanban-filters { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; background: var(--card); border: 1px solid var(--border); border-radius: var(--r); padding: 12px 16px; margin-bottom: 16px; }
.filter-input { padding: 6px 11px; border: 1px solid var(--border); border-radius: var(--r-sm); font-size: 13px; color: var(--text); background: var(--bg); outline: none; transition: border-color var(--t); }
.filter-input:focus { border-color: var(--primary); }
.filter-input.search { min-width: 180px; }
.kanban-board { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 12px; height: calc(100vh - 210px); align-items: flex-start; }
.kanban-board.fluxo-board  { height: calc(100vh - 336px); }
.kanban-board.trafego-board{ height: calc(100vh - 322px); }
.kanban-board.crm-board    { height: calc(100vh - 232px); }
.kanban-board.equipe-board { height: calc(100vh - 420px); min-height: 220px; }
.kanban-col { min-width: 280px; width: 280px; flex-shrink: 0; display: flex; flex-direction: column; height: 100%; }
.kanban-col.wide { min-width: 320px; width: 320px; }
.kanban-col.crm-col { min-width: 280px; width: 280px; }
.kanban-col-divider { min-width: 2px; width: 2px; background: var(--border); align-self: stretch; border-radius: 2px; flex-shrink: 0; }
.kanban-col-header { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border-radius: var(--r) var(--r) 0 0; color: #fff; font-weight: 700; font-size: 12px; }
.col-count { background: rgba(255,255,255,0.22); border-radius: 20px; padding: 1px 7px; font-size: 11px; }
.kanban-col-body { background: rgba(0,0,0,0.03); border: 1px solid var(--border); border-top: none; border-radius: 0 0 var(--r) var(--r); padding: 8px; flex: 1; display: flex; flex-direction: column; gap: 7px; overflow-y: auto; }

/* ============================================================
   TASK CARDS
   ============================================================ */
.task-card { background: var(--card); border-radius: var(--r-sm); border: 1px solid var(--border); padding: 10px; box-shadow: var(--shadow-xs); transition: box-shadow var(--t), transform var(--t); cursor: pointer; }
.task-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.task-card.can-trafego { border-left: 3px solid var(--success); }
.task-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 6px; margin-bottom: 7px; }
.task-card-client { font-size: 10.5px; font-weight: 700; padding: 2px 7px; border-radius: 20px; color: #fff; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-card-priority { font-size: 10.5px; font-weight: 600; padding: 2px 6px; border-radius: 20px; }
.priority-high   { background: #FEE2E2; color: #DC2626; }
.priority-medium { background: #FEF3C7; color: #D97706; }
.priority-low    { background: #D1FAE5; color: #059669; }
.task-card-title { font-size: 12.5px; font-weight: 600; color: var(--text); margin-bottom: 6px; line-height: 1.4; }
.task-card-type  { font-size: 11px; color: var(--text-muted); margin-bottom: 7px; }
.task-card-footer { display: flex; align-items: center; justify-content: space-between; }
.task-card-member { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--text-muted); }
.mini-avatar { border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; color: #fff; flex-shrink: 0; }
.mini-avatar-wrap { position: relative; display: inline-flex; flex-shrink: 0; }
.task-card-deadline { font-size: 10.5px; color: var(--text-muted); display: flex; align-items: center; gap: 3px; }
.task-card-deadline.overdue { color: var(--danger); font-weight: 600; }
.task-card-deadline.today   { color: var(--warning); font-weight: 600; }
.task-card-actions { display: flex; gap: 4px; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--divider); }
.task-card-attachments { display: flex; align-items: center; gap: 4px; margin-top: 6px; font-size: 10.5px; color: var(--text-muted); }
.trafego-hint { font-size: 10px; font-weight: 700; color: var(--success); display: flex; align-items: center; gap: 4px; margin-top: 6px; }

/* Campaign cards */
.campaign-card { background: var(--card); border-radius: var(--r-sm); border: 1px solid var(--border); padding: 14px; box-shadow: var(--shadow-xs); transition: box-shadow var(--t), transform var(--t); cursor: pointer; }
.campaign-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.campaign-card-header { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 10px; }
.campaign-type-icon { width: 36px; height: 36px; min-width: 36px; border-radius: var(--r-sm); display: flex; align-items: center; justify-content: center; font-size: 16px; color: #fff; }
.campaign-card-title  { font-size: 13px; font-weight: 700; margin-bottom: 2px; }
.campaign-card-client { font-size: 11.5px; color: var(--text-muted); }
.campaign-card-meta   { font-size: 11.5px; color: var(--text-muted); display: flex; gap: 12px; margin-bottom: 10px; }
.campaign-origin { font-size: 11px; color: var(--info); background: #EFF6FF; padding: 3px 8px; border-radius: 20px; font-weight: 600; }
.campaign-card-actions { display: flex; gap: 6px; padding-top: 10px; border-top: 1px solid var(--divider); }

/* ============================================================
   STATUS BADGES
   ============================================================ */
.status-badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 20px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.status-informacoes         { background: #EEF2FF; color: var(--s-informacoes); }
.status-briefing            { background: #EFF6FF; color: var(--s-briefing); }
.status-a-criar             { background: #FFFBEB; color: var(--s-a-criar); }
.status-em-criacao          { background: #FFF7ED; color: var(--s-em-criacao); }
.status-em-revisao          { background: #F5F3FF; color: var(--s-em-revisao); }
.status-em-aprovacao        { background: #FDF2F8; color: var(--s-em-aprovacao); }
.status-agendar             { background: #ECFEFF; color: var(--s-agendar); }
.status-concluido           { background: #ECFDF5; color: var(--s-concluido); }
.status-aguardando-info     { background: #FEF2F2; color: var(--s-aguardando-info); }
.status-aguardando-captacao { background: #FEF3C7; color: var(--s-aguardando-captacao); }
.status-configurar          { background: #F5F3FF; color: var(--s-configurar); }
.status-rodando             { background: #ECFDF5; color: var(--s-rodando); }

/* ============================================================
   RESPONSIBLE DISPLAY IN MODAL
   ============================================================ */
.responsible-display { padding: 8px 12px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm); min-height: 40px; display: flex; align-items: center; }
.responsible-auto { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-md); }
.responsible-auto small { color: var(--text-muted); font-size: 11px; }
.responsible-none { color: var(--text-light); font-size: 13px; font-style: italic; }

/* Task history */
.task-history { display: flex; flex-direction: column; gap: 6px; max-height: 140px; overflow-y: auto; padding: 8px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm); }
.history-item { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text-muted); }
.history-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.history-text strong { color: var(--text-md); font-weight: 600; }

/* ============================================================
   ATTACHMENTS
   ============================================================ */
.attachment-section { border: 1px solid var(--border); border-radius: var(--r-sm); overflow: hidden; }
.attachment-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 12px; background: var(--bg); }
.att-sep { color: var(--border); font-size: 18px; }
.att-url-input   { flex: 2; min-width: 140px; font-size: 12.5px; }
.att-label-input { flex: 1; min-width: 100px; font-size: 12.5px; }
.attachment-list { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 12px; min-height: 0; }
.attachment-list:empty { display: none; }
.att-img-item {
  position: relative; width: 72px; height: 72px;
  border-radius: var(--r-sm); overflow: hidden; border: 1px solid var(--border);
  flex-shrink: 0;
}
.att-img-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.att-img-actions {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0);
  display: flex; align-items: flex-start; justify-content: flex-end;
  gap: 2px; padding: 3px;
  opacity: 0; transition: opacity var(--t), background var(--t);
}
.att-img-item:hover .att-img-actions { opacity: 1; background: rgba(0,0,0,0.35); }
.att-action-btn {
  width: 20px; height: 20px; border-radius: 50%;
  background: rgba(0,0,0,0.65); color: #fff; border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 9px; flex-shrink: 0; line-height: 1;
  transition: background var(--t);
}
.att-action-btn:hover { background: rgba(0,0,0,0.9); }
.att-download-btn { background: rgba(16,185,129,0.8); }
.att-download-btn:hover { background: rgba(16,185,129,1); }
.att-img-remove { background: rgba(239,68,68,0.8); }
.att-img-remove:hover { background: rgba(239,68,68,1); }
.att-link-item {
  display: flex; align-items: center; gap: 7px;
  background: #EFF6FF; border: 1px solid #BFDBFE;
  border-radius: 20px; padding: 4px 8px 4px 8px;
  font-size: 12px; color: var(--info); font-weight: 600; max-width: 260px;
}
.att-link-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; min-width: 0; color: var(--info); }
.att-link-item a.att-link-name { color: var(--info); }
.att-link-item .att-download-btn {
  background: none; color: var(--success); font-size: 11px;
  width: auto; height: auto; border-radius: 0; padding: 0;
}
.att-link-item .att-download-btn:hover { background: none; color: #059669; }
.att-link-remove { color: var(--text-muted); cursor: pointer; font-size: 10px; background: none; border: none; padding: 0; line-height: 1; flex-shrink: 0; }
.card-att-preview { display: flex; gap: 4px; margin-top: 6px; flex-wrap: wrap; }
.card-att-thumb { width: 32px; height: 32px; border-radius: 4px; object-fit: cover; border: 1px solid var(--border); }
.card-att-link { font-size: 10px; color: var(--info); background: #EFF6FF; border-radius: 20px; padding: 2px 7px; display: flex; align-items: center; gap: 3px; font-weight: 600; }

/* ============================================================
   AGENDA
   ============================================================ */
.agenda-filters { display: flex; gap: 10px; margin-bottom: 20px; flex-wrap: wrap; align-items: center; }
.agenda-group { margin-bottom: 24px; }
.agenda-group-label { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.7px; color: var(--text-muted); margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.agenda-count { background: var(--divider); border-radius: 20px; padding: 1px 8px; font-size: 11px; }
.agenda-event-card { background: var(--card); border: 1px solid var(--border); border-left: 4px solid; border-radius: var(--r-sm); padding: 14px 16px; margin-bottom: 8px; display: flex; align-items: center; gap: 16px; transition: box-shadow var(--t), transform var(--t); cursor: pointer; }
.agenda-event-card:hover { box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.agenda-event-time { min-width: 50px; text-align: center; font-size: 14px; font-weight: 800; }
.agenda-event-time .time-label { font-size: 10px; color: var(--text-muted); font-weight: 400; }
.agenda-event-divider { width: 1px; height: 36px; background: var(--border); }
.agenda-event-main { flex: 1; min-width: 0; }
.agenda-event-title { font-size: 14px; font-weight: 700; margin-bottom: 3px; }
.agenda-event-meta  { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 12px; }
.agenda-event-participants { display: flex; gap: 4px; }
.agenda-event-actions { display: flex; gap: 6px; }
.agenda-type-selector { display: flex; gap: 8px; flex-wrap: wrap; }
.agenda-type-btn { flex: 1; min-width: 100px; padding: 9px 12px; border-radius: var(--r-sm); border: 1.5px solid var(--border); font-size: 12.5px; font-weight: 600; color: var(--text-muted); display: flex; align-items: center; justify-content: center; gap: 7px; cursor: pointer; transition: all var(--t); }
.agenda-type-btn.active { border-color: var(--primary); color: var(--primary); background: #F5F3FF; }
.participants-selector { display: flex; gap: 8px; flex-wrap: wrap; }
.participant-chip { display: flex; align-items: center; gap: 7px; padding: 6px 12px; border-radius: 50px; border: 1.5px solid var(--border); font-size: 12.5px; font-weight: 600; cursor: pointer; transition: all var(--t); color: var(--text-muted); }
.participant-chip input[type="checkbox"] { display: none; }
.participant-chip.selected { border-color: transparent; color: #fff; }

/* ============================================================
   MEU DIA
   ============================================================ */
.meu-dia-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.member-tab { display: flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 50px; border: 2px solid var(--border); background: var(--card); color: var(--text-muted); font-size: 13px; font-weight: 600; cursor: pointer; transition: all var(--t); }
.member-tab:hover { border-color: var(--primary); color: var(--primary); }
.member-tab.active { color: #fff; border-color: transparent; }
.day-section { margin-bottom: 22px; }
.day-section-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.6px; color: var(--text-muted); margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.ds-count { background: var(--divider); border-radius: 20px; padding: 1px 8px; font-size: 11px; color: var(--text-muted); }
.task-row { background: var(--card); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 12px 14px; display: flex; align-items: center; gap: 12px; margin-bottom: 7px; transition: box-shadow var(--t); }
.task-row:hover { box-shadow: var(--shadow-sm); }
.task-row.overdue  { border-left: 3px solid var(--danger); }
.task-row.today    { border-left: 3px solid var(--warning); }
.task-row.upcoming { border-left: 3px solid var(--info); }
.task-row-status { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.task-row-main { flex: 1; min-width: 0; }
.task-row-title { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task-row-meta { font-size: 11.5px; color: var(--text-muted); margin-top: 2px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.task-row-tab-tag { font-size: 10px; padding: 1px 7px; border-radius: 20px; font-weight: 700; }
.tab-tag-fluxo   { background: #F5F3FF; color: var(--primary); }
.tab-tag-trafego { background: #ECFDF5; color: var(--success); }
.task-row-actions { display: flex; gap: 5px; }

/* ============================================================
   DASHBOARD
   ============================================================ */
.stats-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 14px; margin-bottom: 22px; }
.stat-card { background: var(--card); border-radius: var(--r); border: 1px solid var(--border); padding: 18px; display: flex; align-items: center; gap: 14px; box-shadow: var(--shadow-xs); transition: transform var(--t), box-shadow var(--t); }
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.stat-icon { width: 46px; height: 46px; border-radius: var(--r); flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 20px; color: #fff; }
.stat-value { font-size: 26px; font-weight: 800; line-height: 1.1; }
.stat-label { font-size: 11.5px; color: var(--text-muted); margin-top: 2px; }
.grid-2     { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grid-60-40 { display: grid; grid-template-columns: 1.5fr 1fr; gap: 18px; }
.card { background: var(--card); border-radius: var(--r); border: 1px solid var(--border); box-shadow: var(--shadow-xs); }
.card-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--divider); }
.card-title  { font-size: 13.5px; font-weight: 700; }
.card-body   { padding: 16px 18px; }
.chart-container { position: relative; height: 220px; }
.recent-task-item { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--divider); cursor: pointer; }
.recent-task-item:last-child { border-bottom: none; }
.recent-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.recent-task-info { flex: 1; min-width: 0; }
.recent-task-title { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent-task-meta  { font-size: 11px; color: var(--text-muted); margin-top: 1px; }
.overdue-item { display: flex; align-items: center; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--divider); gap: 8px; }
.overdue-item:last-child { border-bottom: none; }
.overdue-task-name { font-size: 13px; font-weight: 600; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.overdue-task-client { font-size: 11px; color: var(--text-muted); }
.overdue-days { font-size: 11px; font-weight: 700; color: var(--danger); white-space: nowrap; }

/* ============================================================
   CLIENTES
   ============================================================ */
.section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.section-title  { font-size: 16px; font-weight: 700; }
.clients-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(270px,1fr)); gap: 14px; }
.client-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--r); overflow: hidden; transition: box-shadow var(--t), transform var(--t); cursor: pointer; }
.client-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.client-card-top  { height: 5px; }
.client-card-body { padding: 16px; }
.client-card-name    { font-size: 14.5px; font-weight: 700; margin-bottom: 3px; }
.client-card-segment { font-size: 12px; color: var(--text-muted); margin-bottom: 10px; }
.client-card-stats   { display: flex; gap: 14px; }
.client-stat { text-align: center; }
.client-stat-value { font-size: 18px; font-weight: 800; }
.client-stat-label { font-size: 10.5px; color: var(--text-muted); }
.client-card-footer { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; background: var(--divider); border-top: 1px solid var(--border); }
.client-detail-header { background: var(--card); border: 1px solid var(--border); border-radius: var(--r); padding: 22px; margin-bottom: 18px; display: flex; align-items: center; gap: 18px; }
.client-detail-avatar { width: 52px; height: 52px; border-radius: var(--r); display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 800; color: #fff; }
.client-detail-info h2 { font-size: 19px; font-weight: 800; margin-bottom: 3px; }
.client-detail-info p  { color: var(--text-muted); font-size: 13px; }
.client-detail-actions { margin-left: auto; display: flex; gap: 7px; }

/* ============================================================
   CRM
   ============================================================ */
.crm-card { background: var(--card); border-radius: var(--r-sm); border: 1px solid var(--border); padding: 12px; box-shadow: var(--shadow-xs); transition: box-shadow var(--t), transform var(--t); cursor: pointer; }
.crm-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.crm-card-top     { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.crm-card-name    { font-size: 13px; font-weight: 700; margin-bottom: 2px; }
.crm-card-company { font-size: 11.5px; color: var(--text-muted); margin-bottom: 4px; display: flex; align-items: center; gap: 4px; }
.crm-card-footer  { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--divider); }
.crm-temp { font-size: 10.5px; font-weight: 700; padding: 2px 8px; border-radius: 20px; }
.crm-value    { font-size: 12px; font-weight: 700; color: var(--success); margin-bottom: 4px; display: flex; align-items: center; gap: 4px; }
.crm-followup { font-size: 10.5px; color: var(--text-muted); display: flex; align-items: center; gap: 4px; margin-top: 4px; }
.crm-followup.overdue { color: var(--danger);  font-weight: 600; }
.crm-followup.today   { color: var(--warning); font-weight: 600; }

/* CRM Prospect modal */
.crm-tabs { display: flex; gap: 0; border-bottom: 2px solid var(--border); background: var(--card); }
.crm-tab  { padding: 10px 18px; font-size: 13px; font-weight: 600; color: var(--text-muted); border-bottom: 2px solid transparent; margin-bottom: -2px; cursor: pointer; transition: all var(--t); background: none; border-top: none; border-left: none; border-right: none; display: flex; align-items: center; gap: 7px; }
.crm-tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.crm-tab-pane { }

/* CRM Interactions */
.interaction-new  { background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 14px; margin-bottom: 16px; }
.interaction-item { flex-direction: column; display: flex; gap: 4px; padding: 12px 0; border-bottom: 1px solid var(--divider); }
.interaction-item:last-child { border-bottom: none; }
.interaction-meta { display: flex; align-items: center; gap: 10px; font-size: 11.5px; }
.interaction-text { font-size: 13px; color: var(--text-md); line-height: 1.55; white-space: pre-wrap; }
.interaction-list { overflow-y: auto; }

/* CRM status badges */
.status-lead-frio           { background: #F9FAFB; color: #6B7280; }
.status-primeiro-contato    { background: #EFF6FF; color: #3B82F6; }
.status-aguardando-resposta { background: #FFFBEB; color: #D97706; }
.status-em-negociacao       { background: #FFF7ED; color: #F97316; }
.status-proposta-enviada    { background: #F5F3FF; color: #8B5CF6; }
.status-fechado             { background: #ECFDF5; color: #10B981; }
.status-perdido             { background: #FEF2F2; color: #EF4444; }

/* ============================================================
   REUNIÕES
   ============================================================ */
.meetings-search-bar { display: flex; gap: 10px; margin-bottom: 20px; align-items: center; flex-wrap: wrap; }
.meetings-search-input-wrap { position: relative; flex: 1; min-width: 200px; }
.meetings-search-input-wrap i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }
.meetings-search-input-wrap .form-control { padding-left: 36px; }
.meeting-client-section { margin-bottom: 20px; }
.meeting-client-header  { display: flex; align-items: center; gap: 12px; padding: 13px 16px; background: var(--card); border: 1px solid var(--border); border-radius: var(--r); cursor: pointer; transition: background var(--t); }
.meeting-client-header:hover { background: var(--bg); }
.meeting-client-avatar  { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 15px; font-weight: 700; flex-shrink: 0; }
.meeting-client-info    { flex: 1; }
.meeting-client-name    { font-size: 14px; font-weight: 700; }
.meeting-client-meta    { font-size: 11.5px; color: var(--text-muted); }
.meeting-client-body    { border: 1px solid var(--border); border-top: none; border-radius: 0 0 var(--r) var(--r); overflow: hidden; }
.meeting-card           { padding: 16px 18px; border-bottom: 1px solid var(--divider); background: var(--card); transition: background var(--t); }
.meeting-card:hover     { background: var(--bg); }
.meeting-card:last-child { border-bottom: none; }
.meeting-card-header    { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.meeting-type-badge     { font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 20px; display: flex; align-items: center; gap: 5px; }
.meeting-date           { font-size: 12px; color: var(--text-muted); font-weight: 500; }
.meeting-card-title     { font-size: 14px; font-weight: 700; color: var(--text-dark); margin-bottom: 6px; }
.meeting-card-meta      { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.meeting-section-block  { margin-top: 10px; }
.meeting-section-label  { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); margin-bottom: 3px; display: block; }
.meeting-section-label.decisions { color: var(--success); }
.meeting-section-label.next      { color: var(--warning); }
.meeting-section-content { font-size: 13px; color: var(--text-md); line-height: 1.6; white-space: pre-wrap; background: var(--bg); border-left: 3px solid var(--divider); padding: 6px 10px; border-radius: 0 4px 4px 0; }
.meeting-card-actions   { display: flex; gap: 6px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--divider); }
.meeting-participants   { display: flex; gap: 4px; flex-wrap: wrap; align-items: center; }

/* ============================================================
   RELATÓRIOS
   ============================================================ */
.report-filters { background: var(--card); border: 1px solid var(--border); border-radius: var(--r); padding: 16px 18px; margin-bottom: 22px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.report-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.report-table th { background: var(--divider); padding: 9px 12px; text-align: left; font-weight: 600; color: var(--text-muted); font-size: 11px; text-transform: uppercase; letter-spacing: 0.4px; }
.report-table td { padding: 11px 12px; border-bottom: 1px solid var(--divider); color: var(--text-md); }
.report-table tr:hover td { background: var(--bg); }

/* ============================================================
   FORMS
   ============================================================ */
.form-group { margin-bottom: 14px; }
.form-row   { display: flex; gap: 12px; }
.form-row .form-group { flex: 1; min-width: 0; }
.form-label { display: block; font-size: 12px; font-weight: 700; color: var(--text-md); margin-bottom: 5px; }
.required { color: var(--danger); }
.form-control { width: 100%; padding: 8px 11px; border: 1px solid var(--border); border-radius: var(--r-sm); font-size: 13.5px; color: var(--text); background: var(--card); outline: none; transition: border-color var(--t), box-shadow var(--t); }
.form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,58,237,0.1); }
select.form-control { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%236B7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 9px center; background-size: 16px; padding-right: 32px; }
textarea.form-control { resize: vertical; }
.color-input { height: 40px; padding: 4px; }
.priority-selector { display: flex; gap: 7px; }
.priority-btn { flex: 1; padding: 7px 10px; border-radius: var(--r-sm); border: 1.5px solid var(--border); font-size: 12px; font-weight: 600; color: var(--text-muted); display: flex; align-items: center; justify-content: center; gap: 5px; cursor: pointer; transition: all var(--t); }
.priority-btn[data-priority="low"].active    { border-color: var(--success); color: var(--success); background: #ECFDF5; }
.priority-btn[data-priority="medium"].active { border-color: var(--warning); color: #D97706; background: #FFFBEB; }
.priority-btn[data-priority="high"].active   { border-color: var(--danger); color: var(--danger); background: #FEF2F2; }

/* ============================================================
   MODAIS
   ============================================================ */
.modal-backdrop { position: fixed; inset: 0; background: rgba(17,24,39,0.45); backdrop-filter: blur(3px); z-index: 300; display: none; opacity: 0; transition: opacity 0.2s; }
.modal-backdrop.open { display: block; opacity: 1; }
.modal { position: fixed; top: 50%; left: 50%; transform: translate(-50%,-52%) scale(0.97); width: 95%; max-width: 680px; max-height: 90vh; background: var(--card); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); z-index: 301; display: none; flex-direction: column; opacity: 0; transition: transform 0.22s ease, opacity 0.22s ease; overflow: hidden; }
.modal.open { display: flex; transform: translate(-50%,-50%) scale(1); opacity: 1; }
.modal-lg { max-width: 760px; }
.modal-sm { max-width: 480px; }
.modal-xs { max-width: 380px; }
.modal-xl { max-width: 860px; }
.modal-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 22px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.modal-header h2 { font-size: 15px; font-weight: 700; }
.modal-tab-label { display: inline-block; margin-top: 3px; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 20px; }
.modal-close { width: 28px; height: 28px; border-radius: var(--r-sm); color: var(--text-muted); display: flex; align-items: center; justify-content: center; transition: all var(--t); }
.modal-close:hover { background: var(--divider); color: var(--text); }
.modal-body   { flex: 1; overflow-y: auto; padding: 18px 22px; }
.modal-footer { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 14px 22px; border-top: 1px solid var(--border); flex-shrink: 0; }

/* ============================================================
   NOTIFICATION PANEL
   ============================================================ */
.notif-overlay { position: fixed; inset: 0; z-index: 200; display: none; }
.notif-overlay.open { display: block; }
.notif-panel { position: fixed; top: var(--topbar-h); right: -350px; width: 330px; height: calc(100vh - var(--topbar-h)); background: var(--card); border-left: 1px solid var(--border); box-shadow: var(--shadow-lg); z-index: 201; display: flex; flex-direction: column; transition: right 0.25s ease; }
.notif-panel.open { right: 0; }
.notif-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--border); }
.notif-panel-header h3 { font-size: 14px; font-weight: 700; }
.notif-panel-list { flex: 1; overflow-y: auto; padding: 10px; display: flex; flex-direction: column; gap: 7px; }
.notif-item { padding: 11px; border-radius: var(--r-sm); border: 1px solid var(--border); display: flex; align-items: flex-start; gap: 9px; font-size: 12.5px; }
.notif-item.notif-overdue { border-left: 3px solid var(--danger); }
.notif-item.notif-today   { border-left: 3px solid var(--warning); }
.notif-icon { font-size: 14px; margin-top: 1px; }
.notif-text strong { display: block; font-weight: 600; color: var(--text); font-size: 12.5px; }
.notif-text span   { color: var(--text-muted); font-size: 11px; }

/* ============================================================
   TOASTS
   ============================================================ */
#toast-container { position: fixed; top: 18px; right: 18px; z-index: 9999; display: flex; flex-direction: column; gap: 8px; }
.toast { display: flex; align-items: center; gap: 9px; padding: 11px 16px; background: #1F2937; color: #fff; border-radius: var(--r-sm); box-shadow: var(--shadow-lg); font-size: 13px; min-width: 240px; max-width: 360px; animation: toastIn 0.3s ease forwards; }
.toast.toast-success { background: #065F46; }
.toast.toast-error   { background: #991B1B; }
.toast.toast-warning { background: #92400E; }
@keyframes toastIn  { from { transform: translateX(110%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes toastOut { from { transform: translateX(0); opacity: 1; } to { transform: translateX(110%); opacity: 0; } }
.toast.removing { animation: toastOut 0.3s ease forwards; }

/* Notification toasts (user events — bottom-right, different from system toasts) */
#notif-toast-container { position: fixed; bottom: 24px; right: 24px; z-index: 9998; display: flex; flex-direction: column; gap: 10px; max-width: 360px; pointer-events: none; }
.notif-toast { display: flex; align-items: flex-start; gap: 11px; padding: 13px 14px 13px 13px; background: var(--card); border: 1px solid var(--border); border-left: 3px solid var(--primary); border-radius: var(--r); box-shadow: var(--shadow-lg); min-width: 280px; animation: ntIn 0.3s ease forwards; pointer-events: all; }
.notif-toast.removing { animation: ntOut 0.3s ease forwards; }
@keyframes ntIn  { from { transform: translateY(16px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes ntOut { from { transform: translateY(0); opacity: 1; } to { transform: translateY(16px); opacity: 0; } }
.notif-toast-icon { width: 34px; height: 34px; border-radius: 9px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 14px; }
.notif-toast-body { flex: 1; min-width: 0; }
.notif-toast-msg { font-size: 12.5px; color: var(--text); line-height: 1.4; word-break: break-word; }
.notif-toast-link { background: none; border: none; color: var(--primary); font-size: 11.5px; font-weight: 600; cursor: pointer; padding: 4px 0 0; display: block; }
.notif-toast-link:hover { text-decoration: underline; }
.notif-toast-close { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 12px; padding: 1px 3px; flex-shrink: 0; line-height: 1; }
.notif-toast-close:hover { color: var(--text); }
/* Profile dropdown notif toggle row */
.profile-notif-toggle { display: flex; align-items: center; justify-content: space-between; }
/* Notif panel sections */
.notif-section-label { font-size: 10px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; padding: 4px 6px 2px; }
.notif-item-unread { background: var(--bg); }
.notif-item-unread .notif-text strong::after { content: ''; display: inline-block; width: 6px; height: 6px; background: var(--primary); border-radius: 50%; margin-left: 5px; vertical-align: middle; }

/* ============================================================
   EMPTY STATE
   ============================================================ */
.empty-state { text-align: center; padding: 36px 20px; color: var(--text-muted); }
.empty-state-icon { font-size: 38px; margin-bottom: 10px; opacity: 0.25; }
.empty-state h3 { font-size: 14px; font-weight: 700; margin-bottom: 5px; color: var(--text); }
.empty-state p  { font-size: 12.5px; }

/* ============================================================
   SCROLLBAR
   ============================================================ */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 10px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1200px) {
  .stats-grid { grid-template-columns: repeat(2,1fr); }
  .grid-2, .grid-60-40 { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .sidebar { position: fixed; top: 0; left: -280px; height: 100%; transition: left 0.25s ease; }
  .sidebar.mobile-open { left: 0; box-shadow: var(--shadow-lg); }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .content { padding: 14px; }
  .topbar { padding: 0 14px; }
  .form-row { flex-direction: column; }
  #user-topbar-name { display: none; }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .clients-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   SIDEBAR — CLIENTES
   ============================================================ */
.sidebar-nav { flex: 0 0 auto !important; overflow-y: visible !important; }

.sidebar-clients-section {
  flex: 1;
  overflow-y: auto;
  border-top: 1px solid rgba(255,255,255,0.06);
  min-height: 60px;
}
.sidebar-clients-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px 4px;
}
.sidebar-add-client-btn {
  background: none;
  border: none;
  color: rgba(255,255,255,0.35);
  cursor: pointer;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  font-size: 11px;
  transition: color 0.15s, background 0.15s;
}
.sidebar-add-client-btn:hover { color: #fff; background: var(--sidebar-hover); }

.sidebar-client-item {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 7px 12px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.5);
  font-size: 12.5px;
  cursor: pointer;
  text-align: left;
  border-radius: var(--r-sm);
  margin: 1px 4px;
  width: calc(100% - 8px);
  transition: all 0.15s;
  white-space: nowrap;
  overflow: hidden;
}
.sidebar-client-item:hover { color: #fff; background: var(--sidebar-hover); }
.sidebar-client-item.active { color: #fff; background: var(--sidebar-active); }
.sidebar-client-dot {
  width: 8px;
  height: 8px;
  min-width: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.sidebar-client-name { overflow: hidden; text-overflow: ellipsis; }
.sidebar-clients-empty { color: rgba(255,255,255,0.22); font-size: 11.5px; padding: 8px 14px; }

/* Collapsed sidebar hides client names */
.sidebar.collapsed .sidebar-clients-section { min-height: 0; }
.sidebar.collapsed .sidebar-clients-header  { padding: 6px; justify-content: center; }
.sidebar.collapsed .sidebar-client-item     { padding: 7px; justify-content: center; margin: 1px 6px; width: calc(100% - 12px); }
.sidebar.collapsed .sidebar-client-name,
.sidebar.collapsed .sidebar-clients-empty,
.sidebar.collapsed .sidebar-add-client-btn  { display: none; }

/* ============================================================
   PASTA DE CLIENTE (Client Folder)
   ============================================================ */
.client-folder-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.client-folder-avatar {
  width: 50px;
  height: 50px;
  min-width: 50px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
  color: #fff;
}
.client-folder-info { flex: 1; min-width: 0; }
.client-folder-name { font-size: 20px; font-weight: 800; margin: 0 0 3px; }
.client-folder-meta { font-size: 13px; color: var(--text-muted); margin: 0; }
.client-folder-actions { display: flex; gap: 8px; flex-shrink: 0; }

.folder-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0;
}
.folder-tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: -1px;
  transition: color 0.15s, border-color 0.15s;
}
.folder-tab:hover { color: var(--text); }
.folder-tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }

.folder-list { padding: 4px 0; }
.folder-list-group { margin-bottom: 16px; }
.folder-list-group-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 10px;
  border-left: 3px solid;
  border-radius: 0 4px 4px 0;
  background: var(--bg);
  margin-bottom: 4px;
  color: var(--text-md);
}

/* ============================================================
   ACESSOS DOS CLIENTES
   ============================================================ */
.acessos-container { padding: 4px 0; max-width: 860px; }

.acessos-badge-wrap { margin-bottom: 20px; }
.acessos-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #FEF3C7;
  color: #92400E;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid #FDE68A;
}

.acessos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.access-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-md, 10px);
  padding: 14px;
  box-shadow: var(--shadow-xs);
}
.access-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--divider);
}
.access-platform-icon { font-size: 20px; color: var(--primary); width: 22px; text-align: center; }
.access-platform-name { font-size: 13px; font-weight: 700; color: var(--text); }
.access-fields { display: flex; flex-direction: column; gap: 8px; }

.pw-field-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.pw-field-wrap .form-control { padding-right: 38px; }
.pw-toggle {
  position: absolute;
  right: 8px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 13px;
  padding: 2px;
  line-height: 1;
}
.pw-toggle:hover { color: var(--text); }

.acessos-add-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 14px;
  background: var(--bg);
  border-radius: var(--r-sm);
  border: 1px dashed var(--border);
}

/* ============================================================
   PRESENÇA ONLINE/OFFLINE
   ============================================================ */
.team-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}
.presence-dot {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 2px solid var(--sidebar-bg);
}
.presence-online  { background: #22C55E; }
.presence-offline { background: #9CA3AF; }
.presence-dot-light { border-color: var(--card); }
.presence-label-online { font-size: 10px; color: #22C55E; font-weight: 600; }
.presence-label-offline { font-size: 10px; color: transparent; }

/* ============================================================
   CHAT DOS CARDS
   ============================================================ */
.modal-chat { max-width: 1060px !important; }

.modal-body-split {
  display: flex;
  overflow: hidden;
  padding: 0 !important;
  flex: 1;
  min-height: 0;
}
.modal-form-col {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  padding: 18px 22px;
}
.modal-chat-col {
  width: 320px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  border-left: 1px solid var(--border);
  background: var(--card);
  overflow: hidden;
}
.chat-header {
  padding: 14px 16px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-md);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--bg);
}
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.chat-empty {
  text-align: center;
  padding: 30px 16px;
  color: var(--text-muted);
  font-size: 12px;
  margin: auto 0;
}
.chat-empty i { font-size: 28px; opacity: 0.2; display: block; margin-bottom: 8px; }
.chat-empty p { margin: 0; line-height: 1.5; }

.chat-date-sep {
  text-align: center;
  font-size: 10.5px;
  color: var(--text-light);
  background: var(--bg);
  border-radius: 10px;
  padding: 2px 10px;
  margin: 6px auto;
  width: fit-content;
}

.chat-msg {
  display: flex;
  align-items: flex-end;
  gap: 6px;
}
.chat-msg-me {
  flex-direction: row-reverse;
}
.chat-avatar-sm {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  flex-shrink: 0;
}
.chat-bubble-wrap {
  max-width: 82%;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.chat-sender {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-muted);
  padding-left: 2px;
}
.chat-bubble {
  padding: 8px 11px;
  border-radius: 14px 14px 14px 4px;
  font-size: 12.5px;
  line-height: 1.45;
  word-break: break-word;
  background: var(--bg);
  color: var(--text);
}
.chat-msg-me .chat-bubble {
  background: var(--primary);
  color: #fff;
  border-radius: 14px 14px 4px 14px;
}
.chat-msg-me .chat-bubble .chat-mention { color: rgba(255,255,255,0.9) !important; }
.chat-ts {
  font-size: 10px;
  color: var(--text-light);
  padding: 0 2px;
}
.chat-msg-me .chat-ts { text-align: right; }

.chat-input-area {
  border-top: 1px solid var(--border);
  flex-shrink: 0;
  background: var(--card);
}
.chat-mention-dropdown {
  position: absolute;
  bottom: 100%;
  left: 0;
  right: 0;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r-sm) var(--r-sm) 0 0;
  box-shadow: 0 -4px 16px rgba(0,0,0,0.1);
  overflow: hidden;
  z-index: 10;
}
.mention-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  width: 100%;
  cursor: pointer;
  font-size: 13px;
  border: none;
  background: none;
  color: var(--text);
  text-align: left;
}
.mention-option:hover { background: var(--bg); }

.chat-input-wrap {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 10px;
}
.chat-input {
  flex: 1;
  resize: none;
  font-size: 12.5px;
  min-height: 56px;
  max-height: 100px;
}
.chat-send-btn {
  flex-shrink: 0;
  padding: 8px 12px;
  align-self: flex-end;
}

@media (max-width: 768px) {
  .modal-body-split { flex-direction: column; }
  .modal-chat-col { width: 100%; border-left: none; border-top: 1px solid var(--border); max-height: 260px; }
  .modal-chat { max-width: 95% !important; }
}

/* ============================================================
   NOVOS STATUS — FLUXO
   ============================================================ */
:root {
  --s-criar-demanda:      #7C3AED;
  --s-alterar-copy:       #DC2626;
  --s-alterar-arte:       #D97706;
  --s-enviar-grafica:     #0891B2;
  --s-formulario-cliente: #A78BFA;
}

/* ============================================================
   CONFIGURAÇÕES DA AGÊNCIA
   ============================================================ */
.settings-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 4px;
}
@media (max-width: 900px) { .settings-grid { grid-template-columns: 1fr; } }

.settings-logo-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  background: var(--bg);
  border-radius: var(--r-sm);
  min-height: 140px;
  justify-content: center;
}
.settings-logo-preview {
  max-width: 200px;
  max-height: 100px;
  object-fit: contain;
  border-radius: 6px;
}
.settings-logo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-light);
  font-size: 13px;
}
.settings-logo-placeholder i { font-size: 32px; opacity: 0.3; }
.settings-logo-placeholder p { margin: 0; }

.settings-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.settings-hint {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 6px;
}

.color-picker-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 6px;
}

/* Login screen live preview */
.login-prev-wrap {
  background: var(--bg);
  border-radius: var(--r);
  padding: 12px;
  margin-bottom: 4px;
}
.login-prev-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 10px;
}
.login-prev-screen {
  width: 100%; height: 260px;
  border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #0F0D2A, #1a1040 50%, #14103a);
  overflow: hidden; position: relative;
}
.login-prev-card {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 14px;
  padding: 18px 20px;
  width: 190px;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
}
.login-prev-logo-wrap {
  display: flex; align-items: center; justify-content: center;
  min-height: 36px; margin-bottom: 2px;
}
.login-prev-logo-mark {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, #7C3AED, #EC4899);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 16px;
}
.login-prev-title {
  color: #fff; font-size: 9.5px; font-weight: 700;
  text-align: center; line-height: 1.3; width: 100%;
}
.login-prev-subtitle {
  color: rgba(255,255,255,0.45); font-size: 8px;
  text-align: center; width: 100%;
}
.login-prev-field {
  width: 100%; height: 18px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 5px; margin-top: 2px;
}
.login-prev-btn {
  width: 100%; height: 22px;
  background: linear-gradient(135deg, #7C3AED, #6D28D9);
  border-radius: 5px; margin-top: 4px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 8.5px; font-weight: 600;
}
.color-input {
  width: 44px;
  height: 44px;
  border: 2px solid var(--border);
  border-radius: var(--r-sm);
  cursor: pointer;
  background: none;
  padding: 2px;
  flex-shrink: 0;
}
.color-hex {
  font-size: 12px;
  font-family: monospace;
  background: var(--bg);
  padding: 4px 8px;
  border-radius: 4px;
  color: var(--text-md);
  min-width: 70px;
}

/* ============================================================
   VIEW CONTROLS (kanban/lista toggle + person filter + hide-empty)
   ============================================================ */
.view-controls-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  padding: 8px 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r);
}
.person-filter-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  flex: 1;
}
.person-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px 4px 8px;
  border-radius: 50px;
  border: 1.5px solid var(--border);
  background: var(--card);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--t);
  white-space: nowrap;
}
.person-chip:hover { border-color: var(--primary); color: var(--text); }
.person-chip.active { box-shadow: 0 2px 6px rgba(0,0,0,0.15); }
.person-chip-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.view-controls-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.sort-select {
  padding: 5px 10px;
  font-size: 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  min-width: 160px;
}
.view-mode-toggle {
  display: flex;
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  overflow: hidden;
}
.view-mode-btn {
  padding: 5px 10px;
  background: var(--card);
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 13px;
  transition: all var(--t);
  line-height: 1;
}
.view-mode-btn:hover { background: var(--bg); color: var(--text); }
.view-mode-btn.active { background: var(--primary); color: #fff; }
.active-filter { background: var(--primary-light, #EDE9FE) !important; color: var(--primary) !important; border-color: var(--primary) !important; font-weight: 600; }

/* ============================================================
   TASK TABLE (lista view)
   ============================================================ */
.task-table-wrap {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r);
  overflow: auto;
  max-height: calc(100vh - 308px);
}
.task-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.task-table thead tr {
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 1;
}
.task-table th {
  padding: 10px 14px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.task-table tbody tr {
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background var(--t);
}
.task-table tbody tr:last-child { border-bottom: none; }
.task-table tbody tr:hover { background: var(--bg); }
.task-table td {
  padding: 10px 14px;
  color: var(--text);
  vertical-align: middle;
}
.task-table-title {
  font-weight: 600;
  max-width: 240px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.task-table-member {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

/* ============================================================
   BRIEFINGS MENSAIS — PLATFORM VIEW
   ============================================================ */
.briefing-link-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.brief-link-display {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}
.brief-link-input {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  color: var(--text-muted) !important;
  background: var(--bg) !important;
  font-family: monospace;
  cursor: text;
}

.brief-response-card {
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}
.brief-response-card:last-child { border-bottom: none; }
.brief-response-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
  cursor: pointer;
  transition: background var(--t);
}
.brief-response-header:hover { background: var(--bg); }
.brief-response-main { flex: 1; min-width: 0; }
.brief-response-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin: 4px 0 4px;
}
.brief-response-meta {
  font-size: 12px;
  color: var(--text-muted);
}
.brief-response-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.brief-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 9px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
}
.brief-badge-new  { background: #FEE2E2; color: #DC2626; }
.brief-badge-ok   { background: #D1FAE5; color: #059669; }

/* Briefing detail expand/collapse */
.brief-detail {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}
.brief-detail.open { max-height: 1200px; }
.brief-detail-inner {
  padding: 0 20px 20px;
  border-top: 1px solid var(--border);
}

.brief-ans-section {
  margin-bottom: 16px;
  padding-top: 14px;
}
.brief-ans-section:first-child { padding-top: 14px; }
.brief-ans-sect-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: 8px;
}
.brief-ans-row {
  display: flex;
  gap: 12px;
  margin-bottom: 6px;
  font-size: 13px;
  align-items: baseline;
}
.brief-ans-label {
  flex-shrink: 0;
  width: 160px;
  font-weight: 600;
  color: var(--text-muted);
  font-size: 12px;
}
.brief-ans-val {
  flex: 1;
  color: var(--text);
  line-height: 1.5;
  white-space: pre-wrap;
}
.brief-ans-empty {
  color: var(--text-muted);
  font-style: italic;
}

@media (max-width: 600px) {
  .brief-ans-row { flex-direction: column; gap: 2px; }
  .brief-ans-label { width: auto; }
}

/* ============================================================
   VISÃO DA EQUIPE (Carol only)
   ============================================================ */
.equipe-tabs-wrap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}
.equipe-tab {
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--r);
  padding: 16px 18px;
  cursor: pointer;
  transition: all var(--t);
  position: relative;
  overflow: hidden;
}
.equipe-tab::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--tab-color, transparent);
  opacity: 0;
  transition: opacity var(--t);
}
.equipe-tab:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}
.equipe-tab.active {
  border-color: var(--tab-color, var(--primary));
  box-shadow: 0 4px 20px rgba(0,0,0,0.10);
}
.equipe-tab.active::before { opacity: 1; }

.equipe-tab-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}
.equipe-tab-info { flex: 1; min-width: 0; }
.equipe-tab-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.equipe-tab-role {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
  font-weight: 500;
}
.equipe-presence {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
  font-weight: 500;
}
.equipe-presence.online { color: #22C55E; }

.equipe-tab-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.equipe-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 3px 9px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
}
.equipe-stat-num {
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
}
.equipe-stat-ok   { background: #D1FAE5; border-color: #A7F3D0; color: #059669; }
.equipe-stat-ok .equipe-stat-num { color: #047857; }
.equipe-stat-danger { background: #FEE2E2; border-color: #FECACA; color: #DC2626; }
.equipe-stat-warn   { background: #FEF3C7; border-color: #FDE68A; color: #D97706; }

.equipe-content-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 11px 16px;
  margin-bottom: 12px;
}

/* Table row states for overdue / today */
.equipe-row-overdue td { background: #FFF5F5 !important; }
.equipe-row-today   td { background: #FFFBEB !important; }
.equipe-row-overdue:hover td { background: #FEE2E2 !important; }
.equipe-row-today:hover   td { background: #FEF3C7 !important; }
.equipe-dl-overdue { color: #DC2626 !important; font-weight: 700; }
.equipe-dl-today   { color: #D97706 !important; font-weight: 700; }

/* Inline tags on title */
.equipe-overdue-tag {
  display: inline-flex; align-items: center;
  background: #FEE2E2; color: #DC2626;
  font-size: 10px; font-weight: 700;
  padding: 1px 7px; border-radius: 20px;
  margin-left: 6px; vertical-align: middle;
  text-transform: uppercase; letter-spacing: .03em;
}
.equipe-today-tag {
  display: inline-flex; align-items: center;
  background: #FEF3C7; color: #D97706;
  font-size: 10px; font-weight: 700;
  padding: 1px 7px; border-radius: 20px;
  margin-left: 6px; vertical-align: middle;
  text-transform: uppercase; letter-spacing: .03em;
}

/* Area badges */
.equipe-area-badge {
  display: inline-block; padding: 2px 8px;
  border-radius: 20px; font-size: 11px; font-weight: 700;
  white-space: nowrap;
}
.badge-fluxo  { background: #EDE9FE; color: #7C3AED; }
.badge-trafego{ background: #FCE7F3; color: #BE185D; }

@media (max-width: 900px) {
  .equipe-tabs-wrap { grid-template-columns: 1fr; }
}

/* ============================================================
   FILTRO POR DATA
   ============================================================ */
.date-filter-bar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 7px 12px; margin-bottom: 6px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--r);
  font-size: 12.5px;
}
.date-filter-bar.has-filter { border-color: var(--primary); background: var(--primary-light)1a; }
.date-filter-label { color: var(--text-muted); font-weight: 600; white-space: nowrap; display: flex; align-items: center; gap: 5px; }
.date-sep { color: var(--text-light); font-size: 11px; }
.filter-date { max-width: 150px; padding: 4px 8px; font-size: 12px; }
.filter-date[type="month"] { max-width: 130px; }
.filter-date:disabled { opacity: 0.4; pointer-events: none; }

/* ============================================================
   VIDEO ATTACHMENT
   ============================================================ */
.att-video-item {
  display: flex; flex-direction: column; gap: 4px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--r-sm); position: relative;
  overflow: hidden; flex-shrink: 0;
}
.att-video-preview { width: 100%; max-height: 200px; border-radius: 0; background: #000; display: block; }
.att-video-name { font-size: 11px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; padding: 4px 6px; }
.att-video-name span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att-video-name .att-action-btn { width: 22px; height: 22px; font-size: 10px; flex-shrink: 0; }
.card-att-video {
  width: 36px; height: 36px; border-radius: 6px;
  background: #1F2937; color: #fff; display: inline-flex;
  align-items: center; justify-content: center; font-size: 14px;
  cursor: pointer; flex-shrink: 0;
}

/* ============================================================
   CONFIGURAÇÕES AVANÇADAS — TABS
   ============================================================ */
.config-tabs-bar {
  display: flex; gap: 4px; flex-wrap: wrap;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r); padding: 6px; margin-bottom: 16px;
}
.config-tab {
  display: flex; align-items: center; gap: 7px;
  padding: 8px 14px; border-radius: var(--r-sm);
  border: none; background: transparent;
  font-size: 13px; font-weight: 500; color: var(--text-muted);
  cursor: pointer; transition: all var(--t); white-space: nowrap;
}
.config-tab:hover { background: var(--bg); color: var(--text); }
.config-tab.active { background: var(--primary); color: #fff; box-shadow: 0 2px 8px rgba(124,58,237,.3); }
.config-tab-body {}

/* Briefing config */
.cfg-briefing-list { display: flex; flex-direction: column; }
.cfg-briefing-section {
  padding: 16px; border-bottom: 1px solid var(--border);
  transition: opacity var(--t);
}
.cfg-briefing-section:last-child { border-bottom: none; }
.cfg-section-disabled { opacity: 0.5; }
.cfg-section-header { display: flex; align-items: flex-start; gap: 12px; }
.cfg-section-info { flex: 1; }
.cfg-section-title-input { font-weight: 600; font-size: 14px; }

/* Status config */
.cfg-status-list { display: flex; flex-direction: column; }
.cfg-status-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 16px; border-bottom: 1px solid var(--divider);
  transition: opacity var(--t);
}
.cfg-status-row:last-child { border-bottom: none; }
.cfg-status-hidden { opacity: 0.45; }
.cfg-status-color { width: 36px; height: 32px; border-radius: var(--r-sm); padding: 2px; cursor: pointer; flex-shrink: 0; }
.cfg-status-name { flex: 1; min-width: 120px; }
.cfg-status-id { font-size: 11px; color: var(--text-light); font-family: monospace; white-space: nowrap; }
.cfg-group-badge { font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 20px; white-space: nowrap; }
.cfg-group-badge.main { background: #EDE9FE; color: #7C3AED; }
.cfg-group-badge.wait { background: #FEF3C7; color: #D97706; }

/* Users config */
.cfg-users-list { display: flex; flex-direction: column; }
.cfg-user-row {
  display: flex; align-items: center; gap: 12px;
  padding: 16px; border-bottom: 1px solid var(--border);
}
.cfg-user-row:last-child { border-bottom: none; }
.cfg-user-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 16px; font-weight: 700; flex-shrink: 0;
}
.cfg-user-fields { flex: 1; min-width: 0; }
.cfg-user-row-fields { display: flex; gap: 10px; flex-wrap: wrap; }

/* Automations config */
.cfg-auto-list { display: flex; flex-direction: column; }
.cfg-auto-row {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 14px 16px; border-bottom: 1px solid var(--divider);
}
.cfg-auto-row:last-child { border-bottom: none; }
.cfg-auto-icon {
  width: 36px; height: 36px; border-radius: 8px;
  background: var(--primary-light)33; color: var(--primary);
  display: flex; align-items: center; justify-content: center; font-size: 15px; flex-shrink: 0;
}
.cfg-auto-info { flex: 1; }
.cfg-auto-label { font-weight: 600; font-size: 13.5px; margin-bottom: 2px; }
.cfg-auto-desc  { font-size: 12px; color: var(--text-muted); }

/* Toggle switch */
.toggle-switch {
  position: relative; display: inline-flex; align-items: center;
  width: 40px; height: 22px; flex-shrink: 0; cursor: pointer;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute; inset: 0; border-radius: 22px;
  background: var(--border); transition: background var(--t);
}
.toggle-slider::before {
  content: ''; position: absolute;
  width: 16px; height: 16px; left: 3px; bottom: 3px;
  border-radius: 50%; background: #fff;
  transition: transform var(--t); box-shadow: 0 1px 4px rgba(0,0,0,.2);
}
.toggle-switch input:checked + .toggle-slider { background: var(--primary); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(18px); }
.toggle-switch input:disabled + .toggle-slider { opacity: 0.6; cursor: not-allowed; }

@media (max-width: 768px) {
  .config-tabs-bar { flex-direction: column; }
  .config-tab { justify-content: flex-start; }
  .cfg-user-row-fields { flex-direction: column; }
  .date-filter-bar { gap: 6px; }
  .filter-date { max-width: 120px; }
}

/* ── Custom user inactive ── */
.cfg-user-inactive { opacity: 0.5; }

/* ── Briefing question row ── */
.cfg-bq-row {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-sm);
  padding: 12px; margin-bottom: 8px;
}

/* ── Status config custom ── */
.cfg-status-custom { background: #F5F3FF22; }

/* ── Tráfego Pago badge (on cards) ── */
.paid-traffic-badge {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 10px; font-weight: 700; padding: 2px 7px;
  border-radius: 10px; background: #FEF3C7; color: #B45309;
  flex-shrink: 0; letter-spacing: .02em;
}
.task-card.paid-traffic { border-top: 2.5px solid #F59E0B; }
.task-card.paid-traffic .task-card-top { padding-top: 2px; }
.btn-filter-paid { transition: all var(--t); }
.btn-filter-paid.active { background: #FEF3C7 !important; color: #B45309 !important; border-color: #F59E0B !important; }

/* ── Paid traffic toggle (modal) ── */
.paid-traffic-toggle-row {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; border-radius: var(--r-sm);
  border: 1px solid var(--border); background: var(--bg);
  margin-bottom: 2px;
}

/* ── Relatório Semanal ── */
.report-view-bar { display: flex; gap: 8px; margin-bottom: 16px; }
.report-view-btn { padding: 7px 16px; border-radius: var(--r-sm); border: 1px solid var(--border); background: var(--card); font-size: 13px; font-weight: 600; color: var(--text-muted); cursor: pointer; transition: all var(--t); }
.report-view-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); box-shadow: 0 2px 8px rgba(124,58,237,.25); }
.report-week-nav { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.week-nav-btn { width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--border); background: var(--card); display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 13px; transition: all var(--t); }
.week-nav-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.week-label { font-size: 14px; font-weight: 700; color: var(--text); }
.semanal-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(280px,1fr)); gap: 14px; }
.semanal-person-block { background: var(--card); border: 1px solid var(--border); border-radius: var(--r); padding: 16px; }
.semanal-person-header { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--divider); }
.semanal-person-name { font-weight: 700; font-size: 14px; }
.semanal-person-role { font-size: 11px; color: var(--text-muted); }
.semanal-stat { display: flex; align-items: center; justify-content: space-between; padding: 5px 0; border-bottom: 1px solid var(--divider); font-size: 13px; }
.semanal-stat:last-child { border-bottom: none; }
.semanal-stat-label { color: var(--text-md); }
.semanal-stat-count { font-weight: 700; min-width: 22px; text-align: right; }
.semanal-task-list { margin-top: 8px; }
.semanal-task-item { font-size: 11.5px; color: var(--text-muted); padding: 3px 0; border-bottom: 1px solid var(--divider); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.semanal-task-item:last-child { border-bottom: none; }
.generate-report-btn { display: flex; align-items: center; gap: 8px; }

/* ── Font upload custom ── */
.cfg-font-name-input { flex: 2; min-width: 140px; }
.cfg-font-upload-label { cursor: pointer; }
