/* 
 * Urb Engenharia — Design System
 * Cores, tipografia e classes estruturais baseadas no manual de marca oficial.
 */

/* --- Importação de Fontes --- */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600&family=Jost:wght@300;400;500;600;700&display=swap');

/* --- Variáveis Globais (Media Kit) --- */
:root {
  --primary: #131B33;      /* Azul Corporativo (Solidez e Engenharia) */
  --accent: #2E6BA8;       /* Azul Aço (Ações e Links) */
  --text: #23262E;         /* Grafite (Corpo do Texto) */
  --bg: #F8F7F9;           /* Papel (Fundo Principal) */
  --border: #E0DFE3;       /* Cinza de Borda (Divisores e Bordas) */
  --white: #FFFFFF;
  --success: #25D366;      /* Verde WhatsApp */
  --shadow-sm: 0 2px 8px rgba(35, 38, 46, 0.05);
  --shadow-md: 0 8px 24px rgba(19, 27, 51, 0.08);
  --shadow-lg: 0 16px 48px rgba(19, 27, 51, 0.12);
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --font-title: 'Jost', sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* --- Reset --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: var(--font-body);
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* --- Tipografia --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  color: var(--primary);
  font-weight: 600;
  line-height: 1.25;
}

p {
  font-family: var(--font-body);
  color: var(--text);
}

.font-mono {
  font-family: var(--font-mono);
}

/* --- Layout Estrutural --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 100px 0;
  position: relative;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 16px;
  text-align: center;
  position: relative;
  padding-bottom: 16px;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background-color: var(--accent);
}

.section-subtitle {
  font-family: var(--font-title);
  font-size: 1.15rem;
  text-align: center;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 48px;
}

/* --- Navbar --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background-color: rgba(248, 247, 249, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: 80px;
  display: flex;
  align-items: center;
  transition: var(--transition);
}

.navbar.scrolled {
  height: 70px;
  background-color: rgba(19, 27, 51, 0.95);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar.scrolled .nav-link {
  color: rgba(255, 255, 255, 0.8);
}

.navbar.scrolled .nav-link:hover {
  color: var(--white);
}

.navbar.scrolled .logo-img {
  filter: invert(1);
}

.navbar-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo-img {
  height: 44px;
  width: auto;
  transition: var(--transition);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-cta {
  padding: 10px 20px;
}

/* --- Botão hambúrguer (oculto no desktop) --- */
.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 0;
  cursor: pointer;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 6px;
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--primary);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.2s ease, background-color 0.3s ease;
  transform-origin: center;
}

.navbar.scrolled .nav-toggle-bar {
  background-color: var(--white);
}

/* Vira "X" quando aberto */
.nav-toggle.is-active .nav-toggle-bar:nth-child(1) {
  transform: translateY(10px) rotate(45deg);
}
.nav-toggle.is-active .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}
.nav-toggle.is-active .nav-toggle-bar:nth-child(3) {
  transform: translateY(-10px) rotate(-45deg);
}

.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 998;
  background: rgba(19, 27, 51, 0.55);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.nav-backdrop[hidden] {
  display: none;
}

/* Trava o scroll do fundo com o menu aberto */
body.nav-aberto {
  position: fixed;
  width: 100%;
  overflow: hidden;
}

.nav-link {
  font-family: var(--font-title);
  text-decoration: none;
  color: var(--primary);
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition);
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--accent);
  transition: var(--transition);
}

.nav-link:hover::after {
  width: 100%;
}

/* --- Botões --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 12px 28px;
  border-radius: 4px;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background-color: var(--accent);
  color: var(--white);
}

.btn-primary:hover {
  background-color: #245485;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(46, 107, 168, 0.3);
}

.btn-outline {
  background-color: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn-outline:hover {
  background-color: var(--accent);
  color: var(--white);
  transform: translateY(-2px);
}

.btn-white {
  background-color: var(--white);
  color: var(--primary);
}

.btn-white:hover {
  background-color: var(--bg);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.15);
}

/* --- Hero Section (Estilo PD Engenharia - Intimista) --- */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100svh; /* evita o "pulo" quando a barra do navegador mobile recolhe */
  min-height: 650px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  overflow: hidden;
  color: var(--white);
  padding: 0;
}

