/* ==========================================================================
   SERVICIOS AGRÍCOLAS JULIO — Hoja de estilos
   Diseño mobile-first, tipografía grande y alto contraste
   Colores corporativos tomados del logo:
     azul celeste #2883ff  ·  amarillo #ffb200  ·  azul oscuro #0b2545
   ========================================================================== */

/* --------------------------------------------------------------------------
   0. TIPOGRAFÍA PROPIA — Barlow
   Los archivos están en la carpeta /fuentes y se sirven desde tu propio
   dominio: no se pide nada a Google, así que carga más rápido y no hay
   problemas de RGPD. Solo el juego latino (español): 47 KB en total.
   -------------------------------------------------------------------------- */
@font-face {
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fuentes/barlow-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('fuentes/barlow-700.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('fuentes/barlow-800.woff2') format('woff2');
}

/* --------------------------------------------------------------------------
   1. VARIABLES DE COLOR Y TIPOGRAFÍA
   -------------------------------------------------------------------------- */
:root {
  --azul-oscuro:      #0b2545;   /* fondos y textos principales */
  --azul-oscuro-2:    #113a6b;   /* variante para degradados */
  --azul-celeste:     #2883ff;   /* color del logo, acento */
  --azul-celeste-cl:  #e8f2ff;   /* fondos suaves */
  --amarillo:         #ffb200;   /* botón principal (CTA) */
  --amarillo-oscuro:  #e09a00;   /* hover del botón amarillo */
  --verde-whatsapp:   #25d366;
  --verde-whatsapp-2: #1da851;

  --texto:            #1a1a1a;
  --texto-suave:      #454f5b;
  --blanco:           #ffffff;
  --gris-fondo:       #f4f6f9;
  --borde:            #d7dee8;

  --radio:            14px;
  --sombra:           0 4px 16px rgba(11, 37, 69, .12);
  --sombra-fuerte:    0 8px 28px rgba(11, 37, 69, .22);

  /* Barlow, con la fuente del sistema de reserva por si no cargara */
  --fuente: 'Barlow', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
            "Helvetica Neue", Arial, "Noto Sans", sans-serif;

  --ancho-max: 1180px;
}

/* --------------------------------------------------------------------------
   2. BASE
   -------------------------------------------------------------------------- */
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  font-family: var(--fuente);
  font-size: 1.15rem;          /* ≈18,5px en móvil: texto grande y legible */
  line-height: 1.65;
  color: var(--texto);
  background: var(--blanco);
  /* Espacio para la barra fija de contacto en móvil */
  padding-bottom: 84px;
}

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

a { color: var(--azul-celeste); }

h1, h2, h3 {
  line-height: 1.2;
  color: var(--azul-oscuro);
  margin: 0 0 .5em;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.1rem, 7vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.9rem, 5.5vw, 2.7rem); font-weight: 800; }
h3 { font-size: clamp(1.35rem, 4vw, 1.6rem); font-weight: 700; }

p { margin: 0 0 1em; }

.contenedor {
  width: 100%;
  max-width: var(--ancho-max);
  margin: 0 auto;
  padding: 0 20px;
}

section { padding: 60px 0; }

/* Compensa el header fijo al saltar por anclas */
section[id] { scroll-margin-top: 160px; }
@media (min-width: 900px) { section[id] { scroll-margin-top: 110px; } }

.seccion-clara  { background: var(--gris-fondo); }
.seccion-oscura { background: var(--azul-oscuro); color: var(--blanco); }
.seccion-oscura h2, .seccion-oscura h3 { color: var(--blanco); }

.titulo-seccion { text-align: center; margin-bottom: 12px; }

