/* MTH Engenharia — versão HTML/CSS/JS/PHP
   Paleta: PANTONE 2747C (navy), 370C (verde folha), 367C (verde limão) */

:root {
  --navy: #10256b;
  --navy-deep: #0a1747;
  --navy-foreground: #f7f9fc;
  --leaf: #3f9c35;
  --lime: #a4ce4e;

  --background: #ffffff;
  --foreground: #0a1747;
  --muted: #f2f5f9;
  --muted-foreground: #64708a;
  --border: #e2e8f0;

  --gradient-navy: linear-gradient(160deg, var(--navy-deep), var(--navy));
  --gradient-leaf: linear-gradient(90deg, var(--leaf), var(--lime));
  --shadow-elegant: 0 20px 50px -24px rgba(16, 37, 107, 0.55);
  --radius: 4px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--background);
  color: var(--foreground);
  font-family: "Barlow", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .font-display {
  font-family: "Oswald", system-ui, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 1.1;
  font-weight: 600;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }

.container { width: 100%; max-width: 1152px; margin: 0 auto; padding: 0 20px; }
.container.narrow { max-width: 768px; }
.center { text-align: center; }

.surface-navy { background-image: var(--gradient-navy); color: var(--navy-foreground); }

.text-gradient-leaf {
  background-image: var(--gradient-leaf);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.icon { width: 20px; height: 20px; flex: none; }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 10px 18px;
  font-family: "Oswald", system-ui, sans-serif;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s, opacity 0.2s;
}
.btn-sm { padding: 8px 14px; font-size: 13px; }
.btn-lg { padding: 13px 24px; font-size: 15px; }
.btn-block { display: flex; width: 100%; margin-top: 16px; }
.btn-secondary { background: var(--leaf); color: #fff; }
.btn-secondary:hover { background: #368630; }
.btn-outline { border-color: var(--border); color: var(--foreground); background: transparent; }
.btn-outline:hover { background: var(--muted); }
.btn-ghost { border-color: rgba(255, 255, 255, 0.3); color: var(--navy-foreground); background: transparent; }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.1); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.center-row { justify-content: center; }

/* ---------- Cabeçalho ---------- */
.site-header { position: sticky; top: 0; z-index: 50; border-bottom: 1px solid rgba(255, 255, 255, 0.1); }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding-top: 14px; padding-bottom: 14px; }
.logo img { height: 48px; width: auto; background: #fff; border-radius: 3px; padding: 4px 8px; }
.nav-desktop { display: none; align-items: center; gap: 28px; }
.nav-desktop > a { font-size: 14px; font-weight: 500; color: rgba(247, 249, 252, 0.8); transition: color 0.2s; }
.nav-desktop > a:hover { color: var(--lime); }
.nav-toggle { background: none; border: 0; color: var(--navy-foreground); cursor: pointer; }
.nav-toggle svg { width: 26px; height: 26px; }
.nav-mobile { display: none; flex-direction: column; padding: 0 20px 20px; border-top: 1px solid rgba(255, 255, 255, 0.1); }
.nav-mobile.open { display: flex; }
.nav-mobile > a { padding: 12px 0; font-size: 14px; color: rgba(247, 249, 252, 0.85); border-bottom: 1px solid rgba(255, 255, 255, 0.1); }

@media (min-width: 900px) {
  .nav-desktop { display: flex; }
  .nav-toggle { display: none; }
  .nav-mobile { display: none !important; }
}

/* ---------- Hero ---------- */
.hero { overflow: hidden; }
.hero-grid { display: grid; gap: 40px; align-items: center; padding-top: 64px; padding-bottom: 64px; }
.eyebrow { display: inline-block; border-left: 2px solid var(--leaf); padding-left: 12px; font-size: 12px; letter-spacing: 0.3em; color: var(--lime); }
.eyebrow.plain { border: 0; padding-left: 0; }
.hero h1 { margin-top: 24px; font-size: clamp(2.2rem, 6vw, 3.75rem); font-weight: 700; color: var(--navy-foreground); }
.hero-text { margin-top: 24px; max-width: 32rem; color: rgba(247, 249, 252, 0.75); }
.hero-media { position: relative; }
.hero-media img { width: 100%; border-radius: var(--radius); object-fit: cover; box-shadow: var(--shadow-elegant); position: relative; }
.dotted-grid {
  position: absolute; top: -20px; left: -20px; width: 96px; height: 96px; display: none;
  background-image: radial-gradient(rgba(164, 206, 78, 0.7) 1.2px, transparent 1.2px);
  background-size: 10px 10px;
}

@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1fr 1fr; padding-top: 96px; padding-bottom: 96px; }
  .dotted-grid { display: block; }
}

/* ---------- Pilares ---------- */
.pillars { background: var(--muted); border-bottom: 1px solid var(--border); }
.pillars-grid { display: grid; gap: 0; }
.pillars-grid > div { padding: 28px 0; }
.pillars-grid h3 { font-size: 1.25rem; color: var(--navy); }
.pillars-grid p { margin-top: 8px; font-size: 14px; color: var(--muted-foreground); }
@media (min-width: 640px) {
  .pillars-grid { grid-template-columns: repeat(3, 1fr); }
  .pillars-grid > div { padding: 32px 24px; }
}

