/*
Theme Name: Affordable SEO Blog Theme
Theme URI: https://affordableseo.lat/
Author: Rafael Paranaguá
Author URI: https://www.linkedin.com/in/rafael-paranagua/
Description: Tema profissional para blogs de SEO e negócios, focado em performance, cards responsivos e CTAs personalizados.
Version: 1.0.0
Requires at least: 6.5
Tested up to: 6.6
Requires PHP: 8.0
Text Domain: affordable-seo-blog
Domain Path: /languages
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Tags: blog, responsive, custom-logo, custom-colors, custom-menu, two-columns, editor-style
Update URI: false
*/

/* -------------------- RESET / BASE -------------------- */
*{margin:0;padding:0;box-sizing:border-box;}
html,body{max-width:100%;overflow-x:hidden;}
img,svg,video,canvas{max-width:100%;height:auto;display:block;}

body{
  background:#344D96;
  color:#fff;
  font-family:'Lato',sans-serif;
  font-weight:400;
  line-height:1.6;
}

/* Tipografia global */
h1,h2,h3,h4,h5,h6{
  font-family:'Montserrat',sans-serif;
  font-weight:600;
  line-height:1.2;
  margin-bottom:1rem;
}
h1{font-size:2.5rem;font-weight:700;}
h2{font-size:2rem;}
h3{font-size:1.75rem;}
h4{font-size:1.5rem;}
h5{font-size:1.25rem;}
h6{font-size:1.125rem;}
p{margin-bottom:1rem;font-size:1.1rem;font-weight:300;}

