/*
Theme Name: King Post News
Theme URI: https://kingpost.com.br
Author: King Post
Author URI: https://kingpost.com.br
Description: Tema portal de notícias com grade de destaques, barra superior de data/hora e botão de WhatsApp flutuante.
Version: 1.0.5
License: GPL-2.0+
Text Domain: kingpostnews
*/

:root{
  --kp-ticker-speed:80s;
  --blue:#0b4aa8;
  --blue-dark:#083a84;
  --text:#0f172a;
  --muted:#6b7280;
  --bg:#f4f6f8;
  --card:#ffffff;
  --accent:#22c55e;
}

*{box-sizing:border-box}
html,body{margin:0;padding:0;font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;color:var(--text);background:var(--bg)}
a{color:inherit;text-decoration:none}
img{max-width:100%;height:auto;display:block}

/* ---------- Topbar (legado) ---------- */
.kp-topbar{background:var(--blue-dark);color:#e5e7eb;font-size:12px}
.kp-wrap{max-width:1200px;margin:0 auto;padding:0 16px}
.kp-topbar .kp-wrap{display:flex;align-items:center;justify-content:space-between;height:34px}
.kp-topbar a{color:#e5e7eb;opacity:.9}
.kp-topbar a:hover{opacity:1}
.kp-clock{font-variant-numeric:tabular-nums}

/* ---------- Layout base ---------- */
.kp-main{max-width:1200px;margin:20px auto;padding:0 16px;display:grid;grid-template-columns:1fr;gap:20px}
@media(min-width:992px){.kp-main{grid-template-columns:2fr 1fr}}

.kp-card{background:var(--card);border-radius:12px;overflow:hidden;box-shadow:0 2px 12px rgba(15,23,42,.06)}
.kp-card .kp-pad{padding:12px 14px}
.kp-meta{display:flex;gap:8px;align-items:center;color:var(--muted);font-size:12px}
.kp-title{font-size:18px;line-height:1.25;margin:8px 0 6px}
.kp-title-lg{font-size:26px;font-weight:800;line-height:1.2;margin:10px 0}
.kp-grid{display:grid;gap:16px}
.kp-grid.cols-2{grid-template-columns:1fr 1fr}
.kp-grid.cols-3{grid-template-columns:repeat(3,1fr)}
.kp-grid.cols-4{grid-template-columns:repeat(4,1fr)}
@media(max-width:768px){.kp-grid.cols-3,.kp-grid.cols-4{grid-template-columns:1fr 1fr}}
@media(max-width:520px){.kp-grid.cols-2,.kp-grid.cols-3,.kp-grid.cols-4{grid-template-columns:1fr}}

.kp-section{margin-top:8px}
.kp-section h3{margin:0 0 12px;font-size:20px;border-left:4px solid var(--blue);padding-left:10px}
.kp-section .kp-more{font-size:13px;color:var(--blue);font-weight:700}

.kp-widget{background:var(--card);border-radius:12px;padding:12px;box-shadow:0 2px 12px rgba(15,23,42,.06);margin-bottom:16px}
.kp-badge{display:inline-block;background:var(--blue);color:#fff;padding:3px 8px;border-radius:999px;font-size:11px}

/* ---------- Footer ---------- */
.kp-footer{background:#0b1220;color:#cbd5e1;margin-top:30px}
.kp-footer-top{padding:30px 0}
.kp-footer-columns{display:grid;gap:16px;grid-template-columns:repeat(1,1fr)}
@media(min-width:768px){.kp-footer-columns{grid-template-columns:repeat(3,1fr)}}
.kp-footer-bottom{background:#070c16;padding:14px 0;font-size:12px;color:#9ca3af;text-align:center}

/* ---------- WhatsApp flutuante ---------- */
.kp-whatsapp{
  position:fixed;right:16px;bottom:16px;z-index:9999;
  width:56px;height:56px;border-radius:50%;
  background:#25d366;display:flex;align-items:center;justify-content:center;
  box-shadow:0 8px 20px rgba(0,0,0,.2);color:#fff;font-size:26px;
}
.kp-whatsapp:hover{transform:translateY(-2px)}

/* =========================================================
   Header: topbar preta + header azul + nav + ticker
   ========================================================= */

/* Top bar preta (CNet-like) */
.kp-bar{background:#1f2937;color:#e5e7eb;font-size:12px}
.kp-bar .kp-wrap{display:flex;align-items:center;justify-content:space-between;height:36px; text-transform:uppercase}
.kp-bar a{color:#e5e7eb;opacity:.95}
.kp-bar a:hover{opacity:1}
.kp-bar .left{display:flex;gap:14px;align-items:center}
.kp-social{display:flex;gap:10px;align-items:center}
.kp-social a{display:inline-flex;width:28px;height:28px;align-items:center;justify-content:center;border-radius:50%;background:#111827}

/* -------- Header azul -------- */
.kp-header{background:#194a9d;color:#fff;border-bottom:1px solid rgba(255,255,255,.08)}
.kp-header .kp-wrap:not(.kp-grid3){display:flex;align-items:center;justify-content:space-between;padding:14px 16px}

/* ====== HEADER DESKTOP (logo centro real + busca direita) ====== */
.kp-header .kp-wrap.kp-grid3{
  position:relative;
  min-height:120px;                /* garante altura para o logo absoluto */
  display:grid;
  grid-template-columns:1fr 0 1fr; /* col esq / (logo absoluto) / col dir */
  align-items:center;
  gap:16px;
  padding:14px 16px;
}

/* Logo central geométrico */
.kp-header .kp-logo{
  position:absolute;
  left:50%;
  top:50%;
  transform:translate(-50%,-50%);
  max-width:250px;
  width:auto;
  z-index:3;                        /* abaixo da busca para não bloquear foco */
}
.kp-header .custom-logo,
.kp-header .kp-logo img{
  max-width:250px !important;
 
  width:auto;
  height:auto;
  display:block;
}
.kp-header .kp-logo strong{font-size:28px;line-height:1.1;white-space:nowrap;color:#fff}

/* Busca à direita (EDITÁVEL no desktop) */
.kp-header .kp-search{
  grid-column:3;
  justify-self:end;
  white-space:nowrap;
  width:320px;
  z-index:5;                        /* acima do logo: recebe clique/foco */
}
.kp-header .kp-search form{
  display:flex;align-items:center;
  background:rgba(0,0,0,.25);
  border-radius:6px;overflow:hidden;
}
.kp-header .kp-search input[type='search']{
  display:block;width:100%;
  border:0;background:transparent;color:#fff;
  padding:10px 12px;outline:none;font-size:14px;
}
.kp-header .kp-search input::placeholder{color:rgba(255,255,255,.8)}
.kp-header .kp-search button{
  border:0;background:rgba(0,0,0,.35);color:#fff;
  padding:0 14px;height:38px;border-radius:0;cursor:pointer;
  font-weight:800;text-transform:uppercase;display:flex;align-items:center;gap:6px;
}
/* EVITA ícone duplicado se o HTML já tiver 🔍 */
.kp-header .kp-search button::before{content:none !important;}

/* ====== MOBILE: logo em cima, busca embaixo ====== */
@media (max-width:768px){
  .kp-header .kp-wrap.kp-grid3{
    min-height:auto;
    grid-template-columns:1fr;
    grid-template-rows:auto auto;
    gap:10px;
  }
  .kp-header .kp-logo{
    position:static;transform:none;justify-self:center;max-width:180px;
  }
  .kp-header .kp-search{
    width:100%;justify-self:stretch;
  }
  .kp-header .kp-search form{
    background:rgba(0,0,0,.25);border-radius:6px;overflow:hidden;
  }
  .kp-header .kp-search button{
    height:38px;border-radius:0;
  }
}

/* -------- Navegação -------- */
.kp-nav{background:#194a9d}
.kp-nav .kp-wrap{display:flex;justify-content:center;font-size: 12px;}
.kp-nav ul{list-style:none;margin:0;padding:0;display:flex;gap:22px;flex-wrap:wrap}
.kp-nav li a{display:block;padding:12px 8px;color:#fff;font-weight:800;letter-spacing:.02em;text-transform:uppercase}
.kp-nav li a:hover{background:rgba(255,255,255,.1);border-radius:6px}

/* -------- Ticker -------- */
.kp-ticker{background:#e5e7eb;color:#111827;border-top:1px solid #d1d5db;border-bottom:1px solid #d1d5db}
.kp-ticker .kp-wrap{display:flex;align-items:center;gap:12px;overflow:hidden}
.kp-ticker .label{white-space:nowrap;display:flex;align-items:center;gap:8px;background:#fff;padding:10px 14px;border-radius:4px;font-weight:800;text-transform:uppercase;color:#0f172a}
.kp-ticker .label .dot{width:8px;height:8px;background:#2563eb;border-radius:50%}
.kp-ticker .items{display:block;position:relative;flex:1 1 auto;min-width:0;overflow:hidden}
.kp-ticker .track{display:inline-flex;gap:28px;white-space:nowrap;will-change:transform;animation:kp-marquee var(--kp-ticker-speed,80s) linear infinite}
.kp-ticker .items a{color:#111827}
@keyframes kp-marquee{0%{transform:translateX(0)}100%{transform:translateX(-50%)}}
.kp-ticker:hover .track{animation-play-state:paused}

/* ---------- Hero ---------- */
.kp-hero{max-width:1200px;margin:20px auto;padding:0 16px}
.kp-hero-grid{display:grid;gap:20px}
@media(min-width:992px){.kp-hero-grid{grid-template-columns:1fr 1fr}}
.kp-hero-card{position:relative;border-radius:14px;overflow:hidden;min-height:280px;box-shadow:0 10px 30px rgba(0,0,0,.12)}
.kp-hero-card img{width:100%;height:100%;object-fit:cover;display:block;aspect-ratio:16/9}
.kp-hero-card .overlay{position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,0,0.0)40%,rgba(0,0,0,0.65)100%)}
.kp-hero-card .content{position:absolute;left:0;right:0;bottom:0;padding:18px;color:#fff}
.kp-hero-card .badge{display:inline-block;font-size:12px;font-weight:800;letter-spacing:.04em;color:#d1d5db;margin-bottom:6px;text-transform:uppercase}
.kp-hero-card .title{font-size:28px;line-height:1.15;font-weight:900;margin:0}
@media(max-width:520px){.kp-hero-card .title{font-size:22px}}
.kp-hero-small-grid{display:grid;gap:20px;margin-top:20px}
@media(min-width:992px){.kp-hero-small-grid{grid-template-columns:repeat(4,1fr)}}
.kp-hero-mini .title{font-size:16px;line-height:1.25;font-weight:800;color:#0f172a;margin:8px 0 0}
.kp-hero-mini .meta{font-size:12px;color:#6b7280}
.kp-hero-mini img{border-radius:12px;aspect-ratio:16/9;object-fit:cover}
/* === HEADER: logo 100% central + busca à direita (desktop) === */

/* wrapper do header */
.kp-header { background:#194a9d; color:#fff; border-bottom:1px solid rgba(255,255,255,.08); }
.kp-header .kp-wrap.kp-grid3{
  position: relative;         /* ancora a busca absoluta */
  min-height: 120px;          /* altura confortável p/ centralizar verticalmente */
  padding: 14px 16px;
}

/* LOGO — centrado por margin auto (sem absolute) */
.kp-header .kp-logo{
  display:block;
  max-width:250px;
  margin:0 auto;              /* centro perfeito */
  z-index:2;                  /* abaixo da busca (que é absolute) */
  text-align:center;
}
.kp-header .kp-logo img,
.kp-header .custom-logo{
  max-width:250px !important;
  width:auto;
  height:auto;
  display:inline-block;
}
.kp-header .kp-logo strong{
  font-size:28px; line-height:1.1; white-space:nowrap; color:#fff;
}

/* BUSCA — fixa à direita e centralizada verticalmente */
.kp-header .kp-search{
  position:absolute;
  right:16px;
  top:50%;
  transform:translateY(-50%);
  width:320px;
  z-index:5;                 /* acima do logo para receber clique/foco */
}
.kp-header .kp-search form{
  display:flex; align-items:center;
  background:rgba(0,0,0,.25);
  border-radius:6px; overflow:hidden;
}
.kp-header .kp-search input[type="search"]{
  display:block; width:100%;
  border:0; background:transparent; color:#fff;
  padding:10px 12px; outline:none; font-size:14px;
}
.kp-header .kp-search input::placeholder{ color:rgba(255,255,255,.8); }
/* botão: NÃO adicionar ícone por pseudo-elemento para evitar duplicação */
.kp-header .kp-search button{
  border:0; background:rgba(0,0,0,.35); color:#fff;
  padding:0 14px; height:38px; border-radius:0; cursor:pointer;
  font-weight:800; text-transform:uppercase;
  display:flex; align-items:center; gap:6px;
}
.kp-header .kp-search button::before{ content:none !important; }

/* — MOBILE: logo em cima, busca embaixo — */
@media (max-width: 768px){
  .kp-header .kp-wrap.kp-grid3{
    min-height:auto;
    padding:12px 16px 10px;
  }
  .kp-header .kp-logo{
    max-width:180px;
  }
  .kp-header .kp-search{
    position:static;          /* volta a fluir */
    transform:none;
    width:100%;
    margin-top:10px;
  }
}
/* === HEADER (4 colunas): logo 100% central + busca à direita === */

/* header azul */
.kp-header{ background:#194a9d; color:#fff; border-bottom:1px solid rgba(255,255,255,.08); }

/* Wrapper do header em 4 colunas:
   [col1 = 1fr] [col2 = LOGO (auto)] [col3 = 1fr (espaço de balanceamento)] [col4 = BUSCA (auto)]
   OBS: seu HTML tem 3 elementos; usaremos a col3 como "espaçador" vazio para centralizar o logo. */
.kp-header .kp-wrap.kp-grid3{
  display:grid;
  grid-template-columns: 1fr auto 1fr auto;
  align-items:center;
  gap:16px;
  padding:14px 16px;
  min-height:120px; /* altura confortável */
}

/* Primeiro filho (seu <div></div> vazio) fica na col1 (já é o padrão) */

/* Logo na coluna 2, centralizado visualmente */
.kp-header .kp-logo{
  grid-column: 2;
  justify-self: center;
  max-width: 250px;      /* limite de largura pedido */
  margin: 0 auto;
  text-align: center;
  z-index: 2;
}
.kp-header .kp-logo img,
.kp-header .custom-logo{
  max-width: 250px !important;
  width: auto;
  height: auto;          /* sem max-height */
  display: inline-block;
}
.kp-header .kp-logo strong{
  font-size:28px; line-height:1.1; white-space:nowrap; color:#fff;
}

/* Busca sempre na coluna 4 (direita), editável */
.kp-header .kp-search{
  grid-column: 4;
  justify-self: end;
  width: 360px;          /* ajuste se quiser menor/maior */
  white-space: nowrap;
  z-index: 5;
}
.kp-header .kp-search form{
  display:flex; align-items:center;
  background: rgba(0,0,0,.25);
  border-radius: 6px; overflow: hidden;
}
.kp-header .kp-search input[type="search"]{
  display:block; width:100%;
  border:0; background:transparent; color:#fff;
  padding:10px 12px; outline:none; font-size:14px;
}
.kp-header .kp-search input::placeholder{ color: rgba(255,255,255,.8); }
.kp-header .kp-search button{
  border:0; background: rgba(0,0,0,.35); color:#fff;
  padding:0 14px; height:38px; border-radius:0; cursor:pointer;
  font-weight:800; text-transform:uppercase;
  display:flex; align-items:center; gap:6px;
}
/* evita ícone duplicado se algum CSS anterior adicionava ::before */
.kp-header .kp-search button::before{ content:none !important; }

/* ===== MOBILE: 1 coluna (logo em cima, busca embaixo) ===== */
@media (max-width: 768px){
  .kp-header .kp-wrap.kp-grid3{
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap:10px;
    min-height:auto;
  }
  .kp-header .kp-logo{
    grid-column: 1; justify-self: center; max-width: 180px;
  }
  .kp-header .kp-search{
    grid-column: 1; justify-self: stretch; width: 100%; margin-top: 6px;
  }
}
/* ===== Spotlight (1 grande + 4 menores) responsivo ===== */
.kp-spotlight{
  display:grid;
  gap:16px;
  grid-template-columns: 2fr 1fr; /* desktop */
}
.kp-spotlight-main .kp-spotlight-feature{
  overflow:hidden;border-radius:14px;
}
.kp-spotlight-img{
  width:100%;height:auto;display:block;object-fit:cover;
  aspect-ratio:16/9;
}
.kp-spotlight-minis{
  display:grid;gap:16px;
  grid-template-columns: 1fr; /* desktop: minis empilhados */
}

/* mini card */
.kp-spotlight-mini{
  display:flex;gap:12px;align-items:center;padding:8px;border-radius:12px;overflow:hidden;
}
.kp-spotlight-thumb{
  width:160px;height:100px;object-fit:cover;border-radius:8px;flex:0 0 auto;
}
.kp-spotlight-mini-body{ padding:4px 2px; }

/* ===== Breakpoints ===== */
@media (max-width: 991.98px){
  /* tablet: destaque em cima e minis em 2 colunas */
  .kp-spotlight{
    grid-template-columns: 1fr; /* empilha */
  }
  .kp-spotlight-minis{
    grid-template-columns: repeat(2, minmax(0,1fr)); /* 2x2 */
  }
  .kp-spotlight-thumb{
    width:120px;height:80px;
  }
}

@media (max-width: 520px){
  /* mobile: minis 1 por linha */
  .kp-spotlight-minis{
    grid-template-columns: 1fr;
  }
  .kp-spotlight-mini{
    gap:10px;
  }
  .kp-spotlight-thumb{
    width:110px;height:72px;
  }
}
/* ===== Grid 4 responsivo (4→3→2→1) ===== */
.kp-grid4{
  display:grid;
  gap:16px;
  grid-template-columns: repeat(4, minmax(0, 1fr)); /* ≥1200px */
}

@media (max-width: 1199.98px){
  .kp-grid4{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 991.98px){
  .kp-grid4{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 520px){
  .kp-grid4{ grid-template-columns: 1fr; }
}


.kp-cat-rail{padding:18px 0 8px;background:#fff}
.kp-cat-list{display:flex;gap:18px;overflow:auto;list-style:none;margin:0;padding:6px 0}
.kp-cat-li{flex:0 0 auto}
.kp-cat-card{
  display:block;width:129px;height:160px;border-radius:16px;overflow:hidden;
  background-size:cover;background-position:center;position:relative;
  box-shadow:0 6px 16px rgba(0,0,0,.18); text-decoration:none
}
.kp-cat-card:before{
  content:"";position:absolute;inset:0;
  background:linear-gradient(180deg,rgba(0,0,0,.0) 40%,rgba(0,0,0,.55) 100%);
}
.kp-cat-name{
  position:absolute;left:12px;right:12px;bottom:12px;
  font:700 12px/1.2 Inter,system-ui,Arial,sans-serif;
  letter-spacing:.6px;color:#fff;text-transform:uppercase
}
.kp-cat-card:hover{transform:translateY(-2px);box-shadow:0 10px 20px rgba(0,0,0,.22)}
@media (min-width:1024px){ .kp-cat-card{width:129px;height:180px} }


.kp-ad.kp-ad-cat-top iframe,
.kp-ad.kp-ad-cat-top ins,
.kp-ad.kp-ad-cat-top div { margin-left:auto; margin-right:auto; }


/* ===== ÁREA DE COMENTÁRIOS ===== */
#comments { margin: 24px 0 0; }

/* Título e navegação */
#comments h2, #reply-title {
  font-size: 20px; font-weight: 700; margin: 16px 0 0 16px;
}
.comment-navigation, .nav-links { margin: 12px 0; }

/* ===== LISTA DE COMENTÁRIOS ===== */
.comment-list { list-style: none; margin: 0; padding: 0; }
.comment-list > li { margin: 0 0 16px; }
.comment-body {
  border: 1px solid #e5e7eb; background: #fff; border-radius: 12px;
  padding: 16px;
}
.comment-author { display:flex; align-items:center; gap:10px; margin-bottom:6px; }
.comment-author .avatar { border-radius: 50%; width: 48px; height: 48px; }
.comment-author .says { display:none; }
.comment-meta, .comment-metadata {
  font-size: 12px; color: #6b7280; margin-bottom: 8px;
}
.comment-content p { margin: 0 0 10px; }
.reply a {
  font-size: 12px; color: #2563eb; text-decoration: none; font-weight:600;
}
.reply a:hover { text-decoration: underline; }

/* Respostas (filhos) */
.comment-list .children {
  list-style: none; margin-top: 12px; margin-left: 24px; padding-left: 0;
}

/* ===== FORMULÁRIO PADRÃO (comment_form) ===== */
.comment-respond { 
  border: 1px solid #e5e7eb; background: #fff; border-radius: 12px; 
  margin-top: 24px;
}
.comment-respond .comment-notes { 
  font-size: 13px; color: #6b7280; margin: 0 0 12px; 
}
.comment-respond form { padding: 16px; }

.comment-form p { margin: 0 0 12px; }
.comment-form label { 
  display:block; font-size: 13px; font-weight: 600; margin-bottom: 6px; 
}
.comment-form .required,
.comment-form .req { color: #ef4444; }

/* Campos */
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%; padding: 10px 12px; border: 1px solid #d1d5db; 
  border-radius: 10px; background: #fff; outline: none; font: inherit;
}
.comment-form textarea { min-height: 140px; resize: vertical; }
.comment-form input:focus,
.comment-form textarea:focus {
  border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}

/* Checkbox cookies */
.comment-form-cookies-consent { 
  display:flex; align-items:center; gap:8px; font-size:13px; color:#374151; 
}
.comment-form-cookies-consent input { width:auto; }

/* Botão enviar */
.comment-form input[type="submit"],
.comment-form .submit,
#submit {
  background:#0b3b91; color:#fff; border:none; padding:10px 16px;
  border-radius:10px; font-weight:700; cursor:pointer;
}
.comment-form input[type="submit"]:hover,
#submit:hover { filter: brightness(.95); }

/* Ajustes responsivos */
@media (max-width: 640px){
  .comment-list .children { margin-left: 16px; }
}

/* ====== SIDEBAR PADRONIZADA (estrutura <aside>) ====== */
aside {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ====== BLOCO GERAL ====== */
.kp-widget {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(2,6,23,.06);
  padding: 18px;
  max-width: 382px;
}

/* ====== TÍTULOS ====== */
.kp-widget .wp-block-heading {
  margin: 0 0 14px;
  font-weight: 800;
  font-size: 1.25rem;
  color: #0f172a;
}

/* ====== CAMPO DE PESQUISA ====== */
.kp-widget .wp-block-search__inside-wrapper {
  display: flex;
  gap: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 6px;
}

.kp-widget .wp-block-search__input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 1rem;
  padding: 6px 10px;
  outline: none;
  color: #0f172a;
}

.kp-widget .wp-block-search__button {
  background: #0b1852;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 8px 16px;
  cursor: pointer;
  font-weight: 600;
  transition: background .2s, transform .2s;
}

.kp-widget .wp-block-search__button:hover {
  background: #162673;
  transform: translateY(-1px);
}

/* ====== ÚLTIMAS NOTÍCIAS ====== */
.kp-widget .wp-block-latest-posts__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.kp-widget .wp-block-latest-posts__list li {
  display: flex;
  align-items: center;
  gap: 12px;
}

.kp-widget .wp-block-latest-posts__featured-image {
  flex: 0 0 auto;
  width: 64px;
  height: 64px;
  overflow: hidden;
  border-radius: 10px;
}

.kp-widget .wp-block-latest-posts__featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.kp-widget .wp-block-latest-posts__post-title {
  flex: 1;
  text-decoration: none;
  background: #f8fafc;
  border: 1px solid #eef2f7;
  padding: 8px 10px;
  border-radius: 10px;
  color: #0f172a;
  transition: background .2s, color .2s, box-shadow .2s;
  font-weight: 500;
  line-height: 1.3;
}

.kp-widget .wp-block-latest-posts__post-title:hover {
  background: #eef2ff;
  color: #0b1852;
  box-shadow: 0 6px 18px rgba(11,24,82,.12);
}

/* ====== CATEGORIAS ====== */
.kp-widget .wp-block-categories-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.kp-widget .wp-block-categories-list li a {
  display: flex;
  align-items: center;
  gap: .5rem;
  text-decoration: none;
  background: #f8fafc;
  border: 1px solid #eef2f7;
  color: #0f172a;
  padding: 10px 12px;
  border-radius: 12px;
  transition: background .2s, color .2s, box-shadow .2s;
}

.kp-widget .wp-block-categories-list li a:hover {
  background: #eef2ff;
  color: #0b1852;
  box-shadow: 0 6px 18px rgba(11,24,82,.12);
}

/* remove qualquer ícone antigo */
.kp-widget .wp-block-latest-posts__list li a::before,
.kp-widget .wp-block-categories-list li a::before {
  content: none !important;
}

/* ====== RESPONSIVO ====== */
@media (max-width: 768px) {
  aside {
    gap: 18px;
  }
  .kp-widget {
    padding: 14px;
  }
}


/* =====================================
   MENU RESPONSIVO + BOTÃO HAMBÚRGUER
   ===================================== */

/* ====== BOTÃO HAMBÚRGUER ====== */
.kp-burger {
  display: none; /* só aparece no mobile */
  position: relative;
  z-index: 1001;
  margin: 8px 16px;
  padding: 8px 12px;
  border: 0;
  background: transparent;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  color: #0b1852;
}

/* Ícone (as três barras) */
.kp-burger-icon {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}

.kp-burger-icon span {
  display: block;
  width: 24px;
  height: 2px;
  background: #0b1852; /* cor do tema */
  transition: transform .25s ease, opacity .25s ease;
}

/* Texto “Menu” */
.kp-burger-text {
  font-size: 16px;
  color: #0b1852;
  line-height: 1;
}

/* Animação do hambúrguer ao abrir */
body.kp-nav-open .kp-burger-icon span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
body.kp-nav-open .kp-burger-icon span:nth-child(2) {
  opacity: 0;
}
body.kp-nav-open .kp-burger-icon span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* ====== NAVEGAÇÃO PADRÃO (DESKTOP) ====== */
.kp-nav {
  display: block; /* sempre visível no desktop */
  background: #194a9d;
}

.kp-nav .kp-wrap {
  position: relative;
}

.kp-nav .kp-menu,
.kp-nav .menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 20px;
}

.kp-nav .menu > li {
  position: relative;
}

.kp-nav .menu > li > a {
  display: inline-block;
  padding: 12px 6px;
  color: #000;
  text-decoration: none;
}

/* Submenus no desktop */
.kp-nav .menu li ul.sub-menu {
  position: absolute;
  left: 0;
  top: 100%;
  background: #fff;
  border: 1px solid #eee;
  box-shadow: 0 8px 20px rgba(0,0,0,.06);
  padding: 8px 0;
  min-width: 220px;
  display: none;
  z-index: 1000;
}
.kp-nav .menu > li:hover > ul.sub-menu {
  display: block;
}

/* ====== MOBILE ====== */
@media (max-width: 768px) {

  /* Mostra o botão hambúrguer */
  .kp-burger {
    display: inline-flex;
  }

  /* Esconde o menu no mobile */
  .kp-nav {
    display: none;
  }

  /* Mostra o menu quando aberto */
  body.kp-nav-open .kp-nav {
    display: block;
  }

  /* Empilha itens verticalmente */
  .kp-nav .kp-wrap {
    padding: 0 16px 12px;
  }

  .kp-nav .kp-menu,
  .kp-nav .menu {
    flex-direction: column;
    gap: 0;
  }

  .kp-nav .menu > li > a {
    display: block;
    padding: 12px 8px;
    border-bottom: 1px solid #eee;
  }

  /* Submenus no mobile: colapsáveis */
  .kp-nav .menu li ul.sub-menu {
    position: static;
    border: 0;
    box-shadow: none;
    display: none;
    padding: 0 0 8px 12px;
  }

  .kp-nav .menu li.kp-sub-open > ul.sub-menu {
    display: block;
  }
}
/* Centralizar o logo no mobile */
@media (max-width: 768px) {
  .kp-header .kp-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }

  .kp-header .kp-logo {
    margin: 0 auto;
    text-align: center;
  }

  /* Opcional: deixar a busca abaixo e ocupar 100% */
  .kp-header .kp-search {
    width: 100%;
    margin-top: 10px;
  }

  .kp-header .kp-search form {
    display: flex;
    justify-content: center;
  }

  .kp-header .kp-search input[type="search"] {
    width: 80%;
  }
}
/* Centralizar LOGO no mobile quando o header usa .kp-grid3 */
@media (max-width: 768px) {
  /* transforma a grade em 1 coluna e centraliza tudo */
  .kp-header .kp-wrap.kp-grid3 {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: center; /* centraliza itens na coluna */
    align-items: center;
    row-gap: 10px;
  }

  /* some com a coluna vazia da esquerda */
  .kp-header .kp-wrap.kp-grid3 > div:first-child {
    display: none;
  }

  /* garante que o logo ocupe a linha inteira e fique ao centro */
  .kp-header .kp-logo {
    grid-column: 1 / -1;
    justify-self: center;
    text-align: center;
  }

  /* deixa a busca abaixo, centralizada e fluida */
  .kp-header .kp-search {
    grid-column: 1 / -1;
    width: 100%;
  }
  .kp-header .kp-search form {
    margin: 0 auto;
    max-width: 640px;
    display: flex;
  }
  .kp-header .kp-search input[type="search"] {
    flex: 1;
  }
}

/* segurança: logo não estoura e fica centrado */
.kp-header .kp-logo img,
.kp-header .custom-logo {
  display: block;
  max-width: 240px;
  width: 100%;
  height: auto;
  margin: 0 auto;
}
