/* ============================================================
   Agropro — hoja de estilo única
   Tipografía: Archivo (variable, eje de ancho) — un solo tipo.
   Acento: verde tomado del logo real de Agropro. Un solo acento.
   Escala de espaciado: 4 8 12 16 24 32 48 64 96 128
   ============================================================ */

:root {
  --ink:        #0F1A14;
  --ink-soft:   #1B2A21;
  --paper:      #F7F5EF;
  --bone:       #EDE9DD;
  --line:       #D8D3C4;
  --line-dark:  rgba(247, 245, 239, .16);
  --muted:      #56615A;
  --muted-light:#A9B4AC;

  --green:       #2F7A52;   /* acento */
  --green-deep:  #1E5537;   /* acento sobre papel, texto */
  --green-press: #24603F;
  --green-bright:#69C494;   /* acento sobre oscuro */

  --s-1: 4px;  --s-2: 8px;  --s-3: 12px; --s-4: 16px;
  --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 64px;
  --s-9: 96px; --s-10: 128px;

  --gutter: var(--s-5);
  --maxw: 1240px;
  --radius: 2px;

  --ease: cubic-bezier(.22, .61, .36, 1);
}

@media (min-width: 720px)  { :root { --gutter: var(--s-7); } }
@media (min-width: 1100px) { :root { --gutter: var(--s-8); } }

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Archivo, "Helvetica Neue", Arial, sans-serif;
  font-variation-settings: "wdth" 100;
  font-size: 17px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, picture, svg { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3 { margin: 0; line-height: 1.03; letter-spacing: -0.025em; font-weight: 700; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }

.skip {
  position: absolute; left: var(--s-4); top: -100px; z-index: 100;
  background: var(--ink); color: var(--paper);
  padding: var(--s-3) var(--s-4); text-decoration: none; font-weight: 600;
}
.skip:focus { top: var(--s-4); }

:where(a, button, input, select, textarea):focus-visible {
  outline: 2px solid var(--green-bright);
  outline-offset: 3px;
}

/* ---------- Etiquetas / eyebrow ---------- */
.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--green-deep);
  margin-bottom: var(--s-4);
}
.eyebrow.light { color: var(--green-bright); }

/* ---------- Tipografía de display ---------- */
.display {
  font-size: clamp(38px, 8.2vw, 108px);
  font-weight: 800;
  font-variation-settings: "wdth" 92;
  letter-spacing: -0.035em;
  line-height: .96;
}
.display em { font-style: normal; color: var(--green-bright); }

h2 {
  font-size: clamp(30px, 4.4vw, 54px);
  font-weight: 700;
  font-variation-settings: "wdth" 96;
  letter-spacing: -0.03em;
}
h3 { font-size: 21px; font-weight: 700; letter-spacing: -0.015em; }
.balance { text-wrap: balance; }

/* En pantallas angostas los saltos de línea escritos a mano para los h2
   estorban; el h1 conserva el suyo porque separa las dos mitades de la frase. */
@media (max-width: 700px) {
  h2 br { display: none; }
  h2 { text-wrap: balance; }
}

.lede, .sec-lede { font-size: clamp(17px, 1.55vw, 20px); color: var(--muted); max-width: 54ch; }
.lede.light, .sec-lede.light { color: var(--muted-light); }
.lede { color: rgba(247,245,239,.86); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: var(--s-2);
  background: var(--green); color: #fff;
  border: 0; border-radius: var(--radius);
  padding: var(--s-3) var(--s-5);
  font: inherit; font-size: 15px; font-weight: 600; letter-spacing: -0.005em;
  text-decoration: none; cursor: pointer;
  transition: background .18s var(--ease), transform .18s var(--ease);
}
.btn:hover  { background: var(--green-press); }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: var(--s-2) var(--s-4); font-size: 14px; }
.btn-lg { padding: var(--s-4) var(--s-6); font-size: 16px; }
.btn-wide { width: 100%; justify-content: center; }
.btn-ghost {
  background: transparent; color: var(--paper);
  box-shadow: inset 0 0 0 1px rgba(247,245,239,.42);
}
.btn-ghost:hover { background: rgba(247,245,239,.10); box-shadow: inset 0 0 0 1px rgba(247,245,239,.7); }
.wa-i { width: 18px; height: 18px; fill: currentColor; stroke: none; }

