/*
Theme Name: Sanders Civil Rights Custom
Theme URI: https://thesandersfirmpc.com/
Author: The Sanders Firm, P.C.
Description: Custom Classic Editor-friendly WordPress theme for The Sanders Firm, P.C. civil-rights website.
Version: 0.2.8
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 8.0
Text Domain: sanders-civil-rights
*/

:root {
  --tsf-burgundy: #7F2E33;
  --tsf-burgundy-dark: #64242A;
  --tsf-slate: #4B555C;
  --tsf-ink: #202326;
  --tsf-text: #4D5256;
  --tsf-muted: #70777C;
  --tsf-line: #D9DDDF;
  --tsf-soft-line: #ECEEEF;
  --tsf-white: #FFFFFF;
  --tsf-off-white: #F8F8F6;
  --tsf-pale: #F3F4F4;
  --tsf-serif: Georgia, "Times New Roman", serif;
  --tsf-sans: Arial, Helvetica, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin:0; background:var(--tsf-white); color:var(--tsf-ink); font-family:var(--tsf-sans); text-rendering:optimizeLegibility; }
a { color:var(--tsf-burgundy); }
.wrap { max-width:1180px; margin:0 auto; padding-left:30px; padding-right:30px; }
.screen-reader-text { position:absolute; left:-9999px; }
.site-header { background:var(--tsf-white); border-bottom:1px solid var(--tsf-line); }
.header-inner { min-height:96px; display:grid; grid-template-columns:310px minmax(0,1fr); align-items:center; gap:44px; }
.site-logo img { width:290px; max-width:100%; height:auto; display:block; }
.site-nav { display:flex; align-items:center; justify-content:flex-end; gap:30px; font-size:14px; color:var(--tsf-ink); font-weight:700; white-space:nowrap; }
.site-nav a { color:var(--tsf-ink); text-decoration:none; }
.site-nav .consultation-link { background:var(--tsf-burgundy); color:var(--tsf-white); padding:13px 20px; border-radius:4px; font-weight:900; }
.mobile-menu-toggle { display:none; border:0; background:transparent; color:var(--tsf-burgundy); font-size:30px; line-height:1; }
.home-hero { position:relative; min-height:650px; overflow:hidden; background:var(--tsf-white); }
.hero-grid { display:grid; grid-template-columns:46% 54%; min-height:650px; }
.hero-copy { display:flex; align-items:center; position:relative; z-index:2; }
.hero-copy-inner { max-width:500px; margin-left:max(30px, calc((100vw - 1180px)/2 + 30px)); padding-right:46px; }
.hero-title { font-family:var(--tsf-serif); font-size:56px; line-height:1.06; font-weight:500; margin:0; letter-spacing:-.7px; }
.hero-title span { color:var(--tsf-burgundy); display:block; }
.hero-rule { width:58px; height:3px; background:var(--tsf-burgundy); margin:28px 0; }
.hero-subtitle { color:var(--tsf-ink); font-size:19px; line-height:1.75; margin:0; }
.hero-button { display:inline-flex; align-items:center; gap:12px; background:var(--tsf-burgundy); color:var(--tsf-white); text-decoration:none; margin-top:34px; padding:15px 22px; border-radius:4px; font-size:14px; font-weight:900; letter-spacing:.4px; text-transform:uppercase; }
.hero-image { min-height:650px; position:relative; background-size:cover; background-position:center center; overflow:hidden; }
.hero-image::before { content:""; position:absolute; inset:0; background:linear-gradient(90deg, rgba(255,255,255,.88) 0%, rgba(255,255,255,.48) 20%, rgba(255,255,255,0) 38%); pointer-events:none; }
.practice-section { background:var(--tsf-white); padding:78px 0 90px; border-top:1px solid var(--tsf-line); }
.section-kicker { text-align:center; color:var(--tsf-burgundy); font-size:13px; letter-spacing:4px; text-transform:uppercase; font-weight:900; }
.section-kicker::after { content:""; display:block; width:42px; height:2px; background:var(--tsf-burgundy); margin:13px auto 0; }
.section-title { text-align:center; font-family:var(--tsf-serif); font-size:32px; line-height:1.2; font-weight:500; letter-spacing:.4px; margin:26px 0 0; }
.practice-grid { display:grid; grid-template-columns:repeat(4, 1fr); gap:0; margin-top:58px; }
.practice-card { text-align:center; padding:0 34px; border-left:1px solid var(--tsf-line); }
.practice-card:first-child { border-left:0; }
.practice-icon { color:var(--tsf-burgundy); font-size:52px; height:70px; display:flex; align-items:center; justify-content:center; margin-bottom:18px; }
.practice-card h3 { font-family:var(--tsf-serif); font-size:20px; line-height:1.25; text-transform:uppercase; font-weight:600; margin:0; }
.practice-card p { color:var(--tsf-text); line-height:1.65; font-size:15px; margin:18px 0 0; }
.cred-band { background:linear-gradient(90deg, var(--tsf-burgundy-dark), var(--tsf-burgundy)); color:var(--tsf-white); padding:54px 0; position:relative; overflow:hidden; }
.cred-inner { position:relative; display:grid; grid-template-columns:1fr 1fr; gap:58px; align-items:center; }
.cred-title { font-family:var(--tsf-serif); font-size:32px; line-height:1.25; font-weight:500; border-left:3px solid rgba(255,255,255,.65); padding-left:28px; }
.cred-text { font-family:var(--tsf-serif); font-size:23px; line-height:1.55; color:rgba(255,255,255,.92); }
.insights-section { background:var(--tsf-off-white); padding:78px 0 82px; }
.insights-intro { max-width:720px; margin:20px auto 0; text-align:center; color:var(--tsf-text); font-size:17px; line-height:1.7; }
.insight-grid { display:grid; grid-template-columns:repeat(3, 1fr); gap:28px; margin-top:46px; }
.insight-card { background:var(--tsf-white); border:1px solid var(--tsf-line); border-radius:8px; overflow:hidden; box-shadow:0 12px 32px rgba(0,0,0,.05); }
.insight-card img { width:100%; height:165px; object-fit:cover; display:block; border-bottom:1px solid var(--tsf-line); }
.insight-body { padding:24px; }
.insight-meta { display:flex; justify-content:space-between; gap:14px; font-size:11px; text-transform:uppercase; letter-spacing:.7px; }
.insight-meta span { color:var(--tsf-burgundy); font-weight:900; }
.insight-meta em { color:var(--tsf-muted); font-style:normal; }
.insight-card h3 { font-family:var(--tsf-serif); font-size:21px; line-height:1.3; font-weight:500; margin:12px 0 0; }
.insight-card p { color:var(--tsf-text); line-height:1.65; font-size:14px; margin:14px 0 0; }
.insight-card a { color:var(--tsf-burgundy); text-decoration:none; font-weight:900; display:inline-flex; gap:8px; margin-top:18px; font-size:13px; }
.view-all { text-align:center; margin-top:42px; }
.view-all a { display:inline-flex; align-items:center; gap:12px; background:var(--tsf-burgundy); color:var(--tsf-white); padding:14px 22px; border-radius:4px; text-decoration:none; font-weight:900; text-transform:uppercase; font-size:13px; letter-spacing:.8px; }
.next-step { background:var(--tsf-white); border-top:1px solid var(--tsf-line); padding:42px 0; }
.next-inner { display:grid; grid-template-columns:auto 1fr auto; gap:24px; align-items:center; }
.calendar-icon { width:54px; height:54px; border:2px solid var(--tsf-burgundy); color:var(--tsf-burgundy); display:flex; align-items:center; justify-content:center; border-radius:8px; font-size:28px; }
.next-step h2 { font-family:var(--tsf-serif); font-size:25px; font-weight:500; margin:0; }
.next-step p { color:var(--tsf-text); margin:8px 0 0; line-height:1.55; }
.outline-button { border:1px solid var(--tsf-burgundy); color:var(--tsf-burgundy); padding:14px 22px; border-radius:4px; text-decoration:none; font-weight:900; text-transform:uppercase; font-size:13px; }
.site-footer { background:#EEF0F1; color:var(--tsf-ink); border-top:1px solid var(--tsf-line); }
.footer-inner { padding:48px 0 30px; }
.footer-grid { display:grid; grid-template-columns:1.2fr 1fr 1fr; gap:60px; align-items:start; }
.footer-logo img { width:250px; max-width:100%; height:auto; }
.site-footer p { color:var(--tsf-text); line-height:1.7; font-size:14px; max-width:360px; margin:20px 0 0; }
.social-links { display:flex; gap:20px; margin-top:24px; }
.social-links a { width:32px; height:32px; border-radius:4px; border:1px solid var(--tsf-slate); display:flex; align-items:center; justify-content:center; color:var(--tsf-slate); text-decoration:none; font-weight:900; }
.footer-office h3 { color:var(--tsf-burgundy); font-family:var(--tsf-serif); font-size:17px; letter-spacing:1.2px; text-transform:uppercase; margin:0 0 16px; }
.footer-office p { margin:0; color:var(--tsf-text); font-size:17px; line-height:1.75; }
.footer-notice { border-top:1px solid var(--tsf-line); margin-top:38px; padding-top:18px; color:var(--tsf-text); font-size:13px; line-height:1.6; }
.footer-notice strong { color:var(--tsf-ink); }
.footer-bottom { border-top:1px solid var(--tsf-line); margin-top:18px; padding-top:20px; display:flex; justify-content:space-between; gap:24px; color:var(--tsf-text); font-size:13px; }
.back-top { position:fixed; right:22px; bottom:22px; width:42px; height:42px; border-radius:999px; background:var(--tsf-slate); color:var(--tsf-white); display:flex; align-items:center; justify-content:center; text-decoration:none; font-weight:900; box-shadow:0 10px 26px rgba(0,0,0,.18); }
.page-content, .single-content { padding:70px 0; }
.content-narrow { max-width:850px; margin:0 auto; padding:0 30px; }
.content-narrow h1 { font-family:var(--tsf-serif); font-size:48px; line-height:1.1; font-weight:500; }
.content-narrow p, .content-narrow li { font-size:18px; line-height:1.8; color:var(--tsf-text); }
@media (max-width:980px) {
  .header-inner { grid-template-columns:1fr auto; min-height:86px; }
  .site-nav a:not(.consultation-link), .site-nav .consultation-link { display:none; }
  .mobile-menu-toggle { display:block; }
  .hero-grid { grid-template-columns:1fr; min-height:auto; }
  .hero-copy-inner { margin:0 auto; max-width:760px; padding:70px 30px 44px; }
  .hero-image { min-height:430px; }
  .practice-grid { grid-template-columns:repeat(2, 1fr); row-gap:48px; }
  .practice-card:nth-child(3) { border-left:0; }
  .cred-inner, .footer-grid, .insight-grid { grid-template-columns:1fr; }
  .next-inner { grid-template-columns:auto 1fr; }
  .next-inner .outline-button { grid-column:2; justify-self:start; }
}
@media (max-width:640px) {
  .wrap { padding-left:22px; padding-right:22px; }
  .header-inner { min-height:78px; }
  .site-logo img { width:230px; }
  .hero-title { font-size:40px; }
  .hero-subtitle { font-size:17px; }
  .hero-copy-inner { padding:54px 22px 36px; }
  .hero-button { width:auto; max-width:max-content; padding:14px 18px; }
  .hero-image { min-height:300px; }
  .practice { padding:58px 0 64px; }
  .section-title { font-size:25px; }
  .practice-grid { grid-template-columns:1fr; margin-top:42px; }
  .practice-card { border-left:0; border-top:1px solid var(--tsf-line); padding:32px 18px 0; }
  .practice-card:first-child { border-top:0; }
  .cred-inner { gap:28px; }
  .cred-title { font-size:26px; }
  .cred-text { font-size:19px; }
  .insights-section { padding:58px 0 62px; }
  .next-inner { grid-template-columns:1fr; }
  .next-inner .outline-button { grid-column:auto; }
  .footer-grid { gap:34px; }
  .footer-bottom { flex-direction:column; }
  .back-top { width:38px; height:38px; right:16px; bottom:16px; }
}


/* =========================================================
   TSF Corrected Header, Navigation, and Responsive Menu
   Version 0.1.1
   ========================================================= */

.site-nav ul,
.site-nav .primary-menu,
.site-nav .menu {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 30px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav li {
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
  line-height: 1;
}

.site-nav li::marker {
  content: "";
  display: none;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  color: var(--tsf-ink);
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
}

.site-nav .menu-item-has-children > a::after {
  content: "▾";
  display: inline-block;
  margin-left: 6px;
  color: var(--tsf-burgundy);
  font-size: 10px;
  line-height: 1;
}

.site-nav .sub-menu {
  position: absolute;
  top: calc(100% + 18px);
  left: 0;
  z-index: 9999;
  display: block;
  min-width: 220px;
  list-style: none;
  margin: 0;
  padding: 10px 0;
  background: #fff;
  border: 1px solid var(--tsf-line);
  border-radius: 6px;
  box-shadow: 0 14px 35px rgba(0,0,0,.12);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}

.site-nav li:hover > .sub-menu,
.site-nav li:focus-within > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.site-nav .sub-menu li {
  display: block;
  width: 100%;
}

.site-nav .sub-menu a {
  display: block;
  width: 100%;
  padding: 12px 18px;
  color: var(--tsf-ink);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.site-nav .sub-menu a:hover,
.site-nav .sub-menu a:focus {
  background: var(--tsf-off-white);
  color: var(--tsf-burgundy);
}

.practice-card {
  cursor: default;
}

@media (max-width: 1180px) {
  .site-header {
    position: relative;
    z-index: 9999;
    background: #fff;
  }

  .header-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    min-height: 82px;
  }

  .site-logo {
    display: block;
    min-width: 0;
    max-width: 250px;
    overflow: visible;
  }

  .site-logo a,
  .site-logo img,
  .custom-logo {
    display: block;
  }

  .site-logo img,
  .custom-logo {
    width: auto;
    max-width: 235px;
    max-height: 54px;
    height: auto;
  }

  .site-nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    position: relative;
    width: auto;
    min-width: 44px;
    gap: 0;
  }

  .site-nav .consultation-link {
    display: none;
  }

  .site-nav > ul,
  .site-nav .primary-menu,
  .site-nav .menu {
    display: none;
    list-style: none;
    margin: 0;
    padding: 0;
  }

  .site-nav li,
  .site-header li {
    list-style: none;
  }

  .site-nav li::marker,
  .site-header li::marker {
    content: "";
    display: none;
  }

  .mobile-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    margin: 0;
    border: 1px solid var(--tsf-line);
    border-radius: 4px;
    background: #fff;
    color: var(--tsf-burgundy);
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    z-index: 10002;
  }

  .site-nav.is-open > ul,
  .site-nav.is-open .primary-menu,
  .site-nav.is-open .menu {
    display: flex;
    position: absolute;
    top: 58px;
    right: 0;
    width: min(360px, calc(100vw - 44px));
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    margin: 0;
    padding: 10px 0;
    list-style: none;
    background: #fff;
    border: 1px solid var(--tsf-line);
    border-radius: 6px;
    box-shadow: 0 16px 36px rgba(0,0,0,.16);
    z-index: 10000;
  }

  .site-nav.is-open li {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .site-nav.is-open a {
    display: block;
    width: 100%;
    padding: 14px 18px;
    color: var(--tsf-ink);
    text-decoration: none;
    font-size: 15px;
    line-height: 1.35;
    font-weight: 800;
    border-bottom: 1px solid var(--tsf-soft-line);
    background: #fff;
  }

  .site-nav.is-open li:last-child > a {
    border-bottom: 0;
  }

  .site-nav.is-open .sub-menu {
    position: static;
    display: block;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: 0;
    border-radius: 0;
    min-width: 0;
    width: 100%;
    margin: 0;
    padding: 0;
    background: var(--tsf-off-white);
  }

  .site-nav.is-open .sub-menu a {
    padding-left: 34px;
    font-size: 14px;
    color: var(--tsf-text);
    background: var(--tsf-off-white);
  }

  .site-nav.is-open .menu-item-has-children > a::after {
    content: "▾";
    float: right;
    color: var(--tsf-burgundy);
  }

  .hero-grid {
    grid-template-columns: 50% 50%;
  }

  .hero-copy-inner {
    padding-right: 34px;
  }

  .hero-image {
    background-position: 44% center;
  }
}

@media (max-width: 980px) {
  .hero-grid {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .hero-copy-inner {
    margin: 0 auto;
    max-width: 760px;
    padding: 70px 30px 44px;
  }

  .hero-image {
    min-height: 430px;
    background-position: center center;
  }
}

@media (max-width: 640px) {
  .site-logo {
    max-width: 220px;
  }

  .site-logo img,
  .custom-logo {
    max-width: 205px;
    max-height: 50px;
  }

  .header-inner {
    min-height: 78px;
    gap: 12px;
  }

  .site-nav.is-open > ul,
  .site-nav.is-open .primary-menu,
  .site-nav.is-open .menu {
    width: min(330px, calc(100vw - 44px));
  }
}


/* =========================================================
   TSF Targeted Responsive Refinements
   Version 0.1.2
   ========================================================= */

/* Hard-hide the separate header consultation button on tablet/mobile.
   It remains available through Contact / Schedule paths, but does not crowd the hamburger header. */
@media (max-width: 1180px) {
  .site-header .consultation-link,
  .site-header a.consultation-link,
  .site-nav .consultation-link {
    display: none !important;
    visibility: hidden !important;
    width: 0 !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
  }

  .site-nav {
    flex: 0 0 auto !important;
    min-width: 44px !important;
  }

  .mobile-menu-toggle {
    display: inline-flex !important;
    flex: 0 0 44px !important;
  }
}

/* Blog / Insights images: make cards more usable in phone landscape and tablet views. */
@media (min-width: 641px) and (max-width: 1180px) {
  .insight-card img {
    height: 260px !important;
    object-fit: contain !important;
    background: var(--tsf-pale) !important;
  }

  .insight-grid {
    gap: 30px !important;
  }
}

@media (max-width: 640px) {
  .insight-card img {
    height: 220px !important;
    object-fit: contain !important;
    background: var(--tsf-pale) !important;
  }
}

/* Footer breathing room for iPhone landscape and iPad views. */
@media (min-width: 641px) and (max-width: 1180px) {
  .site-footer .wrap,
  .footer-inner {
    padding-left: 44px !important;
    padding-right: 44px !important;
  }

  .footer-grid {
    gap: 34px !important;
  }

  .footer-logo,
  .footer-office {
    text-align: left !important;
  }
}

@media (max-width: 640px) {
  .site-footer .wrap,
  .footer-inner {
    padding-left: 24px !important;
    padding-right: 24px !important;
  }
}


/* =========================================================
   TSF Hero Responsive Correction
   Version 0.1.3
   Purpose: preserve full hero scene on iPhone and iPad views.
   ========================================================= */

/* Tablet and small laptop range: stack hero and use the mobile-safe image field. */
@media (max-width: 1180px) {
  .hero-grid {
    grid-template-columns: 1fr !important;
    min-height: auto !important;
  }

  .hero-copy-inner {
    margin: 0 auto !important;
    max-width: 760px !important;
    padding: 64px 30px 40px !important;
  }

  .hero-image {
    background-image: var(--hero-mobile-image) !important;
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center center !important;
    background-color: var(--tsf-off-white) !important;
    min-height: 430px !important;
  }

  .hero-image::before {
    background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,0)) !important;
  }
}

