/* ============================================================
   main.css — PayIA global styles & design tokens
   ============================================================ */

/* ─── Design tokens ────────────────────────────────────────── */
:root {
  /* Minimal clean — branco puro, texto navy quase-preto */
  --bg-base:     #FFFFFF;
  --bg-surface:  #FFFFFF;
  --bg-card:     #FFFFFF;
  --bg-elevated: #F5F6F8;

  /* Brand — navy ink para CTAs, azul só como acento pontual */
  --brand-ink:     #0F172A;
  --brand-primary: #2563EB;
  --brand-mid:     #1D4ED8;
  --brand-bright:  #0EA5E9;
  --brand-teal:    #0EA5E9;

  --text-primary:   #0B1220;
  --text-secondary: #475467;
  --text-muted:     #667085;

  --success: #10B981;
  --danger:  #EF4444;
  --warning: #F59E0B;

  --paid:    rgba(16,185,129,0.1);
  --overdue: rgba(239,68,68,0.1);
  --pending: rgba(245,158,11,0.1);

  --border-subtle: #F0F2F5;
  --border-card:   #E4E7EC;

  --glow-purple: 0 8px 24px rgba(15,23,42,0.06);
  --glow-teal:   0 8px 24px rgba(15,23,42,0.06);
  --glow-bright: 0 16px 40px rgba(15,23,42,0.08);

  --glass-bg:   rgba(255,255,255,0.85);
  --glass-blur: blur(12px);

  --radius-card:  16px;
  --radius-btn:   999px;
  --radius-input: 10px;

  --font-main:     'Plus Jakarta Sans', 'Inter', system-ui, sans-serif;
  --tracking-wide: 0.12em;

  --transition-fast:   0.15s ease;
  --transition-smooth: 0.3s cubic-bezier(0.4,0,0.2,1);

  --sidebar-w: 240px;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font-main);
  background: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Grain removido — visual minimal limpo */

img, svg { display: block; max-width: 100%; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }
input, select, textarea { font-family: inherit; }

:focus-visible { outline: 2px solid var(--brand-primary); outline-offset: 3px; border-radius: 4px; }

/* ─── Screen management ─────────────────────────────────────── */
.screen { display: block; }
.screen[hidden] { display: none !important; }

/* ─── Container ─────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 20px;
}

/* ─── Typography ─────────────────────────────────────────────── */
.gradient-text {
  background: linear-gradient(135deg, var(--brand-bright), var(--brand-teal));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ─── Navbar ─────────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background var(--transition-smooth), border-color var(--transition-smooth), backdrop-filter var(--transition-smooth);
}
.navbar.scrolled {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border-color: rgba(255,255,255,0.05);
}
.navbar-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 68px;
}
.navbar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.logo-icon { flex-shrink: 0; }
.logo-text { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }

.navbar-links {
  display: none;
  align-items: center;
  gap: 28px;
}
.navbar-links a {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
}
.navbar-links a:hover { color: var(--text-primary); }

.navbar-ctas {
  display: none;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.navbar-hamburger {
  margin-left: auto;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  border-radius: 8px;
}
.navbar-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-secondary);
  border-radius: 2px;
  transition: transform var(--transition-smooth), opacity var(--transition-smooth);
}
.navbar-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.navbar-hamburger.open span:nth-child(2) { opacity: 0; }
.navbar-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  top: 68px;
  left: 0;
  right: 0;
  z-index: 99;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mobile-menu[hidden] { display: none; }
.mobile-link {
  display: block;
  padding: 12px 16px;
  font-size: 15px;
  color: var(--text-secondary);
  border-radius: 10px;
  transition: background var(--transition-fast), color var(--transition-fast);
}
.mobile-link:hover { background: var(--bg-elevated); color: var(--text-primary); }
.mobile-ctas { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.btn-full { width: 100%; justify-content: center; }

/* ─── Hero ───────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;
  padding-bottom: 80px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 0%, rgba(37,99,235,0.05) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid var(--border-card);
  border-radius: var(--radius-btn);
  font-size: 13px;
  color: var(--text-secondary);
}
.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
  flex-shrink: 0;
}
.badge-star { color: var(--brand-bright); }

.hero-title {
  font-size: clamp(40px, 6.5vw, 84px);
  font-weight: 800;
  line-height: 1.03;
  letter-spacing: -0.04em;
}
.hero-subtitle {
  max-width: 520px;
  color: var(--text-secondary);
  font-size: clamp(16px, 2vw, 18px);
  line-height: 1.7;
}
.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}
.hero-social-proof {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Hero 3D Mockup */
.hero-mockup-wrapper {
  width: 100%;
  max-width: 860px;
  margin-top: 16px;
  perspective: 1200px;
}
.hero-mockup {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--glow-purple), 0 40px 80px rgba(0,0,0,0.5);
  transform: perspective(1200px) rotateX(8deg) rotateY(-4deg);
  transform-origin: center center;
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.8s ease;
}
.hero-mockup.demo-playing {
  transform: perspective(1200px) rotateX(0deg) rotateY(0deg) scale(1.06);
  box-shadow: 0 25px 50px -12px rgba(37, 99, 235, 0.25), 0 40px 80px rgba(0,0,0,0.45);
  animation: none !important;
}

/* Demo Prominence & Caption Styles */
#verDemoBtn {
  border-color: var(--brand-bright);
  box-shadow: 0 0 12px rgba(14, 165, 233, 0.15);
  animation: pulse-border 2s infinite;
  transition: all var(--transition-smooth);
}
#verDemoBtn:hover {
  background: rgba(14, 165, 233, 0.05);
  box-shadow: 0 0 20px rgba(14, 165, 233, 0.3);
}

@keyframes pulse-border {
  0%, 100% { border-color: rgba(14, 165, 233, 0.4); box-shadow: 0 0 12px rgba(14, 165, 233, 0.15); }
  50% { border-color: rgba(37, 99, 235, 0.8); box-shadow: 0 0 20px rgba(37, 99, 235, 0.3); }
}

.demo-tutorial-banner {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px;
  background: rgba(37, 99, 235, 0.04);
  border: 1px dashed rgba(37, 99, 235, 0.25);
  border-radius: var(--radius-input);
  font-size: 13.5px;
  color: var(--text-secondary);
  max-width: 660px;
  margin: 16px auto 8px auto;
  text-align: center;
  line-height: 1.5;
}
.tutorial-sparkle {
  color: var(--brand-bright);
  font-weight: 800;
}

