/* ========== ESTILOS GERAIS ========== */
html, body {
    max-width: 100%;
    overflow-x: hidden;
}

.produtos-container {
    display: flex;
    max-width: 1200px;
    margin: 2rem auto;
    gap: 2rem;
    padding: 0 1rem;
    flex-wrap: nowrap;
    box-sizing: border-box;
}

.filtros-menu {
    flex: 0 0 250px;
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

.filtros-menu h2 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    color: #2E8B57;
    margin-bottom: 1.5rem;
}

.filtro {
    margin-bottom: 2rem;
}

.filtro-header {
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.filtro h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.1rem;
    color: #2E8B57;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dropdown-content {
    display: none;
    list-style: none;
    padding: 0;
    margin: 0;
}

.dropdown-content.active {
    display: block;
}

.filtro ul li {
    margin-bottom: 0.75rem;
}

.filtro ul li label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.limpar-filtros-btn {
    width: 100%;
    padding: 10px;
    margin-top: 20px;
    background-color: #f44336;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
    box-sizing: border-box;
}

.limpar-filtros-btn:hover {
    background-color: #d32f2f;
}

.produtos-lista {
    flex: 1;
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

.produtos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.produto-item {
    background: white;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    min-height: 200px;
    box-sizing: border-box;
}

.produto-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 12px rgba(0, 0, 0, 0.2);
}

.produto-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.imagem-container {
    width: 100%;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.imagem-container img {
    max-width: 100%;
    max-height: 100%;
    border-radius: 10px;
    object-fit: contain;
}

.produto-card h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.25rem;
    color: #2E8B57;
    margin: 0.5rem 0;
}

.produto-card p {
    font-family: 'Roboto', sans-serif;
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.cta-button {
    background: #2E8B57;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: background 0.3s ease;
    margin-top: auto;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
}

.cta-button:hover {
    background: #1f6f4a;
}

.produto-card .cta-button {
    display: none;
}

/* Estilos para o botão de Catálogos */
.catalogos-btn-container {
    text-align: center;
    margin: 40px 0;
    padding: 0 20px;
}

.catalogos-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    background-color: #2E8B57;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 4px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.catalogos-btn i {
    margin-right: 10px;
    font-size: 1.2rem;
}

.catalogos-btn:hover {
    background-color: #1a252f;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* ========== ELEMENTOS MOBILE (OCULTOS NO DESKTOP) ========== */
.mobile-filtros-btn,
.filtros-header,
.close-filtros-btn {
    display: none;
}

/* ========== RESPONSIVIDADE GERAL ========== */
@media (max-width: 992px) {
    .produtos-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .produtos-container {
        flex-direction: column;
        padding: 0 1rem;
        gap: 0;
        width: 100%;
        margin: 1rem auto;
    }
    
    .mobile-filtros-btn,
    .filtros-header {
        display: flex;
    }
    
    .mobile-filtros-btn {
        width: 100%;
        margin: 0.5rem 0 1rem 0;
        padding: 12px 16px;
        background-color: #2E8B57;
        color: white;
        border: none;
        border-radius: 8px;
        font-size: 1rem;
        justify-content: space-between;
        align-items: center;
        box-sizing: border-box;
    }
    
    .filtros-menu {
        display: none;
        width: 100%;
        margin: 0 0 1rem 0;
        padding: 1rem;
        border-radius: 8px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }
    
    .filtros-menu.mobile-active {
        display: block;
        animation: fadeIn 0.3s ease;
    }
    
    .filtros-header {
        justify-content: space-between;
        align-items: center;
        margin-bottom: 1rem;
    }
    
    .close-filtros-btn {
        display: block;
        background: none;
        border: none;
        color: #2E8B57;
        font-size: 1.2rem;
        cursor: pointer;
        padding: 5px;
    }
    
    .produtos-lista {
        width: 100%;
        margin: 0;
        padding: 0;
        background: transparent;
        box-shadow: none;
    }
    
    .produtos-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem;
        padding: 0;
        width: 100%;
    }
    
    .produto-item {
        padding: 0.75rem;
        min-height: auto;
    }
    
    .dropdown-content {
        max-height: 50vh;
        overflow-y: auto;
    }
}