/* iPad landscape and similar tablet widths: keep the full scene visible. */
@media (min-width: 761px) and (max-width: 1180px) {
  .hero-image {
    min-height: 460px !important;
    background-size: contain !important;
    background-position: center center !important;
  }
}

/* iPhone portrait: prevent cropping of the laptop, arm, and subject. */
@media (max-width: 760px) {
  .hero-copy-inner {
    padding: 52px 22px 34px !important;
  }

  .hero-image {
    min-height: 300px !important;
    background-size: contain !important;
    background-position: center center !important;
  }
}

/* iPhone landscape: allow a slightly taller image band so the scene does not feel cut off. */
@media (max-width: 920px) and (orientation: landscape) {
  .hero-image {
    min-height: 360px !important;
    background-size: contain !important;
    background-position: center center !important;
  }
}


/* =========================================================
   TSF Final Pre-Launch Refinements
   Version 0.1.4
   Purpose: desktop menu spacing, mobile CTA centering, related-post image display.
   ========================================================= */

/* Desktop menu: tighten spacing slightly without crowding the header. */
@media (min-width: 1181px) {
  .header-inner {
    grid-template-columns: 300px minmax(0, 1fr) !important;
    gap: 34px !important;
  }

  .site-logo img,
  .custom-logo {
    max-width: 280px !important;
    height: auto !important;
  }

  .site-nav,
  .site-nav ul,
  .site-nav .menu,
  .site-nav .primary-menu {
    gap: 24px !important;
  }

  .site-nav a {
    font-size: 14px !important;
  }

  .site-nav .consultation-link {
    padding: 13px 18px !important;
  }
}

