/* ========= ESTILOS GLOBAIS E VARIÁVEIS ========= */
:root {
    --branco: #FFFFFF;
    --azul-claro: #003bd7;
    --azul-medio: #003bd7;
    --azul-escuro: #1E3A8A;
    --verde-cta: #00dd2f;
    --fundo-cinza-claro: #F8F9FA;
    --gradiente-hero: linear-gradient(135deg, #003bd7, #3D8DFF);
}

/* NOVO: Habilita a rolagem suave para toda a página */
html {
    scroll-behavior: smooth;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: var(--branco);
}

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

h1, h2, h3 {
    line-height: 1.2;
}

section {
    padding: 60px 0;
}


/* ========= HEADER ========= */
.header-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 0;
}
.logo {
    height: 40px;
}


/* ========= HERO ========= */
#hero {
    background: var(--gradiente-hero);
    color: var(--branco);
    padding: 40px 0;
    text-align: left;
}
.hero-content {
    display: flex;
    align-items: center;
    gap: 2rem;
}
.hero-text {
    padding-top: 40px;
    flex: 1;
}
.hero-text h1 {
    color: var(--branco);
    font-size: 2.8rem;
    line-height: 1.2;
}
.hero-text p {
    color: var(--branco);
    font-size: 1.1rem;
    margin: 1rem 0 2rem 0;
}
.cta-button {
    background-color: var(--verde-cta);
    color: var(--branco);
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.2s;
}
.cta-button:hover {
    transform: scale(1.05);
}
.hero-image {
    flex: 1;
}
.hero-image img {
    max-width: 100%;
    height: auto;
}


/* ========= COMO FUNCIONA ========= */
#como-funciona {
    background-color: var(--fundo-cinza-claro);
    padding-top: 120px;
    position: relative;
}
.features-box {
    background-color: var(--branco);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    display: flex;
    gap: 1.5rem;
    padding: 2rem;
    text-align: center;
    position: absolute;
    width: 90%;
    max-width: 900px;
    top: 0;
    left: 50%;
    transform: translate(-50%, -50%);
}
.feature-item {
    flex: 1;
}
.feature-icon {
    margin-bottom: 1rem;
}
.feature-icon svg {
    width: 48px;
    height: 48px;
    margin: 0 auto;
}
.feature-item h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
}
.feature-item p {
    font-size: 0.85rem;
}
.steps-section {
    padding-top: 80px; /* Aumentado para dar espaço ao features-box */
    display: flex;
    flex-direction: column;
    align-items: center;
}
.steps-title {
    text-align: center;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #222;
}
.steps-benefits-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
    max-width: 900px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}
.step-benefit {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(44, 62, 80, 0.06);
    border: 1.5px solid #f0f2f7;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    min-height: 170px;
    transition: box-shadow 0.18s, border-color 0.18s;
    font-size: 16px;
    color: #000;
    text-align: left;
}
.step-benefit:hover {
    box-shadow: 0 6px 24px rgba(44, 62, 80, 0.13);
    border-color: #2563eb;
}
.step-benefit-header {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin-bottom: 0.5rem;
}
.step-benefit-number {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #2563eb;
    color: #fff;
    font-size: 1.5rem;
    font-weight: 700;
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(44, 62, 80, 0.07);
    flex-shrink: 0;
}
.step-benefit-title {
    font-weight: 700;
    color: #2563eb;
    font-size: 1.1rem;
}
.step-benefit-desc {
    color: #444;
    font-size: 0.97rem;
    font-weight: 400;
    margin: 0;
}


/* ========= CONDIÇÕES FACILITADAS ========= */
#condicoes {
    position: relative; 
    background: radial-gradient(circle at top center, var(--azul-claro), var(--azul-medio));
    color: var(--branco);
    padding: 60px 20px;
    text-align: center;
}
#condicoes::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-top: 20px solid var(--fundo-cinza-claro); 
}
#condicoes h2 {
    color: var(--branco);
    font-size: 2.2rem;
    font-weight: 400;
    margin-bottom: 1rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}
#condicoes h2 strong {
    font-weight: 700;
}
#condicoes p {
    color: var(--branco);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}