/* ---------- Cabecera ---------- */
.site-head {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  transition: background .3s var(--ease), box-shadow .3s var(--ease);
}
/* Sin backdrop-filter a propósito: el fondo ya es casi opaco y el desenfoque
   sobre una cabecera fija repinta en cada scroll (caro en celular). */
.site-head.is-stuck {
  background: rgba(15, 26, 20, .96);
  box-shadow: 0 1px 0 var(--line-dark);
}
.head-inner {
  display: flex; align-items: center; gap: var(--s-6);
  height: 76px;
}
.brand { display: flex; align-items: center; gap: var(--s-3); text-decoration: none; margin-right: auto; }
.brand img { width: 40px; height: 40px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text b {
  font-size: 20px; font-weight: 800; letter-spacing: .01em;
  font-variation-settings: "wdth" 88; color: var(--paper);
}
.brand-text i {
  font-style: normal; font-size: 9.5px; font-weight: 600;
  letter-spacing: .2em; text-transform: uppercase; color: var(--green-bright);
}

.nav { display: none; gap: var(--s-6); }
.nav a {
  text-decoration: none; font-size: 15px; font-weight: 500;
  color: rgba(247,245,239,.82); position: relative; padding-block: var(--s-1);
}
.nav a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: -2px; height: 1.5px;
  background: var(--green-bright); transition: right .25s var(--ease);
}
.nav a:hover { color: var(--paper); }
.nav a:hover::after { right: 0; }

.head-cta { display: none; }