/* Center the primary consultation CTA on iPhone/iPad/tablet hero views. */
@media (max-width: 1180px) {
  .hero-copy-inner {
    text-align: center !important;
  }

  .hero-rule {
    margin-left: auto !important;
    margin-right: auto !important;
  }

  .hero-button {
    display: inline-flex !important;
    width: auto !important;
    max-width: max-content !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }
}

/* Related-post plugin image normalization.
   Covers common related-post plugins without changing article content. */
.related-posts img,
.related-post img,
.related-posts .post-thumbnail img,
.related-post .post-thumbnail img,
.yarpp-related img,
.yarpp-thumbnail img,
.crp_related img,
.crp-list-item img,
.rp4wp-related-posts img,
.jp-relatedposts img,
.jp-relatedposts-post-img,
.jetpack-related-posts img,
.wp_rp_content img,
.wp_rp_wrap img,
.similar-posts img,
#jp-relatedposts img {
  width: 100% !important;
  max-width: 100% !important;
  height: 190px !important;
  object-fit: cover !important;
  object-position: center center !important;
  display: block !important;
  border-radius: 6px !important;
}

/* Make related-post cards more consistent where the plugin uses list/card layouts. */
.related-posts article,
.related-post,
.yarpp-related .yarpp-thumbnail,
.crp_related .crp-list-item,
.rp4wp-related-posts li,
.jp-relatedposts-post,
.wp_rp_content li,
.wp_rp_wrap li {
  overflow: hidden !important;
}

