:root {
  color-scheme: light;
  --ink: #17211f;
  --muted: #5f6d68;
  --line: #dfe8e3;
  --paper: #f8faf7;
  --surface: #ffffff;
  --mint: #dff3e8;
  --green: #12745f;
  --teal: #0c5560;
  --gold: #b48124;
  --coral: #c75f4d;
  --shadow: 0 18px 45px rgba(25, 49, 43, 0.11);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 15% 10%, rgba(223, 243, 232, 0.95), transparent 28rem),
    linear-gradient(180deg, #f4f8f5 0%, #ffffff 46%, #f8faf7 100%);
  color: var(--ink);
}

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

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 5vw, 72px);
  border-bottom: 1px solid rgba(223, 232, 227, 0.8);
  background: rgba(248, 250, 247, 0.88);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  background: var(--green);
  color: #fff;
  font-weight: 800;
}

.brand strong,
.brand small {
  display: block;
}

.brand small,
.eyebrow,
.post-meta,
footer span {
  color: var(--muted);
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  color: #33413d;
  font-size: 0.95rem;
  font-weight: 650;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.65fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
  min-height: calc(100vh - 79px);
  padding: clamp(56px, 7vw, 104px) clamp(20px, 5vw, 72px) 42px;
}

.hero-copy {
  max-width: 900px;
}

.eyebrow {
  margin: 0 0 12px;
  text-transform: uppercase;
  letter-spacing: 0;
  font-size: 0.79rem;
  font-weight: 800;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 900px;
  margin-bottom: 22px;
  font-size: clamp(2.55rem, 6.5vw, 5.7rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.hero-copy > p:not(.eyebrow) {
  max-width: 760px;
  color: #42524e;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  line-height: 1.62;
}

.hero-actions,
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button,
.chip {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-weight: 800;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 18px;
}

.button.primary,
.chip.active {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}

.button.ghost {
  background: transparent;
}

.hero-panel {
  display: grid;
  gap: 14px;
}

.hero-panel > div,
.post,
.clusters article,
.workflow > div,
.lead form {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
}

.hero-panel > div {
  padding: 22px;
}

.metric {
  display: block;
  margin-bottom: 10px;
  color: var(--teal);
  font-size: 2.45rem;
  font-weight: 900;
  line-height: 1;
}

.ticker {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 16px clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #102722;
  color: #fff;
}

.ticker span {
  color: #a9cbc1;
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

.ticker strong {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 7px 11px;
  font-size: 0.88rem;
}

.section {
  padding: clamp(56px, 8vw, 96px) clamp(20px, 5vw, 72px);
}

.section-heading {
  max-width: 780px;
  margin-bottom: 28px;
}

.section-heading.row {
  display: flex;
  max-width: none;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

h2 {
  margin-bottom: 0;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.05;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.25rem;
  line-height: 1.2;
}

.clusters,
.workflow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.clusters article,
.workflow > div {
  min-height: 220px;
  padding: 22px;
}

.clusters span,
.workflow span {
  display: inline-grid;
  width: 36px;
  height: 36px;
  place-items: center;
  margin-bottom: 22px;
  border-radius: 8px;
  background: var(--mint);
  color: var(--green);
  font-weight: 900;
}

.clusters p,
.workflow p,
.post p,
.lead p {
  color: var(--muted);
  line-height: 1.55;
}

.article-shell {
  background: #eef5f1;
}

.search {
  display: grid;
  min-width: min(100%, 330px);
  gap: 7px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 800;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.search input {
  min-height: 46px;
  padding: 0 14px;
}

.chip {
  padding: 10px 13px;
}

.articles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 22px;
}

.post {
  display: flex;
  min-height: 278px;
  flex-direction: column;
  padding: 22px;
}

.post.featured {
  grid-column: span 2;
  background: linear-gradient(135deg, #10362f 0%, #0c5560 100%);
  color: #fff;
}

.post.featured p,
.post.featured .post-meta {
  color: #d3ebe4;
}

.tag {
  width: fit-content;
  margin-bottom: 24px;
  border-radius: 999px;
  background: rgba(18, 116, 95, 0.12);
  color: var(--green);
  padding: 7px 10px;
  font-size: 0.79rem;
  font-weight: 900;
}

.featured .tag {
  background: rgba(255, 255, 255, 0.13);
  color: #fff;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: auto;
  padding-top: 22px;
  font-size: 0.88rem;
  font-weight: 750;
}

.automation {
  background: #fff;
}

.workflow > div:nth-child(2) span {
  background: #f3e6ca;
  color: var(--gold);
}

.workflow > div:nth-child(3) span {
  background: #e1eef2;
  color: var(--teal);
}

.workflow > div:nth-child(4) span {
  background: #f7ded9;
  color: var(--coral);
}

.lead {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(320px, 0.55fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
  background: #102722;
  color: #fff;
}

.lead .eyebrow,
.lead p {
  color: #bdd9d2;
}

.lead form {
  display: grid;
  gap: 14px;
  padding: 22px;
  color: var(--ink);
}

.lead label {
  display: grid;
  gap: 7px;
  color: #41504c;
  font-size: 0.88rem;
  font-weight: 800;
}

.lead input,
.lead select,
.lead textarea {
  min-height: 44px;
  padding: 10px 12px;
}

textarea {
  min-height: 104px;
  resize: vertical;
}

footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding: 28px clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
  background: #fff;
}

.hidden {
  display: none;
}

/* Honeypot do formulário de lead (ver app/templates/home.html): escondido
   por posicionamento fora da tela, de propósito NÃO com display:none nem
   visibility:hidden — alguns bots checam essas duas propriedades e pulam
   o campo; um humano nunca vê nem alcança este campo via teclado
   (tabindex="-1"), mas ele continua presente no DOM para quem preenche
   tudo às cegas. */
.campo-armadilha {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

@media (max-width: 920px) {
  .hero,
  .lead,
  .section-heading.row {
    grid-template-columns: 1fr;
  }

  .section-heading.row {
    display: grid;
    align-items: start;
  }

  .clusters,
  .workflow,
  .articles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero {
    min-height: auto;
  }

  .clusters,
  .workflow,
  .articles {
    grid-template-columns: 1fr;
  }

  .post.featured {
    grid-column: auto;
  }
}