.hero-bg-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.82) contrast(1.08) saturate(1.05);
  z-index: 1;
  transition: var(--transition);
}

.hero-color-filter {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(19, 27, 51, 0.6) 0%, rgba(46, 107, 168, 0.8) 100%);
  mix-blend-mode: color;
  z-index: 1.5;
  pointer-events: none;
}

/*
 * Marca d'água em degradê (de baixo para cima).
 * Camada 1 — filtro óptico real: desfoque/dessaturação progressiva revelada
 * por uma máscara vertical, densa no rodapé e transparente no topo.
 */
.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  backdrop-filter: blur(7px) saturate(0.7) brightness(0.72);
  -webkit-backdrop-filter: blur(7px) saturate(0.7) brightness(0.72);
  -webkit-mask-image: linear-gradient(to top,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 0.96) 10%,
    rgba(0, 0, 0, 0.85) 20%,
    rgba(0, 0, 0, 0.68) 31%,
    rgba(0, 0, 0, 0.48) 43%,
    rgba(0, 0, 0, 0.30) 55%,
    rgba(0, 0, 0, 0.16) 68%,
    rgba(0, 0, 0, 0.06) 82%,
    rgba(0, 0, 0, 0) 100%);
  mask-image: linear-gradient(to top,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 0.96) 10%,
    rgba(0, 0, 0, 0.85) 20%,
    rgba(0, 0, 0, 0.68) 31%,
    rgba(0, 0, 0, 0.48) 43%,
    rgba(0, 0, 0, 0.30) 55%,
    rgba(0, 0, 0, 0.16) 68%,
    rgba(0, 0, 0, 0.06) 82%,
    rgba(0, 0, 0, 0) 100%);
}

/*
 * Camada 2 — véu de cor da marca (azul corporativo) em degradê ascendente,
 * com pigmento de azul aço na faixa média e vinheta lateral discreta.
 * Paradas múltiplas suavizam o banding em telas grandes.
 */
.hero-overlay-gradient {
  position: absolute;
  inset: 0;
  z-index: 2.1;
  pointer-events: none;
  background:
    linear-gradient(to top,
      rgba(19, 27, 51, 0.96) 0%,
      rgba(19, 27, 51, 0.92) 8%,
      rgba(19, 27, 51, 0.83) 17%,
      rgba(19, 27, 51, 0.70) 27%,
      rgba(21, 34, 62, 0.55) 38%,
      rgba(24, 45, 78, 0.40) 50%,
      rgba(27, 56, 94, 0.27) 62%,
      rgba(25, 48, 82, 0.16) 74%,
      rgba(19, 27, 51, 0.07) 87%,
      rgba(19, 27, 51, 0) 100%),
    linear-gradient(to right,
      rgba(19, 27, 51, 0.55) 0%,
      rgba(19, 27, 51, 0.18) 42%,
      rgba(19, 27, 51, 0.12) 62%,
      rgba(19, 27, 51, 0.45) 100%);
}

/* Fallback: sem suporte a backdrop-filter, reforça o véu de cor */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .hero-overlay {
    background: linear-gradient(to top,
      rgba(11, 16, 31, 0.85) 0%,
      rgba(11, 16, 31, 0.55) 30%,
      rgba(11, 16, 31, 0.25) 60%,
      rgba(11, 16, 31, 0) 100%);
  }
}

.hero-content-wrapper {
  position: relative;
  z-index: 3;
  width: 100%;
  padding-bottom: 100px;
  padding-left: 80px;
}

.hero-content {
  max-width: 800px;
}

