:root {
  --bg: #f6f3ed;
  --bg-2: #ece7de;
  --paper: #fffcf7;
  --paper-trans: rgba(255, 252, 247, 0.92);
  --fg: #2c323a;
  --hero: #232932;
  --hero-light: #2c3440;
  --muted: #57606c;
  --accent: #b8954a;
  --accent-light: #dfcaa0;
  --gold: #c9a66a;
  --gold-glow: rgba(201, 166, 106, 0.18);
  --slate: #7c8594;
  --sand: #c4b49a;
  --ok: #2e6047;
  --ok-hover: #26533c;
  --border: rgba(44, 50, 58, 0.12);
  --border-light: rgba(44, 50, 58, 0.07);
  --line-inv: rgba(246, 243, 237, 0.14);
  --sans: "Source Sans 3", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --display: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  --shadow-sm: 0 2px 8px rgba(44, 50, 58, 0.05);
  --shadow-md: 0 8px 24px -4px rgba(44, 50, 58, 0.08);
  --shadow-lg: 0 16px 32px -6px rgba(44, 50, 58, 0.12);
  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  max-width: 100vw;
}

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

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 500;
  margin: 0;
  line-height: 1.15;
  text-wrap: balance;
}

p {
  margin: 0;
  text-wrap: pretty;
}

button, [role="button"] {
  cursor: pointer;
  font-family: inherit;
  border: none;
  background: none;
}

.wrap {
  width: min(1120px, calc(100% - 2.5rem));
  margin-inline: auto;
}

.kicker {
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}

.rule {
  width: 4rem;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  margin: 1.5rem 0;
}

.muted { color: var(--muted); }
.sand { color: var(--sand); }
.gold { color: var(--gold); }

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: var(--paper-trans);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 4.5rem;
  position: relative;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
}

.brand img {
  height: 2.6rem;
  width: auto;
  transition: transform 0.25s ease;
}

.brand:hover img {
  transform: scale(1.04);
}

.brand-name {
  display: block;
  font-family: var(--display);
  font-size: 0.95rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--fg);
}

.brand-sub {
  display: block;
  font-size: 0.65rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--slate);
  margin-top: 0.1rem;
}

/* Menu Toggle Button */
.menu-btn {
  display: none;
  align-items: center;
  gap: 0.6rem;
  border: 1px solid var(--border);
  background: var(--paper);
  border-radius: 999px;
  padding: 0.5rem 0.9rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg);
  min-height: 42px;
  transition: var(--transition);
}

.menu-btn:hover {
  background: var(--bg-2);
  border-color: var(--accent);
}

.menu-icon {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 16px;
  height: 12px;
}

.menu-icon span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--fg);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.menu-btn.open .menu-icon span:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}

.menu-btn.open .menu-icon span:nth-child(2) {
  opacity: 0;
}

.menu-btn.open .menu-icon span:nth-child(3) {
  transform: translateY(-5px) rotate(-45deg);
}

/* Desktop Navigation */
nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
}

nav a {
  position: relative;
  opacity: 0.8;
  padding: 0.25rem 0;
  transition: opacity 0.2s ease, color 0.2s ease;
}

nav a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--accent);
  transition: width 0.25s ease;
}

nav a:hover {
  opacity: 1;
  color: var(--accent);
}

nav a:hover::after {
  width: 100%;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--paper);
  border-bottom: 1px solid var(--border);
}

.hero-bg {
  pointer-events: none;
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 15% 20%, rgba(201, 166, 106, 0.14), transparent 60%),
    radial-gradient(ellipse at 85% 75%, rgba(124, 133, 148, 0.1), transparent 55%),
    linear-gradient(to bottom, transparent 80%, rgba(246, 243, 237, 0.5));
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 3.5rem;
  align-items: center;
  padding: 4.5rem 0 5.5rem;
}

.hero-logo {
  max-width: 25rem;
  margin-inline: auto;
  border-radius: 1.5rem;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  background: #ffffff;
  border: 1px solid var(--border-light);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-logo:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.hero-logo img {
  width: 100%;
  height: auto;
}

.eyebrow {
  margin-bottom: 1.25rem;
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--slate);
  font-weight: 500;
  line-height: 1.6;
}

h1 {
  font-size: clamp(2.4rem, 5vw, 3.85rem);
  letter-spacing: -0.02em;
  color: var(--fg);
}

h1 em {
  font-style: italic;
  color: var(--accent);
  font-weight: 400;
}

.lead {
  max-width: 48ch;
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--muted);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2.25rem;
}