/* Links padrão */
a{color:#000;text-decoration:none;transition:color .2s ease;}
a:hover{color:#000;}

/* Container */
.container{max-width:1200px;margin:0 auto;padding:0 20px;}

/* -------------------- HEADER / NAV -------------------- */
.site-header{
  background:#fff;
  padding:1rem 0;
  box-shadow:0 2px 10px rgba(0,0,0,.1);
  position:sticky;top:0;z-index:1000;
}
.header-content{display:flex;justify-content:space-between;align-items:center;}
.site-title{color:#333;font-size:1.5rem;font-weight:700;}
.site-title:hover{color:#007BFF;}
.site-description{color:#666;font-size:.9rem;margin-top:.25rem;}

.main-navigation ul{list-style:none;display:flex;gap:2rem;}
.main-navigation a{
  color:#000;font-weight:500;padding:.5rem 1rem;border-radius:5px;transition:all .3s ease;
}
.main-navigation a:hover{color:#000;background:#f8f9fa;}

/* Toggle mobile */
.nav-toggle{
  display:none;background:none;border:none;
  width:30px;height:30px;padding:5px;cursor:pointer;position:relative;color:#333;
  flex-direction:column;justify-content:space-around;
}
.hamburger-line{width:100%;height:3px;background:#EA580C;border-radius:2px;transition:transform .25s ease,opacity .25s ease;}
.nav-toggle:hover .hamburger-line{background:#DC2626;}
.nav-toggle.active .hamburger-line:nth-child(1){transform:translateY(6px) rotate(45deg);}
.nav-toggle.active .hamburger-line:nth-child(2){opacity:0;}
.nav-toggle.active .hamburger-line:nth-child(3){transform:translateY(-6px) rotate(-45deg);}

/* Overlay opcional */
#mobileMenuOverlay{position:fixed;left:0;right:0;bottom:0;top:64px;background:rgba(0,0,0,.4);display:none;z-index:900;}
#mobileMenuOverlay.active{display:block;}

/* -------------------- MAIN -------------------- */
.main-content{min-height:calc(100vh - 200px);padding:3rem 0;}

/* -------------------- BLOG / CARDS -------------------- */
.blog-layout{display:grid;grid-template-columns:1fr;gap:3rem;min-width:0;}
@media (min-width:1024px){.blog-layout{grid-template-columns:2fr 1fr;}}

.post-grid{display:grid;grid-template-columns:1fr;gap:2rem;margin-bottom:3rem;min-width:0;}
@media (min-width:768px){.post-grid{grid-template-columns:repeat(auto-fit,minmax(280px,1fr));}}

.post-card{
  background:rgba(255,255,255,.1);
  backdrop-filter:blur(10px);
  border-radius:15px;overflow:hidden;
  border:1px solid rgba(255,255,255,.2);
  display:flex;flex-direction:column;
  transition:transform .3s ease,background .3s ease;
  min-height:100%;
}
.post-card:hover{transform:translateY(-5px);background:rgba(255,255,255,.15);}
.post-thumbnail{width:100%;height:200px;overflow:hidden;}
.post-image{width:100%;height:100%;object-fit:cover;transition:transform .3s ease;}
.post-card:hover .post-image{transform:scale(1.05);}

/* CHAVE: filhos do card podem encolher em flex (evita overflow) */
.post-card > *{min-width:0;}

.post-content-wrapper{padding:2rem;display:flex;flex-direction:column;flex:1;min-width:0;width:100%;}
.post-title{margin-bottom:1rem;}
.post-title a{color:#fff;}
.post-title a:hover{color:#EA580C;}
.post-meta{font-size:.9rem;color:rgba(255,255,255,.8);margin-bottom:1rem;}
.post-excerpt{margin-bottom:1.5rem;color:rgba(255,255,255,.9);flex:1;}

.post-card .post-meta a,
.post-card .post-excerpt a{color:#000;text-decoration:underline;text-underline-offset:2px;}
.post-card .post-meta a:hover,
.post-card .post-excerpt a:hover{text-decoration-thickness:2px;}

/* Read More – compacto */
.read-more{
  display:inline-block;width:auto;padding:.6rem 1rem;border-radius:6px;
  background:#EA580C;color:#fff;font-weight:600;font-size:.95rem;line-height:1;
  text-decoration:none;transition:transform .2s ease,background .2s ease;align-self:flex-start;
}
.read-more:hover{background:#DC2626;transform:translateY(-2px);color:#fff;}

/* -------------------- PAGINAÇÃO -------------------- */
.custom-pagination{margin:3rem 0;}
.pagination-wrapper{
  display:flex;justify-content:center;align-items:center;gap:.5rem;flex-wrap:wrap;
}
.pagination-wrapper a,.pagination-wrapper span{
  background:rgba(255,255,255,.1);color:#fff;padding:.75rem 1rem;border-radius:8px;
  border:1px solid rgba(255,255,255,.2);min-width:45px;text-align:center;font-weight:500;
}
.pagination-wrapper a:hover{background:rgba(255,255,255,.2);transform:translateY(-2px);}
.pagination-wrapper .current{background:#EA580C;border-color:#EA580C;}

/* -------------------- SIDEBAR -------------------- */
.sidebar-widget{
  background:rgba(255,255,255,.1);
  backdrop-filter:blur(10px);
  border-radius:15px;padding:2rem;border:1px solid rgba(255,255,255,.2);
  min-height:auto;
}
.widget-title{color:#fff;margin-bottom:1.5rem;font-size:1.25rem;font-weight:600;}
.categories-list,.recent-posts-list{list-style:none;}
.categories-list li,.recent-posts-list li{margin-bottom:.75rem;padding-bottom:.75rem;border-bottom:1px solid rgba(255,255,255,.1);}
.categories-list li:last-child,.recent-posts-list li:last-child{border-bottom:none;margin-bottom:0;padding-bottom:0;}
.categories-list a,.recent-posts-list a{color:rgba(255,255,255,.9);}
.categories-list a:hover,.recent-posts-list a:hover{color:#EA580C;}

/* espaçamento entre widgets no desktop */
@media (min-width:1024px){
  .blog-sidebar .sidebar-widget,
  .blog-sidebar .widget{margin-bottom:3rem;}
  .blog-sidebar .sidebar-widget:last-child,
  .blog-sidebar .widget:last-child{margin-bottom:0;}
}

/* Search widget – evita overflow em flex */
.search-widget .search-form{display:flex;width:100%;}
.search-widget .search-form input[type="search"]{
  background:rgba(255,255,255,.15);
  border:1px solid rgba(255,255,255,.3);
  color:#fff;border-radius:8px 0 0 8px;
  flex:1 1 auto;min-width:0; /* chave para não estourar em mobile */
}
.search-widget .search-form input[type="search"]:focus{
  outline:none;border-color:#EA580C;background:rgba(255,255,255,.2);
}
.search-widget .search-form button{border-radius:0 8px 8px 0;flex:0 0 auto;white-space:nowrap;}

/* -------------------- SINGLE POST -------------------- */
article.single-post{
  max-width:1100px;width:100%;
  margin:2rem auto 0;
  background:#495FA1;color:#fff;
  border-radius:16px;padding:3rem 2.25rem;border:none;backdrop-filter:none;
}
article.single-post .single-post-title{
  color:#fff;font-size:2.6rem;line-height:1.2;margin-bottom:1rem;text-align:center;
}
article.single-post .single-post-meta{
  color:rgba(255,255,255,.9);text-align:center;margin-bottom:2rem;
  padding-bottom:1rem;border-bottom:1px solid rgba(255,255,255,.35);
}
article.single-post .post-content{color:#fff;font-size:1.12rem;line-height:1.85;}
article.single-post .post-content img{border-radius:10px;margin:2rem 0;}
.wp-block-image img{height:auto;}

article.single-post .post-content h1{font-size:2.2rem;margin:2rem 0 1rem;color:#fff;}
article.single-post .post-content h2{font-size:1.9rem;margin:1.75rem 0 .75rem;color:#fff;}
article.single-post .post-content h3{font-size:1.6rem;margin:1.5rem 0 .6rem;color:#fff;}
article.single-post .post-content h4{font-size:1.35rem;margin:1.25rem 0 .5rem;color:#fff;}
article.single-post .post-content h5{font-size:1.18rem;margin:1rem 0 .4rem;color:#fff;}
article.single-post .post-content h6{font-size:1rem;margin:.75rem 0 .3rem;color:#fff;}

/* Links no SINGLE (meta e conteúdo, exceto botões) */
article.single-post .single-post-meta a{
  color:#FBBF24;text-decoration:underline;text-underline-offset:2px;
}
article.single-post .post-content a:not(.cta-button):not(.wp-element-button):not(.wp-block-button__link){
  color:#FBBF24;text-decoration:underline;text-underline-offset:2px;
}

/* Botões no conteúdo do SINGLE (shortcode + Gutenberg) */
.cta-button,
article.single-post .post-content a.wp-element-button,
article.single-post .post-content .wp-block-button .wp-block-button__link{
  background:#EA580C;color:#fff;text-decoration:none;
  display:inline-flex;align-items:center;gap:.5rem;
  padding:14px 22px;border-radius:12px;font-weight:700;line-height:1;
  box-shadow:0 8px 20px rgba(234,88,12,.35);
  transition:transform .15s ease,box-shadow .15s ease,background-color .15s ease;
  width:auto;cursor:pointer;border:none;
}
.cta-button:hover,
article.single-post .post-content a.wp-element-button:hover,
article.single-post .post-content .wp-block-button .wp-block-button__link:hover{
  background:#DC2626;transform:translateY(-1px);box-shadow:0 10px 24px rgba(234,88,12,.45);
}

/* Listas no single */
article.single-post .post-content ul,
article.single-post .post-content ol{list-style-position:outside;margin:1rem 0;padding-left:1.25rem;}
article.single-post .post-content li{margin:.4rem 0;}

/* Navegação (Next/Prev) */
article.single-post .post-navigation{margin-top:1.75rem;padding-top:1rem;border-top:1px solid rgba(255,255,255,.25);}
article.single-post .post-navigation a{color:#fff;text-decoration:underline;}

/* Header normal no single + sem faixa branca extra */
.single .site-header{width:100%;margin:0;border-radius:0;background:#fff;}
.single .main-content{padding-top:0;}

/* -------------------- FOOTER -------------------- */
.site-footer{background:#fff;color:#333;padding:3rem 0 1rem;margin-top:4rem;}
.footer-content{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:2rem;margin-bottom:2rem;}
.footer-section h3{color:#333;margin-bottom:1rem;}
.footer-section p,.footer-section a{color:#666;}
.footer-section a:hover{color:#007BFF;}
.footer-bottom{text-align:center;padding-top:2rem;border-top:1px solid #ddd;color:#666;}

/* Search form (global) */
.search-form{display:flex;margin-bottom:2rem;}
.search-form input[type="search"]{
  flex:1;padding:1rem;border:1px solid rgba(255,255,255,.3);border-radius:5px 0 0 5px;
  background:rgba(255,255,255,.1);color:#fff;font-size:1rem;min-width:0;
}
.search-form input[type="search"]::placeholder{color:rgba(255,255,255,.6);}
.search-form button{
  background:#EA580C;color:#fff;border:none;padding:1rem 1.5rem;border-radius:0 5px 5px 0;
  cursor:pointer;transition:all .3s ease;
}
.search-form button:hover{background:#DC2626;}

/* -------------------- RESPONSIVO -------------------- */
@media (max-width:768px){
  .nav-toggle{display:flex;margin-left:auto;}
  .header-content{position:relative;}
  .main-navigation{
    display:none;position:absolute;top:100%;left:0;right:0;background:#fff;
    box-shadow:0 5px 10px rgba(0,0,0,.1);z-index:1000;
  }
  .main-navigation.active{display:block;}
  #mainNav .nav-menu,#mainNav .menu{display:flex;flex-direction:column;gap:0;padding:.5rem 20px 1rem;}
  .main-navigation a{display:block;padding:1rem;border-bottom:1px solid #f0f0f0;color:#333;}

  /* Single full-bleed com 2px de margem lateral */
  .single .container{padding-left:2px;padding-right:2px;}
  article.single-post{margin:8px 0;padding:1.5rem;border-radius:0;}
  article.single-post .single-post-title{font-size:2rem;}
  article.single-post .post-content h1{font-size:1.8rem;}
  article.single-post .post-content h2{font-size:1.55rem;}
  article.single-post .post-content h3{font-size:1.35rem;}
  article.single-post .post-content h4{font-size:1.2rem;}
  article.single-post .post-content h5{font-size:1.05rem;}
  article.single-post .post-content h6{font-size:.95rem;}

  /* Footer centralizado no mobile */
  .site-footer .footer-content{grid-template-columns:1fr;text-align:center;}
  .site-footer .footer-section h3{text-align:center;}
  .site-footer .footer-section a,
  .site-footer .footer-section p{text-align:center;}
}

/* ===== BLOG (index/archive) – CORREÇÕES MOBILE/TABLET ===== */
/* REMOVIDO overflow clip/hidden que estava cortando os cards */
@media (max-width:900px){
  /* gutters pelo container, sem margens laterais nos cards/widgets */
  body:not(.single) .container{padding-left:12px;padding-right:12px;}
  body:not(.single) .post-card,
  body:not(.single) .blog-sidebar .sidebar-widget,
  body:not(.single) .blog-sidebar .widget{margin-left:0;margin-right:0;max-width:100%;}

  /* 1 coluna sem cortes */
  body:not(.single) .post-grid{grid-template-columns:1fr;}
  
  /* CORREÇÃO PRINCIPAL: removido overflow que cortava os cards */
  body:not(.single) .blog-layout,
  body:not(.single) .post-grid{
    overflow:visible; /* permite que o conteúdo seja totalmente visível */
  }
  
  /* Garante altura completa dos cards */
  body:not(.single) .post-card{
    min-height:auto;
    height:auto;
  }

  /* espaçamento extra entre os widgets no mobile */
  .blog-sidebar .sidebar-widget,
  .blog-sidebar .widget{margin-bottom:16px;}
}

/* ultra-mobile (<= 400px): quebras seguras e gutters menores */
@media (max-width:400px){
  /* Permite quebra de palavras longas sem cortar o conteúdo */
  .post-title,.post-title a,.post-excerpt,
  .categories-list a,.recent-posts-list a,.sidebar-widget{
    overflow-wrap:break-word;
    word-break:break-word;
    hyphens:auto;
  }
  
  /* Garante visibilidade total em telas pequenas */
  body:not(.single) .post-card,
  body:not(.single) .sidebar-widget{
    overflow:visible;
  }
}

@media (max-width:359px){
  body:not(.single) .container{padding-left:8px;padding-right:8px;}
  
  /* Ajusta padding dos cards em telas muito pequenas */
  body:not(.single) .post-content-wrapper{
    padding:1.5rem 1rem;
  }
  
  /* Garante que widgets não sejam cortados */
  body:not(.single) .sidebar-widget{
    padding:1.5rem 1rem;
  }
}

/* ==== BLOG INDEX: anti-corte abaixo de ~410px (seguro até ~340px) ==== */
@media (max-width: 480px){
  /* Escopo apenas na home do blog */
  body.blog .container{ padding-left:12px; padding-right:12px; }

  /* Garante que nada seja “podado” pelos wrappers */
  body.blog .blog-layout,
  body.blog .post-grid{ overflow: visible; }

  /* Evita que conteúdo interno seja cortado pelo card */
  body.blog .post-card{ overflow: visible; height:auto; min-height:auto; }

  /* Cards e widgets com padding mais compacto em telas estreitas */
  body.blog .post-content-wrapper{ padding: 1.5rem 1rem; }
  body.blog .sidebar-widget{ padding: 1.5rem 1rem; }

  /* Quebra segura de palavras longas (títulos, excerpt, listas e links) */
  body.blog .post-title,
  body.blog .post-title a,
  body.blog .post-excerpt,
  body.blog .categories-list a,
  body.blog .recent-posts-list a{
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
  }

  /* Grid mais “apertado” para caber sem overflow lateral */
  body.blog .post-grid{ gap: 1.25rem; }

  /* Search do sidebar/form global: garante que não “estoure” */
  body.blog .search-form{ display:flex; width:100%; }
  body.blog .search-form input[type="search"]{ min-width:0; flex:1 1 auto; }
  body.blog .search-form button{
    flex:0 0 auto;
    max-width:40vw;          /* evita empurrar o input */
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
  }
}

/* Ultra-estreito: pequenos ajustes adicionais */
@media (max-width: 360px){
  body.blog .container{ padding-left:8px; padding-right:8px; }
  body.blog .post-content-wrapper,
  body.blog .sidebar-widget{ padding: 1.25rem .9rem; }
}

/* ==== BLOG INDEX: endurecer para <370px e <350px ==== */

/* 1) Até 370px: força 1 coluna e evita cortes por min-width:auto em flex items */
@media (max-width: 370px){
  /* Se for GRID, vira 1 coluna; se for FLEX, os filhos ocupam 100% */
  body.blog .post-grid{ grid-template-columns: 1fr !important; gap: 1rem; }
  body.blog .post-grid > *{ flex: 1 1 100% !important; max-width: 100% !important; }

  /* Nada “corta” por conta de min-width:auto dos filhos em flex */
  body.blog .post-card,
  body.blog .post-content-wrapper,
  body.blog .sidebar-widget,
  body.blog .recent-posts-list,
  body.blog .categories-list,
  body.blog .search-form{ min-width: 0; }

  /* Imagens não empurram largura/altura do card */
  body.blog .post-card img{ width:100%; height:auto; object-fit:contain; }

  /* Títulos/links quebram agressivamente; tipografia ligeiramente menor */
  body.blog .post-title,
  body.blog .post-title a,
  body.blog .post-excerpt,
  body.blog .categories-list a,
  body.blog .recent-posts-list a{
    overflow-wrap:anywhere; word-break:break-word; hyphens:auto;
  }
  body.blog .post-title{ font-size:clamp(1rem,3.6vw,1.125rem); line-height:1.25; }
  body.blog .post-excerpt{ font-size:.95rem; }

  /* Metadados/categorias não estouram em linha única */
  body.blog .post-meta{ display:flex; flex-wrap:wrap; gap:.35rem .5rem; }

  /* Wrappers não podam conteúdo */
  body.blog .blog-layout,
  body.blog .post-grid,
  body.blog .post-card{ overflow:visible; height:auto; }
}

/* 2) Ultra-estreito: 350px e abaixo */
@media (max-width: 350px){
  body.blog .container{ padding-left:6px; padding-right:6px; }
  body.blog .post-content-wrapper,
  body.blog .sidebar-widget{ padding:1.1rem .85rem; }

  /* Search compacto sem empurrar o input */
  body.blog .search-form{ display:flex; gap:.5rem; }
  body.blog .search-form input[type="search"]{ min-width:0; flex:1 1 auto; }
  body.blog .search-form button{
    flex:0 0 auto; max-width:48vw; white-space:nowrap; text-overflow:ellipsis; overflow:hidden;
  }

  /* Títulos dos widgets menores para caber sem overflow lateral */
  body.blog .sidebar-widget h3{ font-size:1rem; line-height:1.25; }
}
/* ===== ULTRA-MOBILE: AJUSTES ESPECÍFICOS PARA 320-350px ===== */
@media (max-width: 370px) {
  /* Ajustes gerais de container */
  body.blog .container, 
  body:not(.single) .container {
    padding-left: 6px;
    padding-right: 6px;
  }
  
  /* Ajuste fino de padding para cards e widgets */
  body.blog .post-content-wrapper,
  body.blog .sidebar-widget,
  body:not(.single) .post-content-wrapper,
  body:not(.single) .sidebar-widget {
    padding: 1rem 0.8rem;
  }
  
  /* Títulos menores mas ainda legíveis */
  body.blog .post-title,
  body:not(.single) .post-title {
    font-size: 1.05rem;
    line-height: 1.2;
  }
  
  /* Texto de excerto um pouco menor */
  body.blog .post-excerpt,
  body:not(.single) .post-excerpt {
    font-size: 0.95rem;
  }
  
  /* Meta informações em coluna para melhor ajuste */
  body.blog .post-meta,
  body:not(.single) .post-meta {
    flex-direction: column;
    gap: 0.25rem;
  }
  
  /* Botão de leitura mais compacto */
  body.blog .read-more,
  body:not(.single) .read-more {
    padding: 0.5rem 0.8rem;
    font-size: 0.9rem;
  }
}

/* ===== AJUSTES ESPECÍFICOS PARA 320px ===== */
@media (max-width: 330px) {
  /* Container com padding mínimo mas sem cortar conteúdo */
  body.blog .container, 
  body:not(.single) .container {
    padding-left: 4px;
    padding-right: 4px;
  }
  
  /* Padding ultra compacto */
  body.blog .post-content-wrapper,
  body.blog .sidebar-widget,
  body:not(.single) .post-content-wrapper,
  body:not(.single) .sidebar-widget {
    padding: 0.8rem 0.6rem;
  }
  
  /* Títulos com tamanho mínimo legível */
  body.blog .post-title,
  body:not(.single) .post-title {
    font-size: 1rem;
  }
  
  /* Widget titles mais compactos */
  body.blog .widget-title,
  body:not(.single) .widget-title {
    font-size: 1.1rem;
    margin-bottom: 1rem;
  }
  
  /* Formulário de busca em coluna para melhor ajuste */
  body.blog .search-form,
  body:not(.single) .search-form {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  body.blog .search-form input[type="search"],
  body:not(.single) .search-form input[type="search"] {
    border-radius: 8px;
    width: 100%;
  }
  
  body.blog .search-form button,
  body:not(.single) .search-form button {
    border-radius: 8px;
    width: 100%;
    max-width: none;
  }
  
  /* Listas com menor espaçamento */
  body.blog .categories-list li, 
  body.blog .recent-posts-list li,
  body:not(.single) .categories-list li, 
  body:not(.single) .recent-posts-list li {
    margin-bottom: 0.5rem;
    padding-bottom: 0.5rem;
  }
}

/* ===== GARANTIA DE QUEBRA DE TEXTO EM ELEMENTOS LONGS ===== */
@media (max-width: 370px) {
  .post-title, .post-title a,
  .post-excerpt, .widget-title,
  .categories-list a, .recent-posts-list a {
    overflow-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
  }
}

/* ===== AJUSTES ESPECÍFICOS PARA TELAS DE 300px ===== */
@media (max-width: 300px) {
  /* Container com padding mínimo */
  body.blog .container, 
  body:not(.single) .container {
    padding-left: 2px;
    padding-right: 2px;
  }
  
  /* Padding ultra compacto */
  body.blog .post-content-wrapper,
  body.blog .sidebar-widget,
  body:not(.single) .post-content-wrapper,
  body:not(.single) .sidebar-widget {
    padding: 0.6rem 0.4rem;
  }
  
  /* Títulos com tamanho mínimo legível */
  body.blog .post-title,
  body:not(.single) .post-title {
    font-size: 0.95rem;
    line-height: 1.15;
    margin-bottom: 0.5rem;
  }
  
  /* Texto de excerto menor */
  body.blog .post-excerpt,
  body:not(.single) .post-excerpt {
    font-size: 0.85rem;
    margin-bottom: 0.8rem;
  }
  
  /* Meta informações compactas */
  body.blog .post-meta,
  body:not(.single) .post-meta {
    font-size: 0.75rem;
    margin-bottom: 0.8rem;
  }
  
  /* Botão de leitura mais compacto */
  body.blog .read-more,
  body:not(.single) .read-more {
    padding: 0.4rem 0.6rem;
    font-size: 0.8rem;
  }
  
  /* Widget titles compactos */
  body.blog .widget-title,
  body:not(.single) .widget-title {
    font-size: 1rem;
    margin-bottom: 0.8rem;
  }
  
  /* Listas com menor espaçamento */
  body.blog .categories-list li, 
  body.blog .recent-posts-list li,
  body:not(.single) .categories-list li, 
  body:not(.single) .recent-posts-list li {
    margin-bottom: 0.4rem;
    padding-bottom: 0.4rem;
    font-size: 0.85rem;
  }
  
  /* Thumbnail mais baixa para economizar espaço vertical */
  body.blog .post-thumbnail,
  body:not(.single) .post-thumbnail {
    height: 150px;
  }
  
  /* Paginação mais compacta */
  body.blog .pagination-wrapper a, 
  body.blog .pagination-wrapper span,
  body:not(.single) .pagination-wrapper a, 
  body:not(.single) .pagination-wrapper span {
    padding: 0.4rem 0.6rem;
    min-width: 35px;
    font-size: 0.8rem;
  }
  
  /* Garantir que imagens não causem overflow */
  body.blog .post-image,
  body:not(.single) .post-image {
    max-height: 150px;
    object-fit: cover;
  }
  
  /* Ajuste fino para o formulário de busca */
  body.blog .search-form input[type="search"],
  body:not(.single) .search-form input[type="search"] {
    padding: 0.6rem;
    font-size: 0.85rem;
  }
  
  body.blog .search-form button,
  body:not(.single) .search-form button {
    padding: 0.6rem 0.8rem;
    font-size: 0.85rem;
  }
}

/* ===== GARANTIA EXTRA DE QUEBRA DE TEXTO ===== */
@media (max-width: 300px) {
  .post-title, .post-title a,
  .post-excerpt, .widget-title,
  .categories-list a, .recent-posts-list a,
  .post-meta span {
    overflow-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
    line-height: 1.2;
  }
  
  /* Forçar quebra em elementos específicos */
  .post-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem;
  }
  
  .post-meta span {
    white-space: normal;
    margin-right: 0.2rem;
  }
}
/* Footer centralizado no mobile (estrutura com .footer-widgets/.footer-col) */
@media (max-width:768px){
  .site-footer .footer-widgets{grid-template-columns:1fr; text-align:center;}
  .site-footer .footer-col img{display:block; margin:0 auto;}   /* imagens */
  .site-footer .footer-col .widget-title{ text-align:center; }
  .site-footer .footer-col p,
  .site-footer .footer-col a{ text-align:center; }

  /* menu do rodapé centralizado */
  .footer-bottom{ text-align:center; }
  .footer-nav{ display:flex; justify-content:center; }
}

.site-footer .footer-col ul{ list-style-position:inside; padding-left:0; text-align:center; }
/* ===== Footer bonito, editável por widgets ===== */
.site-footer{
  background:#111827; color:#fff;
  padding:2.25rem 0 1.25rem;
}
.site-footer a{ color:#fff; opacity:.9; text-decoration:none; transition:opacity .2s ease, color .2s ease; }
.site-footer a:hover{ opacity:1; }

/* Grid das colunas (use Footer 1 = Logo/descrição, Footer 2 = Links, Footer 3 = Social; Footer 4 opcional) */
.footer-widgets{
  display:grid; gap:2rem;
  grid-template-columns:repeat(3,minmax(0,1fr)); /* 3 colunas por padrão */
  align-items:flex-start;
  margin-bottom:1.25rem;
}
.footer-col .widget{ margin:0; }
.footer-col .widget-title{ margin-bottom:.75rem; font-weight:700; }

/* Listas de widgets sem bullets e com espaçamento bonito */
.site-footer .footer-col ul{ list-style:none; padding:0; margin:.25rem 0 0; }
.site-footer .footer-col li{ margin:.4rem 0; }
.site-footer .footer-col li > a{ display:inline-block; }

/* Menu do footer (se você usar a localização “footer” em Aparência → Menus) */
.footer-nav{ list-style:none; display:flex; flex-wrap:wrap; gap:.9rem 1.25rem; padding:0; margin:0; }
.footer-nav li{ margin:0; }

/* Bloco “redes sociais” (use num widget HTML) */
.social-links{ list-style:none; display:flex; flex-wrap:wrap; gap:.6rem; padding:0; margin:.25rem 0 0; }
.social-links li{ margin:0; }
.social-links a{
  display:inline-flex; align-items:center; justify-content:center;
  width:40px; height:40px; border-radius:999px;
  background:rgba(255,255,255,.09);
  transition:background .2s ease, transform .15s ease;
}
.social-links a:hover{ background:rgba(255,255,255,.18); transform:translateY(-1px); }
.social-links svg{ width:20px; height:20px; fill:#fff; }

/* Linha inferior (copyright) */
.footer-bottom{
  border-top:1px solid rgba(255,255,255,.15);
  padding-top:1rem; display:flex; gap:1rem;
  align-items:center; justify-content:space-between; flex-wrap:wrap;
  color:rgba(255,255,255,.85); font-size:.95rem;
}

/* Responsivo: centraliza no mobile, mantém listas alinhadas à esquerda */
@media (max-width:900px){
  .footer-widgets{ grid-template-columns:1fr; text-align:center; }
  .footer-nav{ justify-content:center; }
  .social-links{ justify-content:center; }
  /* mantém listas legíveis mesmo com container centralizado */
  .site-footer .footer-col ul{ display:inline-block; text-align:left; }
}
/* ===== Footer: padroniza o bloco Social Icons do WP ===== */
.site-footer .wp-block-social-links{
  display:flex;
  flex-wrap:wrap;
  gap:.6rem;
  padding:0;
  margin:.25rem 0 0;
  list-style:none;
}

.site-footer .wp-block-social-links .wp-social-link{
  margin:0;
  line-height:0; /* evita altura extra ao redor do ícone */
}

.site-footer .wp-block-social-links .wp-social-link .wp-block-social-link-anchor{
  width:40px;
  height:40px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:rgba(255,255,255,.09);
  color:#fff;                /* cor de “currentColor” para o SVG */
  transition:background .2s ease, transform .15s ease, opacity .15s ease;
}

.site-footer .wp-block-social-links .wp-social-link .wp-block-social-link-anchor:hover{
  background:rgba(255,255,255,.18);
  transform:translateY(-1px);
  opacity:1;
}

.site-footer .wp-block-social-links .wp-social-link svg{
  width:20px;
  height:20px;
  fill:#fff;                 /* garante ícone branco mesmo em “logos only” */
}

/* Centraliza os ícones no mobile, mantendo o grid bonito */
@media (max-width:900px){
  .site-footer .wp-block-social-links{ justify-content:center; }
}