.subtitulo-seccion {
  text-align: center;
  font-size: 1.2rem;
  color: var(--texto-suave);
  max-width: 700px;
  margin: 0 auto 40px;
}
.seccion-oscura .subtitulo-seccion { color: #c9d8ec; }

/* Línea decorativa bajo los títulos */
.titulo-seccion::after {
  content: "";
  display: block;
  width: 90px;
  height: 6px;
  background: var(--amarillo);
  border-radius: 3px;
  margin: 18px auto 0;
}

/* Accesibilidad: foco siempre visible */
a:focus-visible,
button:focus-visible {
  outline: 4px solid var(--amarillo);
  outline-offset: 3px;
}

/* --------------------------------------------------------------------------
   3. BOTONES  (grandes, fáciles de pulsar)
   -------------------------------------------------------------------------- */
.boton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 64px;
  padding: 14px 30px;
  font-family: inherit;
  font-size: 1.25rem;
  font-weight: 800;
  text-decoration: none;
  border: none;
  border-radius: var(--radio);
  cursor: pointer;
  box-shadow: var(--sombra);
  transition: transform .15s ease, background-color .15s ease;
}
.boton:hover { transform: translateY(-2px); }
.boton:active { transform: translateY(0); }
.boton svg { width: 28px; height: 28px; flex-shrink: 0; }

.boton-principal   { background: var(--amarillo); color: var(--azul-oscuro); }
.boton-principal:hover { background: var(--amarillo-oscuro); }

.boton-whatsapp    { background: var(--verde-whatsapp); color: #fff; }
.boton-whatsapp:hover { background: var(--verde-whatsapp-2); }

.boton-ancho { width: 100%; max-width: 420px; }

.grupo-botones {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

/* --------------------------------------------------------------------------
   4. CABECERA / NAVEGACIÓN
   -------------------------------------------------------------------------- */
.cabecera {
  /* En móvil la cabecera NO se queda fija (ocuparía demasiada pantalla):
     abajo hay una barra fija con los botones de Llamar y WhatsApp.
     A partir de 900px sí queda fija arriba. */
  position: static;
  top: 0;
  z-index: 100;
  background: var(--blanco);
  border-bottom: 3px solid var(--azul-celeste);
  box-shadow: 0 2px 10px rgba(11, 37, 69, .08);
}

.cabecera-interior {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 10px 0 0;
}

/* LOGO: se usa el archivo logo_julio_transparente.svg de la raíz */
.logo img { height: 54px; width: auto; }
@media (max-width: 400px) { .logo img { height: 46px; } }

.menu {
  display: flex;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0 0 6px;
  flex-wrap: wrap;
  justify-content: center;
}
.menu a {
  display: block;
  padding: 9px 11px;
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--azul-oscuro);
  text-decoration: none;
  border-radius: 10px;
}
@media (min-width: 900px) {
  .logo img { height: 66px; }
  .menu a { padding: 12px 16px; font-size: 1.1rem; }
}
.menu a:hover { background: var(--azul-celeste-cl); color: var(--azul-oscuro); }

/* El botón "Llamar ahora" de la cabecera se oculta en móvil
   porque abajo hay una barra fija de contacto siempre visible */
.cabecera .boton { display: none; min-height: 56px; font-size: 1.1rem; padding: 10px 22px; }

@media (min-width: 900px) {
  .cabecera { position: sticky; }
  .cabecera .boton { display: inline-flex; }
  .menu { padding: 0; justify-content: flex-end; }
  .cabecera-interior {
    flex-direction: row;
    justify-content: space-between;
    gap: 24px;
    padding: 12px 0;
  }
}

/* --------------------------------------------------------------------------
   5. PORTADA (HERO)
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  color: var(--blanco);
  padding: 70px 0 80px;
  text-align: center;

  /* IMAGEN DE PORTADA → imagenes/hero-recoleccion.jpg
     (foto aérea del tractor con el paraguas vibrador en el almendro).
     La capa azul oscuro garantiza que el texto se lea siempre. */
  background-color: var(--azul-oscuro);
  background-image:
    /* Degradado: oscuro arriba y abajo (donde el texto necesita contraste)
       y más claro en el centro, para que se vea la foto del trabajo. */
    linear-gradient(180deg,
      rgba(11, 37, 69, .88) 0%,
      rgba(11, 37, 69, .58) 30%,
      rgba(11, 37, 69, .58) 62%,
      rgba(11, 37, 69, .90) 100%),
    url("imagenes/hero-recoleccion.jpg");
  background-size: cover;
  background-position: center;
}