/* ---------- Seções ---------- */
.section { padding: 72px 0; scroll-margin-top: 80px; }
.section.muted { background: var(--muted); }
.section h2 { font-size: clamp(1.75rem, 4vw, 2.25rem); color: var(--navy); }
.section h2.on-navy { color: var(--navy-foreground); }
.section p { color: var(--muted-foreground); }
.section .on-navy-text { color: rgba(247, 249, 252, 0.75); margin-top: 20px; }
.rule { width: 64px; height: 4px; background: var(--leaf); margin-top: 16px; }
.two-col { display: grid; gap: 40px; align-items: center; }
.two-col p + p { margin-top: 16px; }
.two-col > div > p:first-of-type { margin-top: 24px; }
.rounded { border-radius: var(--radius); object-fit: cover; width: 100%; }
@media (min-width: 900px) { .two-col { grid-template-columns: 1fr 1fr; gap: 48px; } }

.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; margin-top: 32px; }
.stats dt { font-family: "Oswald", sans-serif; font-size: 1.875rem; color: var(--leaf); }
.stats dd { font-size: 14px; color: var(--muted-foreground); }

/* ---------- Serviços ---------- */
.services-grid { display: grid; gap: 1px; background: var(--border); margin-top: 40px; }
.service-card { background: #fff; padding: 28px; transition: background-color 0.25s; }
.service-card .icon { width: 32px; height: 32px; color: var(--leaf); }
.service-card h3 { margin-top: 20px; font-size: 1.125rem; color: var(--navy); }
.service-card p { margin-top: 8px; font-size: 14px; color: var(--muted-foreground); }
.service-card:hover { background: var(--navy); }
.service-card:hover h3 { color: var(--navy-foreground); }
.service-card:hover p { color: rgba(247, 249, 252, 0.75); }
.service-card:hover .icon { color: var(--lime); }
@media (min-width: 640px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .services-grid { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Inspeção ---------- */
.check-list { list-style: none; margin-top: 32px; display: grid; gap: 12px; }
.check-list li { display: flex; align-items: center; gap: 12px; color: var(--navy-foreground); }
.check-list .icon { color: var(--lime); }
#inspecao .btn { margin-top: 32px; }
.duo-grid { display: grid; gap: 16px; }
.duo-grid img { height: 100%; }
@media (min-width: 640px) { .duo-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- Obras ---------- */
.works-list { list-style: none; display: grid; gap: 16px; margin-top: 40px; }
.works-list li {
  background: var(--muted);
  border-left: 2px solid var(--leaf);
  padding: 22px 20px;
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  font-size: 1.05rem;
  color: var(--navy);
}
@media (min-width: 640px) { .works-list { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .works-list { grid-template-columns: repeat(3, 1fr); } }

.gallery { display: grid; gap: 12px; margin-top: 40px; }
.gallery figure { overflow: hidden; border-radius: var(--radius); background: var(--muted); }
.gallery img { height: 256px; width: 100%; object-fit: cover; transition: transform 0.5s; }
.gallery img:hover { transform: scale(1.05); }
@media (min-width: 640px) { .gallery { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .gallery { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Contato ---------- */
.contact-form { margin-top: 40px; text-align: left; display: grid; gap: 16px; }
.contact-form label { display: block; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted-foreground); }
.contact-form input, .contact-form select, .contact-form textarea {
  width: 100%; margin-top: 6px; padding: 11px 12px;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: #fff; color: var(--foreground);
  font-family: inherit; font-size: 15px; text-transform: none; letter-spacing: normal;
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus {
  outline: 2px solid var(--leaf); outline-offset: 1px; border-color: var(--leaf);
}
.field-row { display: grid; gap: 16px; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } }
.hp { position: absolute; left: -9999px; opacity: 0; }
.alert { margin-top: 24px; padding: 12px 16px; border-radius: var(--radius); font-size: 14px; }
.alert.success { background: rgba(63, 156, 53, 0.12); color: #2c6f26; }
.alert.error { background: rgba(200, 40, 40, 0.1); color: #a02020; }

/* ---------- Rodapé ---------- */
.site-footer { border-top: 1px solid rgba(255, 255, 255, 0.1); }
.footer-grid { display: grid; gap: 32px; padding-top: 56px; padding-bottom: 56px; }
.footer-about { margin-top: 16px; max-width: 20rem; font-size: 14px; color: rgba(247, 249, 252, 0.7); }
.footer-title { font-size: 14px; letter-spacing: 0.2em; color: var(--lime); }
.footer-list { list-style: none; margin-top: 16px; display: grid; gap: 12px; font-size: 14px; color: rgba(247, 249, 252, 0.8); }
.footer-list li { display: flex; align-items: center; gap: 8px; }
.footer-list .icon { width: 16px; height: 16px; color: var(--leaf); }
.footer-copy { font-size: 12px; color: rgba(247, 249, 252, 0.5); }
@media (min-width: 900px) {
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-copy { text-align: right; }
}

/* ---------- WhatsApp flutuante ---------- */
.wa-float {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  width: 52px; height: 52px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--leaf); color: #fff;
  box-shadow: 0 10px 24px -8px rgba(16, 37, 107, 0.6);
}
.wa-float:hover { background: #368630; }

/* ---------- Animação de entrada ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