/* ==========================================================================
   Buttons & Micro-interactions
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0 1.5rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid var(--border);
  background: var(--paper);
  color: var(--fg);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.btn:hover {
  background: var(--bg-2);
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn:active {
  transform: translateY(0);
}

.btn-gold {
  background: var(--accent);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 4px 14px rgba(184, 149, 74, 0.35);
}

.btn-gold:hover {
  background: #a3823d;
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(184, 149, 74, 0.45);
}

.btn-wa {
  background: var(--ok);
  color: #ffffff;
  border-color: transparent;
  box-shadow: 0 4px 14px rgba(46, 96, 71, 0.3);
}

.btn-wa:hover {
  background: var(--ok-hover);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(46, 96, 71, 0.4);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none !important;
}

/* ==========================================================================
   Sections & Layouts
   ========================================================================== */
.section {
  padding: 5.5rem 0;
}

.bg-2 {
  background: var(--bg-2);
}

.dark {
  background: var(--hero);
  color: var(--paper);
}

.dark .kicker {
  color: var(--gold);
}

h2 {
  margin-top: 0.5rem;
  font-size: clamp(2rem, 3.8vw, 2.6rem);
  letter-spacing: -0.01em;
}

.intro {
  margin: 0.85rem 0 2.25rem;
  max-width: 62ch;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.65;
}

.dark .intro, .dark .lead {
  color: var(--sand);
}

/* Retrato */
.portrait {
  display: grid;
  gap: 3rem;
  align-items: center;
}

.portrait img {
  width: 100%;
  max-width: 28rem;
  margin-inline: auto;
  border-radius: 1rem;
  object-fit: cover;
  object-position: top;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-light);
}

/* Cards de Atuação */
.cards-2 {
  display: grid;
  gap: 1.25rem;
}

.card {
  border: 1px solid var(--border);
  background: var(--paper);
  border-radius: 1.25rem;
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}

.card .tag {
  margin-bottom: 0.6rem;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
}

.card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.6rem;
  font-family: var(--sans);
  color: var(--fg);
}

.card p {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.85rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.card-link:hover {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

/* Timeline */
.timeline {
  display: grid;
  gap: 0;
  list-style: none;
  padding: 0;
  margin: 0;
}

.timeline li {
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 1.25rem;
  border-top: 1px solid var(--line-inv);
  padding: 1.35rem 0;
  color: var(--sand);
  align-items: baseline;
  transition: background 0.2s ease;
}

.timeline time {
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 600;
}

/* Livros & Artigos */
.books {
  display: grid;
  gap: 1.5rem;
}

.books article {
  display: grid;
  gap: 0.35rem;
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 0;
  transition: transform 0.2s ease;
}

.books article:last-child {
  border-bottom: 0;
}

.books h3 {
  font-size: 1.35rem;
  color: var(--fg);
}

.articles {
  list-style: none;
  padding: 0;
  margin: 0;
  color: var(--muted);
}

.articles li {
  padding: 0.5rem 0;
  line-height: 1.6;
  border-bottom: 1px dashed var(--border-light);
}

.articles li:last-child {
  border-bottom: none;
}

/* Passos / Deontologia */
.steps {
  display: grid;
  gap: 1rem;
}

.step {
  border-top: 3px solid var(--accent);
  background: var(--paper);
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.step:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.step b {
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  color: var(--accent);
  display: block;
}

.step h3 {
  margin: 0.6rem 0 0.35rem;
  font-family: var(--sans);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--fg);
}

.step p {
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.6;
}

/* ==========================================================================
   Formulário de Contato
   ========================================================================== */
.form {
  display: grid;
  gap: 1.25rem;
  max-width: 38rem;
  margin-top: 2.25rem;
}

.row {
  display: grid;
  gap: 1.25rem;
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sand);
}

input, select, textarea {
  width: 100%;
  height: 3rem;
  border-radius: 0.6rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  padding: 0 0.9rem;
  font-size: 1rem;
  color: #ffffff;
  font-family: inherit;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23c9a66a' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
}

select option {
  background: var(--hero);
  color: var(--paper);
}

textarea {
  height: auto;
  min-height: 8.5rem;
  padding: 0.9rem;
  resize: vertical;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(255, 255, 255, 0.09);
  box-shadow: 0 0 0 3px rgba(201, 166, 106, 0.25);
}

.invalid {
  border-color: #e06c6c !important;
}

.err {
  font-size: 0.8rem;
  color: #ff9b9b;
  margin-top: 0.35rem;
  min-height: 1.1rem;
}

.note {
  font-size: 0.9rem;
  color: var(--gold);
  font-weight: 500;
}

.legal {
  margin-top: 2.5rem;
  max-width: 66ch;
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--sand);
  opacity: 0.85;
}