/* ========= FORMULÁRIO DE SIMULAÇÃO ========= */
#simulacao {
    background-color: #ffffff;
    padding: 20px 0;
}
.simulacao-content {
    display: flex;
    align-items: center;
    gap: 4rem;
}
.simulacao-image {
    flex: 1;
    text-align: center;
}
.simulacao-image img {
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0px 15px 30px rgba(0, 0, 0, 0.15));
}
.simulacao-form-wrapper {
    flex: 1;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 8px 32px rgba(44, 62, 80, 0.10), 0 1.5px 6px rgba(44, 62, 80, 0.06);
    padding: 0;
    transition: box-shadow 0.2s;
    overflow: hidden;
}
.form-group {
    margin-bottom: 1rem;
    display: flex;
    flex-direction: column;
}
.form-group-double {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}
.form-group-double .form-group {
    margin-bottom: 0;
}
.form-group input, textarea {
    width: 100%;
    padding: 1rem;
    border: 1px solid #dcdcdc;
    border-radius: 12px;
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.form-group input:focus, textarea:focus {
    border-color: var(--azul-claro);
    box-shadow: 0 0 0 4px rgba(61, 141, 255, 0.15);
}
.form-group input::placeholder, textarea::placeholder {
    color: #999;
}
.submit-button {
    width: 100%;
    background-color: var(--verde-cta);
    color: var(--branco);
    padding: 1rem;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 58px;
    box-shadow: 0 4px 15px rgba(5, 196, 107, 0.3);
}
.submit-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(5, 196, 107, 0.4);
}
.submit-button:disabled {
    background-color: #aaa;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}


/* ========= FEEDBACK DO FORMULÁRIO (AJAX) ========= */
.form-status {
    text-align: center;
    min-height: 1.2em;
    font-weight: bold;
    margin-top: 1rem;
    transition: color 0.3s;
}
.spinner {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--branco);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
.hidden {
    display: none;
}
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}


/* ========= ABAS E FORMULÁRIOS DINÂMICOS ========= */
.form-toggle {
    display: flex;
    background-color: #e9ecef;
    padding: 5px;
    border-radius: 12px;
    margin: 2rem 2.5rem 1.5rem 2.5rem; 
}
.toggle-button {
    flex: 1;
    padding: 0.8rem;
    border: none;
    background-color: transparent;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    color: #6c757d;
    transition: all 0.3s ease;
}
.toggle-button.active {
    background-color: #ffffff;
    color: var(--azul-medio);
    font-weight: 600;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
.lead-form.hidden {
    display: none;
}
textarea {
    min-height: 100px;
    resize: vertical;
}
#form-cliente, #form-fornecedor {
    padding: 0 2.5rem 2.5rem 2.5rem;
}


/* ========= ESTILOS RESPONSIVOS ========= */
@media (max-width: 900px) {
    .steps-benefits-grid {
        gap: 0.8rem;
        width: 100%;
    }
}
@media (max-width: 768px) {
    section {
        padding: 40px 0;
    }
    .hero-content {
        flex-direction: column;
        text-align: center;
    }
    .hero-image {
        order: -1;
        margin-bottom: 2rem;
    }
    .hero-text h1 {
        font-size: 2.2rem;
    }
    .hero-text {
        padding-top: 0;
    }
    #como-funciona {
        padding-top: 40px;
    }
    .features-box {
        position: static; /* Mude de 'relative' para 'static' */
        width: 100%;
        transform: none;
        margin-bottom: 2rem;
        flex-direction: column;
        top: auto;
        left: auto;
    }
    .steps-section {
        padding-top: 0;
    }
    .simulacao-content {
        flex-direction: column;
    }
    .simulacao-image { 
        display: none;
    }
    .simulacao-form-wrapper {
        border-radius: 15px;
    }
}
@media (max-width: 576px) {
    #condicoes h2 {
      font-size: 1.9rem;
    }
}
@media (max-width: 480px) {
    .steps-benefits-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    #form-cliente, #form-fornecedor {
        padding: 0 1.5rem 1.5rem 1.5rem;
    }
    .form-toggle {
        margin: 1.5rem;
    }
}


/* ======================================================= */
/* ==== NOVO: ESTILO PARA A CAIXA DE SELEÇÃO (SELECT) ==== */
/* ======================================================= */

.form-group select {
    /* 1. Aplica os mesmos estilos dos outros inputs */
    width: 100%;
    padding: 1rem;
    border: 1px solid #dcdcdc;
    border-radius: 12px;
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    background-color: var(--branco); /* Garante o fundo branco */
    cursor: pointer;

    /* 2. Remove a aparência padrão do navegador (incluindo a seta feia) */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;

    /* 3. Adiciona uma seta customizada como imagem de fundo */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%236c757d'%3E%3Cpath d='M8 11.414l-4.95-4.95a1 1 0 0 1 1.414-1.414L8 8.586l3.536-3.536a1 1 0 0 1 1.414 1.414L8 11.414z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1em;

    /* 4. Adiciona um padding extra à direita para o texto não ficar em cima da seta */
    padding-right: 3rem;
}

/* Deixa o texto do placeholder "UF*" cinza, como nos outros campos */
.form-group select:required:invalid {
    color: #999;
}

/* Deixa o texto preto depois que uma opção é selecionada */
.form-group option {
    color: #333;
}