/*
Theme Name: Texas Homes Realty Modern
Theme URI: https://www.txhomesrealty.com/
Author: Pay Per Click Houston
Description: A modern, conversion-focused theme for Texas Homes Realty & Management. Built for property management, rentals, buying, selling, and existing WordPress content.
Version: 1.3.0
Requires at least: 6.4
Requires PHP: 7.4
Text Domain: thr-modern
*/

:root {
  --thr-purple: #60408f;
  --thr-purple-dark: #432a68;
  --thr-purple-light: #eee9f6;
  --thr-ink: #29252f;
  --thr-muted: #6d6873;
  --thr-gray: #f5f4f6;
  --thr-line: #e4e0e8;
  --thr-white: #fff;
  --thr-gold: #c9a86a;
  --thr-radius: 18px;
  --thr-shadow: 0 18px 50px rgba(35, 25, 48, .12);
  --thr-container: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--thr-ink); background: var(--thr-white); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: 17px; line-height: 1.7; -webkit-font-smoothing: antialiased; }
body.menu-open { overflow: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--thr-purple-dark); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--thr-purple); }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--thr-gold); outline-offset: 3px; }
.thr-container { width: min(calc(100% - 40px), var(--thr-container)); margin-inline: auto; }
.thr-container::before, .thr-container::after { content: none !important; display: none !important; }
.narrow { width: min(calc(100% - 40px), 820px); margin-inline: auto; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link:focus { clip: auto; width: auto; height: auto; margin: 10px; padding: 10px 16px; background: #fff; z-index: 99999; }

h1, h2, h3, h4 { margin: 0 0 .65em; color: var(--thr-ink); font-family: Georgia, "Times New Roman", serif; line-height: 1.13; letter-spacing: -.025em; }
h1 { font-size: clamp(2.75rem, 6vw, 5.6rem); }
h2 { font-size: clamp(2.05rem, 4vw, 3.45rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.65rem); }
p { margin: 0 0 1.25em; }
.eyebrow { display: inline-flex; align-items: center; gap: 9px; margin-bottom: 18px; color: var(--thr-purple); font-size: .78rem; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.section-heading { max-width: 730px; margin-bottom: 42px; }
.section-heading p { color: var(--thr-muted); font-size: 1.08rem; }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 52px; padding: 13px 24px; border: 1px solid transparent; border-radius: 999px; background: var(--thr-purple); color: #fff; font-size: .86rem; font-weight: 800; letter-spacing: .025em; line-height: 1.2; text-decoration: none; transition: transform .2s ease, box-shadow .2s ease, background .2s ease; }
.button:hover { transform: translateY(-2px); background: var(--thr-purple-dark); color: #fff; box-shadow: 0 12px 28px rgba(67,42,104,.26); }
.button--light { background: #fff; color: var(--thr-purple-dark); }
.button--light:hover { background: var(--thr-purple-light); color: var(--thr-purple-dark); }
.button--outline { border-color: rgba(255,255,255,.65); background: transparent; color: #fff; }
.button--outline:hover { background: #fff; color: var(--thr-purple-dark); }
.button--ghost { border-color: var(--thr-line); background: transparent; color: var(--thr-purple-dark); }
.button--ghost:hover { border-color: var(--thr-purple); background: var(--thr-purple-light); color: var(--thr-purple-dark); }

.site-topbar { background: var(--thr-ink); color: rgba(255,255,255,.82); font-size: .79rem; }
.site-topbar__inner { min-height: 38px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.site-topbar p { margin: 0; }
.site-topbar a { color: #fff; text-decoration: none; }
.site-topbar__links { display: flex; gap: 18px; }
.site-header { position: relative; z-index: 50; border-bottom: 1px solid var(--thr-line); background: rgba(255,255,255,.96); }
.site-header.is-stuck { position: sticky; top: 0; box-shadow: 0 8px 30px rgba(30,20,40,.08); }
.site-header__inner { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.site-branding { flex: 0 0 auto; }
.custom-logo-link { display: block; }
.custom-logo { max-height: 60px; width: auto; }
.brand-wordmark { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-icon { width: 46px; height: 46px; flex: 0 0 46px; border-radius: 13px 5px 13px 5px; object-fit: contain; box-shadow: 0 8px 18px rgba(67,42,104,.22); }
.brand-copy { min-width: 0; }
.brand-name { display: block; color: var(--thr-ink); font-family: Georgia, serif; font-size: 1.16rem; font-weight: 700; letter-spacing: .01em; line-height: 1.05; }
.brand-tagline { display: block; margin-top: 5px; color: var(--thr-purple); font-size: .59rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.primary-nav { min-width: 0; margin-left: auto; }
.primary-nav ul { margin: 0; padding: 0; list-style: none; }
.primary-nav > ul { display: flex; align-items: center; gap: 2px; }
.primary-nav li { position: relative; margin: 0; }
.primary-nav a { display: block; padding: 11px 8px; color: var(--thr-ink); font-size: .79rem; font-weight: 750; line-height: 1.3; text-decoration: none; white-space: nowrap; }
.primary-nav a:hover, .primary-nav .current-menu-item > a { color: var(--thr-purple); }
.primary-nav .menu-item-has-children > a { padding-right: 22px; }
.primary-nav .menu-item-has-children > a::after { content: ""; position: absolute; top: 50%; right: 8px; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-65%) rotate(45deg); }
.primary-nav .sub-menu { position: absolute; top: calc(100% + 10px); left: 0; z-index: 100; min-width: 245px; padding: 10px; border: 1px solid var(--thr-line); border-radius: 12px; background: #fff; box-shadow: var(--thr-shadow); opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .18s ease, visibility .18s ease, transform .18s ease; }
.primary-nav > ul > li:nth-last-child(-n+3) > .sub-menu { right: 0; left: auto; }
.primary-nav .sub-menu a { padding: 10px 12px; border-radius: 7px; font-size: .8rem; white-space: normal; }
.primary-nav .sub-menu a:hover { background: var(--thr-purple-light); }
.primary-nav li:hover > .sub-menu, .primary-nav li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.submenu-toggle { display: none; }
.header-cta { min-height: 44px; padding: 11px 18px; }
.menu-toggle { display: none; width: 46px; height: 46px; padding: 0; border: 1px solid var(--thr-line); border-radius: 50%; background: #fff; color: var(--thr-ink); }
.menu-toggle span, .menu-toggle::before, .menu-toggle::after { content: ""; display: block; width: 20px; height: 2px; margin: 4px auto; background: currentColor; transition: .2s; }
.menu-toggle.is-active span { opacity: 0; }
.menu-toggle.is-active::before { transform: translateY(6px) rotate(45deg); }
.menu-toggle.is-active::after { transform: translateY(-6px) rotate(-45deg); }

.hero { position: relative; min-height: 700px; display: grid; align-items: center; isolation: isolate; background: #2e2940 center/cover no-repeat; color: #fff; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(27,21,34,.91) 0%, rgba(38,27,50,.72) 42%, rgba(27,21,34,.18) 78%, rgba(27,21,34,.1) 100%); }
.hero::after { content: ""; position: absolute; inset: auto 0 0; height: 140px; z-index: -1; background: linear-gradient(transparent, rgba(20,15,27,.32)); }
.hero__content { width: min(690px, 100%); padding: 92px 0 150px; }
.hero .eyebrow { color: #d9c8f1; }
.hero h1 { color: #fff; }
.hero h1 em { color: #d9c8f1; font-style: normal; }
.hero__lead { max-width: 600px; color: rgba(255,255,255,.86); font-size: clamp(1.05rem, 2vw, 1.28rem); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero__trust { display: flex; flex-wrap: wrap; gap: 14px 25px; margin-top: 30px; color: rgba(255,255,255,.78); font-size: .83rem; font-weight: 700; }
.hero__trust span::before { content: "✓"; margin-right: 8px; color: #e3cc9a; }
.quick-actions { position: relative; z-index: 5; margin-top: -70px; }
.quick-actions__grid { display: grid; grid-template-columns: repeat(5, 1fr); border: 1px solid rgba(255,255,255,.35); border-radius: var(--thr-radius); background: #fff; box-shadow: var(--thr-shadow); overflow: hidden; }
.quick-action { min-height: 140px; padding: 25px 18px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; border-right: 1px solid var(--thr-line); color: var(--thr-ink); text-align: center; text-decoration: none; transition: .2s ease; }
.quick-action:last-child { border: 0; }
.quick-action:hover { background: var(--thr-purple); color: #fff; transform: translateY(-5px); }
.quick-action__icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; background: var(--thr-purple-light); color: var(--thr-purple); font-size: 1.1rem; font-weight: 900; }
.quick-action:hover .quick-action__icon { background: rgba(255,255,255,.16); color: #fff; }
.quick-action strong { font-family: Georgia, serif; font-size: 1.03rem; }
.quick-action small { color: var(--thr-muted); line-height: 1.35; }
.quick-action:hover small { color: rgba(255,255,255,.76); }

.intro { padding: 135px 0 100px; }
.intro__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(50px, 8vw, 100px); align-items: center; }
.intro__media { position: relative; }
.intro__media img { width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: var(--thr-radius); box-shadow: var(--thr-shadow); }
.intro__badge { position: absolute; right: -24px; bottom: 30px; width: 160px; min-height: 145px; padding: 22px; display: flex; flex-direction: column; justify-content: center; border: 7px solid #fff; border-radius: 50%; background: var(--thr-purple); color: #fff; text-align: center; box-shadow: var(--thr-shadow); }
.intro__badge strong { font-family: Georgia, serif; font-size: 2.35rem; line-height: 1; }
.intro__badge span { margin-top: 7px; font-size: .7rem; font-weight: 800; letter-spacing: .1em; line-height: 1.25; text-transform: uppercase; }
.intro__copy p { color: var(--thr-muted); }
.check-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 22px; margin: 27px 0 34px; padding: 0; list-style: none; }
.check-list li { position: relative; padding-left: 27px; font-weight: 750; }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--thr-purple); }

.services { padding: 100px 0; background: var(--thr-gray); }
.services__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service-card { border: 1px solid var(--thr-line); border-radius: var(--thr-radius); background: #fff; overflow: hidden; box-shadow: 0 10px 32px rgba(35,25,48,.06); transition: transform .25s ease, box-shadow .25s ease; }
.service-card:hover { transform: translateY(-8px); box-shadow: var(--thr-shadow); }
.service-card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.service-card__body { padding: 30px; }
.service-card__number { color: var(--thr-purple); font-size: .72rem; font-weight: 900; letter-spacing: .16em; text-transform: uppercase; }
.service-card h3 { margin-top: 8px; }
.service-card p { color: var(--thr-muted); font-size: .94rem; }
.text-link { display: inline-flex; align-items: center; gap: 8px; color: var(--thr-purple-dark); font-size: .81rem; font-weight: 850; letter-spacing: .03em; text-decoration: none; text-transform: uppercase; }
.text-link::after { content: "→"; transition: transform .2s; }
.text-link:hover::after { transform: translateX(4px); }

.stats { background: var(--thr-purple-dark); color: #fff; }
.stats__grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 42px 22px; border-right: 1px solid rgba(255,255,255,.14); text-align: center; }
.stat:last-child { border: 0; }
.stat strong { display: block; color: #fff; font-family: Georgia, serif; font-size: clamp(2rem, 4vw, 3rem); line-height: 1; }
.stat span { display: block; margin-top: 10px; color: rgba(255,255,255,.7); font-size: .75rem; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }

.process { padding: 110px 0; }
.process__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; counter-reset: steps; }
.step { position: relative; padding-top: 24px; border-top: 2px solid var(--thr-line); counter-increment: steps; }
.step::before { content: "0" counter(steps); position: absolute; top: -22px; left: 0; padding-right: 12px; background: #fff; color: var(--thr-purple); font-family: Georgia, serif; font-size: 1.2rem; font-weight: 700; }
.step p { color: var(--thr-muted); }

.founder { padding: 100px 0; background: #2c2831; color: #fff; overflow: hidden; }
.founder__grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(50px, 8vw, 100px); align-items: center; }
.founder__image { position: relative; }
.founder__image img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: var(--thr-radius); }
.founder blockquote { margin: 0; }
.founder blockquote p { color: #fff; font-family: Georgia, serif; font-size: clamp(1.55rem, 3vw, 2.4rem); line-height: 1.38; }
.founder cite { display: block; margin-top: 26px; color: #d9c8f1; font-style: normal; font-weight: 800; }
.founder cite span { display: block; margin-top: 4px; color: rgba(255,255,255,.55); font-size: .78rem; font-weight: 600; }

.cta-band { padding: 88px 0; background: linear-gradient(135deg, var(--thr-purple), var(--thr-purple-dark)); color: #fff; }
.cta-band__inner { display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: center; }
.cta-band h2 { color: #fff; margin-bottom: 12px; }
.cta-band p { margin: 0; color: rgba(255,255,255,.75); }

.news { padding: 105px 0; }
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.post-card { border-bottom: 1px solid var(--thr-line); padding-bottom: 24px; }
.post-card img { width: 100%; aspect-ratio: 16/10; object-fit: cover; border-radius: 12px; margin-bottom: 22px; }
.post-card__meta { color: var(--thr-purple); font-size: .72rem; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.post-card h3 { margin: 9px 0 12px; }
.post-card h3 a { color: inherit; text-decoration: none; }
.post-card p { color: var(--thr-muted); font-size: .9rem; }

.contact-panel { padding: 100px 0; background: var(--thr-gray); }
.contact-panel__card { display: grid; grid-template-columns: 1.1fr .9fr; border-radius: var(--thr-radius); background: #fff; box-shadow: var(--thr-shadow); overflow: hidden; }
.contact-panel__content { padding: clamp(35px, 6vw, 70px); }
.contact-panel__aside { padding: clamp(35px, 5vw, 60px); background: var(--thr-purple-dark); color: #fff; }
.contact-panel__aside h3 { color: #fff; }
.contact-list { margin: 25px 0 0; padding: 0; list-style: none; }
.contact-list li { padding: 15px 0; border-top: 1px solid rgba(255,255,255,.13); }
.contact-list span { display: block; color: #cdbce2; font-size: .68rem; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
.contact-list a, .contact-list address { color: #fff; font-style: normal; text-decoration: none; }

.homepage-additions { padding: 90px 0; border-top: 1px solid var(--thr-line); background: #fff; }
.homepage-additions__content::before, .homepage-additions__content::after { content: none !important; display: none !important; }
.homepage-additions__content > :first-child { margin-top: 0; }
.homepage-additions__content > :last-child { margin-bottom: 0; }
.homepage-additions__content > .alignwide { width: min(calc(100% - 40px), var(--thr-container)); }
.homepage-additions__content > .alignfull { width: 100%; max-width: none; }

.site-main { min-height: 50vh; }
.page-hero { padding: 95px 0 80px; background: linear-gradient(135deg, #302a38, var(--thr-purple-dark)); color: #fff; }
.page-hero .eyebrow { color: #d9c8f1; }
.page-hero h1 { max-width: 850px; color: #fff; font-size: clamp(2.5rem, 5vw, 4.6rem); }
.page-hero p { max-width: 710px; color: rgba(255,255,255,.72); }
.content-area { padding: 80px 0 100px; }
.entry-content > * { max-width: 820px; margin-left: auto; margin-right: auto; }
.entry-content > .alignwide { max-width: var(--thr-container); }
.entry-content > .alignfull { max-width: none; }
.entry-content h2, .entry-content h3 { margin-top: 1.5em; }
.entry-content img { border-radius: 12px; }
.entry-content table { width: 100%; border-collapse: collapse; }
.entry-content th, .entry-content td { padding: 12px; border: 1px solid var(--thr-line); text-align: left; }
.entry-content input:not([type="submit"]), .entry-content textarea, .entry-content select { width: 100%; padding: 13px 14px; border: 1px solid #cbc6d0; border-radius: 8px; background: #fff; }
.entry-content input[type="submit"] { border: 0; border-radius: 999px; padding: 14px 24px; background: var(--thr-purple); color: #fff; font-weight: 800; cursor: pointer; }
.archive-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 34px; }
.pagination { margin-top: 50px; }
.not-found { padding: 120px 0; text-align: center; }

.site-footer { padding: 75px 0 0; background: #211e25; color: rgba(255,255,255,.67); }
.footer-grid { display: grid; grid-template-columns: 1.25fr .75fr .9fr 1.1fr; gap: 50px; padding-bottom: 55px; }
.site-footer h2, .site-footer h3 { color: #fff; }
.site-footer h3 { font-family: inherit; font-size: .74rem; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
.site-footer a { color: rgba(255,255,255,.72); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.footer-menu { margin: 0; padding: 0; list-style: none; }
.footer-menu li { margin: 9px 0; }
.footer-legal { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.footer-legal a { padding: 7px 10px; border: 1px solid rgba(255,255,255,.14); border-radius: 6px; font-size: .72rem; }
.footer-bottom { padding: 22px 0; border-top: 1px solid rgba(255,255,255,.1); font-size: .73rem; }
.footer-bottom__inner { display: flex; justify-content: space-between; gap: 20px; }

@media (max-width: 1280px) {
  .primary-nav { position: absolute; top: 100%; right: 0; left: 0; display: none; max-height: calc(100vh - 90px); margin: 0; padding: 18px 20px 28px; border-top: 1px solid var(--thr-line); background: #fff; box-shadow: 0 22px 40px rgba(30,20,40,.12); overflow-y: auto; }
  .primary-nav.is-open { display: block; }
  .primary-nav > ul { display: block; }
  .primary-nav a { padding: 14px 48px 14px 8px; border-bottom: 1px solid var(--thr-line); font-size: .98rem; white-space: normal; }
  .primary-nav .menu-item-has-children > a { padding-right: 48px; }
  .primary-nav .menu-item-has-children > a::after { display: none; }
  .primary-nav .sub-menu { position: static; min-width: 0; max-height: 0; padding: 0 0 0 18px; border: 0; border-radius: 0; box-shadow: none; opacity: 1; visibility: visible; transform: none; overflow: hidden; transition: max-height .25s ease; }
  .primary-nav .submenu-open > .sub-menu { max-height: 1000px; }
  .primary-nav .sub-menu a { padding: 11px 12px; border-bottom: 1px solid var(--thr-line); border-radius: 0; font-size: .9rem; }
  .submenu-toggle { position: absolute; top: 6px; right: 0; display: grid; width: 42px; height: 42px; place-items: center; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--thr-purple-dark); cursor: pointer; }
  .submenu-toggle::before { content: "+"; font-size: 1.35rem; line-height: 1; }
  .submenu-toggle[aria-expanded="true"]::before { content: "−"; }
  .menu-toggle { display: block; }
  .header-cta { margin-left: auto; }
  .quick-actions__grid { grid-template-columns: repeat(3, 1fr); }
  .quick-action:nth-child(3) { border-right: 0; }
  .quick-action:nth-child(-n+3) { border-bottom: 1px solid var(--thr-line); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 780px) {
  .site-topbar__inner { justify-content: center; }
  .site-topbar__inner > p, .site-topbar__links a:last-child { display: none; }
  .site-header__inner { min-height: 76px; }
  .header-cta { display: none; }
  .brand-tagline { display: none; }
  .hero { min-height: 670px; background-position: 62% center; }
  .hero::before { background: linear-gradient(90deg, rgba(27,21,34,.92), rgba(38,27,50,.74) 70%, rgba(27,21,34,.35)); }
  .hero__content { padding: 75px 0 135px; }
  .quick-actions__grid { grid-template-columns: 1fr 1fr; }
  .quick-action, .quick-action:nth-child(3) { min-height: 125px; border-right: 1px solid var(--thr-line); border-bottom: 1px solid var(--thr-line); }
  .quick-action:nth-child(even) { border-right: 0; }
  .quick-action:last-child { grid-column: 1 / -1; border-bottom: 0; }
  .intro { padding-top: 110px; }
  .intro__grid, .founder__grid, .contact-panel__card { grid-template-columns: 1fr; }
  .intro__media { max-width: 540px; }
  .intro__media img { aspect-ratio: 4/3; }
  .intro__badge { right: -10px; width: 135px; min-height: 125px; }
  .services__grid, .process__grid, .post-grid, .archive-grid { grid-template-columns: 1fr; }
  .stats__grid { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(-n+2) { border-bottom: 1px solid rgba(255,255,255,.14); }
  .cta-band__inner { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom__inner { display: block; }
  .homepage-additions { padding: 65px 0; }
}

@media (max-width: 480px) {
  .thr-container, .narrow { width: min(calc(100% - 28px), var(--thr-container)); }
  body { font-size: 16px; }
  .brand-name { font-size: .99rem; }
  .brand-icon { width: 40px; height: 40px; flex-basis: 40px; }
  .hero__actions .button { width: 100%; }
  .quick-actions { margin-top: -50px; }
  .quick-action { padding: 20px 10px; }
  .check-list { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