.bar {
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line-inv);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: var(--sand);
}

/* ==========================================================================
   Card Accent (novas áreas)
   ========================================================================== */
.card-accent {
  border-color: rgba(201, 166, 106, 0.3);
  background: linear-gradient(135deg, var(--paper) 0%, rgba(201, 166, 106, 0.05) 100%);
  position: relative;
  overflow: hidden;
}

.card-accent::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--gold));
}

/* ==========================================================================
   Diferenciais
   ========================================================================== */
.diferenciais-grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 0.5rem;
}

.diferencial {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 1.25rem;
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.diferencial:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}

.diferencial-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.875rem;
  background: linear-gradient(135deg, rgba(184, 149, 74, 0.12), rgba(201, 166, 106, 0.06));
  border: 1px solid rgba(184, 149, 74, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
  transition: background 0.25s ease;
}

.diferencial:hover .diferencial-icon {
  background: linear-gradient(135deg, rgba(184, 149, 74, 0.2), rgba(201, 166, 106, 0.12));
}

.diferencial h3 {
  font-family: var(--sans);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.diferencial p {
  font-size: 0.93rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
}

/* ==========================================================================
   Seção IA — h2 em dark
   ========================================================================== */
#ia h2 em {
  color: var(--gold);
}

/* ==========================================================================
   Chat Widget
   ========================================================================== */
.chat-widget {
  margin-top: 2.5rem;
  max-width: 46rem;
  border-radius: 1.5rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 60px -10px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

/* Header */
.chat-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  flex-shrink: 0;
}

.chat-status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--slate);
  transition: background 0.4s ease;
  flex-shrink: 0;
}

.chat-status-dot.online {
  background: #4ade80;
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.2);
  animation: pulse-dot 2s ease-in-out infinite;
}

.chat-status-dot.offline {
  background: #f87171;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.2); }
  50% { box-shadow: 0 0 0 5px rgba(74, 222, 128, 0.08); }
}

.chat-header-title {
  font-size: 0.87rem;
  font-weight: 600;
  color: var(--paper);
  letter-spacing: 0.03em;
}

.chat-header-sub {
  font-size: 0.73rem;
  color: var(--slate);
  letter-spacing: 0.02em;
  margin-left: auto;
}

.chat-header-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--gold);
  border: 1px solid rgba(201, 166, 106, 0.4);
  background: rgba(201, 166, 106, 0.08);
  border-radius: 999px;
  padding: 0.22rem 0.65rem;
  text-decoration: none;
  transition: all 0.2s ease;
  margin-left: 0.5rem;
}

.chat-header-btn:hover {
  background: rgba(201, 166, 106, 0.2);
  border-color: var(--gold);
  color: #fff;
}

.chat-typing {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 0.6rem 0.9rem;
}

.chat-typing span {
  width: 6px;
  height: 6px;
  background: var(--gold);
  border-radius: 50%;
  animation: typing-bounce 1.2s infinite ease-in-out;
}

.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing-bounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.35; }
  40% { transform: scale(1.1); opacity: 1; }
}

/* Messages area */
.chat-messages {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-height: 14rem;
  max-height: 22rem;
  overflow-y: auto;
  scroll-behavior: smooth;
}

.chat-messages::-webkit-scrollbar {
  width: 4px;
}

.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 2px;
}