/* Sombras algo más marcadas: ahora el texto va sobre la foto, no sobre
   un fondo liso, y tiene que leerse igual de bien. */
.hero h1 {
  color: var(--blanco);
  text-shadow: 0 2px 6px rgba(0, 0, 0, .55), 0 4px 24px rgba(11, 37, 69, .8);
}

.hero-destacado { color: var(--amarillo); }

.hero-lema {
  font-size: clamp(1.3rem, 4.5vw, 1.75rem);
  font-weight: 700;
  color: #ffffff;
  max-width: 720px;
  margin: 0 auto 14px;
  text-shadow: 0 2px 6px rgba(0, 0, 0, .6), 0 3px 18px rgba(11, 37, 69, .8);
}

.hero-texto {
  font-size: 1.2rem;
  color: #eaf1fa;
  max-width: 640px;
  margin: 0 auto 34px;
  text-shadow: 0 1px 5px rgba(0, 0, 0, .7), 0 2px 14px rgba(11, 37, 69, .85);
}

.hero .grupo-botones { margin-bottom: 26px; }

.hero-telefono {
  font-size: 1.25rem;
  color: #ffffff;
  text-shadow: 0 1px 5px rgba(0, 0, 0, .7), 0 2px 14px rgba(11, 37, 69, .85);
}
.hero-telefono strong { color: var(--amarillo); font-size: 1.4rem; white-space: nowrap; }

/* Franja de confianza bajo la portada */
.franja {
  background: var(--azul-celeste);
  color: var(--blanco);
  padding: 18px 0;
  font-size: 1.1rem;
  font-weight: 700;
}
.franja ul {
  list-style: none;
  margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: 10px 34px;
  justify-content: center; text-align: center;
}
.franja li { display: flex; align-items: center; gap: 10px; }
.franja svg { width: 26px; height: 26px; flex-shrink: 0; }

/* --------------------------------------------------------------------------
   6. SERVICIOS
   -------------------------------------------------------------------------- */
.rejilla-servicios {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 700px)  { .rejilla-servicios { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1050px) { .rejilla-servicios { grid-template-columns: repeat(4, 1fr); } }

.tarjeta {
  background: var(--blanco);
  border: 2px solid var(--borde);
  border-top: 8px solid var(--azul-celeste);
  border-radius: var(--radio);
  padding: 28px 24px 30px;
  box-shadow: var(--sombra);
}
.tarjeta:nth-child(2n) { border-top-color: var(--amarillo); }

.icono {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 74px; height: 74px;
  border-radius: 50%;
  background: var(--azul-celeste-cl);
  margin-bottom: 18px;
}
.icono svg { width: 40px; height: 40px; stroke: var(--azul-oscuro); }
.tarjeta:nth-child(2n) .icono { background: #fff3d6; }

.tarjeta p { color: var(--texto-suave); margin-bottom: 0; }

.aviso-servicios {
  margin-top: 36px;
  text-align: center;
  font-size: 1.2rem;
  background: var(--azul-celeste-cl);
  border: 2px dashed var(--azul-celeste);
  border-radius: var(--radio);
  padding: 24px 20px;
}
.aviso-servicios p { margin-bottom: 20px; }

/* --------------------------------------------------------------------------
   7. POR QUÉ ELEGIRNOS
   -------------------------------------------------------------------------- */
.rejilla-ventajas {
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  margin-bottom: 44px;
}
@media (min-width: 800px) { .rejilla-ventajas { grid-template-columns: repeat(3, 1fr); } }

.ventaja {
  background: rgba(255, 255, 255, .07);
  border: 2px solid rgba(255, 255, 255, .22);
  border-radius: var(--radio);
  padding: 30px 26px;
  text-align: center;
}
.ventaja .icono { background: var(--amarillo); margin: 0 auto 20px; }
.ventaja .icono svg { stroke: var(--azul-oscuro); }
.ventaja p { color: #d7e4f5; margin-bottom: 0; font-size: 1.15rem; }

.dato-experiencia {
  display: block;
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--amarillo);
  line-height: 1.1;
}

/* --------------------------------------------------------------------------
   8. VÍDEOS Y GALERÍA
   -------------------------------------------------------------------------- */
/* --- Bandas con vídeo de fondo y texto encima --------------------------- */
.banda {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 480px;
  overflow: hidden;
  background: var(--azul-oscuro);   /* color de respaldo si falta el vídeo */
  border-top: 4px solid var(--azul-celeste);
}
@media (min-width: 900px) { .banda { min-height: 560px; } }

.banda-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;   /* el vídeo llena la banda, se recorta lo que sobra */
  z-index: 0;
}

/* Capa oscura: sin ella el texto blanco no se leería sobre el vídeo */
.banda::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    100deg,
    rgba(11, 37, 69, .93) 0%,
    rgba(11, 37, 69, .82) 55%,
    rgba(11, 37, 69, .68) 100%);
}