/* Tablet and phone landscape: avoid tiny, half-visible related-post thumbnails. */
@media (min-width: 641px) and (max-width: 1180px) {
  .related-posts img,
  .related-post img,
  .yarpp-related img,
  .yarpp-thumbnail img,
  .crp_related img,
  .crp-list-item img,
  .rp4wp-related-posts img,
  .jp-relatedposts img,
  .jp-relatedposts-post-img,
  .jetpack-related-posts img,
  .wp_rp_content img,
  .wp_rp_wrap img,
  .similar-posts img,
  #jp-relatedposts img {
    height: 230px !important;
    object-fit: cover !important;
  }
}

/* iPhone portrait: full-width related-post thumbnails. */
@media (max-width: 640px) {
  .related-posts img,
  .related-post img,
  .yarpp-related img,
  .yarpp-thumbnail img,
  .crp_related img,
  .crp-list-item img,
  .rp4wp-related-posts img,
  .jp-relatedposts img,
  .jp-relatedposts-post-img,
  .jetpack-related-posts img,
  .wp_rp_content img,
  .wp_rp_wrap img,
  .similar-posts img,
  #jp-relatedposts img {
    height: 220px !important;
    object-fit: cover !important;
  }
}


/* =========================================================
   TSF iPad Portrait Pre-Footer CTA Centering
   Version 0.1.5
   Purpose: override earlier tablet grid rule that places the CTA button in column 2.
   ========================================================= */

