/*
Theme Name: Renovation Insights
Theme URI: https://findmyrenovation.com/insights/
Author: Click Circle LLC
Description: Find My Renovation's article section. Mirrors the static site's design tokens (navy + orange, Sora + Inter) so findmyrenovation.com/insights/ reads as part of the same site. Every article leads into the quote funnel its category names.
Version: 1.0.0
Requires at least: 6.4
Requires PHP: 8.1
License: Proprietary
Text Domain: renovation-insights
*/

/* ---------- Tokens: copied from findmyrenovation.com index.html ---------- */
:root{
  --bg:#F5F7FB;
  --bg-warm:#EEF2FA;
  --surface:#FFFFFF;
  --ink:#2E3A59;
  --ink-deep:#17213A;
  --body:#3D4763;          /* article body text: softer than --ink, far darker than --muted */
  --muted:#6B7280;
  --border:#E5E5E5;
  --accent:#E65100;
  --accent-dark:#B83D00;
  --accent-tint:#FDEAE0;
  --success:#16A34A;
  --success-bg:#EAF9EF;
  --shadow: 0 1px 2px rgba(46,58,89,0.06), 0 10px 28px rgba(46,58,89,0.08);
  --shadow-lg: 0 16px 36px rgba(23,33,58,0.16), 0 4px 14px rgba(23,33,58,0.08);
}
*{box-sizing:border-box;}
html,body{margin:0;padding:0;}
html{background:var(--bg); overflow-x:hidden;}
body{
  color:var(--ink);
  font-family:'Inter',-apple-system,BlinkMacSystemFont,sans-serif;
  -webkit-font-smoothing:antialiased;
  line-height:1.6;
  overflow-x:hidden;
  min-height:100vh; display:flex; flex-direction:column;
}
.site-main{flex:1 0 auto;}
h1,h2,h3,h4{
  font-family:'Sora',-apple-system,sans-serif;
  font-weight:700;
  letter-spacing:-0.01em;
  line-height:1.25;
  margin:0 0 14px;
  color:var(--ink);
}
p{margin:0;}
a{color:var(--accent-dark);}
img{max-width:100%; height:auto; display:block;}
button{font-family:inherit;}
.screen-reader-text{position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap;}
.skip-link:focus{position:fixed; top:8px; left:8px; width:auto; height:auto; clip:auto; z-index:100; background:#fff; padding:10px 14px; border-radius:8px;}

.wrap{max-width:1140px; margin:0 auto; padding:0 24px;}
.wrap-narrow{max-width:768px; margin-left:auto; margin-right:auto; padding-left:24px; padding-right:24px;}

.eyebrow{
  display:inline-block; font-size:11.5px; font-weight:700;
  letter-spacing:0.09em; text-transform:uppercase;
  color:var(--accent-dark); background:var(--accent-tint);
  padding:5px 12px; border-radius:99px; margin-bottom:16px;
}
.eyebrow a{color:inherit; text-decoration:none;}

/* ---------- Buttons (site) ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  border:none; border-radius:10px; font-weight:700; font-size:15.5px;
  cursor:pointer; text-decoration:none; white-space:nowrap;
  transition:transform .12s ease, box-shadow .12s ease;
}
.btn:hover{transform:translateY(-1px);}
.btn-primary{
  background:linear-gradient(180deg, #FF8F3F, var(--accent));
  color:#fff;
  padding:15px 26px;
  box-shadow:0 3px 0 var(--accent-dark), 0 6px 16px rgba(230,81,0,0.3);
}
.btn-primary.small{padding:11px 18px; font-size:13.5px;}
.btn svg{width:16px; height:16px; flex:none;}

/* ---------- Nav (site): logo + one button ---------- */
.nav{
  position:sticky; top:0; z-index:40;
  padding:14px 24px; background:#fff; border-bottom:1px solid var(--border);
}
.admin-bar .nav{top:32px;}
@media (max-width:782px){ .admin-bar .nav{top:46px;} }
.nav-inner{
  max-width:1140px; margin:0 auto; width:100%;
  display:flex; align-items:center; justify-content:space-between; gap:14px;
}
.brand{display:flex; align-items:center; flex:none;}
.brand img{height:28px; width:auto;}
@media (max-width:520px){
  .nav{padding:12px 16px;}
  .brand img{height:21px;}
  .nav .btn-primary.small{padding:9px 12px; font-size:12px;}
}
@media (max-width:380px){
  .brand img{height:18px;}
  .nav .btn-primary.small{padding:8px 10px; font-size:11px;}
  .nav .btn svg{display:none;}
}

/* ---------- Article list (home / archives): title row + tile grid ---------- */
.page-head{padding:44px 0 8px; text-align:center;}
.page-head h1{font-size:36px; margin:0 0 8px;}
.page-head .sub{margin:0 auto; color:var(--muted); font-size:16px; max-width:560px;}
.post-list{padding:30px 0 80px;}
.post-grid{
  list-style:none; margin:0; padding:0;
  display:grid; grid-template-columns:repeat(4, minmax(0, 1fr)); gap:22px;
}
@media (max-width:1024px){ .post-grid{grid-template-columns:repeat(3, minmax(0, 1fr));} }
@media (max-width:760px){ .post-grid{grid-template-columns:repeat(2, minmax(0, 1fr)); gap:16px;} }
@media (max-width:460px){ .post-grid{grid-template-columns:1fr;} }
.post-grid > li{display:flex;}
.tile{
  flex:1; background:var(--surface); border:1px solid var(--border); border-radius:16px;
  overflow:hidden; box-shadow:var(--shadow);
  display:flex; flex-direction:column;
  transition:transform .15s ease, box-shadow .15s ease;
}
.tile:hover{transform:translateY(-3px); box-shadow:var(--shadow-lg);}
.tile-img{display:block; aspect-ratio:4/3; overflow:hidden; background:var(--bg-warm);}
.tile-img img{width:100%; height:100%; object-fit:cover; display:block;}
.tile-ph{
  width:100%; height:100%; display:flex; align-items:center; justify-content:center;
  background:linear-gradient(160deg, var(--ink-deep), var(--ink));
}
.tile-ph img{width:60%; height:auto; opacity:0.9;}
.tile-body{padding:16px 18px 20px; display:flex; flex-direction:column; gap:6px;}
.tile-date{font-size:12px; font-weight:600; color:var(--muted);}
.tile h2{font-size:16.5px; line-height:1.35; margin:0;}
.tile h2 a{color:var(--ink); text-decoration:none;}
.tile h2 a:hover{color:var(--accent-dark);}
.empty{color:var(--muted); font-size:16px; text-align:center;}

.pagination{margin-top:36px; display:flex; justify-content:center;}
.pagination .nav-links{display:flex; gap:6px; flex-wrap:wrap;}
.pagination .page-numbers{
  display:inline-flex; align-items:center; justify-content:center;
  min-width:40px; height:40px; padding:0 12px; border-radius:10px;
  border:1px solid var(--border); background:var(--surface);
  color:var(--ink); font-weight:700; font-size:14px; text-decoration:none;
}
.pagination .page-numbers.current{background:var(--ink); color:#fff; border-color:var(--ink);}
.pagination .page-numbers.dots{border:none; background:transparent;}
.pagination a.page-numbers:hover{border-color:var(--accent); color:var(--accent-dark);}

/* ---------- Single article ----------
   Sized for readers who would rather not squint: 18px body, generous leading,
   body text well above the contrast minimum. */
.article{background:var(--surface); padding:44px 0 72px;}
.article-head h1{font-size:38px; line-height:1.18; margin:0 0 14px; color:var(--ink-deep);}
.standfirst{font-size:19px; line-height:1.55; color:var(--body); margin:0 0 16px;}
.article-meta{
  display:flex; flex-wrap:wrap; gap:6px 10px; align-items:center;
  font-size:13px; font-weight:600; color:var(--muted); margin:0 0 26px;
}
.article-meta a{color:var(--muted); text-decoration:underline;}
.article-meta a:hover{color:var(--ink);}
.article-hero{margin-top:0; margin-bottom:34px;}
.article-hero img{width:100%; aspect-ratio:16/9; object-fit:cover; border-radius:16px; box-shadow:var(--shadow);}
@media (max-width:640px){
  .article{padding:28px 0 56px;}
  .article-head h1{font-size:28px;}
  .standfirst{font-size:17px;}
  .article-hero img{border-radius:12px;}
}

.entry-content{font-size:18px; line-height:1.7; color:var(--body);}
.entry-content > *{margin-top:0;}
.entry-content h2{font-size:25px; line-height:1.28; margin:44px 0 14px; color:var(--ink-deep);}
.entry-content h2:first-child{margin-top:0;}
.entry-content h3{font-size:20px; margin:30px 0 10px;}
.entry-content h4{font-family:'Inter',sans-serif; font-weight:700; letter-spacing:0.07em; text-transform:uppercase; font-size:12px; margin:26px 0 8px;}
.entry-content p{margin:0 0 20px;}
.entry-content strong{color:var(--ink-deep);}
.entry-content a{color:var(--accent-dark); text-decoration:underline; text-underline-offset:2px;}
.entry-content a:hover{color:var(--accent);}
.entry-content ul, .entry-content ol{margin:0 0 22px; padding-left:24px;}
.entry-content li{margin-bottom:9px;}
.entry-content hr{border:none; border-top:1px solid var(--border); margin:40px 0;}
.entry-content blockquote{
  margin:28px 0; padding:18px 22px; border-left:4px solid var(--accent);
  background:var(--accent-tint); border-radius:12px; color:var(--ink-deep);
}
.entry-content blockquote p{margin:0;}
.entry-content blockquote p + p{margin-top:8px;}
.entry-content blockquote cite{display:block; margin-top:8px; font-size:13px; color:var(--muted); font-style:normal;}
.entry-content img{border-radius:12px;}
.entry-content figure{margin:28px 0;}
.entry-content figcaption{font-size:13px; color:var(--muted); margin-top:8px; text-align:center;}
.entry-content .wp-block-table{overflow-x:auto;}
.entry-content table{width:100%; border-collapse:collapse; margin:0 0 6px; font-size:16px; line-height:1.45;}
.entry-content th, .entry-content td{border:1px solid var(--border); padding:11px 13px; text-align:left; vertical-align:top;}
.entry-content th{background:var(--bg-warm); color:var(--ink-deep); font-weight:700;}
.entry-content code{background:var(--bg-warm); padding:2px 6px; border-radius:6px; font-size:0.92em;}
.entry-content .aligncenter{margin-left:auto; margin-right:auto;}
.entry-content .alignwide, .entry-content .alignfull{max-width:none;}
.entry-content .wp-block-image img{margin:0 auto;}
.entry-content > :last-child{margin-bottom:0;}
@media (max-width:640px){
  .entry-content{font-size:17px;}
  .entry-content h2{font-size:22px; margin-top:36px;}
}

/* "Good to know" box: a paragraph or group given the class "note" in the editor
   (Block > Advanced > Additional CSS class). */
.entry-content .note{
  background:var(--bg-warm); border-left:4px solid var(--ink); border-radius:12px;
  padding:16px 20px; margin:0 0 24px; font-size:16.5px; color:var(--ink);
}
.entry-content .note > :last-child{margin-bottom:0;}
/* Sources / fine print at the foot of an article: class "sources". */
.entry-content .sources{font-size:14px; line-height:1.6; color:var(--muted); margin-top:36px; padding-top:18px; border-top:1px solid var(--border);}
.entry-content .sources a{color:var(--muted);}

/* [quote_cta]: the quote button inside an article */
.quote-cta{
  display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:16px 24px;
  background:var(--accent-tint); border:1px solid #F7CDB6; border-radius:16px;
  padding:22px 24px; margin:32px 0;
}
.quote-cta__copy{flex:1 1 300px;}
.entry-content .quote-cta__title{font-family:'Sora',sans-serif; font-weight:700; font-size:19px; line-height:1.3; color:var(--ink-deep); margin:0 0 4px;}
.entry-content .quote-cta__text{font-size:15px; line-height:1.5; color:var(--body); margin:0;}
.entry-content .quote-cta .btn, .entry-content .quote-cta-button .btn{color:#fff; text-decoration:none; flex:none;}
.quote-cta-button{margin:28px 0;}
@media (max-width:640px){
  .quote-cta{padding:20px;}
  .quote-cta .btn, .quote-cta-button .btn{width:100%; white-space:normal; text-align:center;}
}

/* Closing band into the funnel (the point of the whole section) */
.closing-cta{margin-top:48px;}
.closing-cta__inner{
  background:linear-gradient(160deg, var(--ink-deep), var(--ink)); color:#fff;
  border-radius:18px; padding:40px 32px; text-align:center; box-shadow:var(--shadow-lg);
}
.closing-cta h2{color:#fff; font-size:27px; margin:0 0 10px;}
.closing-cta p{color:rgba(255,255,255,0.8); font-size:16px; line-height:1.6; max-width:520px; margin:0 auto 24px;}
.closing-cta__trust{
  list-style:none; margin:22px 0 0; padding:0;
  display:flex; flex-wrap:wrap; justify-content:center; gap:8px 22px;
  font-size:13px; font-weight:600; color:rgba(255,255,255,0.85);
}
.closing-cta__trust li::before{content:'\2713'; color:#FF8A3D; font-weight:800; margin-right:7px;}
@media (max-width:640px){
  .closing-cta__inner{padding:30px 20px;}
  .closing-cta h2{font-size:23px;}
  .closing-cta .btn{width:100%; white-space:normal;}
}

.entry-footer{
  margin-top:36px;
  display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:14px;
}
.entry-footer .tags{display:flex; flex-wrap:wrap; gap:8px;}
.entry-footer .tags a{
  font-size:12px; font-weight:700; color:var(--accent-dark); background:var(--accent-tint);
  padding:4px 10px; border-radius:99px; text-decoration:none;
}
.back-link{display:inline-flex; align-items:center; gap:6px; color:var(--ink); font-weight:700; font-size:14px; text-decoration:none;}
.back-link svg{width:15px; height:15px;}
.back-link:hover{text-decoration:underline;}

/* Search (404 page) */
.search-form{display:flex; gap:8px; max-width:420px; margin-top:20px;}
.search-form input[type=search]{
  flex:1; font:inherit; padding:11px 14px; border:1px solid var(--border); border-radius:10px; background:var(--surface);
}
.search-form button{
  font:inherit; font-weight:700; padding:11px 16px; border:none; border-radius:10px;
  background:var(--ink); color:#fff; cursor:pointer;
}

/* ---------- Footer (site) ---------- */
.site-footer{background:var(--ink-deep); color:rgba(255,255,255,0.7); padding:46px 0 26px;}
.footer-top{
  display:flex; justify-content:space-between; align-items:flex-start;
  flex-wrap:wrap; gap:24px; padding-bottom:28px;
  border-bottom:1px solid rgba(255,255,255,0.1);
}
.footer-brand img{height:26px; display:block; margin-bottom:14px;}
.footer-brand p{font-size:13px; color:rgba(255,255,255,0.55); max-width:280px; line-height:1.6;}
.footer-cols{display:flex; gap:56px; flex-wrap:wrap;}
.footer-col h4{
  font-family:'Inter',sans-serif; font-size:11.5px; font-weight:700; letter-spacing:0.08em; text-transform:uppercase;
  color:rgba(255,255,255,0.45); margin:0 0 14px;
}
.footer-col a{display:block; font-size:13.5px; color:rgba(255,255,255,0.75); text-decoration:none; margin-bottom:10px;}
.footer-col a:hover{color:#fff;}
.footer-bottom{
  display:flex; justify-content:space-between; flex-wrap:wrap; gap:10px;
  padding-top:20px; font-size:12px; color:rgba(255,255,255,0.4);
}
.footer-links{display:flex; flex-wrap:wrap; gap:6px 16px;}
.footer-links a{color:rgba(255,255,255,0.6); text-decoration:underline; white-space:nowrap;}
.footer-disclaimer{
  font-size:11px; line-height:1.6; color:rgba(255,255,255,0.35);
  margin-top:22px; padding-top:18px; border-top:1px solid rgba(255,255,255,0.08);
}
@media (max-width:640px){ .footer-top{gap:28px;} .footer-cols{gap:32px;} }
