@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&display=swap');

:root {
    --primary-color: #2f6d2f; /* Verde escuro */
    --secondary-color: #4caf50; /* Verde médio */
    --text-color: #333;
    --background-color: #ffffff;
    --font-family: 'Poppins', sans-serif;
    --success-color: #28a745;
    --error-color: #dc3545;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    color: var(--text-color);
    background-color: var(--background-color);
    line-height: 1.8;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

header.scrolled {
    padding: 0.8rem 0;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header .logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--text-color);
}

header .logo img {
    height: 40px;
    margin-right: 0;
    transition: transform 0.3s ease;
}

header .logo img:hover {
    transform: rotate(-10deg);
}

/* Oculta texto dentro da logo para evitar duplicidade (mantém acessibilidade via aria-label) */
header .logo span { display: none; }

header nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
}

header nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 600;
    position: relative;
    padding-bottom: 5px;
}

header nav a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-image: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    transition: width 0.3s ease;
}

header nav a:hover::after {
    width: 100%;
}

/* Botão de menu (mobile) */
.menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.menu-toggle i { width: 28px; height: 28px; }

.site-nav { }

/* Navegação mobile */
@media (max-width: 768px) {
    .menu-toggle { display: inline-flex; }
    header nav ul { gap: 15px; }
    .site-nav { display: none; }
    .site-nav.open { 
        display: block; 
        position: fixed;
        top: 64px;
        left: 0;
        width: 100%;
        background: rgba(255,255,255,0.97);
        box-shadow: 0 8px 20px rgba(0,0,0,0.1);
        padding: 16px 24px;
    }
    .site-nav ul { 
        display: flex; 
        flex-direction: column; 
        gap: 12px; 
    }
}

main {
    padding-top: 100px;
}

section {
    padding: 80px 0;
}

section:nth-of-type(even) {
    background-color: #f9f9f9;
}

h1, h2, h3 {
    font-weight: 700;
}

section h2 {
    text-align: center;
    margin-bottom: 60px;
    font-size: 2.8rem;
    position: relative;
    padding-bottom: 10px;
}

section h2::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 4px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background-image: linear-gradient(to right, var(--primary-color), var(--secondary-color));
}

#home {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-image: linear-gradient(to right, rgba(47, 109, 47, 0.1), rgba(76, 175, 80, 0.1));
}

#home h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

.pillars {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 50px;
}

.pillar {
    background: var(--background-color);
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    width: 30%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center;
}

.pillar:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.12);
}

.pillar i {
    width: 48px;
    height: 48px;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.pillar h3 {
    margin-bottom: 10px;
    font-size: 1.5rem;
}

#about p {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
}

#portfolio .cases {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.case {
    background: white;
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.case:hover {
    transform: scale(1.05);
}

.case h3 {
    margin-bottom: 10px;
}

#pipeline .steps {
    display: flex;
    justify-content: space-between;
    text-align: center;
    position: relative;
}

#pipeline .steps::before {
    content: '';
    position: absolute;
    top: 25px;
    left: 10%;
    width: 80%;
    height: 2px;
    background: #e0e0e0;
    z-index: -1;
}

.step {
    width: 18%;
    position: relative;
}

.step span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-image: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    color: white;
    margin: 0 auto 15px;
    font-weight: 700;
    font-size: 1.2rem;
    border: 3px solid white;
    box-shadow: 0 0 0 3px var(--secondary-color);
}

#contact form {
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

#contact input, #contact textarea {
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    width: 100%;
    font-family: var(--font-family);
    font-size: 1rem;
    transition: border-color 0.3s;
}

#contact input:focus, #contact textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

#contact .nda {
    display: flex;
    align-items: center;
    gap: 10px;
}
#contact .nda input[type="checkbox"] { width: auto; height: auto; flex: 0 0 auto; accent-color: var(--primary-color); }
#contact .nda label { text-align: left; line-height: 1.4; flex: 0 1 auto; }

#contact button {
    padding: 18px;
    border: none;
    border-radius: 5px;
    background-image: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    color: white;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
}

#contact button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

#legal p, #partners p, #blog p {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

footer {
    text-align: center;
    padding: 30px 0;
    background: #222;
    color: white;
}

footer a {
    color: #fff;
    text-decoration: none;
}

footer a:hover {
    color: var(--secondary-color);
}