.burger {
  width: 44px; height: 44px; display: grid; place-content: center; gap: 6px;
  background: none; border: 0; cursor: pointer; padding: 0;
}
.burger span { display: block; width: 24px; height: 2px; background: var(--paper); transition: transform .25s var(--ease), opacity .2s; }
.burger[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.burger[aria-expanded="true"] span:last-child  { transform: translateY(-4px) rotate(-45deg); }

@media (min-width: 940px) {
  .nav { display: flex; }
  .head-cta { display: inline-flex; }
  .burger { display: none; }
}

/* Menú móvil desplegado */
@media (max-width: 939px) {
  .nav {
    position: fixed; inset: 76px 0 auto 0;
    display: flex; flex-direction: column; gap: 0;
    background: rgba(15, 26, 20, .98);
    backdrop-filter: blur(10px);
    padding: var(--s-4) var(--gutter) var(--s-6);
    transform: translateY(-8px);
    opacity: 0; visibility: hidden;
    transition: opacity .22s var(--ease), transform .22s var(--ease), visibility .22s;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav a { font-size: 24px; font-weight: 700; padding-block: var(--s-3); border-bottom: 1px solid var(--line-dark); }
  .nav a::after { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  background: var(--ink);
  color: var(--paper);
  overflow: hidden;
}
.hero-media { position: absolute; inset: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background:
    /* oscurece el lado del texto sin tapar la foto */
    linear-gradient(to right, rgba(15,26,20,.62) 0%, rgba(15,26,20,.30) 46%, rgba(15,26,20,0) 78%),
    /* legibilidad de la cabecera arriba y del bloque de texto abajo */
    linear-gradient(to bottom, rgba(15,26,20,.78) 0%, rgba(15,26,20,.34) 20%, rgba(15,26,20,.30) 44%, rgba(15,26,20,.82) 80%, rgba(15,26,20,.97) 100%);
}
.hero-inner { position: relative; z-index: 1; padding-block: var(--s-9) var(--s-8); }
.hero-inner .eyebrow { margin-bottom: var(--s-5); }
.display { margin-bottom: var(--s-5); }
@media (min-width: 700px) { .display { max-width: 15ch; } }
.hero-inner .lede { margin-bottom: var(--s-7); }
.hero-cta { display: flex; flex-wrap: wrap; gap: var(--s-3); }

.hero-strip { position: relative; z-index: 1; border-top: 1px solid var(--line-dark); }
.strip-grid {
  display: grid; grid-template-columns: repeat(2, 1fr);
  padding-block: 0;
}
.strip-grid > div {
  display: flex; flex-direction: column; gap: var(--s-1);
  padding: var(--s-5) var(--s-4) var(--s-5) 0;
}
.strip-grid > div + div { border-left: 1px solid var(--line-dark); padding-left: var(--s-4); }
.strip-grid b {
  font-size: 30px; font-weight: 800; line-height: 1;
  font-variation-settings: "wdth" 90; color: var(--green-bright);
}
.strip-grid span { font-size: 13px; color: var(--muted-light); line-height: 1.35; }

@media (min-width: 720px) {
  .strip-grid { grid-template-columns: repeat(4, 1fr); }
  .strip-grid b { font-size: 38px; }
  .strip-grid > div { padding-block: var(--s-6); }
}

/* ---------- Secciones genéricas ---------- */
.section { padding-block: var(--s-9); }
@media (min-width: 900px) { .section { padding-block: var(--s-10); } }

.sec-head { max-width: 60ch; margin-bottom: var(--s-8); }
.sec-head h2 { margin-bottom: var(--s-5); }

/* ---------- Líneas de producto ---------- */
.cards {
  display: grid; gap: 1px;
  background: var(--line);
  border-block: 1px solid var(--line);
}
.card {
  background: var(--paper);
  padding: var(--s-6) var(--s-5) var(--s-7);
  display: flex; flex-direction: column; gap: var(--s-3);
  transition: background .25s var(--ease);
}
.card:hover { background: var(--bone); }
.card .num {
  font-size: 13px; font-weight: 700; letter-spacing: .12em;
  color: var(--green-deep); margin-bottom: var(--s-2);
}
.card p { color: var(--muted); font-size: 16px; }
.card .link { margin-top: auto; padding-top: var(--s-4); }

.link {
  display: inline-flex; align-items: center; gap: var(--s-2);
  text-decoration: none; font-size: 14.5px; font-weight: 600;
  color: var(--green-deep);
}
.link svg {
  width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform .22s var(--ease);
}
.link:hover svg { transform: translateX(4px); }

@media (min-width: 640px)  { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .cards { grid-template-columns: repeat(4, 1fr); } .card { padding: var(--s-7) var(--s-5) var(--s-8); } }

/* ---------- Marcas ---------- */
.marcas { background: var(--ink); color: var(--paper); padding-block: var(--s-8); overflow: hidden; }
.marcas-head { margin-bottom: var(--s-6); }
.marcas-head .eyebrow { margin-bottom: 0; }
/* Los bordes se desvanecen con dos capas sobre el fondo sólido en vez de
   mask-image: enmascarar un elemento que se anima repinta en cada frame. */
.marquee { position: relative; }
.marquee::before, .marquee::after {
  content: ""; position: absolute; top: 0; bottom: 0; width: 12%; z-index: 1; pointer-events: none;
}
.marquee::before { left: 0;  background: linear-gradient(90deg, var(--ink), rgba(15,26,20,0)); }
.marquee::after  { right: 0; background: linear-gradient(270deg, var(--ink), rgba(15,26,20,0)); }
.marquee-track {
  display: flex; width: max-content;
  will-change: transform;
  animation: slide 34s linear infinite;
}
.marquee:hover .marquee-track,
.marquee-track.is-paused { animation-play-state: paused; }
.marquee-track span {
  font-size: clamp(30px, 5vw, 58px);
  font-weight: 700; font-variation-settings: "wdth" 86;
  letter-spacing: -0.02em;
  color: rgba(247,245,239,.55);
  padding-inline: var(--s-6);
  white-space: nowrap;
  transition: color .25s var(--ease);
}
.marquee-track span:hover { color: var(--green-bright); }
@keyframes slide { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  /* Sin movimiento la lista se acomoda en filas; las copias que solo existen
     para que el bucle no tenga costura se ocultan. */
  .marquee-track { animation: none; flex-wrap: wrap; width: 100%; justify-content: center; }
  .marquee-track span[aria-hidden="true"] { display: none; }
  .marquee::before, .marquee::after { display: none; }
}

/* ---------- Cultivos ---------- */
.cultivos { background: var(--bone); }
.cultivos-grid { display: grid; gap: var(--s-7); }
.cultivos .sec-head { margin-bottom: 0; }

.crops { border-top: 1px solid var(--line); }
.crops li { border-bottom: 1px solid var(--line); }
.crops a {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: var(--s-4);
  padding: var(--s-4) var(--s-2) var(--s-4) 0;
  text-decoration: none;
  transition: padding-left .28s var(--ease), color .28s var(--ease);
}
.crops a:hover { padding-left: var(--s-4); color: var(--green-deep); }
.c-n { font-size: 12px; font-weight: 700; letter-spacing: .1em; color: var(--muted); }
.c-t {
  font-size: clamp(22px, 3.1vw, 34px); font-weight: 700;
  font-variation-settings: "wdth" 94; letter-spacing: -0.028em;
}
.c-a { font-size: 20px; color: var(--muted); opacity: 0; transform: translateX(-6px); transition: opacity .25s var(--ease), transform .25s var(--ease); }
.crops a:hover .c-a { opacity: 1; transform: none; color: var(--green-deep); }

@media (min-width: 1000px) {
  .cultivos-grid { grid-template-columns: 5fr 6fr; gap: var(--s-9); align-items: start; }
}

/* ---------- Enfoque ---------- */
.enfoque { padding-block: var(--s-9); }
@media (min-width: 900px) { .enfoque { padding-block: var(--s-10); } }
.enfoque-inner { display: grid; gap: var(--s-8); align-items: center; }
.enfoque-media { margin: 0; }
.enfoque-media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); }
.enfoque-text h2 { margin-bottom: var(--s-7); }

.steps { counter-reset: step; margin-bottom: var(--s-7); }
.steps li {
  counter-increment: step;
  padding: var(--s-5) 0 var(--s-5) var(--s-7);
  border-top: 1px solid var(--line);
  position: relative;
}
.steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute; left: 0; top: var(--s-5);
  font-size: 13px; font-weight: 700; letter-spacing: .1em; color: var(--green-deep);
}
.steps h3 { margin-bottom: var(--s-2); }
.steps p { color: var(--muted); font-size: 16px; }

