/* ===== JK Pinturas - Sistema Compartilhado =====
 * Stitch Modern Atelier Design System
 */

:root {
  /* Cores exatas do Stitch Modern Atelier */
  --background: #FAF6EE;
  --on-background: #1a1b21;
  --surface: #faf8ff;
  --surface-dim: #d9d9e2;
  --surface-bright: #faf8ff;
  --surface-container-lowest: #ffffff;
  --surface-container-low: #f3f3fb;
  --surface-container: #ededf6;
  --surface-container-high: #e8e7f0;
  --surface-container-highest: #e2e2ea;
  --on-surface: #1a1b21;
  --on-surface-variant: #434652;
  --outline: #737784;
  --outline-variant: #c3c6d4;
  --surface-tint: #2a5ab8;
  
  /* Cores primárias */
  --primary: #0043a1;
  --on-primary: #ffffff;
  --primary-container: #0043a1;
  --on-primary-container: #9ab6ff;
  --inverse-primary: #b1c6ff;
  --primary-fixed: #d9e2ff;
  --primary-fixed-dim: #b1c6ff;
  --on-primary-fixed: #001946;
  
  /* Cores secundárias */
  --secondary: #4f5e83;
  --on-secondary: #ffffff;
  --secondary-container: #c5d4ff;
  --on-secondary-container: #4c5b80;
  
  /* Cores de erro */
  --error: #ba1a1a;
  --on-error: #ffffff;
  --error-container: #ffdad6;
  --on-error-container: #93000a;
  
  /* Cores legado (para compatibilidade) */
  --ink: var(--on-background);
  --ink-2: #2e3037;
  --paper: var(--background);
  --paper-2: var(--surface-container);
  --rule: var(--outline-variant);
  --muted: var(--on-surface-variant);
  --accent: var(--primary);
  
  /* Cores da marca JK */
  --jk-blue: #0043a1;
  --jk-blue-deep: #002e74;
  --jk-red: #ba1a1a;
  --jk-yellow: #d9a441;
  --jk-green: #2ba84a;
  
  /* Tipografia */
  --f-display: "Space Grotesk", system-ui, sans-serif;
  --f-headline: "Space Grotesk", system-ui, sans-serif;
  --f-editorial: "Newsreader", Georgia, serif;
  --f-serif: "Newsreader", Georgia, serif;
  --f-body: "Inter", system-ui, sans-serif;
  --f-mono: "JetBrains Mono", monospace;
  --f-label: "Space Grotesk", system-ui, sans-serif;
  
  /* Espaçamento */
  --spacing-unit: 8px;
  --spacing-xs: 8px;
  --spacing-sm: 16px;
  --spacing-md: 24px;
  --spacing-lg: 48px;
  --spacing-xl: 80px;
  --spacing-xxl: 128px;
  --container-max: 1440px;
  --gutter: 32px;
  --container-padding: 64px;
  
  /* Border radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 22px;
  --radius-xl: 24px;
  --radius-full: 9999px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

img {
  max-width: 100%;
  display: block;
}

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

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

/* Utilitários tipográficos */
.font-display { font-family: var(--f-display); }
.font-editorial { font-family: var(--f-editorial); font-style: italic; }
.font-body { font-family: var(--f-body); }
.font-mono { font-family: var(--f-mono); }

/* Container */
.container {
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-padding);
}

/* WhatsApp FAB - botão fixo + ondas */
.wa-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: #25D366;
  color: white;
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.4);
  overflow: visible;
}

.wa-fab:hover {
  transform: scale(1.08);
}

/* Ícone fixo acima de tudo */
.wa-ico {
  position: relative;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  pointer-events: none;
}

.wa-ico svg {
  width: 28px;
  height: 28px;
}

/* Ondas usando pseudo-elementos */
.wa-fab::before,
.wa-fab::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25D366;
  z-index: -1;
  pointer-events: none;
}

.wa-fab::before {
  animation: wa-pulse 3.5s ease-out 1.2s infinite;
}

.wa-fab::after {
  animation: wa-pulse 3.5s ease-out 2.4s infinite;
}

.wa-fab .wa-wave {
  position: absolute;
  top: 0;
  left: 0;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25D366;
  z-index: -1;
  pointer-events: none;
  animation: wa-pulse 3.5s ease-out infinite;
}

@keyframes wa-pulse {
  0% {
    transform: scale(1);
    opacity: 0.6;
  }
  100% {
    transform: scale(2.2);
    opacity: 0;
  }
}

@media print {
  .wa-fab { display: none; }
}
