/* ===========================================================
   Blog do Calcula Trabalhador — estilos próprios da seção.
   Usa os tokens (--azul, --verde, etc.) de style.css, já carregado.
   =========================================================== */

.blog-main { padding: clamp(1.5rem, 4vw, 2.5rem) 0 3rem; }
.blog-wrap { width: min(1180px, 92vw); margin-inline: auto; }

/* barra de progresso de leitura (só nos posts) — fica logo abaixo do header */
.read-progress { position: fixed; left: 0; right: 0; top: 74px; height: 3px; background: transparent; z-index: 49; pointer-events: none; }
.read-progress span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--azul), var(--verde)); border-radius: 0 3px 3px 0; transition: width .08s linear; }

/* ---- breadcrumb ---- */
.crumb { font-size: .82rem; color: var(--texto-mute); margin: 0 0 1.1rem; }
.crumb a { color: var(--texto-mute); text-decoration: none; }
.crumb a:hover { color: var(--azul); }
.crumb span { color: var(--cinza-300); margin: 0 .35rem; }

/* ---- hero do índice ---- */
.blog-top { display: grid; grid-template-columns: 1fr; gap: 1.5rem; align-items: start;
  border-bottom: 1px solid var(--borda); padding-bottom: 1.6rem; margin-bottom: 1.8rem; }
@media (min-width: 880px) { .blog-top { grid-template-columns: 1.2fr 1fr; } }
.blog-top h1 { font-family: Manrope, Inter, sans-serif; font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800; color: var(--azul); margin: 0 0 .6rem; line-height: 1.12; }
.blog-top p { color: var(--texto-suave); font-size: 1.02rem; margin: 0; max-width: 46ch; }
.trust { display: grid; grid-template-columns: 1fr 1fr; gap: .7rem; }
.trust__item { display: flex; gap: .6rem; align-items: flex-start;
  background: var(--cinza-50); border: 1px solid var(--borda); border-radius: var(--raio-sm); padding: .7rem .8rem; }
.trust__item .icon { width: 22px; height: 22px; color: var(--verde-texto); flex: none; }
.trust__item strong { display: block; font-size: .86rem; color: var(--grafite); }
.trust__item span { font-size: .76rem; color: var(--texto-mute); }

/* ---- layout índice (lista + aside) ---- */
.blog-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; }
@media (min-width: 920px) { .blog-grid { grid-template-columns: minmax(0,1fr) 312px; gap: 2.4rem; } }

/* ---- toolbar (busca + filtros) ---- */
.blog-tools { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; justify-content: space-between; margin-bottom: 1.3rem; }
.blog-search { position: relative; flex: 1 1 220px; }
.blog-search input { width: 100%; padding: .62rem .9rem .62rem 2.3rem; border: 1px solid var(--borda);
  border-radius: 999px; font: inherit; font-size: .92rem; background: var(--branco); color: var(--texto); }
.blog-search input:focus { outline: 2px solid var(--azul); outline-offset: 1px; border-color: var(--azul); }
.blog-search .icon { position: absolute; left: .8rem; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; color: var(--texto-mute); pointer-events: none; }
.filters { display: flex; flex-wrap: wrap; gap: .4rem; }
.filters button { border: 1px solid var(--borda); background: var(--branco); color: var(--texto-suave);
  font: inherit; font-size: .85rem; font-weight: 600; padding: .42rem .85rem; border-radius: 999px; cursor: pointer; transition: var(--t); }