@media (min-width: 641px) and (max-width: 1180px) and (orientation: portrait) {
  .next-step {
    text-align: center !important;
  }

  .next-step .wrap.next-inner,
  .next-step .next-inner {
    display: flex !important;
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    max-width: 1180px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    gap: 18px !important;
    text-align: center !important;
  }

  .next-step .next-inner > * {
    flex: 0 0 auto !important;
    width: 100% !important;
    max-width: 760px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    text-align: center !important;
  }

  .next-step .calendar-icon {
    width: 54px !important;
    max-width: 54px !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }

  .next-step .next-inner a.outline-button,
  .next-step a.outline-button,
  .next-step .outline-button {
    display: inline-flex !important;
    flex: 0 0 auto !important;
    width: auto !important;
    max-width: max-content !important;
    min-width: 0 !important;
    grid-column: 1 / -1 !important;
    justify-self: center !important;
    align-self: center !important;
    margin: 0 auto !important;
    text-align: center !important;
    white-space: nowrap !important;
  }
}



/* =========================================================
   TSF iPhone/iPad Landscape Pre-Footer CTA Alignment
   Version 0.1.6
   Purpose: keep portrait centered, restore landscape button to right.
   ========================================================= */

@media (max-width: 1180px) and (orientation: landscape) {
  .next-step {
    text-align: left !important;
  }

  .next-step .wrap.next-inner,
  .next-step .next-inner {
    display: grid !important;
    grid-template-columns: auto minmax(0, 1fr) auto !important;
    align-items: center !important;
    justify-items: stretch !important;
    justify-content: stretch !important;
    text-align: left !important;
    gap: 24px !important;
    width: 100% !important;
  }

  .next-step .calendar-icon {
    grid-column: 1 !important;
    justify-self: start !important;
    align-self: center !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .next-step .next-inner > div:not(.calendar-icon) {
    grid-column: 2 !important;
    justify-self: stretch !important;
    align-self: center !important;
    width: auto !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    text-align: left !important;
  }

  .next-step .next-inner a.outline-button,
  .next-step a.outline-button,
  .next-step .outline-button {
    grid-column: 3 !important;
    display: inline-flex !important;
    justify-self: end !important;
    align-self: center !important;
    width: auto !important;
    max-width: max-content !important;
    min-width: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    text-align: center !important;
    white-space: nowrap !important;
  }
}

/* Safety: keep portrait-only centering intact. */
@media (max-width: 1180px) and (orientation: portrait) {
  .next-step .next-inner a.outline-button,
  .next-step a.outline-button,
  .next-step .outline-button {
    margin-left: auto !important;
    margin-right: auto !important;
  }
}


/* =========================================================
   TSF Post-Launch Design Update
   Version 0.2.0
   Inner pages, blog templates, automatic insights, contact form styling,
   footer social treatment.
   ========================================================= */

/* Footer social profiles */
.footer-logo + p + .social-links,
.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
  align-items: center;
}

.social-links::before {
  content: "Follow The Sanders Firm";
  flex-basis: 100%;
  color: var(--tsf-ink);
  font-size: 12px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  font-weight: 900;
  margin-bottom: 2px;
}

.social-links a {
  width: auto;
  min-width: 36px;
  height: 34px;
  padding: 0 11px;
  border-radius: 4px;
  border: 1px solid var(--tsf-slate);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--tsf-slate);
  text-decoration: none;
  font-weight: 900;
  font-size: 13px;
}

.social-links a:hover,
.social-links a:focus {
  background: var(--tsf-burgundy);
  border-color: var(--tsf-burgundy);
  color: #fff;
}

/* Inner static pages */
.inner-hero,
.archive-hero {
  background: var(--tsf-off-white);
  border-bottom: 1px solid var(--tsf-line);
  padding: 76px 0 70px;
}

.inner-hero-inner,
.archive-hero-inner {
  max-width: 980px;
}

.inner-kicker {
  color: var(--tsf-burgundy);
  font-size: 12px;
  letter-spacing: 3px;
  text-transform: uppercase;
  font-weight: 900;
  margin-bottom: 18px;
}

.inner-hero h1,
.archive-hero h1,
.article-header h1 {
  font-family: var(--tsf-serif);
  font-size: 54px;
  line-height: 1.08;
  font-weight: 500;
  letter-spacing: -0.6px;
  margin: 0;
  color: var(--tsf-ink);
}