.banda-contenido {
  position: relative;
  z-index: 2;
  color: var(--blanco);
  padding: 64px 20px;
  max-width: 860px;
  text-align: center;
}
.banda-contenido h3 {
  color: var(--blanco);
  font-size: clamp(1.6rem, 5.5vw, 2.4rem);
  text-shadow: 0 2px 12px rgba(0, 0, 0, .5);
  margin-bottom: .5em;
}
.banda-contenido > p {
  font-size: 1.2rem;
  color: #e4edf9;
  margin-bottom: 28px;
  text-shadow: 0 1px 8px rgba(0, 0, 0, .55);
}

/* Selector con dos clases para que gane a la regla de arriba */
.banda-contenido .banda-etiqueta {
  display: inline-block;
  background: var(--amarillo);
  color: var(--azul-oscuro);
  font-size: 1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 8px 18px;
  border-radius: 999px;
  margin-bottom: 18px;
  text-shadow: none;
}

/* --- Carrusel de fotos: se desliza en horizontal ------------------------ */
.carrusel { position: relative; }

.carrusel-pista {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  overflow-y: hidden;
  /* El dedo "engancha" cada foto al deslizar */
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding: 6px 20px 22px;
  scrollbar-color: var(--azul-celeste) var(--borde);
}
/* Barra de desplazamiento visible y gruesa: ayuda a entender que hay más fotos */
.carrusel-pista::-webkit-scrollbar { height: 12px; }
.carrusel-pista::-webkit-scrollbar-track { background: var(--borde); border-radius: 6px; }
.carrusel-pista::-webkit-scrollbar-thumb { background: var(--azul-celeste); border-radius: 6px; }

.carrusel-pista figure {
  margin: 0;
  flex: 0 0 auto;
  width: min(86vw, 460px);
  scroll-snap-align: center;
  border-radius: var(--radio);
  overflow: hidden;
  box-shadow: var(--sombra);
  background: var(--azul-oscuro);   /* color de respaldo si falta la foto */
}
.carrusel-pista img {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

@media (min-width: 700px) {
  .carrusel-pista { gap: 22px; padding: 6px 32px 26px; }
  .carrusel-pista figure { width: 460px; }
  .carrusel-pista img { height: 360px; }
}
@media (min-width: 1100px) {
  .carrusel-pista figure { width: 540px; }
  .carrusel-pista img { height: 400px; }
}

/* Flechas y aviso */
.carrusel-mandos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 14px;
}
.carrusel-flecha {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 66px;
  height: 66px;
  flex-shrink: 0;
  border: 3px solid var(--azul-oscuro);
  border-radius: 50%;
  background: var(--blanco);
  color: var(--azul-oscuro);
  cursor: pointer;
  box-shadow: var(--sombra);
  transition: background-color .15s ease;
}
.carrusel-flecha:hover { background: var(--amarillo); }
.carrusel-flecha svg { width: 32px; height: 32px; }

.carrusel-aviso {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--texto-suave);
  text-align: center;
}

/* --------------------------------------------------------------------------
   9. CONTACTO
   -------------------------------------------------------------------------- */