/* Bubbles */
.chat-bubble {
  max-width: 85%;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  animation: bubble-in 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes bubble-in {
  from { opacity: 0; transform: translateY(8px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-bubble-ai {
  align-self: flex-start;
}

.chat-bubble-user {
  align-self: flex-end;
}

.chat-bubble p {
  margin: 0;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  font-size: 0.93rem;
  line-height: 1.55;
}

.chat-bubble-ai p {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--paper);
  border-bottom-left-radius: 0.25rem;
}

.chat-bubble-user p {
  background: var(--accent);
  color: #fff;
  border-bottom-right-radius: 0.25rem;
}

.chat-disclaimer {
  font-size: 0.73rem !important;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  color: var(--slate) !important;
  letter-spacing: 0.01em;
}

.chat-sources {
  padding: 0.7rem 0.85rem;
  border-left: 2px solid rgba(201, 166, 106, 0.7);
  background: rgba(201, 166, 106, 0.08);
  border-radius: 0.25rem 0.7rem 0.7rem 0.25rem;
  font-size: 0.76rem;
  line-height: 1.45;
}

.chat-sources strong {
  color: var(--paper);
}

.chat-sources ul {
  margin: 0.35rem 0 0;
  padding-left: 1.1rem;
}

.chat-sources a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.btn-card {
  margin-top: 1rem;
  font-size: 0.78rem;
  padding: 0.7rem 1rem;
}

.content-dialog {
  width: min(960px, calc(100% - 2rem));
  max-height: calc(100vh - 2rem);
  padding: 0;
  border: 1px solid rgba(201, 166, 106, 0.35);
  border-radius: 1.25rem;
  color: var(--ink);
  background: var(--paper);
  box-shadow: 0 2rem 6rem rgba(8, 17, 31, 0.45);
  overflow: auto;
}

.content-dialog::backdrop {
  background: rgba(8, 17, 31, 0.78);
  backdrop-filter: blur(5px);
}

.content-dialog-panel {
  position: relative;
  padding: clamp(1.5rem, 4vw, 3.5rem);
}

.content-dialog-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid rgba(8, 17, 31, 0.14);
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  font-size: 1.5rem;
  cursor: pointer;
}

.content-dialog-lead {
  max-width: 68ch;
  color: var(--muted);
}

.digital-content-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.75rem;
}

.digital-content-grid article {
  padding: 1.25rem;
  border: 1px solid rgba(8, 17, 31, 0.12);
  border-radius: 1rem;
  background: #fff;
}

.digital-content-grid h3 {
  margin: 0.4rem 0 0.7rem;
}

.text-link {
  display: inline-block;
  margin-top: 0.75rem;
  color: var(--accent-dark, #8b642d);
  font-weight: 700;
  text-underline-offset: 0.2em;
}

.dialog-legal {
  margin: 1.5rem 0 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(8, 17, 31, 0.12);
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.5;
}

@media (max-width: 760px) {
  .digital-content-grid { grid-template-columns: 1fr; }
}

/* Typing indicator */
.chat-typing {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.75rem 1rem;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1rem;
  border-bottom-left-radius: 0.25rem;
  width: fit-content;
  align-self: flex-start;
}

.chat-typing span {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--slate);
  animation: typing-bounce 1.4s ease-in-out infinite;
}

.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing-bounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-5px); opacity: 1; }
}

/* Offline message */
.chat-offline-msg {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 1.25rem;
  background: rgba(248, 113, 113, 0.08);
  border-top: 1px solid rgba(248, 113, 113, 0.2);
  font-size: 0.87rem;
  color: #fca5a5;
}

.chat-offline-msg a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.chat-offline-msg[hidden] {
  display: none;
}

/* Input area */
.chat-input-area {
  display: flex;
  align-items: flex-end;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.15);
  flex-shrink: 0;
}

.chat-input {
  flex: 1;
  height: auto !important;
  min-height: 2.6rem;
  max-height: 8rem;
  border-radius: 0.875rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.6rem 0.9rem;
  font-size: 0.93rem;
  color: var(--paper);
  font-family: inherit;
  resize: none;
  overflow-y: auto;
  line-height: 1.5;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.chat-input::placeholder {
  color: var(--slate);
}

.chat-input:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(255, 255, 255, 0.09);
  box-shadow: 0 0 0 3px rgba(201, 166, 106, 0.18);
}

.chat-send-btn {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 0.875rem;
  background: var(--accent);
  color: #fff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
  box-shadow: 0 4px 14px rgba(184, 149, 74, 0.35);
}

.chat-send-btn:hover:not(:disabled) {
  background: #a3823d;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(184, 149, 74, 0.45);
}

.chat-send-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none !important;
}

.chat-legal {
  padding: 0.6rem 1.25rem;
  font-size: 0.68rem;
  color: rgba(124, 133, 148, 0.7);
  letter-spacing: 0.04em;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  margin: 0;
  background: transparent;
}

/* Botão de contato dentro da bolha */
.chat-contact-btn {
  margin-top: 0.65rem;
  font-size: 0.78rem;
  min-height: 2.4rem;
  padding: 0 1.1rem;
  align-self: flex-start;
}

