/* Importação de Fontes */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&family=Open+Sans:wght@400;700&display=swap');

/* Variáveis CSS para Cores */
:root {
    --color-primary: #28a745; /* Verde Agribussiness */
    --color-secondary: #007bff; /* Azul para detalhes */
    --color-dark: #343a40; /* Texto e fundo escuro */
    --color-light: #f8f9fa; /* Fundo claro */
    --color-white: #ffffff;
    --color-text: #495057; /* Cor padrão do texto */
}

/* Reset Básico */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Open Sans', sans-serif;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-light);
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px;
}

h1, h2, h3 {
    font-family: 'Montserrat', sans-serif;
    color: var(--color-dark);
    margin-bottom: 20px;
}

h1 {
    font-size: 2.8em;
    color: var(--color-white);
}

h2 {
    font-size: 2.2em;
    text-align: center;
    margin-bottom: 40px;
}

h3 {
    font-size: 1.5em;
    margin-top: 15px;
}

p {
    margin-bottom: 15px;
}

a {
    text-decoration: none;
    color: var(--color-primary);
}

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

/* Botões */
.btn-primary, .btn-secondary {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 5px;
    font-weight: 600;
    transition: background-color 0.3s ease;
    text-align: center;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-white);
    border: 2px solid var(--color-primary);
}

.btn-primary:hover {
    background-color: #218838; /* Um pouco mais escuro */
    border-color: #218838;
}

.btn-secondary {
    background-color: var(--color-white);
    color: var(--color-primary);
    border: 2px solid var(--color-primary);
}

.btn-secondary:hover {
    background-color: var(--color-primary);
    color: var(--color-white);
}

/* Hero Section */
.hero-section {
    /*background: url('https://via.placeholder.com/1500x800?text=Fundo+Agronegocio') no-repeat center center/cover;*/
    background: url(../assets/header.png) no-repeat center center/cover;
    color: var(--color-white);
    text-align: center;
    padding: 100px 0;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative; /* Para o overlay */
}

.hero-section::before { /* Overlay escuro para melhor leitura do texto */
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* 50% de opacidade */
    z-index: 0;
}

.hero-section .container {
    position: relative; /* Coloca o conteúdo acima do overlay */
    z-index: 1;
}

.hero-section p {
    font-size: 1.2em;
    margin-bottom: 30px;
}

/* Logo posicionado no canto superior esquerdo */
.logo-container {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 2;
}

.hero-section .logo {
    max-width: 200px;
    /*filter: brightness(0) invert(1); /* Deixa o placeholder branco para destacar */
}

/* Seções de Conteúdo (Notícias, Tutoriais, Quem Somos) */
.noticias-section, .tutoriais-section, .quem-somos-section, .newsletter-section, .como-funciona-section {
    padding: 60px 0;
    text-align: center;
}

.noticias-section, .tutoriais-section {
    background-color: var(--color-light);
    border-bottom: 1px solid #e0e0e0;
}

.como-funciona-section {
    background-color: var(--color-white);
    border-bottom: 1px solid #e0e0e0;
}

.quem-somos-section {
    background-color: var(--color-white);
    border-bottom: 1px solid #e0e0e0;
}

.newsletter-section {
    background-color: var(--color-dark);
    color: var(--color-white);
}

.newsletter-section h2, .newsletter-section p {
    color: var(--color-white);
}

/* Estilo para a imagem da jornada */
.jornada-imagem {
    margin-top: 40px;
    display: flex;
    justify-content: center;
}

.jornada-img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}


.cards-container {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    margin-bottom: 40px;
}

.card {
    background-color: var(--color-white);
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    width: calc(33.333% - 20px); /* 3 colunas, considerando o gap */
    flex-grow: 1;
    min-width: 280px; /* Garante que não fique muito pequeno em telas menores */
    max-width: auto; /* Limita o tamanho máximo */
    text-align: left;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.card img {
    width: 100%;
    max-width: 100%;
    height: auto;
    min-height: 150px;
    max-height: 300px;
    object-fit: cover;
    object-position: center;
    border-radius: 8px 8px 0 0;
}

.card h3, .card p {
    padding: 0 20px;
}

.card h3 {
    margin-top: 20px;
}

.card p {
    font-size: 0.95em;
    color: var(--color-text);
    flex-grow: 1; /* Faz o parágrafo ocupar o espaço restante */
}

.card .btn-secondary {
    margin: 20px;
    align-self: flex-start; /* Alinha o botão à esquerda dentro do card */
}

/* Newsletter Form */
.newsletter-form {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-top: 30px;
}

.newsletter-form input {
    padding: 12px 15px;
    border: 1px solid #ced4da;
    border-radius: 5px;
    width: 100%;
    max-width: 300px;
    font-size: 1em;
}

.newsletter-form button {
    padding: 12px 25px;
    border-radius: 5px;
    border: none;
    background-color: var(--color-primary);
    color: var(--color-white);
    font-size: 1em;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.newsletter-form button:hover {
    background-color: #218838;
}

/* Social Links */
.social-links {
    margin-top: 30px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.social-links img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: var(--color-white); /* Para dar um fundo aos ícones placeholder */
}


/* Footer */
footer {
    background-color: var(--color-dark);
    color: var(--color-white);
    text-align: center;
    padding: 30px 0;
    font-size: 0.9em;
}

footer a {
    color: var(--color-primary);
    margin: 0 10px;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--color-white);
}

/* Responsividade */
@media (max-width: 768px) {
    h1 {
        font-size: 2em;
    }

    h2 {
        font-size: 1.8em;
    }

    .hero-section {
        padding: 80px 0;
    }

    .card {
        width: calc(50% - 15px); /* 2 colunas em tablets */
        max-width: 350px;
    }

    .card img {
        min-height: 120px;
        max-height: 200px;
    }

    /* Logo menor em tablets */
    .hero-section .logo {
        max-width: 120px;
    }

    /* Responsividade para imagem da jornada */
    .jornada-img {
        max-width: 90%;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.8em;
    }

    h2 {
        font-size: 1.5em;
    }

    .hero-section p {
        font-size: 1em;
    }

    .card {
        width: 100%; /* 1 coluna em celulares */
        max-width: 100%;
    }

    .card img {
        min-height: 150px;
        max-height: 200px;
    }

    /* Logo ainda menor em celulares */
    .logo-container {
        top: 15px;
        left: 15px;
    }

    .hero-section .logo {
        max-width: 100px;
    }

    /* Responsividade para imagem da jornada em mobile */
    .jornada-img {
        max-width: 95%;
        margin: 0 auto;
    }

    .newsletter-form input,
    .newsletter-form button {
        max-width: 100%; /* Ocupa a largura total */
    }
}