@media (min-width: 980px) {
  .enfoque-inner { grid-template-columns: 1fr 1fr; gap: var(--s-9); }
}

/* ---------- Nosotros ---------- */
.nosotros { background: var(--ink); color: var(--paper); }
.nosotros .eyebrow { color: var(--green-bright); }
.nosotros .sec-head { margin-bottom: var(--s-8); }

.mv { display: grid; gap: var(--s-6); margin-bottom: var(--s-9); }
.mv article { border-top: 2px solid var(--green); padding-top: var(--s-5); }
.mv-text { font-size: clamp(19px, 2.1vw, 26px); line-height: 1.42; letter-spacing: -0.015em; }

.valores > .eyebrow { margin-bottom: var(--s-6); }
.valores ul { display: grid; gap: 1px; background: var(--line-dark); border-block: 1px solid var(--line-dark); }
.valores li { background: var(--ink); padding: var(--s-5) var(--s-4) var(--s-6) 0; }
.valores h3 { margin-bottom: var(--s-2); font-size: 18px; }
.valores p { color: var(--muted-light); font-size: 15px; }

@media (min-width: 800px) {
  .mv { grid-template-columns: 1fr 1fr; gap: var(--s-8); }
  .valores ul { grid-template-columns: repeat(3, 1fr); }
  .valores li { padding: var(--s-6) var(--s-5) var(--s-7); }
}
@media (min-width: 1100px) { .valores ul { grid-template-columns: repeat(5, 1fr); } }

/* ---------- Contacto ---------- */
.contacto { position: relative; background: var(--ink); color: var(--paper); overflow: hidden; }
.contacto-media { position: absolute; inset: 0; }
.contacto-media img { width: 100%; height: 100%; object-fit: cover; }
.contacto::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to right, rgba(15,26,20,.96) 0%, rgba(15,26,20,.88) 46%, rgba(15,26,20,.55) 100%);
}
.contacto-inner {
  position: relative; z-index: 1;
  display: grid; gap: var(--s-8);
  padding-block: var(--s-9);
}
.contacto-text h2 { margin-bottom: var(--s-5); }

.contact-list { margin-top: var(--s-7); display: grid; gap: var(--s-4); }
.contact-list li { display: flex; flex-direction: column; gap: var(--s-1); padding-top: var(--s-4); border-top: 1px solid var(--line-dark); }
.contact-list span { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted-light); }
.contact-list a {
  font-size: 19px; font-weight: 600; text-decoration: none;
  color: var(--paper); width: fit-content;
  border-bottom: 1.5px solid transparent; transition: border-color .2s var(--ease), color .2s var(--ease);
}
.contact-list a:hover { color: var(--green-bright); border-bottom-color: var(--green-bright); }
.contact-list li:last-child { flex-direction: row; flex-wrap: wrap; gap: var(--s-5); align-items: baseline; }
.contact-list li:last-child span { flex-basis: 100%; }

