/* --- 1. CONFIGURAÇÕES GLOBAIS E RESET --- */
html {
    scroll-padding-top: 75px; /* Ajuste para Navbar fixa */
    position: relative;
    min-height: 100%;
}

html, body {
    overflow-x: hidden;
    width: 100%;
}

body {
    margin: 0;
    padding: 0;
    color: #212529; /* Melhor contraste global */
}

/* --- 2. NAVEGAÇÃO E NAVBAR --- */
.navbar {
    height: auto !important;
    min-height: 56px;
    overflow: visible !important;
}

.navbar .container {
    padding-left: 1rem;
    padding-right: 1rem;
}

.navbar-brand {
    letter-spacing: 1px;
    font-size: 1.5rem;
}

.nav-link {
    font-weight: 500;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: #4dabff !important;
}

.nav-item.dropdown {
    display: flex;
    align-items: center;
}

.navbar-collapse {
    overflow: visible !important;
    max-height: none !important;
}

.navbar form {
    margin: 0;
    display: flex;
    align-items: center;
}

.navbar .input-group {
    max-width: 150px;
}

#langDrop {
    border-radius: 20px;
    padding: 5px 15px;
    transition: all 0.3s ease;
}

#langDrop:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Ajustes de busca na Navbar */
.input-group input[name="searchTerm"] {
    transition: all 0.3s ease;
}

.input-group input[name="searchTerm"]:focus {
    max-width: 250px !important;
    background-color: #fff !important;
    color: #000 !important;
    border-color: #4dabff !important;
}

/* Media Queries para Navbar Responsiva */
@media (max-width: 1200px) {
    .navbar-nav .nav-link {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
        font-size: 0.9rem;
    }
}

@media (max-width: 991.98px) {
    .input-group input[name="searchTerm"] {
        max-width: 100% !important;
    }
}

/* --- 3. COMPONENTES E ANIMAÇÕES --- */
.transition-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.transition-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15) !important;
}

img.shadow-lg {
    transition: transform 0.3s ease;
}

img.shadow-lg:hover {
    transform: scale(1.02);
}

.object-fit-cover {
    object-fit: cover;
}

/* Foco para Acessibilidade */
.btn:focus, .form-control:focus {
    box-shadow: 0 0 0 0.1rem #ffffff, 0 0 0 0.25rem #258cfb;
}

/* --- 4. SEÇÃO FEATURES (HOME) --- */
#features .card {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    border-radius: 1rem;
    background-color: #ffffff;
    border: none;
}

#features .card:hover {
    transform: translateY(-10px);
    box-shadow: 0 1rem 3rem rgba(0,0,0,.175) !important;
}

.feature {
    height: 4rem;
    width: 4rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin: 0 auto;
}

.hover-shadow {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hover-shadow:hover {
    transform: translateY(-5px);
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.1) !important;
}

/* --- 5. BLOG (LISTAS E CORPO DO ARTIGO) --- */
/* Resumo na lista de posts */
.post-excerpt, .card-text-custom, .line-clamp {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.5;
}

.post-excerpt * {
    margin: 0 !important;
    padding: 0 !important;
    font-size: inherit !important;
    font-weight: normal !important;
}

.post-excerpt img {
    display: none; /* Oculta imagens dentro do resumo nos cards */
}

/* 📱 CORREÇÃO RESPONSIVA DAS IMAGENS DOS ARTIGOS (MOBILE/DESKTOP) */
.post-content img, .blog-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
    margin: 1.5rem auto;
    border-radius: 8px;
    object-fit: cover;
}

.post-content {
    line-height: 1.8;
    color: #2d3436;
    font-size: 1.15rem;
    word-wrap: break-word; /* Evita que links longos quebrem a tela no mobile */
}

.post-content p {
    margin-bottom: 1.5rem;
}

/* --- 6. FOOTER (ACESSIBILIDADE 100%) --- */
footer .text-primary {
    color: #4dabff !important;
}

footer p, footer a {
    color: #e0e0e0 !important;
}

footer a:hover {
    color: #ffffff !important;
    text-decoration: underline;
}

/* --- 7. UTILITÁRIOS E GRID --- */
.bg-light {
    background-color: #f8f9fa !important;
}

.table-responsive {
    overflow: visible !important;
}

.content-area {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    text-align: left;
}

#postTitleToDelete {
    word-wrap: break-word;
    max-height: 100px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Estilos de Paginação */
.pagination .page-link {
    color: #4dabff;
    border-radius: 5px;
    margin: 0 3px;
}

.pagination .page-item.active .page-link {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: #ffffff !important;
}

.pagination .page-item.disabled .page-link {
    background-color: #f8f9fa;
    color: #6c757d;
}

/* Mapa e Empresas */
.company-map-label {
    background-color: #0d6efd;
    color: #ffffff;
    border: none;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.company-map-label::before {
    border-top-color: #0d6efd !important;
}

.empresas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.empresa-card {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 16px;
    background-color: #ffffff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.empresa-card h3 {
    margin-top: 0;
    color: #333333;
    font-size: 1.1rem;
}

.btn-mapa {
    display: inline-block;
    margin-top: 10px;
    padding: 6px 12px;
    background-color: #007bff;
    color: #ffffff;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.85rem;
}