@media (max-width: 480px) {
    .produtos-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.5rem;
    }
    
    .produto-item {
        padding: 0.5rem;
    }
    
    .produto-card h3 {
        font-size: 1rem;
    }
    
    .imagem-container {
        height: 120px;
    }
    
    .cta-button {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== SOLUÇÃO DEFINITIVA PARA A HOME ========== */
.home .produtos-lista {
    width: 100%;
    max-width: 1400px;
    margin: 2rem auto 0;
    padding: 0 15px;
    box-sizing: border-box;
    background: transparent; /* Fundo transparente */
    box-shadow: none; /* Remove sombra */
    border-radius: 0; /* Remove bordas arredondadas */
    padding: 0; /* Remove padding interno se necessário */
}

.home .produtos-grid {
    display: grid;
    width: 100%;
    justify-content: center; /* Centraliza os cards */
    grid-template-columns: repeat(auto-fit, minmax(250px, 260px)); /* Largura fixa */
    gap: 20px;
}

/* Mobile - 2 colunas */
/* ========== SOLUÇÃO PARA ALTURA CONSISTENTE DOS CARDS NO MOBILE ========== */
@media (max-width: 767px) {
    
    .home .produtos-lista {
        padding: 0 15px; /* Margem menor em mobile */
    }
    
    .home .produtos-grid {
        grid-template-columns: repeat(2, minmax(140px, 1fr));
        gap: 12px;
        align-items: stretch; /* Garante que todos os cards tenham a mesma altura */
    }
    
    .home .produto-item {
        padding: 12px;
        height: 100%; /* Ocupa toda a altura da célula do grid */
        display: flex;
        flex-direction: column;
    }
    
    .home .produto-card {
        flex: 1; /* Faz o card ocupar todo o espaço disponível */
        display: flex;
        flex-direction: column;
        min-height: 200px; /* Altura mínima consistente */
    }
    
    .home .imagem-container {
        height: 90px;
        flex-shrink: 0; /* Impede que a imagem reduza desproporcionalmente */
        margin-bottom: 8px;
    }
    
    .home .produto-card h3 {
        font-size: 0.9rem;
        margin: 0.3rem 0;
        line-height: 1.2;
        flex-shrink: 0;
    }
    
    .home .produto-card p {
        font-size: 0.75rem;
        margin-bottom: 0.5rem;
        -webkit-line-clamp: 2;
        line-height: 1.3;
        flex-grow: 1; /* Ocupa o espaço disponível */
        overflow: hidden;
    }
    
    .home .cta-button {
        padding: 0.3rem 0.6rem;
        font-size: 0.75rem;
        margin-top: auto; /* Sempre fica no final */
        flex-shrink: 0;
    }
}

/* Tablet - 3 colunas */
@media (min-width: 768px) and (max-width: 1199px) {
    .home .produtos-grid {
        grid-template-columns: repeat(3, minmax(180px, 200px));
        gap: 15px;
    }
}

/* Desktop - 4 colunas */
@media (min-width: 1200px) {
    .home .produtos-grid {
        grid-template-columns: repeat(4, minmax(220px, 260px));
    }
}

/* Estilos dos cards (mantendo seu visual original) */
.home .produto-item {
    width: 100%;
    height: 100%;
    overflow: hidden;
    margin: 0 auto;
    box-sizing: border-box;
    background: white;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.home .produto-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.15);
}

.home .produto-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    width: 100%;
}

.home .imagem-container {
    width: 100%;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    flex-shrink: 0;
}

.home .imagem-container img {
    max-width: 100%;
    max-height: 100%;
    border-radius: 8px;
    object-fit: contain;
}

.home .produto-card h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.1rem;
    color: #2E8B57;
    margin: 0.5rem 0;
    flex-shrink: 0;
}

.home .produto-card p {
    font-family: 'Roboto', sans-serif;
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 1rem;
    flex-grow: 1;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.home .cta-button {
    background: #2E8B57;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    text-decoration: none;
    font-size: 0.85rem;
    transition: background 0.3s ease;
    margin-top: auto;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

.home .cta-button:hover {
    background: #1f6f4a;
}