.hero-tagline {
  font-family: var(--font-mono);
  font-size: clamp(0.75rem, 1.2vw, 0.9rem);
  letter-spacing: 0.3em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 16px;
  display: block;
  font-weight: 600;
}

.hero-title {
  color: var(--white);
  font-size: clamp(2.8rem, 6vw, 4.8rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: 0.05em;
  text-transform: none;
}

.hero-sub {
  font-family: var(--font-mono);
  font-size: clamp(0.85rem, 1.6vw, 1.1rem);
  font-weight: 400;
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 40px;
}

.hero-btns {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}


/* --- Placa do logotipo (seção Diferenciais) --- */
.why-us-placa {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  box-shadow: var(--shadow-md);
  height: 100%;
  min-height: 380px;
  overflow: hidden; /* trava de segurança: a logo nunca vaza da placa */
}

/*
 * A logo era ampliada com transform: scale(2.8) sobre um max-width de 90%,
 * o que a fazia estourar a placa e gerar rolagem horizontal em toda a página.
 * Agora o tamanho vem da própria largura, que respeita o container.
 */
.why-us-logo {
  width: min(78%, 380px);
  height: auto;
  object-fit: contain;
}

/* --- Seção de Serviços --- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.service-card {
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 40px;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-md);
  border-color: rgba(46, 107, 168, 0.3);
}

.service-icon-wrapper {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  background-color: rgba(46, 107, 168, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  margin-bottom: 24px;
}

.service-card-title {
  font-size: 1.35rem;
  font-weight: 600;
  margin-bottom: 16px;
}

.service-card-desc {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.6;
  margin-bottom: 24px;
  flex-grow: 1;
}

.service-card-list {
  list-style: none;
  border-top: 1px solid var(--border);
  padding-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.service-card-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text);
}

.service-card-list li svg {
  color: var(--accent);
}

/* --- Portfólio / BIM 3D --- */
.portfolio {
  background-color: var(--white);
}

.portfolio-item {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
  align-items: center;
  margin-bottom: 80px;
}

.portfolio-item:last-child {
  margin-bottom: 0;
}

.portfolio-item.reverse {
  grid-template-columns: 1.1fr 0.9fr;
}

.portfolio-item.reverse .portfolio-info {
  order: 2;
}

.portfolio-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.portfolio-meta {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.portfolio-title {
  font-size: 2rem;
  font-weight: 600;
}

.portfolio-desc {
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 16px;
}

/* --- Slider de Imagens no Portfólio (Swipe / Arrastável) --- */
.slider-container {
  position: relative;
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.slider-wrapper {
  display: flex;
  width: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  /* Ocultar barra de rolagem */
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

.slider-wrapper::-webkit-scrollbar {
  display: none; /* Chrome, Safari and Opera */
}

.slide {
  flex: 0 0 100%;
  width: 100%;
  position: relative;
  scroll-snap-align: start;
}

.slide-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background-color: rgba(19, 27, 51, 0.85);
  color: var(--white);
  padding: 6px 12px;
  font-family: var(--font-title);
  font-size: 0.8rem;
  font-weight: 500;
  border-radius: 4px;
  letter-spacing: 0.05em;
  pointer-events: none;
  z-index: 2;
}

.slider-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  margin-top: 16px;
}

.slider-arrow {
  background-color: var(--white);
  border: 1px solid var(--border);
  color: var(--text);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
}

.slider-arrow:hover {
  background-color: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

.slider-arrow svg {
  display: block;
}

.slider-dots {
  display: flex;
  gap: 8px;
}

/*
 * O ponto visual continua com 8px, mas ganha uma área de toque de 44px
 * via pseudo-elemento — sem alterar o espaçamento do layout.
 */
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--border);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.dot::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 44px;
  height: 44px;
  transform: translate(-50%, -50%);
}

.dot.active {
  background-color: var(--accent);
  transform: scale(1.2);
}


/* Placeholder Sketchfab (Lazy-load 3D) */
.ratio-16-9 {
  display: block;
  position: relative;
  width: 100%;
  height: 0;
  padding-top: 56.25%;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.ratio-inner {
  display: block;
  position: absolute;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.js-sketchfab-placeholder {
  cursor: pointer;
  background-color: var(--bg);
}

.sketchfab-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: rgba(19, 27, 51, 0.7);
  color: var(--white);
  padding: 24px;
  transition: var(--transition);
}

.sketchfab-overlay svg {
  margin-bottom: 12px;
  transition: var(--transition);
}

.sketchfab-overlay span {
  font-family: var(--font-title);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.85rem;
}

.js-sketchfab-placeholder:hover .sketchfab-overlay {
  background: rgba(19, 27, 51, 0.8);
}

.js-sketchfab-placeholder:hover .sketchfab-overlay svg {
  transform: scale(1.15);
}

.js-sketchfab-placeholder.is-loaded .sketchfab-overlay {
  display: none;
}

/* --- Diferenciais / Placa --- */
.why-us {
  background-color: var(--bg);
}

.why-us-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.why-us-content {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.why-us-item {
  display: flex;
  gap: 20px;
}

.why-us-num {
  font-family: var(--font-mono);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}

.why-us-text h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.why-us-text p {
  font-size: 0.95rem;
  color: var(--text);
}

/* Mock de Placa de Obra do Media Kit */
.obra-placa {
  background-color: var(--white);
  border: 4px solid var(--primary);
  border-radius: 4px;
  padding: 40px;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.obra-placa-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.obra-placa-logo {
  height: 48px;
  width: auto;
}

.obra-placa-crea {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: rgba(35, 38, 46, 0.6);
  text-align: right;
}

.obra-placa-title {
  font-family: var(--font-title);
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--primary);
  line-height: 1.2;
}

.obra-placa-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  border-top: 2px solid var(--primary);
  padding-top: 20px;
}

.obra-placa-col h5 {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.obra-placa-col p {
  font-size: 0.8rem;
  line-height: 1.6;
  color: var(--text);
}

/* --- FAQ acordeão --- */
.faq-container {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.faq-container details {
  background-color: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  transition: var(--transition);
}

.faq-container details[open] {
  border-color: var(--accent);
  box-shadow: var(--shadow-sm);
}

.faq-container summary {
  list-style: none;
  cursor: pointer;
  padding: 24px;
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.faq-container summary::-webkit-details-marker {
  display: none;
}

.faq-container summary::after {
  content: '+';
  color: var(--accent);
  font-size: 1.5rem;
  line-height: 1;
  transition: var(--transition);
  font-weight: 500;
}

.faq-container details[open] summary::after {
  content: '−';
  transform: rotate(180deg);
}

.faq-content {
  padding: 0 24px 24px;
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.7;
  border-top: 1px solid rgba(224, 223, 227, 0.4);
  padding-top: 16px;
}

/* --- Contato / Rodapé --- */
.footer {
  background-color: var(--primary);
  color: var(--white);
  padding: 100px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 80px;
  margin-bottom: 60px;
}

.footer-info {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.footer-logo {
  height: 48px;
  align-self: flex-start;
  filter: invert(1);
}

.footer-info p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
  line-height: 1.7;
}

.footer-contact-details {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 12px;
}

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
}

.footer-contact-item svg {
  color: var(--accent);
}

.footer-form-wrapper {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 40px;
}

.footer-form-title {
  color: var(--white);
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.footer-form-sub {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form-control {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  padding: 12px 16px;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}

.form-control::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.form-control:focus {
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.08);
}

textarea.form-control {
  resize: vertical;
  min-height: 100px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  font-family: var(--font-title);
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

/* --- WhatsApp Botão Flutuante --- */
.whatsapp-float {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 60px;
  height: 60px;
  background-color: var(--success);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.3);
  z-index: 999;
  transition: var(--transition);
  text-decoration: none;
}

.whatsapp-float:hover {
  transform: scale(1.1) translateY(-4px);
  box-shadow: 0 12px 32px rgba(37, 211, 102, 0.4);
}

.whatsapp-float svg {
  width: 32px;
  height: 32px;
}

/* --- Responsividade (Media Queries) --- */
@media (max-width: 1024px) {
  .hero-content-wrapper {
    padding-left: 24px;
    padding-right: 24px;
    padding-bottom: 80px;
  }
  .hero-content {
    text-align: center;
    margin: 0 auto;
  }
  .hero-btns {
    justify-content: center;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .portfolio-item, .portfolio-item.reverse {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .portfolio-item.reverse .portfolio-info {
    order: unset;
  }
  .why-us-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

@media (max-width: 768px) {
  section {
    padding: 70px 0;
  }
  .section-title {
    font-size: 2rem;
  }

  /* --- Menu mobile: painel deslizante no lugar do menu oculto --- */
  .nav-toggle {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 999;
    width: min(82vw, 320px);
    height: 100%;
    height: 100dvh;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 4px;
    padding: 96px 24px calc(32px + env(safe-area-inset-bottom));
    background-color: var(--primary);
    box-shadow: -8px 0 32px rgba(19, 27, 51, 0.28);
    transform: translateX(100%);
    transition: transform 0.32s cubic-bezier(0.25, 0.8, 0.25, 1);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav-menu.is-open {
    transform: translateX(0);
  }

  /* Links com alvo de toque cheio e separador sutil */
  .nav-menu .nav-link {
    display: flex;
    align-items: center;
    min-height: 52px;
    width: 100%;
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  /* A navbar clara não deve mais recolorir os links dentro do painel escuro */
  .navbar.scrolled .nav-menu .nav-link {
    color: rgba(255, 255, 255, 0.92);
  }

  .nav-menu .nav-link::after {
    display: none; /* o sublinhado animado não faz sentido no painel */
  }

  .nav-menu .nav-cta {
    justify-content: center;
    margin-top: 24px;
    padding: 16px 20px;
    font-size: 1rem;
    text-align: center;
    border-bottom: 0;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }
  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .whatsapp-float {
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
  }
  .whatsapp-float svg {
    width: 26px;
    height: 26px;
  }

  /* --- Capa: degradê mais alto, pois o texto ocupa mais da tela em retrato --- */
  .hero-content-wrapper {
    padding-bottom: 72px;
  }

  .hero-overlay-gradient {
    background:
      linear-gradient(to top,
        rgba(19, 27, 51, 0.97) 0%,
        rgba(19, 27, 51, 0.94) 12%,
        rgba(19, 27, 51, 0.87) 24%,
        rgba(21, 34, 62, 0.75) 36%,
        rgba(24, 45, 78, 0.58) 48%,
        rgba(27, 56, 94, 0.40) 60%,
        rgba(25, 48, 82, 0.24) 73%,
        rgba(19, 27, 51, 0.10) 87%,
        rgba(19, 27, 51, 0) 100%);
  }

  /* Desfoque menor: blur em tela cheia pesa em aparelho de entrada */
  .hero-overlay {
    backdrop-filter: blur(4px) saturate(0.75) brightness(0.78);
    -webkit-backdrop-filter: blur(4px) saturate(0.75) brightness(0.78);
  }

  /* --- Alvos de toque das setas do slider (mín. 44px) --- */
  .slider-arrow {
    width: 44px;
    height: 44px;
  }

  .why-us-placa {
    min-height: 260px;
    padding: 20px;
  }

  .why-us-logo {
    width: min(70%, 260px);
  }
}

/* --- Evita zoom automático do iOS ao focar campos (exige >= 16px) --- */
@media (max-width: 768px) {
  input,
  select,
  textarea,
  .form-control {
    font-size: 16px;
  }
}

/* --- Trava global contra rolagem horizontal --- */
html,
body {
  overflow-x: clip;
}

/* --- Respeita quem pediu menos animação no sistema --- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