.inner-hero p,
.archive-hero p {
  max-width: 790px;
  margin: 22px 0 0;
  color: var(--tsf-text);
  font-size: 20px;
  line-height: 1.7;
}

.inner-rule {
  width: 62px;
  height: 3px;
  background: var(--tsf-burgundy);
  margin-top: 30px;
}

.inner-content {
  background: var(--tsf-white);
  padding: 70px 0 78px;
}

.inner-content-wrap,
.content-narrow {
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 30px;
  padding-right: 30px;
}

.inner-content-wrap h2,
.content-narrow h2,
.article-body h2 {
  font-family: var(--tsf-serif);
  font-size: 32px;
  line-height: 1.22;
  font-weight: 500;
  color: var(--tsf-ink);
  margin: 56px 0 18px;
  padding-top: 6px;
  position: relative;
}

.inner-content-wrap h2::before,
.content-narrow h2::before,
.article-body h2::before {
  content: "";
  display: block;
  width: 44px;
  height: 3px;
  background: var(--tsf-burgundy);
  margin-bottom: 18px;
}

.inner-content-wrap h2:first-child,
.content-narrow h2:first-child,
.article-body h2:first-child {
  margin-top: 0;
}

.inner-content-wrap h3,
.content-narrow h3,
.article-body h3 {
  font-family: var(--tsf-serif);
  font-size: 24px;
  line-height: 1.3;
  font-weight: 500;
  color: var(--tsf-ink);
  margin: 36px 0 14px;
}

.inner-content-wrap p,
.content-narrow p,
.article-body p {
  color: var(--tsf-text);
  font-size: 18px;
  line-height: 1.82;
  margin: 0 0 24px;
}

.inner-content-wrap ul,
.inner-content-wrap ol,
.content-narrow ul,
.content-narrow ol,
.article-body ul,
.article-body ol {
  color: var(--tsf-text);
  font-size: 18px;
  line-height: 1.75;
  margin: 0 0 30px 24px;
}

.inner-content-wrap li,
.content-narrow li,
.article-body li {
  margin-bottom: 10px;
}

.inner-content-wrap blockquote,
.content-narrow blockquote,
.article-body blockquote {
  border-left: 4px solid var(--tsf-burgundy);
  margin: 34px 0;
  padding: 18px 24px;
  background: var(--tsf-off-white);
  color: var(--tsf-ink);
}

/* Blog archive */
.archive-hero {
  padding-bottom: 64px;
}

.archive-listing {
  padding-top: 70px;
}

.pagination-wrap {
  margin-top: 44px;
  text-align: center;
}

.pagination-wrap .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  margin: 0 3px;
  padding: 0 10px;
  border: 1px solid var(--tsf-line);
  color: var(--tsf-ink);
  text-decoration: none;
  font-weight: 800;
}

.pagination-wrap .current,
.pagination-wrap .page-numbers:hover {
  background: var(--tsf-burgundy);
  color: #fff;
  border-color: var(--tsf-burgundy);
}

.insight-placeholder,
.related-placeholder {
  height: 205px;
  background: var(--tsf-off-white);
  border-bottom: 1px solid var(--tsf-line);
}

/* Single thought-piece */
.single-content.thought-piece {
  background: var(--tsf-white);
  padding: 74px 0 78px;
}

.article-wrap {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 30px;
}

.article-header {
  border-bottom: 1px solid var(--tsf-line);
  padding-bottom: 32px;
  margin-bottom: 34px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  color: var(--tsf-muted);
  font-size: 14px;
  margin-top: 18px;
  font-weight: 700;
}

.article-featured-image {
  margin: 0 0 34px;
}

.article-featured-image img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
}

.article-share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 0 0 38px;
  padding: 16px 18px;
  background: var(--tsf-off-white);
  border: 1px solid var(--tsf-line);
  border-radius: 8px;
}

.article-share span {
  color: var(--tsf-ink);
  font-weight: 900;
  margin-right: 4px;
}

.article-share a {
  color: var(--tsf-burgundy);
  text-decoration: none;
  font-weight: 900;
  border-bottom: 1px solid rgba(127,46,51,.35);
}

.author-box,
.related-analysis {
  margin-top: 56px;
  padding: 28px;
  background: var(--tsf-off-white);
  border: 1px solid var(--tsf-line);
  border-radius: 10px;
}

.author-box h2,
.related-analysis h2 {
  font-family: var(--tsf-serif);
  font-size: 26px;
  font-weight: 500;
  margin: 0 0 14px;
  color: var(--tsf-ink);
}

.author-box p {
  margin: 0;
  color: var(--tsf-text);
  font-size: 16px;
  line-height: 1.72;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.related-card {
  background: #fff;
  border: 1px solid var(--tsf-line);
  border-radius: 8px;
  overflow: hidden;
}

.related-card a {
  color: var(--tsf-ink);
  text-decoration: none;
  display: block;
}

.related-card img,
.related-placeholder {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
}

.related-card span {
  display: block;
  padding: 14px;
  font-size: 14px;
  line-height: 1.45;
  font-weight: 900;
}

/* Related-post plugin image normalization */
.related-posts img,
.related-post img,
.yarpp-related img,
.yarpp-thumbnail img,
.crp_related img,
.crp-list-item img,
.rp4wp-related-posts img,
.jp-relatedposts img,
.jp-relatedposts-post-img,
.jetpack-related-posts img,
.wp_rp_content img,
.wp_rp_wrap img,
.similar-posts img,
#jp-relatedposts img {
  width: 100% !important;
  max-width: 100% !important;
  height: 210px !important;
  object-fit: cover !important;
  object-position: center center !important;
  display: block !important;
  border-radius: 6px !important;
}

/* Contact page / CF7 styling moved into the theme */
.tsf-contact-page {
  max-width: 1040px;
  margin: 42px auto 0;
}