.demo-caption-container {
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  border-radius: 12px;
  padding: 16px 24px;
  max-width: 520px;
  margin: 16px auto;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  text-align: center;
  animation: slideInBottom 0.4s ease;
}
.demo-caption-step {
  font-size: 10px;
  font-weight: 800;
  color: var(--brand-primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 4px;
}
.demo-caption-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 6px;
}
.demo-caption-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ─── Interactive Step Explanation Cards ─────────────────────── */
.demo-steps-explanation[hidden] { display: none !important; }
.demo-steps-explanation {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  width: 100%;
  max-width: 1080px;
  margin: 32px auto 16px auto;
  text-align: left;
}

/* Mockup Projection & CRM/Invoices extra styles */
.btn-mock-action {
  transition: all var(--transition-fast);
  cursor: pointer;
}
.btn-mock-action.btn-success {
  background: rgba(62,207,142,0.12) !important;
  border-color: rgba(62,207,142,0.3) !important;
  color: var(--success) !important;
}
.mockup-spinner {
  width: 8px;
  height: 8px;
  border: 1px solid var(--text-muted);
  border-top-color: var(--brand-primary);
  border-radius: 50%;
  display: inline-block;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

.demo-step-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 20px;
  cursor: pointer;
  transition: all var(--transition-smooth);
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.demo-step-card:hover {
  transform: translateY(-4px);
  border-color: var(--brand-primary);
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.08);
}

.demo-step-card.active {
  border-color: var(--brand-primary);
  background: var(--bg-surface);
  box-shadow: 0 0 20px rgba(14, 165, 233, 0.12), 0 4px 12px rgba(0, 0, 0, 0.03);
}

.demo-step-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.demo-step-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.08);
  color: var(--brand-primary);
  font-weight: 700;
  font-size: 13px;
  flex-shrink: 0;
  transition: all var(--transition-fast);
}

.demo-step-card.active .demo-step-badge {
  background: var(--brand-primary);
  color: #fff;
  box-shadow: 0 0 8px rgba(37, 99, 235, 0.35);
}

.demo-step-card h3 {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.2;
}

.demo-step-short {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.4;
  margin: 0 0 12px 0;
}

.demo-step-details {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
  border-top: 1px dashed var(--border-subtle);
  padding-top: 12px;
  margin-top: auto;
}

.step-detail-tag {
  display: inline-block;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--brand-primary);
  background: rgba(37, 99, 235, 0.06);
  padding: 1px 6px;
  border-radius: 4px;
  margin-bottom: 6px;
}

.demo-step-details p {
  margin: 0;
}

.demo-step-action-hint {
  font-size: 11px;
  font-weight: 600;
  color: var(--brand-primary);
  margin-top: 12px;
  text-align: right;
  opacity: 0.6;
  transition: opacity var(--transition-fast);
}

.demo-step-card:hover .demo-step-action-hint,
.demo-step-card.active .demo-step-action-hint {
  opacity: 1;
}

/* Responsividade para os cartões explicativos */
@media (max-width: 1023px) {
  .demo-steps-explanation {
    grid-template-columns: 1fr;
    max-width: 580px;
    padding-inline: 16px;
  }
}


.mockup-titlebar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
}
.mockup-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: #444;
  display: inline-block;
}
.mockup-titlebar .mockup-dot:nth-child(1) { background: #FF5F57; }
.mockup-titlebar .mockup-dot:nth-child(2) { background: #FEBC2E; }
.mockup-titlebar .mockup-dot:nth-child(3) { background: #28C840; }
.mockup-url {
  margin-left: 12px;
  font-size: 11px;
  color: var(--text-muted);
  background: var(--bg-elevated);
  padding: 3px 12px;
  border-radius: 6px;
  flex: 1;
  text-align: center;
}
.mockup-body {
  display: flex;
  min-height: 280px;
}
.mockup-sidebar {
  width: 48px;
  background: var(--bg-surface);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 6px;
  gap: 10px;
}
.mockup-logo-mini {
  width: 24px; height: 24px;
  background: var(--brand-primary);
  border-radius: 6px;
}
.mockup-nav-item {
  width: 28px; height: 6px;
  background: var(--bg-elevated);
  border-radius: 3px;
}
.mockup-nav-item.active-item { background: var(--brand-primary); }

.mockup-tab-content {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: fadeIn 0.4s ease;
}
.mockup-header-simple {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 6px;
  text-align: left;
}

.mockup-content {
  flex: 1;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.mockup-kpis { display: flex; gap: 10px; }
.mockup-kpi {
  flex: 1;
  background: var(--bg-elevated);
  border-radius: 10px;
  padding: 10px;
  border: 1px solid var(--border-subtle);
}
.mkpi-label { font-size: 9px; color: var(--text-muted); margin-bottom: 4px; }
.mkpi-value { font-size: 13px; font-weight: 700; }
.mkpi-value.green { color: var(--success); }
.mkpi-value.red   { color: var(--danger); }
.mkpi-value.teal  { color: var(--brand-teal); }

.mockup-chart {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 60px;
  padding: 0 4px;
}
.mockup-bar-group { display: flex; align-items: flex-end; gap: 2px; flex: 1; }
.mockup-bar {
  flex: 1;
  background: rgba(62,207,142,0.5);
  border-radius: 3px 3px 0 0;
  transition: height 0.3s;
}
.mockup-bar.overdue { background: rgba(241,100,100,0.5); }

.mockup-rows { display: flex; flex-direction: column; gap: 6px; }
.mockup-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: var(--bg-elevated);
  border-radius: 8px;
}
.mockup-avatar {
  width: 24px; height: 24px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 9px; font-weight: 700; color: white;
  flex-shrink: 0;
}
.mockup-row-info { flex: 1; }
.mockup-row-name { height: 6px; background: var(--text-muted); border-radius: 3px; width: 70%; margin-bottom: 4px; }
.mockup-row-sub  { height: 4px; background: var(--bg-card); border-radius: 2px; width: 45%; }
.mockup-badge { font-size: 8px; font-weight: 600; padding: 2px 7px; border-radius: 99px; }
.mockup-badge.overdue-badge { background: var(--overdue); color: var(--danger); }
.mockup-badge.pending-badge { background: var(--pending); color: var(--warning); }
.mockup-badge.paid-badge    { background: var(--paid);    color: var(--success); }

/* ─── Trust Bar ──────────────────────────────────────────────── */
.trust-bar {
  padding: 40px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  overflow: hidden;
}
.trust-label {
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: var(--tracking-wide);
  color: var(--text-muted);
  margin-bottom: 20px;
}
.trust-track-wrapper { overflow: hidden; position: relative; }
.trust-track {
  display: flex;
  gap: 48px;
  width: max-content;
  animation: marquee 25s linear infinite;
}
.trust-logo {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-secondary);
  opacity: 0.4;
  white-space: nowrap;
  letter-spacing: 0.02em;
}

/* ─── Sections ───────────────────────────────────────────────── */
.section-header {
  text-align: center;
  margin-bottom: 64px;
}
.section-title {
  font-size: clamp(30px, 4.5vw, 54px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.08;
  margin-bottom: 16px;
}
.section-subtitle {
  font-size: 17px;
  color: var(--text-secondary);
  max-width: 480px;
  margin-inline: auto;
}

.features, .audience, .pricing { padding: 100px 0; }

/* ─── Features Bento Grid ────────────────────────────────────── */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto;
  gap: 20px;
}

/* ─── Audience Zigzag ────────────────────────────────────────── */
.audience-items { display: flex; flex-direction: column; gap: 80px; }
.audience-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 60px;
}
.audience-item.reverse .audience-text { order: 2; }
.audience-item.reverse .audience-visual { order: 1; }

.audience-text { position: relative; }
.audience-step {
  position: absolute;
  top: -20px;
  left: -20px;
  font-size: 120px;
  font-weight: 900;
  color: var(--brand-bright);
  opacity: 0.06;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}
.audience-badge {
  display: inline-block;
  padding: 4px 14px;
  background: rgba(249,115,22,0.12);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-btn);
  font-size: 13px;
  color: var(--brand-bright);
  font-weight: 600;
  margin-bottom: 16px;
}
.audience-text h3 {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}
.audience-text p { color: var(--text-secondary); line-height: 1.7; margin-bottom: 24px; }
.audience-features { display: flex; flex-direction: column; gap: 10px; margin-bottom: 28px; }
.audience-features li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-secondary); }
.audience-features svg { color: var(--brand-teal); flex-shrink: 0; }