/* Formulário inline de contato */
.chat-contact-form {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(201, 166, 106, 0.25);
  border-radius: 1rem;
  padding: 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  animation: bubble-in 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.chat-contact-title {
  font-size: 0.83rem;
  color: var(--sand);
  margin: 0;
}

.chat-contact-form input {
  height: 2.6rem;
  border-radius: 0.6rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
  padding: 0 0.85rem;
  font-size: 0.9rem;
  color: var(--paper);
  font-family: inherit;
  width: 100%;
}

.chat-contact-form input:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 0 2px rgba(201, 166, 106, 0.2);
}

.chat-contact-form .btn {
  align-self: flex-start;
  font-size: 0.78rem;
  min-height: 2.4rem;
  padding: 0 1.1rem;
}

.chat-cf-note {
  font-size: 0.78rem;
  color: #fca5a5;
  margin: 0;
  min-height: 1em;
}

.chat-contact-success {
  font-size: 0.87rem;
  color: #4ade80;
  margin: 0;
  padding: 0.75rem 0;
}


/* Screen-reader only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   Botão Flutuante WhatsApp
   ========================================================================== */
.wa-float {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  z-index: 99;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: #25d366;
  color: #ffffff;
  padding: 0.75rem 1.15rem;
  border-radius: 999px;
  box-shadow: 0 6px 22px rgba(37, 211, 102, 0.45);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  backdrop-filter: blur(4px);
}

.wa-float:hover {
  background: #20ba5a;
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 26px rgba(37, 211, 102, 0.55);
  color: #ffffff;
}

.wa-float svg {
  flex-shrink: 0;
}

/* ==========================================================================
   Responsividade (Desktop >= 768px)
   ========================================================================== */
@media (min-width: 768px) {
  .menu-btn {
    display: none !important;
  }
  nav {
    display: flex !important;
    position: static;
  }
  .hero-grid {
    grid-template-columns: 0.85fr 1.15fr;
    padding: 6rem 0;
  }
  .hero-logo {
    display: block;
  }
  .portrait {
    grid-template-columns: 0.9fr 1.1fr;
    gap: 4.5rem;
  }
  .cards-2 {
    grid-template-columns: 1fr 1fr;
  }
  .row {
    grid-template-columns: 1fr 1fr;
  }
  .books article {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
  .timeline {
    grid-template-columns: 1fr 1fr;
    gap: 0 2.5rem;
  }
  .steps {
    grid-template-columns: repeat(4, 1fr);
  }
  .hide-mobile {
    display: block;
  }
  .diferenciais-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================================================
   Responsividade (Mobile < 768px)
   ========================================================================== */
@media (max-width: 767px) {
  .wrap {
    width: calc(100% - 2rem);
  }

  .header-inner {
    min-height: 4rem;
  }

  .brand img {
    height: 2.2rem;
  }

  .brand-name {
    font-size: 0.85rem;
    letter-spacing: 0.14em;
  }

  .brand-sub {
    font-size: 0.6rem;
    letter-spacing: 0.18em;
  }

  .menu-btn {
    display: inline-flex;
  }

  nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--paper);
    flex-direction: column;
    gap: 0;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.1);
    padding: 0.75rem 1rem 1.25rem;
    animation: menuSlide 0.25s ease forwards;
  }

  @keyframes menuSlide {
    from {
      opacity: 0;
      transform: translateY(-8px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  nav.open {
    display: flex;
  }

  nav a {
    display: block;
    width: 100%;
    padding: 0.85rem 0.5rem;
    font-size: 0.85rem;
    border-bottom: 1px solid var(--border-light);
    opacity: 0.9;
  }

  nav a:last-child {
    border-bottom: none;
  }

  .hero-logo {
    display: none;
  }

  .hero-grid {
    padding: 3rem 0 4.5rem;
    gap: 1.5rem;
  }

  .eyebrow {
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    line-height: 1.5;
    margin-bottom: 0.85rem;
  }

  h1 {
    font-size: 2.35rem;
    line-height: 1.15;
  }

  .lead {
    font-size: 1rem;
    line-height: 1.6;
  }

  .section {
    padding: 3.75rem 0;
  }

  .timeline li {
    grid-template-columns: 1fr;
    gap: 0.35rem;
    padding: 1rem 0;
  }

  .timeline time {
    display: inline-block;
    width: fit-content;
    padding: 0.15rem 0.6rem;
    border-radius: 999px;
    background: rgba(201, 166, 106, 0.12);
    border: 1px solid rgba(201, 166, 106, 0.25);
    font-size: 0.72rem;
  }

  .steps {
    grid-template-columns: 1fr;
  }

  .wa-float-text {
    display: none;
  }

  .wa-float {
    padding: 0.8rem;
    bottom: 1.25rem;
    right: 1.25rem;
  }
}