.tsf-contact-intro,
.tsf-contact-section {
  border-left: 3px solid var(--tsf-burgundy);
  padding-left: 28px;
  margin-bottom: 34px;
}

.tsf-contact-intro h2,
.tsf-contact-section h2,
.tsf-form-panel h2 {
  font-family: var(--tsf-serif);
  font-size: 32px;
  line-height: 1.2;
  font-weight: 500;
  color: var(--tsf-ink);
  margin: 0 0 18px;
}

.tsf-contact-intro p,
.tsf-contact-section p {
  color: var(--tsf-text);
  font-size: 18px;
  line-height: 1.75;
  margin: 0 0 20px;
}

.tsf-form-panel {
  width: 100%;
  background: #fff;
  border: 1px solid var(--tsf-line);
  border-radius: 10px;
  padding: 38px;
  box-shadow: 0 12px 32px rgba(0,0,0,.05);
  margin-bottom: 34px;
}

.tsf-intake-form {
  width: 100%;
  margin-top: 8px;
}

.tsf-field {
  width: 100%;
  margin-bottom: 20px;
}

.tsf-intake-form label {
  display: block;
  width: 100%;
  color: var(--tsf-ink);
  font-size: 14px;
  font-weight: 800;
}

.tsf-intake-form input[type="text"],
.tsf-intake-form input[type="email"],
.tsf-intake-form input[type="tel"],
.tsf-intake-form select,
.tsf-intake-form textarea {
  width: 100% !important;
  border: 1px solid var(--tsf-line);
  border-radius: 4px;
  padding: 14px 15px;
  margin-top: 7px;
  font-size: 16px;
  color: var(--tsf-ink);
  background: #fff;
  font-family: var(--tsf-sans);
}

.tsf-intake-form textarea {
  min-height: 175px;
  resize: vertical;
}

.tsf-intake-form input:focus,
.tsf-intake-form select:focus,
.tsf-intake-form textarea:focus {
  outline: none;
  border-color: var(--tsf-burgundy);
  box-shadow: 0 0 0 3px rgba(127,46,51,.12);
}

.tsf-acknowledgment {
  margin-top: 22px;
  padding: 18px;
  background: var(--tsf-off-white);
  border: 1px solid var(--tsf-line);
  border-radius: 8px;
}

.tsf-acknowledgment .wpcf7-list-item {
  margin: 0;
}

.tsf-acknowledgment label {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  color: var(--tsf-text);
  font-size: 14px;
  line-height: 1.55;
  font-weight: 600;
}

.tsf-acknowledgment input[type="checkbox"] {
  width: auto !important;
  min-width: 16px;
  margin-top: 4px;
  accent-color: var(--tsf-burgundy);
}

.tsf-submit {
  margin-top: 26px;
  margin-bottom: 0;
}

.tsf-intake-form input[type="submit"] {
  background: var(--tsf-burgundy);
  color: #fff;
  border: 0;
  border-radius: 4px;
  padding: 15px 24px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: .7px;
  text-transform: uppercase;
  cursor: pointer;
  font-family: var(--tsf-sans);
}

.tsf-intake-form input[type="submit"]:hover {
  background: var(--tsf-burgundy-dark);
}

.tsf-contact-warning {
  margin-top: 28px;
  padding: 22px;
  background: var(--tsf-off-white);
  border: 1px solid var(--tsf-line);
  border-radius: 8px;
  color: var(--tsf-text);
  font-size: 15px;
  line-height: 1.65;
}

.tsf-contact-warning strong {
  color: var(--tsf-ink);
}

.tsf-intake-form .wpcf7-not-valid-tip {
  color: var(--tsf-burgundy);
  font-size: 13px;
  margin-top: 6px;
  font-weight: 700;
}

.tsf-intake-form .wpcf7-response-output {
  margin: 22px 0 0;
  padding: 16px 18px;
  border-radius: 6px;
  font-size: 15px;
  line-height: 1.55;
}

/* Responsive refinements for new templates */
@media (max-width: 980px) {
  .related-grid {
    grid-template-columns: 1fr;
  }

  .related-card img,
  .related-placeholder {
    height: 230px;
  }
}

@media (max-width: 760px) {
  .inner-hero,
  .archive-hero {
    padding: 52px 0 48px;
  }

  .inner-hero h1,
  .archive-hero h1,
  .article-header h1 {
    font-size: 38px;
  }

  .inner-hero p,
  .archive-hero p {
    font-size: 18px;
  }

  .inner-content,
  .single-content.thought-piece {
    padding: 52px 0 58px;
  }

  .inner-content-wrap,
  .content-narrow,
  .article-wrap {
    padding-left: 22px;
    padding-right: 22px;
  }

  .inner-content-wrap h2,
  .content-narrow h2,
  .article-body h2 {
    font-size: 28px;
    margin-top: 42px;
  }

  .inner-content-wrap p,
  .content-narrow p,
  .article-body p,
  .inner-content-wrap li,
  .content-narrow li,
  .article-body li {
    font-size: 17px;
    line-height: 1.78;
  }

  .article-share {
    align-items: flex-start;
  }

  .tsf-contact-page {
    margin-top: 32px;
  }

  .tsf-contact-intro,
  .tsf-contact-section {
    padding-left: 20px;
  }

  .tsf-contact-intro h2,
  .tsf-contact-section h2,
  .tsf-form-panel h2 {
    font-size: 27px;
  }

  .tsf-contact-intro p,
  .tsf-contact-section p {
    font-size: 17px;
  }

  .tsf-form-panel {
    padding: 26px;
  }

  .tsf-intake-form input[type="submit"] {
    width: 100%;
  }
}


/* =========================================================
   TSF Design Update Refinement
   Version 0.2.1
   Purpose: preserve page-title treatment, remove repeated landscape/accent
   lines from inner-page headings and Contact page sections.
   ========================================================= */

