/* home.css - Estilos específicos da Home */

.hero-home {
  position: relative;
  height: calc(100vh - 189px);
  height: calc(100dvh - 189px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 120px;
  padding-bottom: 0;
  background: var(--gradient-brand);
  z-index: 10;
  overflow: visible;
}

.hero-home::after {
  display: none;
}

.hero-gradient-overlay {
  display: none;
}

.hero-container-split {
  position: relative;
  z-index: 10; /* Increased to stay above the wave (z-index 5) */
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: auto; /* Changed from 100% to auto to use padding for centering */
}

.hero-trucks {
  flex: 1.2;
  display: flex;
  justify-content: flex-start;
  align-items: flex-end;
  position: relative;
  height: 100%;
  padding-right: 1rem;
  z-index: 30;
}

.hero-trucks img {
  max-width: 160%;
  height: auto;
  transform: translateX(-14%);
  filter: drop-shadow(0 20px 40px rgba(0,0,0,0.5));
  pointer-events: none;
  position: relative;
  z-index: 30;
}

.hero-text-right {
  flex: 1;
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  z-index: 5; /* Ensure text stays on top of oversized truck image */
}

.hero-typography {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.hero-top-text {
  color: var(--color-white);
  font-size: clamp(1.2rem, 2.5vw, 2.2rem); /* Slightly reduced top text */
  font-style: italic;
  font-weight: 400;
  margin-bottom: -0.2rem;
}

.hero-main-title {
  color: var(--color-white);
  font-size: clamp(2.75rem, 5.6vw, 4.4rem); /* Increased by 25% as requested */
  font-style: italic;
  font-weight: 900;
  line-height: 0.95;
  text-transform: lowercase;
  text-shadow: 4px 4px 10px rgba(0,0,0,0.3);
  margin-bottom: 0.5rem;
}

.hero-bottom-text {
  color: var(--color-white);
  font-size: clamp(0.9rem, 1.8vw, 1.3rem); /* Further reduced to avoid overlapping with the trucks on the left */
  font-style: italic;
  font-weight: 500;
}

/* Responsividade Hero Split */
@media (max-width: 1149px) {
  .hero-home {
    height: auto;
    min-height: 75vh; /* Reduzido de 100vh para ficar mais compacto */
    padding-top: 90px; /* Aumentado mais 25% conforme solicitado */
    padding-bottom: 0; /* Removido para os caminhões tocarem a linha da onda */
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* Alinha ao topo para respeitar o padding-top de 40px */
    width: 100%;
    margin: 0;
    overflow: visible; /* Essencial para permitir que os caminhões sobreponham a seção de baixo */
  }

  .hero-home::after {
    display: none; /* Fundo reto no mobile/tablet conforme solicitado */
  }
  
  @media (max-width: 767px) {
    .hero-home {
      min-height: 552px; /* Reduzido mais 20px conforme solicitado (572 - 20) */
      padding-top: 102px; /* Deslocado 12px para baixo conforme solicitado (90 + 12) */
    }

    .hero-trucks img {
      margin-bottom: -20px; /* Subido 20px (de -40px para -20px) conforme solicitado */
    }
  }

  .hero-container-split {
    flex-direction: column-reverse;
    justify-content: space-between; /* Texto no topo (com padding) e caminhões na base */
    flex: 1;
    width: 100%;
  }
  
  .hero-trucks {
    width: 100%;
    margin-top: 1rem;
    padding-right: 0;
    justify-content: center;
  }

  /* Ajustes EXCLUSIVOS para Tablet (iPad, etc) */
  @media (min-width: 768px) and (max-width: 1149px) {
    .hero-home {
      min-height: calc(75vh - 95px); /* Reduzido mais 5px para ajuste fino de alinhamento */
    }
    
    .hero-trucks img {
      transform: translateX(-13px) translateY(-49px) scale(1.18) !important; /* Tamanho 1.18 e deslocado 8px extras para a esquerda */
      margin-bottom: -50px !important; /* Força os pneus a vazar para a parte branca */
    }

    .hero-main-title {
      font-size: 4.5rem !important; /* Aumentado ~10% para tablet */
    }

    .hero-actions .btn {
      transform: scale(1.1); /* Botão 10% maior no tablet */
    }
  }
  
  .hero-trucks img {
    max-width: 100%;
    transform: translateX(-5px) translateY(-14px) scale(1.3); /* Descido mais 3px conforme solicitado (de -17px para -14px) */
    margin-bottom: -20px; /* Margem base para manter a sobreposição na parte branca */
    display: block;
    position: relative;
    z-index: 10;
  }
  
  .hero-text-right, .hero-typography, .hero-actions {
    align-items: center;
    text-align: center;
  }
  
  .hero-actions {
    justify-content: center !important;
  }

  .home-diferenciais {
    z-index: 1 !important;
    position: relative;
  }

  .hero-home {
    z-index: 20 !important;
    position: relative;
  }

  .hero-container-split {
    max-width: 100% !important;
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

/* Diferenciais / Grid de Valores */
.home-diferenciais {
  background: var(--color-white);
  position: relative;
  z-index: 3;
  padding-top: 4.75rem !important;
}

.diferenciais-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .diferenciais-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Seção Sobre a Empresa com Imagem Lateral */
.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 992px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
  }
}

.about-img-box {
  position: relative;
}

.about-img-box::before {
  content: '';
  position: absolute;
  top: -20px;
  left: -20px;
  width: 100px;
  height: 100px;
  background: var(--color-primary);
  z-index: -1;
  border-radius: 4px;
}

.about-img-box::after {
  content: '';
  position: absolute;
  bottom: -20px;
  right: -20px;
  width: 60%;
  height: 40%;
  border: 4px solid var(--color-secondary);
  z-index: -1;
  border-radius: 4px;
}

.about-img {
  border-radius: 8px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  object-fit: cover;
  aspect-ratio: 4/3;
}

/* ── Seção de Números / Indicadores ────────────────────────── */
.section-numbers {
  background: var(--color-neutral-light);
  padding: 4rem 0;
}

.numbers-bar {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .numbers-bar {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Card base */
.stat-card {
  background: var(--color-white);
  border-radius: 12px;
  padding: 2rem 1.5rem 2.25rem;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* Linha de acento laranja no topo */
.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: var(--gradient-primary);
  border-radius: 12px 12px 0 0;
}

.stat-icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, rgba(242,138,0,0.12), rgba(245,166,35,0.06));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  color: var(--color-primary);
}

.stat-icon svg {
  width: 26px;
  height: 26px;
}

.stat-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--color-secondary);
  margin-bottom: 0.75rem;
}

.stat-value {
  font-size: 3.75rem;
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1;
  margin: 0;
}

/* Card de certificações */
.stat-card--certs .cert-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem;
  margin-top: 0.25rem;
  width: 100%;
}

.cert-badges span {
  background: var(--color-secondary);
  color: var(--color-white);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.5rem 0.85rem;
  border-radius: 20px;
  text-align: center;
  white-space: nowrap;
}
