/* ================================================================
   HOME.CSS — WikiAgro — Mobile-First / Editorial / Técnico
   Correção V57: hero coluna única, busca Bulário, autocomplete técnico
   ================================================================ */

/* ── BASE ── */
.home-main {
  width: 100%;
  background: #f7f5f1;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #1a1714;
}

/* ── HERO — coluna única em todos os tamanhos mobile ── */
.h-hero {
  background: #3d2810;
  padding: 24px 20px 24px;
}
.h-hero__col {
  width: 100%;
  max-width: 640px;
}
.h-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.38);
  margin-bottom: 12px;
}
.h-hero__dot {
  width: 5px;
  height: 5px;
  background: #4caf50;
  border-radius: 50%;
  flex-shrink: 0;
}
.h-hero__title {
  font-family: 'Baloo 2', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
  letter-spacing: -0.025em;
  margin: 0 0 10px;
}
.h-hero__sub {
  font-size: 14px;
  color: rgba(255,255,255,0.45);
  line-height: 1.6;
  margin: 0 0 20px;
  max-width: 520px;
}

/* ── BUSCA — 100% largura no mobile ── */
.h-search {
  display: flex;
  align-items: stretch;
  background: rgba(255,255,255,0.09);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 8px;
  overflow: hidden;
  width: 100%;
  transition: border-color 0.18s;
}
.h-search:focus-within {
  border-color: rgba(129,199,132,0.7);
  background: rgba(255,255,255,0.12);
}
.h-search__input {
  flex: 1;
  height: 50px;
  padding: 0 14px;
  font-size: 15px;
  color: #fff;
  background: transparent;
  border: none;
  outline: none;
  font-family: inherit;
  min-width: 0;
  caret-color: #81c784;
}
.h-search__input::placeholder { color: rgba(255,255,255,0.28); }
.h-search__div {
  width: 1px;
  background: rgba(255,255,255,0.12);
  align-self: stretch;
  margin: 10px 0;
  flex-shrink: 0;
}
.h-search__btn {
  height: 50px;
  padding: 0 18px;
  background: #2e7d32;
  color: #fff;
  border: none;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: inherit;
  flex-shrink: 0;
  transition: background 0.15s;
}
.h-search__btn:hover { background: #1b5e20; }
.h-search__btn svg { width: 15px; height: 15px; flex-shrink: 0; }
.h-search__hint {
  margin-top: 10px;
  font-size: 11px;
  color: rgba(255,255,255,0.22);
  letter-spacing: 0.02em;
}

/* ── AUTOCOMPLETE — técnico, sem ícones decorativos ── */
.h-ac {
  display: none;
  position: fixed;
  background: #fff;
  border: 1px solid #e5e1d8;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.11);
  z-index: 99999;
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 360px;
  overflow-y: auto;
  min-width: 240px;
}
.h-ac__item {
  padding: 15px 16px;
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid #f0ede8;
  transition: background 0.1s;
}
.h-ac__item:last-of-type { border-bottom: none; }
.h-ac__item:hover, .h-ac__item.active { background: #faf9f6; }
.h-ac__body { flex: 1; min-width: 0; }
.h-ac__name {
  font-size: 15px;
  font-weight: 600;
  color: #1a1714;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}
.h-ac__empresa {
  font-size: 13px;
  color: #9a9590;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.h-ac__ia {
  font-size: 12px;
  color: #7a756e;
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-style: italic;
}
.h-ac__classe {
  font-size: 11px;
  font-weight: 600;
  color: #5a5550;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  flex-shrink: 0;
  align-self: flex-start;
  padding-top: 2px;
  white-space: nowrap;
}
.h-ac__empty {
  padding: 14px 16px;
  font-size: 13px;
  color: #9a9590;
}
.h-ac__footer {
  padding: 10px 16px;
  border-top: 1px solid #f0ede8;
  background: #faf9f6;
}
.h-ac__ver-todos {
  font-size: 12px;
  color: #2e7d32;
  text-decoration: none;
  font-weight: 500;
}
.h-ac__ver-todos:hover { text-decoration: underline; }

/* ── SEÇÃO GENÉRICA ── */
.h-section {
  padding: 28px 20px;
}
.h-section--alt { background: #fff; }
.h-section--dark { background: #3d2810; }
.h-section__inner { width: 100%; }
.h-section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 8px;
}
.h-section__title {
  font-family: 'Baloo 2', sans-serif;
  font-size: 10px;
  font-weight: 700;
  color: #a09890;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin: 0;
}
.h-section__link {
  font-size: 12px;
  color: #2e7d32;
  text-decoration: none;
  font-weight: 500;
}
.h-section__link:hover { text-decoration: underline; }

/* ── LISTA EDITORIAL DE ÁREAS ── */
.h-areas {
  list-style: none;
  margin: 0;
  padding: 0;
}
.h-area {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid #e5e1d8;
  text-decoration: none;
  color: inherit;
}
.h-area:last-child { border-bottom: none; }
.h-area:hover .h-area__name { color: #2e7d32; }
.h-area__num {
  font-size: 11px;
  font-weight: 700;
  color: #d0cbc0;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  padding-top: 2px;
  flex-shrink: 0;
  width: 20px;
  text-align: right;
}
.h-area--main .h-area__num { color: #2e7d32; }
.h-area__body { flex: 1; min-width: 0; }
.h-area__name {
  font-family: 'Baloo 2', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #1a1714;
  letter-spacing: -0.01em;
  display: block;
  margin-bottom: 3px;
  transition: color 0.12s;
}
.h-area--main .h-area__name { font-size: 18px; }
.h-area__count {
  font-size: 12px;
  color: #7a756e;
  display: block;
  margin-bottom: 4px;
}
.h-area__desc {
  font-size: 13px;
  color: #a09890;
  line-height: 1.5;
  display: block;
}
.h-area--main .h-area__desc { color: #7a756e; }
.h-area__arrow {
  font-size: 14px;
  color: #d0cbc0;
  flex-shrink: 0;
  padding-top: 2px;
  transition: color 0.12s, transform 0.12s;
}
.h-area:hover .h-area__arrow { color: #2e7d32; transform: translateX(2px); }

/* ── ÍNDICE TÉCNICO DE PRODUTOS — uma coluna no mobile ── */
.h-products {
  list-style: none;
  margin: 0;
  padding: 0;
}
.h-product {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid #e5e1d8;
  text-decoration: none;
  color: inherit;
}
.h-product:last-child { border-bottom: none; }
.h-product:hover .h-product__name { color: #2e7d32; }
.h-product__num {
  font-size: 11px;
  font-weight: 700;
  color: #d0cbc0;
  font-variant-numeric: tabular-nums;
  padding-top: 2px;
  flex-shrink: 0;
  width: 20px;
  text-align: right;
}
.h-product:first-child .h-product__num { color: #2e7d32; }
.h-product__body { flex: 1; min-width: 0; }
.h-product__name {
  font-family: 'Baloo 2', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #1a1714;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.01em;
  transition: color 0.12s;
}
.h-product__ia {
  font-size: 12px;
  color: #7a756e;
  display: block;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.h-product__class {
  font-size: 11px;
  font-weight: 500;
  color: #9a9490;
  display: block;
  margin-top: 3px;
}

/* ── CULTURAS — grid 2 colunas no mobile ── */
.h-culturas {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border: 1px solid #e5e1d8;
  border-radius: 8px;
  overflow: hidden;
}
.h-cultura {
  display: flex;
  flex-direction: column;
  padding: 14px 16px;
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid #e5e1d8;
  border-right: 1px solid #e5e1d8;
  background: #fff;
  transition: background 0.1s;
}
.h-cultura:nth-child(even) { border-right: none; }
.h-cultura:nth-last-child(-n+2) { border-bottom: none; }
.h-cultura:hover { background: #faf9f7; }
.h-cultura:hover .h-cultura__name { color: #2e7d32; }
.h-cultura__name {
  font-size: 14px;
  font-weight: 600;
  color: #1a1714;
  letter-spacing: -0.01em;
  transition: color 0.12s;
}
.h-cultura__count {
  font-size: 11px;
  color: #a09890;
  margin-top: 3px;
  font-variant-numeric: tabular-nums;
}

/* ── SOBRE ── */
.h-about__inner {
  text-align: center;
  max-width: 480px;
  margin: 0 auto;
}
.h-about__title {
  font-family: 'Baloo 2', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.h-about__text {
  font-size: 13px;
  color: rgba(255,255,255,0.4);
  line-height: 1.6;
  margin: 0 0 16px;
}
.h-about__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}
.h-about__link {
  font-size: 12px;
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  padding: 4px 10px;
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 4px;
  transition: color 0.12s, border-color 0.12s;
  font-family: inherit;
}
.h-about__link:hover { color: #fff; border-color: rgba(255,255,255,0.25); }

/* ── SCREEN READER ── */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ── TABLET: 640px+ ── */
@media (min-width: 640px) {
  .h-hero { padding: 36px 32px 32px; }
  .h-hero__title { font-size: 32px; }
  .h-section { padding: 36px 32px; }
  .h-culturas { grid-template-columns: repeat(3, 1fr); }
  .h-cultura:nth-child(even) { border-right: 1px solid #e5e1d8; }
  .h-cultura:nth-child(3n) { border-right: none; }
  .h-cultura:nth-last-child(-n+3) { border-bottom: none; }
  .h-cultura:nth-last-child(n+4) { border-bottom: 1px solid #e5e1d8; }
}

/* ── DESKTOP: 1024px+ ── */
@media (min-width: 1024px) {
  .h-hero {
    padding: 44px 0 40px;
  }
  .h-hero__col {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 40px;
  }
  .h-hero__title { font-size: 36px; }
  .h-hero__sub { font-size: 15px; }
  .h-search { max-width: 600px; }
  .h-section { padding: 44px 0; }
  .h-section__inner {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 40px;
  }
  /* Desktop: áreas em 2 colunas com Bulário em destaque */
  .h-areas {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
  }
  .h-area--main {
    grid-column: 1 / 3;
    border-bottom: 1px solid #e5e1d8;
    padding-bottom: 20px;
  }
  .h-area--main .h-area__name { font-size: 20px; }
  .h-area:not(.h-area--main) {
    border-bottom: 1px solid #e5e1d8;
    padding: 16px 0;
  }
  .h-area:nth-child(odd):not(.h-area--main) {
    padding-right: 24px;
    border-right: none;
  }
  .h-area:nth-child(even):not(.h-area--main) {
    padding-left: 24px;
    border-left: 1px solid #e5e1d8;
  }
  .h-area:nth-child(even):not(.h-area--main) {
    padding-left: 32px;
  }
  .h-area:nth-last-child(-n+2):not(.h-area--main) { border-bottom: none; }
  /* Desktop: produtos em 2 colunas */
  .h-products {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 40px;
  }
  .h-product { border-bottom: 1px solid #e5e1d8; }
  /* Desktop: culturas em 3 colunas */
  .h-culturas { grid-template-columns: repeat(3, 1fr); }
  .h-cultura:nth-child(even) { border-right: 1px solid #e5e1d8; }
  .h-cultura:nth-child(3n) { border-right: none; }
}

/* ── DESKTOP GRANDE: 1280px+ ── */
@media (min-width: 1280px) {
  .h-hero__col { max-width: 1200px; }
  .h-section__inner { max-width: 1200px; }
}

/* ── V63: Ocultar botão voltar ao topo na Home ── */
body.page-home #back-to-top,
body.page-home #ds-back-to-top {
}

/* V85.10.2 — Tipografia exclusiva da seção Culturas */
.h-section[aria-label="Culturas"] .h-section__title,
.h-section[aria-label="Culturas"] .h-section__link,
.h-section[aria-label="Culturas"] .h-cultura__name {
  font-family: "Baloo 2", sans-serif;
}