.portfolio-link {
    display: inline-block;
    margin-top: 10px;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.portfolio-link:hover {
    color: var(--secondary-color);
}

.nda-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.nda-link:hover {
    color: var(--secondary-color);
}

#form-feedback {
    text-align: center;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    display: none;
}

#form-feedback.success {
    background-color: var(--success-color);
    color: white;
    display: block;
}

#form-feedback.error {
    background-color: var(--error-color);
    color: white;
    display: block;
}

.form-error {
    color: var(--error-color);
    font-size: 0.9rem;
    margin-top: 5px;
}

input.invalid, textarea.invalid {
    border-color: var(--error-color) !important;
}

/* Form wizard */
.form-steps {
    max-width: 800px;
    margin: 0 auto;
}

.steps-indicator {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.steps-indicator .indicator {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eee;
    color: #666;
    font-weight: 700;
}

.steps-indicator .indicator.active {
    background-image: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    color: #fff;
}

.steps-indicator .indicator.done {
    background: #cde7c9; /* tom de verde suave */
    color: #2f6d2f;
}

.form-step h3 {
    margin-bottom: 10px;
}

.upload-label {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.signature-area {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.signature-area canvas {
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fafafa;
}

.signature-actions {
    display: flex;
    justify-content: flex-end;
}

.step-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

button.secondary {
    background: #f0f0f0;
    color: #333;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    header nav ul {
        flex-direction: column;
        gap: 15px;
    }
    
    #home h1 {
        font-size: 2.5rem;
    }
    
    section h2 {
        font-size: 2rem;
    }
    
    .pillars {
        flex-direction: column;
        gap: 20px;
    }
    
    .pillar {
        width: 100%;
    }
    
    #pipeline .steps {
        flex-direction: column;
        gap: 20px;
    }
    
    #pipeline .steps::before {
        display: none;
    }
    
    .step {
        width: 100%;
    }
    
    #contact form {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    #home h1 {
        font-size: 2rem;
    }
    
    section h2 {
        font-size: 1.8rem;
    }
    
    header .logo span {
        font-size: 1.4rem;
    }
    
    header nav ul {
        gap: 10px;
    }
    
    section {
        padding: 60px 0;
    }
}
#contact .form-step { display: grid; gap: 16px; }
.form-step input, .form-step textarea, .form-step .upload-label, .form-step .nda { margin-top: 4px; }
.form-step input, .form-step textarea { margin-bottom: 10px; }

/* Ajuste de colagem dos inputs em telas pequenas */
@media (max-width: 640px) {
    #ideaForm .form-grid { grid-template-columns: 1fr; }
    #ideaForm .form-grid .form-group { margin-bottom: 12px; }
}

/* Ajustes de alinhamento NDA e responsividade da assinatura */
#contact .nda label { text-align: left; line-height: 1.4; }
.signature-area canvas { width: 100%; max-width: 100%; height: 180px; }

/* Botões de ação: alinhamento e estilo do secundário */
.step-actions { justify-content: space-between; flex-wrap: wrap; }
.step-actions button { min-width: 140px; }
#contact button.secondary { background-image: none; background-color: #f0f0f0; color: #333; }
#contact button.secondary:hover { background-color: #e4e4e4; box-shadow: none; }

@media (max-width: 768px) {
    .signature-area canvas { height: 160px; }
    .step-actions { justify-content: center; }
}

/* Blog modal e lista */
.modal { position: fixed; inset: 0; background: rgba(0,0,0,.4); display: none; align-items: center; justify-content: center; z-index: 2000; padding: 20px; }
.modal.open { display: flex; }
.modal .modal-content { background: #fff; border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.2); max-width: 900px; width: min(100%, 900px); padding: 24px; position: relative; max-height: 85vh; overflow-y: auto; }
.modal .modal-close { position: absolute; top: 10px; right: 10px; background: #f0f0f0; border: none; border-radius: 6px; padding: 6px 10px; cursor: pointer; }

/* Conteúdo do modal do blog */
#modal-title { margin-bottom: 10px; }
#modal-body { line-height: 1.7; text-align: left; }
#modal-body p { word-break: break-word; text-align: left; }

#blog-list { max-width: 800px; margin: 0 auto; }
#blog-list ul { list-style: none; display: grid; gap: 12px; padding: 0; }
#blog-list li { background: #fff; border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.08); padding: 14px; cursor: pointer; transition: transform .2s; }
#blog-list li:hover { transform: translateY(-2px); }
