/* Agrical — site institucional. Linguagem visual inspirada na estrutura/tokens do 888 Ultra Black
   (ver MAPA-ESTRUTURA-888.md). Nenhum texto/marca do 888 usado — só tokens de layout/cor/tipografia. */

:root {
  --bg: #20201D;
  --card: #161613;
  --surface-dense: #161613;
  --surface-deep: #0E0E0C;
  --fg: #E3E1DD;
  --primary: #7A1F24;
  --primary-hover: #8E252B;
  --primary-fg: #F4F3F1;
  --secondary: #30302C;
  --muted: #2A2A27;
  --muted-fg: #928E87;
  --accent: #B27338;
  --accent-text: #D9A066; /* variante mais clara do accent, só para TEXTO sobre fundo escuro — garante WCAG AA 4.5:1 (o --accent original, #B27338, fica ~4.2:1 em texto pequeno sobre --bg/--surface-deep e falha o axe-core) */
  --border: #353531;
  --radius: 4px;
  --container-max: 1400px;
  --header-h-mobile: 64px;
  --header-h-desktop: 80px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "IBM Plex Sans", system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-inline: 16px;
}
@media (min-width: 1024px) {
  .container { padding-inline: 32px; }
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--primary);
  color: var(--primary-fg);
  padding: 12px 20px;
  z-index: 200;
  border-radius: var(--radius);
}
.skip-link:focus {
  left: 16px;
  top: 16px;
}

/* ===== Tipografia ===== */
h1, h2, h3, h4 {
  margin: 0;
  font-weight: 700;
  line-height: 1.15;
  text-wrap: balance;
}
h1 { font-size: clamp(32px, 6vw, 72px); }
h2 { font-size: clamp(24px, 3.4vw, 40px); }
h3 { font-size: clamp(20px, 2.4vw, 26px); }

p { margin: 0; text-wrap: pretty; }

.eyebrow {
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-text);
  font-weight: 600;
}

/* ===== Header ===== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--header-h-mobile);
  display: flex;
  align-items: center;
  background: rgba(32, 32, 29, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
@media (min-width: 768px) {
  .site-header { height: var(--header-h-desktop); }
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
}

.site-logo img {
  height: 40px;
  width: auto;
}
@media (min-width: 768px) {
  .site-logo img { height: 52px; }
}

.main-nav {
  display: none;
}
@media (min-width: 1024px) {
  .main-nav {
    display: flex;
    align-items: center;
    gap: 32px;
    flex: 1;
    justify-content: center;
  }
  .main-nav a {
    font-size: 14px;
    font-weight: 500;
    color: var(--fg);
    white-space: nowrap;
    transition: color 150ms ease-out;
  }
  .main-nav a:hover,
  .main-nav a:focus-visible,
  .main-nav a[aria-current="page"] {
    color: var(--accent-text);
  }
}

.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 22px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 150ms ease-out, border-color 150ms ease-out, color 150ms ease-out;
  white-space: nowrap;
}
.btn-primary {
  background: var(--primary);
  color: var(--primary-fg);
}
.btn-primary:hover, .btn-primary:focus-visible { background: var(--primary-hover); }
.btn-outline {
  background: transparent;
  color: var(--fg);
  border-color: var(--border);
}
.btn-outline:hover, .btn-outline:focus-visible { border-color: var(--accent-text); color: var(--accent-text); }

.hamburger {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
}
@media (min-width: 1024px) { .hamburger { display: none; } }
.hamburger span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--fg);
  transition: transform 200ms ease-out, opacity 200ms ease-out;
}
.hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  position: fixed;
  inset: var(--header-h-mobile) 0 0 0;
  background: var(--surface-deep);
  z-index: 90;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  transform: translateY(-8px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease-out, transform 220ms ease-out;
}
.mobile-menu.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.mobile-menu a {
  font-size: 22px;
  font-weight: 600;
}
@media (min-width: 1024px) { .mobile-menu { display: none; } }

@media (prefers-reduced-motion: reduce) {
  .mobile-menu, .hamburger span, .main-nav a, .btn, .hero-slide { transition: none !important; }
}

/* ===== Hero slider (Home) ===== */
.hero-slider {
  position: relative;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
  background: var(--surface-deep);
}
.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1000ms ease-out;
}
.hero-slide.is-active { opacity: 1; }
.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(14,14,12,0.88) 0%, rgba(14,14,12,0.55) 42%, rgba(14,14,12,0.15) 70%);
}
.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
  padding-top: var(--header-h-desktop);
}
.hero-text {
  max-width: 780px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.hero-text h1 {
  color: var(--fg);
  font-size: clamp(26px, 4.6vw, 50px);
  max-width: 34ch;
  letter-spacing: -0.005em;
}
.hero-text .hero-support { font-size: 18px; color: var(--fg); max-width: 50ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 8px; }
.hero-micro { font-size: 13px; color: var(--muted-fg); margin-top: 4px; }

.hero-nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  background: rgba(22,22,19,0.6);
  border: 1px solid var(--border);
  color: var(--fg);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  display: none;
  cursor: pointer;
  font-size: 20px;
}
@media (min-width: 768px) { .hero-nav-arrow { display: flex; } }
.hero-nav-arrow.prev { left: 24px; }
.hero-nav-arrow.next { right: 24px; }

