/* =========================
   HERO / CARROSSEL
========================= */
@media (max-width: 991.98px) {
  .hero-overlay .container {
    max-width: 100%;
    padding-left: 20px;
    padding-right: 20px;
  }

  .hero-overlay .btn-lg {
    padding: 0.65rem 1.75rem;
    font-size: 1rem;
  }
}

@media (max-width: 767.98px) {
  .hero,
  .carousel,
  .carousel-inner,
  .carousel-item {
    height: 100svh; /* evita corte pela barra do navegador mobile */
  }

  .hero-img {
    height: 100svh;
  }

  .hero-overlay .display-2 {
    font-size: 1.9rem;
    line-height: 1.3;
  }

  .hero-overlay .lead {
    font-size: 1rem;
  }

  .hero-overlay .mt-5 {
    margin-top: 1.75rem !important;
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  .hero-overlay .mt-5 .btn {
    width: 100%;
    margin: 0 !important;
  }
}

@media (max-width: 575.98px) {
  .hero-overlay .display-2 {
    font-size: 1.6rem;
  }
}

/* =========================
   NAVBAR
========================= */
@media (max-width: 991.98px) {
  #mainNav {
    background: #111 !important;
    padding: 12px 0;
  }

  #navbarResponsive {
    max-height: calc(100svh - 70px);
    overflow-y: auto;
  }

  .navbar-nav .nav-item {
    text-align: center;
  }

  .navbar-nav .btn {
    margin-top: 10px;
    width: 100%;
  }
}

/* =========================
   MISSÃO BAR
========================= */
@media (max-width: 575.98px) {
  .missao-bar .container {
    text-align: center;
  }

  #digitando {
    display: block;
    width: 100%;
  }
}

/* =========================
   CARDS DE PRODUTOS / PORTFÓLIO
========================= */
@media (max-width: 575.98px) {
  #produtos .card-body h4 {
    font-size: 1.1rem;
  }

  #produtos .card-body p {
    font-size: 0.92rem;
  }

  .portfolio-caption-heading {
    font-size: 1rem;
  }

  .portfolio-caption-subheading {
    font-size: 0.85rem;
  }
}

/* =========================
   TIMELINE (Empresa)
========================= */
@media (max-width: 767.98px) {
  .timeline-image {
    width: 90px;
    height: 90px;
  }

  .timeline-image i {
    font-size: 28px;
  }

  .timeline > li {
    margin-bottom: 50px;
  }
}

/* =========================
   MODAIS DE PORTFÓLIO
========================= */
@media (max-width: 767.98px) {
  .modal-dialog {
    max-width: calc(100% - 24px);
    margin: 0.75rem auto;
  }

  .modal-body {
    padding: 1.25rem;
  }

  .modal-body img {
    max-height: 300px;
  }
}

/* =========================
   CONTATO — cards de informação e "como funciona"
========================= */
@media (min-width: 576px) and (max-width: 991.98px) {
  .contato-card,
  .process-card {
    max-width: 100%;
  }
}

/* Reorganiza os cards de contato/processo em 2 colunas em tablets,
   sem precisar alterar as classes no HTML (col-lg-3) */
@media (min-width: 576px) and (max-width: 991.98px) {
  .row:has(> .col-lg-3 .contato-card) > .col-lg-3,
  .row:has(> .col-lg-3 .process-card) > .col-lg-3 {
    flex: 0 0 auto;
    width: 50%;
  }
}

/* =========================
   FORMULÁRIO DE ORÇAMENTO
========================= */
@media (max-width: 575.98px) {
  #formulario .row.align-items-center {
    flex-direction: column;
  }
}

/* =========================
   FOOTER (todas as páginas)
   Obs.: contato.css já cuida do footer em contato.html;
   as regras abaixo estendem o mesmo comportamento para
   index.html, produtos.html, empresa.html e portfolio.html.
========================= */
@media (max-width: 991.98px) {
  .footer-modern {
    text-align: center;
  }

  .footer-modern .row > div {
    margin-bottom: 35px;
  }

  .footer-modern .d-flex {
    justify-content: center !important;
  }

  .social-icon {
    width: 50px;
    height: 50px;
    font-size: 20px;
  }
}

@media (max-width: 575.98px) {
  .footer-modern .d-flex {
    flex-wrap: wrap;
    gap: 12px;
  }

  .social-icon {
    width: 42px;
    height: 42px;
    font-size: 17px;
  }
}

/* =========================
   MAPAS (embed do rodapé, fora do contato.html)
========================= */
@media (max-width: 575.98px) {
  .footer-modern iframe {
    height: 200px !important;
  }
}