/* Formulario */
.quote {
  background: var(--paper); color: var(--ink);
  padding: var(--s-6) var(--s-5) var(--s-7);
  border-radius: var(--radius);
  display: grid; gap: var(--s-4);
  align-content: start;
}
.field { display: grid; gap: var(--s-2); }
.field-row { display: grid; gap: var(--s-4); }
.field label { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.field input, .field select, .field textarea {
  font: inherit; font-size: 16px; color: var(--ink);
  background: var(--bone);
  border: 0; border-bottom: 1.5px solid var(--line);
  border-radius: var(--radius) var(--radius) 0 0;
  padding: var(--s-3) var(--s-3);
  width: 100%;
  transition: border-color .2s var(--ease), background .2s var(--ease);
}
.field textarea { resize: vertical; min-height: 108px; line-height: 1.5; }
.field input::placeholder, .field textarea::placeholder { color: #8A938C; }
.field input:focus, .field select:focus, .field textarea:focus { border-bottom-color: var(--green); background: #fff; }
.field select { appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' fill='none' stroke='%2356615A' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right var(--s-3) center; background-size: 12px;
  padding-right: var(--s-6);
}
.field.has-error input, .field.has-error textarea { border-bottom-color: #B3402F; }
.quote .btn { margin-top: var(--s-2); }
.form-note { font-size: 14px; color: var(--muted); min-height: 1.4em; }
.form-note.is-error { color: #8E2F21; font-weight: 600; }

@media (min-width: 560px) { .field-row { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) {
  .contacto-inner { grid-template-columns: 1fr 1fr; gap: var(--s-9); padding-block: var(--s-10); align-items: center; }
  .quote { padding: var(--s-7) var(--s-6) var(--s-8); }
}

/* ---------- Pie ---------- */
.site-foot { background: var(--ink); color: var(--paper); border-top: 1px solid var(--line-dark); padding-top: var(--s-8); }
.foot-inner { display: grid; gap: var(--s-8); padding-bottom: var(--s-8); }
.foot-brand { display: grid; gap: var(--s-4); }
.foot-brand img { width: 48px; height: 48px; }
.foot-brand p {
  font-size: 22px; font-weight: 700; line-height: 1.2;
  font-variation-settings: "wdth" 92; letter-spacing: -0.02em;
  color: var(--paper);
}
.foot-cols { display: grid; gap: var(--s-6); }
.foot-cols > div { display: grid; gap: var(--s-2); align-content: start; }
.foot-cols .eyebrow { margin-bottom: var(--s-2); }
.foot-cols a { font-size: 15px; color: var(--muted-light); text-decoration: none; width: fit-content; transition: color .18s var(--ease); }
.foot-cols a:hover { color: var(--paper); }

.foot-legal {
  display: flex; flex-wrap: wrap; gap: var(--s-3) var(--s-6);
  justify-content: space-between;
  padding-block: var(--s-5);
  border-top: 1px solid var(--line-dark);
  font-size: 13.5px; color: var(--muted-light);
}

@media (min-width: 720px) { .foot-cols { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 980px) { .foot-inner { grid-template-columns: 1fr 2fr; gap: var(--s-9); } }

/* ---------- Botón flotante de WhatsApp ---------- */
.wa-float {
  position: fixed; right: var(--s-4); bottom: var(--s-4); z-index: 45;
  display: inline-flex; align-items: center; gap: var(--s-2);
  background: var(--green); color: #fff;
  padding: var(--s-3) var(--s-4);
  border-radius: 999px; text-decoration: none;
  font-size: 15px; font-weight: 600;
  box-shadow: 0 6px 24px rgba(15, 26, 20, .28);
  transition: background .2s var(--ease), transform .2s var(--ease);
}
.wa-float:hover { background: var(--green-press); transform: translateY(-2px); }
.wa-float svg { width: 22px; height: 22px; fill: currentColor; }
@media (max-width: 520px) { .wa-float span { display: none; } .wa-float { padding: var(--s-3); } }

/* ---------- Aparición al hacer scroll ----------
   El estado oculto SOLO existe si `has-js` está en <html>. El script del
   <head> lo quita si main.js no llegó a arrancar, así que ningún contenido
   depende de que una transición corra para poder verse. */
.has-js .reveal { opacity: 0; transform: translateY(18px); }
.has-js .reveal.is-in {
  opacity: 1; transform: none;
  transition: opacity .6s var(--ease), transform .6s var(--ease);
}
@media (prefers-reduced-motion: reduce) {
  .has-js .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .link svg, .crops a, .c-a { transition: none; }
}
