/* ============================================================
   VISI MARKETING CRM — GLOBAL
   Variáveis, reset, tipografia, layout base, botões
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* ---- CSS VARIABLES ---- */
:root {
  --cyan: #1ACEEE;
  --cyan-dim: rgba(26, 206, 238, 0.15);
  --cyan-mid: rgba(26, 206, 238, 0.35);
  --black: #0D0D0D;
  --black-2: #111111;
  --black-3: #1A1A1A;
  --white: #FFFFFF;
  --bg: #ECEEF2;
  --card-dark: #0F0F0F;
  --card-light: #FFFFFF;
  --text-muted: #aaaaaa;
  --text-secondary: #666666;
  --border-light: rgba(0,0,0,0.07);
  --border-dark: rgba(255,255,255,0.08);
  --sidebar-w: 240px;
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --shadow: 0 4px 24px rgba(0,0,0,0.07);
  --shadow-dark: 0 8px 32px rgba(0,0,0,0.25);
  --transition: all 0.22s ease;
}

[data-theme="dark"] {
  --cyan: #1ACEEE;
  --cyan-dim: rgba(26, 206, 238, 0.15);
  --cyan-mid: rgba(26, 206, 238, 0.35);
  
  /* Text and background inversions */
  --black: #FFFFFF;
  --black-2: #FAFAFA;
  --black-3: #F0F0F0;
  
  --white: #111111; /* Elements that were white (like cards) */
  --bg: #000000; /* Main background pure black */
  
  --card-dark: #161616;
  --card-light: #0D0D0D;
  
  --text-muted: #666666;
  --text-secondary: #aaaaaa;
  
  --border-light: rgba(255, 255, 255, 0.08);
  --border-dark: rgba(0, 0, 0, 0.07);
  
  --shadow: 0 4px 24px rgba(0,0,0,0.4);
}

/* ---- RESET & BASE ---- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  font-family: 'Inter', sans-serif;
  background-color: var(--bg);
  color: var(--black);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ---- APP SHELL ---- */
.app-shell {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* ---- MAIN CONTENT AREA ---- */
.main-content {
  flex: 1;
  overflow-y: auto;
  padding: 32px 32px 40px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0,0,0,0.15) transparent;
}

.main-content::-webkit-scrollbar { width: 6px; }
.main-content::-webkit-scrollbar-thumb {
  background: rgba(0,0,0,0.12);
  border-radius: 6px;
}

/* ---- PAGE HEADER ---- */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 28px;
}

.page-title-block h1 {
  font-size: 26px;
  font-weight: 800;
  color: var(--black);
  letter-spacing: -0.5px;
  line-height: 1.2;
}

.page-title-block p {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: var(--black);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--black-3);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.btn-cyan {
  background: var(--cyan);
  color: var(--black);
}
.btn-cyan:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(26, 206, 238, 0.35);
}

.btn-ghost {
  background: var(--white);
  color: var(--black);
  border: 1px solid var(--border-light);
}
.btn-ghost:hover { background: var(--bg); }

.btn svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---- PAGE TRANSITIONS ---- */
.page-outlet {
  animation: pageFadeIn 0.25s ease;
}

@keyframes pageFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---- EMPTY / PLACEHOLDER STATE ---- */
.placeholder-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 60vh;
  gap: 16px;
  text-align: center;
  color: var(--text-muted);
}

.placeholder-page .placeholder-icon {
  width: 64px;
  height: 64px;
  border-radius: 20px;
  background: var(--white);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-page .placeholder-icon svg {
  width: 28px;
  height: 28px;
  stroke: var(--text-muted);
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.placeholder-page h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--black);
}

.placeholder-page p {
  font-size: 13px;
  color: var(--text-secondary);
  max-width: 320px;
}

/* ---- ANIMATIONS ---- */
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---- RESPONSIVE ---- */
@media (max-width: 768px) {
  .main-content { padding: 20px 16px; }
  .page-header { flex-direction: column; gap: 12px; }
}