.audience-visual { display: flex; justify-content: center; }
.audience-mockup {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-card);
  padding: 24px;
  width: 100%;
  max-width: 320px;
  box-shadow: var(--glow-purple);
}
.am-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; font-size: 14px; font-weight: 600; }
.am-badge { padding: 3px 10px; border-radius: 99px; font-size: 11px; font-weight: 700; }
.am-badge.overdue { background: var(--overdue); color: var(--danger); }
.am-badge.pending { background: var(--pending); color: var(--warning); }
.am-badge.paid    { background: var(--paid);    color: var(--success); }
.am-value { font-size: 28px; font-weight: 800; margin-bottom: 20px; }
.am-value.teal { color: var(--brand-teal); }
.am-actions { display: flex; gap: 8px; }
.am-btn {
  flex: 1;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 600;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-mid));
  color: white;
  text-align: center;
}
.am-btn.ghost { background: transparent; border: 1px solid var(--border-card); color: var(--text-secondary); }
.am-tone { font-size: 12px; color: var(--text-muted); }
.am-stat { font-size: 13px; color: var(--success); font-weight: 600; }
.formal-style { border-color: rgba(249,115,22,0.4); }

/* ─── Pricing ────────────────────────────────────────────────── */
.pricing-toggle {
  display: inline-flex;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-btn);
  padding: 4px;
  margin-top: 28px;
  gap: 4px;
}
.toggle-btn {
  padding: 8px 20px;
  border-radius: 99px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  transition: background var(--transition-smooth), color var(--transition-smooth);
  display: flex;
  align-items: center;
  gap: 6px;
}
.toggle-btn.active { background: var(--brand-primary); color: white; }
.toggle-badge {
  background: rgba(62,207,142,0.2);
  color: var(--success);
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 99px;
  font-weight: 700;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}

/* ─── CTA Final ──────────────────────────────────────────────── */
.cta-final {
  position: relative;
  padding: 100px 0;
  overflow: hidden;
}
.cta-bg {
  position: absolute;
  inset: 0;
}
.cta-content {
  position: relative;
  z-index: 1;
  text-align: center;
}
.cta-content h2 { font-size: clamp(32px, 5vw, 60px); font-weight: 800; line-height: 1.1; margin-bottom: 16px; letter-spacing: -0.03em; }
.cta-content > p { color: rgba(255,255,255,0.7); margin-bottom: 32px; font-size: 18px; }
.cta-proof { margin-top: 20px; font-size: 14px; color: rgba(255,255,255,0.5); }

/* ─── Footer ─────────────────────────────────────────────────── */
.footer { padding: 64px 0 32px; border-top: 1px solid var(--border-subtle); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}
.footer-brand .navbar-logo { margin-bottom: 16px; }
.footer-tagline { font-size: 14px; color: var(--text-muted); line-height: 1.6; margin-bottom: 24px; }
.footer-socials { display: flex; gap: 12px; }
.social-icon {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  color: var(--text-muted);
  transition: color var(--transition-fast), border-color var(--transition-fast);
}
.social-icon:hover { color: var(--brand-primary); border-color: var(--brand-primary); }
.footer-heading { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 16px; }
.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links a { font-size: 14px; color: var(--text-secondary); transition: color var(--transition-fast); }
.footer-links a:hover { color: var(--text-primary); }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid var(--border-subtle);
  font-size: 13px;
  color: var(--text-muted);
}

/* ─── Auth Screens ───────────────────────────────────────────── */
.auth-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  position: relative;
}
.auth-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 0%, rgba(249,115,22,0.15), transparent 70%);
  pointer-events: none;
}
.auth-back {
  position: absolute;
  top: 24px;
  left: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
  z-index: 1;
}
.auth-back:hover { color: var(--text-primary); }

/* ─── Dashboard Layout ───────────────────────────────────────── */
.dashboard-layout {
  display: flex;
  min-height: 100vh;
}
.dashboard-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  /* Light-mode layout: white base, dark blue text, royal/neon blue accents */
  --bg-base:       #F8FAFC;
  --bg-surface:    #FFFFFF;
  --bg-card:       #FFFFFF;
  --bg-elevated:   #F1F5F9;
  --text-primary:  #0A1628;
  --text-secondary:#334155;
  --text-muted:    #64748B;
  --border-subtle: rgba(37, 99, 235, 0.08);
  --border-card:   rgba(37, 99, 235, 0.12);
  --glass-bg:      rgba(255, 255, 255, 0.92);
  background: var(--bg-base);
  color: var(--text-primary);
}
.dashboard-content { flex: 1; padding: 24px; overflow-y: auto; }