.bloque-contacto {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-bottom: 40px;
}
@media (min-width: 800px) { .bloque-contacto { grid-template-columns: repeat(2, 1fr); } }

.dato-contacto {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--blanco);
  border: 2px solid var(--borde);
  border-radius: var(--radio);
  padding: 22px 24px;
  text-decoration: none;
  color: var(--texto);
  box-shadow: var(--sombra);
}
.dato-contacto:hover { border-color: var(--azul-celeste); background: var(--azul-celeste-cl); }
.dato-contacto .icono { width: 62px; height: 62px; margin: 0; flex-shrink: 0; }
.dato-contacto .icono svg { width: 32px; height: 32px; }
.dato-contacto .etiqueta {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--texto-suave);
}
.dato-contacto .valor {
  display: block;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--azul-oscuro);
  word-break: break-word;
}
/* El correo es largo: se muestra algo más pequeño para que no se parta */
.dato-contacto .valor-email { font-size: 1.1rem; }
@media (max-width: 430px) {
  .dato-contacto .valor { font-size: 1.15rem; }
  .dato-contacto .valor-email { font-size: .95rem; }
  .dato-contacto { gap: 14px; padding: 20px 18px; }
  .dato-contacto .icono { width: 54px; height: 54px; }
}

.caja-llamada {
  background: var(--azul-oscuro);
  color: var(--blanco);
  border-radius: var(--radio);
  padding: 40px 24px;
  text-align: center;
  box-shadow: var(--sombra-fuerte);
}
.caja-llamada h3 { color: var(--blanco); font-size: clamp(1.5rem, 5vw, 2rem); }
.caja-llamada p { color: #d7e4f5; font-size: 1.2rem; max-width: 560px; margin: 0 auto 26px; }

.horario {
  margin-top: 24px;
  font-size: 1.1rem;
  color: #c9d8ec;
}

/* Redes sociales */
.redes {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 34px;
}
.redes a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 60px;
  padding: 12px 26px;
  border-radius: var(--radio);
  background: var(--azul-oscuro);
  color: var(--blanco);
  font-size: 1.15rem;
  font-weight: 700;
  text-decoration: none;
}
.redes a:hover { background: var(--azul-celeste); }
.redes svg { width: 30px; height: 30px; fill: currentColor; }

/* --------------------------------------------------------------------------
   10. PIE DE PÁGINA
   -------------------------------------------------------------------------- */
.pie {
  background: var(--azul-oscuro);
  color: #c9d8ec;
  padding: 46px 0 34px;
  text-align: center;
  font-size: 1.05rem;
}
/* El logo está diseñado sobre fondo blanco (el tractor y las letras
   interiores son blancos). Sobre el azul oscuro del pie se verían como
   manchas sueltas, así que se coloca dentro de un círculo blanco. */
.pie img {
  height: 96px;
  width: 96px;
  margin: 0 auto 20px;
  background: var(--blanco);
  border-radius: 50%;
  padding: 6px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
}
.pie strong { color: var(--blanco); font-size: 1.25rem; }
.pie a { color: var(--amarillo); }
.pie .redes a { background: rgba(255,255,255,.1); }
.pie .redes a:hover { background: var(--azul-celeste); }
.copyright {
  margin: 30px 0 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.2);
  font-size: .98rem;
}

/* --------------------------------------------------------------------------
   11. BARRA FIJA DE CONTACTO (SOLO MÓVIL)
   -------------------------------------------------------------------------- */
.barra-movil {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 200;
  display: flex;
  gap: 10px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: var(--blanco);
  border-top: 3px solid var(--azul-oscuro);
  box-shadow: 0 -4px 16px rgba(11, 37, 69, .18);
}
.barra-movil .boton {
  flex: 1;
  min-height: 60px;
  font-size: 1.15rem;
  padding: 10px 8px;
  box-shadow: none;
}
.barra-movil .boton svg { width: 26px; height: 26px; }

@media (min-width: 900px) {
  .barra-movil { display: none; }
  body { padding-bottom: 0; }
  section { padding: 80px 0; }
}