/* Keep the page title hero/rule, but remove repeated burgundy lines before every H2. */
.inner-content-wrap h2::before,
.content-narrow h2::before,
.article-body h2::before {
  display: none !important;
  content: none !important;
}

/* Restore clean section heading spacing after removing accent rules. */
.inner-content-wrap h2,
.content-narrow h2,
.article-body h2 {
  padding-top: 0 !important;
  margin-top: 48px !important;
}

/* Contact page: remove left vertical/landscape accent treatment and keep clean blocks. */
.tsf-contact-intro,
.tsf-contact-section {
  border-left: 0 !important;
  padding-left: 0 !important;
  margin-bottom: 34px !important;
}

.tsf-contact-intro h2,
.tsf-contact-section h2,
.tsf-form-panel h2 {
  padding-top: 0 !important;
}

.tsf-contact-intro h2::before,
.tsf-contact-section h2::before,
.tsf-form-panel h2::before {
  display: none !important;
  content: none !important;
}

/* Keep subtle separation through spacing, not decorative rules. */
.tsf-contact-section {
  padding-top: 4px !important;
}

/* Footer social links: ensure the area appears cleanly when URLs are populated. */
.social-links {
  min-height: 0 !important;
}

.social-links:empty {
  display: none !important;
}

@media (max-width: 760px) {
  .inner-content-wrap h2,
  .content-narrow h2,
  .article-body h2 {
    margin-top: 38px !important;
  }

  .tsf-contact-intro,
  .tsf-contact-section {
    padding-left: 0 !important;
  }
}


/* =========================================================
   TSF Footer Social Customizer Update
   Version 0.2.2
   Purpose: social links controlled through Appearance > Customize,
   not ACF Options Page.
   ========================================================= */

.social-links::before {
  display: none !important;
  content: none !important;
}

.social-label {
  color: var(--tsf-ink);
  font-size: 12px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  font-weight: 900;
  margin-top: 24px;
  margin-bottom: 10px;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 0 !important;
  align-items: center;
}

.social-links a {
  width: auto !important;
  min-width: 36px !important;
  height: 34px !important;
  padding: 0 11px !important;
  border-radius: 4px;
  border: 1px solid var(--tsf-slate);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--tsf-slate);
  text-decoration: none;
  font-weight: 900;
  font-size: 13px;
}

.social-links a:hover,
.social-links a:focus {
  background: var(--tsf-burgundy);
  border-color: var(--tsf-burgundy);
  color: #fff;
}


/* =========================================================
   TSF Footer Social Customizer Placement Update
   Version 0.2.3
   Note: footer social URL fields appear under Appearance > Customize > Site Identity.
   ========================================================= */


/* =========================================================
   TSF Social Share Row Update
   Version 0.2.4
   Purpose: show share row on pages and ensure LinkedIn / X / Email are all visible on posts.
   ========================================================= */

.article-share,
.tsf-share-row {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  gap: 10px 14px !important;
  margin: 42px 0 0 !important;
  padding: 16px 18px !important;
  background: var(--tsf-off-white) !important;
  border: 1px solid var(--tsf-line) !important;
  border-radius: 8px !important;
  clear: both !important;
}

.single-content .article-share {
  margin: 0 0 38px !important;
}

.article-share span,
.tsf-share-row span {
  display: inline-block !important;
  color: var(--tsf-ink) !important;
  font-weight: 900 !important;
  margin-right: 2px !important;
}

.article-share a,
.tsf-share-row a,
.article-share a:visited,
.tsf-share-row a:visited {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: var(--tsf-burgundy) !important;
  background: #fff !important;
  border: 1px solid rgba(127,46,51,.32) !important;
  border-radius: 4px !important;
  padding: 8px 11px !important;
  font-size: 13px !important;
  line-height: 1 !important;
  text-decoration: none !important;
  font-weight: 900 !important;
  min-width: 46px !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.article-share a:hover,
.tsf-share-row a:hover,
.article-share a:focus,
.tsf-share-row a:focus {
  background: var(--tsf-burgundy) !important;
  color: #fff !important;
  border-color: var(--tsf-burgundy) !important;
}

@media (max-width: 640px) {
  .article-share,
  .tsf-share-row {
    align-items: flex-start !important;
  }

  .article-share span,
  .tsf-share-row span {
    flex-basis: 100% !important;
  }
}


/* =========================================================
   TSF Share / Author Refinement
   Version 0.2.5
   Purpose: add Facebook share and remove redundant theme author box.
   ========================================================= */

.author-box {
  display: none !important;
}

.article-share a.share-facebook,
.tsf-share-row a.share-facebook {
  min-width: 78px !important;
}


/* =========================================================
   TSF Share Position Refinement
   Version 0.2.6
   Purpose: standardize share rows after content on pages and posts.
   ========================================================= */

.single-content .article-share,
.single-content .tsf-share-row {
  margin: 42px 0 0 !important;
}

.related-analysis {
  margin-top: 42px !important;
}

.inner-content-wrap .article-share,
.inner-content-wrap .tsf-share-row {
  margin-top: 42px !important;
  margin-bottom: 0 !important;
}


/* =========================================================
   TSF Author Meta Correction
   Version 0.2.7
   Purpose: single-post meta identifies Eric Sanders, not the firm entity.
   ========================================================= */


/* =========================================================
   TSF Single Blog Title Rule Alignment
   Version 0.2.8
   Purpose: make single blog title area coordinate with inner-page title treatment.
   ========================================================= */

.article-header {
  border-bottom: 0 !important;
}

.article-title-rule {
  margin-top: 28px !important;
  margin-bottom: 0 !important;
}

.single-content .article-header {
  padding-bottom: 0 !important;
  margin-bottom: 34px !important;
}