/* ─── Sidebar ────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--bg-surface);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  transition: transform var(--transition-smooth);
}
.sidebar-header {
  padding: 20px 16px;
  border-bottom: 1px solid var(--border-subtle);
}
.sidebar-nav { flex: 1; padding: 16px 10px; display: flex; flex-direction: column; gap: 4px; }
.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast), border-left-color var(--transition-fast);
  border-left: 2px solid transparent;
  border-radius: 0 10px 10px 0;
  margin-left: -2px;
  white-space: nowrap;          /* nunca quebra linha */
  overflow: hidden;
  text-overflow: ellipsis;      /* "..." se ultrapassar */
}
.sidebar-nav-item svg { flex-shrink: 0; opacity: 0.7; }
.sidebar-nav-item:hover {
  background: rgba(37, 99, 235, 0.06);
  color: var(--brand-primary);
}
.sidebar-nav-item.active {
  background: rgba(37, 99, 235, 0.10);
  color: var(--brand-primary);
  border-left-color: var(--brand-primary);
}
.sidebar-nav-item.active svg { opacity: 1; }

.sidebar-footer {
  padding: 14px 16px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(180deg, transparent, rgba(124,58,237,.04));
  position: relative;
}
.sidebar-user-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-mid));
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(124,58,237,.35);
  border: 2px solid rgba(255,255,255,.08);
  color: white;
}
.sidebar-user-info { flex: 1; min-width: 0; }
.sidebar-user-info strong {
  display: block;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text-primary);
}
.sidebar-user-info span  {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.sidebar-logout {
  color: var(--text-muted);
  padding: 8px;
  border-radius: 8px;
  transition: color var(--transition-fast), background var(--transition-fast);
}
.sidebar-logout:hover { color: #EF4444; background: rgba(239,68,68,0.1); }

/* Dashboard Header */
.dashboard-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  position: sticky;
  top: 0;
  z-index: 10;
}
.dash-greeting h2 { font-size: 18px; font-weight: 700; line-height: 1.2; }
.dash-greeting span { font-size: 12px; color: var(--text-muted); }
.dash-search {
  flex: 1;
  max-width: 360px;
  margin-inline: auto;
  position: relative;
}
.dash-search input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-btn);
  padding: 9px 16px 9px 38px;
  font-size: 14px;
  color: var(--text-primary);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.dash-search input:focus { border-color: var(--brand-primary); box-shadow: var(--glow-purple); outline: none; }
.dash-search input::placeholder { color: var(--text-muted); }
.dash-search-icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }
.dash-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }

/* Perfil + configurações no header do painel */
.dash-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-primary), var(--brand-bright));
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--border-card);
  cursor: pointer;
  flex-shrink: 0;
  overflow: hidden;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}
.dash-avatar:hover { transform: scale(1.06); box-shadow: 0 6px 16px rgba(15,23,42,0.15); }

.dash-icon-btn {
  width: 38px; height: 38px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-secondary);
  border: 1px solid var(--border-card);
  background: var(--bg-surface);
  cursor: pointer;
  flex-shrink: 0;
  transition: background var(--transition-fast), color var(--transition-fast), transform var(--transition-fast);
}
.dash-icon-btn:hover { background: var(--bg-elevated); color: var(--text-primary); transform: rotate(20deg); }

/* Menu de perfil no header (avatar + nome/plano + sair) */
.dash-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 8px 5px 5px;
  border: 1px solid var(--border-card);
  border-radius: 999px;
  background: var(--bg-surface);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.dash-user:hover { border-color: var(--border-subtle); box-shadow: 0 4px 14px rgba(15,23,42,0.06); }