.hero-dots {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  gap: 10px;
}
.hero-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(227,225,221,0.35);
  border: none;
  cursor: pointer;
  padding: 0;
}
.hero-dot.is-active { background: var(--fg); width: 22px; border-radius: 5px; }

/* ===== Hero textual (demais páginas) ===== */
.hero-textual {
  padding-top: calc(var(--header-h-desktop) + 110px);
  padding-bottom: 110px;
  background: var(--bg);
  text-align: center;
}
.hero-textual .container { max-width: 900px; }
.hero-textual h1 { margin: 0 auto; max-width: 20ch; }
.hero-textual .hero-support {
  margin-top: 20px;
  font-size: 18px;
  color: var(--muted-fg);
  max-width: 55ch;
  margin-inline: auto;
}

/* ===== Bifurcação (cards) ===== */
.split-section { background: var(--surface-dense); padding-block: 0; }
.split-grid {
  display: grid;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .split-grid { grid-template-columns: 1fr 1fr; }
}
.split-card {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}
@media (min-width: 768px) { .split-card { aspect-ratio: 3 / 2; } }
.split-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 700ms ease-out;
}
.split-card:hover img { transform: scale(1.05); }
.split-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(14,14,12,0.9) 0%, rgba(14,14,12,0.15) 55%, rgba(14,14,12,0) 75%);
  z-index: 1;
}
.split-card-content {
  position: relative;
  z-index: 2;
  padding: 36px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.split-card-content p { color: var(--fg); max-width: 40ch; }

/* ===== Faixa de herança / banda sólida ===== */
.band-solid {
  background: #000000;
  padding-block: 120px;
  text-align: center;
}
.band-solid h2 { color: var(--fg); max-width: 22ch; margin-inline: auto; }
.band-solid .btn { margin-top: 32px; }

/* ===== Footer ===== */
.site-footer {
  background: var(--surface-deep);
  border-top: 1px solid var(--border);
  padding-block: 64px 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  padding-bottom: 48px;
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 24px; }
}
.footer-brand img { height: 68px; width: auto; margin-bottom: 14px; }
.footer-brand p { color: var(--muted-fg); font-size: 14px; max-width: 32ch; }
.footer-col .footer-heading {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-text);
  margin: 0 0 18px;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.footer-col a, .footer-col p {
  font-size: 14px;
  color: var(--muted-fg);
  transition: color 150ms ease-out;
}
.footer-col a:hover, .footer-col a:focus-visible { color: var(--fg); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-block: 22px;
  text-align: center;
}
.footer-bottom p { color: var(--muted-fg); font-size: 13px; }

/* ===== Utilitários ===== */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

main { display: block; }
