/*
Theme Name: Irmãos Resende Blog
Theme URI: https://irmaosresende.com.br/
Author: Irmãos Resende Contabilidade
Description: Tema editorial leve e responsivo para o blog da Irmãos Resende Contabilidade.
Version: 1.0.1
Requires at least: 6.5
Requires PHP: 8.0
Text Domain: irmaos-resende-blog
*/

:root {
  --blue-950: #041e46;
  --blue-900: #083f8c;
  --blue-800: #0a51ad;
  --blue-100: #dce9f8;
  --blue-50: #f3f7fc;
  --ink: #14233a;
  --muted: #5f6f84;
  --line: #dbe3ed;
  --green: #147a65;
  --white: #fff;
  --radius: 18px;
  --shadow: 0 18px 55px rgba(5, 35, 76, .1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--blue-50); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.65; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
.screen-reader-text { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.container { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }
.skip-link { position: fixed; z-index: 1000; top: -100px; left: 20px; padding: 10px 14px; color: var(--white); background: var(--blue-950); border-radius: 8px; }
.skip-link:focus { top: 15px; }

.site-header { position: sticky; z-index: 50; top: 0; background: rgba(255,255,255,.97); border-bottom: 1px solid var(--line); backdrop-filter: blur(12px); }
.header-inner { display: flex; min-height: 78px; align-items: center; justify-content: space-between; gap: 28px; }
.brand img { width: 225px; }
.main-nav { display: flex; align-items: center; gap: 24px; color: #35455e; font-size: .88rem; font-weight: 700; }
.main-nav a:hover { color: var(--blue-800); }
.nav-cta { padding: 10px 16px; color: var(--white) !important; background: var(--blue-900); border-radius: 9px; }
.menu-toggle { display: none; width: 42px; height: 42px; padding: 9px; background: transparent; border: 1px solid var(--line); border-radius: 9px; }
.menu-toggle span { display: block; height: 2px; margin: 5px 0; background: var(--blue-950); }

.blog-hero { padding: 78px 0 70px; color: var(--white); background: linear-gradient(135deg, var(--blue-950), #073a7c); }
.eyebrow { display: block; margin-bottom: 10px; color: #9fc2ec; font-size: .75rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.blog-hero h1 { max-width: 850px; margin: 0; font: 700 clamp(2.7rem, 6vw, 5rem)/1.04 Georgia, serif; letter-spacing: -.04em; }
.blog-hero p { max-width: 700px; margin: 20px 0 0; color: #c3d1e4; font-size: 1.08rem; }

.posts-section { padding: 72px 0 100px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 30px; }
.section-heading h2 { margin: 0; color: var(--blue-950); font: 700 clamp(2rem, 4vw, 3.2rem)/1.1 Georgia, serif; }
.posts-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.post-card { overflow: hidden; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 30px rgba(5,35,76,.05); transition: transform .25s, box-shadow .25s; }
.post-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.post-card-cover { display: block; aspect-ratio: 3 / 2; overflow: hidden; background: var(--blue-900); }
.post-card-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s; }
.post-card:hover .post-card-cover img { transform: scale(1.03); }
.post-card-placeholder { display: grid; height: 100%; place-items: center; color: #b9d3f2; font-size: 2.5rem; background: linear-gradient(135deg, var(--blue-800), var(--blue-950)); }
.post-card-body { padding: 25px; }
.post-category { display: inline-flex; margin-bottom: 11px; padding: 5px 9px; color: var(--blue-900); background: var(--blue-100); border-radius: 999px; font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.post-meta { display: flex; flex-wrap: wrap; gap: 14px; color: var(--muted); font-size: .72rem; }
.post-card h2 { margin: 12px 0 10px; color: var(--blue-950); font-size: 1.25rem; line-height: 1.3; }
.post-card h2 a:hover { color: var(--blue-800); }
.post-card p { margin: 0 0 17px; color: var(--muted); font-size: .88rem; }
.text-link { color: var(--blue-800); font-weight: 800; }
.pagination { margin-top: 42px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.pagination .page-numbers { min-width: 40px; padding: 8px 12px; text-align: center; background: var(--white); border: 1px solid var(--line); border-radius: 8px; }
.pagination .current { color: var(--white); background: var(--blue-900); border-color: var(--blue-900); }

.article-hero { padding: 54px 0 50px; color: var(--white); background: linear-gradient(135deg, var(--blue-950), #073a7c); }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; color: #aebfd5; font-size: .76rem; }
.breadcrumbs a:hover { color: var(--white); }
.article-hero h1 { max-width: 1080px; margin: 10px 0 18px; font: 700 clamp(2.25rem, 4vw, 3.75rem)/1.08 Georgia, serif; letter-spacing: -.035em; text-wrap: balance; }
.article-lead { max-width: 820px; margin: 0; color: #c8d5e6; font-size: 1.12rem; }
.article-meta { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 25px; color: #aebfd5; font-size: .76rem; }
.article-shell { display: grid; grid-template-columns: minmax(0, 790px) 280px; justify-content: center; gap: 58px; padding: 62px 0 100px; }
.article-main { min-width: 0; }
.featured-image { overflow: hidden; margin-bottom: 28px; background: #dfe9f5; border-radius: var(--radius); box-shadow: var(--shadow); }
.featured-image img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.article-content { padding: clamp(28px, 5vw, 52px); background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.article-content > *:first-child { margin-top: 0; }
.article-content p, .article-content li { color: #35455e; }
.article-content p { margin: 0 0 1.25em; }
.article-content h2 { margin: 2em 0 .55em; color: var(--blue-950); font: 700 1.8rem/1.25 Georgia, serif; }
.article-content h3 { margin: 1.6em 0 .45em; color: var(--blue-950); font-size: 1.2rem; }
.article-content ul, .article-content ol { padding-left: 1.35em; }
.article-content a { color: var(--blue-800); text-decoration: underline; text-underline-offset: 3px; }
.article-content hr { height: 1px; margin: 38px 0; background: var(--line); border: 0; }
.article-aside { align-self: start; position: sticky; top: 104px; }
.aside-card { padding: 26px; color: var(--white); background: var(--blue-950); border-radius: var(--radius); }
.aside-card h2 { margin: 0 0 10px; font: 700 1.4rem/1.2 Georgia, serif; }
.aside-card p { color: #becce0; font-size: .86rem; }
.aside-card a { display: block; margin-top: 17px; padding: 11px 14px; color: var(--white); background: var(--green); border-radius: 9px; text-align: center; font-weight: 800; }

.empty-state { padding: 45px; background: var(--white); border: 1px dashed #b8c7d8; border-radius: var(--radius); text-align: center; }
.site-footer { padding: 64px 0 0; color: #c8d3e3; background: var(--blue-950); }
.footer-grid { display: grid; grid-template-columns: 1.5fr repeat(2, 1fr); gap: 60px; padding-bottom: 48px; }
.footer-brand img { width: 225px; padding: 8px 12px; background: var(--white); border-radius: 10px; }
.footer-brand p { max-width: 390px; }
.site-footer h2 { color: var(--white); font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; }
.site-footer a { display: block; margin: 9px 0; color: #aebdd2; font-size: .85rem; }
.site-footer a:hover { color: var(--white); }
.footer-bottom { display: flex; justify-content: space-between; gap: 20px; padding: 18px 0; border-top: 1px solid rgba(255,255,255,.11); color: #8fa4c2; font-size: .75rem; }

@media (max-width: 900px) {
  .menu-toggle { display: block; }
  .main-nav { position: absolute; top: 78px; right: 20px; left: 20px; display: none; padding: 20px; background: var(--white); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); }
  .main-nav.open { display: grid; }
  .posts-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-shell { grid-template-columns: 1fr; }
  .article-aside { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 620px) {
  .container { width: min(100% - 28px, 1180px); }
  .brand img { width: 190px; }
  .blog-hero, .article-hero { padding: 50px 0 46px; }
  .posts-section { padding: 48px 0 70px; }
  .posts-grid { grid-template-columns: 1fr; }
  .section-heading { display: block; }
  .article-shell { padding: 35px 0 70px; }
  .article-content { padding: 25px 21px; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .footer-brand { grid-column: auto; }
  .footer-bottom { display: block; }
}