.dash-user-info {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  cursor: pointer;
  min-width: 0;
  max-width: 150px;
}
.dash-user-info strong {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dash-user-info span {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.dash-logout {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  cursor: pointer;
  flex-shrink: 0;
  transition: background var(--transition-fast), color var(--transition-fast);
}
.dash-logout:hover { background: rgba(239,68,68,0.10); color: var(--danger); }

/* ─── Card 'Uso do plano' em Configurações ─────────────────── */
.usage-card { border-radius: 18px; padding: 22px 24px; background: #fff; }
.usage-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 16px;
}
.usage-sub {
  font-size: 12.5px; color: var(--text-muted, #667085);
  margin: 4px 0 0;
}
.usage-plan-pill {
  padding: 5px 12px; border-radius: 999px;
  font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em;
  background: var(--bg-elevated, #F2F4F7); color: var(--text-secondary, #475467);
  border: 1px solid var(--border-card, #E4E7EC);
}
.usage-plan-pill[data-plan="pro"] {
  background: linear-gradient(135deg, rgba(124,58,237,.10), rgba(56,189,248,.10));
  color: #7C3AED;
  border-color: rgba(124,58,237,.35);
}
.usage-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}
.usage-item {
  padding: 12px 14px;
  background: var(--bg-elevated, #F2F4F7);
  border: 1px solid var(--border-subtle, #F0F2F5);
  border-radius: 12px;
}
.usage-item-head {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 10px; margin-bottom: 8px;
}
.usage-item-label { font-size: 12.5px; color: var(--text-secondary, #475467); font-weight: 700; }
.usage-item-val {
  font-size: 15px; font-weight: 800;
  color: var(--text-primary, #0B1220); white-space: nowrap;
}
.usage-item-val span {
  font-size: 11px; font-weight: 600;
  color: var(--text-muted, #667085);
}
.usage-bar {
  width: 100%; height: 6px; border-radius: 999px;
  background: rgba(15,23,42,.05); overflow: hidden;
}
.usage-bar-fill {
  height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, #10B981, #34D399);
  transition: width .35s ease;
}
.usage-warn .usage-bar-fill { background: linear-gradient(90deg, #F59E0B, #FBBF24); }
.usage-full .usage-bar-fill { background: linear-gradient(90deg, #EF4444, #F87171); }
.usage-locked {
  background: rgba(124,58,237,.06);
  border-color: rgba(124,58,237,.20);
}
.usage-locked .usage-item-val { color: #7C3AED; }

/* ─── Sino de notificações ─────────────────────────────────── */
.dash-notif { position: relative; }
/* Botão do sino ganha "aviso" quando tem badge */
.dash-notif:has(.notif-badge:not([hidden])) #notifBtn {
  color: #DC2626;
  border-color: rgba(239, 68, 68, 0.35);
  background: rgba(239, 68, 68, 0.06);
}
.dash-notif:has(.notif-badge:not([hidden])) #notifBtn:hover {
  background: rgba(239, 68, 68, 0.12);
  color: #B91C1C;
  transform: translateY(-1px);
}
/* Sininho balança de leve quando tem pendência */
.dash-notif:has(.notif-badge:not([hidden])) #notifBtn svg {
  animation: bellShake 3s ease-in-out infinite;
  transform-origin: 50% 20%;
}
@keyframes bellShake {
  0%, 92%, 100% { transform: rotate(0); }
  94% { transform: rotate(10deg); }
  96% { transform: rotate(-8deg); }
  98% { transform: rotate(6deg); }
}

.notif-badge {
  position: absolute; top: -4px; right: -4px;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 999px;
  background: linear-gradient(135deg, #F43F5E, #DC2626);
  color: #fff;
  font-size: 11px; font-weight: 800; line-height: 18px; text-align: center;
  border: 2px solid var(--bg-surface, #fff);
  box-shadow: 0 4px 10px rgba(239, 68, 68, 0.35);
  animation: badgePop .35s cubic-bezier(.22,.9,.3,1) both, badgePulse 2s ease-in-out infinite;
}
@keyframes badgePop {
  from { transform: scale(0); opacity: 0; }
  60%  { transform: scale(1.15); }
  to   { transform: scale(1); opacity: 1; }
}
@keyframes badgePulse {
  0%, 100% { box-shadow: 0 4px 10px rgba(239, 68, 68, 0.35), 0 0 0 0 rgba(239, 68, 68, 0.5); }
  50%      { box-shadow: 0 4px 10px rgba(239, 68, 68, 0.35), 0 0 0 6px rgba(239, 68, 68, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .notif-badge,
  .dash-notif:has(.notif-badge:not([hidden])) #notifBtn svg { animation: none; }
}
.notif-dropdown {
  position: absolute; top: calc(100% + 10px); right: 0; z-index: 60;
  width: 320px; max-width: calc(100vw - 32px);
  background: #fff; border: 1px solid var(--border-card, #E4E7EC);
  border-radius: 14px; box-shadow: 0 20px 50px rgba(15,23,42,.16);
  overflow: hidden;
}
.notif-dropdown[hidden] { display: none; }
.notif-head {
  display: flex; align-items: baseline; justify-content: space-between;
  padding: 14px 16px; border-bottom: 1px solid var(--border-subtle, #F0F2F5);
}
.notif-head strong { font-size: 14px; color: var(--text-primary, #0B1220); }
.notif-head span { font-size: 12px; color: var(--text-muted, #667085); }
.notif-body { max-height: 360px; overflow-y: auto; }
.notif-empty { padding: 28px 16px; text-align: center; font-size: 13px; color: var(--text-muted, #667085); }
.notif-item {
  width: 100%; display: flex; gap: 10px; align-items: stretch;
  padding: 11px 16px; background: #fff; border: none; cursor: pointer; text-align: left;
  border-bottom: 1px solid var(--border-subtle, #F0F2F5); transition: background .12s;
}
.notif-item:hover { background: var(--bg-elevated, #F2F4F7); }
.notif-item-bar { width: 3px; border-radius: 3px; flex-shrink: 0; }
.notif-item-main { flex: 1; min-width: 0; }
.notif-item-top { display: flex; justify-content: space-between; gap: 8px; }
.notif-item-top strong { font-size: 13px; color: var(--text-primary, #0B1220); }
.notif-item-val { font-size: 13px; font-weight: 800; color: var(--text-primary, #0B1220); white-space: nowrap; }
.notif-item-sub { display: block; font-size: 12px; color: var(--text-muted, #667085); margin-top: 2px; }
.notif-tag { font-weight: 700; }
.notif-tag.over  { color: #DC2626; }
.notif-tag.today { color: #D97706; }

/* ─── Busca global (resultados) ────────────────────────────── */
.gs-results {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 60;
  background: #fff; border: 1px solid var(--border-card, #E4E7EC);
  border-radius: 14px; box-shadow: 0 20px 50px rgba(15,23,42,.16);
  overflow: hidden; max-height: 380px; overflow-y: auto;
}
.gs-results[hidden] { display: none; }
.gs-group {
  padding: 8px 14px 4px; font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .05em; color: var(--text-muted, #667085);
}
.gs-empty { padding: 20px 16px; text-align: center; font-size: 13px; color: var(--text-muted, #667085); }
.gs-item {
  width: 100%; display: flex; align-items: center; gap: 10px;
  padding: 9px 14px; background: #fff; border: none; cursor: pointer; text-align: left;
  transition: background .12s;
}
.gs-item:hover { background: var(--bg-elevated, #F2F4F7); }
.gs-avatar {
  width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 13px;
}
.gs-dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.gs-main { display: flex; flex-direction: column; min-width: 0; }
.gs-main strong { font-size: 13px; color: var(--text-primary, #0B1220); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-main span { font-size: 12px; color: var(--text-muted, #667085); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* No celular, esconde nome/plano — deixa só avatar + sair */
@media (max-width: 640px) {
  .dash-user-info { display: none; }
  .dash-user { padding: 4px; gap: 4px; }
}

/* Dashboard Tabs */
.dashboard-tabs {
  display: flex;
  padding: 0 24px;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  overflow-x: auto;
  gap: 4px;
}
.dashboard-tabs::-webkit-scrollbar { height: 0; }
[data-tab] {
  padding: 14px 18px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: color var(--transition-fast), border-color var(--transition-fast);
  cursor: pointer;
}
[data-tab]:hover { color: var(--text-secondary); }
[data-tab].active { color: var(--text-primary); border-bottom-color: var(--brand-primary); }

.tab-panel { animation: fadeIn 0.2s ease; }
.tab-panel[hidden] { display: none; }

/* KPI Grid */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

/* Chart */
.chart-section {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-card);
  padding: 24px;
  margin-bottom: 24px;
}
.chart-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.chart-title { font-size: 15px; font-weight: 700; }
.chart-legend { display: flex; gap: 16px; }
.chart-legend-item { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-secondary); }
.legend-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.legend-dot.received { background: #38BDF8; }
.legend-dot.overdue  { background: var(--brand-primary); }

#dashChart {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  height: 160px;
}
.chart-group {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  height: 100%;
  justify-content: flex-end;
}
.chart-bars-wrap {
  flex: 1;
  width: 100%;
  display: flex;
  align-items: flex-end;
  gap: 3px;
}
.chart-bar {
  flex: 1;
  border-radius: 4px 4px 0 0;
  height: var(--h);
  transition: height 0.4s ease, opacity 0.2s;
  min-height: 4px;
}
.chart-bar:hover { opacity: 0.8; }
.received-bar { background: linear-gradient(to top, #38BDF8, rgba(56,189,248,0.5)); }
.overdue-bar  { background: linear-gradient(to top, #F16464, rgba(241,100,100,0.5)); }
.chart-label { font-size: 11px; color: var(--text-muted); }

/* Table */
.table-section {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-card);
  overflow-x: auto;
}
.table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-subtle);
}
.table-title { font-size: 15px; font-weight: 700; }
.table-search {
  position: relative;
  width: 260px;
}
.table-search input {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-btn);
  padding: 8px 14px 8px 34px;
  font-size: 13px;
  color: var(--text-primary);
}
.table-search input:focus { border-color: var(--brand-primary); outline: none; }
.table-search input::placeholder { color: var(--text-muted); }
.search-icon-sm { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--text-muted); }
.charges-table { width: 100%; border-collapse: collapse; }
.charges-table th {
  padding: 12px 20px;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-subtle);
  white-space: nowrap;
}
.charges-table td { padding: 14px 20px; border-bottom: 1px solid var(--border-subtle); vertical-align: middle; }
.table-row { transition: background var(--transition-fast); }
.table-row:hover { background: var(--bg-elevated); }
.table-row:last-child td { border-bottom: none; }

.client-cell { display: flex; align-items: center; gap: 10px; }
.client-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; color: white;
  flex-shrink: 0;
}
.client-info { display: flex; flex-direction: column; }
.client-name { font-size: 14px; font-weight: 600; line-height: 1.3; }
.client-company { font-size: 12px; color: var(--text-muted); }
.td-value { font-size: 14px; font-weight: 700; }
.td-date { font-size: 13px; color: var(--text-secondary); }

.row-actions { display: flex; gap: 6px; }
.icon-btn {
  width: 32px; height: 32px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  background: transparent;
  transition: background var(--transition-fast), color var(--transition-fast);
}
.icon-btn:hover       { background: var(--bg-elevated); color: var(--text-primary); }
.icon-btn.teal:hover  { background: rgba(6,182,212,0.1); color: var(--brand-teal); }
.icon-btn.danger:hover{ background: rgba(241,100,100,0.1); color: var(--danger); }

.table-footer {
  display: flex;
  justify-content: flex-end;
  padding: 14px 20px;
  border-top: 1px solid var(--border-subtle);
}
.pag-info { font-size: 13px; color: var(--text-muted); margin-right: 12px; display: flex; align-items: center; }
.pag-btns { display: flex; gap: 6px; }
.pag-btn {
  width: 32px; height: 32px;
  border-radius: 8px;
  font-size: 13px;
  background: var(--bg-elevated);
  color: var(--text-secondary);
  transition: background var(--transition-fast), color var(--transition-fast);
}
.pag-btn.active  { background: var(--brand-primary); color: white; }
.pag-btn:hover:not(.active) { background: var(--bg-card); }

/* AI Panel */
.ai-panel { display: grid; grid-template-columns: 2fr 3fr; gap: 24px; min-height: 520px; }
.ai-config-panel, .ai-output-panel { background: var(--bg-card); border: 1px solid var(--border-card); border-radius: var(--radius-card); padding: 24px; }
.ai-section-title { font-size: 15px; font-weight: 700; margin-bottom: 20px; display: flex; align-items: center; gap: 8px; }
.ai-field { margin-bottom: 16px; }
.ai-field label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; }

.tone-group { display: flex; gap: 6px; flex-wrap: wrap; }
.tone-btn {
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid var(--border-card);
  color: var(--text-secondary);
  background: transparent;
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}
.tone-btn:hover { border-color: var(--brand-primary); color: var(--text-primary); transform: translateY(-1px); }
.tone-btn.active { background: linear-gradient(135deg, var(--brand-primary), var(--brand-mid)); color: white; border-color: transparent; box-shadow: 0 4px 14px rgba(124,58,237,.25); }

/* Alternador IA / Custom no modal de lembrete */
.rm-mode {
  display: inline-flex; gap: 4px; padding: 4px;
  background: var(--bg-elevated, #F2F4F7);
  border: 1px solid var(--border-card, #E4E7EC);
  border-radius: 999px; margin-bottom: 12px;
  flex-wrap: wrap;
}
.rm-mode-btn {
  background: transparent; border: none;
  padding: 7px 14px; border-radius: 999px;
  font-size: 12.5px; font-weight: 700;
  color: var(--text-secondary, #475467);
  font-family: inherit; cursor: pointer;
  transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.rm-mode-btn:hover { color: var(--text-primary, #0B1220); }
.rm-mode-btn.active {
  background: #fff; color: var(--text-primary, #0B1220);
  box-shadow: 0 1px 3px rgba(15,23,42,0.08), 0 4px 12px rgba(15,23,42,0.05);
}
.rm-pane[hidden] { display: none; }
.rm-hint {
  font-size: 12px; color: var(--text-muted, #667085);
  margin: 0 0 10px; line-height: 1.4;
}
.rm-pane textarea { resize: vertical; min-height: 100px; }

/* Ações do modo custom (botão melhorar + hint) */
.rm-custom-actions {
  display: flex; align-items: center; gap: 12px;
  flex-wrap: wrap; margin-top: 8px;
}
#rmImproveBtn {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--brand-primary, #2563EB);
  border: 1px dashed rgba(37,99,235,0.35);
  background: rgba(37,99,235,0.05);
}
#rmImproveBtn:hover { background: rgba(37,99,235,0.10); }
#rmImproveBtn.loading { color: transparent; }

/* Chips de método de pagamento (multi-select) */
.rm-pay {
  display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 6px;
}
.rm-pay-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border-card, #E4E7EC);
  color: var(--text-secondary, #475467);
  font-family: inherit; font-size: 12.5px; font-weight: 700;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}
.rm-pay-btn:hover { border-color: var(--brand-ink, #0F172A); color: var(--text-primary, #0B1220); transform: translateY(-1px); }
.rm-pay-btn.active {
  background: linear-gradient(135deg, #10B981, #34D399);
  color: #fff; border-color: transparent;
  box-shadow: 0 4px 14px rgba(16,185,129,.25);
}
.rm-pay-btn span { font-size: 14px; line-height: 1; }

/* ─── Listas 'Aguardando' e 'Enviadas' no painel IA ─────────── */
.ai-schedules {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 24px;
}
.ai-schedules-col {
  background: #fff;
  border: 1px solid var(--border-card, #E4E7EC);
  border-radius: 18px;
  padding: 18px 20px;
}
.ai-schedules-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 10px; margin-bottom: 12px;
}
.ai-schedules-head h3 {
  font-size: 14px; font-weight: 800; margin: 0;
  color: var(--text-primary, #0B1220);
}
.ai-schedules-count {
  min-width: 24px; padding: 2px 8px;
  border-radius: 999px;
  background: var(--bg-elevated, #F2F4F7);
  font-size: 11px; font-weight: 800;
  color: var(--text-secondary, #475467);
  text-align: center;
}
.ai-schedules-list {
  display: flex; flex-direction: column; gap: 8px;
  max-height: 380px; overflow-y: auto;
}
.ai-sched-item {
  position: relative;
  display: flex; flex-direction: column; gap: 4px;
  padding: 10px 12px;
  background: var(--bg-elevated, #F2F4F7);
  border-radius: 10px;
  border: 1px solid var(--border-subtle, #F0F2F5);
  transition: border-color .15s ease;
}
.ai-sched-item:hover { border-color: var(--border-card, #E4E7EC); }
.ai-sched-item-head {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 8px;
}
.ai-sched-item-head strong {
  font-size: 13px; font-weight: 700;
  color: var(--text-primary, #0B1220);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ai-sched-chan {
  font-size: 10.5px; font-weight: 700;
  color: var(--text-muted, #667085);
  text-transform: uppercase; letter-spacing: .04em;
  flex-shrink: 0;
}
.ai-sched-when {
  font-size: 12px; color: var(--text-secondary, #475467);
  font-weight: 700;
}
.ai-sched-preview {
  font-size: 12px; color: var(--text-muted, #667085);
  line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.ai-sched-cancel {
  position: absolute; top: 8px; right: 8px;
  width: 20px; height: 20px; border-radius: 50%;
  background: transparent; border: none; font-size: 16px; line-height: 1;
  color: var(--text-muted, #667085);
  cursor: pointer; transition: background .15s ease, color .15s ease;
}
.ai-sched-cancel:hover {
  background: rgba(239,68,68,.10);
  color: var(--danger, #EF4444);
}

@media (max-width: 900px) {
  .ai-schedules { grid-template-columns: 1fr; }
}
.tone-btn .tone-emoji { font-size: 14px; line-height: 1; }
.tone-group-expanded { gap: 8px; }

.ai-label-hint {
  font-weight: 400;
  color: var(--text-muted);
  font-size: 12px;
  margin-left: 4px;
}

.tone-custom-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.02);
  border: 1px dashed var(--border-subtle);
  border-radius: 10px;
  transition: border-color .15s ease, background .15s ease;
}
.tone-custom-wrap:focus-within {
  border-color: var(--brand-primary);
  border-style: solid;
  background: rgba(124,58,237,.05);
}
.tone-custom-wrap svg { color: var(--text-muted); flex-shrink: 0; }
.tone-custom-input {
  flex: 1;
  border: none;
  background: transparent;
  outline: none;
  color: var(--text-primary);
  font-size: 13px;
  font-family: inherit;
  padding: 0;
}
.tone-custom-input::placeholder { color: var(--text-muted); font-style: italic; }
.tone-custom-input.has-value ~ .tone-btn { opacity: .5; }

/* Output terminal */
.output-terminal {
  background: #080E1A;
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: var(--radius-card);
  overflow: hidden;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 280px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}
.terminal-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(56, 189, 248, 0.15);
  background: #0F172A;
}
.terminal-dot { width: 10px; height: 10px; border-radius: 50%; }
.terminal-dot:nth-child(1) { background: #FF5F56; }
.terminal-dot:nth-child(2) { background: #FFBD2E; }
.terminal-dot:nth-child(3) { background: #27C93F; }
.terminal-label { margin-left: 8px; font-size: 11px; color: #94A3B8; font-weight: 700; letter-spacing: 0.06em; }
.terminal-body { padding: 20px; flex: 1; overflow-y: auto; background: #080E1A; }
#aiOutputText {
  font-family: 'Courier New', monospace;
  font-size: 14.5px;
  line-height: 1.8;
  color: #F8FAFC;
  white-space: pre-wrap;
  word-break: break-word;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}
.ai-output-actions { display: flex; gap: 10px; margin-top: 16px; }

.ai-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 40px;
  color: #64748B;
  text-align: center;
}
.ai-empty svg { opacity: 0.6; color: #64748B; }
.ai-empty p { font-size: 14px; color: #94A3B8; }
.ai-empty strong { color: var(--brand-bright); }

/* Reminders */
.reminder-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  margin-bottom: 10px;
  transition: border-color var(--transition-fast);
}
.reminder-item:hover { border-color: var(--border-card); }
.reminder-inactive { opacity: 0.5; }
.reminder-avatar { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; color: white; flex-shrink: 0; }
.reminder-info { display: flex; flex-direction: column; flex: 1; }
.reminder-info strong { font-size: 14px; font-weight: 600; }
.reminder-info span   { font-size: 12px; color: var(--text-muted); }
.reminder-meta { display: flex; flex-direction: column; align-items: flex-end; }
.reminder-channel { font-size: 13px; color: var(--text-secondary); }
.reminder-time    { font-size: 11px; color: var(--text-muted); }

/* ─── Detailed Features Grid ─────────────────────────────────── */
.bento-grid-detailed {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.feat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: 20px;
  padding: 32px 24px;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
              box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  z-index: 1;
}

/* Dynamic background glow and gradient top line on hover */
.feat-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at top right, var(--card-glow, rgba(124, 58, 237, 0.1)), transparent 70%);
  z-index: -1;
  border-radius: inherit;
  opacity: 0.3;
  transition: opacity 0.4s ease;
}
.feat-card::after {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--card-gradient);
  opacity: 0;
  transition: opacity 0.4s ease;
}
.feat-card:hover {
  transform: translateY(-6px);
  border-color: var(--card-glow);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12), 0 0 24px var(--card-glow);
}
.feat-card:hover::before {
  opacity: 0.8;
}
.feat-card:hover::after {
  opacity: 1;
}

/* Individual card visual configurations */
.feat-card:nth-child(1) {
  --card-glow: rgba(59, 130, 246, 0.2);
  --card-gradient: linear-gradient(135deg, #3B82F6 0%, #8B5CF6 100%);
  --icon-bg: rgba(59, 130, 246, 0.08);
}
.feat-card:nth-child(2) {
  --card-glow: rgba(236, 72, 153, 0.2);
  --card-gradient: linear-gradient(135deg, #EC4899 0%, #8B5CF6 100%);
  --icon-bg: rgba(236, 72, 153, 0.08);
}
.feat-card:nth-child(3) {
  --card-glow: rgba(16, 185, 129, 0.2);
  --card-gradient: linear-gradient(135deg, #10B981 0%, #059669 100%);
  --icon-bg: rgba(16, 185, 129, 0.08);
}
.feat-card:nth-child(4) {
  --card-glow: rgba(245, 158, 11, 0.2);
  --card-gradient: linear-gradient(135deg, #F59E0B 0%, #EF4444 100%);
  --icon-bg: rgba(245, 158, 11, 0.08);
}
.feat-card:nth-child(5) {
  --card-glow: rgba(139, 92, 246, 0.2);
  --card-gradient: linear-gradient(135deg, #8B5CF6 0%, #3B82F6 100%);
  --icon-bg: rgba(139, 92, 246, 0.08);
}
.feat-card:nth-child(6) {
  --card-glow: rgba(244, 63, 94, 0.2);
  --card-gradient: linear-gradient(135deg, #F43F5E 0%, #E11D48 100%);
  --icon-bg: rgba(244, 63, 94, 0.08);
}
.feat-card:nth-child(7) {
  --card-glow: rgba(14, 165, 233, 0.2);
  --card-gradient: linear-gradient(135deg, #0EA5E9 0%, #2563EB 100%);
  --icon-bg: rgba(14, 165, 233, 0.08);
}
.feat-card:nth-child(8) {
  --card-glow: rgba(100, 116, 139, 0.2);
  --card-gradient: linear-gradient(135deg, #64748B 0%, #334155 100%);
  --icon-bg: rgba(100, 116, 139, 0.08);
}

.feat-icon-wrapper {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--icon-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  flex-shrink: 0;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.1);
}
.feat-card:hover .feat-icon-wrapper {
  transform: scale(1.05) translateY(-2px);
}

.feat-card h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
  letter-spacing: -0.3px;
}
.feat-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

/* Toggle Switch */
.toggle-switch { position: relative; display: inline-block; width: 40px; height: 22px; flex-shrink: 0; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-elevated);
  border-radius: 99px;
  transition: background var(--transition-smooth);
  cursor: pointer;
  border: 1px solid var(--border-subtle);
}
.toggle-slider::after {
  content: '';
  position: absolute;
  width: 16px; height: 16px;
  background: var(--text-muted);
  border-radius: 50%;
  top: 2px; left: 2px;
  transition: transform var(--transition-smooth), background var(--transition-smooth);
}
.toggle-switch input:checked + .toggle-slider { background: rgba(37, 99, 235, 0.25); border-color: var(--brand-primary); }
.toggle-switch input:checked + .toggle-slider::after { transform: translateX(18px); background: var(--brand-primary); }

/* Charge Detail */
.detail-row { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--border-subtle); font-size: 14px; }
.detail-row:last-child { border-bottom: none; }
.detail-row span { color: var(--text-muted); }
.value-highlight { color: var(--success); font-size: 18px; }
.danger-text { color: var(--danger); }

/* Empty State */
.empty-state { text-align: center; padding: 48px; color: var(--text-muted); font-size: 14px; }

/* Settings */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.settings-card { background: var(--bg-card); border: 1px solid var(--border-card); border-radius: var(--radius-card); padding: 24px; }
.settings-card h3 { font-size: 15px; font-weight: 700; margin-bottom: 16px; }

/* ─── Responsive ─────────────────────────────────────────────── */
@media (min-width: 768px) {
  .navbar-links { display: flex; }
  .navbar-ctas  { display: flex; }
  .navbar-hamburger { display: none; }
}

@media (min-width: 1024px) {
  .container { padding-inline: 40px; }
}

@media (max-width: 1023px) {
  .bento-grid     { grid-template-columns: 1fr 1fr; }
  .bento-grid-detailed { grid-template-columns: repeat(2, 1fr); }
  .pricing-grid   { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; }
  .footer-grid    { grid-template-columns: 1fr 1fr; }
  .kpi-grid       { grid-template-columns: 1fr 1fr; }
  .ai-panel       { grid-template-columns: 1fr; }
  .settings-grid  { grid-template-columns: 1fr; }
}

@media (max-width: 767px) {
  .audience-item, .audience-item.reverse { grid-template-columns: 1fr; gap: 32px; }
  .audience-item.reverse .audience-text  { order: 0; }
  .audience-item.reverse .audience-visual{ order: 0; }
  .bento-grid     { grid-template-columns: 1fr; }
  .bento-grid-detailed { grid-template-columns: 1fr; }
  .footer-grid    { grid-template-columns: 1fr; }
  .kpi-grid       { grid-template-columns: 1fr 1fr; }
  .sidebar        { position: fixed; left: 0; top: 0; bottom: 0; z-index: 50; transform: translateX(-100%); }
  .sidebar.sidebar-open { transform: translateX(0); }
  .dashboard-header {
    padding: 12px 16px;
    flex-wrap: wrap;
    gap: 12px;
  }
  .dash-greeting {
    flex: 1;
    min-width: 0;
  }
  .dash-greeting h2 {
    font-size: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .dash-greeting span {
    display: block;
    font-size: 11px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .dash-search {
    order: 3;
    flex: 1 0 100%;
    max-width: 100%;
    margin-inline: 0;
  }
  .dash-actions {
    margin-left: auto;
    order: 2;
  }
  .dash-actions .btn {
    padding: 6px 10px;
    font-size: 12px;
  }
  .dashboard-content{ padding: 16px; }
  .charges-table th:nth-child(4),
  .charges-table td:nth-child(4) { display: none; }
}

@media (max-width: 480px) {
  .kpi-grid { grid-template-columns: 1fr; }
  .table-header { padding: 16px; flex-direction: column; align-items: flex-start; gap: 12px; }
  .table-header .btn { width: 100%; }
}
