/* ========================================================================== */
/* PÁGINA DO ARTIGO (MOLDE DE LEITURA & HEADLESS CMS)
/* ========================================================================== */

/* ========================================== */
/* 1. LAYOUT GERAL E CONTAINERS               */
/* ========================================== */

.post-section {
    padding-top: 60px; /* Compensa o header fixo */
    padding-bottom: 80px;
    background-color: var(--white);
    min-height: 100vh; /* Evita o pulo do Footer enquanto carrega */
}

/* A "Coluna de Leitura" (Trava a largura para não cansar os olhos) */
.container-sm {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 25px; /* Respiro lateral no celular */
}

/* ========================================== */
/* 2. CABEÇALHO DO ARTIGO (HEADER E META)     */
/* ========================================== */

.post-header {
    text-align: center;
    margin-bottom: 40px;
}

.post-tag {
    background-color: #e8f3f1;
    color: var(--primary-color);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: inline-block;
    margin-bottom: 20px;
}

.post-title {
    font-size: 3rem;
    color: var(--secondary-color);
    line-height: 1.2;
    margin-bottom: 30px;
}

.post-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    padding: 20px 0;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 15px;
    text-align: left;
}

.author-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    object-position: 50% 1%; 
    image-rendering: -webkit-optimize-contrast; /* Melhora nitidez */
    image-rendering: crisp-edges;
}

.author-info strong {
    display: block;
    color: var(--secondary-color);
    font-size: 1.1rem;
}

.author-info span {
    color: #888;
    font-size: 0.9rem;
}

/* ========================================== */
/* 3. IMAGEM DE CAPA                          */
/* ========================================== */

.post-cover {
    margin: 40px auto;
    max-width: 1000px; /* Levemente mais larga que o texto para destaque */
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.post-cover img {
    width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: cover;
    display: block;
}

/* ========================================== */
/* 4. CORPO DO TEXTO (PADRÃO DE LEITURA WP)   */
/* ========================================== */

.post-content {
    color: #333333; /* Cinza escuro descansa a vista */
    font-size: 1.15rem; /* Letra num tamanho confortável para leitura longa */
    line-height: 1.8; /* Bastante espaço entre as linhas */
}

.post-content p {
    margin-bottom: 25px; /* Respiro generoso entre parágrafos */
}

/* Texto de introdução (Opcional se o Helio usar a classe .lead) */
.post-content .lead {
    font-size: 1.4rem;
    color: var(--secondary-color);
    font-weight: 300;
    line-height: 1.6;
    margin-bottom: 40px;
}

/* Subtítulos */
.post-content h2 {
    font-size: 1.8rem;
    color: var(--secondary-color);
    margin-top: 50px; 
    margin-bottom: 20px; 
    font-weight: 700;
    text-align: left;
}

.post-content h2::after {
    display: none; /* Remove a barrinha verde global dos subtítulos internos */
}

.post-content h3 {
    font-size: 1.4rem;
    color: #2c2c2c;
    margin-top: 40px;
    margin-bottom: 15px;
    font-weight: 600;
}

/* Imagens no meio do texto */
.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 35px 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    display: block;
}

/* Listas */
.post-content ul, 
.post-content ol {
    margin-bottom: 30px;
    padding-left: 20px;
}

.post-content li {
    margin-bottom: 10px;
}

/* Citações */
.post-content blockquote {
    border-left: 5px solid var(--primary-color);
    background-color: #f4f9f8;
    padding: 25px 30px;
    margin: 40px 0;
    font-size: 1.2rem;
    font-style: italic;
    color: #333;
    border-radius: 0 10px 10px 0;
}

/* Links no texto */
.post-content a {
    color: #25D366; 
    text-decoration: underline;
    text-decoration-color: rgba(37, 211, 102, 0.3);
    text-underline-offset: 3px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.post-content a:hover {
    color: #1ebc59;
    text-decoration-color: #1ebc59;
}

/* ========================================== */
/* 5. TABELAS (RESPONSIVAS E ELEGANTES)       */
/* ========================================== */

.post-content table {
    width: 100%;
    border-collapse: separate; 
    border-spacing: 0;
    margin: 35px 0;
    font-size: 1rem;
    background-color: #ffffff;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.05);
    border-radius: 10px;
    overflow: hidden;
    border: 3px solid #158c40; /* Verde Escuro da Clínica */
}

.post-content table thead {
    background-color: #158c40; 
    color: #ffffff;
}

.post-content table th {
    padding: 18px 20px;
    text-align: left;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    border-bottom: none; 
}

.post-content table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid #eeeeee;
    line-height: 1.5;
    color: #444;
}