.filters button:hover { border-color: var(--azul); color: var(--azul); }
.filters button[aria-pressed="true"] { background: var(--azul); border-color: var(--azul); color: #fff; }

/* ---- card de post ---- */
.bloglist { display: grid; grid-template-columns: 1fr; gap: 1.1rem; max-width: none; margin: 0; }
.blogcard { display: grid; grid-template-columns: 1fr; align-items: center; background: var(--branco);
  border: 1px solid var(--borda); border-radius: var(--raio); overflow: hidden; transition: var(--t); }
@media (min-width: 560px) { .blogcard { grid-template-columns: 220px 1fr; } }
.blogcard:hover { box-shadow: var(--sombra-md); transform: translateY(-2px); }
.blogcard__media { aspect-ratio: 16/10; background: var(--cinza-100); overflow: hidden; }
.blogcard__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blogcard__body { padding: 1.1rem 1.2rem 1.2rem; display: flex; flex-direction: column; }
.blogcard__meta { display: flex; gap: .6rem; align-items: center; font-size: .78rem; color: var(--texto-mute); margin-bottom: .5rem; }
.cat-chip { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em;
  padding: .18rem .55rem; border-radius: 999px; }
.cat-chip--clt { background: #EBF3FB; color: var(--azul); }
.cat-chip--mei { background: #E6F4EE; color: var(--verde-texto); }
.cat-chip--empresario { background: #F2EBFC; color: var(--roxo-texto); }
.cat-chip--autonomo { background: #E6F4F2; color: #0B6E63; }
.blogcard__body h2 { font-size: 1.12rem; font-weight: 800; color: var(--grafite); margin: 0 0 .35rem; line-height: 1.25; }
.blogcard__body h2 a { color: inherit; text-decoration: none; }
.blogcard__body h2 a:hover { color: var(--azul); }
.blogcard__body p { font-size: .9rem; color: var(--texto-suave); margin: 0 0 .8rem; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 4; line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.blogcard__more { margin-top: auto; font-size: .85rem; font-weight: 700; color: var(--verde-texto); text-decoration: none; display: inline-flex; align-items: center; gap: .3rem; }
.blogcard.is-hidden { display: none; }
.blog-empty { color: var(--texto-mute); padding: 2rem 0; text-align: center; }

/* ---- aside ---- */
.aside-card { background: var(--branco); border: 1px solid var(--borda); border-radius: var(--raio); padding: 1.2rem; margin-bottom: 1.3rem; }
.aside-card h3 { font-size: 1rem; font-weight: 800; color: var(--grafite); margin: 0 0 .9rem; }
.cat-list { list-style: none; margin: 0; padding: 0; }
.cat-list li { margin: 0; }
.cat-list a { display: flex; justify-content: space-between; align-items: center; gap: .5rem;
  padding: .55rem .2rem; border-bottom: 1px solid var(--cinza-100); text-decoration: none; color: var(--texto-suave); font-size: .92rem; font-weight: 600; }
.cat-list li:last-child a { border-bottom: 0; }
.cat-list a:hover { color: var(--azul); }
.cat-list .count { font-size: .78rem; color: var(--texto-mute); background: var(--cinza-100); border-radius: 999px; padding: .1rem .5rem; }
.cta-box { background: linear-gradient(160deg, #0F4C81, #0B3A63); color: #fff; border-radius: var(--raio); padding: 1.3rem; }
.cta-box h3 { color: #fff; font-size: 1.05rem; margin: 0 0 .5rem; }
.cta-box p { color: #DCE7F2; font-size: .86rem; margin: 0 0 1rem; line-height: 1.5; }
.cta-box .btn { width: 100%; justify-content: center; }
.cta-box ul { list-style: none; margin: .9rem 0 0; padding: 0; display: grid; gap: .35rem; }
.cta-box ul li { font-size: .78rem; color: #BFD9F2; display: flex; gap: .4rem; align-items: center; }
.cta-box ul .icon { width: 15px; height: 15px; color: #6FE0B0; }

/* =========================== POST =========================== */
.post-hero { border-bottom: 1px solid var(--borda); padding-bottom: 1.6rem; margin-bottom: 1.8rem; }
.post-hero__meta { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; font-size: .82rem; color: var(--texto-mute); margin-bottom: .8rem; }
.post-hero__meta .dot { color: var(--cinza-300); }
.post-hero h1 { font-family: Manrope, Inter, sans-serif; font-size: clamp(1.7rem, 3.6vw, 2.4rem);
  font-weight: 800; color: var(--azul); line-height: 1.15; margin: 0 0 .7rem; }
.post-hero__lead { font-size: 1.05rem; color: var(--texto-suave); line-height: 1.6; margin: 0 0 1.3rem; max-width: 70ch; }
.post-hero__media { border-radius: var(--raio); overflow: hidden; border: 1px solid var(--borda); }
.post-hero__media img { width: 100%; height: auto; display: block; }

.post-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; }
@media (min-width: 940px) { .post-grid { grid-template-columns: minmax(0,1fr) 300px; gap: 2.6rem; } }

/* tipografia do artigo */
.post-content { color: var(--texto-suave); font-size: 1.02rem; line-height: 1.75; }
.post-content h2 { font-family: Manrope, Inter, sans-serif; font-size: 1.4rem; font-weight: 800; color: var(--azul);
  margin: 2.2rem 0 .8rem; scroll-margin-top: 90px; }
.post-content h3 { font-size: 1.12rem; font-weight: 700; color: var(--grafite); margin: 1.6rem 0 .6rem; scroll-margin-top: 90px; }
.post-content p { margin: 0 0 1rem; }
.post-content ul, .post-content ol { margin: 0 0 1.1rem; padding-left: 1.3rem; }
.post-content li { margin-bottom: .5rem; }
.post-content a { color: var(--verde-texto); font-weight: 600; }
.post-content a.btn, .post-content a.btn:hover { color: #fff; font-weight: 700; }
.post-content strong { color: var(--grafite); }
.post-content figure { margin: 1.5rem 0; }
.post-content figure img { width: 100%; height: auto; display: block; }
.post-content figcaption { font-size: .8rem; color: var(--texto-mute); text-align: center; margin-top: .5rem; }

/* CTA de ferramenta no fim do artigo */
.tool-cta { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between;
  background: #E6F4EE; border: 1px solid #A8DCC5; border-radius: var(--raio); padding: 1.2rem 1.3rem; margin: 2rem 0 1rem; }
.tool-cta div { flex: 1 1 240px; }
.tool-cta strong { display: block; color: var(--verde-texto); font-size: 1.05rem; margin-bottom: .25rem; }
.tool-cta p { margin: 0; font-size: .9rem; color: var(--texto-suave); }

/* rodapé do artigo: feedback + share */
.post-foot { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between;
  border-top: 1px solid var(--borda); margin-top: 2rem; padding-top: 1.2rem; }
.share-row { display: flex; gap: .5rem; align-items: center; }
.share-row span { font-size: .85rem; color: var(--texto-mute); margin-right: .2rem; }
.share-row a, .share-row button { display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px;
  border-radius: 50%; border: 1px solid var(--borda); background: var(--branco); color: var(--texto-suave); cursor: pointer; transition: var(--t); }
.share-row a:hover, .share-row button:hover { border-color: var(--azul); color: var(--azul); }
.share-row .icon { width: 18px; height: 18px; }

/* aside do post */
.post-aside { align-self: start; }
@media (min-width: 940px) { .post-aside { position: sticky; top: 84px; } }
.toc { list-style: none; margin: 0; padding: 0; }
.toc li { margin: 0; }
.toc a { display: block; padding: .35rem 0 .35rem .8rem; border-left: 2px solid var(--borda);
  color: var(--texto-suave); text-decoration: none; font-size: .88rem; transition: var(--t); }
.toc a:hover { color: var(--azul); border-left-color: var(--azul); }
.related-tool { display: flex; gap: .8rem; align-items: flex-start; }
.related-tool__icon { width: 40px; height: 40px; flex: none; border-radius: 10px; background: #EBF3FB;
  display: flex; align-items: center; justify-content: center; }
.related-tool__icon .icon { width: 22px; height: 22px; color: var(--azul); }
.related-tool strong { display: block; font-size: .95rem; color: var(--grafite); margin-bottom: .2rem; }
.related-tool p { font-size: .82rem; color: var(--texto-mute); margin: 0 0 .7rem; line-height: 1.45; }
.rel-posts { list-style: none; margin: 0; padding: 0; }
.rel-posts li { padding: .7rem 0; border-bottom: 1px solid var(--cinza-100); }
.rel-posts li:last-child { border-bottom: 0; padding-bottom: 0; }
.rel-posts a { color: var(--grafite); text-decoration: none; font-size: .9rem; font-weight: 600; line-height: 1.35; }
.rel-posts a:hover { color: var(--azul); }
.rel-posts small { display: block; color: var(--texto-mute); font-size: .76rem; margin-top: .2rem; }

/* FAQ */
.post-faq { margin-top: 2.4rem; }
.post-faq h2 { font-family: Manrope, Inter, sans-serif; font-size: 1.4rem; font-weight: 800; color: var(--azul); margin: 0 0 1rem; }
.post-faq details { border: 1px solid var(--borda); border-radius: var(--raio-sm); padding: .9rem 1.1rem; margin-bottom: .7rem; background: var(--branco); }
.post-faq summary { font-weight: 700; color: var(--grafite); cursor: pointer; list-style: none; font-size: .98rem; }
.post-faq summary::-webkit-details-marker { display: none; }
.post-faq summary::after { content: "+"; float: right; color: var(--verde-texto); font-weight: 800; }
.post-faq details[open] summary::after { content: "–"; }
.post-faq details p { margin: .7rem 0 0; color: var(--texto-suave); font-size: .94rem; line-height: 1.6; }
