
/*
Theme Name: Mobilidade Biometano
Theme URI: https://www.mobilidadebiometano.com.br/
Author: Marcus + ChatGPT
Description: Tema leve com menu nativo do WordPress, homepage com hero (imagem destacada), páginas internas com fundo #114030 e CPT "Produtor de Biometano".
Version: 1.0.0
Text Domain: mbtheme
*/

/* Tipografia e reset básico */
html, body {margin:0; padding:0;}
body {
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  color: #0f1f17;
  background: #114030;
}

/* Páginas internas com fundo verde escuro */
body:not(.home) {
  background: #114030;
  color: #f0f7f3;
}

/* Links */
a { color: #0FA570; text-decoration: none; }
a:hover { text-decoration: underline; }

/* Cabeçalho */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(17,64,48,0.92);
  color: #fff;
  backdrop-filter: saturate(180%) blur(8px);
}
.home .site-header {
  background: #114030;
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.site-branding a { color: #fff; font-weight: 700; letter-spacing: .3px; font-size: 18px; }

/* Menu */
.primary-nav { display: flex; align-items: center; gap: 24px; }
.primary-nav .menu { list-style: none; margin:0; padding:0; display:flex; gap: 24px; }
.primary-nav .menu > li > a { color: #fff; font-weight: 600; }
.primary-nav .menu > li > a:hover { opacity: .85; }

/* Hamburguer no mobile */
.menu-toggle {
  display: none;
  background: transparent;
  border: 0;
  width: 36px; height: 36px;
  position: relative;
}
.menu-toggle span, .menu-toggle::before, .menu-toggle::after {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  height: 2px;
  background: #fff;
  transition: all .2s ease;
}
.menu-toggle span { top: 17px; }
.menu-toggle::before { top: 10px; }
.menu-toggle::after { bottom: 10px; }

@media (max-width: 900px) {
  .menu-toggle { display: inline-block; }
  .primary-nav { display:none; }
  .primary-nav.is-open { 
    display:block; 
    width: 100%;
  }
  .primary-nav .menu { flex-direction: column; gap: 14px; padding: 12px 0; }
  .header-inner { flex-wrap: wrap; }
}

/* Hero da Home (usa Imagem Destacada da página Home) */
.hero {
  position: relative;
  min-height: 60vh;
  display: grid;
  place-items: center;
  text-align: center;
  color: #fff;
  overflow: hidden;
}
.hero::before {
  content:"";
  position:absolute; inset:0;
  background-size: cover;
  background-position: center;
  filter: saturate(110%) contrast(105%);
  z-index: 0;
}
.hero::after {
  content:"";
  position:absolute; inset:0;
  background: linear-gradient(180deg, rgba(0,0,0,.55), rgba(0,0,0,.25));
  z-index: 1;
}
.hero-inner { position: relative; z-index: 2; padding: 60px 20px; max-width: 980px; }
.hero h1 { font-size: clamp(28px, 5vw, 54px); margin: 0 0 10px; letter-spacing:.2px; }
.hero p { font-size: clamp(16px, 2.2vw, 22px); opacity: .95; }

/* Conteúdo genérico */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 28px 20px;
  background: transparent;
}
body:not(.home) .card, body:not(.home) .post-content {
  background: #114030;
  border: 0px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  padding: 16px 18px;
}

/* Listagens (posts e produtores) */
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 22px;
}
@media (max-width: 980px) { .grid { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 640px) { .grid { grid-template-columns: 1fr; } }

.card {
  background: #fff;
  border: 1px solid #e6ece8;
  border-radius: 12px;
  padding: 16px 18px;
}
body:not(.home) .card a { color: #A9F5D0; }
.card h2, .card h3 { margin: 0 0 8px; font-size: 20px; }
.card p { margin: 0; }

/* Footer */
.site-footer {
  color:#ffffff;
  background:#114030;
  margin-top: 40px;
}
.site-footer .container { padding: 28px 20px; }
.site-footer a { color:#b9fde2; }

.bg-green { background-color: #114030 !important; }


/* Forçar fundo verde no header */
.site-header,
.site-header.bg-green,
header.bg-green {
    background-color: #114030 !important;
}

/* Garantir centralização do rodapé */
.site-footer,
.footer,
.footer .container {
    text-align: center !important;
    justify-content: center !important;
}