.post-content table tbody tr:last-of-type td {
    border-bottom: none; 
}

.post-content table tbody tr:hover td {
    background-color: #f4f9f8; 
    transition: background-color 0.2s ease;
}

/* ========================================== */
/* 6. BOTÕES INJETADOS PELO JS (PULSANTES)    */
/* ========================================== */

.cta-artigo {
    text-align: center;
    margin: 30px 0;
    padding: 25px 30px; 
    background-color: #f4f9f8; 
    border-radius: 8px;
}

.cta-artigo p {
    font-size: 0.95rem; 
    color: #555;
    margin-bottom: 15px;
    font-weight: 500;
}

.btn-agendar-artigo {
    display: inline-block;
    background-color: #128C7E; 
    color: white !important;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 50px;
    text-decoration: none !important; 
    box-shadow: 0 4px 15px rgba(18, 140, 126, 0.3);
    animation: pulsarBotao 2s infinite ease-in-out; 
    transition: all 0.3s ease; 
}

.btn-agendar-artigo:hover {
    background-color: #075E54; 
    animation: none; 
    transform: translateY(-2px); 
    text-decoration: none !important; 
}

@keyframes pulsarBotao {
    0% { transform: scale(1); }
    50% { transform: scale(1.03); } 
    100% { transform: scale(1); }
}

/* ========================================== */
/* 7. CTA FINAL (INVISTA NA SUA SAÚDE)        */
/* ========================================== */

.post-cta {
    margin-top: 60px;
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    padding: 50px;
    border-radius: 20px;
    text-align: center;
    color: var(--white);
    box-shadow: 0 15px 30px rgba(11, 79, 72, 0.15);
}

.post-cta h3 {
    color: var(--white);
    font-size: 2rem;
    margin-top: 0;
    margin-bottom: 15px;
}

.post-cta p {
    font-size: 1.1rem;
    margin-bottom: 25px !important; /* Aproxima o texto do botão */
    color: rgba(255,255,255,0.9);
}

/* Conserto Cirúrgico do Botão Final */
.post-cta .btn {
    background-color: var(--white);
    color: var(--secondary-color);
    display: inline-block !important; 
    margin: 0 auto !important; /* Centraliza perfeitamente */
    padding: 15px 30px !important; 
    line-height: 1.2 !important; 
    vertical-align: middle !important;
    transition: all 0.3s ease;
}

.post-cta .btn:hover {
    background-color: #f0f0f0;
    transform: translateY(-3px);
}

/* ========================================== */
/* 8. RESPONSIVIDADE (MODO CELULAR)           */
/* ========================================== */

@media (max-width: 768px) {
    /* Ajustes de Título e Texto */
    .post-title { font-size: 2.2rem; }
    .post-content { font-size: 1.05rem; }
    .post-content .lead { font-size: 1.2rem; }
    
    /* Ajuste da Caixa Final */
    .post-cta { padding: 40px 20px; }
    .post-cta h3 { font-size: 1.6rem; }
    
    /* A Mágica da Tabela (Rolagem lateral) */
    .post-content table {
        display: block; 
        overflow-x: auto; 
        white-space: nowrap; 
    }
}

/* ========================================== */
/* 9. ESTILOS DE SUPORTE (LOADING E FOOTER)   */
/* ========================================== */

.loading-text {
    text-align: center;
    margin-top: 100px;
    font-size: 1.2rem;
    color: var(--primary-color);
}

.artigo-footer {
    background-color: var(--secondary-color);
    padding: 40px 0;
    text-align: center;
    color: white;
    margin-top: 60px; /* Garante que o rodapé não cole no conteúdo */
}